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>
29 #define CODEC_VER_MAJ(ver) (ver >> 22)
30 #define CODEC_VER_MIN(ver) ((ver >> 12) & ((1 << 10) - 1))
31 #define CODEC_VER_PAT(ver) (ver & ((1 << 12) - 1))
32 #define CODEC_VER(ver) CODEC_VER_MAJ(ver), CODEC_VER_MIN(ver), CODEC_VER_PAT(ver)
92 void *create_pNext,
size_t size);
98 FFVkVideoCommon *common,
99 VkVideoSessionCreateInfoKHR *session_create);
AVPixelFormat
Pixel format.
VkVideoCodecOperationFlagBitsKHR encode_op
const FFVkCodecMap ff_vk_codec_map[AV_CODEC_ID_FIRST_AUDIO]
Index is codec_id.
FFVulkanExtensions encode_extension
int ff_vk_h265_level_to_av(StdVideoH265LevelIdc level)
VkVideoCodecOperationFlagBitsKHR decode_op
FFVulkanExtensions decode_extension
int ff_vk_video_get_buffer(FFVulkanContext *ctx, FFVkVideoCommon *s, AVBufferRef **buf, VkBufferUsageFlags usage, void *create_pNext, size_t size)
Get a mapped FFVkPooledBuffer with a specific guaranteed minimum size from a pool.
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(void *log, 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.
@ AV_CODEC_ID_FIRST_AUDIO
A dummy id pointing at the start of audio codecs.
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.