[Scummvm-cvs-logs] CVS: residual matrix3.cpp,1.2,1.3 matrix3.h,1.2,1.3 matrix4.cpp,1.2,1.3 matrix4.h,1.2,1.3 model.cpp,1.9,1.10
Vincent Hamm
yazoo at users.sourceforge.net
Wed Oct 1 05:21:03 CEST 2003
Update of /cvsroot/scummvm/residual
In directory sc8-pr-cvs1:/tmp/cvs-serv29227
Modified Files:
matrix3.cpp matrix3.h matrix4.cpp matrix4.h model.cpp
Log Message:
Fixed major problem in matrix code
Index: matrix3.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/matrix3.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- matrix3.cpp 28 Aug 2003 02:01:48 -0000 1.2
+++ matrix3.cpp 1 Oct 2003 12:20:27 -0000 1.3
@@ -163,16 +163,16 @@
return roll;
}
-void Matrix3::transform( Vector3d v )
+void Matrix3::transform( Vector3d* v )
{
float x;
float y;
float z;
- x = v.dotProduct( right_.x(), up_.x(), at_.x() );
- y = v.dotProduct( right_.x(), up_.x(), at_.x() );
- z = v.dotProduct( right_.x(), up_.x(), at_.x() );
+ x = v->dotProduct( right_.x(), up_.x(), at_.x() );
+ y = v->dotProduct( right_.x(), up_.x(), at_.x() );
+ z = v->dotProduct( right_.x(), up_.x(), at_.x() );
- v.set( x, y, z );
+ v->set( x, y, z );
}
Index: matrix3.h
===================================================================
RCS file: /cvsroot/scummvm/residual/matrix3.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- matrix3.h 28 Aug 2003 02:01:48 -0000 1.2
+++ matrix3.h 1 Oct 2003 12:20:27 -0000 1.3
@@ -40,7 +40,7 @@
float getYaw();
float getRoll();
- void transform( Vector3d v );
+ void transform( Vector3d* v );
// operators
Matrix3& operator *=(const Matrix3& s)
Index: matrix4.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/matrix4.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- matrix4.cpp 28 Aug 2003 02:01:48 -0000 1.2
+++ matrix4.cpp 1 Oct 2003 12:20:27 -0000 1.3
@@ -12,7 +12,7 @@
v.set( x, y, z );
- rot_.transform( v );
+ rot_.transform( &v );
pos_ += v;
}
Index: matrix4.h
===================================================================
RCS file: /cvsroot/scummvm/residual/matrix4.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- matrix4.h 28 Aug 2003 02:01:48 -0000 1.2
+++ matrix4.h 1 Oct 2003 12:20:27 -0000 1.3
@@ -42,7 +42,7 @@
Vector3d v;
v = s.pos_;
- rot_.transform( v );
+ rot_.transform( &v );
pos_+=v;
Index: model.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/model.cpp,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- model.cpp 21 Sep 2003 09:51:59 -0000 1.9
+++ model.cpp 1 Oct 2003 12:20:27 -0000 1.10
@@ -156,7 +156,7 @@
v.set( *(pVertices), *(pVertices+1), *(pVertices+2) );
- tempMatrix.rot_.transform( v );
+ tempMatrix.rot_.transform( &v );
v+= tempMatrix.pos_;
GLdouble winX;
@@ -634,7 +634,7 @@
v.set( *(pVertices), *(pVertices+1), *(pVertices+2) );
- tempMatrix.rot_.transform( v );
+ tempMatrix.rot_.transform( &v );
v+= tempMatrix.pos_;
glVertex3f( v.x(), v.y(), v.z() );
@@ -686,7 +686,7 @@
v.set( *(pVertices), *(pVertices+1), *(pVertices+2) );
- tempMatrix.rot_.transform( v );
+ tempMatrix.rot_.transform( &v );
v+= tempMatrix.pos_;
GLdouble winX;
More information about the Scummvm-git-logs
mailing list