diff --git a/src/vulkan/runtime/vk_video.c b/src/vulkan/runtime/vk_video.c index 46b60a4e0cc..7c6c137787a 100644 --- a/src/vulkan/runtime/vk_video.c +++ b/src/vulkan/runtime/vk_video.c @@ -43,6 +43,8 @@ vk_video_session_init(struct vk_device *device, vid->ref_format = create_info->referencePictureFormat; vid->max_dpb_slots = create_info->maxDpbSlots; vid->max_active_ref_pics = create_info->maxActiveReferencePictures; + vid->luma_bit_depth = create_info->pVideoProfile->lumaBitDepth; + vid->chroma_bit_depth = create_info->pVideoProfile->chromaBitDepth; switch (vid->op) { case VK_VIDEO_CODEC_OPERATION_DECODE_H264_BIT_KHR: { @@ -452,6 +454,8 @@ vk_video_session_parameters_init(struct vk_device *device, vk_object_base_init(device, ¶ms->base, VK_OBJECT_TYPE_VIDEO_SESSION_PARAMETERS_KHR); params->op = vid->op; + params->luma_bit_depth = vid->luma_bit_depth; + params->chroma_bit_depth = vid->chroma_bit_depth; switch (vid->op) { case VK_VIDEO_CODEC_OPERATION_DECODE_H264_BIT_KHR: { diff --git a/src/vulkan/runtime/vk_video.h b/src/vulkan/runtime/vk_video.h index 77667997cb5..6338d2c3282 100644 --- a/src/vulkan/runtime/vk_video.h +++ b/src/vulkan/runtime/vk_video.h @@ -81,6 +81,8 @@ struct vk_video_session { struct vk_object_base base; VkVideoSessionCreateFlagsKHR flags; VkVideoCodecOperationFlagsKHR op; + VkVideoComponentBitDepthFlagsKHR luma_bit_depth; + VkVideoComponentBitDepthFlagsKHR chroma_bit_depth; VkExtent2D max_coded; VkFormat picture_format; VkFormat ref_format; @@ -112,6 +114,8 @@ struct vk_video_session { struct vk_video_session_parameters { struct vk_object_base base; VkVideoCodecOperationFlagsKHR op; + VkVideoComponentBitDepthFlagsKHR luma_bit_depth; + VkVideoComponentBitDepthFlagsKHR chroma_bit_depth; union { struct { uint32_t max_h264_sps_count;