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 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 vp8cx_init_de_quantizer(pbi); | 80 vp8cx_init_de_quantizer(pbi); |
81 | 81 |
82 vp8_loop_filter_init(&pbi->common); | 82 vp8_loop_filter_init(&pbi->common); |
83 | 83 |
84 pbi->common.error.setjmp = 0; | 84 pbi->common.error.setjmp = 0; |
85 | 85 |
86 #if CONFIG_ERROR_CONCEALMENT | 86 #if CONFIG_ERROR_CONCEALMENT |
87 pbi->ec_enabled = oxcf->error_concealment; | 87 pbi->ec_enabled = oxcf->error_concealment; |
88 pbi->overlaps = NULL; | 88 pbi->overlaps = NULL; |
89 #else | 89 #else |
| 90 (void)oxcf; |
90 pbi->ec_enabled = 0; | 91 pbi->ec_enabled = 0; |
91 #endif | 92 #endif |
92 /* Error concealment is activated after a key frame has been | 93 /* Error concealment is activated after a key frame has been |
93 * decoded without errors when error concealment is enabled. | 94 * decoded without errors when error concealment is enabled. |
94 */ | 95 */ |
95 pbi->ec_active = 0; | 96 pbi->ec_active = 0; |
96 | 97 |
97 pbi->decoded_key_frame = 0; | 98 pbi->decoded_key_frame = 0; |
98 | 99 |
99 /* Independent partitions is activated when a frame updates the | 100 /* Independent partitions is activated when a frame updates the |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
296 | 297 |
297 return 1; | 298 return 1; |
298 } | 299 } |
299 | 300 |
300 int vp8dx_receive_compressed_data(VP8D_COMP *pbi, size_t size, | 301 int vp8dx_receive_compressed_data(VP8D_COMP *pbi, size_t size, |
301 const uint8_t *source, | 302 const uint8_t *source, |
302 int64_t time_stamp) | 303 int64_t time_stamp) |
303 { | 304 { |
304 VP8_COMMON *cm = &pbi->common; | 305 VP8_COMMON *cm = &pbi->common; |
305 int retcode = -1; | 306 int retcode = -1; |
| 307 (void)size; |
| 308 (void)source; |
306 | 309 |
307 pbi->common.error.error_code = VPX_CODEC_OK; | 310 pbi->common.error.error_code = VPX_CODEC_OK; |
308 | 311 |
309 retcode = check_fragments_for_errors(pbi); | 312 retcode = check_fragments_for_errors(pbi); |
310 if(retcode <= 0) | 313 if(retcode <= 0) |
311 return retcode; | 314 return retcode; |
312 | 315 |
313 cm->new_fb_idx = get_free_fb (cm); | 316 cm->new_fb_idx = get_free_fb (cm); |
314 | 317 |
315 /* setup reference frames for vp8_decode_frame */ | 318 /* setup reference frames for vp8_decode_frame */ |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
400 if (pbi->common.show_frame == 0) | 403 if (pbi->common.show_frame == 0) |
401 return ret; | 404 return ret; |
402 | 405 |
403 pbi->ready_for_new_data = 1; | 406 pbi->ready_for_new_data = 1; |
404 *time_stamp = pbi->last_time_stamp; | 407 *time_stamp = pbi->last_time_stamp; |
405 *time_end_stamp = 0; | 408 *time_end_stamp = 0; |
406 | 409 |
407 #if CONFIG_POSTPROC | 410 #if CONFIG_POSTPROC |
408 ret = vp8_post_proc_frame(&pbi->common, sd, flags); | 411 ret = vp8_post_proc_frame(&pbi->common, sd, flags); |
409 #else | 412 #else |
| 413 (void)flags; |
410 | 414 |
411 if (pbi->common.frame_to_show) | 415 if (pbi->common.frame_to_show) |
412 { | 416 { |
413 *sd = *pbi->common.frame_to_show; | 417 *sd = *pbi->common.frame_to_show; |
414 sd->y_width = pbi->common.Width; | 418 sd->y_width = pbi->common.Width; |
415 sd->y_height = pbi->common.Height; | 419 sd->y_height = pbi->common.Height; |
416 sd->uv_height = pbi->common.Height / 2; | 420 sd->uv_height = pbi->common.Height / 2; |
417 ret = 0; | 421 ret = 0; |
418 } | 422 } |
419 else | 423 else |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
492 remove_decompressor(pbi); | 496 remove_decompressor(pbi); |
493 } | 497 } |
494 else | 498 else |
495 { | 499 { |
496 /* TODO : remove frame threads and decoder instances for each | 500 /* TODO : remove frame threads and decoder instances for each |
497 * thread here */ | 501 * thread here */ |
498 } | 502 } |
499 | 503 |
500 return VPX_CODEC_OK; | 504 return VPX_CODEC_OK; |
501 } | 505 } |
OLD | NEW |