From: Biswapriyo Nath nathbappai@gmail.com
Required for https://code.ffmpeg.org/FFmpeg/FFmpeg/commit/92f2f9ea5c49e94814693861a7e9e47... --- include/d3d12.idl | 5 + include/d3d12video.idl | 525 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 530 insertions(+)
diff --git a/include/d3d12.idl b/include/d3d12.idl index d7b283a2e02..f49f3cbde1e 100644 --- a/include/d3d12.idl +++ b/include/d3d12.idl @@ -428,6 +428,11 @@ const UINT D3D12_VIDEO_DECODE_MAX_HISTOGRAM_COMPONENTS = 4; const UINT D3D12_VIDEO_DECODE_MIN_BITSTREAM_OFFSET_ALIGNMENT = 256; const UINT D3D12_VIDEO_DECODE_MIN_HISTOGRAM_OFFSET_ALIGNMENT = 256; const UINT D3D12_VIDEO_DECODE_STATUS_MACROBLOCKS_AFFECTED_UNKNOWN = 0xffffffff; +const UINT D3D12_VIDEO_ENCODER_AV1_INVALID_DPB_RESOURCE_INDEX = 0xff; +const UINT D3D12_VIDEO_ENCODER_AV1_MAX_TILE_COLS = 64; +const UINT D3D12_VIDEO_ENCODER_AV1_MAX_TILE_ROWS = 64; +const UINT D3D12_VIDEO_ENCODER_AV1_SUPERRES_DENOM_MIN = 9; +const UINT D3D12_VIDEO_ENCODER_AV1_SUPERRES_NUM = 8; const UINT D3D12_VIDEO_PROCESS_MAX_FILTERS = 32; const UINT D3D12_VIDEO_PROCESS_STEREO_VIEWS = 2; const UINT D3D12_VIEWPORT_AND_SCISSORRECT_MAX_INDEX = 15; diff --git a/include/d3d12video.idl b/include/d3d12video.idl index f39b28d29a9..2e98a52d903 100644 --- a/include/d3d12video.idl +++ b/include/d3d12video.idl @@ -85,6 +85,8 @@ typedef enum D3D12_FEATURE_VIDEO D3D12_FEATURE_VIDEO_ENCODER_SUPPORT = 43, D3D12_FEATURE_VIDEO_ENCODER_CODEC_PICTURE_CONTROL_SUPPORT = 44, D3D12_FEATURE_VIDEO_ENCODER_RESOURCE_REQUIREMENTS = 45, + D3D12_FEATURE_VIDEO_ENCODER_FRAME_SUBREGION_LAYOUT_CONFIG = 46, + D3D12_FEATURE_VIDEO_ENCODER_SUPPORT1 = 47, } D3D12_FEATURE_VIDEO;
typedef enum D3D12_BITSTREAM_ENCRYPTION_TYPE @@ -808,6 +810,442 @@ cpp_quote("DEFINE_GUID(D3D12_VIDEO_DECODE_PROFILE_AV1_PROFILE2, 0x0c5f2aa1, 0xe5 cpp_quote("DEFINE_GUID(D3D12_VIDEO_DECODE_PROFILE_AV1_12BIT_PROFILE2, 0x17127009, 0xa00f, 0x4ce1, 0x99, 0x4e, 0xbf, 0x40, 0x81, 0xf6, 0xf3, 0xf0);") cpp_quote("DEFINE_GUID(D3D12_VIDEO_DECODE_PROFILE_AV1_12BIT_PROFILE2_420, 0x2d80bed6, 0x9cac, 0x4835, 0x9e, 0x91, 0x32, 0x7b, 0xbc, 0x4f, 0x9e, 0xe8);")
+typedef enum D3D12_VIDEO_ENCODER_AV1_PROFILE +{ + D3D12_VIDEO_ENCODER_AV1_PROFILE_MAIN = 0, + D3D12_VIDEO_ENCODER_AV1_PROFILE_HIGH = 1, + D3D12_VIDEO_ENCODER_AV1_PROFILE_PROFESSIONAL = 2, +} D3D12_VIDEO_ENCODER_AV1_PROFILE; + +typedef enum D3D12_VIDEO_ENCODER_AV1_LEVELS +{ + D3D12_VIDEO_ENCODER_AV1_LEVELS_2_0 = 0, + D3D12_VIDEO_ENCODER_AV1_LEVELS_2_1 = 1, + D3D12_VIDEO_ENCODER_AV1_LEVELS_2_2 = 2, + D3D12_VIDEO_ENCODER_AV1_LEVELS_2_3 = 3, + D3D12_VIDEO_ENCODER_AV1_LEVELS_3_0 = 4, + D3D12_VIDEO_ENCODER_AV1_LEVELS_3_1 = 5, + D3D12_VIDEO_ENCODER_AV1_LEVELS_3_2 = 6, + D3D12_VIDEO_ENCODER_AV1_LEVELS_3_3 = 7, + D3D12_VIDEO_ENCODER_AV1_LEVELS_4_0 = 8, + D3D12_VIDEO_ENCODER_AV1_LEVELS_4_1 = 9, + D3D12_VIDEO_ENCODER_AV1_LEVELS_4_2 = 10, + D3D12_VIDEO_ENCODER_AV1_LEVELS_4_3 = 11, + D3D12_VIDEO_ENCODER_AV1_LEVELS_5_0 = 12, + D3D12_VIDEO_ENCODER_AV1_LEVELS_5_1 = 13, + D3D12_VIDEO_ENCODER_AV1_LEVELS_5_2 = 14, + D3D12_VIDEO_ENCODER_AV1_LEVELS_5_3 = 15, + D3D12_VIDEO_ENCODER_AV1_LEVELS_6_0 = 16, + D3D12_VIDEO_ENCODER_AV1_LEVELS_6_1 = 17, + D3D12_VIDEO_ENCODER_AV1_LEVELS_6_2 = 18, + D3D12_VIDEO_ENCODER_AV1_LEVELS_6_3 = 19, + D3D12_VIDEO_ENCODER_AV1_LEVELS_7_0 = 20, + D3D12_VIDEO_ENCODER_AV1_LEVELS_7_1 = 21, + D3D12_VIDEO_ENCODER_AV1_LEVELS_7_2 = 22, + D3D12_VIDEO_ENCODER_AV1_LEVELS_7_3 = 23, +} D3D12_VIDEO_ENCODER_AV1_LEVELS; + +typedef enum D3D12_VIDEO_ENCODER_AV1_TIER +{ + D3D12_VIDEO_ENCODER_AV1_TIER_MAIN = 0, + D3D12_VIDEO_ENCODER_AV1_TIER_HIGH = 1, +} D3D12_VIDEO_ENCODER_AV1_TIER; + +typedef struct D3D12_VIDEO_ENCODER_AV1_LEVEL_TIER_CONSTRAINTS +{ + D3D12_VIDEO_ENCODER_AV1_LEVELS Level; + D3D12_VIDEO_ENCODER_AV1_TIER Tier; +} D3D12_VIDEO_ENCODER_AV1_LEVEL_TIER_CONSTRAINTS; + +typedef enum D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_NONE = 0x0, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_128x128_SUPERBLOCK = 0x1, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_FILTER_INTRA = 0x2, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_INTRA_EDGE_FILTER = 0x4, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_INTERINTRA_COMPOUND = 0x8, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_MASKED_COMPOUND = 0x10, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_WARPED_MOTION = 0x20, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_DUAL_FILTER = 0x40, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_JNT_COMP = 0x80, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_FORCED_INTEGER_MOTION_VECTORS = 0x100, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_SUPER_RESOLUTION = 0x200, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_LOOP_RESTORATION_FILTER = 0x400, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_PALETTE_ENCODING = 0x800, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_CDEF_FILTERING = 0x1000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_INTRA_BLOCK_COPY = 0x2000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_FRAME_REFERENCE_MOTION_VECTORS = 0x4000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_ORDER_HINT_TOOLS = 0x8000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_AUTO_SEGMENTATION = 0x10000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_CUSTOM_SEGMENTATION = 0x20000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_LOOP_FILTER_DELTAS = 0x40000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_QUANTIZATION_DELTAS = 0x80000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_QUANTIZATION_MATRIX = 0x100000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_REDUCED_TX_SET = 0x200000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_MOTION_MODE_SWITCHABLE = 0x400000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_ALLOW_HIGH_PRECISION_MV = 0x800000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_SKIP_MODE_PRESENT = 0x1000000, + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAG_DELTA_LF_PARAMS = 0x2000000, +} D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAGS)") + +typedef enum D3D12_VIDEO_ENCODER_AV1_TX_MODE +{ + D3D12_VIDEO_ENCODER_AV1_TX_MODE_ONLY4x4 = 0, + D3D12_VIDEO_ENCODER_AV1_TX_MODE_LARGEST = 1, + D3D12_VIDEO_ENCODER_AV1_TX_MODE_SELECT = 2, +} D3D12_VIDEO_ENCODER_AV1_TX_MODE; + +typedef enum D3D12_VIDEO_ENCODER_AV1_TX_MODE_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_TX_MODE_FLAG_NONE = 0x0, + D3D12_VIDEO_ENCODER_AV1_TX_MODE_FLAG_ONLY4x4 = (1 << D3D12_VIDEO_ENCODER_AV1_TX_MODE_ONLY4x4), + D3D12_VIDEO_ENCODER_AV1_TX_MODE_FLAG_LARGEST = (1 << D3D12_VIDEO_ENCODER_AV1_TX_MODE_LARGEST), + D3D12_VIDEO_ENCODER_AV1_TX_MODE_FLAG_SELECT = (1 << D3D12_VIDEO_ENCODER_AV1_TX_MODE_SELECT), +} D3D12_VIDEO_ENCODER_AV1_TX_MODE_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_TX_MODE_FLAGS)") + +typedef enum D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS +{ + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_EIGHTTAP = 0, + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_EIGHTTAP_SMOOTH = 1, + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_EIGHTTAP_SHARP = 2, + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_BILINEAR = 3, + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_SWITCHABLE = 4, +} D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS; + +typedef enum D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAG_NONE = 0x0, + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAG_EIGHTTAP = (1 << D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_EIGHTTAP), + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAG_EIGHTTAP_SMOOTH = (1 << D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_EIGHTTAP_SMOOTH), + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAG_EIGHTTAP_SHARP = (1 << D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_EIGHTTAP_SHARP), + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAG_BILINEAR = (1 << D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_BILINEAR), + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAG_SWITCHABLE = (1 << D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_SWITCHABLE), +} D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAGS)") + +typedef enum D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_BLOCK_SIZE +{ + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_BLOCK_SIZE_4x4 = 0, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_BLOCK_SIZE_8x8 = 1, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_BLOCK_SIZE_16x16 = 2, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_BLOCK_SIZE_32x32 = 3, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_BLOCK_SIZE_64x64 = 4, +} D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_BLOCK_SIZE; + +typedef enum D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE +{ + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_DISABLED = 0, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_Q = 1, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_LF_Y_V = 2, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_LF_Y_H = 3, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_LF_U = 4, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_LF_V = 5, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_REF_FRAME = 6, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_SKIP = 7, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_GLOBALMV = 8, +} D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE; + +typedef enum D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_NONE = 0, + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_DISABLED = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_DISABLED), + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_ALT_Q = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_Q), + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_ALT_LF_Y_V = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_LF_Y_V), + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_ALT_LF_Y_H = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_LF_Y_H), + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_ALT_LF_U = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_LF_U), + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_ALT_LF_V = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_LF_V), + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_REF_FRAME = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_REF_FRAME), + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_ALT_SKIP = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_SKIP), + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAG_ALT_GLOBALMV = (1 << D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_ALT_GLOBALMV), +} D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAGS)") + +typedef enum D3D12_VIDEO_ENCODER_AV1_RESTORATION_TYPE +{ + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TYPE_DISABLED = 0, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TYPE_SWITCHABLE = 1, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TYPE_WIENER = 2, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TYPE_SGRPROJ = 3, +} D3D12_VIDEO_ENCODER_AV1_RESTORATION_TYPE; + +typedef enum D3D12_VIDEO_ENCODER_AV1_RESTORATION_TILESIZE +{ + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TILESIZE_DISABLED = 0, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TILESIZE_32x32 = 1, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TILESIZE_64x64 = 2, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TILESIZE_128x128 = 3, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TILESIZE_256x256 = 4, +} D3D12_VIDEO_ENCODER_AV1_RESTORATION_TILESIZE; + +typedef enum D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAG_NOT_SUPPORTED = 0x0, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAG_32x32 = 0x1, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAG_64x64 = 0x2, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAG_128x128 = 0x4, + D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAG_256x256 = 0x8, +} D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAGS)") + +typedef enum D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION +{ + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_IDENTITY = 0, + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_TRANSLATION = 1, + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_ROTZOOM = 2, + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_AFFINE = 3, +} D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION; + +typedef enum D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAG_NONE = 0, + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAG_IDENTITY = (1 << D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_IDENTITY), + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAG_TRANSLATION = (1 << D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_TRANSLATION), + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAG_ROTZOOM = (1 << D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_ROTZOOM), + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAG_AFFINE = (1 << D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_AFFINE), +} D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAGS)") + +typedef enum D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_NONE = 0, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_QUANTIZATION = 0x1, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_QUANTIZATION_DELTA = 0x2, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_LOOP_FILTER = 0x4, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_LOOP_FILTER_DELTA = 0x8, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_CDEF_DATA = 0x10, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_CONTEXT_UPDATE_TILE_ID = 0x20, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_COMPOUND_PREDICTION_MODE = 0x40, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_PRIMARY_REF_FRAME = 0x80, + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAG_REFERENCE_INDICES = 0x100, +} D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAGS)") + +typedef struct D3D12_VIDEO_ENCODER_AV1_CODEC_CONFIGURATION_SUPPORT +{ + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAGS SupportedFeatureFlags; + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAGS RequiredFeatureFlags; + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS_FLAGS SupportedInterpolationFilters; + D3D12_VIDEO_ENCODER_AV1_RESTORATION_SUPPORT_FLAGS SupportedRestorationParams[3][3]; + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MODE_FLAGS SupportedSegmentationModes; + D3D12_VIDEO_ENCODER_AV1_TX_MODE_FLAGS SupportedTxModes[4]; + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_BLOCK_SIZE SegmentationBlockSize; + D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES_FLAGS PostEncodeValuesFlags; + UINT MaxTemporalLayers; + UINT MaxSpatialLayers; +} D3D12_VIDEO_ENCODER_AV1_CODEC_CONFIGURATION_SUPPORT; + +typedef enum D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE +{ + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_KEY_FRAME = 0, + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_INTER_FRAME = 1, + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_INTRA_ONLY_FRAME = 2, + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_SWITCH_FRAME = 3, +} D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE; + +typedef enum D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAG_NONE = 0x0, + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAG_KEY_FRAME = (1 << D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_KEY_FRAME), + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAG_INTER_FRAME = (1 << D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_INTER_FRAME), + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAG_INTRA_ONLY_FRAME = (1 << D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_INTRA_ONLY_FRAME), + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAG_SWITCH_FRAME = (1 << D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_SWITCH_FRAME), +} D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAGS)") + +typedef enum D3D12_VIDEO_ENCODER_AV1_COMP_PREDICTION_TYPE +{ + D3D12_VIDEO_ENCODER_AV1_COMP_PREDICTION_TYPE_SINGLE_REFERENCE = 0, + D3D12_VIDEO_ENCODER_AV1_COMP_PREDICTION_TYPE_COMPOUND_REFERENCE = 1, +} D3D12_VIDEO_ENCODER_AV1_COMP_PREDICTION_TYPE; + +typedef struct D3D12_VIDEO_ENCODER_CODEC_AV1_PICTURE_CONTROL_SUPPORT +{ + D3D12_VIDEO_ENCODER_AV1_COMP_PREDICTION_TYPE PredictionMode; + UINT MaxUniqueReferencesPerFrame; + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE_FLAGS SupportedFrameTypes; + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION_FLAGS SupportedReferenceWarpedMotionFlags; +} D3D12_VIDEO_ENCODER_CODEC_AV1_PICTURE_CONTROL_SUPPORT; + +typedef struct D3D12_VIDEO_ENCODER_AV1_CODEC_CONFIGURATION +{ + D3D12_VIDEO_ENCODER_AV1_FEATURE_FLAGS FeatureFlags; + UINT OrderHintBitsMinus1; +} D3D12_VIDEO_ENCODER_AV1_CODEC_CONFIGURATION; + +typedef struct D3D12_VIDEO_ENCODER_AV1_SEQUENCE_STRUCTURE +{ + UINT IntraDistance; + UINT InterFramePeriod; +} D3D12_VIDEO_ENCODER_AV1_SEQUENCE_STRUCTURE; + +typedef struct D3D12_VIDEO_ENCODER_AV1_REFERENCE_PICTURE_WARPED_MOTION_INFO +{ + D3D12_VIDEO_ENCODER_AV1_REFERENCE_WARPED_MOTION_TRANSFORMATION TransformationType; + INT TransformationMatrix[8]; + BOOL InvalidAffineSet; +} D3D12_VIDEO_ENCODER_AV1_REFERENCE_PICTURE_WARPED_MOTION_INFO; + +typedef struct D3D12_VIDEO_ENCODER_AV1_REFERENCE_PICTURE_DESCRIPTOR +{ + UINT ReconstructedPictureResourceIndex; + UINT TemporalLayerIndexPlus1; + UINT SpatialLayerIndexPlus1; + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE FrameType; + D3D12_VIDEO_ENCODER_AV1_REFERENCE_PICTURE_WARPED_MOTION_INFO WarpedMotionInfo; + UINT OrderHint; + UINT PictureIndex; +} D3D12_VIDEO_ENCODER_AV1_REFERENCE_PICTURE_DESCRIPTOR; + +typedef enum D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAGS +{ + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_NONE = 0x0, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_ENABLE_ERROR_RESILIENT_MODE = 0x1, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_DISABLE_CDF_UPDATE = 0x2, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_ENABLE_PALETTE_ENCODING = 0x4, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_ENABLE_SKIP_MODE = 0x8, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_FRAME_REFERENCE_MOTION_VECTORS = 0x10, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_FORCE_INTEGER_MOTION_VECTORS = 0x20, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_ALLOW_INTRA_BLOCK_COPY = 0x40, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_USE_SUPER_RESOLUTION = 0x80, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_DISABLE_FRAME_END_UPDATE_CDF = 0x100, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_ENABLE_FRAME_SEGMENTATION_AUTO = 0x200, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_ENABLE_FRAME_SEGMENTATION_CUSTOM = 0x400, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_ENABLE_WARPED_MOTION = 0x800, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_REDUCED_TX_SET = 0x1000, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_MOTION_MODE_SWITCHABLE = 0x2000, + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAG_ALLOW_HIGH_PRECISION_MV = 0x4000, +} D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAGS; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAGS)") + +typedef struct D3D12_VIDEO_ENCODER_AV1_RESTORATION_CONFIG +{ + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TYPE FrameRestorationType[3]; + D3D12_VIDEO_ENCODER_AV1_RESTORATION_TILESIZE LoopRestorationPixelSize[3]; +} D3D12_VIDEO_ENCODER_AV1_RESTORATION_CONFIG; + +typedef struct D3D12_VIDEO_ENCODER_AV1_SEGMENT_DATA +{ + UINT64 EnabledFeatures; + INT64 FeatureValue[8]; +} D3D12_VIDEO_ENCODER_AV1_SEGMENT_DATA; + +typedef struct D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_CONFIG +{ + UINT64 UpdateMap; + UINT64 TemporalUpdate; + UINT64 UpdateData; + UINT64 NumSegments; + D3D12_VIDEO_ENCODER_AV1_SEGMENT_DATA SegmentsData[8]; +} D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_CONFIG; + +typedef struct D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MAP +{ + UINT SegmentsMapByteSize; + UINT8 *pSegmentsMap; +} D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MAP; + +typedef struct D3D12_VIDEO_ENCODER_CODEC_AV1_LOOP_FILTER_CONFIG +{ + UINT64 LoopFilterLevel[2]; + UINT64 LoopFilterLevelU; + UINT64 LoopFilterLevelV; + UINT64 LoopFilterSharpnessLevel; + UINT64 LoopFilterDeltaEnabled; + UINT64 UpdateRefDelta; + INT64 RefDeltas[8]; + UINT64 UpdateModeDelta; + INT64 ModeDeltas[2]; +} D3D12_VIDEO_ENCODER_CODEC_AV1_LOOP_FILTER_CONFIG; + +typedef struct D3D12_VIDEO_ENCODER_CODEC_AV1_LOOP_FILTER_DELTA_CONFIG +{ + UINT64 DeltaLFPresent; + UINT64 DeltaLFMulti; + UINT64 DeltaLFRes; +} D3D12_VIDEO_ENCODER_CODEC_AV1_LOOP_FILTER_DELTA_CONFIG; + +typedef struct D3D12_VIDEO_ENCODER_CODEC_AV1_QUANTIZATION_CONFIG +{ + UINT64 BaseQIndex; + INT64 YDCDeltaQ; + INT64 UDCDeltaQ; + INT64 UACDeltaQ; + INT64 VDCDeltaQ; + INT64 VACDeltaQ; + UINT64 UsingQMatrix; + UINT64 QMY; + UINT64 QMU; + UINT64 QMV; +} D3D12_VIDEO_ENCODER_CODEC_AV1_QUANTIZATION_CONFIG; + +typedef struct D3D12_VIDEO_ENCODER_CODEC_AV1_QUANTIZATION_DELTA_CONFIG +{ + UINT64 DeltaQPresent; + UINT64 DeltaQRes; +} D3D12_VIDEO_ENCODER_CODEC_AV1_QUANTIZATION_DELTA_CONFIG; + +typedef struct D3D12_VIDEO_ENCODER_AV1_CDEF_CONFIG +{ + UINT64 CdefBits; + UINT64 CdefDampingMinus3; + UINT64 CdefYPriStrength[8]; + UINT64 CdefUVPriStrength[8]; + UINT64 CdefYSecStrength[8]; + UINT64 CdefUVSecStrength[8]; +} D3D12_VIDEO_ENCODER_AV1_CDEF_CONFIG; + +typedef struct D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_CODEC_DATA +{ + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_FLAGS Flags; + D3D12_VIDEO_ENCODER_AV1_FRAME_TYPE FrameType; + D3D12_VIDEO_ENCODER_AV1_COMP_PREDICTION_TYPE CompoundPredictionType; + D3D12_VIDEO_ENCODER_AV1_INTERPOLATION_FILTERS InterpolationFilter; + D3D12_VIDEO_ENCODER_AV1_RESTORATION_CONFIG FrameRestorationConfig; + D3D12_VIDEO_ENCODER_AV1_TX_MODE TxMode; + UINT SuperResDenominator; + UINT OrderHint; + UINT PictureIndex; + UINT TemporalLayerIndexPlus1; + UINT SpatialLayerIndexPlus1; + D3D12_VIDEO_ENCODER_AV1_REFERENCE_PICTURE_DESCRIPTOR ReferenceFramesReconPictureDescriptors[8]; + UINT ReferenceIndices[7]; + UINT PrimaryRefFrame; + UINT RefreshFrameFlags; + D3D12_VIDEO_ENCODER_CODEC_AV1_LOOP_FILTER_CONFIG LoopFilter; + D3D12_VIDEO_ENCODER_CODEC_AV1_LOOP_FILTER_DELTA_CONFIG LoopFilterDelta; + D3D12_VIDEO_ENCODER_CODEC_AV1_QUANTIZATION_CONFIG Quantization; + D3D12_VIDEO_ENCODER_CODEC_AV1_QUANTIZATION_DELTA_CONFIG QuantizationDelta; + D3D12_VIDEO_ENCODER_AV1_CDEF_CONFIG CDEF; + UINT QPMapValuesCount; + INT16 *pRateControlQPMap; + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_CONFIG CustomSegmentation; + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_MAP CustomSegmentsMap; +} D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_CODEC_DATA; + +typedef struct D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_SUBREGIONS_LAYOUT_DATA_TILES +{ + UINT64 RowCount; + UINT64 ColCount; + UINT64 RowHeights[D3D12_VIDEO_ENCODER_AV1_MAX_TILE_ROWS]; + UINT64 ColWidths[D3D12_VIDEO_ENCODER_AV1_MAX_TILE_COLS]; + UINT64 ContextUpdateTileId; +} D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_SUBREGIONS_LAYOUT_DATA_TILES; + +typedef struct D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES +{ + UINT64 CompoundPredictionType; + D3D12_VIDEO_ENCODER_CODEC_AV1_LOOP_FILTER_CONFIG LoopFilter; + D3D12_VIDEO_ENCODER_CODEC_AV1_LOOP_FILTER_DELTA_CONFIG LoopFilterDelta; + D3D12_VIDEO_ENCODER_CODEC_AV1_QUANTIZATION_CONFIG Quantization; + D3D12_VIDEO_ENCODER_CODEC_AV1_QUANTIZATION_DELTA_CONFIG QuantizationDelta; + D3D12_VIDEO_ENCODER_AV1_CDEF_CONFIG CDEF; + D3D12_VIDEO_ENCODER_AV1_SEGMENTATION_CONFIG SegmentationConfig; + UINT64 PrimaryRefFrame; + UINT64 ReferenceIndices[7]; +} D3D12_VIDEO_ENCODER_AV1_POST_ENCODE_VALUES; + typedef enum D3D12_VIDEO_ENCODER_RATE_CONTROL_MODE { D3D12_VIDEO_ENCODER_RATE_CONTROL_MODE_ABSOLUTE_QP_MAP = 0, @@ -894,6 +1332,7 @@ typedef enum D3D12_VIDEO_ENCODER_CODEC { D3D12_VIDEO_ENCODER_CODEC_H264 = 0, D3D12_VIDEO_ENCODER_CODEC_HEVC = 1, + D3D12_VIDEO_ENCODER_CODEC_AV1 = 2, } D3D12_VIDEO_ENCODER_CODEC;
typedef enum D3D12_VIDEO_ENCODER_PROFILE_H264 @@ -916,6 +1355,7 @@ typedef struct D3D12_VIDEO_ENCODER_PROFILE_DESC { D3D12_VIDEO_ENCODER_PROFILE_H264 *pH264Profile; D3D12_VIDEO_ENCODER_PROFILE_HEVC *pHEVCProfile; + D3D12_VIDEO_ENCODER_AV1_PROFILE *pAV1Profile; }; } D3D12_VIDEO_ENCODER_PROFILE_DESC;
@@ -979,6 +1419,7 @@ typedef struct D3D12_VIDEO_ENCODER_LEVEL_SETTING { D3D12_VIDEO_ENCODER_LEVELS_H264 *pH264LevelSetting; D3D12_VIDEO_ENCODER_LEVEL_TIER_CONSTRAINTS_HEVC *pHEVCLevelSetting; + D3D12_VIDEO_ENCODER_AV1_LEVEL_TIER_CONSTRAINTS *pAV1LevelSetting; }; } D3D12_VIDEO_ENCODER_LEVEL_SETTING;
@@ -1111,6 +1552,33 @@ typedef struct D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC UCHAR max_transform_hierarchy_depth_intra; } D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC;
+typedef enum D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC_FLAGS1 +{ + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC_FLAG1_NONE = 0x0, + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC_FLAG1_SEPARATE_COLOUR_PLANE_SUPPORT = 0x1, + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC_FLAG1_SEPARATE_COLOUR_PLANE_REQUIRED = 0x2, +} D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC_FLAGS1; +cpp_quote("DEFINE_ENUM_FLAG_OPERATORS(D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC_FLAGS1)") + +typedef struct D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC1 +{ + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC_FLAGS SupportFlags; + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_HEVC_CUSIZE MinLumaCodingUnitSize; + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_HEVC_CUSIZE MaxLumaCodingUnitSize; + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_HEVC_TUSIZE MinLumaTransformUnitSize; + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_HEVC_TUSIZE MaxLumaTransformUnitSize; + UCHAR max_transform_hierarchy_depth_inter; + UCHAR max_transform_hierarchy_depth_intra; + UINT allowed_diff_cu_chroma_qp_offset_depth_values; + UINT allowed_log2_sao_offset_scale_luma_values; + UINT allowed_log2_sao_offset_scale_chroma_values; + UINT allowed_log2_max_transform_skip_block_size_minus2_values; + UINT allowed_chroma_qp_offset_list_len_minus1_values; + UINT allowed_cb_qp_offset_list_values[6]; + UINT allowed_cr_qp_offset_list_values[6]; + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC_FLAGS1 SupportFlags1; +} D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC1; + typedef struct D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT { UINT DataSize; @@ -1118,6 +1586,8 @@ typedef struct D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT { D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_H264 *pH264Support; D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC *pHEVCSupport; + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT_HEVC1 *pHEVCSupport1; + D3D12_VIDEO_ENCODER_AV1_CODEC_CONFIGURATION_SUPPORT *pAV1Support; }; } D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_SUPPORT;
@@ -1239,6 +1709,7 @@ typedef struct D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION { D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_H264 *pH264Config; D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION_HEVC *pHEVCConfig; + D3D12_VIDEO_ENCODER_AV1_CODEC_CONFIGURATION *pAV1Config; }; } D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION;
@@ -1302,6 +1773,7 @@ typedef struct D3D12_VIDEO_ENCODER_SEQUENCE_GOP_STRUCTURE { D3D12_VIDEO_ENCODER_SEQUENCE_GOP_STRUCTURE_H264 *pH264GroupOfPictures; D3D12_VIDEO_ENCODER_SEQUENCE_GOP_STRUCTURE_HEVC *pHEVCGroupOfPictures; + D3D12_VIDEO_ENCODER_AV1_SEQUENCE_STRUCTURE *pAV1SequenceStructure; }; } D3D12_VIDEO_ENCODER_SEQUENCE_GOP_STRUCTURE;
@@ -1545,6 +2017,34 @@ typedef struct D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA_HEVC INT8 *pRateControlQPMap; } D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA_HEVC;
+typedef struct D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA_HEVC1 +{ + D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA_HEVC_FLAGS Flags; + D3D12_VIDEO_ENCODER_FRAME_TYPE_HEVC FrameType; + UINT slice_pic_parameter_set_id; + UINT PictureOrderCountNumber; + UINT TemporalLayerIndex; + UINT List0ReferenceFramesCount; + UINT *pList0ReferenceFrames; + UINT List1ReferenceFramesCount; + UINT *pList1ReferenceFrames; + UINT ReferenceFramesReconPictureDescriptorsCount; + D3D12_VIDEO_ENCODER_REFERENCE_PICTURE_DESCRIPTOR_HEVC *pReferenceFramesReconPictureDescriptors; + UINT List0RefPicModificationsCount; + UINT *pList0RefPicModifications; + UINT List1RefPicModificationsCount; + UINT *pList1RefPicModifications; + UINT QPMapValuesCount; + INT8 *pRateControlQPMap; + UCHAR diff_cu_chroma_qp_offset_depth; + UCHAR log2_sao_offset_scale_luma; + UCHAR log2_sao_offset_scale_chroma; + UCHAR log2_max_transform_skip_block_size_minus2; + UCHAR chroma_qp_offset_list_len_minus1; + CHAR cb_qp_offset_list[6]; + CHAR cr_qp_offset_list[6]; +} D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA_HEVC1; + typedef struct D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA { UINT DataSize; @@ -1552,6 +2052,8 @@ typedef struct D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA { D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA_H264 *pH264PicData; D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA_HEVC *pHEVCPicData; + D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA_HEVC1 *pHEVCPicData1; + D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_CODEC_DATA *pAV1PicData; }; } D3D12_VIDEO_ENCODER_PICTURE_CONTROL_CODEC_DATA;
@@ -1606,9 +2108,32 @@ typedef struct D3D12_VIDEO_ENCODER_PICTURE_CONTROL_SUBREGIONS_LAYOUT_DATA { const D3D12_VIDEO_ENCODER_PICTURE_CONTROL_SUBREGIONS_LAYOUT_DATA_SLICES *pSlicesPartition_H264; const D3D12_VIDEO_ENCODER_PICTURE_CONTROL_SUBREGIONS_LAYOUT_DATA_SLICES *pSlicesPartition_HEVC; + const D3D12_VIDEO_ENCODER_AV1_PICTURE_CONTROL_SUBREGIONS_LAYOUT_DATA_TILES *pTilesPartition_AV1; }; } D3D12_VIDEO_ENCODER_PICTURE_CONTROL_SUBREGIONS_LAYOUT_DATA;
+typedef struct D3D12_FEATURE_DATA_VIDEO_ENCODER_SUPPORT1 +{ + UINT NodeIndex; + D3D12_VIDEO_ENCODER_CODEC Codec; + DXGI_FORMAT InputFormat; + D3D12_VIDEO_ENCODER_CODEC_CONFIGURATION CodecConfiguration; + D3D12_VIDEO_ENCODER_SEQUENCE_GOP_STRUCTURE CodecGopSequence; + D3D12_VIDEO_ENCODER_RATE_CONTROL RateControl; + D3D12_VIDEO_ENCODER_INTRA_REFRESH_MODE IntraRefresh; + D3D12_VIDEO_ENCODER_FRAME_SUBREGION_LAYOUT_MODE SubregionFrameEncoding; + UINT ResolutionsListCount; + const D3D12_VIDEO_ENCODER_PICTURE_RESOLUTION_DESC *pResolutionList; + UINT MaxReferenceFramesInDPB; + D3D12_VIDEO_ENCODER_VALIDATION_FLAGS ValidationFlags; + D3D12_VIDEO_ENCODER_SUPPORT_FLAGS SupportFlags; + D3D12_VIDEO_ENCODER_PROFILE_DESC SuggestedProfile; + D3D12_VIDEO_ENCODER_LEVEL_SETTING SuggestedLevel; + D3D12_FEATURE_DATA_VIDEO_ENCODER_RESOLUTION_SUPPORT_LIMITS *pResolutionDependentSupport; + D3D12_VIDEO_ENCODER_PICTURE_CONTROL_SUBREGIONS_LAYOUT_DATA SubregionFrameEncodingData; + UINT MaxQualityVsSpeed; +} D3D12_FEATURE_DATA_VIDEO_ENCODER_SUPPORT1; + typedef struct D3D12_VIDEO_ENCODER_SEQUENCE_CONTROL_DESC { D3D12_VIDEO_ENCODER_SEQUENCE_CONTROL_FLAGS Flags;