diff options
author | Thorsten Behrens <thb@openoffice.org> | 2006-06-02 07:50:38 +0000 |
---|---|---|
committer | Thorsten Behrens <thb@openoffice.org> | 2006-06-02 07:50:38 +0000 |
commit | 72e2b8e11ce1ba63430c469d8050ece89291e439 (patch) | |
tree | 5ae70a7b13742a60e92c6ac8e04b341335436d31 /basebmp/source | |
parent | 6a4ea42a8fa08a8b1016b1481aea47d2f02705e8 (diff) |
#i65904# Now calculating stride correctly, even for 1bpp mask images
Diffstat (limited to 'basebmp/source')
-rw-r--r-- | basebmp/source/bitmapdevice.cxx | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/basebmp/source/bitmapdevice.cxx b/basebmp/source/bitmapdevice.cxx index 598ed9dd6a7c..bd7425bf4526 100644 --- a/basebmp/source/bitmapdevice.cxx +++ b/basebmp/source/bitmapdevice.cxx @@ -4,9 +4,9 @@ * * $RCSfile: bitmapdevice.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: thb $ $Date: 2006-06-02 08:36:14 $ + * last change: $Author: thb $ $Date: 2006-06-02 08:50:38 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -1075,7 +1075,8 @@ BitmapDeviceSharedPtr createBitmapDevice( const basegfx::B2IVector& rSize, sal_Int32 nScanlineStride(0); // HACK: 1bpp and 32bpp only, currently - if( nScanlineFormat == Format::ONE_BIT_MSB_PAL ) + if( nScanlineFormat == Format::ONE_BIT_MSB_PAL + || nScanlineFormat == Format::ONE_BIT_MSB_TC_MASK ) nScanlineStride = (rSize.getX() + 7) >> 3; else if( nScanlineFormat == Format::EIGHT_BIT_TC_MASK ) nScanlineStride = rSize.getX(); @@ -1195,7 +1196,8 @@ BitmapDeviceSharedPtr createBitmapDevice( const basegfx::B2IVector& rSize sal_Int32 nScanlineStride(0); // HACK: 1bpp and 32bpp only, currently - if( nScanlineFormat == Format::ONE_BIT_MSB_PAL ) + if( nScanlineFormat == Format::ONE_BIT_MSB_PAL + || nScanlineFormat == Format::ONE_BIT_MSB_TC_MASK ) nScanlineStride = (rSize.getX() + 7) >> 3; else if( nScanlineFormat == Format::EIGHT_BIT_TC_MASK ) nScanlineStride = rSize.getX(); |