diff options
author | Daniel Robertson <danlrobertson89@gmail.com> | 2015-07-17 12:28:01 -0400 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2015-07-29 06:51:27 +0000 |
commit | b97aa3faa03e5944aac8f3c35a8c198fba295e83 (patch) | |
tree | 7c10524446f7c6fdcca0b9ee1cf763ac1e11eeec /include/vcl/salbtype.hxx | |
parent | e5fc46499126aff725953f73527819e333f13bbc (diff) |
Remove the unnecessary type definition: HPBYTE
HPBYTE is a duplicate defintion of Scanline as seen below.
include/vcl/salbtype.hxx:
34: typedef sal_uInt8* HPBYTE;
35: typedef HPBYTE Scanline;
Remove the definition of HPBYTE and inline the definition of
Scanline. Replace all instances with sal_uInt8*.
Change-Id: I8a79a9d6c45af57fbabf8d3e6a04a1b5eba15a7b
Reviewed-on: https://gerrit.libreoffice.org/17175
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'include/vcl/salbtype.hxx')
-rw-r--r-- | include/vcl/salbtype.hxx | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/include/vcl/salbtype.hxx b/include/vcl/salbtype.hxx index f4ce3cb8fc8b..673c28551593 100644 --- a/include/vcl/salbtype.hxx +++ b/include/vcl/salbtype.hxx @@ -31,8 +31,7 @@ // - Memory - -typedef sal_uInt8* HPBYTE; -typedef HPBYTE Scanline; +typedef sal_uInt8* Scanline; typedef const sal_uInt8* ConstScanline; @@ -216,19 +215,19 @@ public: inline sal_uLong GetBlueMask() const; inline void GetColorFor8Bit( BitmapColor& rColor, const sal_uInt8* pPixel ) const; - inline void SetColorFor8Bit( const BitmapColor& rColor, HPBYTE pPixel ) const; + inline void SetColorFor8Bit( const BitmapColor& rColor, sal_uInt8* pPixel ) const; inline void GetColorFor16BitMSB( BitmapColor& rColor, const sal_uInt8* pPixel ) const; - inline void SetColorFor16BitMSB( const BitmapColor& rColor, HPBYTE pPixel ) const; + inline void SetColorFor16BitMSB( const BitmapColor& rColor, sal_uInt8* pPixel ) const; inline void GetColorFor16BitLSB( BitmapColor& rColor, const sal_uInt8* pPixel ) const; - inline void SetColorFor16BitLSB( const BitmapColor& rColor, HPBYTE pPixel ) const; + inline void SetColorFor16BitLSB( const BitmapColor& rColor, sal_uInt8* pPixel ) const; inline void GetColorFor24Bit( BitmapColor& rColor, const sal_uInt8* pPixel ) const; - inline void SetColorFor24Bit( const BitmapColor& rColor, HPBYTE pPixel ) const; + inline void SetColorFor24Bit( const BitmapColor& rColor, sal_uInt8* pPixel ) const; inline void GetColorFor32Bit( BitmapColor& rColor, const sal_uInt8* pPixel ) const; inline void GetColorAndAlphaFor32Bit( BitmapColor& rColor, sal_uInt8& rAlpha, const sal_uInt8* pPixel ) const; - inline void SetColorFor32Bit( const BitmapColor& rColor, HPBYTE pPixel ) const; + inline void SetColorFor32Bit( const BitmapColor& rColor, sal_uInt8* pPixel ) const; }; // - BitmapBuffer - @@ -651,7 +650,7 @@ inline void ColorMask::GetColorFor8Bit( BitmapColor& rColor, const sal_uInt8* pP MASK_TO_COLOR( nVal, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, rColor ); } -inline void ColorMask::SetColorFor8Bit( const BitmapColor& rColor, HPBYTE pPixel ) const +inline void ColorMask::SetColorFor8Bit( const BitmapColor& rColor, sal_uInt8* pPixel ) const { *pPixel = (sal_uInt8) COLOR_TO_MASK( rColor, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, mnAlphaChannel ); } @@ -663,7 +662,7 @@ inline void ColorMask::GetColorFor16BitMSB( BitmapColor& rColor, const sal_uInt8 MASK_TO_COLOR( nVal, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, rColor ); } -inline void ColorMask::SetColorFor16BitMSB( const BitmapColor& rColor, HPBYTE pPixel ) const +inline void ColorMask::SetColorFor16BitMSB( const BitmapColor& rColor, sal_uInt8* pPixel ) const { const sal_uInt16 nVal = (sal_uInt16)COLOR_TO_MASK( rColor, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, mnAlphaChannel ); @@ -678,7 +677,7 @@ inline void ColorMask::GetColorFor16BitLSB( BitmapColor& rColor, const sal_uInt8 MASK_TO_COLOR( nVal, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, rColor ); } -inline void ColorMask::SetColorFor16BitLSB( const BitmapColor& rColor, HPBYTE pPixel ) const +inline void ColorMask::SetColorFor16BitLSB( const BitmapColor& rColor, sal_uInt8* pPixel ) const { const sal_uInt16 nVal = (sal_uInt16)COLOR_TO_MASK( rColor, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, mnAlphaChannel ); @@ -692,7 +691,7 @@ inline void ColorMask::GetColorFor24Bit( BitmapColor& rColor, const sal_uInt8* p MASK_TO_COLOR( nVal, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, rColor ); } -inline void ColorMask::SetColorFor24Bit( const BitmapColor& rColor, HPBYTE pPixel ) const +inline void ColorMask::SetColorFor24Bit( const BitmapColor& rColor, sal_uInt8* pPixel ) const { const sal_uInt32 nVal = COLOR_TO_MASK( rColor, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, mnAlphaChannel ); pPixel[ 0 ] = (sal_uInt8) nVal; pPixel[ 1 ] = (sal_uInt8) ( nVal >> 8UL ); pPixel[ 2 ] = (sal_uInt8) ( nVal >> 16UL ); @@ -715,7 +714,7 @@ inline void ColorMask::GetColorAndAlphaFor32Bit( BitmapColor& rColor, sal_uInt8& MASK_TO_COLOR( nVal, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, rColor ); } -inline void ColorMask::SetColorFor32Bit( const BitmapColor& rColor, HPBYTE pPixel ) const +inline void ColorMask::SetColorFor32Bit( const BitmapColor& rColor, sal_uInt8* pPixel ) const { const sal_uInt32 nVal = COLOR_TO_MASK( rColor, mnRMask, mnGMask, mnBMask, mnRShift, mnGShift, mnBShift, mnAlphaChannel ); pPixel[ 0 ] = (sal_uInt8) nVal; pPixel[ 1 ] = (sal_uInt8) ( nVal >> 8UL ); |