From 304d31097571c62b0a1c580cf7a488fc793a85e5 Mon Sep 17 00:00:00 2001 From: Linfeng Zhang Date: Fri, 3 Jun 2016 09:28:11 -0700 Subject: [PATCH] Fix Visual Studio build failure in filter_selectively_vert_row2() calls Error messages: ..\vp9\common\vp9_loopfilter.c(1312): warning C4244: 'function' : conversion from 'uint64_t' to 'unsigned int', possible loss of data [.build-x86_64-win64-vs10\vpx.vcxproj] ..\vp9\common\vp9_loopfilter.c(1313): warning C4244: 'function' : conversion from 'uint64_t' to 'unsigned int', possible loss of data [.build-x86_64-win64-vs10\vpx.vcxproj] ..\vp9\common\vp9_loopfilter.c(1312): error C2220: warning treated as error - no 'object' file generated [.build-x86_64-win64-vs10\vpx.vcxproj] Change-Id: Ia69260611997cd2ba41c7184a85ecead740a7c07 --- vp9/common/vp9_loopfilter.c | 35 +++++++++++++++++++++++++---------- 1 file changed, 25 insertions(+), 10 deletions(-) diff --git a/vp9/common/vp9_loopfilter.c b/vp9/common/vp9_loopfilter.c index d41d45e8a..183dec4e7 100644 --- a/vp9/common/vp9_loopfilter.c +++ b/vp9/common/vp9_loopfilter.c @@ -1302,15 +1302,24 @@ void vp9_filter_block_plane_ss00(VP9_COMMON *const cm, // Disable filtering on the leftmost column. #if CONFIG_VP9_HIGHBITDEPTH if (cm->use_highbitdepth) { - highbd_filter_selectively_vert_row2( - plane->subsampling_x, CONVERT_TO_SHORTPTR(dst->buf), dst->stride, - mask_16x16, mask_8x8, mask_4x4, mask_4x4_int, cm->lf_info.lfthr, - &lfm->lfl_y[r << 3], (int)cm->bit_depth); + highbd_filter_selectively_vert_row2(plane->subsampling_x, + CONVERT_TO_SHORTPTR(dst->buf), + dst->stride, + (unsigned int)mask_16x16, + (unsigned int)mask_8x8, + (unsigned int)mask_4x4, + (unsigned int)mask_4x4_int, + cm->lf_info.lfthr, + &lfm->lfl_y[r << 3], + (int)cm->bit_depth); } else { #endif // CONFIG_VP9_HIGHBITDEPTH - filter_selectively_vert_row2( - plane->subsampling_x, dst->buf, dst->stride, mask_16x16, mask_8x8, - mask_4x4, mask_4x4_int, cm->lf_info.lfthr, &lfm->lfl_y[r << 3]); + filter_selectively_vert_row2(plane->subsampling_x, dst->buf, dst->stride, + (unsigned int)mask_16x16, + (unsigned int)mask_8x8, + (unsigned int)mask_4x4, + (unsigned int)mask_4x4_int, + cm->lf_info.lfthr, &lfm->lfl_y[r << 3]); #if CONFIG_VP9_HIGHBITDEPTH } #endif // CONFIG_VP9_HIGHBITDEPTH @@ -1395,14 +1404,20 @@ void vp9_filter_block_plane_ss11(VP9_COMMON *const cm, if (cm->use_highbitdepth) { highbd_filter_selectively_vert_row2(plane->subsampling_x, CONVERT_TO_SHORTPTR(dst->buf), - dst->stride, mask_16x16, mask_8x8, - mask_4x4, mask_4x4_int, + dst->stride, + (unsigned int)mask_16x16, + (unsigned int)mask_8x8, + (unsigned int)mask_4x4, + (unsigned int)mask_4x4_int, cm->lf_info.lfthr, &lfl_uv[r << 1], (int)cm->bit_depth); } else { #endif // CONFIG_VP9_HIGHBITDEPTH filter_selectively_vert_row2(plane->subsampling_x, dst->buf, dst->stride, - mask_16x16, mask_8x8, mask_4x4, mask_4x4_int, + (unsigned int)mask_16x16, + (unsigned int)mask_8x8, + (unsigned int)mask_4x4, + (unsigned int)mask_4x4_int, cm->lf_info.lfthr, &lfl_uv[r << 1]); #if CONFIG_VP9_HIGHBITDEPTH }