[FFmpeg-devel] [PATCH 2/2] lavc/libx264: add mb_info option

Carotti, Elias eliascrt at amazon.it
Wed Jul 12 01:01:44 EEST 2023


> +2023-06-21 - xxxxxxxxxx - lavc 60.23.100 - libx264.c
> +  Add mb_info option.

> Do we actually need the option? If the encoder's caller bothered with adding the side data, then I'd think it should always be used, otherwise why is it even there?

 >I agree, I just thought I had to update that file as well, if that's not the case feel free to remove it.
>Best
>Elias

On a second thought, though, I think I misinterpreted your mail and I  wrongly thought you were referring only to the APIchanges file. 

The thing is that libx264 expects a boolean value (b_mb_info) to be set to check the mb_info. 
So, yes, in principle I'd agree with you but I think we still need to tell it in advance by setting the option because the encoder needs to track additional statistics.

>From x264.h:
        int          b_mb_info;            /* Use input mb_info data in x264_picture_t */
and then subsequent uses both in frame.h and analyse.c check for the flag to be set.

Further on, this flag doesn't seem to be updated by the x264_encoder_reconfig(..) method, so the only possibility I see is setting it in advance in the setup phase.
Best
Elias



NICE SRL, viale Monte Grappa 3/5, 20124 Milano, Italia, Registro delle Imprese di Milano Monza Brianza Lodi REA n. 2096882, Capitale Sociale: 10.329,14 EUR i.v., Cod. Fisc. e P.IVA 01133050052, Societa con Socio Unico





More information about the ffmpeg-devel mailing list