summaryrefslogtreecommitdiff
path: root/svx/source
diff options
context:
space:
mode:
authorRüdiger Timm <rt@openoffice.org>2004-04-02 13:06:42 +0000
committerRüdiger Timm <rt@openoffice.org>2004-04-02 13:06:42 +0000
commit8943c7abd8d7e9df7c8af95b445d09d03d221d06 (patch)
tree2ec0c6783ab73116410b795486d4de063ca7876f /svx/source
parent8f68c7665c3f72b5d7b6a70933651cb45442d610 (diff)
INTEGRATION: CWS sj05 (1.30.88); FILE MERGED
2004/03/15 14:29:22 sj 1.30.88.2: RESYNC: (1.30-1.31); FILE MERGED 2004/03/04 10:36:25 sj 1.30.88.1: solved flipping problem
Diffstat (limited to 'svx/source')
-rw-r--r--svx/source/engine3d/obj3d.cxx34
1 files changed, 31 insertions, 3 deletions
diff --git a/svx/source/engine3d/obj3d.cxx b/svx/source/engine3d/obj3d.cxx
index b5e89e4c192a..6153e39cde89 100644
--- a/svx/source/engine3d/obj3d.cxx
+++ b/svx/source/engine3d/obj3d.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: obj3d.cxx,v $
*
- * $Revision: 1.31 $
+ * $Revision: 1.32 $
*
- * last change: $Author: kz $ $Date: 2004-02-26 17:45:55 $
+ * last change: $Author: rt $ $Date: 2004-04-02 14:06:42 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -1123,7 +1123,6 @@ const Matrix4D& E3dObject::GetFullTransform()
bTfHasChanged = FALSE;
}
-
return aFullTfMatrix;
}
@@ -1952,6 +1951,7 @@ E3dCompoundObject::E3dCompoundObject() : E3dObject()
bBytesLeft = FALSE;
bCreateE3dPolyObj = FALSE;
bGeometryValid = FALSE;
+ bFullTfIsPositive = TRUE;
}
E3dCompoundObject::E3dCompoundObject(E3dDefaultAttributes& rDefault) : E3dObject()
@@ -2652,6 +2652,34 @@ void E3dCompoundObject::ReCreateGeometry(BOOL bCreateOldGeometry)
CreateGeometry();
}
+void E3dCompoundObject::GetFullTransform(Matrix4D& rMatrix) const
+{
+ E3dObject::GetFullTransform( rMatrix );
+}
+const Matrix4D& E3dCompoundObject::GetFullTransform()
+{
+ if ( bTfHasChanged )
+ {
+ aFullTfMatrix = aTfMatrix;
+
+ if ( GetParentObj() )
+ aFullTfMatrix *= GetParentObj()->GetFullTransform();
+
+ bTfHasChanged = FALSE;
+
+ // THB: Temporary fix for SJ's flipping problem
+ // TODO: Clarify with AW
+ // Check whether matrix mirrors
+ const bool bIsPositive( aFullTfMatrix.Determinant() >= 0.0 );
+ if( bIsPositive != bFullTfIsPositive )
+ {
+ bGeometryValid = FALSE; // force geometry recreation, which then takes care of flipping
+ bFullTfIsPositive = bIsPositive;
+ }
+ }
+ return aFullTfMatrix;
+}
+
/*************************************************************************
|*
|* Geometrieerzeugung