mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-10 03:19:40 +00:00
mpeg2: fix decoding of 4K videos.
Account for slice_vertical_position_extension when vertical_size > 2800.
This commit is contained in:
parent
564ca5d221
commit
06725d651e
1 changed files with 3 additions and 2 deletions
|
@ -1127,7 +1127,7 @@ parse_slice(GstVaapiDecoderMpeg2 *decoder,
|
|||
GstMpegVideoSliceHdr *slice_hdr;
|
||||
GstBitReader br;
|
||||
gint mb_x, mb_y, mb_inc;
|
||||
guint8 slice_vertical_position_extension;
|
||||
guint8 slice_vertical_position_extension = 0;
|
||||
guint8 extra_bit_slice, junk8;
|
||||
|
||||
priv->state &= (GST_MPEG_VIDEO_STATE_GOT_SEQ_HDR|
|
||||
|
@ -1164,7 +1164,8 @@ parse_slice(GstVaapiDecoderMpeg2 *decoder,
|
|||
}
|
||||
slice_hdr->header_size = 32 + gst_bit_reader_get_pos(&br);
|
||||
|
||||
mb_y = packet->type - GST_MPEG_VIDEO_PACKET_SLICE_MIN;
|
||||
mb_y = ((guint)slice_vertical_position_extension << 7) +
|
||||
packet->type - GST_MPEG_VIDEO_PACKET_SLICE_MIN;
|
||||
mb_x = -1;
|
||||
do {
|
||||
if (!decode_vlc(&br, &mb_inc, mpeg2_mbaddr_vlc_table,
|
||||
|
|
Loading…
Reference in a new issue