diff mbox series

[FFmpeg-devel,41/57] avcodec/mpeg4videodec: Inline constants

Message ID GV1P250MB073717D3584894AA1DC717308FC02@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM
State New
Headers show
Series [FFmpeg-devel,01/57] avcodec/vc1: Combine identical checks | expand

Commit Message

Andreas Rheinhardt June 12, 2024, 1:48 p.m. UTC
Partitioned macroblocks are always 8bit and not studio profile.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/mpeg4videodec.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

Comments

Michael Niedermayer June 13, 2024, 7:16 a.m. UTC | #1
On Wed, Jun 12, 2024 at 03:48:37PM +0200, Andreas Rheinhardt wrote:
> Partitioned macroblocks are always 8bit and not studio profile.

This is not true

Table 9-1 -- Tools for Version 1 Visual Object Types

data partitioning allows N-Bit object Type, theres a "x" there
Thing is we dont fully support N-bit so it may look like that but
studio profile != N-bit

some other of your patches also look like they remove N-bit related code

[...]

thx
diff mbox series

Patch

diff --git a/libavcodec/mpeg4videodec.c b/libavcodec/mpeg4videodec.c
index 116dc1507e..f1b542cebf 100644
--- a/libavcodec/mpeg4videodec.c
+++ b/libavcodec/mpeg4videodec.c
@@ -949,8 +949,7 @@  static int mpeg4_decode_partition_a(Mpeg4DecContext *ctx)
             int dir = 0;
 
             mb_num++;
-            ff_update_block_index(s, s->avctx->bits_per_raw_sample,
-                                  s->avctx->lowres, s->chroma_x_shift);
+            ff_update_block_index(s, 8, s->avctx->lowres, 1);
             if (s->mb_x == s->resync_mb_x && s->mb_y == s->resync_mb_y + 1)
                 s->first_slice_line = 0;
 
@@ -1141,8 +1140,7 @@  static int mpeg4_decode_partition_b(MpegEncContext *s, int mb_count)
             const int xy = s->mb_x + s->mb_y * s->mb_stride;
 
             mb_num++;
-            ff_update_block_index(s, s->avctx->bits_per_raw_sample,
-                                  s->avctx->lowres, s->chroma_x_shift);
+            ff_update_block_index(s, 8, s->avctx->lowres, 1);
             if (s->mb_x == s->resync_mb_x && s->mb_y == s->resync_mb_y + 1)
                 s->first_slice_line = 0;