comparison cavs.h @ 8605:33f51dd2491f libavcodec

rename vector_t to cavs_vector
author stefang
date Fri, 16 Jan 2009 17:20:17 +0000
parents 0579157cbb14
children c3a96cea3453
comparison
equal deleted inserted replaced
8604:48c89068a41b 8605:33f51dd2491f
140 DECLARE_ALIGNED_8(typedef, struct) { 140 DECLARE_ALIGNED_8(typedef, struct) {
141 int16_t x; 141 int16_t x;
142 int16_t y; 142 int16_t y;
143 int16_t dist; 143 int16_t dist;
144 int16_t ref; 144 int16_t ref;
145 } vector_t; 145 } cavs_vector;
146 146
147 struct dec_2dvlc { 147 struct dec_2dvlc {
148 int8_t rltab[59][3]; 148 int8_t rltab[59][3];
149 int8_t level_add[27]; 149 int8_t level_add[27];
150 int8_t golomb_order; 150 int8_t golomb_order;
184 B is the macroblock to the top (1,2) 184 B is the macroblock to the top (1,2)
185 C is the macroblock to the top-right (3) 185 C is the macroblock to the top-right (3)
186 D is the macroblock to the top-left (0) 186 D is the macroblock to the top-left (0)
187 187
188 the same is repeated for backward motion vectors */ 188 the same is repeated for backward motion vectors */
189 vector_t mv[2*4*3]; 189 cavs_vector mv[2*4*3];
190 vector_t *top_mv[2]; 190 cavs_vector *top_mv[2];
191 vector_t *col_mv; 191 cavs_vector *col_mv;
192 192
193 /** luma pred mode cache 193 /** luma pred mode cache
194 0: -- B2 B3 194 0: -- B2 B3
195 3: A1 X0 X1 195 3: A1 X0 X1
196 6: A3 X2 X3 */ 196 6: A3 X2 X3 */
234 extern const uint8_t ff_cavs_partition_flags[30]; 234 extern const uint8_t ff_cavs_partition_flags[30];
235 extern const int_fast8_t ff_left_modifier_l[8]; 235 extern const int_fast8_t ff_left_modifier_l[8];
236 extern const int_fast8_t ff_top_modifier_l[8]; 236 extern const int_fast8_t ff_top_modifier_l[8];
237 extern const int_fast8_t ff_left_modifier_c[7]; 237 extern const int_fast8_t ff_left_modifier_c[7];
238 extern const int_fast8_t ff_top_modifier_c[7]; 238 extern const int_fast8_t ff_top_modifier_c[7];
239 extern const vector_t ff_cavs_intra_mv; 239 extern const cavs_vector ff_cavs_intra_mv;
240 extern const vector_t ff_cavs_un_mv; 240 extern const cavs_vector ff_cavs_un_mv;
241 extern const vector_t ff_cavs_dir_mv; 241 extern const cavs_vector ff_cavs_dir_mv;
242 242
243 static inline void modify_pred(const int_fast8_t *mod_table, int *mode) { 243 static inline void modify_pred(const int_fast8_t *mod_table, int *mode) {
244 *mode = mod_table[*mode]; 244 *mode = mod_table[*mode];
245 if(*mode < 0) { 245 if(*mode < 0) {
246 av_log(NULL, AV_LOG_ERROR, "Illegal intra prediction mode\n"); 246 av_log(NULL, AV_LOG_ERROR, "Illegal intra prediction mode\n");
251 static inline void set_intra_mode_default(AVSContext *h) { 251 static inline void set_intra_mode_default(AVSContext *h) {
252 h->pred_mode_Y[3] = h->pred_mode_Y[6] = INTRA_L_LP; 252 h->pred_mode_Y[3] = h->pred_mode_Y[6] = INTRA_L_LP;
253 h->top_pred_Y[h->mbx*2+0] = h->top_pred_Y[h->mbx*2+1] = INTRA_L_LP; 253 h->top_pred_Y[h->mbx*2+0] = h->top_pred_Y[h->mbx*2+1] = INTRA_L_LP;
254 } 254 }
255 255
256 static inline void set_mvs(vector_t *mv, enum block_t size) { 256 static inline void set_mvs(cavs_vector *mv, enum block_t size) {
257 switch(size) { 257 switch(size) {
258 case BLK_16X16: 258 case BLK_16X16:
259 mv[MV_STRIDE ] = mv[0]; 259 mv[MV_STRIDE ] = mv[0];
260 mv[MV_STRIDE+1] = mv[0]; 260 mv[MV_STRIDE+1] = mv[0];
261 case BLK_16X8: 261 case BLK_16X8: