Go to the documentation of this file.
19 #ifndef AVCODEC_VULKAN_VIDEO_H
20 #define AVCODEC_VULKAN_VIDEO_H
25 #include <vk_video/vulkan_video_codecs_common.h>
27 #define CODEC_VER_MAJ(ver) (ver >> 22)
28 #define CODEC_VER_MIN(ver) ((ver >> 12) & ((1 << 10) - 1))
29 #define CODEC_VER_PAT(ver) (ver & ((1 << 12) - 1))
30 #define CODEC_VER(ver) CODEC_VER_MAJ(ver), CODEC_VER_MIN(ver), CODEC_VER_PAT(ver)
87 VkImageView *view, VkImageAspectFlags *aspect,
94 FFVkVideoCommon *common,
95 VkVideoSessionCreateInfoKHR *session_create);
AVPixelFormat
Pixel format.
int ff_vk_h265_profile_to_av(StdVideoH264ProfileIdc profile)
VkSamplerYcbcrConversion yuv_sampler
This structure describes decoded (raw) audio or video data.
StdVideoH264LevelIdc ff_vk_h264_level_to_vk(int level_idc)
AVBufferRef * dpb_hwfc_ref
int ff_vk_h265_level_to_av(StdVideoH265LevelIdc level)
StdVideoH265ProfileIdc ff_vk_h265_profile_to_vk(int profile)
StdVideoH265LevelIdc ff_vk_h265_level_to_vk(int level_idc)
StdVideoH264ProfileIdc ff_vk_h264_profile_to_vk(int profile)
Convert profile from/to AV to Vulkan.
VkVideoSessionKHR session
enum AVPixelFormat ff_vk_pix_fmt_from_vkfmt(VkFormat vkf)
Get pixfmt from a Vulkan format.
VkImageAspectFlags ff_vk_aspect_bits_from_vkfmt(VkFormat vkf)
Get aspect bits which include all planes from a VkFormat.
int ff_vk_video_common_init(AVCodecContext *avctx, FFVulkanContext *s, FFVkVideoCommon *common, VkVideoSessionCreateInfoKHR *session_create)
Initialize video session, allocating and binding necessary memory.
VkVideoChromaSubsamplingFlagBitsKHR ff_vk_subsampling_from_av_desc(const AVPixFmtDescriptor *desc)
Get Vulkan's chroma subsampling from a pixfmt descriptor.
int ff_vk_create_view(FFVulkanContext *s, FFVkVideoCommon *common, VkImageView *view, VkImageAspectFlags *aspect, AVVkFrame *src, VkFormat vkf, int is_dpb)
Creates image views for video frames.
int ff_vk_h264_profile_to_av(StdVideoH264ProfileIdc profile)
main external API structure.
VkImageAspectFlags layered_aspect
A reference to a data buffer.
Descriptor that unambiguously describes how the bits of a pixel are stored in the up to 4 data planes...
VkVideoComponentBitDepthFlagBitsKHR ff_vk_depth_from_av_depth(int depth)
Get Vulkan's bit depth from an [8:12] integer.
int ff_vk_h264_level_to_av(StdVideoH264LevelIdc level)
Convert level from Vulkan to AV.
void ff_vk_video_common_uninit(FFVulkanContext *s, FFVkVideoCommon *common)
Free video session and required resources.