From c43a3a58677b467274ce6c21d7db1a6c0cc65cb4 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Tue, 17 Nov 2015 13:03:23 +0000 Subject: establish that Virtual Devices either match Physical Device depth or ... are 1 or (rarely) 8 bit and lock that down. Change-Id: I3d946ebef34ffb71c5adea7aa420af50e9584e05 --- vcl/headless/svpvd.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'vcl/headless/svpvd.cxx') diff --git a/vcl/headless/svpvd.cxx b/vcl/headless/svpvd.cxx index f861ac76a9d5..3cc8b5f7d91e 100644 --- a/vcl/headless/svpvd.cxx +++ b/vcl/headless/svpvd.cxx @@ -67,10 +67,10 @@ bool SvpSalVirtualDevice::SetSizeUsingBuffer( long nNewDX, long nNewDY, { SvpSalInstance* pInst = SvpSalInstance::s_pDefaultInstance; assert( pInst ); - basebmp::Format nFormat = pInst->getFormatForBitCount( m_nBitCount ); + basebmp::Format nFormat = pInst->getBaseBmpFormatForDeviceFormat(m_eFormat); sal_Int32 nStride = basebmp::getBitmapDeviceStrideForWidth(nFormat, aDevSize.getX()); - if ( m_nBitCount == 1 ) + if (m_eFormat == DeviceFormat::BITMASK) { std::vector< basebmp::Color > aDevPal(2); aDevPal[0] = basebmp::Color( 0, 0, 0 ); -- cgit