23#ifndef AVCODEC_D3D12VA_DECODE_H
24#define AVCODEC_D3D12VA_DECODE_H
55 D3D12_VIDEO_DECODE_CONFIGURATION
cfg;
140#define D3D12VA_VIDEO_DEC_ASYNC_DEPTH 36
141#define D3D12VA_DECODE_CONTEXT(avctx) ((D3D12VADecodeContext *)((avctx)->internal->hwaccel_priv_data))
142#define D3D12VA_FRAMES_CONTEXT(avctx) ((AVHWFramesContext *)(avctx)->hw_frames_ctx->data)
188 const void *pp,
unsigned pp_size,
189 const void *qm,
unsigned qm_size,
190 int(*)(
AVCodecContext *, D3D12_VIDEO_DECODE_INPUT_STREAM_ARGUMENTS *, ID3D12Resource *));
Libavcodec external API header.
int ff_d3d12va_decode_uninit(AVCodecContext *avctx)
uninit D3D12VADecodeContext
int ff_d3d12va_common_frame_params(AVCodecContext *avctx, AVBufferRef *hw_frames_ctx)
d3d12va common frame params
int ff_d3d12va_decode_init(AVCodecContext *avctx)
init D3D12VADecodeContext
int ff_d3d12va_get_suitable_max_bitstream_size(AVCodecContext *avctx)
Get a suitable maximum bitstream size.
int ff_d3d12va_common_end_frame(AVCodecContext *avctx, AVFrame *frame, const void *pp, unsigned pp_size, const void *qm, unsigned qm_size, int(*)(AVCodecContext *, D3D12_VIDEO_DECODE_INPUT_STREAM_ARGUMENTS *, ID3D12Resource *))
d3d12va common end frame
An API-specific header for AV_HWDEVICE_TYPE_D3D12VA.
common internal api header.
AVPixelFormat
Pixel format.
A reference to a data buffer.
main external API structure.
This struct is allocated as AVHWDeviceContext.hwctx.
This struct is used to sync d3d12 execution.
This structure describes decoded (raw) audio or video data.
This structure is used to provide the necessary configurations and data to the FFmpeg Direct3D 12 HWA...
AVFifo * objects_queue
A cached queue for reusing the D3D12 command allocators and upload buffers.
D3D12_VIDEO_DECODE_CONFIGURATION cfg
D3D12 configuration used to create the decoder.
enum AVPixelFormat pix_fmt
Pixel format.
ID3D12CommandQueue * command_queue
D3D12 command queue.
ID3D12VideoDecodeCommandList * command_list
D3D12 video decode command list.
AVD3D12VASyncContext sync_ctx
The sync context used to sync command queue.
ID3D12VideoDecoderHeap * decoder_heap
D3D12 video decoder heap.
unsigned report_id
Private to the FFmpeg AVHWAccel implementation.
ID3D12VideoDecoder * decoder
D3D12 video decoder.
UINT max_num_ref
Maximum number of reference frames.
UINT * ref_subresources
The array of subresources used for reference frames.
AVBufferRef * decoder_ref
ID3D12Resource ** ref_only_resources
UINT bitstream_size
Bitstream size for each frame.
AVD3D12VADeviceContext * device_ctx
A pointer to AVD3D12VADeviceContext used to create D3D12 objects.
ID3D12Resource ** ref_resources
The array of resources used for reference frames.
UINT used_mask
Used mask used to record reference frames indices.
void * reference_only_map
The Reference-Only feature in DirectX 12 is a memory optimization technique designed for video decodi...