1 /*
2 * This file is part of FFmpeg.
3 *
4 * FFmpeg is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * FFmpeg is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with FFmpeg; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17 */
18
19 #include <string.h>
20
21 #include <va/va.h>
22 #include <va/va_enc_hevc.h>
23
27
35
36
40
44
50
53
57
62
69
70
72 char *
data,
size_t *data_len,
74 {
77 int err;
78
80 if (err < 0) {
82 return err;
83 }
84
87 "%zu < %zu.\n", *data_len,
90 }
91
94
95 return 0;
96 }
97
100 void *nal_unit)
101 {
105 int err;
106
109 if (err < 0) {
112 return err;
113 }
114
115 return 0;
116 }
117
119 char *
data,
size_t *data_len)
120 {
124 int err;
125
128 if (err < 0)
131 }
132
134 if (err < 0)
136
138 if (err < 0)
140
142 if (err < 0)
144
148 return err;
149 }
150
154 char *
data,
size_t *data_len)
155 {
159 int err;
160
163 if (err < 0)
166 }
167
169 if (err < 0)
171
175 return err;
176 }
177
179 {
188 int i;
189
192
193 memset(vps, 0, sizeof(*vps));
194 memset(sps, 0, sizeof(*sps));
195 memset(pps, 0, sizeof(*pps));
196
197
198 // VPS
199
202 .nuh_layer_id = 0,
203 .nuh_temporal_id_plus1 = 1,
204 };
205
207
213
216 .general_profile_idc = avctx->
profile,
217 .general_tier_flag = 0,
218
219 .general_progressive_source_flag = 1,
220 .general_interlaced_source_flag = 0,
221 .general_non_packed_constraint_flag = 1,
222 .general_frame_only_constraint_flag = 1,
223
224 .general_level_idc = avctx->
level,
225 };
227
232
236
243 } else {
247 }
249
250
251 // SPS
252
255 .nuh_layer_id = 0,
256 .nuh_temporal_id_plus1 = 1,
257 };
258
260
263
265
267
270
273
283 } else {
285 }
286
290
292
302 }
303
304 // These have to come from the capabilities of the encoder. We have no
305 // way to query them, so just hardcode parameters which work on the Intel
306 // driver.
307 // CTB size from 8x8 to 32x32.
310 // Transform size from 4x4 to 32x32.
313 // Full transform hierarchy allowed (2-5).
316 // AMP works.
318 // SAO and temporal MVP do not work.
321
323
324 // STRPSs should ideally be here rather than defined individually in
325 // each slice, but the structure isn't completely fixed so for now
326 // don't bother.
329
331
335 { 0, 0 },
336 { 1, 1 }, { 12, 11 }, { 10, 11 }, { 16, 11 },
337 { 40, 33 }, { 24, 11 }, { 20, 11 }, { 32, 11 },
338 { 80, 33 }, { 18, 11 }, { 15, 11 }, { 64, 33 },
339 { 160, 99 }, { 4, 3 }, { 3, 2 }, { 2, 1 },
340 };
341 int i;
346 break;
347 }
348 }
353 }
355 }
356
365
373 }
374 } else {
380 }
381
387 }
388
395
403
404
405 // PPS
406
409 .nuh_layer_id = 0,
410 .nuh_temporal_id_plus1 = 1,
411 };
412
415
418
420
423
425
426
427 // Fill VAAPI parameter buffers.
428
429 *vseq = (VAEncSequenceParameterBufferHEVC) {
433
435 .intra_idr_period = avctx->
gop_size,
438
441
442 .seq_fields.bits = {
448 .strong_intra_smoothing_enabled_flag =
451 .sample_adaptive_offset_enabled_flag =
456 },
457
458 .log2_min_luma_coding_block_size_minus3 =
460 .log2_diff_max_min_luma_coding_block_size =
462 .log2_min_transform_block_size_minus2 =
464 .log2_diff_max_min_transform_block_size =
466 .max_transform_hierarchy_depth_inter =
468 .max_transform_hierarchy_depth_intra =
470
471 .pcm_sample_bit_depth_luma_minus1 =
473 .pcm_sample_bit_depth_chroma_minus1 =
475 .log2_min_pcm_luma_coding_block_size_minus3 =
477 .log2_max_pcm_luma_coding_block_size_minus3 =
480
481 .vui_parameters_present_flag = 0,
482 };
483
484 *vpic = (VAEncPictureParameterBufferHEVC) {
485 .decoded_curr_pic = {
486 .picture_id = VA_INVALID_ID,
487 .flags = VA_PICTURE_HEVC_INVALID,
488 },
489
490 .coded_buf = VA_INVALID_ID,
491
492 .collocated_ref_pic_index = 0xff,
493
494 .last_picture = 0,
495
500
503
505 .ctu_max_bitsize_allowed = 0,
506
507 .num_ref_idx_l0_default_active_minus1 =
509 .num_ref_idx_l1_default_active_minus1 =
511
513
514 .pic_fields.bits = {
524 .loop_filter_across_tiles_enabled_flag =
528 .screen_content_flag = 0,
529 .enable_gpu_weighted_prediction = 0,
530 .no_output_of_prior_pics_flag = 0,
531 },
532 };
533
534 return 0;
535 }
536
539 {
544 int i;
545
548
550
554 } else {
556
566 } else {
570 else
574 }
575 }
577
582 .nuh_layer_id = 0,
583 .nuh_temporal_id_plus1 = 1,
584 };
586 } else {
588 }
589
590 vpic->decoded_curr_pic = (VAPictureHEVC) {
593 .flags = 0,
594 };
595
596 for (i = 0; i < pic->
nb_refs; i++) {
599
600 vpic->reference_frames[i] = (VAPictureHEVC) {
604 VA_PICTURE_HEVC_RPS_ST_CURR_BEFORE : 0) |
606 VA_PICTURE_HEVC_RPS_ST_CURR_AFTER : 0),
607 };
608 }
610 vpic->reference_frames[i] = (VAPictureHEVC) {
611 .picture_id = VA_INVALID_ID,
612 .flags = VA_PICTURE_HEVC_INVALID,
613 };
614 }
615
617
619
622 vpic->pic_fields.bits.idr_pic_flag = 1;
623 vpic->pic_fields.bits.coding_type = 1;
624 vpic->pic_fields.bits.reference_pic_flag = 1;
625 break;
627 vpic->pic_fields.bits.idr_pic_flag = 0;
628 vpic->pic_fields.bits.coding_type = 1;
629 vpic->pic_fields.bits.reference_pic_flag = 1;
630 break;
632 vpic->pic_fields.bits.idr_pic_flag = 0;
633 vpic->pic_fields.bits.coding_type = 2;
634 vpic->pic_fields.bits.reference_pic_flag = 1;
635 break;
637 vpic->pic_fields.bits.idr_pic_flag = 0;
638 vpic->pic_fields.bits.coding_type = 3;
639 vpic->pic_fields.bits.reference_pic_flag = 0;
640 break;
641 default:
643 }
644
646
647 return 0;
648 }
649
653 {
661 int i;
662
665 .nuh_layer_id = 0,
666 .nuh_temporal_id_plus1 = 1,
667 };
668
670
671 // Currently we only support one slice per frame.
674
676
679
683 int used;
684
686
688 memset(rps, 0, sizeof(*rps));
689
692 // Not yet in DPB.
693 continue;
694 }
695 used = 0;
696 for (i = 0; i < pic->
nb_refs; i++) {
697 if (pic->
refs[i] == st)
698 used = 1;
699 }
700 if (!used) {
701 // Usually each picture always uses all of the others in the
702 // DPB as references. The one case we have to treat here is
703 // a non-IDR IRAP picture, which may need to hold unused
704 // references across itself to be used for the decoding of
705 // following RASL pictures. This looks for such an RASL
706 // picture, and keeps the reference if there is one.
710 continue;
712 continue;
713 if (rp->
refs[0] == st && rp->
refs[1] == pic)
714 break;
715 }
716 if (!rp)
717 continue;
718 }
719 // This only works for one instance of each (delta_poc_sN_minus1
720 // is relative to the previous frame in the list, not relative to
721 // the current frame directly).
727 } else {
732 }
733 }
734
737
743 }
744
748 }
749
752
757 else
759
760
761 *vslice = (VAEncSliceParameterBufferHEVC) {
764
767
770
773
775
779
782
783 .slice_fields.bits = {
784 .last_slice_of_pic_flag = 1,
787 .slice_temporal_mvp_enabled_flag =
791 .num_ref_idx_active_override_flag =
795 .slice_deblocking_filter_disabled_flag =
797 .slice_loop_filter_across_slices_enabled_flag =
800 },
801 };
802
804 vslice->ref_pic_list0[i].picture_id = VA_INVALID_ID;
805 vslice->ref_pic_list0[i].flags = VA_PICTURE_HEVC_INVALID;
806 vslice->ref_pic_list1[i].picture_id = VA_INVALID_ID;
807 vslice->ref_pic_list1[i].flags = VA_PICTURE_HEVC_INVALID;
808 }
809
812 // Backward reference for P- or B-frame.
815 vslice->ref_pic_list0[0] = vpic->reference_frames[0];
816 }
818 // Forward reference for B-frame.
820 vslice->ref_pic_list1[0] = vpic->reference_frames[1];
821 }
822
823 return 0;
824 }
825
827 {
831 int err;
832
834 if (err < 0)
835 return err;
836
839
843
849 else
854 else
856
858 "%d / %d / %d for IDR- / P- / B-frames.\n",
860
863 // These still need to be set for pic_init_qp/slice_qp_delta.
867
869 ctx->
va_rc_mode == VA_RC_CBR ?
"constant" :
"variable",
871
872 } else {
874 }
875
876 return 0;
877 }
878
881
883
884 .sequence_params_size = sizeof(VAEncSequenceParameterBufferHEVC),
886
887 .picture_params_size = sizeof(VAEncPictureParameterBufferHEVC),
889
890 .slice_params_size = sizeof(VAEncSliceParameterBufferHEVC),
892
893 .sequence_header_type = VAEncPackedHeaderSequence,
895
896 .slice_header_type = VAEncPackedHeaderHEVC_Slice,
898 };
899
901 {
905
906 ctx->
codec = &vaapi_encode_type_h265;
907
912
918 break;
920 #ifdef VA_RT_FORMAT_YUV420_10BPP
923 break;
924 #else
926 "supported with this VAAPI version.\n");
928 #endif
929 default:
933 }
935
939 else
941 } else
943
945 VA_ENC_PACKED_HEADER_SEQUENCE | // VPS, SPS and PPS.
946 VA_ENC_PACKED_HEADER_SLICE; // Slice headers.
947
950
952 }
953
955 {
958
959 if (priv)
961
963 }
964
965 #define OFFSET(x) (offsetof(VAAPIEncodeContext, codec_options_data) + \
966 offsetof(VAAPIEncodeH265Options, x))
967 #define FLAGS (AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM)
969 { "qp", "Constant QP (for P-frames; scaled by qfactor/qoffset for I/B)",
971
972 { "aud", "Include AUD",
974
975 { "profile", "Set profile (general_profile_idc)",
978
979 #define PROFILE(name, value) name, NULL, 0, AV_OPT_TYPE_CONST, \
980 { .i64 = value }, 0, 0, FLAGS, "profile"
983 #undef PROFILE
984
985 { "level", "Set level (general_level_idc)",
987 { .i64 = 153 }, 0x00, 0xff,
FLAGS,
"level" },
988
989 #define LEVEL(name, value) name, NULL, 0, AV_OPT_TYPE_CONST, \
990 { .i64 = value }, 0, 0, FLAGS, "level"
993 {
LEVEL(
"2.1", 63) },
995 {
LEVEL(
"3.1", 93) },
997 {
LEVEL(
"4.1", 123) },
999 {
LEVEL(
"5.1", 153) },
1000 {
LEVEL(
"5.2", 156) },
1001 {
LEVEL(
"6", 180) },
1002 {
LEVEL(
"6.1", 183) },
1003 {
LEVEL(
"6.2", 186) },
1004 #undef LEVEL
1005
1007 };
1008
1010 { "b", "0" },
1011 { "bf", "2" },
1012 { "g", "120" },
1013 { "i_qfactor", "1" },
1014 { "i_qoffset", "0" },
1015 { "b_qfactor", "6/5" },
1016 { "b_qoffset", "0" },
1018 };
1019
1025 };
1026
1028 .
name =
"hevc_vaapi",
1037 .priv_class = &vaapi_encode_h265_class,
1039 .
defaults = vaapi_encode_h265_defaults,
1043 },
1044 .wrapper_name = "vaapi",
1045 };
uint8_t sps_video_parameter_set_id
uint8_t loop_filter_across_tiles_enabled_flag
uint8_t transfer_characteristics
uint8_t pps_pic_parameter_set_id
uint8_t vps_poc_proportional_to_timing_flag
uint8_t num_ref_idx_l0_default_active_minus1
VAEntrypoint va_entrypoint
uint8_t log2_max_mv_length_horizontal
ptrdiff_t const GLvoid * data
uint8_t motion_vectors_over_pic_boundaries_flag
uint8_t sps_sub_layer_ordering_info_present_flag
char codec_options_data[0]
static int vaapi_encode_h265_add_nal(AVCodecContext *avctx, CodedBitstreamFragment *au, void *nal_unit)
int64_t bit_rate
the average bitrate
#define LIBAVUTIL_VERSION_INT
uint8_t bitstream_restriction_flag
uint8_t bit_depth_luma_minus8
static av_cold int init(AVCodecContext *avctx)
#define AV_CODEC_CAP_HARDWARE
Codec is backed by a hardware implementation.
uint8_t vui_timing_info_present_flag
int ff_cbs_init(CodedBitstreamContext **ctx_ptr, enum AVCodecID codec_id, void *log_ctx)
Create and initialise a new context for the given codec.
enum AVColorRange color_range
MPEG vs JPEG YUV range.
uint8_t sps_max_sub_layers_minus1
uint8_t sps_max_num_reorder_pics[HEVC_MAX_SUB_LAYERS]
const char * av_default_item_name(void *ptr)
Return the context name.
static const AVClass vaapi_encode_h265_class
uint8_t tiles_enabled_flag
int ff_cbs_insert_unit_content(CodedBitstreamContext *ctx, CodedBitstreamFragment *frag, int position, CodedBitstreamUnitType type, void *content, AVBufferRef *content_buf)
Insert a new unit into a fragment with the given content.
AVRational sample_aspect_ratio
sample aspect ratio (0 if unknown) That is the width of a pixel divided by the height of the pixel...
uint8_t restricted_ref_pic_lists_flag
H265RawProfileTierLevel profile_tier_level
static av_cold int vaapi_encode_h265_close(AVCodecContext *avctx)
CodedBitstreamContext * cbc
void * codec_sequence_params
uint8_t sample_adaptive_offset_enabled_flag
uint8_t vui_parameters_present_flag
uint8_t pcm_sample_bit_depth_luma_minus1
static const AVCodecDefault vaapi_encode_h265_defaults[]
uint8_t bit_depth_chroma_minus8
float i_quant_offset
qscale offset between P and I-frames
uint8_t general_profile_idc
uint8_t used_by_curr_pic_s0_flag[HEVC_MAX_REFS]
AVRational time_base
This is the fundamental unit of time (in seconds) in terms of which frame timestamps are represented...
unsigned int va_packed_headers
uint32_t vps_num_units_in_tick
uint8_t sign_data_hiding_enabled_flag
const char * class_name
The name of the class; usually it is the same name as the context structure type to which the AVClass...
uint16_t conf_win_right_offset
#define AV_CODEC_CAP_DELAY
Encoder or decoder requires flushing with NULL input at the end in order to give the complete and cor...
#define av_assert0(cond)
assert() equivalent, that is always enabled.
uint16_t pic_height_in_luma_samples
uint8_t vps_sub_layer_ordering_info_present_flag
float b_quant_factor
qscale factor between IP and B-frames If > 0 then the last P-frame quantizer will be used (q= lastp_q...
#define FF_PROFILE_HEVC_MAIN
uint8_t vps_timing_info_present_flag
uint8_t log2_max_pic_order_cnt_lsb_minus4
uint8_t constrained_intra_pred_flag
uint32_t sps_max_latency_increase_plus1[HEVC_MAX_SUB_LAYERS]
uint8_t matrix_coefficients
uint8_t aspect_ratio_info_present_flag
uint8_t vps_max_sub_layers_minus1
#define AV_LOG_VERBOSE
Detailed information.
VASurfaceID recon_surface
uint8_t log2_min_luma_transform_block_size_minus2
static const uint8_t header[24]
uint8_t sps_scaling_list_data_present_flag
uint8_t log2_min_pcm_luma_coding_block_size_minus3
static int vaapi_encode_h265_write_access_unit(AVCodecContext *avctx, char *data, size_t *data_len, CodedBitstreamFragment *au)
#define FF_PROFILE_HEVC_MAIN_10
uint8_t video_full_range_flag
enum AVChromaLocation chroma_sample_location
This defines the location of chroma samples.
uint8_t chroma_sample_loc_type_bottom_field
uint16_t vps_num_layer_sets_minus1
uint8_t video_signal_type_present_flag
size_t data_size
The number of bytes in the bitstream.
uint32_t vui_num_ticks_poc_diff_one_minus1
uint8_t vps_max_dec_pic_buffering_minus1[HEVC_MAX_SUB_LAYERS]
uint8_t log2_max_mv_length_vertical
uint8_t vps_video_parameter_set_id
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
void ff_cbs_fragment_uninit(CodedBitstreamContext *ctx, CodedBitstreamFragment *frag)
Free all allocated memory in a fragment.
uint8_t conformance_window_flag
uint8_t max_bits_per_min_cu_denom
static av_cold int vaapi_encode_h265_init(AVCodecContext *avctx)
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
uint8_t chroma_loc_info_present_flag
#define PROFILE(name, value)
#define AV_LOG_DEBUG
Stuff which is only useful for libav* developers.
static int vaapi_encode_h265_init_sequence_params(AVCodecContext *avctx)
uint8_t num_negative_pics
simple assert() macros that are a bit more flexible than ISO C assert().
const char * name
Name of the codec implementation.
float i_quant_factor
qscale factor between P- and I-frames If > 0 then the last P-frame quantizer will be used (q = lastp_...
static const AVOption vaapi_encode_h265_options[]
static const AVCodecDefault defaults[]
uint8_t general_tier_flag
uint8_t transform_skip_enabled_flag
H265RawNALUnitHeader nal_unit_header
uint8_t pcm_sample_bit_depth_chroma_minus1
void * codec_picture_params
size_t data_bit_padding
The number of bits which should be ignored in the final byte.
uint8_t chroma_sample_loc_type_top_field
uint8_t vps_max_layers_minus1
static int vaapi_encode_h265_init_slice_params(AVCodecContext *avctx, VAAPIEncodePicture *pic, VAAPIEncodeSlice *slice)
uint16_t conf_win_bottom_offset
H265RawNALUnitHeader nal_unit_header
static const VAAPIEncodeType vaapi_encode_type_h265
uint8_t scaling_list_enabled_flag
H265RawProfileTierLevel profile_tier_level
uint8_t transquant_bypass_enabled_flag
int width
picture width / height.
uint32_t vps_max_latency_increase_plus1[HEVC_MAX_SUB_LAYERS]
uint8_t vui_hrd_parameters_present_flag
uint16_t delta_poc_s1_minus1[HEVC_MAX_REFS]
uint8_t diff_cu_qp_delta_depth
#define FF_PROFILE_UNKNOWN
av_cold int ff_vaapi_encode_init(AVCodecContext *avctx)
AVCodec ff_hevc_vaapi_encoder
uint8_t sps_seq_parameter_set_id
enum AVColorPrimaries color_primaries
Chromaticity coordinates of the source primaries.
unsigned int va_rt_format
struct VAAPIEncodePicture * next
uint16_t pic_width_in_luma_samples
void * codec_picture_params
static int vaapi_encode_h265_init_picture_params(AVCodecContext *avctx, VAAPIEncodePicture *pic)
uint8_t vps_base_layer_available_flag
uint8_t log2_min_luma_coding_block_size_minus3
uint8_t * data
Pointer to the bitstream form of this fragment.
uint8_t pps_seq_parameter_set_id
#define FF_ARRAY_ELEMS(a)
the normal 2^n-1 "JPEG" YUV ranges
int ff_cbs_write_fragment_data(CodedBitstreamContext *ctx, CodedBitstreamFragment *frag)
Write the content of the fragment to its own internal buffer.
uint16_t vps_num_hrd_parameters
struct VAAPIEncodePicture * refs[MAX_PICTURE_REFERENCES]
uint8_t used_by_curr_pic_s1_flag[HEVC_MAX_REFS]
uint8_t max_bytes_per_pic_denom
H265RawNALUnitHeader nal_unit_header
static int vaapi_encode_h265_write_slice_header(AVCodecContext *avctx, VAAPIEncodePicture *pic, VAAPIEncodeSlice *slice, char *data, size_t *data_len)
const struct VAAPIEncodeType * codec
uint8_t log2_diff_max_min_pcm_luma_coding_block_size
Libavcodec external API header.
uint8_t entropy_coding_sync_enabled_flag
uint8_t weighted_bipred_flag
uint16_t conf_win_top_offset
uint8_t sps_temporal_mvp_enabled_flag
VAAPIEncodePicture * pic_start
Coded bitstream fragment structure, combining one or more units.
uint8_t general_level_idc
main external API structure.
uint32_t vui_num_units_in_tick
uint8_t max_transform_hierarchy_depth_intra
uint8_t pps_loop_filter_across_slices_enabled_flag
uint8_t weighted_pred_flag
uint8_t sps_temporal_id_nesting_flag
static int FUNC() aud(CodedBitstreamContext *ctx, RWContext *rw, H264RawAUD *current)
uint16_t conf_win_left_offset
Describe the class of an AVClass context structure.
static int FUNC() pps(CodedBitstreamContext *ctx, RWContext *rw, H264RawPPS *current)
Context structure for coded bitstream operations.
enum AVColorSpace colorspace
YUV colorspace type.
Rational number (pair of numerator and denominator).
enum AVColorTransferCharacteristic color_trc
Color Transfer Characteristic.
static int FUNC() sps(CodedBitstreamContext *ctx, RWContext *rw, H264RawSPS *current)
uint8_t chroma_format_idc
void ff_cbs_close(CodedBitstreamContext **ctx_ptr)
Close a context and free all internal state.
float b_quant_offset
qscale offset between IP and B-frames
uint8_t general_profile_compatibility_flag[32]
uint8_t vps_base_layer_internal_flag
static enum AVPixelFormat pix_fmts[]
static int FUNC() vps(CodedBitstreamContext *ctx, RWContext *rw, H265RawVPS *current)
uint8_t pcm_loop_filter_disabled_flag
H265RawNALUnitHeader nal_unit_header
static int vaapi_encode_h265_write_sequence_header(AVCodecContext *avctx, char *data, size_t *data_len)
uint8_t num_positive_pics
int gop_size
the number of pictures in a group of pictures, or 0 for intra_only
uint8_t vui_poc_proportional_to_timing_flag
uint8_t max_transform_hierarchy_depth_inter
static av_cold int vaapi_encode_h265_configure(AVCodecContext *avctx)
common internal api header.
common internal and external API header
static int ref[MAX_W *MAX_W]
uint8_t pps_scaling_list_data_present_flag
uint8_t num_tile_rows_minus1
int ff_vaapi_encode2(AVCodecContext *avctx, AVPacket *pkt, const AVFrame *input_image, int *got_packet)
uint8_t num_tile_columns_minus1
uint16_t delta_poc_s0_minus1[HEVC_MAX_REFS]
uint8_t log2_diff_max_min_luma_coding_block_size
CodedBitstreamFragment current_access_unit
uint8_t vps_max_num_reorder_pics[HEVC_MAX_SUB_LAYERS]
H265RawSliceHeader header
uint8_t num_short_term_ref_pic_sets
void * codec_slice_params
uint8_t log2_parallel_merge_level_minus2
uint8_t vps_temporal_id_nesting_flag
#define LEVEL(name, value)
uint8_t general_profile_space
uint8_t sps_max_dec_pic_buffering_minus1[HEVC_MAX_SUB_LAYERS]
uint32_t vps_num_ticks_poc_diff_one_minus1
uint8_t separate_colour_plane_flag
uint8_t strong_intra_smoothing_enabled_flag
uint8_t colour_description_present_flag
AVPixelFormat
Pixel format.
uint8_t log2_diff_max_min_luma_transform_block_size
uint8_t long_term_ref_pics_present_flag
uint8_t layer_id_included_flag[HEVC_MAX_LAYER_SETS][HEVC_MAX_LAYERS]
av_cold int ff_vaapi_encode_close(AVCodecContext *avctx)
int64_t rc_max_rate
maximum bitrate
uint8_t num_ref_idx_l1_default_active_minus1
uint8_t cu_qp_delta_enabled_flag