# HG changeset patch # User michael # Date 1229465771 0 # Node ID 1ef90fd7706aed317ee3a0340d123cc1b5ee2cec # Parent 0030146fc2ba172028eb4ac5062d9b27148387be Fix indention, also do a little vertical alignment of changed lines. diff -r 0030146fc2ba -r 1ef90fd7706a h264.c --- a/h264.c Tue Dec 16 21:35:35 2008 +0000 +++ b/h264.c Tue Dec 16 22:16:11 2008 +0000 @@ -2448,15 +2448,15 @@ if(transform_bypass && h->sps.profile_idc==244 && dir<=1){ h->hpc.pred8x8l_add[dir](ptr, h->mb + i*16, linesize); }else{ - const int nnz = h->non_zero_count_cache[ scan8[i] ]; - h->hpc.pred8x8l[ dir ](ptr, (h->topleft_samples_available<topright_samples_available<mb[i*16]) - idct_dc_add(ptr, h->mb + i*16, linesize); - else - idct_add(ptr, h->mb + i*16, linesize); - } + const int nnz = h->non_zero_count_cache[ scan8[i] ]; + h->hpc.pred8x8l[ dir ](ptr, (h->topleft_samples_available<topright_samples_available<mb[i*16]) + idct_dc_add(ptr, h->mb + i*16, linesize); + else + idct_add (ptr, h->mb + i*16, linesize); + } } } }else @@ -2467,30 +2467,30 @@ if(transform_bypass && h->sps.profile_idc==244 && dir<=1){ h->hpc.pred4x4_add[dir](ptr, h->mb + i*16, linesize); }else{ - uint8_t *topright; - int nnz, tr; - if(dir == DIAG_DOWN_LEFT_PRED || dir == VERT_LEFT_PRED){ - const int topright_avail= (h->topright_samples_available<topright_samples_available<hpc.pred4x4[ dir ](ptr, topright, linesize); - nnz = h->non_zero_count_cache[ scan8[i] ]; - if(nnz){ - if(is_h264){ - if(nnz == 1 && h->mb[i*16]) - idct_dc_add(ptr, h->mb + i*16, linesize); - else - idct_add(ptr, h->mb + i*16, linesize); - }else - svq3_add_idct_c(ptr, h->mb + i*16, linesize, s->qscale, 0); - } + topright= NULL; + + h->hpc.pred4x4[ dir ](ptr, topright, linesize); + nnz = h->non_zero_count_cache[ scan8[i] ]; + if(nnz){ + if(is_h264){ + if(nnz == 1 && h->mb[i*16]) + idct_dc_add(ptr, h->mb + i*16, linesize); + else + idct_add (ptr, h->mb + i*16, linesize); + }else + svq3_add_idct_c(ptr, h->mb + i*16, linesize, s->qscale, 0); + } } } } @@ -2518,12 +2518,12 @@ if(transform_bypass && h->sps.profile_idc==244 && (h->intra16x16_pred_mode==VERT_PRED8x8 || h->intra16x16_pred_mode==HOR_PRED8x8)){ h->hpc.pred16x16_add[h->intra16x16_pred_mode](dest_y, block_offset, h->mb, linesize); }else{ - for(i=0; i<16; i++){ - if(h->non_zero_count_cache[ scan8[i] ]) - idct_add(dest_y + block_offset[i], h->mb + i*16, linesize); - else if(h->mb[i*16]) - idct_dc_add(dest_y + block_offset[i], h->mb + i*16, linesize); - } + for(i=0; i<16; i++){ + if(h->non_zero_count_cache[ scan8[i] ]) + idct_add (dest_y + block_offset[i], h->mb + i*16, linesize); + else if(h->mb[i*16]) + idct_dc_add(dest_y + block_offset[i], h->mb + i*16, linesize); + } } }else{ const int di = IS_8x8DCT(mb_type) ? 4 : 1; @@ -2562,12 +2562,12 @@ h->hpc.pred8x8_add[h->chroma_pred_mode](dest[0], block_offset + 16, h->mb + 16*16, uvlinesize); h->hpc.pred8x8_add[h->chroma_pred_mode](dest[1], block_offset + 20, h->mb + 20*16, uvlinesize); }else{ - for(i=16; i<16+8; i++){ - if(h->non_zero_count_cache[ scan8[i] ]) - idct_add(dest[(i&4)>>2] + block_offset[i], h->mb + i*16, uvlinesize); - else if(h->mb[i*16]) - idct_dc_add(dest[(i&4)>>2] + block_offset[i], h->mb + i*16, uvlinesize); - } + for(i=16; i<16+8; i++){ + if(h->non_zero_count_cache[ scan8[i] ]) + idct_add (dest[(i&4)>>2] + block_offset[i], h->mb + i*16, uvlinesize); + else if(h->mb[i*16]) + idct_dc_add(dest[(i&4)>>2] + block_offset[i], h->mb + i*16, uvlinesize); + } } }else{ for(i=16; i<16+8; i++){