aboutsummaryrefslogtreecommitdiffstats
path: root/src/effects/SkGradientShader.cpp
diff options
context:
space:
mode:
authorThe Android Open Source Project <initial-contribution@android.com>2009-01-15 16:12:09 -0800
committerThe Android Open Source Project <initial-contribution@android.com>2009-01-15 16:12:09 -0800
commit76692c34c7e2d69f4e43133e516c580f08caed99 (patch)
treea6af463065559abbd8e86487d19eafc0e4779ded /src/effects/SkGradientShader.cpp
parent03202c9c3dfbf8c4feb0a1ee9b3680817e633f58 (diff)
downloadexternal_skia-76692c34c7e2d69f4e43133e516c580f08caed99.zip
external_skia-76692c34c7e2d69f4e43133e516c580f08caed99.tar.gz
external_skia-76692c34c7e2d69f4e43133e516c580f08caed99.tar.bz2
auto import from //branches/cupcake/...@126645
Diffstat (limited to 'src/effects/SkGradientShader.cpp')
-rw-r--r--src/effects/SkGradientShader.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/effects/SkGradientShader.cpp b/src/effects/SkGradientShader.cpp
index a1674cb..9b5d922 100644
--- a/src/effects/SkGradientShader.cpp
+++ b/src/effects/SkGradientShader.cpp
@@ -608,7 +608,7 @@ private:
};
// Return true if fx, fx+dx, fx+2*dx, ... is always in range
-static bool no_need_for_clamp(int fx, int dx, int count)
+static inline bool no_need_for_clamp(int fx, int dx, int count)
{
SkASSERT(count > 0);
return (unsigned)((fx | (fx + (count - 1) * dx)) >> 8) <= 0xFF;
@@ -733,7 +733,7 @@ bool Linear_Gradient::asABitmap(SkBitmap* bitmap, SkMatrix* matrix,
#ifdef TEST_GRADIENT_DITHER
static void dither_memset16(uint16_t dst[], uint16_t value, uint16_t other, int count)
{
- if ((unsigned)dst & 2)
+ if (reinterpret_cast<uintptr_t>(dst) & 2)
{
*dst++ = value;
count -= 1;