Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(486)

Side by Side Diff: source/libvpx/vp9/decoder/vp9_onyxd_int.h

Issue 11555023: libvpx: Add VP9 decoder. (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/libvpx/
Patch Set: Created 8 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
Property Changes:
Added: svn:eol-style
+ LF
OLDNEW
(Empty)
1 /*
2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved.
3 *
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.
9 */
10
11
12 #ifndef VP9_DECODER_VP9_ONYXD_INT_H_
13 #define VP9_DECODER_VP9_ONYXD_INT_H_
14 #include "vpx_ports/config.h"
15 #include "vp9/common/vp9_onyxd.h"
16 #include "vp9/decoder/vp9_treereader.h"
17 #include "vp9/common/vp9_onyxc_int.h"
18 #include "vp9/decoder/vp9_dequantize.h"
19
20 // #define DEC_DEBUG
21
22 typedef struct {
23 int ithread;
24 void *ptr1;
25 void *ptr2;
26 } DECODETHREAD_DATA;
27
28 typedef struct {
29 MACROBLOCKD mbd;
30 int mb_row;
31 int current_mb_col;
32 short *coef_ptr;
33 } MB_ROW_DEC;
34
35 typedef struct {
36 int const *scan;
37 int const *scan_8x8;
38 UINT8 const *ptr_block2leftabove;
39 vp9_tree_index const *vp9_coef_tree_ptr;
40 unsigned char *norm_ptr;
41 UINT8 *ptr_coef_bands_x;
42 UINT8 *ptr_coef_bands_x_8x8;
43
44 ENTROPY_CONTEXT_PLANES *A;
45 ENTROPY_CONTEXT_PLANES *L;
46
47 INT16 *qcoeff_start_ptr;
48
49 vp9_prob const *coef_probs[BLOCK_TYPES];
50 vp9_prob const *coef_probs_8x8[BLOCK_TYPES_8X8];
51 vp9_prob const *coef_probs_16X16[BLOCK_TYPES_16X16];
52
53 UINT8 eob[25];
54
55 } DETOK;
56
57 typedef struct VP9Decompressor {
58 DECLARE_ALIGNED(16, MACROBLOCKD, mb);
59
60 DECLARE_ALIGNED(16, VP9_COMMON, common);
61
62 VP9D_CONFIG oxcf;
63
64
65 const unsigned char *Source;
66 unsigned int source_sz;
67
68 vp9_reader *mbc;
69 int64_t last_time_stamp;
70 int ready_for_new_data;
71
72 DETOK detoken;
73
74 vp9_dequant_idct_add_fn_t idct_add;
75 vp9_dequant_dc_idct_add_fn_t dc_idct_add;
76 vp9_dequant_dc_idct_add_y_block_fn_t dc_idct_add_y_block;
77 vp9_dequant_idct_add_y_block_fn_t idct_add_y_block;
78 vp9_dequant_idct_add_uv_block_fn_t idct_add_uv_block;
79
80 vp9_prob prob_skip_false;
81
82 int decoded_key_frame;
83
84 } VP9D_COMP;
85
86 int vp9_decode_frame(VP9D_COMP *cpi, const unsigned char **p_data_end);
87
88
89 #if CONFIG_DEBUG
90 #define CHECK_MEM_ERROR(lval,expr) do {\
91 lval = (expr); \
92 if(!lval) \
93 vpx_internal_error(&pbi->common.error, VPX_CODEC_MEM_ERROR,\
94 "Failed to allocate "#lval" at %s:%d", \
95 __FILE__,__LINE__);\
96 } while(0)
97 #else
98 #define CHECK_MEM_ERROR(lval,expr) do {\
99 lval = (expr); \
100 if(!lval) \
101 vpx_internal_error(&pbi->common.error, VPX_CODEC_MEM_ERROR,\
102 "Failed to allocate "#lval);\
103 } while(0)
104 #endif
105
106 #endif // __INC_ONYXD_INT_H
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698