Go to the documentation of this file.
19 #ifndef AVCODEC_VULKAN_DECODE_H
20 #define AVCODEC_VULKAN_DECODE_H
41 VkVideoDecodeUsageInfoKHR
usage;
53 VkVideoCapabilitiesKHR
caps;
93 VkVideoPictureResourceInfoKHR
ref;
97 VkVideoPictureResourceInfoKHR
refs [36];
147 const uint8_t *
data,
size_t size,
int add_startcode,
148 uint32_t *nb_slices,
const uint32_t **
offsets);
166 void *create_pNext,
size_t size);
172 const VkVideoSessionParametersCreateInfoKHR *session_params_create);
VkVideoProfileInfoKHR profile
VkVideoDecodeH265ProfileInfoKHR h265_profile
uint64_t FFVulkanExtensions
FFVulkanDecodeShared * shared_ctx
int ff_vk_decode_uninit(AVCodecContext *avctx)
Free decoder.
This structure describes decoded (raw) audio or video data.
uint32_t frame_id_alloc_mask
int ff_vk_get_decode_buffer(FFVulkanDecodeContext *ctx, AVBufferRef **buf, void *create_pNext, size_t size)
Get an FFVkBuffer suitable for decoding from.
VkVideoDecodeAV1ProfileInfoKHR av1_profile
int ff_vk_decode_add_slice(AVCodecContext *avctx, FFVulkanDecodePicture *vp, const uint8_t *data, size_t size, int add_startcode, uint32_t *nb_slices, const uint32_t **offsets)
Add slice data to frame.
VkVideoPictureResourceInfoKHR ref
AVBufferRef * session_params
int ff_vk_decode_create_params(AVBufferRef **par_ref, void *logctx, FFVulkanDecodeShared *ctx, const VkVideoSessionParametersCreateInfoKHR *session_params_create)
Create VkVideoSessionParametersKHR wrapped in an AVBufferRef.
VkVideoCodecOperationFlagBitsKHR decode_op
This struct aggregates all the (hardware/vendor-specific) "high-level" state, i.e.
VkVideoDecodeH264ProfileInfoKHR h264_profile
VkVideoPictureResourceInfoKHR refs[36]
VkVideoProfileListInfoKHR profile_list
PFN_vkWaitSemaphores wait_semaphores
static const int offsets[]
int ff_vk_params_invalidate(AVCodecContext *avctx, int t, const uint8_t *b, uint32_t s)
Removes current session parameters to recreate them.
int ff_vk_update_thread_context(AVCodecContext *dst, const AVCodecContext *src)
Synchronize the contexts between 2 threads.
VkVideoDecodeUsageInfoKHR usage
FFVulkanExtensions decode_extension
void ff_vk_decode_free_frame(AVHWDeviceContext *dev_ctx, FFVulkanDecodePicture *vp)
Free a frame and its state.
int ff_vk_decode_frame(AVCodecContext *avctx, AVFrame *pic, FFVulkanDecodePicture *vp, AVFrame *rpic[], FFVulkanDecodePicture *rvkp[])
Decode a frame.
AVCodecID
Identify the syntax and semantics of the bitstream.
uint8_t ptrdiff_t const uint8_t ptrdiff_t int intptr_t intptr_t int int16_t * dst
VkVideoCapabilitiesKHR caps
VkImageAspectFlags img_aspect_ref
VkVideoSessionParametersKHR empty_session_params
unsigned int slice_off_max
int ff_vk_frame_params(AVCodecContext *avctx, AVBufferRef *hw_frames_ctx)
Initialize hw_frames_ctx with the parameters needed to decode the stream using the parameters from av...
VkExtensionProperties ext_props
VkVideoReferenceSlotInfoKHR ref_slot
VkVideoReferenceSlotInfoKHR ref_slots[36]
struct HEVCHeaderSet * hevc_headers
int ff_vk_decode_prepare_frame(FFVulkanDecodeContext *dec, AVFrame *pic, FFVulkanDecodePicture *vkpic, int is_current, int alloc_dpb)
Prepare a frame, creates the image view, and sets up the dpb fields.
main external API structure.
A reference to a data buffer.
int ff_vk_decode_init(AVCodecContext *avctx)
Initialize decoder.
void ff_vk_decode_flush(AVCodecContext *avctx)
Flush decoder.
VkImageView img_view_dest
PFN_vkDestroyImageView destroy_image_view
VkVideoDecodeInfoKHR decode_info
VkImageAspectFlags img_aspect
VkVideoDecodeCapabilitiesKHR dec_caps