]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/dxva2_h264.c
parser: Move Doxygen documentation to the header files
[ffmpeg] / libavcodec / dxva2_h264.c
index 9608ecb8e68f586ef1b69d4f50fdc6e08a2c3f65..2fd0767f8990c71e9ca078a309e29f58fc1c9751 100644 (file)
@@ -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->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) |
                                         /* sp_for_switch_flag (not implemented by Libav) */
                                         (0                                    <<  3) |
@@ -441,11 +442,10 @@ static int end_frame(AVCodecContext *avctx)
 AVHWAccel ff_h264_dxva2_hwaccel = {
     .name           = "h264_dxva2",
     .type           = AVMEDIA_TYPE_VIDEO,
-    .id             = CODEC_ID_H264,
-    .pix_fmt        = PIX_FMT_DXVA2_VLD,
+    .id             = AV_CODEC_ID_H264,
+    .pix_fmt        = AV_PIX_FMT_DXVA2_VLD,
     .start_frame    = start_frame,
     .decode_slice   = decode_slice,
     .end_frame      = end_frame,
     .priv_data_size = sizeof(struct dxva2_picture_context),
 };
-