Skip to content

Instantly share code, notes, and snippets.

@on-three
on-three / gist:11035094
Created April 18, 2014 09:53
Downloading video off NHK Educational site. File parameters drawn out of wireshark logs.
rtmpdump -r "rtmp://flv9.nhk.or.jp:1935/flv9/_definst_/mp4:das/D0005110/D0005110302_00000_V_000.f4v" -o nhk.flv
Note that closed captions for this can be snatched from local browser cached files as .ttml files. Format of the .ttml files reminds me of Arib closed caption format.
@on-three
on-three / gist:11358874
Created April 28, 2014 00:23
convert an image to an N second webm
avconv -loop 1 -i stannis_behead.jpg -t 00:00:07 -c:v libvpx test.webm
@on-three
on-three / gist:04def3c93156671bbdd8
Created June 18, 2014 16:23
VLC Settings for transcoding relay
:sout=#transcode{vcodec=h264,venc=x264{crf=18,keyint=250,vbv-maxrate=1700,vbvbufsize=3400,preset=medium,threads=auto},vfilter=croppadd{croptop=36,cropbottom=36,cropleft=64,cropright=64},width=1280,height=720,acodec=mpga,ab=128,channels=2,samplerate=48000}
@on-three
on-three / gist:3c9186774b1467b7cdb5
Created June 28, 2014 06:58
Tentative Jojo's Bizarre Adventure: Stardust Crusaders schedule
Anonymous Fri 27 Jun 2014 10:39:26 No.109445289
Daily reminder
Episode 6 (5/9) Dark Blue Moon [Correct]
Episode 7(5/16): Strength [Correct]
Episode 8 (5/23): Ebony Devil [Correct]
Episode 9 (5/30): Yellow Temperance [Correct]
Episode 10 (6/6): The Emperor and the Hanged Man Part 1 [Correct]
Episode 11 (6/13): The Emperor and the Hanged Man Part 2 [Correct]
@on-three
on-three / gist:1c3fe6977153a87c2877
Last active August 29, 2015 14:05
convert images and rename in files
cp -r dir1 dir1_copy
#find ./dir1_copy -type f -iname "*.jpg" -exec sh -c "echo {}; mogrify -format png {}; rm {}" \;
find ./dir1_copy -type f -name "*.jpg" -exec sh -c 'echo $1; convert "$1" "${1%.jpg}.png"; rm $1' _ {} \;
find ./dir1_copy -type f -iname "*.txt" -exec sh -c "echo {}; sed -i 's/\.jpg\"/\.png\"/g' {}" \;
@on-three
on-three / gist:3f58a6691a40186d2dba
Last active August 29, 2015 14:05
VLC Streaming Commands
vlc -I dummy -vvv video.mp4 --sout '#transcode{vcodec=h264,vb=0,scale=0,acodec=mpga,ab=128,channels=2,samplerate=44100}:http{mux=ffmpeg{mux=flv},dst=:8080/}'
#?tv?shows_20131102.log:[13:10:18] <GEEGEEGEE> vlc.exe -vvv http://192.168.0.12:2345 :sout=#transcode{vcodec=h264,vb=1900,scale=0,acodec=mp3,ab=128,channels=2,samplerate=44100,scodec=dvbs,soverlay,deinterlace=0}:http{caching=5000,mux=ts,dst=:55555/} :sout-keep
#?tv?shows_20130210.log:[09:26:15] <donnyst> "c:\Program Files (x86)\VideoLAN\VLC\vlc.exe" "D:\music\lol.mp4" -sout=#transcode{vcodec=theo,vb=800,scale=1,acodec=vorb,ab=128,channels=2,samplerate=44100}: std{access=shout,mux=ogg,dst=myusername:mypassword@myicecastserver.domain.com:port/test.mp4}
#?tv?shows_20140218.log:[08:22:08] <Anonymousey> su -l -c "cvlc -I dummy http://xxx:fricheE5@25.102.90.94:9981/stream/channel/f57902659468c58056c90502e453f119 --repeat http://xxx:fricheE5@25.102.90.94:9981/stream/channel/f57902659468c58056c90502e453f119 --sout='#transcode{venc=x264{keyint=60,profile=base
@on-three
on-three / gist:bef78cfe147da417f65a
Created August 25, 2014 23:10
XCode Conditional Breakpoint on String
(BOOL)[[VARIABLENAME] isEqualToString:@"STRINGVALUE"]
@on-three
on-three / gist:5dd96da94c2dd1c57cb9
Created August 30, 2014 17:33
Create h264/mp3 .ts from static image of N seconds
avconv -loop 1 -i 720_test_pattern.png -c:v libx264 -c:a libmp3lame -t 300 720test.ts
@on-three
on-three / gist:feefb0f137b132aa163e
Created September 2, 2014 08:00
Video Capture setup
#?tv?shows_20140523.log:[22:02:49] <swam> qb: cablecard > external usb infinitv4 > wmc > hdfury3 > avermediahd internal pmcia capture card > vlc
@on-three
on-three / icecast.xml
Created September 6, 2014 22:24
Basic icecast config used for weeabot
<icecast>
<limits>
<clients>500</clients>
<sources>10</sources>
<threadpool>10</threadpool>
<queue-size>10000000</queue-size>
<client-timeout>30</client-timeout>
<header-timeout>15</header-timeout>
<source-timeout>30</source-timeout>
<burst-on-connect>1</burst-on-connect>