Browse Source

Make aiMatrix4x4t ctor that takes in pos, rot and scale take in const refs. Fixes #284.

Jonne Nauha 11 years ago
parent
commit
199d455261
2 changed files with 3 additions and 3 deletions
  1. 2 2
      include/assimp/matrix4x4.h
  2. 1 1
      include/assimp/matrix4x4.inl

+ 2 - 2
include/assimp/matrix4x4.h

@@ -84,8 +84,8 @@ public:
 	 * @param rotation The rotation as a hamilton quaternion 
 	 * @param rotation The rotation as a hamilton quaternion 
 	 * @param position The position for the x,y,z axes
 	 * @param position The position for the x,y,z axes
 	 */
 	 */
-	aiMatrix4x4t(aiVector3t<TReal>& scaling, aiQuaterniont<TReal>& rotation,
-		aiVector3t<TReal>& position);
+	aiMatrix4x4t(const aiVector3t<TReal>& scaling, const aiQuaterniont<TReal>& rotation,
+		const aiVector3t<TReal>& position);
 
 
 public:
 public:
 
 

+ 1 - 1
include/assimp/matrix4x4.inl

@@ -109,7 +109,7 @@ inline aiMatrix4x4t<TReal>::aiMatrix4x4t (const aiMatrix3x3t<TReal>& m)
 
 
 // ----------------------------------------------------------------------------------------
 // ----------------------------------------------------------------------------------------
 template <typename TReal>
 template <typename TReal>
-inline aiMatrix4x4t<TReal>::aiMatrix4x4t (aiVector3t<TReal>& scaling, aiQuaterniont<TReal>& rotation, aiVector3t<TReal>& position)
+inline aiMatrix4x4t<TReal>::aiMatrix4x4t (const aiVector3t<TReal>& scaling, const aiQuaterniont<TReal>& rotation, const aiVector3t<TReal>& position)
 {
 {
 	// build a 3x3 rotation matrix
 	// build a 3x3 rotation matrix
 	aiMatrix3x3t<TReal> m = rotation.GetMatrix();
 	aiMatrix3x3t<TReal> m = rotation.GetMatrix();