Skip to content

Instantly share code, notes, and snippets.

View heavyengineer's full-sized avatar
👾
not eating cheese

steev heavyengineer

👾
not eating cheese
View GitHub Profile

Keybase proof

I hereby claim:

  • I am heavyengineer on github.
  • I am steev_initsix (https://keybase.io/steev_initsix) on keybase.
  • I have a public key ASBrl4cBk4m1bAY5AdcyXDttBZtn_HehbYUV2lEHme7jsQo

To claim this, I am signing this object:

Keybase proof

I hereby claim:

  • I am heavyengineer on github.
  • I am steve_axonista (https://keybase.io/steve_axonista) on keybase.
  • I have a public key ASC-5e4jYDU0Jb5g4o_CpN5vTsgaegudP4b_B3bU-GKY9wo

To claim this, I am signing this object:

@heavyengineer
heavyengineer / transcode.sh
Created November 17, 2019 12:20
Transcode oneplus3 4k video to DNXHR format compatible with davinci resolve 16
#!/bin/bash
# if an argument is supplied, use that as the filename
if test ! -z "$1"
then
ffmpeg -i ${1} -c:v dnxhd -profile:v dnxhr_hq -pix_fmt yuv420p -c:a pcm_s16le ${1}.mov
# else, get all the MP4s
else
for f in *.MP4
do
ffmpeg -i ${f} -c:v dnxhd -profile:v dnxhr_hq -pix_fmt yuv420p -c:a pcm_s16le ${f}.mov
@heavyengineer
heavyengineer / espeak_mbrola.sh
Created November 2, 2019 17:29
use espeak and voices and output to wav
espeak -p 30 -k 15 -v en-GB-x-gbcwmd -s 130 "Some text." --stdout > yamyam.wav
@heavyengineer
heavyengineer / gcloudTTS.sh
Created November 2, 2019 17:03
get text to speech as files from gcloud
#!/bin/bash
# supply a string of text to be encoded
# e.g. ./getGcloudTTs.sh $(cat speech.txt)
timestamp=`date +"%s"`
outputfilename=audio_${timestamp}.mp3
data()
{
@heavyengineer
heavyengineer / gist:2ec7c771bd4dcff8dbc4fa33b64fc894
Created May 21, 2019 17:12
ffmpeg gopro 7 wide angle footage with lens correction filter
#!/bin/bash
lens="k2=0.006:k1=-0.18"
for f in *.MP4
do
ffmpeg -i ${f} -vf lenscorrection=${lens} ${f}.mp4
done
@heavyengineer
heavyengineer / transcode.sh
Last active October 21, 2022 13:21
transcode gopro mp4 to DNxHR yuv422 with 10 bit color, fix wide angle lens and pcm wav sound for davinci resolve 16 editing
#!/bin/bash
for f in *.MP4
do
#ffmpeg -i ${f} -c:v dnxhd -vf lenscorrection=k2=0.006:k1=-0.18 -profile:v dnxhr_hqx -pix_fmt yuv422p10le -c:a pcm_s16le ${f}.mov
~/bin/ffmpeg -i ${f} -c:v dnxhd -profile:v dnxhr_hqx -pix_fmt yuv422p10le -vf "lenscorrection=cx=0.5:cy=0.5:k1=-0.227:k2=-0.022" -c:a pcm_s16le ${dest}/${io}.lens_corrected.mov
done
@heavyengineer
heavyengineer / transcode.sh
Created May 19, 2019 22:28
ffmpeg transcode gohero pro 7 footage to something davinci resolve 16 can use
#!/bin/bash
for f in *.MP4
do
ffmpeg -i ${f} -c:v dnxhd -vf "scale=1280:720,fps=30000/1001,format=yuv422p" -b:v 110M -c:a pcm_s16le ${f}.mov
done
@heavyengineer
heavyengineer / gist:989f97de3840bfcc2060515a7e5aee3b
Created May 19, 2019 22:19
ffmpeg transcode gopro hero7 hevc libx264 to something kodi can display
for f in *.MP4
do
ffmpeg -i ${f} -c:v libx264 -crf 28 -c:a aac -b:a 128k ${f}.mp4
done