diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-02-25 12:59:38 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-02-25 14:56:25 +0000 |
commit | 4b06c351bd573b81b1b4f4ff3df0fd5d8e68e28c (patch) | |
tree | 59df01f2f683cb4b5a13fecb7737b6cc9979baf9 /basebmp | |
parent | 923a8604aa631dbfb9c62f8fa9bef71dc8addcef (diff) |
give basebmp a cairo compatible 24 bit surface
where each unit is actually 32bit with unused upper 8bit.
Change-Id: I5c406cebe406d2db6fda73d744dfd22a99b80ba3
Diffstat (limited to 'basebmp')
-rw-r--r-- | basebmp/source/bitmapdevice.cxx | 9 | ||||
-rw-r--r-- | basebmp/source/debug.cxx | 2 |
2 files changed, 8 insertions, 3 deletions
diff --git a/basebmp/source/bitmapdevice.cxx b/basebmp/source/bitmapdevice.cxx index 34cf2c882ff8..60ad322fc1cb 100644 --- a/basebmp/source/bitmapdevice.cxx +++ b/basebmp/source/bitmapdevice.cxx @@ -107,6 +107,7 @@ static const sal_uInt8 bitsPerPixel[] = 16, // SIXTEEN_BIT_LSB_TC_MASK 16, // SIXTEEN_BIT_MSB_TC_MASK 24, // TWENTYFOUR_BIT_TC_MASK + 32, // TWENTYFOUR_BIT_TC_MASK_BGRU 32, // THIRTYTWO_BIT_TC_MASK_BGRA 32, // THIRTYTWO_BIT_TC_MASK_ARGB 32, // THIRTYTWO_BIT_TC_MASK_ABGR @@ -2076,15 +2077,17 @@ BitmapDeviceSharedPtr createBitmapDeviceImplInner( const basegfx::B2IVector& aBounds, rSize, nScanlineFormat, nScanlineStride, pFirstScanline, pMem, pPal, rDamage ); - - // twentyfour bit formats case FORMAT_TWENTYFOUR_BIT_TC_MASK: return createRenderer<PixelFormatTraits_BGR24,StdMasks>( aBounds, rSize, nScanlineFormat, nScanlineStride, pFirstScanline, pMem, pPal, rDamage ); - + // hybrid cairo 24bits used out of 32bit format + case FORMAT_THIRTYTWO_BIT_TC_MASK_BGRU: + return createRenderer<PixelFormatTraits_BGRU32_8888,StdMasks>( + aBounds, rSize, nScanlineFormat, nScanlineStride, + pFirstScanline, pMem, pPal, rDamage ); // thirtytwo bit formats diff --git a/basebmp/source/debug.cxx b/basebmp/source/debug.cxx index d8348ffd379b..3e719cd77825 100644 --- a/basebmp/source/debug.cxx +++ b/basebmp/source/debug.cxx @@ -63,6 +63,8 @@ namespace basebmp return "SIXTEEN_BIT_MSB_TC_MASK"; case FORMAT_TWENTYFOUR_BIT_TC_MASK: return "TWENTYFOUR_BIT_TC_MASK"; + case FORMAT_THIRTYTWO_BIT_TC_MASK_BGRU: + return "THIRTYTWO_BIT_TC_MASK_BGRU"; case FORMAT_THIRTYTWO_BIT_TC_MASK_BGRA: return "THIRTYTWO_BIT_TC_MASK_BGRA"; case FORMAT_THIRTYTWO_BIT_TC_MASK_ARGB: |