r243: *** empty log message ***
authorKevin M. Rosenberg <kevin@rosenberg.net>
Mon, 4 Dec 2000 04:44:03 +0000 (04:44 +0000)
committerKevin M. Rosenberg <kevin@rosenberg.net>
Mon, 4 Dec 2000 04:44:03 +0000 (04:44 +0000)
libctgraphics/transformmatrix.cpp
libctsupport/xform.cpp

index 12c51926491d68f3cc7688e3b8cef57bb03944b1..7e3c73d91b2500f0e95e65016e45e0bfa9f6abbb 100644 (file)
@@ -9,7 +9,7 @@
 **  This is part of the CTSim program
 **  Copyright (C) 1983-2000 Kevin Rosenberg
 **
 **  This is part of the CTSim program
 **  Copyright (C) 1983-2000 Kevin Rosenberg
 **
-**  $Id: transformmatrix.cpp,v 1.1 2000/07/28 08:28:08 kevin Exp $
+**  $Id: transformmatrix.cpp,v 1.2 2000/12/04 04:44:02 kevin Exp $
 **
 **  This program is free software; you can redistribute it and/or modify
 **  it under the terms of the GNU General Public License (version 2) as
 **
 **  This program is free software; you can redistribute it and/or modify
 **  it under the terms of the GNU General Public License (version 2) as
 **  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 ******************************************************************************/
 
 **  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 ******************************************************************************/
 
+#include <iostream>\r
 #include "ctsupport.h"
 #include "transformmatrix.h"
 #include "ctsupport.h"
 #include "transformmatrix.h"
-#include <iostream>
-
+\r
 
 TransformationMatrix2D::TransformationMatrix2D (double m[3][3])
 {
 
 TransformationMatrix2D::TransformationMatrix2D (double m[3][3])
 {
@@ -92,9 +92,9 @@ TransformationMatrix2D::invert () const
 
   double determ = determinant ();
   if (fabs(determ) < 1E-6) {
 
   double determ = determinant ();
   if (fabs(determ) < 1E-6) {
-    sys_error (ERR_WARNING, "Determinant = %g [TransformationMatrix2D::invert]", determ);
-    print (cout);
-    cout << endl;
+    sys_error (ERR_WARNING, "Determinant = %g [TransformationMatrix2D::invert]", determ);\r
+       print (cout);\r
+       cout << endl;
   }
 
   b[0][0] =  (mtx[1][1] * mtx[2][2] - mtx[2][1] * mtx[1][2]) / determ;
   }
 
   b[0][0] =  (mtx[1][1] * mtx[2][2] - mtx[2][1] * mtx[1][2]) / determ;
index 9836e26c30fe36922d8e28cc60dfde95cc81f58a..219eb9b7c1bca2d515adec5653a77900d5ad865b 100644 (file)
@@ -2,7 +2,7 @@
 **  This is part of the CTSim program
 **  Copyright (C) 1983-2000 Kevin Rosenberg
 **
 **  This is part of the CTSim program
 **  Copyright (C) 1983-2000 Kevin Rosenberg
 **
-**  $Id: xform.cpp,v 1.3 2000/06/19 19:10:08 kevin Exp $
+**  $Id: xform.cpp,v 1.4 2000/12/04 04:44:03 kevin Exp $
 **
 **  This program is free software; you can redistribute it and/or modify
 **  it under the terms of the GNU General Public License (version 2) as
 **
 **  This program is free software; you can redistribute it and/or modify
 **  it under the terms of the GNU General Public License (version 2) as
@@ -126,16 +126,17 @@ mult_mtx2 (const GRFMTX_2D m1, const GRFMTX_2D m2, GRFMTX_2D result)
 {
   GRFMTX_2D temp;
 
 {
   GRFMTX_2D temp;
 
-  for (int row = 0; row < 3; row++)
+  for (int row = 0; row < 3; row++) {
     for (int col = 0; col < 3; col++) {
       temp[row][col] = 0;
       for (int calc = 0; calc < 3; calc++)
     for (int col = 0; col < 3; col++) {
       temp[row][col] = 0;
       for (int calc = 0; calc < 3; calc++)
-       temp[row][col] += m1[row][calc] * m2[calc][col];
-    }
-
-  for (int row = 0; row < 3; row++)
+           temp[row][col] += m1[row][calc] * m2[calc][col];
+    }\r
+  }\r
+\r
+  for (int r = 0; r < 3; r++)
     for (int col = 0; col < 3; col++)
     for (int col = 0; col < 3; col++)
-      result[row][col] = temp[row][col];
+      result[r][col] = temp[r][col];
 }
 
 void 
 }
 
 void