summaryrefslogtreecommitdiff
path: root/cppcanvas
diff options
context:
space:
mode:
Diffstat (limited to 'cppcanvas')
-rw-r--r--cppcanvas/source/mtfrenderer/transparencygroupaction.cxx29
1 files changed, 5 insertions, 24 deletions
diff --git a/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx b/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx
index c7cd718fc805..8fdfca98a39e 100644
--- a/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx
+++ b/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx
@@ -120,7 +120,6 @@ namespace cppcanvas
// mxBufferBitmap content
CanvasSharedPtr mpCanvas;
rendering::RenderState maState;
- const double mnAlpha;
};
@@ -151,8 +150,7 @@ namespace cppcanvas
mxBufferBitmap(),
maLastTransformation(),
mpCanvas( rCanvas ),
- maState(),
- mnAlpha( 1.0 )
+ maState()
{
tools::initRenderState(maState,rState);
implSetupTransform( maState, rDstPoint );
@@ -400,27 +398,10 @@ namespace cppcanvas
aLocalState.DeviceColor = maState.DeviceColor;
#endif
- if( ::rtl::math::approxEqual(mnAlpha, 1.0) )
- {
- // no further alpha changes necessary -> draw directly
- mpCanvas->getUNOCanvas()->drawBitmap( mxBufferBitmap,
- mpCanvas->getViewState(),
- aLocalState );
- }
- else
- {
- // add alpha modulation value to DeviceColor
- uno::Sequence<rendering::ARGBColor> aCols(1);
- aCols[0] = rendering::ARGBColor( mnAlpha, 1.0, 1.0, 1.0);
- aLocalState.DeviceColor =
- mpCanvas->getUNOCanvas()->getDevice()->getDeviceColorSpace()->convertFromARGB(
- aCols);
-
- mpCanvas->getUNOCanvas()->drawBitmapModulated( mxBufferBitmap,
- mpCanvas->getViewState(),
- aLocalState );
- }
-
+ // no further alpha changes necessary -> draw directly
+ mpCanvas->getUNOCanvas()->drawBitmap( mxBufferBitmap,
+ mpCanvas->getViewState(),
+ aLocalState );
return true;
}