Ángel Ortega

@angel@triptico.com

ex-writer, ex-programmer, ex-musician, ex-illustrator
ex-escritor, ex-programador, ex-músico, ex-dibujante
40.4231709,-3.6612241
https://triptico.com
1 ★ 2 ↺

Ángel Ortega »

TIL that most video processing tools accept as a valid input stream a set of concatenated PPM [1] files, so you can generate video from your own programs easily. You just have to pipe your program's output to the appropriate tools (indicating the FPS) like

./fancy-prg | mpv --no-correct-pts --fps=$FPS -
or
./fancy-prg | ffmpeg -i - -r $FPS video.mp4
[1] https://en.wikipedia.org/wiki/Netpbm_format

History