FFmpeg
|
#include "codec_id.h"
#include "internal.h"
#include "encode.h"
#include "hwconfig.h"
#include "vulkan_video.h"
#include "hw_base_encode.h"
Go to the source code of this file.
Data Structures | |
struct | FFVulkanEncodeDescriptor |
struct | FFVulkanEncodePicture |
struct | FFVulkanCodec |
struct | FFVkEncodeCommonOptions |
struct | FFVulkanEncodeContext |
Macros | |
#define | VK_ENC_FLAG_NO_DELAY 1 << 6 |
#define | FF_VK_RC_MODE_AUTO 0xFFFFFFFF |
#define | VULKAN_ENCODE_COMMON_OPTIONS |
Typedefs | |
typedef int(* | vkenc_cb_write_stream_headers) (AVCodecContext *avctx, uint8_t *data, size_t *data_len) |
Callback for writing stream-level headers. More... | |
typedef int(* | vkenc_cb_init_pic_headers) (AVCodecContext *avctx, FFVulkanEncodePicture *pic) |
Callback for initializing codec-specific picture headers. More... | |
typedef int(* | vkenc_cb_write_filler) (AVCodecContext *avctx, uint32_t filler, uint8_t *data, size_t *data_len) |
Callback for writing alignment data. More... | |
typedef int(* | vkenc_cb_write_extra_headers) (AVCodecContext *avctx, FFVulkanEncodePicture *pic, uint8_t *data, size_t *data_len) |
Callback for writing any extra units requested. More... | |
Functions | |
av_cold int | ff_vulkan_encode_init (AVCodecContext *avctx, FFVulkanEncodeContext *ctx, const FFVulkanEncodeDescriptor *vk_desc, const FFVulkanCodec *codec, void *codec_caps, void *quality_pnext) |
Initialize encoder. More... | |
av_cold int | ff_vulkan_write_global_header (AVCodecContext *avctx, FFVulkanEncodeContext *ctx) |
Write out the extradata in case its needed. More... | |
int | ff_vulkan_encode_receive_packet (AVCodecContext *avctx, AVPacket *pkt) |
Encode. More... | |
void | ff_vulkan_encode_uninit (FFVulkanEncodeContext *ctx) |
Uninitialize encoder. More... | |
int | ff_vulkan_encode_create_session_params (AVCodecContext *avctx, FFVulkanEncodeContext *ctx, void *codec_params_pnext) |
Create session parameters. More... | |
Variables | |
const AVCodecHWConfigInternal *const | ff_vulkan_encode_hw_configs [] |
Paperwork. More... | |
#define VK_ENC_FLAG_NO_DELAY 1 << 6 |
Definition at line 97 of file vulkan_encode.h.
#define FF_VK_RC_MODE_AUTO 0xFFFFFFFF |
Definition at line 162 of file vulkan_encode.h.
#define VULKAN_ENCODE_COMMON_OPTIONS |
Definition at line 197 of file vulkan_encode.h.
typedef int(* vkenc_cb_write_stream_headers) (AVCodecContext *avctx, uint8_t *data, size_t *data_len) |
Callback for writing stream-level headers.
Definition at line 65 of file vulkan_encode.h.
typedef int(* vkenc_cb_init_pic_headers) (AVCodecContext *avctx, FFVulkanEncodePicture *pic) |
Callback for initializing codec-specific picture headers.
Definition at line 71 of file vulkan_encode.h.
typedef int(* vkenc_cb_write_filler) (AVCodecContext *avctx, uint32_t filler, uint8_t *data, size_t *data_len) |
Callback for writing alignment data.
Align is the value to align offset to.
Definition at line 78 of file vulkan_encode.h.
typedef int(* vkenc_cb_write_extra_headers) (AVCodecContext *avctx, FFVulkanEncodePicture *pic, uint8_t *data, size_t *data_len) |
Callback for writing any extra units requested.
data_len must be set to the available size, and its value will be overwritten by the #bytes written to the output buffer.
Definition at line 86 of file vulkan_encode.h.
av_cold int ff_vulkan_encode_init | ( | AVCodecContext * | avctx, |
FFVulkanEncodeContext * | ctx, | ||
const FFVulkanEncodeDescriptor * | vk_desc, | ||
const FFVulkanCodec * | codec, | ||
void * | codec_caps, | ||
void * | quality_pnext | ||
) |
Initialize encoder.
Definition at line 701 of file vulkan_encode.c.
Referenced by vulkan_encode_h264_init(), and vulkan_encode_h265_init().
av_cold int ff_vulkan_write_global_header | ( | AVCodecContext * | avctx, |
FFVulkanEncodeContext * | ctx | ||
) |
Write out the extradata in case its needed.
Definition at line 671 of file vulkan_encode.c.
Referenced by vulkan_encode_h264_init(), and vulkan_encode_h265_init().
int ff_vulkan_encode_receive_packet | ( | AVCodecContext * | avctx, |
AVPacket * | pkt | ||
) |
Encode.
Definition at line 541 of file vulkan_encode.c.
void ff_vulkan_encode_uninit | ( | FFVulkanEncodeContext * | ctx | ) |
Uninitialize encoder.
Definition at line 31 of file vulkan_encode.c.
Referenced by vulkan_encode_h264_close(), and vulkan_encode_h265_close().
int ff_vulkan_encode_create_session_params | ( | AVCodecContext * | avctx, |
FFVulkanEncodeContext * | ctx, | ||
void * | codec_params_pnext | ||
) |
Create session parameters.
Definition at line 1026 of file vulkan_encode.c.
Referenced by create_session_params().
const AVCodecHWConfigInternal* const ff_vulkan_encode_hw_configs[] |
Paperwork.
Definition at line 26 of file vulkan_encode.c.