On Sat, Sep 26, 2026 at 6:25 AM Andrew Randrianasulu < randrianasulu@gmail.com> wrote:
So, with this set of patches (+ those 3 by Phyllis) and ffmpeg 9.0.2 edited into configure.ac build compiles BUT I think I am having problems with vaapi encoding.
Confirmed problems with rendering using h264_vaapi.mp4 so I will try to narrow down the problem. Andrew, for the 3 patches for ffmpeg.C, fileffmpeg.C, and fileac3.C did you want me to attempt to add "#ifdep FFMPEG3"? and is that even the correct ifdef (I am not sure what FFMPEG3 stands for ? version 3?). Also, you mentioned that I may have corrupted one of the "if" statements in the patches - I have not found that yet but have not been looking at that specifically yet. Current plan: since vaapi not working, I plan on (1) updating ffmpeg.git.patch# for ffmpeg 9.0.2 based on your patches in previous email (thank you very much for these), (2) checking in the update of bcdisplayinfo.C with the guicast gl-fb... patch as recommended by Andrea, and (3) removing old library versions where a new version was updated. I tested bluray and dvd creation successfully but feel that further testing for the 3 patches in the cinelerra directory (since I only did mechanical conversion). Do not plan on a release this month since FFmpeg 9 is barely tested and at least the vaapi problem found - there could be more. Thanks, Phyllis
bash-5.1$ bin/cin Cinelerra Infinity - built: Sep 26 2026 03:34:11 git://git.cinelerra-gg.org/goodguy/cinelerra.git (c) 2006-2019 Heroine Virtual Ltd. by Adam Williams 2007-2020 mods for Cinelerra-GG by W.P.Morrow aka goodguy 2003-2017 mods for Cinelerra-CV by CinelerraCV team 2015-2026 mods for Cinelerra-GG by Cinelerra-GG team
Libav version: Lavc62.28.100
Cinelerra is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. There is absolutely no warranty for Cinelerra.
BC_DisplayInfo::gl_fb_config failed RenderFarmClient::main_loop: client started [AVHWFramesContext @ 0xafddc0c0] Unsupported format: vaapi. Failed to initialize HW frame context. err: Invalid argument [h264_vaapi @ 0xa7ddaf00] A hardware frames reference is required to associate the encoding device. FFMPEG::open_encoder err: Invalid argument int FFMPEG::open_encoder(const char*, const char*): open failed h264_vaapi:/dev/shm/dnxhd.mkv Render::render_single: Session finished. Render::render_single: Session finished. ** rendered 1 frames in 2.310 secs, 0.433 fps FFMPEG::open_decoder: some stream times estimated: /dev/shm/dnxhd.mkv FFMPEG::open_decoder: some stream times estimated: /dev/shm/dnxhd.mkv FFMPEG::open_decoder: some stream times estimated: /dev/shm/dnxhd.mkv FFMPEG::open_decoder: some stream times estimated: /dev/shm/dnxhd.mkv Total excess of backups: -50 Session time: 0:02:09 Cpu time: user: 0:00:48.828 sys: 0:00:03.530
Hopefully something simple to fix.
On Fri, Sep 25, 2026 at 8:54 AM Andrew Randrianasulu <randrianasulu@gmail.com> wrote:
пт, 25 сент. 2026 г., 04:46 Phyllis Smith <phylsmith2017@gmail.com>:
Andrew, Attached are the "mechanical" patches for ffmpeg 9.0.1 and with these I
have successfully built Cinelerra. I still have not learned how to code in C/C++ so I referenced other user's patches - mechanically like you suggested.
1) Could you verify?
I think I'll add some conditional #ifdefs around so we still can compile cingg with older external ffmpeg ...
I think you accidently removed one conditional if test in ffmpeg patches but need to verify (I only wake up, downloaded patches and looked at them in mcedit on relatively narrow Termux window)
2) fileac3.C, fileffmpeg.C, and ffmpeg.C all compiled without error
with these patches but how do I test?
As always - make sure you set FFMpeg first as probe order, load few a/v files, playback them, single-step them, randomly seek to random points in timeline, add filter or two (ffmpeg and native, audio and/or video), play forward/backward/at random speed/singlestep with filters on, render tracks to few output formats and check those outputs load back into cingg and play/seek correctly in external players.
If verified, I can check them in at ffmpeg 8.1 for early usage. I will update the ffmpeg.git.patch# to reflect 9.0.1 in the next couple of days too. Thanks, Phyllis
I wish you good luck there - I think mpegts muxer in ffmpeg was updated, so one of our biggest patches for bluray muxing may not apply cleanly anymore ..
On Sat, Sep 12, 2026 at 2:55 PM Andrew Randrianasulu <
randrianasulu@gmail.com> wrote:
сб, 12 сент. 2026 г., 22:46 Phyllis Smith <phylsmith2017@gmail.com>:
Oh no. Not sure why they consider this to be an improvement.
Change itself fairly mechanical just it looks like we will need to
apply it to 6-7 places
grep sample_fmts -r cinelerra/*.C
~/cinelerra/cinelerra-5.1 $ grep sample_fmts -r cinelerra/*.C cinelerra/ffmpeg.C: const AVSampleFormat *sample_fmts,
AVSampleFormat src_fmt)
cinelerra/ffmpeg.C: for( int i=0; sample_fmts[i] >= 0; ++i ) { cinelerra/ffmpeg.C: AVSampleFormat sample_fmt = sample_fmts[i]; cinelerra/ffmpeg.C: if( av_codec && av_codec->sample_fmts ) cinelerra/ffmpeg.C: cin_fmt = find_best_sample_fmt_of_list(av_codec->sample_fmts, AV_SAMPLE_FMT_FLT); cinelerra/ffmpeg.C: sample_fmt = codec->sample_fmts ? codec->sample_fmts[0] : AV_SAMPLE_FMT_S16; cinelerra/ffmpeg.C: ret = av_opt_set_bin(buffersink_ctx, "sample_fmts", cinelerra/fileac3.C: codec_context->sample_fmt = codec->sample_fmts[0]; cinelerra/fileffmpeg.C: const AVSampleFormat *sample_fmts = av_codec ? av_codec->sample_fmts : 0; cinelerra/fileffmpeg.C: if( sample_fmts ) { cinelerra/fileffmpeg.C: for( int i=0; sample_fmts[i]>=0; ++i ) { cinelerra/fileffmpeg.C: const char *name = av_get_sample_fmt_name(sample_fmts[i]); cinelerra/pluginfclient.C: ret = av_opt_set_bin(fsink, "sample_fmts",
~/cinelerra/cinelerra-5.1 $ grep pix_fmts -r cinelerra/*.C cinelerra/ffmpeg.C:static AVPixelFormat get_hw_##fn(AVCodecContext *ctx, const enum AVPixelFormat *pix_fmts) { \ cinelerra/ffmpeg.C: const enum AVPixelFormat *pix_fmts) cinelerra/ffmpeg.C: for( const enum AVPixelFormat *p=pix_fmts; *p!=AV_PIX_FMT_NONE; ++p ) { cinelerra/ffmpeg.C: if( av_codec && av_codec->pix_fmts ) { cinelerra/ffmpeg.C: cin_fmt = avcodec_find_best_pix_fmt_of_list(av_codec->pix_fmts, cinelerra/ffmpeg.C: cin_fmt = av_codec->pix_fmts[0]; cinelerra/ffmpeg.C: pix_fmt = codec->pix_fmts ? codec->pix_fmts[0] : AV_PIX_FMT_YUV420P; cinelerra/ffmpeg.C: ret = av_opt_set_bin(buffersink_ctx, "pix_fmts", cinelerra/fileffmpeg.C: const AVPixelFormat *pix_fmts = av_codec ? av_codec->pix_fmts : 0; cinelerra/fileffmpeg.C: if( pix_fmts ) { cinelerra/fileffmpeg.C: for( int i=0; pix_fmts[i]>=0; ++i ) { cinelerra/fileffmpeg.C: const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(pix_fmts[i]); cinelerra/pluginfclient.C: ret = av_opt_set_bin(fsink, "pix_fmts", ~/cinelerra/cinelerra-5.1 $
Patch for mplayer was already in Arch:
https://gitlab.archlinux.org/archlinux/packaging/packages/mplayer/-/blob/mai...
On Sat, Sep 12, 2026, 13:34 Andrew Randrianasulu <
randrianasulu@gmail.com> wrote:
https://github.com/mltframework/mlt/pull/1281/changes/68bceba12a3c3278ce6903...
of course ffmpeg devs invented yet another way to get supported
sample/pixel formats out of codec internals ....
Will try to make mplayer work first, then may be cinelerra.