diff options
author | Haruhiko Yamagata <h.yamagata@nifty.com> | 2009-05-24 03:39:20 +0000 |
---|---|---|
committer | David Conrad <lessen42@gmail.com> | 2009-05-24 03:39:20 +0000 |
commit | 86b0e9948b14bcc483e779b092d7a196eea4aa61 (patch) | |
tree | cbd1c87db91605ec0904f931050bf2620ebcb96c | |
parent | a7e6312b1e5e852edb62a094e94cfae06f01391b (diff) | |
download | ffmpeg-86b0e9948b14bcc483e779b092d7a196eea4aa61.tar.gz |
H264: Don't deblock if alpha or beta is 0.
This ensures that the MMX loop filter is always bitexact with the C version.
Patch by Haruhiko Yamagata <h.yamagata _a_ nifty com>
Originally committed as revision 18923 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavcodec/h264.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 550c4990db..f4c172b606 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -6003,6 +6003,7 @@ static void filter_mb_edgev( H264Context *h, uint8_t *pix, int stride, int16_t b const int index_a = qp + h->slice_alpha_c0_offset; const int alpha = (alpha_table+52)[index_a]; const int beta = (beta_table+52)[qp + h->slice_beta_offset]; + if (alpha ==0 || beta == 0) return; if( bS[0] < 4 ) { int8_t tc[4]; @@ -6019,6 +6020,7 @@ static void filter_mb_edgecv( H264Context *h, uint8_t *pix, int stride, int16_t const int index_a = qp + h->slice_alpha_c0_offset; const int alpha = (alpha_table+52)[index_a]; const int beta = (beta_table+52)[qp + h->slice_beta_offset]; + if (alpha ==0 || beta == 0) return; if( bS[0] < 4 ) { int8_t tc[4]; @@ -6187,6 +6189,7 @@ static void filter_mb_edgeh( H264Context *h, uint8_t *pix, int stride, int16_t b const int index_a = qp + h->slice_alpha_c0_offset; const int alpha = (alpha_table+52)[index_a]; const int beta = (beta_table+52)[qp + h->slice_beta_offset]; + if (alpha ==0 || beta == 0) return; if( bS[0] < 4 ) { int8_t tc[4]; @@ -6204,6 +6207,7 @@ static void filter_mb_edgech( H264Context *h, uint8_t *pix, int stride, int16_t const int index_a = qp + h->slice_alpha_c0_offset; const int alpha = (alpha_table+52)[index_a]; const int beta = (beta_table+52)[qp + h->slice_beta_offset]; + if (alpha ==0 || beta == 0) return; if( bS[0] < 4 ) { int8_t tc[4]; |