diff options
author | mmentovai@google.com <mmentovai@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-22 04:52:11 +0000 |
---|---|---|
committer | mmentovai@google.com <mmentovai@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-22 04:52:11 +0000 |
commit | cbad942609ba0c4b06bb2eccf5e84e255eee1340 (patch) | |
tree | 9cc9be88a55338d5fe67a429355e3f3a785b878b /skia/include | |
parent | 0b908c92984295229c4ebf3d9a04d0f3c631c127 (diff) | |
download | chromium_src-cbad942609ba0c4b06bb2eccf5e84e255eee1340.zip chromium_src-cbad942609ba0c4b06bb2eccf5e84e255eee1340.tar.gz chromium_src-cbad942609ba0c4b06bb2eccf5e84e255eee1340.tar.bz2 |
Clean up warnings in Skia (also sent upstream)
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1209 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'skia/include')
-rw-r--r-- | skia/include/SkColorPriv.h | 8 | ||||
-rw-r--r-- | skia/include/corecg/SkMath.h | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/skia/include/SkColorPriv.h b/skia/include/SkColorPriv.h index f35aa24..477af0d 100644 --- a/skia/include/SkColorPriv.h +++ b/skia/include/SkColorPriv.h @@ -402,7 +402,7 @@ typedef uint16_t SkPMColor16; #define SkG32To4444(g) ((unsigned)(g) >> 4) #define SkB32To4444(b) ((unsigned)(b) >> 4) -static U8CPU SkReplicateNibble(unsigned nib) +static inline U8CPU SkReplicateNibble(unsigned nib) { SkASSERT(nib <= 0xF); return (nib << 4) | nib; @@ -618,7 +618,7 @@ static inline SkPMColor16 SkDitherPixel32To4444(SkPMColor c) Transforms a normal ARGB_8888 into the same byte order as expanded ARGB_4444, but keeps each component 8bits */ -static uint32_t SkExpand_8888(SkPMColor c) +static inline uint32_t SkExpand_8888(SkPMColor c) { return (((c >> SK_R32_SHIFT) & 0xFF) << 24) | (((c >> SK_G32_SHIFT) & 0xFF) << 8) | @@ -629,7 +629,7 @@ static uint32_t SkExpand_8888(SkPMColor c) /* Undo the operation of SkExpand_8888, turning the argument back into a SkPMColor. */ -static SkPMColor SkCompact_8888(uint32_t c) +static inline SkPMColor SkCompact_8888(uint32_t c) { return (((c >> 24) & 0xFF) << SK_R32_SHIFT) | (((c >> 8) & 0xFF) << SK_G32_SHIFT) | @@ -641,7 +641,7 @@ static SkPMColor SkCompact_8888(uint32_t c) but this routine just keeps the high 4bits of each component in the low 4bits of the result (just like a newly expanded PMColor16). */ -static uint32_t SkExpand32_4444(SkPMColor c) +static inline uint32_t SkExpand32_4444(SkPMColor c) { return (((c >> (SK_R32_SHIFT + 4)) & 0xF) << 24) | (((c >> (SK_G32_SHIFT + 4)) & 0xF) << 8) | diff --git a/skia/include/corecg/SkMath.h b/skia/include/corecg/SkMath.h index 7519dee..d9fb274 100644 --- a/skia/include/corecg/SkMath.h +++ b/skia/include/corecg/SkMath.h @@ -209,7 +209,7 @@ static inline U8CPU SkMulDiv255Round(U8CPU a, U8CPU b) { /** Return a*b/((1 << shift) - 1), rounding any fractional bits. Only valid if a and b are unsigned and <= 32767 and shift is > 0 and <= 8 */ -static unsigned SkMul16ShiftRound(unsigned a, unsigned b, int shift) { +static inline unsigned SkMul16ShiftRound(unsigned a, unsigned b, int shift) { SkASSERT(a <= 32767); SkASSERT(b <= 32767); SkASSERT(shift > 0 && shift <= 8); |