Kaydet (Commit) f5895d9e authored tarafından Armin Weiss's avatar Armin Weiss

#i39532# adaptions for solaris version

üst f92e40c6
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: viewinformation2d.hxx,v $ * $RCSfile: viewinformation2d.hxx,v $
* *
* $Revision: 1.1 $ * $Revision: 1.2 $
* *
* last change: $Author: aw $ $Date: 2006-10-19 10:31:22 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:07 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -36,6 +36,13 @@ ...@@ -36,6 +36,13 @@
#ifndef INCLUDED_DRAWINGLAYER_GEOMETRY_VIEWINFORMATION2D_HXX #ifndef INCLUDED_DRAWINGLAYER_GEOMETRY_VIEWINFORMATION2D_HXX
#define INCLUDED_DRAWINGLAYER_GEOMETRY_VIEWINFORMATION2D_HXX #define INCLUDED_DRAWINGLAYER_GEOMETRY_VIEWINFORMATION2D_HXX
// the solaris compiler defines 'sun' as '1'. To avoid that (and to allow
// pre-declarations of com/sun/star namespace), include sal/config.h here
// where sun is redefined as 'sun' (so i guess the problem is known).
#ifndef _SAL_CONFIG_H_
#include <sal/config.h>
#endif
////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////
// predefines // predefines
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: baseprimitive2d.hxx,v $ * $RCSfile: baseprimitive2d.hxx,v $
* *
* $Revision: 1.3 $ * $Revision: 1.4 $
* *
* last change: $Author: aw $ $Date: 2006-11-28 11:03:56 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:07 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -69,7 +69,7 @@ ...@@ -69,7 +69,7 @@
virtual sal_uInt32 getPrimitiveID() const; virtual sal_uInt32 getPrimitiveID() const;
#define ImplPrimitrive2DIDBlock(TheClass, a, b, c, d) \ #define ImplPrimitrive2DIDBlock(TheClass, a, b, c, d) \
sal_uInt32 TheClass##::getPrimitiveID() const { return Create2DPrimitiveID(a, b, c, d); } sal_uInt32 TheClass::getPrimitiveID() const { return Create2DPrimitiveID(a, b, c, d); }
////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////
// predefines // predefines
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: baseprimitive3d.hxx,v $ * $RCSfile: baseprimitive3d.hxx,v $
* *
* $Revision: 1.2 $ * $Revision: 1.3 $
* *
* last change: $Author: aw $ $Date: 2006-11-07 15:49:05 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:07 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -69,7 +69,7 @@ ...@@ -69,7 +69,7 @@
virtual sal_uInt32 getPrimitiveID() const; virtual sal_uInt32 getPrimitiveID() const;
#define ImplPrimitrive3DIDBlock(TheClass, a, b, c, d) \ #define ImplPrimitrive3DIDBlock(TheClass, a, b, c, d) \
sal_uInt32 TheClass##::getPrimitiveID() const { return Create3DPrimitiveID(a, b, c, d); } sal_uInt32 TheClass::getPrimitiveID() const { return Create3DPrimitiveID(a, b, c, d); }
////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////
// basePrimitive3D class // basePrimitive3D class
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
# #
# $RCSfile: makefile.mk,v $ # $RCSfile: makefile.mk,v $
# #
# $Revision: 1.2 $ # $Revision: 1.3 $
# #
# last change: $Author: aw $ $Date: 2006-08-09 16:47:02 $ # last change: $Author: aw $ $Date: 2006-12-13 16:57:07 $
# #
# The Contents of this file are made available subject to # The Contents of this file are made available subject to
# the terms of GNU Lesser General Public License Version 2.1. # the terms of GNU Lesser General Public License Version 2.1.
...@@ -36,6 +36,7 @@ ...@@ -36,6 +36,7 @@
PRJ=..$/.. PRJ=..$/..
PRJNAME=drawinglayer PRJNAME=drawinglayer
TARGET=animation TARGET=animation
ENABLE_EXCEPTIONS=TRUE
# --- Settings ---------------------------------- # --- Settings ----------------------------------
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
# #
# $RCSfile: makefile.mk,v $ # $RCSfile: makefile.mk,v $
# #
# $Revision: 1.1 $ # $Revision: 1.2 $
# #
# last change: $Author: aw $ $Date: 2006-08-09 16:47:33 $ # last change: $Author: aw $ $Date: 2006-12-13 16:57:08 $
# #
# The Contents of this file are made available subject to # The Contents of this file are made available subject to
# the terms of GNU Lesser General Public License Version 2.1. # the terms of GNU Lesser General Public License Version 2.1.
...@@ -36,6 +36,7 @@ ...@@ -36,6 +36,7 @@
PRJ=..$/.. PRJ=..$/..
PRJNAME=drawinglayer PRJNAME=drawinglayer
TARGET=attribute TARGET=attribute
ENABLE_EXCEPTIONS=TRUE
# --- Settings ---------------------------------- # --- Settings ----------------------------------
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: helplineprimitive2d.cxx,v $ * $RCSfile: helplineprimitive2d.cxx,v $
* *
* $Revision: 1.2 $ * $Revision: 1.3 $
* *
* last change: $Author: aw $ $Date: 2006-11-07 15:49:08 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:08 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -94,7 +94,7 @@ namespace drawinglayer ...@@ -94,7 +94,7 @@ namespace drawinglayer
PolygonMarkerPrimitive2D* pNewA = new PolygonMarkerPrimitive2D(aLineA, getRGBColA(), getRGBColB(), fLogicDashLen); PolygonMarkerPrimitive2D* pNewA = new PolygonMarkerPrimitive2D(aLineA, getRGBColA(), getRGBColB(), fLogicDashLen);
aTempPrimitiveTarget.push_back(pNewA); aTempPrimitiveTarget.push_back(pNewA);
const basegfx::B2DVector aPerpendicularNormalizedDirection(getPerpendicular(aNormalizedDirection)); const basegfx::B2DVector aPerpendicularNormalizedDirection(basegfx::getPerpendicular(aNormalizedDirection));
const basegfx::B2DPoint aStartB(aViewPosition - aPerpendicularNormalizedDirection); const basegfx::B2DPoint aStartB(aViewPosition - aPerpendicularNormalizedDirection);
const basegfx::B2DPoint aEndB(aViewPosition + aPerpendicularNormalizedDirection); const basegfx::B2DPoint aEndB(aViewPosition + aPerpendicularNormalizedDirection);
basegfx::B2DPolygon aLineB; basegfx::B2DPolygon aLineB;
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: sceneprimitive2d.cxx,v $ * $RCSfile: sceneprimitive2d.cxx,v $
* *
* $Revision: 1.3 $ * $Revision: 1.4 $
* *
* last change: $Author: aw $ $Date: 2006-11-28 11:03:57 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:08 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -199,15 +199,15 @@ namespace drawinglayer ...@@ -199,15 +199,15 @@ namespace drawinglayer
{ {
if(basegfx::fTools::equalZero(fShearX) && basegfx::fTools::equalZero(fRotate)) if(basegfx::fTools::equalZero(fShearX) && basegfx::fTools::equalZero(fRotate))
{ {
basegfx::B2DVector aScale, aTranslate; basegfx::B2DVector aScaleB, aTranslateB;
double fRotate, fShearX; double fRotateB, fShearXB;
pNewTextBitmap->getTransform().decompose(aScale, aTranslate, fRotate, fShearX); pNewTextBitmap->getTransform().decompose(aScaleB, aTranslateB, fRotateB, fShearXB);
basegfx::B2DVector aViewSize(basegfx::absolute(aScale)); basegfx::B2DVector aViewSizeB(basegfx::absolute(aScaleB));
aViewSize *= rViewInformation.getViewTransformation(); aViewSizeB *= rViewInformation.getViewTransformation();
const Size aSourceSizePixel(pNewTextBitmap->getBitmapEx().GetSizePixel()); const Size aSourceSizePixel(pNewTextBitmap->getBitmapEx().GetSizePixel());
const bool bXEqual(aSourceSizePixel.getWidth() == basegfx::fround(aViewSize.getX())); const bool bXEqual(aSourceSizePixel.getWidth() == basegfx::fround(aViewSizeB.getX()));
const bool bYEqual(aSourceSizePixel.getHeight() == basegfx::fround(aViewSize.getY())); const bool bYEqual(aSourceSizePixel.getHeight() == basegfx::fround(aViewSizeB.getY()));
OSL_ENSURE(bXEqual && bYEqual, "3D renderer produced non-pixel-aligned graphic (!)"); OSL_ENSURE(bXEqual && bYEqual, "3D renderer produced non-pixel-aligned graphic (!)");
} }
} }
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: textprimitive2d.cxx,v $ * $RCSfile: textprimitive2d.cxx,v $
* *
* $Revision: 1.2 $ * $Revision: 1.3 $
* *
* last change: $Author: aw $ $Date: 2006-11-07 15:49:09 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:08 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -334,10 +334,10 @@ namespace drawinglayer ...@@ -334,10 +334,10 @@ namespace drawinglayer
: TextSimplePortionPrimitive2D(rNewTransform, rText, rDXArray, rFontAttributes, rFontColor), : TextSimplePortionPrimitive2D(rNewTransform, rText, rDXArray, rFontAttributes, rFontColor),
meFontUnderline(eFontUnderline), meFontUnderline(eFontUnderline),
meFontStrikeout(eFontStrikeout), meFontStrikeout(eFontStrikeout),
meFontEmphasisMark(eFontEmphasisMark),
meFontRelief(eFontRelief), meFontRelief(eFontRelief),
mbUnderlineAbove(bUnderlineAbove), mbUnderlineAbove(bUnderlineAbove),
mbWordLineMode(bWordLineMode), mbWordLineMode(bWordLineMode),
meFontEmphasisMark(eFontEmphasisMark),
mbEmphasisMarkAbove(bEmphasisMarkAbove), mbEmphasisMarkAbove(bEmphasisMarkAbove),
mbEmphasisMarkBelow(bEmphasisMarkBelow), mbEmphasisMarkBelow(bEmphasisMarkBelow),
mbShadow(bShadow), mbShadow(bShadow),
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: hatchtextureprimitive3d.cxx,v $ * $RCSfile: hatchtextureprimitive3d.cxx,v $
* *
* $Revision: 1.5 $ * $Revision: 1.6 $
* *
* last change: $Author: aw $ $Date: 2006-11-07 15:49:10 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:08 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -94,10 +94,11 @@ namespace drawinglayer ...@@ -94,10 +94,11 @@ namespace drawinglayer
if(getChildren().hasElements()) if(getChildren().hasElements())
{ {
const Primitive3DSequence aSource(getChildren()); const Primitive3DSequence aSource(getChildren());
const sal_Int32 nSourceCount(aSource.getLength()); const sal_uInt32 nSourceCount(aSource.getLength());
std::vector< Primitive3DReference > aDestination; std::vector< Primitive3DReference > aDestination;
sal_uInt32 a, b, c;
for(sal_Int32 a(0L); a < nSourceCount; a++) for(a = 0L; a < nSourceCount; a++)
{ {
// get reference // get reference
const Primitive3DReference xReference(aSource[a]); const Primitive3DReference xReference(aSource[a]);
...@@ -134,28 +135,27 @@ namespace drawinglayer ...@@ -134,28 +135,27 @@ namespace drawinglayer
basegfx::B3DPoint a3N; basegfx::B3DPoint a3N;
basegfx::B3DVector a3X, a3Y; basegfx::B3DVector a3X, a3Y;
bool b2N(false), b2X(false), b2Y(false); bool b2N(false), b2X(false), b2Y(false);
sal_uInt32 a, b;
for(a = 0L; a < nPolyCount; a++) for(b = 0L; b < nPolyCount; b++)
{ {
const basegfx::B3DPolygon aPartPoly(aFillPolyPolygon.getB3DPolygon(a)); const basegfx::B3DPolygon aPartPoly(aFillPolyPolygon.getB3DPolygon(b));
const sal_uInt32 nPointCount(aPartPoly.count()); const sal_uInt32 nPointCount(aPartPoly.count());
basegfx::B2DPolygon aTexPolygon; basegfx::B2DPolygon aTexPolygon;
for(b = 0L; b < nPointCount; b++) for(c = 0L; c < nPointCount; c++)
{ {
const basegfx::B2DPoint a2Candidate(aPartPoly.getTextureCoordinate(b)); const basegfx::B2DPoint a2Candidate(aPartPoly.getTextureCoordinate(c));
if(!b2N) if(!b2N)
{ {
a2N = a2Candidate; a2N = a2Candidate;
a3N = aPartPoly.getB3DPoint(b); a3N = aPartPoly.getB3DPoint(c);
b2N = true; b2N = true;
} }
else if(!b2X && !a2N.equal(a2Candidate)) else if(!b2X && !a2N.equal(a2Candidate))
{ {
a2X = a2Candidate - a2N; a2X = a2Candidate - a2N;
a3X = aPartPoly.getB3DPoint(b) - a3N; a3X = aPartPoly.getB3DPoint(c) - a3N;
b2X = true; b2X = true;
} }
else if(!b2Y && !a2N.equal(a2Candidate) && !a2X.equal(a2Candidate)) else if(!b2Y && !a2N.equal(a2Candidate) && !a2X.equal(a2Candidate))
...@@ -166,7 +166,7 @@ namespace drawinglayer ...@@ -166,7 +166,7 @@ namespace drawinglayer
if(!basegfx::fTools::equalZero(fCross)) if(!basegfx::fTools::equalZero(fCross))
{ {
a3Y = aPartPoly.getB3DPoint(b) - a3N; a3Y = aPartPoly.getB3DPoint(c) - a3N;
b2Y = true; b2Y = true;
} }
} }
...@@ -300,9 +300,9 @@ namespace drawinglayer ...@@ -300,9 +300,9 @@ namespace drawinglayer
const sal_uInt32 nDestSize(aDestination.size()); const sal_uInt32 nDestSize(aDestination.size());
aRetval.realloc(nDestSize); aRetval.realloc(nDestSize);
for(sal_uInt32 b(0L); b < nDestSize; b++) for(a = 0L; a < nDestSize; a++)
{ {
aRetval[b] = aDestination[b]; aRetval[a] = aDestination[a];
} }
} }
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: sdrextrudelathetools3d.cxx,v $ * $RCSfile: sdrextrudelathetools3d.cxx,v $
* *
* $Revision: 1.5 $ * $Revision: 1.6 $
* *
* last change: $Author: aw $ $Date: 2006-10-19 10:38:33 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:08 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -622,7 +622,7 @@ namespace drawinglayer ...@@ -622,7 +622,7 @@ namespace drawinglayer
basegfx::B3DPoint aCenter(basegfx::tools::getRange(rSliceVector[0L].getB3DPolyPolygon()).getCenter()); basegfx::B3DPoint aCenter(basegfx::tools::getRange(rSliceVector[0L].getB3DPolyPolygon()).getCenter());
for(sal_uInt32 a(0L); a < nLoopCount; a++) for(a = 0L; a < nLoopCount; a++)
{ {
const basegfx::B3DPoint aNextCenter(basegfx::tools::getRange(rSliceVector[(a + 1L) % nNumSlices].getB3DPolyPolygon()).getCenter()); const basegfx::B3DPoint aNextCenter(basegfx::tools::getRange(rSliceVector[(a + 1L) % nNumSlices].getB3DPolyPolygon()).getCenter());
const double fLength(basegfx::B3DVector(aNextCenter - aCenter).getLength()); const double fLength(basegfx::B3DVector(aNextCenter - aCenter).getLength());
...@@ -671,7 +671,13 @@ namespace drawinglayer ...@@ -671,7 +671,13 @@ namespace drawinglayer
if(bCreateNormals) if(bCreateNormals)
{ {
const basegfx::B3DVector aNormal(aFront.count() ? -aFront.getB3DPolygon(0L).getNormal() : basegfx::B3DVector(0.0, 0.0, -1.0)); basegfx::B3DVector aNormal(0.0, 0.0, -1.0);
if(aFront.count())
{
aNormal = -aFront.getB3DPolygon(0L).getNormal();
}
impSetNormal(aFront, aNormal); impSetNormal(aFront, aNormal);
if(bHasSlant) if(bHasSlant)
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: vclprocessor2d.cxx,v $ * $RCSfile: vclprocessor2d.cxx,v $
* *
* $Revision: 1.2 $ * $Revision: 1.3 $
* *
* last change: $Author: aw $ $Date: 2006-11-28 11:03:57 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:09 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -960,12 +960,20 @@ namespace drawinglayer ...@@ -960,12 +960,20 @@ namespace drawinglayer
if(pContent) if(pContent)
{ {
const double fConvertColor(1.0 / 255.0);
for(sal_uInt32 y(0L); y < (sal_uInt32)pContent->Height(); y++) for(sal_uInt32 y(0L); y < (sal_uInt32)pContent->Height(); y++)
{ {
for(sal_uInt32 x(0L); x < (sal_uInt32)pContent->Width(); x++) for(sal_uInt32 x(0L); x < (sal_uInt32)pContent->Width(); x++)
{ {
const basegfx::BColor aBColor(rModifier.getModifiedColor(Color(pContent->GetPixel(y, x)).getBColor())); const BitmapColor aBMCol(pContent->GetColor(y, x));
pContent->SetPixel(y, x, BitmapColor(Color(aBColor))); const basegfx::BColor aBSource(
(double)aBMCol.GetRed() * fConvertColor,
(double)aBMCol.GetGreen() * fConvertColor,
(double)aBMCol.GetBlue() * fConvertColor);
const basegfx::BColor aBDest(rModifier.getModifiedColor(aBSource));
pContent->SetPixel(y, x, BitmapColor(Color(aBDest)));
} }
} }
...@@ -1036,7 +1044,7 @@ namespace drawinglayer ...@@ -1036,7 +1044,7 @@ namespace drawinglayer
{ {
// handle, there is no shear and no mirror // handle, there is no shear and no mirror
bPrimitiveAccepted = true; bPrimitiveAccepted = true;
const Font aFont(getVclFontFromFontAttributes(rTextCandidate.getFontAttributes(), aScale, fRotate)); const Font aFont(primitive2d::getVclFontFromFontAttributes(rTextCandidate.getFontAttributes(), aScale, fRotate));
const basegfx::B2DPoint aPoint(aLocalTransform * basegfx::B2DPoint(0.0, 0.0)); const basegfx::B2DPoint aPoint(aLocalTransform * basegfx::B2DPoint(0.0, 0.0));
const Point aStartPoint(basegfx::fround(aPoint.getX()), basegfx::fround(aPoint.getY())); const Point aStartPoint(basegfx::fround(aPoint.getX()), basegfx::fround(aPoint.getY()));
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
* *
* $RCSfile: defaultprocessor3d.cxx,v $ * $RCSfile: defaultprocessor3d.cxx,v $
* *
* $Revision: 1.3 $ * $Revision: 1.4 $
* *
* last change: $Author: aw $ $Date: 2006-10-19 10:39:22 $ * last change: $Author: aw $ $Date: 2006-12-13 16:57:09 $
* *
* The Contents of this file are made available subject to * The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1. * the terms of GNU Lesser General Public License Version 2.1.
...@@ -683,9 +683,9 @@ namespace drawinglayer ...@@ -683,9 +683,9 @@ namespace drawinglayer
if(bUseTex) if(bUseTex)
{ {
const basegfx::B2DPointInterpolator& rA(maGlobalTextureCoordinateInterpolators[rA.getTextureCoordinateIndex()]); const basegfx::B2DPointInterpolator& rLA(maGlobalTextureCoordinateInterpolators[rA.getTextureCoordinateIndex()]);
const basegfx::B2DPointInterpolator& rB(maGlobalTextureCoordinateInterpolators[rB.getTextureCoordinateIndex()]); const basegfx::B2DPointInterpolator& rLB(maGlobalTextureCoordinateInterpolators[rB.getTextureCoordinateIndex()]);
aTex = basegfx::B2DPointInterpolator(rA.getVal(), rB.getVal(), rA.getZVal(), rB.getZVal(), nSpanLength); aTex = basegfx::B2DPointInterpolator(rLA.getVal(), rLB.getVal(), rLA.getZVal(), rLB.getZVal(), nSpanLength);
} }
if(bUseNrm) if(bUseNrm)
...@@ -1073,7 +1073,14 @@ namespace drawinglayer ...@@ -1073,7 +1073,14 @@ namespace drawinglayer
if(impIsValid(rUV, nX, nY)) if(impIsValid(rUV, nX, nY))
{ {
rBColor = Color(mpRead->GetColor(nY, nX)).getBColor(); const double fConvertColor(1.0 / 255.0);
const BitmapColor aBMCol(mpRead->GetColor(nY, nX));
const basegfx::BColor aBSource(
(double)aBMCol.GetRed() * fConvertColor,
(double)aBMCol.GetGreen() * fConvertColor,
(double)aBMCol.GetBlue() * fConvertColor);
rBColor = aBSource;
} }
else else
{ {
...@@ -1087,7 +1094,10 @@ namespace drawinglayer ...@@ -1087,7 +1094,10 @@ namespace drawinglayer
if(impIsValid(rUV, nX, nY)) if(impIsValid(rUV, nX, nY))
{ {
rfOpacity = ((double)(0xff - Color(mpRead->GetColor(nY, nX)).GetLuminance()) * (1.0 / 255.0)); const BitmapColor aBMCol(mpRead->GetColor(nY, nX));
const Color aColor(aBMCol.GetRed(), aBMCol.GetGreen(), aBMCol.GetBlue());
rfOpacity = ((double)(0xff - aColor.GetLuminance()) * (1.0 / 255.0));
} }
else else
{ {
......
...@@ -4,9 +4,9 @@ ...@@ -4,9 +4,9 @@
# #
# $RCSfile: makefile.mk,v $ # $RCSfile: makefile.mk,v $
# #
# $Revision: 1.1 $ # $Revision: 1.2 $
# #
# last change: $Author: aw $ $Date: 2006-08-09 16:58:20 $ # last change: $Author: aw $ $Date: 2006-12-13 16:57:09 $
# #
# The Contents of this file are made available subject to # The Contents of this file are made available subject to
# the terms of GNU Lesser General Public License Version 2.1. # the terms of GNU Lesser General Public License Version 2.1.
...@@ -36,6 +36,7 @@ ...@@ -36,6 +36,7 @@
PRJ=..$/.. PRJ=..$/..
PRJNAME=drawinglayer PRJNAME=drawinglayer
TARGET=texture TARGET=texture
ENABLE_EXCEPTIONS=TRUE
# --- Settings ---------------------------------- # --- Settings ----------------------------------
......
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