diff options
author | Tom Finegan <tomfinegan@google.com> | 2014-02-06 16:32:09 -0800 |
---|---|---|
committer | Tom Finegan <tomfinegan@google.com> | 2014-02-06 17:02:02 -0800 |
commit | 9ff89d9446fbe87396464e149c893394cf702b9e (patch) | |
tree | 847eebe27dbe34e36e68f3a81e49f2cb23aa1c05 | |
parent | 74074c9965278f20cef0e347ccfcd2f2068f41c9 (diff) | |
download | libvpx-9ff89d9446fbe87396464e149c893394cf702b9e.tar libvpx-9ff89d9446fbe87396464e149c893394cf702b9e.tar.gz libvpx-9ff89d9446fbe87396464e149c893394cf702b9e.tar.bz2 libvpx-9ff89d9446fbe87396464e149c893394cf702b9e.zip |
vp8/encoder: Silence MSVC warnings in firstpass.c.
Added some casts to int to silence MSVC warnings.
Change-Id: I72481ec2abd12110cf87a3d0da7a1cbe9ef2f47c
-rw-r--r-- | vp8/encoder/firstpass.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/vp8/encoder/firstpass.c b/vp8/encoder/firstpass.c index 968c7f365..afcda9f34 100644 --- a/vp8/encoder/firstpass.c +++ b/vp8/encoder/firstpass.c @@ -940,9 +940,9 @@ static int64_t estimate_modemvcost(VP8_COMP *cpi, /* Crude estimate of overhead cost from modes * << 9 is the normalization to (bits * 512) used in vp8_bits_per_mb */ - mode_cost =((((av_pct_inter - av_pct_motion) * zz_cost) + - (av_pct_motion * motion_cost) + - (av_intra * intra_cost)) * cpi->common.MBs) * 512; + mode_cost = (int64_t)((((av_pct_inter - av_pct_motion) * zz_cost) + + (av_pct_motion * motion_cost) + + (av_intra * intra_cost)) * cpi->common.MBs) * 512; return mv_cost + mode_cost; } @@ -2310,7 +2310,7 @@ static void define_gf_group(VP8_COMP *cpi, FIRSTPASS_STATS *this_frame) pct_extra = (pct_extra > 20) ? 20 : pct_extra; cpi->twopass.alt_extra_bits = - (cpi->twopass.gf_group_bits * pct_extra) / 100; + (int)(cpi->twopass.gf_group_bits * pct_extra) / 100; cpi->twopass.gf_group_bits -= cpi->twopass.alt_extra_bits; cpi->twopass.alt_extra_bits /= ((cpi->baseline_gf_interval-1)>>1); @@ -2386,7 +2386,7 @@ static void assign_std_frame_bits(VP8_COMP *cpi, FIRSTPASS_STATS *this_frame) target_frame_size = max_bits; if (target_frame_size > cpi->twopass.gf_group_bits) - target_frame_size = cpi->twopass.gf_group_bits; + target_frame_size = (int)cpi->twopass.gf_group_bits; } /* Adjust error and bits remaining */ |