From 481a7c5986f17a7c212eb9ab12beac57bcecef66 Mon Sep 17 00:00:00 2001 From: Jingning Han Date: Fri, 17 May 2013 10:03:52 -0700 Subject: [PATCH] Fix parameters in 4x8 variance calc Correct the stride parameter of 4x8 in vp9_sub_pixel_variance4x8_ and vp9_sub_pixel_avg_variance4x8. Change-Id: I2ca74d4043817503b21737563994270e3b0619ff --- vp9/encoder/vp9_variance_c.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/vp9/encoder/vp9_variance_c.c b/vp9/encoder/vp9_variance_c.c index e24a46b24..7231dcf22 100644 --- a/vp9/encoder/vp9_variance_c.c +++ b/vp9/encoder/vp9_variance_c.c @@ -873,6 +873,8 @@ unsigned int vp9_sub_pixel_variance4x8_c(const uint8_t *src_ptr, int dst_pixels_per_line, unsigned int *sse) { uint16_t fdata3[5 * 8]; // Temp data bufffer used in filtering + // FIXME(jingning,rbultje): this temp2 buffer probably doesn't need to be + // of this big? same issue appears in all other block size settings. uint8_t temp2[20 * 16]; const int16_t *hfilter, *vfilter; @@ -880,7 +882,7 @@ unsigned int vp9_sub_pixel_variance4x8_c(const uint8_t *src_ptr, vfilter = VP9_BILINEAR_FILTERS_2TAP(yoffset); var_filter_block2d_bil_first_pass(src_ptr, fdata3, src_pixels_per_line, - 1, 17, 4, hfilter); + 1, 9, 4, hfilter); var_filter_block2d_bil_second_pass(fdata3, temp2, 4, 4, 8, 4, vfilter); return vp9_variance4x8_c(temp2, 4, dst_ptr, dst_pixels_per_line, sse); @@ -903,7 +905,7 @@ unsigned int vp9_sub_pixel_avg_variance4x8_c(const uint8_t *src_ptr, vfilter = VP9_BILINEAR_FILTERS_2TAP(yoffset); var_filter_block2d_bil_first_pass(src_ptr, fdata3, src_pixels_per_line, - 1, 17, 4, hfilter); + 1, 9, 4, hfilter); var_filter_block2d_bil_second_pass(fdata3, temp2, 4, 4, 8, 4, vfilter); comp_avg_pred(temp3, second_pred, 4, 8, temp2, 4); return vp9_variance4x8_c(temp3, 4, dst_ptr, dst_pixels_per_line, sse); -- 2.40.0