diff options
author | Johannes Schickel | 2012-10-12 00:45:53 +0200 |
---|---|---|
committer | Filippos Karapetis | 2019-04-01 00:29:23 +0300 |
commit | 3d469682fc26831a11f702b3179a167f5bc23d26 (patch) | |
tree | d29193cedd1470376905807c094c79d0610376da /graphics | |
parent | 627fbaf8a04b08cd99b3ffd333e6e74f126485e9 (diff) | |
download | scummvm-rg350-3d469682fc26831a11f702b3179a167f5bc23d26.tar.gz scummvm-rg350-3d469682fc26831a11f702b3179a167f5bc23d26.tar.bz2 scummvm-rg350-3d469682fc26831a11f702b3179a167f5bc23d26.zip |
GRAPHICS: Add a PixelType to ColorMasks.
This PixelType is the underlying type (uint16/uint32) of a pixel specified by
ColorMasks.
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/colormasks.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/graphics/colormasks.h b/graphics/colormasks.h index 41d73b4014..27e6b167ea 100644 --- a/graphics/colormasks.h +++ b/graphics/colormasks.h @@ -96,6 +96,8 @@ struct ColorMasks<565> { kLow2Bits = (3 << kRedShift) | (3 << kGreenShift) | (3 << kBlueShift), kLow3Bits = (7 << kRedShift) | (7 << kGreenShift) | (7 << kBlueShift) }; + + typedef uint16 PixelType; }; template<> @@ -138,6 +140,8 @@ struct ColorMasks<555> { kLow2Bits = (3 << kRedShift) | (3 << kGreenShift) | (3 << kBlueShift), kLow3Bits = (7 << kRedShift) | (7 << kGreenShift) | (7 << kBlueShift) }; + + typedef uint16 PixelType; }; template<> @@ -162,6 +166,8 @@ struct ColorMasks<1555> { kRedBlueMask = kRedMask | kBlueMask }; + + typedef uint16 PixelType; }; template<> @@ -186,6 +192,8 @@ struct ColorMasks<5551> { kRedBlueMask = kRedMask | kBlueMask }; + + typedef uint16 PixelType; }; template<> @@ -217,6 +225,8 @@ struct ColorMasks<4444> { kRedBlueMask = kRedMask | kBlueMask }; + + typedef uint16 PixelType; }; template<> @@ -252,6 +262,8 @@ struct ColorMasks<888> { qlowBits = kLow2Bits, qhighBits = (~kLowBits) & (kRedMask | kBlueMask | kGreenMask) }; + + typedef uint32 PixelType; }; template<> @@ -286,6 +298,8 @@ struct ColorMasks<8888> { qlowBits = kLow2Bits, qhighBits = ~kLow2Bits }; + + typedef uint32 PixelType; }; #ifdef __WII__ @@ -312,6 +326,8 @@ struct ColorMasks<3444> { kRedBlueMask = kRedMask | kBlueMask }; + + typedef uint16 PixelType; }; #endif |