[x264-devel] unnecessary code or bug in x264_slicetype_analyse?

chen chenm003 at 163.com
Wed Nov 17 07:14:33 UTC 2021


Hi Jack,




Got it, thank you very much.

I forgot the array is pointer that copy from h->lookahead->next.list




Regards,
Min Chen

2021-11-17 14:56:51,"Jack Waller" <ffmpeg at gmail.com> 

Because it is a pointer array.


-----------------------------------------
Productive. Reliable. Fast.




On Wed, Nov 17, 2021 at 2:37 PM chen <chenm003 at 163.com> wrote:

Hello,


I found there some funny code in the function x264_slicetype_analyse.
For example,


...
    else if( num_frames == 0 )
    {
        frames[1]->i_type = X264_TYPE_I;
        return;
    }
...
    /* Restore frametypes for all frames that haven't actually been decided yet. */
    for( int j = reset_start; j <= num_frames; j++ )
        frames[j]->i_type = frames[j]->i_forced_type;
...


In here, the frames[] is temporary Stack allocated array variant, why we setting it's value before return?


Regards,
Min Chen


_______________________________________________
x264-devel mailing list
x264-devel at videolan.org
https://mailman.videolan.org/listinfo/x264-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/x264-devel/attachments/20211117/f6cc59f3/attachment.html>


More information about the x264-devel mailing list