h264: Adjust for the latest h264 API changes

Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com>
This commit is contained in:
Maxime Ripard
2018-07-13 16:10:21 +02:00
parent 22b51f5ced
commit 6194f1e7da
+3 -3
View File
@@ -204,7 +204,7 @@ static void h264_va_slice_to_v4l2(struct sunxi_cedrus_driver_data *driver_data,
} }
if (VASlice->direct_spatial_mv_pred_flag) if (VASlice->direct_spatial_mv_pred_flag)
slice->flags |= V4L2_SLICE_FLAG_DIRECT_SPATIAL_MV_PRED; slice->flags |= V4L2_H264_SLICE_FLAG_DIRECT_SPATIAL_MV_PRED;
slice->pred_weight_table.chroma_log2_weight_denom = slice->pred_weight_table.chroma_log2_weight_denom =
VASlice->chroma_log2_weight_denom; VASlice->chroma_log2_weight_denom;
@@ -249,13 +249,13 @@ int h264_set_controls(struct sunxi_cedrus_driver_data *driver_data,
&surface_object->params.h264.picture, &slice); &surface_object->params.h264.picture, &slice);
rc = v4l2_set_control(driver_data->video_fd, surface_object->request_fd, rc = v4l2_set_control(driver_data->video_fd, surface_object->request_fd,
V4L2_CID_MPEG_VIDEO_H264_DECODE_PARAM, V4L2_CID_MPEG_VIDEO_H264_DECODE_PARAMS,
&decode, sizeof(decode)); &decode, sizeof(decode));
if (rc < 0) if (rc < 0)
return VA_STATUS_ERROR_OPERATION_FAILED; return VA_STATUS_ERROR_OPERATION_FAILED;
rc = v4l2_set_control(driver_data->video_fd, surface_object->request_fd, rc = v4l2_set_control(driver_data->video_fd, surface_object->request_fd,
V4L2_CID_MPEG_VIDEO_H264_SLICE_PARAM, V4L2_CID_MPEG_VIDEO_H264_SLICE_PARAMS,
&slice, sizeof(slice)); &slice, sizeof(slice));
if (rc < 0) if (rc < 0)
return VA_STATUS_ERROR_OPERATION_FAILED; return VA_STATUS_ERROR_OPERATION_FAILED;