OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved. | 2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 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 | 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 | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 419 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
430 | 430 |
431 static vpx_image_t *decoder_get_frame(vpx_codec_alg_priv_t *ctx, | 431 static vpx_image_t *decoder_get_frame(vpx_codec_alg_priv_t *ctx, |
432 vpx_codec_iter_t *iter) { | 432 vpx_codec_iter_t *iter) { |
433 vpx_image_t *img = NULL; | 433 vpx_image_t *img = NULL; |
434 | 434 |
435 if (ctx->img_avail) { | 435 if (ctx->img_avail) { |
436 // iter acts as a flip flop, so an image is only returned on the first | 436 // iter acts as a flip flop, so an image is only returned on the first |
437 // call to get_frame. | 437 // call to get_frame. |
438 if (!(*iter)) { | 438 if (!(*iter)) { |
439 img = &ctx->img; | 439 img = &ctx->img; |
440 img->bit_depth = (int)ctx->pbi->common.bit_depth; | |
441 *iter = img; | 440 *iter = img; |
442 } | 441 } |
443 } | 442 } |
444 ctx->img_avail = 0; | 443 ctx->img_avail = 0; |
445 | 444 |
446 return img; | 445 return img; |
447 } | 446 } |
448 | 447 |
449 static vpx_codec_err_t decoder_set_fb_fn( | 448 static vpx_codec_err_t decoder_set_fb_fn( |
450 vpx_codec_alg_priv_t *ctx, | 449 vpx_codec_alg_priv_t *ctx, |
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
662 0, | 661 0, |
663 NULL, // vpx_codec_enc_cfg_map_t | 662 NULL, // vpx_codec_enc_cfg_map_t |
664 NULL, // vpx_codec_encode_fn_t | 663 NULL, // vpx_codec_encode_fn_t |
665 NULL, // vpx_codec_get_cx_data_fn_t | 664 NULL, // vpx_codec_get_cx_data_fn_t |
666 NULL, // vpx_codec_enc_config_set_fn_t | 665 NULL, // vpx_codec_enc_config_set_fn_t |
667 NULL, // vpx_codec_get_global_headers_fn_t | 666 NULL, // vpx_codec_get_global_headers_fn_t |
668 NULL, // vpx_codec_get_preview_frame_fn_t | 667 NULL, // vpx_codec_get_preview_frame_fn_t |
669 NULL // vpx_codec_enc_mr_get_mem_loc_fn_t | 668 NULL // vpx_codec_enc_mr_get_mem_loc_fn_t |
670 } | 669 } |
671 }; | 670 }; |
OLD | NEW |