[FFmpeg-cvslog] avcodec/osq: fix 20bit decoding and remove invalid modes
Paul B Mahol
git at videolan.org
Tue Sep 5 01:04:01 EEST 2023
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Tue Sep 5 00:03:18 2023 +0200| [8cb2c6a71ebb85f2715287c7571ac3a157d2989d] | committer: Paul B Mahol
avcodec/osq: fix 20bit decoding and remove invalid modes
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=8cb2c6a71ebb85f2715287c7571ac3a157d2989d
---
libavcodec/osq.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/libavcodec/osq.c b/libavcodec/osq.c
index df9099f20f..e2a84657fb 100644
--- a/libavcodec/osq.c
+++ b/libavcodec/osq.c
@@ -103,9 +103,7 @@ static av_cold int osq_init(AVCodecContext *avctx)
case 8: avctx->sample_fmt = AV_SAMPLE_FMT_U8P; break;
case 16: avctx->sample_fmt = AV_SAMPLE_FMT_S16P; break;
case 20:
- case 24:
- case 28:
- case 32: s->factor = 1 << (32 - avctx->extradata[2]);
+ case 24: s->factor = 256;
avctx->sample_fmt = AV_SAMPLE_FMT_S32P; break;
default: return AVERROR_INVALIDDATA;
}
More information about the ffmpeg-cvslog
mailing list