Mercurial > libavcodec.hg
comparison h264.c @ 9125:65141aec8b05 libavcodec
Add more correct bound checking in filter_mb().
Should fix decoding of CVMAPAQP3_Sony_E.jsv in MinGW
author | vitor |
---|---|
date | Wed, 04 Mar 2009 16:56:55 +0000 |
parents | 79818b0595c0 |
children | 793cf8c68c4f |
comparison
equal
deleted
inserted
replaced
9124:7f0d34340349 | 9125:65141aec8b05 |
---|---|
6491 if(!FRAME_MBAFF){ | 6491 if(!FRAME_MBAFF){ |
6492 int qp_thresh = 15 - h->slice_alpha_c0_offset - FFMAX3(0, h->pps.chroma_qp_index_offset[0], h->pps.chroma_qp_index_offset[1]); | 6492 int qp_thresh = 15 - h->slice_alpha_c0_offset - FFMAX3(0, h->pps.chroma_qp_index_offset[0], h->pps.chroma_qp_index_offset[1]); |
6493 int qp = s->current_picture.qscale_table[mb_xy]; | 6493 int qp = s->current_picture.qscale_table[mb_xy]; |
6494 if(qp <= qp_thresh | 6494 if(qp <= qp_thresh |
6495 && (mb_x == 0 || ((qp + s->current_picture.qscale_table[mb_xy-1] + 1)>>1) <= qp_thresh) | 6495 && (mb_x == 0 || ((qp + s->current_picture.qscale_table[mb_xy-1] + 1)>>1) <= qp_thresh) |
6496 && (mb_y == 0 || ((qp + s->current_picture.qscale_table[h->top_mb_xy] + 1)>>1) <= qp_thresh)){ | 6496 && (h->top_mb_xy < 0 || ((qp + s->current_picture.qscale_table[h->top_mb_xy] + 1)>>1) <= qp_thresh)){ |
6497 return; | 6497 return; |
6498 } | 6498 } |
6499 } | 6499 } |
6500 | 6500 |
6501 // CAVLC 8x8dct requires NNZ values for residual decoding that differ from what the loop filter needs | 6501 // CAVLC 8x8dct requires NNZ values for residual decoding that differ from what the loop filter needs |