INTEGRATION: CWS presentationengine01 (1.2.2); FILE MERGED
2004/10/13 12:14:04 thb 1.2.2.5: #i34997#: Fixed problem with transparency bitmap rendering 2004/10/12 14:14:41 thb 1.2.2.4: #i34997# Added support for FLOATTRANSPARENCY meta action 2004/07/20 19:09:03 thb 1.2.2.3: #110496# Unified include statements; removed external prefix from boost includes 2004/05/27 20:51:29 thb 1.2.2.2: #110496# Added classification code to all TODO/HACK/FIXME comments. There are four categories: - code quality (C) - performance (P) - missing functionality (F) - and missing/incomplete error handling (E) Furthermore, every category has a severity number between 1 and 3 associated, where 1 is lowest and 3 highest severity 2004/04/05 15:58:51 thb 1.2.2.1: Resync with canvas01 changes
This commit is contained in:
parent
7c80a3d5e2
commit
a869566a7a
@ -2,9 +2,9 @@
|
||||
*
|
||||
* $RCSfile: implbitmap.cxx,v $
|
||||
*
|
||||
* $Revision: 1.2 $
|
||||
* $Revision: 1.3 $
|
||||
*
|
||||
* last change: $Author: thb $ $Date: 2004-03-18 10:41:09 $
|
||||
* last change: $Author: rt $ $Date: 2004-11-26 20:58:48 $
|
||||
*
|
||||
* The Contents of this file are made available subject to the terms of
|
||||
* either of the following licenses
|
||||
@ -59,8 +59,8 @@
|
||||
*
|
||||
************************************************************************/
|
||||
|
||||
#include "implbitmap.hxx"
|
||||
#include "implbitmapcanvas.hxx"
|
||||
#include <implbitmap.hxx>
|
||||
#include <implbitmapcanvas.hxx>
|
||||
|
||||
#ifndef _BGFX_MATRIX_B2DHOMMATRIX_HXX
|
||||
#include <basegfx/matrix/b2dhommatrix.hxx>
|
||||
@ -100,10 +100,12 @@ namespace cppcanvas
|
||||
"ImplBitmap::draw: invalid canvas" );
|
||||
|
||||
if( pCanvas.get() == NULL ||
|
||||
pCanvas->getUNOCanvas().is() )
|
||||
!pCanvas->getUNOCanvas().is() )
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// TODO: implement caching
|
||||
// TODO(P1): implement caching
|
||||
pCanvas->getUNOCanvas()->drawBitmap( mxBitmap,
|
||||
pCanvas->getViewState(),
|
||||
maRenderState );
|
||||
@ -111,6 +113,35 @@ namespace cppcanvas
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ImplBitmap::drawAlphaModulated( double nAlphaModulation ) const
|
||||
{
|
||||
CanvasSharedPtr pCanvas( getCanvas() );
|
||||
|
||||
OSL_ENSURE( pCanvas.get() != NULL &&
|
||||
pCanvas->getUNOCanvas().is(),
|
||||
"ImplBitmap::drawAlphaModulated(): invalid canvas" );
|
||||
|
||||
if( pCanvas.get() == NULL ||
|
||||
!pCanvas->getUNOCanvas().is() )
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
rendering::RenderState aLocalState( maRenderState );
|
||||
aLocalState.DeviceColor.realloc( 4 );
|
||||
aLocalState.DeviceColor[0] = 1.0;
|
||||
aLocalState.DeviceColor[1] = 1.0;
|
||||
aLocalState.DeviceColor[2] = 1.0;
|
||||
aLocalState.DeviceColor[3] = nAlphaModulation;
|
||||
|
||||
// TODO(P1): implement caching
|
||||
pCanvas->getUNOCanvas()->drawBitmapModulated( mxBitmap,
|
||||
pCanvas->getViewState(),
|
||||
aLocalState );
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
BitmapCanvasSharedPtr ImplBitmap::getBitmapCanvas() const
|
||||
{
|
||||
return mpBitmapCanvas;
|
||||
|
Loading…
x
Reference in New Issue
Block a user