Commit a1b92bd7 authored by fbarchard@google.com's avatar fbarchard@google.com

Warning fixes for implicite casts that vs2012 complains about with higher warning levels

BUG=302
TESTED=hammer build
R=tpsiaki@google.com

Review URL: https://webrtc-codereview.appspot.com/6559004

git-svn-id: http://libyuv.googlecode.com/svn/trunk@948 16f28f9a-4ce2-e073-06de-1de4eb20be90
parent c23b817e
Name: libyuv Name: libyuv
URL: http://code.google.com/p/libyuv/ URL: http://code.google.com/p/libyuv/
Version: 947 Version: 948
License: BSD License: BSD
License File: LICENSE License File: LICENSE
......
...@@ -11,6 +11,6 @@ ...@@ -11,6 +11,6 @@
#ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT #ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT
#define INCLUDE_LIBYUV_VERSION_H_ #define INCLUDE_LIBYUV_VERSION_H_
#define LIBYUV_VERSION 947 #define LIBYUV_VERSION 948
#endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT #endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT
...@@ -178,7 +178,7 @@ static void ScaleARGBBilinearDown(int src_width, int src_height, ...@@ -178,7 +178,7 @@ static void ScaleARGBBilinearDown(int src_width, int src_height,
xr = (xr >> 16) + 1; // Right most pixel used. xr = (xr >> 16) + 1; // Right most pixel used.
int clip_src_width = (((xr - xl) + 1 + 3) & ~3) * 4; // Width aligned to 4. int clip_src_width = (((xr - xl) + 1 + 3) & ~3) * 4; // Width aligned to 4.
src_argb += xl * 4; src_argb += xl * 4;
x -= (xl << 16); x -= static_cast<int>(xl << 16);
void (*InterpolateRow)(uint8* dst_argb, const uint8* src_argb, void (*InterpolateRow)(uint8* dst_argb, const uint8* src_argb,
ptrdiff_t src_stride, int dst_width, int source_y_fraction) = ptrdiff_t src_stride, int dst_width, int source_y_fraction) =
InterpolateRow_C; InterpolateRow_C;
......
...@@ -204,8 +204,8 @@ void ScaleColsUp2_C(uint8* dst_ptr, const uint8* src_ptr, ...@@ -204,8 +204,8 @@ void ScaleColsUp2_C(uint8* dst_ptr, const uint8* src_ptr,
} }
// (1-f)a + fb can be replaced with a + f(b-a) // (1-f)a + fb can be replaced with a + f(b-a)
#define BLENDER(a, b, f) (static_cast<int>(a) + \ #define BLENDER(a, b, f) static_cast<uint8>(static_cast<int>(a) + \
((f) * (static_cast<int>(b) - static_cast<int>(a)) >> 16)) (static_cast<int>(f) * (static_cast<int>(b) - static_cast<int>(a)) >> 16))
void ScaleFilterCols_C(uint8* dst_ptr, const uint8* src_ptr, void ScaleFilterCols_C(uint8* dst_ptr, const uint8* src_ptr,
int dst_width, int x, int dx) { int dst_width, int x, int dx) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment