INTEGRATION: CWS canvas02 (1.1.58); FILE MERGED
2005/10/08 13:17:33 thb 1.1.58.2: RESYNC: (1.1-1.2); FILE MERGED 2005/07/28 10:10:18 thb 1.1.58.1: Join from cws_src680_aw024: #i48939# and new rendering subsystem need AW's clipper changes
This commit is contained in:
parent
e895ac9c68
commit
ad0ef45048
1 changed files with 29 additions and 9 deletions
|
@ -4,9 +4,9 @@
|
|||
*
|
||||
* $RCSfile: b2ipoint.cxx,v $
|
||||
*
|
||||
* $Revision: 1.2 $
|
||||
* $Revision: 1.3 $
|
||||
*
|
||||
* last change: $Author: rt $ $Date: 2005-09-07 20:44:10 $
|
||||
* last change: $Author: kz $ $Date: 2005-11-02 13:56:59 $
|
||||
*
|
||||
* The Contents of this file are made available subject to
|
||||
* the terms of GNU Lesser General Public License Version 2.1.
|
||||
|
@ -41,8 +41,9 @@
|
|||
#include <basegfx/matrix/b2dhommatrix.hxx>
|
||||
#endif
|
||||
|
||||
#ifndef _BGFX_NUMERIC_FTOOLS_HXX
|
||||
#include <basegfx/numeric/ftools.hxx>
|
||||
|
||||
#endif
|
||||
|
||||
namespace basegfx
|
||||
{
|
||||
|
@ -55,13 +56,32 @@ namespace basegfx
|
|||
|
||||
B2IPoint& B2IPoint::operator*=( const ::basegfx::B2DHomMatrix& rMat )
|
||||
{
|
||||
mnX = fround( rMat.get(0,0)*mnX +
|
||||
rMat.get(0,1)*mnY +
|
||||
rMat.get(0,2) );
|
||||
double fTempX(
|
||||
rMat.get(0, 0) * mnX +
|
||||
rMat.get(0, 1) * mnY +
|
||||
rMat.get(0, 2));
|
||||
double fTempY(
|
||||
rMat.get(1, 0) * mnX +
|
||||
rMat.get(1, 1) * mnY +
|
||||
rMat.get(1, 2));
|
||||
|
||||
mnY = fround( rMat.get(1,0)*mnX +
|
||||
rMat.get(1,1)*mnY +
|
||||
rMat.get(1,2) );
|
||||
if(!rMat.isLastLineDefault())
|
||||
{
|
||||
const double fOne(1.0);
|
||||
const double fTempM(
|
||||
rMat.get(2, 0) * mnX +
|
||||
rMat.get(2, 1) * mnY +
|
||||
rMat.get(2, 2));
|
||||
|
||||
if(!fTools::equalZero(fTempM) && !fTools::equal(fOne, fTempM))
|
||||
{
|
||||
fTempX /= fTempM;
|
||||
fTempY /= fTempM;
|
||||
}
|
||||
}
|
||||
|
||||
mnX = fround(fTempX);
|
||||
mnY = fround(fTempY);
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue