CVS: ffmpeg/libavcodec h264.c,1.175,1.176
Update of /cvsroot/ffmpeg/ffmpeg/libavcodec In directory mail:/var2/tmp/cvs-serv22538 Modified Files: h264.c Log Message: fix asymmetric CQMs with pre-transposed DCT. Index: h264.c =================================================================== RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/h264.c,v retrieving revision 1.175 retrieving revision 1.176 diff -u -d -r1.175 -r1.176 --- h264.c 31 Dec 2005 13:20:24 -0000 1.175 +++ h264.c 31 Dec 2005 14:14:38 -0000 1.176 @@ -2973,6 +2973,7 @@ static void init_dequant4_coeff_table(H264Context *h){ int i,j,q,x; + const int transpose = (h->s.dsp.h264_idct_add != ff_h264_idct_add_c); //FIXME ugly for(i=0; i<6; i++ ){ h->dequant4_coeff[i] = h->dequant4_buffer[i]; for(j=0; j<i; j++){ @@ -2988,7 +2989,8 @@ int shift = div6[q] + 2; int idx = rem6[q]; for(x=0; x<16; x++) - h->dequant4_coeff[i][q][x] = ((uint32_t)dequant4_coeff_init[idx][(x&1) + ((x>>2)&1)] * + h->dequant4_coeff[i][q][transpose ? (x>>2)|((x<<2)&0xF) : x] = + ((uint32_t)dequant4_coeff_init[idx][(x&1) + ((x>>2)&1)] * h->pps.scaling_matrix4[i][x]) << shift; } }
participants (1)
-
lorenm@mplayerhq.hu