Commit b5e6aa6c authored by Hendrik Leppkes's avatar Hendrik Leppkes Committed by Michael Niedermayer

dxva2_h264: fix signaling of mbaff frames

The MBAFF flag may only be signaled if we're actually dealing with
a full frame, and not singular fields, as it can happen in mixed content.
Reviewed-by: 's avatarDerek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 1c600888
...@@ -93,7 +93,8 @@ static void fill_picture_parameters(struct dxva_context *ctx, const H264Context ...@@ -93,7 +93,8 @@ static void fill_picture_parameters(struct dxva_context *ctx, const H264Context
pp->num_ref_frames = h->sps.ref_frame_count; pp->num_ref_frames = h->sps.ref_frame_count;
pp->wBitFields = ((s->picture_structure != PICT_FRAME) << 0) | pp->wBitFields = ((s->picture_structure != PICT_FRAME) << 0) |
(h->sps.mb_aff << 1) | ((h->sps.mb_aff &&
(s->picture_structure == PICT_FRAME)) << 1) |
(h->sps.residual_color_transform_flag << 2) | (h->sps.residual_color_transform_flag << 2) |
/* sp_for_switch_flag (not implemented by FFmpeg) */ /* sp_for_switch_flag (not implemented by FFmpeg) */
(0 << 3) | (0 << 3) |
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment