2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved.
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
14 #include "vpx/vpx_decoder.h"
15 #include "vpx/vp8dx.h"
16 #include "vpx/internal/vpx_codec_internal.h"
17 #include "./vpx_version.h"
18 #include "vp9/common/vp9_frame_buffers.h"
19 #include "vp9/decoder/vp9_onyxd.h"
20 #include "vp9/decoder/vp9_onyxd_int.h"
21 #include "vp9/decoder/vp9_read_bit_buffer.h"
22 #include "vp9/vp9_iface_common.h"
24 #define VP9_CAP_POSTPROC (CONFIG_VP9_POSTPROC ? VPX_CODEC_CAP_POSTPROC : 0)
25 typedef vpx_codec_stream_info_t vp9_stream_info_t;
27 /* Structures for handling memory allocations */
29 VP9_SEG_ALG_PRIV = 256,
32 #define NELEMENTS(x) ((int)(sizeof(x)/sizeof(x[0])))
34 static unsigned long priv_sz(const vpx_codec_dec_cfg_t *si,
35 vpx_codec_flags_t flags);
37 static const mem_req_t vp9_mem_req_segs[] = {
38 {VP9_SEG_ALG_PRIV, 0, 8, VPX_CODEC_MEM_ZERO, priv_sz},
39 {VP9_SEG_MAX, 0, 0, 0, NULL}
42 struct vpx_codec_alg_priv {
43 vpx_codec_priv_t base;
44 vpx_codec_mmap_t mmaps[NELEMENTS(vp9_mem_req_segs) - 1];
45 vpx_codec_dec_cfg_t cfg;
51 vp8_postproc_cfg_t postproc_cfg;
52 #if CONFIG_POSTPROC_VISUALIZER
53 unsigned int dbg_postproc_flag;
54 int dbg_color_ref_frame_flag;
55 int dbg_color_mb_modes_flag;
56 int dbg_color_b_modes_flag;
57 int dbg_display_mv_flag;
62 int invert_tile_order;
64 // External frame buffer info to save for VP9 common.
65 void *ext_priv; // Private data associated with the external frame buffers.
66 vpx_get_frame_buffer_cb_fn_t get_ext_fb_cb;
67 vpx_release_frame_buffer_cb_fn_t release_ext_fb_cb;
70 static unsigned long priv_sz(const vpx_codec_dec_cfg_t *si,
71 vpx_codec_flags_t flags) {
72 /* Although this declaration is constant, we can't use it in the requested
73 * segments list because we want to define the requested segments list
74 * before defining the private type (so that the number of memory maps is
78 return sizeof(vpx_codec_alg_priv_t);
81 static void vp9_init_ctx(vpx_codec_ctx_t *ctx, const vpx_codec_mmap_t *mmap) {
84 ctx->priv = mmap->base;
85 ctx->priv->sz = sizeof(*ctx->priv);
86 ctx->priv->iface = ctx->iface;
87 ctx->priv->alg_priv = mmap->base;
89 for (i = 0; i < NELEMENTS(ctx->priv->alg_priv->mmaps); i++)
90 ctx->priv->alg_priv->mmaps[i].id = vp9_mem_req_segs[i].id;
92 ctx->priv->alg_priv->mmaps[0] = *mmap;
93 ctx->priv->alg_priv->si.sz = sizeof(ctx->priv->alg_priv->si);
94 ctx->priv->init_flags = ctx->init_flags;
96 if (ctx->config.dec) {
97 /* Update the reference to the config structure to an internal copy. */
98 ctx->priv->alg_priv->cfg = *ctx->config.dec;
99 ctx->config.dec = &ctx->priv->alg_priv->cfg;
103 static void vp9_finalize_mmaps(vpx_codec_alg_priv_t *ctx) {
104 /* nothing to clean up */
107 static vpx_codec_err_t vp9_init(vpx_codec_ctx_t *ctx,
108 vpx_codec_priv_enc_mr_cfg_t *data) {
109 vpx_codec_err_t res = VPX_CODEC_OK;
111 // This function only allocates space for the vpx_codec_alg_priv_t
112 // structure. More memory may be required at the time the stream
113 // information becomes known.
115 vpx_codec_mmap_t mmap;
117 mmap.id = vp9_mem_req_segs[0].id;
118 mmap.sz = sizeof(vpx_codec_alg_priv_t);
119 mmap.align = vp9_mem_req_segs[0].align;
120 mmap.flags = vp9_mem_req_segs[0].flags;
122 res = vpx_mmap_alloc(&mmap);
124 vp9_init_ctx(ctx, &mmap);
126 ctx->priv->alg_priv->defer_alloc = 1;
133 static vpx_codec_err_t vp9_destroy(vpx_codec_alg_priv_t *ctx) {
136 vp9_remove_decompressor(ctx->pbi);
138 for (i = NELEMENTS(ctx->mmaps) - 1; i >= 0; i--) {
139 if (ctx->mmaps[i].dtor)
140 ctx->mmaps[i].dtor(&ctx->mmaps[i]);
146 static vpx_codec_err_t vp9_peek_si(const uint8_t *data, unsigned int data_sz,
147 vpx_codec_stream_info_t *si) {
148 if (data_sz <= 8) return VPX_CODEC_UNSUP_BITSTREAM;
149 if (data + data_sz <= data) return VPX_CODEC_INVALID_PARAM;
155 struct vp9_read_bit_buffer rb = { data, data + data_sz, 0, NULL, NULL };
156 const int frame_marker = vp9_rb_read_literal(&rb, 2);
157 const int version = vp9_rb_read_bit(&rb);
158 (void) vp9_rb_read_bit(&rb); // unused version bit
160 if (frame_marker != VP9_FRAME_MARKER)
161 return VPX_CODEC_UNSUP_BITSTREAM;
163 if (version > 1) return VPX_CODEC_UNSUP_BITSTREAM;
165 if (version != 0) return VPX_CODEC_UNSUP_BITSTREAM;
168 if (vp9_rb_read_bit(&rb)) { // show an existing frame
172 si->is_kf = !vp9_rb_read_bit(&rb);
177 rb.bit_offset += 1; // show frame
178 rb.bit_offset += 1; // error resilient
180 if (vp9_rb_read_literal(&rb, 8) != VP9_SYNC_CODE_0 ||
181 vp9_rb_read_literal(&rb, 8) != VP9_SYNC_CODE_1 ||
182 vp9_rb_read_literal(&rb, 8) != VP9_SYNC_CODE_2) {
183 return VPX_CODEC_UNSUP_BITSTREAM;
186 colorspace = vp9_rb_read_literal(&rb, 3);
187 if (colorspace != sRGB) {
188 rb.bit_offset += 1; // [16,235] (including xvycc) vs [0,255] range
190 rb.bit_offset += 2; // subsampling x/y
191 rb.bit_offset += 1; // has extra plane
195 rb.bit_offset += 1; // has extra plane
197 // RGB is only available in version 1
198 return VPX_CODEC_UNSUP_BITSTREAM;
202 // TODO(jzern): these are available on non-keyframes in intra only mode.
203 si->w = vp9_rb_read_literal(&rb, 16) + 1;
204 si->h = vp9_rb_read_literal(&rb, 16) + 1;
211 static vpx_codec_err_t vp9_get_si(vpx_codec_alg_priv_t *ctx,
212 vpx_codec_stream_info_t *si) {
213 const size_t sz = (si->sz >= sizeof(vp9_stream_info_t))
214 ? sizeof(vp9_stream_info_t)
215 : sizeof(vpx_codec_stream_info_t);
216 memcpy(si, &ctx->si, sz);
217 si->sz = (unsigned int)sz;
223 static vpx_codec_err_t update_error_state(vpx_codec_alg_priv_t *ctx,
224 const struct vpx_internal_error_info *error) {
225 if (error->error_code)
226 ctx->base.err_detail = error->has_detail ? error->detail : NULL;
228 return error->error_code;
231 static vpx_codec_err_t decode_one(vpx_codec_alg_priv_t *ctx,
232 const uint8_t **data, unsigned int data_sz,
233 void *user_priv, int64_t deadline) {
234 vpx_codec_err_t res = VPX_CODEC_OK;
238 /* Determine the stream parameters. Note that we rely on peek_si to
239 * validate that we have a buffer that does not wrap around the top
243 res = ctx->base.iface->dec.peek_si(*data, data_sz, &ctx->si);
246 /* Perform deferred allocations, if required */
247 if (!res && ctx->defer_alloc) {
250 for (i = 1; !res && i < NELEMENTS(ctx->mmaps); i++) {
251 vpx_codec_dec_cfg_t cfg;
255 ctx->mmaps[i].id = vp9_mem_req_segs[i].id;
256 ctx->mmaps[i].sz = vp9_mem_req_segs[i].sz;
257 ctx->mmaps[i].align = vp9_mem_req_segs[i].align;
258 ctx->mmaps[i].flags = vp9_mem_req_segs[i].flags;
260 if (!ctx->mmaps[i].sz)
261 ctx->mmaps[i].sz = vp9_mem_req_segs[i].calc_sz(&cfg,
262 ctx->base.init_flags);
264 res = vpx_mmap_alloc(&ctx->mmaps[i]);
268 vp9_finalize_mmaps(ctx);
270 ctx->defer_alloc = 0;
273 /* Initialize the decoder instance on the first frame*/
274 if (!res && !ctx->decoder_init) {
275 res = vpx_validate_mmaps(&ctx->si, ctx->mmaps,
276 vp9_mem_req_segs, NELEMENTS(vp9_mem_req_segs),
277 ctx->base.init_flags);
283 vp9_initialize_dec();
285 oxcf.width = ctx->si.w;
286 oxcf.height = ctx->si.h;
288 oxcf.postprocess = 0;
289 oxcf.max_threads = ctx->cfg.threads;
290 oxcf.inv_tile_order = ctx->invert_tile_order;
291 optr = vp9_create_decompressor(&oxcf);
293 // If postprocessing was enabled by the application and a
294 // configuration has not been provided, default it.
295 if (!ctx->postproc_cfg_set &&
296 (ctx->base.init_flags & VPX_CODEC_USE_POSTPROC)) {
297 ctx->postproc_cfg.post_proc_flag = VP8_DEBLOCK | VP8_DEMACROBLOCK;
298 ctx->postproc_cfg.deblocking_level = 4;
299 ctx->postproc_cfg.noise_level = 0;
303 res = VPX_CODEC_ERROR;
305 VP9D_COMP *const pbi = (VP9D_COMP*)optr;
306 VP9_COMMON *const cm = &pbi->common;
308 // Set index to not initialized.
311 if (ctx->get_ext_fb_cb != NULL && ctx->release_ext_fb_cb != NULL) {
312 cm->get_fb_cb = ctx->get_ext_fb_cb;
313 cm->release_fb_cb = ctx->release_ext_fb_cb;
314 cm->cb_priv = ctx->ext_priv;
316 cm->get_fb_cb = vp9_get_frame_buffer;
317 cm->release_fb_cb = vp9_release_frame_buffer;
319 if (vp9_alloc_internal_frame_buffers(&cm->int_frame_buffers))
320 vpx_internal_error(&cm->error, VPX_CODEC_MEM_ERROR,
321 "Failed to initialize internal frame buffers");
322 cm->cb_priv = &cm->int_frame_buffers;
329 ctx->decoder_init = 1;
332 if (!res && ctx->pbi) {
333 YV12_BUFFER_CONFIG sd;
334 int64_t time_stamp = 0, time_end_stamp = 0;
335 vp9_ppflags_t flags = {0};
337 if (ctx->base.init_flags & VPX_CODEC_USE_POSTPROC) {
338 flags.post_proc_flag =
339 #if CONFIG_POSTPROC_VISUALIZER
340 (ctx->dbg_color_ref_frame_flag ? VP9D_DEBUG_CLR_FRM_REF_BLKS : 0) |
341 (ctx->dbg_color_mb_modes_flag ? VP9D_DEBUG_CLR_BLK_MODES : 0) |
342 (ctx->dbg_color_b_modes_flag ? VP9D_DEBUG_CLR_BLK_MODES : 0) |
343 (ctx->dbg_display_mv_flag ? VP9D_DEBUG_DRAW_MV : 0) |
345 ctx->postproc_cfg.post_proc_flag;
347 flags.deblocking_level = ctx->postproc_cfg.deblocking_level;
348 flags.noise_level = ctx->postproc_cfg.noise_level;
349 #if CONFIG_POSTPROC_VISUALIZER
350 flags.display_ref_frame_flag = ctx->dbg_color_ref_frame_flag;
351 flags.display_mb_modes_flag = ctx->dbg_color_mb_modes_flag;
352 flags.display_b_modes_flag = ctx->dbg_color_b_modes_flag;
353 flags.display_mv_flag = ctx->dbg_display_mv_flag;
357 if (vp9_receive_compressed_data(ctx->pbi, data_sz, data, deadline)) {
358 VP9D_COMP *pbi = (VP9D_COMP*)ctx->pbi;
359 res = update_error_state(ctx, &pbi->common.error);
362 if (!res && 0 == vp9_get_raw_frame(ctx->pbi, &sd, &time_stamp,
363 &time_end_stamp, &flags)) {
364 VP9D_COMP *const pbi = (VP9D_COMP*)ctx->pbi;
365 VP9_COMMON *const cm = &pbi->common;
366 yuvconfig2image(&ctx->img, &sd, user_priv);
368 ctx->img.fb_priv = cm->frame_bufs[cm->new_fb_idx].raw_frame_buffer.priv;
376 static void parse_superframe_index(const uint8_t *data, size_t data_sz,
377 uint32_t sizes[8], int *count) {
381 marker = data[data_sz - 1];
384 if ((marker & 0xe0) == 0xc0) {
385 const uint32_t frames = (marker & 0x7) + 1;
386 const uint32_t mag = ((marker >> 3) & 0x3) + 1;
387 const size_t index_sz = 2 + mag * frames;
389 if (data_sz >= index_sz && data[data_sz - index_sz] == marker) {
390 // found a valid superframe index
392 const uint8_t *x = data + data_sz - index_sz + 1;
394 for (i = 0; i < frames; i++) {
395 uint32_t this_sz = 0;
397 for (j = 0; j < mag; j++)
398 this_sz |= (*x++) << (j * 8);
407 static vpx_codec_err_t vp9_decode(vpx_codec_alg_priv_t *ctx,
409 unsigned int data_sz,
412 const uint8_t *data_start = data;
413 const uint8_t *data_end = data + data_sz;
414 vpx_codec_err_t res = 0;
416 int frames_this_pts, frame_count = 0;
418 if (data == NULL || data_sz == 0) return VPX_CODEC_INVALID_PARAM;
420 parse_superframe_index(data, data_sz, sizes, &frames_this_pts);
423 // Skip over the superframe index, if present
424 if (data_sz && (*data_start & 0xe0) == 0xc0) {
425 const uint8_t marker = *data_start;
426 const uint32_t frames = (marker & 0x7) + 1;
427 const uint32_t mag = ((marker >> 3) & 0x3) + 1;
428 const uint32_t index_sz = 2 + mag * frames;
430 if (data_sz >= index_sz && data_start[index_sz - 1] == marker) {
431 data_start += index_sz;
433 if (data_start < data_end)
440 // Use the correct size for this frame, if an index is present.
441 if (frames_this_pts) {
442 uint32_t this_sz = sizes[frame_count];
444 if (data_sz < this_sz) {
445 ctx->base.err_detail = "Invalid frame size in index";
446 return VPX_CODEC_CORRUPT_FRAME;
453 res = decode_one(ctx, &data_start, data_sz, user_priv, deadline);
454 assert(data_start >= data);
455 assert(data_start <= data_end);
457 /* Early exit if there was a decode error */
461 /* Account for suboptimal termination by the encoder. */
462 while (data_start < data_end && *data_start == 0)
465 data_sz = data_end - data_start;
466 } while (data_start < data_end);
470 static vpx_image_t *vp9_get_frame(vpx_codec_alg_priv_t *ctx,
471 vpx_codec_iter_t *iter) {
472 vpx_image_t *img = NULL;
474 if (ctx->img_avail) {
475 /* iter acts as a flip flop, so an image is only returned on the first
488 static vpx_codec_err_t vp9_set_fb_fn(
489 vpx_codec_alg_priv_t *ctx,
490 vpx_get_frame_buffer_cb_fn_t cb_get,
491 vpx_release_frame_buffer_cb_fn_t cb_release, void *cb_priv) {
492 if (cb_get == NULL || cb_release == NULL) {
493 return VPX_CODEC_INVALID_PARAM;
494 } else if (ctx->pbi == NULL) {
495 // If the decoder has already been initialized, do not accept changes to
496 // the frame buffer functions.
497 ctx->get_ext_fb_cb = cb_get;
498 ctx->release_ext_fb_cb = cb_release;
499 ctx->ext_priv = cb_priv;
503 return VPX_CODEC_ERROR;
506 static vpx_codec_err_t vp9_xma_get_mmap(const vpx_codec_ctx_t *ctx,
507 vpx_codec_mmap_t *mmap,
508 vpx_codec_iter_t *iter) {
510 const mem_req_t *seg_iter = *iter;
512 /* Get address of next segment request */
515 seg_iter = vp9_mem_req_segs;
516 else if (seg_iter->id != VP9_SEG_MAX)
519 *iter = (vpx_codec_iter_t)seg_iter;
521 if (seg_iter->id != VP9_SEG_MAX) {
522 mmap->id = seg_iter->id;
523 mmap->sz = seg_iter->sz;
524 mmap->align = seg_iter->align;
525 mmap->flags = seg_iter->flags;
528 mmap->sz = seg_iter->calc_sz(ctx->config.dec, ctx->init_flags);
532 res = VPX_CODEC_LIST_END;
534 } while (!mmap->sz && res != VPX_CODEC_LIST_END);
539 static vpx_codec_err_t vp9_xma_set_mmap(vpx_codec_ctx_t *ctx,
540 const vpx_codec_mmap_t *mmap) {
541 vpx_codec_err_t res = VPX_CODEC_MEM_ERROR;
545 if (mmap->id == VP9_SEG_ALG_PRIV) {
547 vp9_init_ctx(ctx, mmap);
555 if (!res && ctx->priv->alg_priv) {
556 for (i = 0; i < NELEMENTS(ctx->priv->alg_priv->mmaps); i++) {
557 if (ctx->priv->alg_priv->mmaps[i].id == mmap->id)
558 if (!ctx->priv->alg_priv->mmaps[i].base) {
559 ctx->priv->alg_priv->mmaps[i] = *mmap;
563 done &= (ctx->priv->alg_priv->mmaps[i].base != NULL);
568 vp9_finalize_mmaps(ctx->priv->alg_priv);
569 res = ctx->iface->init(ctx, NULL);
575 static vpx_codec_err_t set_reference(vpx_codec_alg_priv_t *ctx, int ctr_id,
577 vpx_ref_frame_t *data = va_arg(args, vpx_ref_frame_t *);
580 vpx_ref_frame_t *frame = (vpx_ref_frame_t *)data;
581 YV12_BUFFER_CONFIG sd;
583 image2yuvconfig(&frame->img, &sd);
584 return vp9_set_reference_dec(ctx->pbi,
585 (VP9_REFFRAME)frame->frame_type, &sd);
587 return VPX_CODEC_INVALID_PARAM;
591 static vpx_codec_err_t copy_reference(vpx_codec_alg_priv_t *ctx, int ctr_id,
593 vpx_ref_frame_t *data = va_arg(args, vpx_ref_frame_t *);
596 vpx_ref_frame_t *frame = (vpx_ref_frame_t *)data;
597 YV12_BUFFER_CONFIG sd;
599 image2yuvconfig(&frame->img, &sd);
601 return vp9_copy_reference_dec(ctx->pbi,
602 (VP9_REFFRAME)frame->frame_type, &sd);
604 return VPX_CODEC_INVALID_PARAM;
608 static vpx_codec_err_t get_reference(vpx_codec_alg_priv_t *ctx, int ctr_id,
610 vp9_ref_frame_t *data = va_arg(args, vp9_ref_frame_t *);
613 YV12_BUFFER_CONFIG* fb;
615 vp9_get_reference_dec(ctx->pbi, data->idx, &fb);
616 yuvconfig2image(&data->img, fb, NULL);
619 return VPX_CODEC_INVALID_PARAM;
623 static vpx_codec_err_t set_postproc(vpx_codec_alg_priv_t *ctx, int ctr_id,
625 #if CONFIG_VP9_POSTPROC
626 vp8_postproc_cfg_t *data = va_arg(args, vp8_postproc_cfg_t *);
629 ctx->postproc_cfg_set = 1;
630 ctx->postproc_cfg = *((vp8_postproc_cfg_t *)data);
633 return VPX_CODEC_INVALID_PARAM;
636 return VPX_CODEC_INCAPABLE;
640 static vpx_codec_err_t set_dbg_options(vpx_codec_alg_priv_t *ctx, int ctrl_id,
642 #if CONFIG_POSTPROC_VISUALIZER && CONFIG_POSTPROC
643 int data = va_arg(args, int);
645 #define MAP(id, var) case id: var = data; break;
648 MAP(VP8_SET_DBG_COLOR_REF_FRAME, ctx->dbg_color_ref_frame_flag);
649 MAP(VP8_SET_DBG_COLOR_MB_MODES, ctx->dbg_color_mb_modes_flag);
650 MAP(VP8_SET_DBG_COLOR_B_MODES, ctx->dbg_color_b_modes_flag);
651 MAP(VP8_SET_DBG_DISPLAY_MV, ctx->dbg_display_mv_flag);
656 return VPX_CODEC_INCAPABLE;
660 static vpx_codec_err_t get_last_ref_updates(vpx_codec_alg_priv_t *ctx,
661 int ctrl_id, va_list args) {
662 int *update_info = va_arg(args, int *);
663 VP9D_COMP *pbi = (VP9D_COMP*)ctx->pbi;
666 *update_info = pbi->refresh_frame_flags;
670 return VPX_CODEC_INVALID_PARAM;
675 static vpx_codec_err_t get_frame_corrupted(vpx_codec_alg_priv_t *ctx,
676 int ctrl_id, va_list args) {
677 int *corrupted = va_arg(args, int *);
680 VP9D_COMP *pbi = (VP9D_COMP*)ctx->pbi;
682 *corrupted = pbi->common.frame_to_show->corrupted;
684 return VPX_CODEC_ERROR;
687 return VPX_CODEC_INVALID_PARAM;
691 static vpx_codec_err_t get_display_size(vpx_codec_alg_priv_t *ctx,
692 int ctrl_id, va_list args) {
693 int *const display_size = va_arg(args, int *);
696 const VP9D_COMP *const pbi = (VP9D_COMP*)ctx->pbi;
698 display_size[0] = pbi->common.display_width;
699 display_size[1] = pbi->common.display_height;
701 return VPX_CODEC_ERROR;
705 return VPX_CODEC_INVALID_PARAM;
709 static vpx_codec_err_t set_invert_tile_order(vpx_codec_alg_priv_t *ctx,
712 ctx->invert_tile_order = va_arg(args, int);
716 static vpx_codec_ctrl_fn_map_t ctf_maps[] = {
717 {VP8_SET_REFERENCE, set_reference},
718 {VP8_COPY_REFERENCE, copy_reference},
719 {VP8_SET_POSTPROC, set_postproc},
720 {VP8_SET_DBG_COLOR_REF_FRAME, set_dbg_options},
721 {VP8_SET_DBG_COLOR_MB_MODES, set_dbg_options},
722 {VP8_SET_DBG_COLOR_B_MODES, set_dbg_options},
723 {VP8_SET_DBG_DISPLAY_MV, set_dbg_options},
724 {VP8D_GET_LAST_REF_UPDATES, get_last_ref_updates},
725 {VP8D_GET_FRAME_CORRUPTED, get_frame_corrupted},
726 {VP9_GET_REFERENCE, get_reference},
727 {VP9D_GET_DISPLAY_SIZE, get_display_size},
728 {VP9_INVERT_TILE_DECODE_ORDER, set_invert_tile_order},
733 #ifndef VERSION_STRING
734 #define VERSION_STRING
736 CODEC_INTERFACE(vpx_codec_vp9_dx) = {
737 "WebM Project VP9 Decoder" VERSION_STRING,
738 VPX_CODEC_INTERNAL_ABI_VERSION,
739 VPX_CODEC_CAP_DECODER | VP9_CAP_POSTPROC |
740 VPX_CODEC_CAP_EXTERNAL_FRAME_BUFFER,
741 /* vpx_codec_caps_t caps; */
742 vp9_init, /* vpx_codec_init_fn_t init; */
743 vp9_destroy, /* vpx_codec_destroy_fn_t destroy; */
744 ctf_maps, /* vpx_codec_ctrl_fn_map_t *ctrl_maps; */
745 vp9_xma_get_mmap, /* vpx_codec_get_mmap_fn_t get_mmap; */
746 vp9_xma_set_mmap, /* vpx_codec_set_mmap_fn_t set_mmap; */
748 vp9_peek_si, /* vpx_codec_peek_si_fn_t peek_si; */
749 vp9_get_si, /* vpx_codec_get_si_fn_t get_si; */
750 vp9_decode, /* vpx_codec_decode_fn_t decode; */
751 vp9_get_frame, /* vpx_codec_frame_get_fn_t frame_get; */
752 vp9_set_fb_fn, /* vpx_codec_set_fb_fn_t set_fb_fn; */
755 /* encoder functions */