diff options
author | Anton Khirnov <anton@khirnov.net> | 2024-06-01 18:38:57 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2024-06-11 17:39:35 +0200 |
commit | 3115c84015d8cc86262844d9a2435d2c5423de0e (patch) | |
tree | 37f397308d9f06524e2229a3a604dd73b2ee7fd3 /libavcodec | |
parent | 381b70e173f9d55a05ef7174f1a3709951dc3ba3 (diff) | |
download | ffmpeg-3115c84015d8cc86262844d9a2435d2c5423de0e.tar.gz |
lavc/hevcdec: only set no_rasl_output_flag for IRAP frames
Its meaning is only specified for IRAP frames.
As it's currently never used otherwise, this should not change decoder
behaviour, but will be useful in future commits.
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/hevc/hevcdec.c | 4 | ||||
-rw-r--r-- | libavcodec/hevc/hevcdec.h | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/libavcodec/hevc/hevcdec.c b/libavcodec/hevc/hevcdec.c index 585a066426..d444ea93f7 100644 --- a/libavcodec/hevc/hevcdec.c +++ b/libavcodec/hevc/hevcdec.c @@ -2925,7 +2925,9 @@ static int hevc_frame_start(HEVCContext *s) s->is_decoded = 0; s->first_nal_type = s->nal_unit_type; - s->no_rasl_output_flag = IS_IDR(s) || IS_BLA(s) || (s->nal_unit_type == HEVC_NAL_CRA_NUT && s->last_eos); + if (IS_IRAP(s)) + s->no_rasl_output_flag = IS_IDR(s) || IS_BLA(s) || + (s->nal_unit_type == HEVC_NAL_CRA_NUT && s->last_eos); /* 8.3.1 */ if (s->temporal_id == 0 && diff --git a/libavcodec/hevc/hevcdec.h b/libavcodec/hevc/hevcdec.h index 5eaebd3584..fa7caf9cf7 100644 --- a/libavcodec/hevc/hevcdec.h +++ b/libavcodec/hevc/hevcdec.h @@ -493,6 +493,7 @@ typedef struct HEVCContext { int overlap; int is_decoded; + // NoRaslOutputFlag associated with the last IRAP frame int no_rasl_output_flag; HEVCPredContext hpc; |