[FFmpeg-devel] [PATCH v2] avcodec/av1dec: convert to receive_frame()

James Almer jamrial at gmail.com
Sat May 20 19:44:30 EEST 2023


On 5/20/2023 1:12 PM, Anton Khirnov wrote:
> Quoting James Almer (2023-05-20 03:50:57)
>> Signed-off-by: James Almer <jamrial at gmail.com>
>> ---
>>   libavcodec/av1dec.c | 75 +++++++++++++++++++++++++++++++++------------
>>   libavcodec/av1dec.h |  4 +++
>>   2 files changed, 60 insertions(+), 19 deletions(-)
> 
> The patch makes the code longer and introduces an evil backward goto.
> So some comment on why is this an improvement would be appropriate.

It's an improvement because it removes the auto-inserted av1_frame_split 
from the process, making the decoder handle temporal units with more 
than one frame in them on its own. I can add that to the commit message.

The extra code is inevitable because it's the decoder who now needs to 
fetch the packet instead of the generic code in decode.c


More information about the ffmpeg-devel mailing list