I am trying to produce video from raw RGB frames, but result video does not open with MediaPlayer: [mov,mp4,m4a,3gp,3g2,mj2 @ 0x195493108c0] moov atom not found error is displayed. What I am doing wrong? Also does Media Kit supports modern codec encoders like H264 of VP8/9?
MediaKit doesn’t care which video format you use, that’s the job of the ffmpeg add-on which should support mostly everything you expect from ffmpeg. However I think the encoding side is quite broken currently.
The ffmpeg addon is currently broken for anything except h264 mp4 with aac, as can be verified by MediaConvertor. For my video editor, I have 2 code paths, MediaKit and direct Ffmpeg, and default to ffmpeg code path since it works (with uglier C code). Its only one function about 50-60 lines of code to interface with. When I finish up with my editor and open source it, I’ll have a crack at porting the code to MediaKit to fix that code path as well.
It produce extremely low framerate for me and do not supports modern formats (mp4, webm). I already managed to build ffmpeg with x264 and make multithreaded screen capture that produce reasonable framerate. Currently I don’t know how to synchronize time in video.
Anyway, jackburton is still around and will accept feature requests and certainly code changes, so why not submit them there? BeScreenCapture uses the Media Kit, so adding WebM should just be exposing it in the UI…
It is probably a 2-line change to add a H.264 profile to the Media Kit FFmpeg plugin encoders whitelist. Why not add that, rather than taking all the time to write something else?
I haven’t looked in Media Kit ffmpeg plugin yet. Zenja says that “The ffmpeg addon is currently broken for anything except h264 mp4 with aac, as can be verified by MediaConvertor”.
I managed to get 1920x1080 25 FPS screen capture with libx264 and 4 threads enabled. Interface became slow during screen capture because of reading frontbuffer. Additional app_server screen buffer is needed to speed up screen capture.
I am using ffmpeg with libx264 enabled, but there are license issues with libx264: https://github.com/haikuports/haikuports/issues/4919. It seems incompatible with MIT license and software using it is infected by GPL. Other video encoders are no such fast as libx264 that is important for software encoding.
Maybe Haiku can get a temporarily license until R1?!
Or a special contract?
See: In addition to being free to use under the GNU GPL, x264 is also available under a commercial license. Contact x264licensing@videolan.org for more details.
It’s also worth noting that H.264 is still patented, and MPEG LA has been known to go after open-source projects in the past that supported encoding it. There was a news article somewhere about this…