diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2010-01-26 13:27:22 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2010-01-26 13:27:22 +0000 |
commit | 3046c25ec545941538ec213fa1180ead4524668c (patch) | |
tree | adcf74bd3933cda993c56d61ce80f7c86e9b4849 | |
parent | 806ac67b51ed2aecd8563e516fdab26a84b370b4 (diff) | |
download | ffmpeg-3046c25ec545941538ec213fa1180ead4524668c.tar.gz |
Fix qp_thres loop filter check for MBAFF.
Originally committed as revision 21453 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavcodec/h264.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/libavcodec/h264.h b/libavcodec/h264.h index 6e68d71f6e..71143c153c 100644 --- a/libavcodec/h264.h +++ b/libavcodec/h264.h @@ -799,9 +799,12 @@ static av_always_inline int fill_caches(H264Context *h, int mb_type, int for_deb int qp = s->current_picture.qscale_table[mb_xy]; if(qp <= qp_thresh && (left_xy[0]<0 || ((qp + s->current_picture.qscale_table[left_xy[0]] + 1)>>1) <= qp_thresh) - && (left_xy[1]<0 || ((qp + s->current_picture.qscale_table[left_xy[1]] + 1)>>1) <= qp_thresh) && (top_xy < 0 || ((qp + s->current_picture.qscale_table[top_xy ] + 1)>>1) <= qp_thresh)){ - return 1; + if(!FRAME_MBAFF) + return 1; + if( (left_xy[0]< 0 || ((qp + s->current_picture.qscale_table[left_xy[0]+s->mb_stride] + 1)>>1) <= qp_thresh) + && (top_xy < s->mb_stride || ((qp + s->current_picture.qscale_table[top_xy -s->mb_stride] + 1)>>1) <= qp_thresh)) + return 1; } if(IS_INTRA(mb_type)) return 0; |