[FFmpeg-devel] [PATCH 10/12] avcodec/rv10: Replace switch by LUT
Andreas Rheinhardt
andreas.rheinhardt at outlook.com
Fri Oct 6 05:03:40 EEST 2023
Vittorio Giovara:
> On Tue, Oct 3, 2023 at 12:03 PM Andreas Rheinhardt <
> andreas.rheinhardt at outlook.com> wrote:
>
>> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
>> ---
>> libavcodec/rv10.c | 21 +++++----------------
>> 1 file changed, 5 insertions(+), 16 deletions(-)
>>
>> diff --git a/libavcodec/rv10.c b/libavcodec/rv10.c
>> index 3f9d5ff242..216328ffe7 100644
>> --- a/libavcodec/rv10.c
>> +++ b/libavcodec/rv10.c
>> @@ -158,25 +158,14 @@ static int rv10_decode_picture_header(MpegEncContext
>> *s)
>>
>> static int rv20_decode_picture_header(RVDecContext *rv, int whole_size)
>> {
>> + static const enum AVPictureType pict_types[] =
>> + { AV_PICTURE_TYPE_I, AV_PICTURE_TYPE_I /* hmm ... */,
>>
>
> Any chance we could replace this comment with something more detailed (or
> remove it if not needed)?
The comment has been added when the mapping for 1 was added in
248a1aa54c0 (which made the default case dead code). I simply preserved
it, Michael probably added it to show that he was not completely sure. I
don't know whether there are different semantics for the two values.
I do not object to the removal of this comment.
- Andreas
More information about the ffmpeg-devel
mailing list