FFmpeg
|
#include "config.h"
#include "config_components.h"
#include <objbase.h>
#include "libavutil/hwcontext.h"
#include "avcodec.h"
#include "internal.h"
Go to the source code of this file.
Data Structures | |
union | AVDXVAContext |
struct | FFDXVASharedContext |
Macros | |
#define | COBJMACROS |
#define | FF_DXVA2_WORKAROUND_SCALING_LIST_ZIGZAG 1 |
Work around for DXVA2/Direct3D11 and old UVD/UVD+ ATI video cards. More... | |
#define | FF_DXVA2_WORKAROUND_INTEL_CLEARVIDEO 2 |
Work around for DXVA2/Direct3D11 and old Intel GPUs with ClearVideo interface. More... | |
#define | DXVA2_VAR(ctx, var) 0 |
#define | D3D11VA_VAR(ctx, var) 0 |
#define | DXVA_SHARED_CONTEXT(avctx) ((FFDXVASharedContext *)((avctx)->internal->hwaccel_priv_data)) |
#define | DXVA_CONTEXT(avctx) (AVDXVAContext *)((avctx)->hwaccel_context ? (avctx)->hwaccel_context : (&(DXVA_SHARED_CONTEXT(avctx)->ctx))) |
#define | D3D11VA_CONTEXT(ctx) (&ctx->d3d11va) |
#define | DXVA2_CONTEXT(ctx) (&ctx->dxva2) |
#define | DXVA2_CONTEXT_VAR(avctx, ctx, var) (avctx->pix_fmt == AV_PIX_FMT_D3D12 ? 0 : (ff_dxva2_is_d3d11(avctx) ? D3D11VA_VAR(ctx, var) : DXVA2_VAR(ctx, var))) |
#define | DXVA_CONTEXT_REPORT_ID(avctx, ctx) (*ff_dxva2_get_report_id(avctx, ctx)) |
#define | DXVA_CONTEXT_WORKAROUND(avctx, ctx) DXVA2_CONTEXT_VAR(avctx, ctx, workaround) |
#define | DXVA_CONTEXT_COUNT(avctx, ctx) DXVA2_CONTEXT_VAR(avctx, ctx, surface_count) |
#define | DXVA_CONTEXT_DECODER(avctx, ctx) (avctx->pix_fmt == AV_PIX_FMT_D3D12 ? 0 : (ff_dxva2_is_d3d11(avctx) ? (void *)D3D11VA_VAR(ctx, decoder) : (void *)DXVA2_VAR(ctx, decoder))) |
#define | DXVA_CONTEXT_CFG(avctx, ctx) (avctx->pix_fmt == AV_PIX_FMT_D3D12 ? 0 : (ff_dxva2_is_d3d11(avctx) ? (void *)D3D11VA_VAR(ctx, cfg) : (void *)DXVA2_VAR(ctx, cfg))) |
#define | DXVA_CONTEXT_CFG_BITSTREAM(avctx, ctx) DXVA2_CONTEXT_VAR(avctx, ctx, cfg->ConfigBitstreamRaw) |
#define | DXVA_CONTEXT_CFG_INTRARESID(avctx, ctx) DXVA2_CONTEXT_VAR(avctx, ctx, cfg->ConfigIntraResidUnsigned) |
#define | DXVA_CONTEXT_CFG_RESIDACCEL(avctx, ctx) DXVA2_CONTEXT_VAR(avctx, ctx, cfg->ConfigResidDiffAccelerator) |
#define | DXVA_CONTEXT_VALID(avctx, ctx) |
Typedefs | |
typedef void | DECODER_BUFFER_DESC |
#define COBJMACROS |
Definition at line 26 of file dxva2_internal.h.
#define FF_DXVA2_WORKAROUND_SCALING_LIST_ZIGZAG 1 |
Work around for DXVA2/Direct3D11 and old UVD/UVD+ ATI video cards.
Definition at line 34 of file dxva2_internal.h.
#define FF_DXVA2_WORKAROUND_INTEL_CLEARVIDEO 2 |
Work around for DXVA2/Direct3D11 and old Intel GPUs with ClearVideo interface.
Definition at line 35 of file dxva2_internal.h.
#define DXVA2_VAR | ( | ctx, | |
var | |||
) | 0 |
Definition at line 42 of file dxva2_internal.h.
#define D3D11VA_VAR | ( | ctx, | |
var | |||
) | 0 |
Definition at line 50 of file dxva2_internal.h.
#define DXVA_SHARED_CONTEXT | ( | avctx | ) | ((FFDXVASharedContext *)((avctx)->internal->hwaccel_priv_data)) |
Definition at line 116 of file dxva2_internal.h.
#define DXVA_CONTEXT | ( | avctx | ) | (AVDXVAContext *)((avctx)->hwaccel_context ? (avctx)->hwaccel_context : (&(DXVA_SHARED_CONTEXT(avctx)->ctx))) |
Definition at line 118 of file dxva2_internal.h.
Definition at line 120 of file dxva2_internal.h.
Definition at line 121 of file dxva2_internal.h.
#define DXVA2_CONTEXT_VAR | ( | avctx, | |
ctx, | |||
var | |||
) | (avctx->pix_fmt == AV_PIX_FMT_D3D12 ? 0 : (ff_dxva2_is_d3d11(avctx) ? D3D11VA_VAR(ctx, var) : DXVA2_VAR(ctx, var))) |
Definition at line 123 of file dxva2_internal.h.
#define DXVA_CONTEXT_REPORT_ID | ( | avctx, | |
ctx | |||
) | (*ff_dxva2_get_report_id(avctx, ctx)) |
Definition at line 125 of file dxva2_internal.h.
#define DXVA_CONTEXT_WORKAROUND | ( | avctx, | |
ctx | |||
) | DXVA2_CONTEXT_VAR(avctx, ctx, workaround) |
Definition at line 126 of file dxva2_internal.h.
#define DXVA_CONTEXT_COUNT | ( | avctx, | |
ctx | |||
) | DXVA2_CONTEXT_VAR(avctx, ctx, surface_count) |
Definition at line 127 of file dxva2_internal.h.
#define DXVA_CONTEXT_DECODER | ( | avctx, | |
ctx | |||
) | (avctx->pix_fmt == AV_PIX_FMT_D3D12 ? 0 : (ff_dxva2_is_d3d11(avctx) ? (void *)D3D11VA_VAR(ctx, decoder) : (void *)DXVA2_VAR(ctx, decoder))) |
Definition at line 128 of file dxva2_internal.h.
#define DXVA_CONTEXT_CFG | ( | avctx, | |
ctx | |||
) | (avctx->pix_fmt == AV_PIX_FMT_D3D12 ? 0 : (ff_dxva2_is_d3d11(avctx) ? (void *)D3D11VA_VAR(ctx, cfg) : (void *)DXVA2_VAR(ctx, cfg))) |
Definition at line 129 of file dxva2_internal.h.
#define DXVA_CONTEXT_CFG_BITSTREAM | ( | avctx, | |
ctx | |||
) | DXVA2_CONTEXT_VAR(avctx, ctx, cfg->ConfigBitstreamRaw) |
Definition at line 130 of file dxva2_internal.h.
#define DXVA_CONTEXT_CFG_INTRARESID | ( | avctx, | |
ctx | |||
) | DXVA2_CONTEXT_VAR(avctx, ctx, cfg->ConfigIntraResidUnsigned) |
Definition at line 131 of file dxva2_internal.h.
#define DXVA_CONTEXT_CFG_RESIDACCEL | ( | avctx, | |
ctx | |||
) | DXVA2_CONTEXT_VAR(avctx, ctx, cfg->ConfigResidDiffAccelerator) |
Definition at line 132 of file dxva2_internal.h.
#define DXVA_CONTEXT_VALID | ( | avctx, | |
ctx | |||
) |
Definition at line 133 of file dxva2_internal.h.
typedef void DECODER_BUFFER_DESC |
Definition at line 72 of file dxva2_internal.h.
unsigned ff_dxva2_get_surface_index | ( | const AVCodecContext * | avctx, |
AVDXVAContext * | , | ||
const AVFrame * | frame, | ||
int | curr | ||
) |
Definition at line 770 of file dxva2.c.
Referenced by ff_dxva2_av1_fill_picture_parameters(), ff_dxva2_h264_fill_picture_parameters(), ff_dxva2_hevc_fill_picture_parameters(), ff_dxva2_mpeg2_fill_picture_parameters(), ff_dxva2_vc1_fill_picture_parameters(), ff_dxva2_vp9_fill_picture_parameters(), and fill_slice_long().
int ff_dxva2_commit_buffer | ( | AVCodecContext * | , |
AVDXVAContext * | , | ||
DECODER_BUFFER_DESC * | , | ||
unsigned | type, | ||
const void * | data, | ||
unsigned | size, | ||
unsigned | mb_count | ||
) |
Definition at line 802 of file dxva2.c.
Referenced by commit_bitstream_and_slice_buffer(), and ff_dxva2_common_end_frame().
int ff_dxva2_common_end_frame | ( | AVCodecContext * | , |
AVFrame * | , | ||
const void * | pp, | ||
unsigned | pp_size, | ||
const void * | qm, | ||
unsigned | qm_size, | ||
int(*)(AVCodecContext *, DECODER_BUFFER_DESC *bs, DECODER_BUFFER_DESC *slice) | commit_bs_si | ||
) |
Definition at line 891 of file dxva2.c.
Referenced by dxva2_av1_end_frame(), dxva2_h264_end_frame(), dxva2_hevc_end_frame(), dxva2_mpeg2_end_frame(), dxva2_vc1_end_frame(), and dxva2_vp9_end_frame().
int ff_dxva2_decode_init | ( | AVCodecContext * | avctx | ) |
int ff_dxva2_decode_uninit | ( | AVCodecContext * | avctx | ) |
Definition at line 730 of file dxva2.c.
Referenced by dxva2_av1_uninit(), and ff_dxva2_decode_init().
int ff_dxva2_common_frame_params | ( | AVCodecContext * | avctx, |
AVBufferRef * | hw_frames_ctx | ||
) |
int ff_dxva2_is_d3d11 | ( | const AVCodecContext * | avctx | ) |
Definition at line 1056 of file dxva2.c.
Referenced by commit_bitstream_and_slice_buffer(), ff_dxva2_commit_buffer(), ff_dxva2_common_end_frame(), ff_dxva2_get_report_id(), ff_dxva2_lock(), and ff_dxva2_unlock().
unsigned* ff_dxva2_get_report_id | ( | const AVCodecContext * | avctx, |
AVDXVAContext * | ctx | ||
) |
void ff_dxva2_h264_fill_picture_parameters | ( | const AVCodecContext * | avctx, |
AVDXVAContext * | ctx, | ||
DXVA_PicParams_H264 * | pp | ||
) |
Definition at line 51 of file dxva2_h264.c.
Referenced by d3d12va_h264_start_frame(), and dxva2_h264_start_frame().
void ff_dxva2_h264_fill_scaling_lists | ( | const AVCodecContext * | avctx, |
AVDXVAContext * | ctx, | ||
DXVA_Qmatrix_H264 * | qm | ||
) |
Definition at line 168 of file dxva2_h264.c.
Referenced by d3d12va_h264_start_frame(), and dxva2_h264_start_frame().
void ff_dxva2_hevc_fill_picture_parameters | ( | const AVCodecContext * | avctx, |
AVDXVAContext * | ctx, | ||
DXVA_PicParams_HEVC * | pp | ||
) |
Definition at line 60 of file dxva2_hevc.c.
Referenced by d3d12va_hevc_start_frame(), and dxva2_hevc_start_frame().
void ff_dxva2_hevc_fill_scaling_lists | ( | const AVCodecContext * | avctx, |
AVDXVAContext * | ctx, | ||
DXVA_Qmatrix_HEVC * | qm | ||
) |
Definition at line 204 of file dxva2_hevc.c.
Referenced by d3d12va_hevc_start_frame(), and dxva2_hevc_start_frame().
int ff_dxva2_vp9_fill_picture_parameters | ( | const AVCodecContext * | avctx, |
AVDXVAContext * | ctx, | ||
DXVA_PicParams_VP9 * | pp | ||
) |
Definition at line 46 of file dxva2_vp9.c.
Referenced by d3d12va_vp9_start_frame(), and dxva2_vp9_start_frame().
void ff_dxva2_mpeg2_fill_picture_parameters | ( | AVCodecContext * | avctx, |
AVDXVAContext * | ctx, | ||
DXVA_PictureParameters * | pp | ||
) |
Definition at line 43 of file dxva2_mpeg2.c.
Referenced by d3d12va_mpeg2_start_frame(), and dxva2_mpeg2_start_frame().
void ff_dxva2_mpeg2_fill_quantization_matrices | ( | AVCodecContext * | avctx, |
AVDXVAContext * | ctx, | ||
DXVA_QmatrixData * | qm | ||
) |
Definition at line 109 of file dxva2_mpeg2.c.
Referenced by d3d12va_mpeg2_start_frame(), and dxva2_mpeg2_start_frame().
void ff_dxva2_mpeg2_fill_slice | ( | AVCodecContext * | avctx, |
DXVA_SliceInfo * | slice, | ||
unsigned | position, | ||
const uint8_t * | buffer, | ||
unsigned | size | ||
) |
Definition at line 126 of file dxva2_mpeg2.c.
Referenced by d3d12va_mpeg2_decode_slice(), and dxva2_mpeg2_decode_slice().
void ff_dxva2_vc1_fill_picture_parameters | ( | AVCodecContext * | avctx, |
AVDXVAContext * | ctx, | ||
DXVA_PictureParameters * | pp | ||
) |
Definition at line 43 of file dxva2_vc1.c.
Referenced by d3d12va_vc1_start_frame(), and dxva2_vc1_start_frame().
void ff_dxva2_vc1_fill_slice | ( | AVCodecContext * | avctx, |
DXVA_SliceInfo * | slice, | ||
unsigned | position, | ||
unsigned | size | ||
) |
Definition at line 167 of file dxva2_vc1.c.
Referenced by d3d12va_vc1_decode_slice(), and dxva2_vc1_decode_slice().