summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-03-16 13:43:08 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-03-16 19:24:10 +0100
commit8015e0a15d1b8c454c26c645c7e8ebee9c4e1ee1 (patch)
tree00f59c45f1efb3cbd928bfe8f374ee42ad9a19db /filter
parentb0967c69d3e08efbc8e3dec807601ac52870792a (diff)
move some mask code from SvxMSDffManager::ImportGraphic inside BitmapEx
part of moving GetMask/GetAlpha touching code inside vcl Change-Id: I46e908ed6216dd521143ca94d2dcbd7e95d8b9ce Reviewed-on: https://gerrit.libreoffice.org/51408 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'filter')
-rw-r--r--filter/source/msfilter/msdffimp.cxx9
1 files changed, 3 insertions, 6 deletions
diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx
index 960fa7f1ed2d..7c77dff78824 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -3822,12 +3822,9 @@ SdrObject* SvxMSDffManager::ImportGraphic( SvStream& rSt, SfxItemSet& rSet, cons
if ( aGraf.GetType() == GraphicType::Bitmap )
{
- BitmapEx aBitmapEx( aGraf.GetBitmapEx() );
- Bitmap aBitmap( aBitmapEx.GetBitmap() );
- Bitmap aMask( aBitmap.CreateMask( MSO_CLR_ToColor( nTransColor, DFF_Prop_pictureTransparent ), 9 ) );
- if ( aBitmapEx.IsTransparent() )
- aMask.CombineSimple( aBitmapEx.GetMask(), BmpCombine::Or );
- aGraf = BitmapEx( aBitmap, aMask );
+ BitmapEx aBitmapEx( aGraf.GetBitmapEx() );
+ aBitmapEx.CombineMaskOr( MSO_CLR_ToColor( nTransColor, DFF_Prop_pictureTransparent ), 9 );
+ aGraf = aBitmapEx;
}
}