[FFmpeg-cvslog] avcodec/rv10: Perform RV20 initialization during init
Andreas Rheinhardt
git at videolan.org
Sat Jun 21 23:20:05 EEST 2025
ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Sun May 25 15:40:25 2025 +0200| [f5fc31acecdef68fae669faa96a3ee0914989859] | committer: Andreas Rheinhardt
avcodec/rv10: Perform RV20 initialization during init
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f5fc31acecdef68fae669faa96a3ee0914989859
---
libavcodec/rv10.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/libavcodec/rv10.c b/libavcodec/rv10.c
index 482af8e52a..1aae92a358 100644
--- a/libavcodec/rv10.c
+++ b/libavcodec/rv10.c
@@ -284,7 +284,6 @@ static int rv20_decode_picture_header(RVDecContext *rv, int whole_size)
skip_bits(&s->gb, 5);
s->h263_aic = s->pict_type == AV_PICTURE_TYPE_I;
- s->modified_quant = 1;
if (!s->avctx->lowres)
s->loop_filter = 1;
@@ -370,6 +369,10 @@ static av_cold int rv10_decode_init(AVCodecContext *avctx)
s->h263_long_vectors = avctx->extradata[3] & 1;
rv->sub_id = AV_RB32A(avctx->extradata + 4);
+ if (avctx->codec_id == AV_CODEC_ID_RV20) {
+ s->modified_quant = 1;
+ s->chroma_qscale_table = ff_h263_chroma_qscale_table;
+ }
major_ver = RV_GET_MAJOR_VER(rv->sub_id);
minor_ver = RV_GET_MINOR_VER(rv->sub_id);
@@ -475,9 +478,6 @@ static int rv10_decode_packet(AVCodecContext *avctx, const uint8_t *buf,
s->c_dc_scale_table = ff_mpeg1_dc_scale_table;
}
- if (s->modified_quant)
- s->chroma_qscale_table = ff_h263_chroma_qscale_table;
-
ff_set_qscale(s, s->qscale);
s->rv10_first_dc_coded[0] = 0;
More information about the ffmpeg-cvslog
mailing list