comparison h264_direct.c @ 11097:7e5d7873fad9 libavcodec

Set x264_build so that checks are simpler.
author michael
date Mon, 08 Feb 2010 00:08:05 +0000
parents 2aeb7a1d1c7f
children 8023ba45995f
comparison
equal deleted inserted replaced
11096:4aa724a692f5 11097:7e5d7873fad9
284 fill_rectangle(&h->ref_cache[0][scan8[0]], 4, 4, 8, (uint8_t)ref[0], 1); 284 fill_rectangle(&h->ref_cache[0][scan8[0]], 4, 4, 8, (uint8_t)ref[0], 1);
285 fill_rectangle(&h->ref_cache[1][scan8[0]], 4, 4, 8, (uint8_t)ref[1], 1); 285 fill_rectangle(&h->ref_cache[1][scan8[0]], 4, 4, 8, (uint8_t)ref[1], 1);
286 if(!IS_INTRA(mb_type_col[0]) && !h->ref_list[1][0].long_ref 286 if(!IS_INTRA(mb_type_col[0]) && !h->ref_list[1][0].long_ref
287 && ( (l1ref0[0] == 0 && FFABS(l1mv0[0][0]) <= 1 && FFABS(l1mv0[0][1]) <= 1) 287 && ( (l1ref0[0] == 0 && FFABS(l1mv0[0][0]) <= 1 && FFABS(l1mv0[0][1]) <= 1)
288 || (l1ref0[0] < 0 && l1ref1[0] == 0 && FFABS(l1mv1[0][0]) <= 1 && FFABS(l1mv1[0][1]) <= 1 288 || (l1ref0[0] < 0 && l1ref1[0] == 0 && FFABS(l1mv1[0][0]) <= 1 && FFABS(l1mv1[0][1]) <= 1
289 && (h->x264_build>33 || !h->x264_build)))){ 289 && h->x264_build>33U))){
290 a=b=0; 290 a=b=0;
291 if(ref[0] > 0) 291 if(ref[0] > 0)
292 a= pack16to32(mv[0][0],mv[0][1]); 292 a= pack16to32(mv[0][0],mv[0][1]);
293 if(ref[1] > 0) 293 if(ref[1] > 0)
294 b= pack16to32(mv[1][0],mv[1][1]); 294 b= pack16to32(mv[1][0],mv[1][1]);
313 fill_rectangle(&h->ref_cache[1][scan8[i8*4]], 2, 2, 8, (uint8_t)ref[1], 1); 313 fill_rectangle(&h->ref_cache[1][scan8[i8*4]], 2, 2, 8, (uint8_t)ref[1], 1);
314 314
315 /* col_zero_flag */ 315 /* col_zero_flag */
316 if(!IS_INTRA(mb_type_col[0]) && !h->ref_list[1][0].long_ref && ( l1ref0[x8 + y8*b8_stride] == 0 316 if(!IS_INTRA(mb_type_col[0]) && !h->ref_list[1][0].long_ref && ( l1ref0[x8 + y8*b8_stride] == 0
317 || (l1ref0[x8 + y8*b8_stride] < 0 && l1ref1[x8 + y8*b8_stride] == 0 317 || (l1ref0[x8 + y8*b8_stride] < 0 && l1ref1[x8 + y8*b8_stride] == 0
318 && (h->x264_build>33 || !h->x264_build)))){ 318 && h->x264_build>33U))){
319 const int16_t (*l1mv)[2]= l1ref0[x8 + y8*b8_stride] == 0 ? l1mv0 : l1mv1; 319 const int16_t (*l1mv)[2]= l1ref0[x8 + y8*b8_stride] == 0 ? l1mv0 : l1mv1;
320 if(IS_SUB_8X8(sub_mb_type)){ 320 if(IS_SUB_8X8(sub_mb_type)){
321 const int16_t *mv_col = l1mv[x8*3 + y8*3*b4_stride]; 321 const int16_t *mv_col = l1mv[x8*3 + y8*3*b4_stride];
322 if(FFABS(mv_col[0]) <= 1 && FFABS(mv_col[1]) <= 1){ 322 if(FFABS(mv_col[0]) <= 1 && FFABS(mv_col[1]) <= 1){
323 if(ref[0] == 0) 323 if(ref[0] == 0)