Kaydet (Commit) 50309b95 authored tarafından Thorsten Behrens's avatar Thorsten Behrens

Another partial fix for fdo#45219

Make sure transparent polygons really only cover the polygonal area,
not the whole bounding box for sprites.
üst 83114b27
...@@ -499,12 +499,11 @@ namespace vclcanvas ...@@ -499,12 +499,11 @@ namespace vclcanvas
} }
if( mp2ndOutDev ) if( mp2ndOutDev )
{
if( !nTransparency || bSourceAlpha )
{ {
// HACK. Normally, CanvasHelper does not care // HACK. Normally, CanvasHelper does not care
// about actually what mp2ndOutDev is... // about actually what mp2ndOutDev is...
if( bSourceAlpha && nTransparency == 255 ) // well, here we do & assume a 1bpp target.
if( nTransparency > 127 )
{ {
mp2ndOutDev->getOutDev().SetDrawMode( DRAWMODE_WHITELINE | DRAWMODE_WHITEFILL | DRAWMODE_WHITETEXT | mp2ndOutDev->getOutDev().SetDrawMode( DRAWMODE_WHITELINE | DRAWMODE_WHITEFILL | DRAWMODE_WHITETEXT |
DRAWMODE_WHITEGRADIENT | DRAWMODE_WHITEBITMAP ); DRAWMODE_WHITEGRADIENT | DRAWMODE_WHITEBITMAP );
...@@ -518,11 +517,6 @@ namespace vclcanvas ...@@ -518,11 +517,6 @@ namespace vclcanvas
mp2ndOutDev->getOutDev().DrawPolyPolygon( aPolyPoly ); mp2ndOutDev->getOutDev().DrawPolyPolygon( aPolyPoly );
} }
} }
else
{
mp2ndOutDev->getOutDev().DrawTransparent( aPolyPoly, (sal_uInt16)nTransPercent );
}
}
} }
// TODO(P1): Provide caching here. // TODO(P1): Provide caching here.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment