FFmpeg
vaapi_encode_vp9.c
Go to the documentation of this file.
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 <va/va.h>
20 #include <va/va_enc_vp9.h>
21 
22 #include "libavutil/avassert.h"
23 #include "libavutil/common.h"
24 #include "libavutil/internal.h"
25 #include "libavutil/opt.h"
26 #include "libavutil/pixfmt.h"
27 
28 #include "avcodec.h"
29 #include "codec_internal.h"
30 #include "vaapi_encode.h"
31 
32 #define VP9_MAX_QUANT 255
33 
34 #define VP9_MAX_TILE_WIDTH 4096
35 
36 typedef struct VAAPIEncodeVP9Picture {
37  int slot;
39 
40 typedef struct VAAPIEncodeVP9Context {
42 
43  // User options.
46 
47  // Derived settings.
48  int q_idx_idr;
49  int q_idx_p;
50  int q_idx_b;
52 
53 
55 {
57  VAEncSequenceParameterBufferVP9 *vseq = ctx->codec_sequence_params;
58  VAEncPictureParameterBufferVP9 *vpic = ctx->codec_picture_params;
59 
60  vseq->max_frame_width = avctx->width;
61  vseq->max_frame_height = avctx->height;
62 
63  vseq->kf_auto = 0;
64 
65  if (!(ctx->va_rc_mode & VA_RC_CQP)) {
66  vseq->bits_per_second = ctx->va_bit_rate;
67  vseq->intra_period = ctx->gop_size;
68  }
69 
70  vpic->frame_width_src = avctx->width;
71  vpic->frame_height_src = avctx->height;
72  vpic->frame_width_dst = avctx->width;
73  vpic->frame_height_dst = avctx->height;
74 
75  return 0;
76 }
77 
79  VAAPIEncodePicture *pic)
80 {
82  VAAPIEncodeVP9Context *priv = avctx->priv_data;
83  VAAPIEncodeVP9Picture *hpic = pic->priv_data;
84  VAEncPictureParameterBufferVP9 *vpic = pic->codec_picture_params;
85  int i;
86  int num_tile_columns;
87 
88  vpic->reconstructed_frame = pic->recon_surface;
89  vpic->coded_buf = pic->output_buffer;
90 
91  // Maximum width of a tile in units of superblocks is MAX_TILE_WIDTH_B64(64)
92  // So the number of tile columns is related to the width of the picture.
93  // We set the minimum possible number for num_tile_columns as default value.
94  num_tile_columns = (vpic->frame_width_src + VP9_MAX_TILE_WIDTH - 1) / VP9_MAX_TILE_WIDTH;
95  vpic->log2_tile_columns = num_tile_columns == 1 ? 0 : av_log2(num_tile_columns - 1) + 1;
96 
97  switch (pic->type) {
98  case PICTURE_TYPE_IDR:
99  av_assert0(pic->nb_refs[0] == 0 && pic->nb_refs[1] == 0);
100  vpic->ref_flags.bits.force_kf = 1;
101  vpic->refresh_frame_flags = 0xff;
102  hpic->slot = 0;
103  break;
104  case PICTURE_TYPE_P:
105  av_assert0(!pic->nb_refs[1]);
106  {
107  VAAPIEncodeVP9Picture *href = pic->refs[0][0]->priv_data;
108  av_assert0(href->slot == 0 || href->slot == 1);
109 
110  if (ctx->max_b_depth > 0) {
111  hpic->slot = !href->slot;
112  vpic->refresh_frame_flags = 1 << hpic->slot | 0xfc;
113  } else {
114  hpic->slot = 0;
115  vpic->refresh_frame_flags = 0xff;
116  }
117  vpic->ref_flags.bits.ref_frame_ctrl_l0 = 1;
118  vpic->ref_flags.bits.ref_last_idx = href->slot;
119  vpic->ref_flags.bits.ref_last_sign_bias = 1;
120  }
121  break;
122  case PICTURE_TYPE_B:
123  av_assert0(pic->nb_refs[0] && pic->nb_refs[1]);
124  {
125  VAAPIEncodeVP9Picture *href0 = pic->refs[0][0]->priv_data,
126  *href1 = pic->refs[1][0]->priv_data;
127  av_assert0(href0->slot < pic->b_depth + 1 &&
128  href1->slot < pic->b_depth + 1);
129 
130  if (pic->b_depth == ctx->max_b_depth) {
131  // Unreferenced frame.
132  vpic->refresh_frame_flags = 0x00;
133  hpic->slot = 8;
134  } else {
135  vpic->refresh_frame_flags = 0xfe << pic->b_depth & 0xff;
136  hpic->slot = 1 + pic->b_depth;
137  }
138  vpic->ref_flags.bits.ref_frame_ctrl_l0 = 1;
139  vpic->ref_flags.bits.ref_frame_ctrl_l1 = 2;
140  vpic->ref_flags.bits.ref_last_idx = href0->slot;
141  vpic->ref_flags.bits.ref_last_sign_bias = 1;
142  vpic->ref_flags.bits.ref_gf_idx = href1->slot;
143  vpic->ref_flags.bits.ref_gf_sign_bias = 0;
144  }
145  break;
146  default:
147  av_assert0(0 && "invalid picture type");
148  }
149  if (vpic->refresh_frame_flags == 0x00) {
150  av_log(avctx, AV_LOG_DEBUG, "Pic %"PRId64" not stored.\n",
151  pic->display_order);
152  } else {
153  av_log(avctx, AV_LOG_DEBUG, "Pic %"PRId64" stored in slot %d.\n",
154  pic->display_order, hpic->slot);
155  }
156 
157  for (i = 0; i < FF_ARRAY_ELEMS(vpic->reference_frames); i++)
158  vpic->reference_frames[i] = VA_INVALID_SURFACE;
159 
160  for (i = 0; i < MAX_REFERENCE_LIST_NUM; i++) {
161  for (int j = 0; j < pic->nb_refs[i]; j++) {
162  VAAPIEncodePicture *ref_pic = pic->refs[i][j];
163  int slot;
164  slot = ((VAAPIEncodeVP9Picture*)ref_pic->priv_data)->slot;
165  av_assert0(vpic->reference_frames[slot] == VA_INVALID_SURFACE);
166  vpic->reference_frames[slot] = ref_pic->recon_surface;
167  }
168  }
169 
170  vpic->pic_flags.bits.frame_type = (pic->type != PICTURE_TYPE_IDR);
171  vpic->pic_flags.bits.show_frame = pic->display_order <= pic->encode_order;
172 
173  if (pic->type == PICTURE_TYPE_IDR)
174  vpic->luma_ac_qindex = priv->q_idx_idr;
175  else if (pic->type == PICTURE_TYPE_P)
176  vpic->luma_ac_qindex = priv->q_idx_p;
177  else
178  vpic->luma_ac_qindex = priv->q_idx_b;
179  vpic->luma_dc_qindex_delta = 0;
180  vpic->chroma_ac_qindex_delta = 0;
181  vpic->chroma_dc_qindex_delta = 0;
182 
183  vpic->filter_level = priv->loop_filter_level;
184  vpic->sharpness_level = priv->loop_filter_sharpness;
185 
186  return 0;
187 }
188 
190 {
191  VAAPIEncodeContext *ctx = avctx->priv_data;
192 
193  // Surfaces must be aligned to 64x64 superblock boundaries.
194  ctx->surface_width = FFALIGN(avctx->width, 64);
195  ctx->surface_height = FFALIGN(avctx->height, 64);
196 
197  return 0;
198 }
199 
201 {
202  VAAPIEncodeContext *ctx = avctx->priv_data;
203  VAAPIEncodeVP9Context *priv = avctx->priv_data;
204 
205  if (ctx->rc_mode->quality) {
206  priv->q_idx_p = av_clip(ctx->rc_quality, 0, VP9_MAX_QUANT);
207  if (avctx->i_quant_factor > 0.0)
208  priv->q_idx_idr =
209  av_clip((avctx->i_quant_factor * priv->q_idx_p +
210  avctx->i_quant_offset) + 0.5,
211  0, VP9_MAX_QUANT);
212  else
213  priv->q_idx_idr = priv->q_idx_p;
214  if (avctx->b_quant_factor > 0.0)
215  priv->q_idx_b =
216  av_clip((avctx->b_quant_factor * priv->q_idx_p +
217  avctx->b_quant_offset) + 0.5,
218  0, VP9_MAX_QUANT);
219  else
220  priv->q_idx_b = priv->q_idx_p;
221  } else {
222  // Arbitrary value.
223  priv->q_idx_idr = priv->q_idx_p = priv->q_idx_b = 100;
224  }
225 
226  ctx->roi_quant_range = VP9_MAX_QUANT;
227 
228  return 0;
229 }
230 
232  { AV_PROFILE_VP9_0, 8, 3, 1, 1, VAProfileVP9Profile0 },
233  { AV_PROFILE_VP9_1, 8, 3, 0, 0, VAProfileVP9Profile1 },
234  { AV_PROFILE_VP9_2, 10, 3, 1, 1, VAProfileVP9Profile2 },
235  { AV_PROFILE_VP9_3, 10, 3, 0, 0, VAProfileVP9Profile3 },
237 };
238 
241 
242  .flags = FLAG_B_PICTURES |
244 
245  .default_quality = 100,
246 
247  .picture_priv_data_size = sizeof(VAAPIEncodeVP9Picture),
248 
249  .get_encoder_caps = &vaapi_encode_vp9_get_encoder_caps,
250  .configure = &vaapi_encode_vp9_configure,
251 
252  .sequence_params_size = sizeof(VAEncSequenceParameterBufferVP9),
253  .init_sequence_params = &vaapi_encode_vp9_init_sequence_params,
254 
255  .picture_params_size = sizeof(VAEncPictureParameterBufferVP9),
256  .init_picture_params = &vaapi_encode_vp9_init_picture_params,
257 };
258 
260 {
261  VAAPIEncodeContext *ctx = avctx->priv_data;
262 
263  ctx->codec = &vaapi_encode_type_vp9;
264 
265  // No packed headers are currently desired. They could be written,
266  // but there isn't any reason to do so - the one usable driver (i965)
267  // can write its own headers and there is no metadata to include.
268  ctx->desired_packed_headers = 0;
269 
270  return ff_vaapi_encode_init(avctx);
271 }
272 
273 #define OFFSET(x) offsetof(VAAPIEncodeVP9Context, x)
274 #define FLAGS (AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM)
278 
279  { "loop_filter_level", "Loop filter level",
280  OFFSET(loop_filter_level), AV_OPT_TYPE_INT, { .i64 = 16 }, 0, 63, FLAGS },
281  { "loop_filter_sharpness", "Loop filter sharpness",
282  OFFSET(loop_filter_sharpness), AV_OPT_TYPE_INT, { .i64 = 4 }, 0, 15, FLAGS },
283  { NULL },
284 };
285 
287  { "b", "0" },
288  { "bf", "0" },
289  { "g", "250" },
290  { "qmin", "-1" },
291  { "qmax", "-1" },
292  { NULL },
293 };
294 
296  .class_name = "vp9_vaapi",
297  .item_name = av_default_item_name,
298  .option = vaapi_encode_vp9_options,
299  .version = LIBAVUTIL_VERSION_INT,
300 };
301 
303  .p.name = "vp9_vaapi",
304  CODEC_LONG_NAME("VP9 (VAAPI)"),
305  .p.type = AVMEDIA_TYPE_VIDEO,
306  .p.id = AV_CODEC_ID_VP9,
307  .priv_data_size = sizeof(VAAPIEncodeVP9Context),
310  .close = &ff_vaapi_encode_close,
311  .p.priv_class = &vaapi_encode_vp9_class,
312  .p.capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_HARDWARE |
314  .caps_internal = FF_CODEC_CAP_NOT_INIT_THREADSAFE |
316  .defaults = vaapi_encode_vp9_defaults,
317  .p.pix_fmts = (const enum AVPixelFormat[]) {
320  },
321  .hw_configs = ff_vaapi_encode_hw_configs,
322  .p.wrapper_name = "vaapi",
323 };
AVPixelFormat
AVPixelFormat
Pixel format.
Definition: pixfmt.h:71
av_clip
#define av_clip
Definition: common.h:98
FF_CODEC_CAP_INIT_CLEANUP
#define FF_CODEC_CAP_INIT_CLEANUP
The codec allows calling the close function for deallocation even if the init function returned a fai...
Definition: codec_internal.h:42
opt.h
AV_CODEC_CAP_HARDWARE
#define AV_CODEC_CAP_HARDWARE
Codec is backed by a hardware implementation.
Definition: codec.h:145
vaapi_encode_vp9_configure
static av_cold int vaapi_encode_vp9_configure(AVCodecContext *avctx)
Definition: vaapi_encode_vp9.c:200
AV_PROFILE_VP9_1
#define AV_PROFILE_VP9_1
Definition: defs.h:154
VAAPIEncodeVP9Context
Definition: vaapi_encode_vp9.c:40
FLAG_B_PICTURES
@ FLAG_B_PICTURES
Definition: vaapi_encode.h:408
VAAPIEncodeVP9Context::loop_filter_sharpness
int loop_filter_sharpness
Definition: vaapi_encode_vp9.c:45
AVOption
AVOption.
Definition: opt.h:346
vaapi_encode_vp9_init_picture_params
static int vaapi_encode_vp9_init_picture_params(AVCodecContext *avctx, VAAPIEncodePicture *pic)
Definition: vaapi_encode_vp9.c:78
AVCodecContext::b_quant_offset
float b_quant_offset
qscale offset between IP and B-frames
Definition: avcodec.h:811
FF_CODEC_CAP_NOT_INIT_THREADSAFE
#define FF_CODEC_CAP_NOT_INIT_THREADSAFE
The codec is not known to be init-threadsafe (i.e.
Definition: codec_internal.h:34
FFCodec
Definition: codec_internal.h:127
ff_vaapi_encode_close
av_cold int ff_vaapi_encode_close(AVCodecContext *avctx)
Definition: vaapi_encode.c:2982
FLAG_B_PICTURE_REFERENCES
@ FLAG_B_PICTURE_REFERENCES
Definition: vaapi_encode.h:410
VP9_MAX_QUANT
#define VP9_MAX_QUANT
Definition: vaapi_encode_vp9.c:32
PICTURE_TYPE_IDR
@ PICTURE_TYPE_IDR
Definition: vaapi_encode.h:58
VAAPIEncodeVP9Picture
Definition: vaapi_encode_vp9.c:36
VAAPIEncodePicture::refs
struct VAAPIEncodePicture * refs[MAX_REFERENCE_LIST_NUM][MAX_PICTURE_REFERENCES]
Definition: vaapi_encode.h:125
VAAPIEncodePicture::nb_refs
int nb_refs[MAX_REFERENCE_LIST_NUM]
Definition: vaapi_encode.h:124
AVCodecContext::i_quant_factor
float i_quant_factor
qscale factor between P- and I-frames If > 0 then the last P-frame quantizer will be used (q = lastp_...
Definition: avcodec.h:820
FFCodecDefault
Definition: codec_internal.h:97
FFCodec::p
AVCodec p
The public AVCodec.
Definition: codec_internal.h:131
vaapi_encode.h
VAAPIEncodePicture
Definition: vaapi_encode.h:73
AV_PROFILE_VP9_3
#define AV_PROFILE_VP9_3
Definition: defs.h:156
VP9_MAX_TILE_WIDTH
#define VP9_MAX_TILE_WIDTH
Definition: vaapi_encode_vp9.c:34
avassert.h
vaapi_encode_vp9_init
static av_cold int vaapi_encode_vp9_init(AVCodecContext *avctx)
Definition: vaapi_encode_vp9.c:259
FF_ARRAY_ELEMS
#define FF_ARRAY_ELEMS(a)
Definition: sinewin_tablegen.c:29
av_cold
#define av_cold
Definition: attributes.h:90
AV_PROFILE_UNKNOWN
#define AV_PROFILE_UNKNOWN
Definition: defs.h:65
VAAPIEncodePicture::codec_picture_params
void * codec_picture_params
Definition: vaapi_encode.h:111
AV_CODEC_ID_VP9
@ AV_CODEC_ID_VP9
Definition: codec_id.h:220
MAX_REFERENCE_LIST_NUM
@ MAX_REFERENCE_LIST_NUM
Definition: vaapi_encode.h:52
AV_CODEC_CAP_ENCODER_REORDERED_OPAQUE
#define AV_CODEC_CAP_ENCODER_REORDERED_OPAQUE
This encoder can reorder user opaque values from input AVFrames and return them with corresponding ou...
Definition: codec.h:159
av_assert0
#define av_assert0(cond)
assert() equivalent, that is always enabled.
Definition: avassert.h:40
OFFSET
#define OFFSET(x)
Definition: vaapi_encode_vp9.c:273
AV_LOG_DEBUG
#define AV_LOG_DEBUG
Stuff which is only useful for libav* developers.
Definition: log.h:201
ctx
AVFormatContext * ctx
Definition: movenc.c:48
VAAPIEncodeVP9Context::q_idx_p
int q_idx_p
Definition: vaapi_encode_vp9.c:49
vaapi_encode_type_vp9
static const VAAPIEncodeType vaapi_encode_type_vp9
Definition: vaapi_encode_vp9.c:239
ff_vaapi_encode_receive_packet
int ff_vaapi_encode_receive_packet(AVCodecContext *avctx, AVPacket *pkt)
Definition: vaapi_encode.c:1396
VAAPIEncodeType
Definition: vaapi_encode.h:419
CODEC_LONG_NAME
#define CODEC_LONG_NAME(str)
Definition: codec_internal.h:272
VAAPIEncodeContext
Definition: vaapi_encode.h:195
FLAGS
#define FLAGS
Definition: vaapi_encode_vp9.c:274
LIBAVUTIL_VERSION_INT
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
AVClass
Describe the class of an AVClass context structure.
Definition: log.h:66
NULL
#define NULL
Definition: coverity.c:32
vaapi_encode_vp9_profiles
static const VAAPIEncodeProfile vaapi_encode_vp9_profiles[]
Definition: vaapi_encode_vp9.c:231
VAAPIEncodeVP9Context::common
VAAPIEncodeContext common
Definition: vaapi_encode_vp9.c:41
VAAPIEncodeType::profiles
const VAAPIEncodeProfile * profiles
Definition: vaapi_encode.h:422
FF_CODEC_RECEIVE_PACKET_CB
#define FF_CODEC_RECEIVE_PACKET_CB(func)
Definition: codec_internal.h:302
av_default_item_name
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:237
VAAPIEncodeVP9Context::q_idx_idr
int q_idx_idr
Definition: vaapi_encode_vp9.c:48
vaapi_encode_vp9_init_sequence_params
static int vaapi_encode_vp9_init_sequence_params(AVCodecContext *avctx)
Definition: vaapi_encode_vp9.c:54
VAAPIEncodeVP9Picture::slot
int slot
Definition: vaapi_encode_vp9.c:37
VAAPIEncodeVP9Context::q_idx_b
int q_idx_b
Definition: vaapi_encode_vp9.c:50
init
int(* init)(AVBSFContext *ctx)
Definition: dts2pts.c:365
AV_CODEC_CAP_DR1
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() or get_encode_buffer() for allocating buffers and supports custom allocators.
Definition: codec.h:52
VAAPIEncodePicture::type
int type
Definition: vaapi_encode.h:92
codec_internal.h
VAAPI_ENCODE_RC_OPTIONS
#define VAAPI_ENCODE_RC_OPTIONS
Definition: vaapi_encode.h:532
for
for(k=2;k<=8;++k)
Definition: h264pred_template.c:425
VAAPI_ENCODE_COMMON_OPTIONS
#define VAAPI_ENCODE_COMMON_OPTIONS
Definition: vaapi_encode.h:505
VAAPIEncodePicture::recon_surface
VASurfaceID recon_surface
Definition: vaapi_encode.h:101
VAAPIEncodePicture::output_buffer
VABufferID output_buffer
Definition: vaapi_encode.h:108
VAAPIEncodePicture::priv_data
void * priv_data
Definition: vaapi_encode.h:110
ff_vp9_vaapi_encoder
const FFCodec ff_vp9_vaapi_encoder
Definition: vaapi_encode_vp9.c:302
VAAPIEncodePicture::display_order
int64_t display_order
Definition: vaapi_encode.h:76
AV_PIX_FMT_VAAPI
@ AV_PIX_FMT_VAAPI
Hardware acceleration through VA-API, data[3] contains a VASurfaceID.
Definition: pixfmt.h:126
VAAPIEncodePicture::b_depth
int b_depth
Definition: vaapi_encode.h:93
AVCodecContext::b_quant_factor
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...
Definition: avcodec.h:804
PICTURE_TYPE_B
@ PICTURE_TYPE_B
Definition: vaapi_encode.h:61
i
#define i(width, name, range_min, range_max)
Definition: cbs_h2645.c:255
VAAPIEncodeVP9Context::loop_filter_level
int loop_filter_level
Definition: vaapi_encode_vp9.c:44
internal.h
common.h
AVCodec::name
const char * name
Name of the codec implementation.
Definition: codec.h:194
AVCodecContext::height
int height
Definition: avcodec.h:618
vaapi_encode_vp9_get_encoder_caps
static av_cold int vaapi_encode_vp9_get_encoder_caps(AVCodecContext *avctx)
Definition: vaapi_encode_vp9.c:189
avcodec.h
ff_vaapi_encode_hw_configs
const AVCodecHWConfigInternal *const ff_vaapi_encode_hw_configs[]
Definition: vaapi_encode.c:35
AV_PROFILE_VP9_2
#define AV_PROFILE_VP9_2
Definition: defs.h:155
ff_vaapi_encode_init
av_cold int ff_vaapi_encode_init(AVCodecContext *avctx)
Definition: vaapi_encode.c:2773
pixfmt.h
AVClass::class_name
const char * class_name
The name of the class; usually it is the same name as the context structure type to which the AVClass...
Definition: log.h:71
AVCodecContext
main external API structure.
Definition: avcodec.h:445
AV_PIX_FMT_NONE
@ AV_PIX_FMT_NONE
Definition: pixfmt.h:72
AV_OPT_TYPE_INT
@ AV_OPT_TYPE_INT
Definition: opt.h:235
AVCodecContext::i_quant_offset
float i_quant_offset
qscale offset between P and I-frames
Definition: avcodec.h:827
AV_CODEC_CAP_DELAY
#define AV_CODEC_CAP_DELAY
Encoder or decoder requires flushing with NULL input at the end in order to give the complete and cor...
Definition: codec.h:76
AV_PROFILE_VP9_0
#define AV_PROFILE_VP9_0
Definition: defs.h:153
AVMEDIA_TYPE_VIDEO
@ AVMEDIA_TYPE_VIDEO
Definition: avutil.h:201
vaapi_encode_vp9_class
static const AVClass vaapi_encode_vp9_class
Definition: vaapi_encode_vp9.c:295
FFALIGN
#define FFALIGN(x, a)
Definition: macros.h:78
AVCodecContext::priv_data
void * priv_data
Definition: avcodec.h:472
VAAPIEncodePicture::encode_order
int64_t encode_order
Definition: vaapi_encode.h:77
AVCodecContext::width
int width
picture width / height.
Definition: avcodec.h:618
av_log
#define av_log(a,...)
Definition: tableprint_vlc.h:27
vaapi_encode_vp9_defaults
static const FFCodecDefault vaapi_encode_vp9_defaults[]
Definition: vaapi_encode_vp9.c:286
PICTURE_TYPE_P
@ PICTURE_TYPE_P
Definition: vaapi_encode.h:60
vaapi_encode_vp9_options
static const AVOption vaapi_encode_vp9_options[]
Definition: vaapi_encode_vp9.c:275
av_log2
int av_log2(unsigned v)
Definition: intmath.c:26
VAAPIEncodeProfile
Definition: vaapi_encode.h:150