Skip to content

Commit

Permalink
Enable KHR_video_maintenance1 if available.
Browse files Browse the repository at this point in the history
I'm sure FFmpeg likes this one.
  • Loading branch information
Themaister committed Dec 27, 2023
1 parent 7224b24 commit 53cd3a0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
6 changes: 6 additions & 0 deletions vulkan/context.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1362,6 +1362,12 @@ bool Context::create_device(VkPhysicalDevice gpu_, VkSurfaceKHR surface,
ADD_CHAIN(ext.barycentric_features, FRAGMENT_SHADER_BARYCENTRIC_FEATURES_KHR);
}

if (ext.supports_video_queue && has_extension(VK_KHR_VIDEO_MAINTENANCE_1_EXTENSION_NAME))
{
enabled_extensions.push_back(VK_KHR_VIDEO_MAINTENANCE_1_EXTENSION_NAME);
ADD_CHAIN(ext.video_maintenance1_features, VIDEO_MAINTENANCE_1_FEATURES_KHR);
}

if ((flags & CONTEXT_CREATION_ENABLE_ADVANCED_WSI_BIT) != 0 && requires_swapchain)
{
if (has_extension(VK_KHR_PRESENT_ID_EXTENSION_NAME))
Expand Down
1 change: 1 addition & 0 deletions vulkan/context.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ struct DeviceFeatures
VkPhysicalDevicePresentIdFeaturesKHR present_id_features = {};
VkPhysicalDevicePresentWaitFeaturesKHR present_wait_features = {};
VkPhysicalDeviceFragmentShaderBarycentricFeaturesKHR barycentric_features = {};
VkPhysicalDeviceVideoMaintenance1FeaturesKHR video_maintenance1_features = {};

// EXT
VkPhysicalDeviceExternalMemoryHostPropertiesEXT host_memory_properties = {};
Expand Down

0 comments on commit 53cd3a0

Please sign in to comment.