diff mbox series

[FFmpeg-devel,7/8] avcodec/av1dec: call ff_cbs_flush() on decoder flush

Message ID 20200925144318.6194-7-jamrial@gmail.com
State Accepted
Commit aa5e49e46d3aa22cc805c85a982afac1405aede5
Headers show
Series [FFmpeg-devel,1/8] avcodec/cbs: add a flush callback to CodedBitstreamType | expand

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

James Almer Sept. 25, 2020, 2:43 p.m. UTC
Signed-off-by: James Almer <jamrial@gmail.com>
---
 libavcodec/av1dec.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Mark Thompson Sept. 29, 2020, 3:58 p.m. UTC | #1
On 25/09/2020 15:43, James Almer wrote:
> Signed-off-by: James Almer <jamrial@gmail.com>
> ---
>   libavcodec/av1dec.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/libavcodec/av1dec.c b/libavcodec/av1dec.c
> index a30a496b4c..07026b7aeb 100644
> --- a/libavcodec/av1dec.c
> +++ b/libavcodec/av1dec.c
> @@ -854,6 +854,8 @@ static void av1_decode_flush(AVCodecContext *avctx)
>       av1_frame_unref(avctx, &s->cur_frame);
>       s->raw_frame_header = NULL;
>       s->raw_seq = NULL;
> +
> +    ff_cbs_flush(s->cbc);
>   }
>   
>   AVCodec ff_av1_decoder = {
> 

Patches 6 and 7 LGTM.

Thanks,

- Mark
James Almer Sept. 30, 2020, 1:26 a.m. UTC | #2
On 9/29/2020 12:58 PM, Mark Thompson wrote:
> On 25/09/2020 15:43, James Almer wrote:
>> Signed-off-by: James Almer <jamrial@gmail.com>
>> ---
>>   libavcodec/av1dec.c | 2 ++
>>   1 file changed, 2 insertions(+)
>>
>> diff --git a/libavcodec/av1dec.c b/libavcodec/av1dec.c
>> index a30a496b4c..07026b7aeb 100644
>> --- a/libavcodec/av1dec.c
>> +++ b/libavcodec/av1dec.c
>> @@ -854,6 +854,8 @@ static void av1_decode_flush(AVCodecContext *avctx)
>>       av1_frame_unref(avctx, &s->cur_frame);
>>       s->raw_frame_header = NULL;
>>       s->raw_seq = NULL;
>> +
>> +    ff_cbs_flush(s->cbc);
>>   }
>>     AVCodec ff_av1_decoder = {
>>
> 
> Patches 6 and 7 LGTM.
> 
> Thanks,
> 
> - Mark

Both patches pushed.
diff mbox series

Patch

diff --git a/libavcodec/av1dec.c b/libavcodec/av1dec.c
index a30a496b4c..07026b7aeb 100644
--- a/libavcodec/av1dec.c
+++ b/libavcodec/av1dec.c
@@ -854,6 +854,8 @@  static void av1_decode_flush(AVCodecContext *avctx)
     av1_frame_unref(avctx, &s->cur_frame);
     s->raw_frame_header = NULL;
     s->raw_seq = NULL;
+
+    ff_cbs_flush(s->cbc);
 }
 
 AVCodec ff_av1_decoder = {