[cig-commits] r12740 - short/3D/PyLith/trunk/playpen/euler

willic3 at geodynamics.org willic3 at geodynamics.org
Wed Aug 27 16:36:31 PDT 2008


Author: willic3
Date: 2008-08-27 16:36:31 -0700 (Wed, 27 Aug 2008)
New Revision: 12740

Modified:
   short/3D/PyLith/trunk/playpen/euler/grabpoints.py
Log:
Exclude points that don't have normals defined.



Modified: short/3D/PyLith/trunk/playpen/euler/grabpoints.py
===================================================================
--- short/3D/PyLith/trunk/playpen/euler/grabpoints.py	2008-08-27 22:24:30 UTC (rev 12739)
+++ short/3D/PyLith/trunk/playpen/euler/grabpoints.py	2008-08-27 23:36:31 UTC (rev 12740)
@@ -155,17 +155,18 @@
       if vertex == ucdInd:
         data = lines[lineCount].split()
         normals = [float(data[v0]), float(data[v1]), float(data[v2])]
+	if normals[0] != 0.0 or normals[1] != 0.0 or normals[2] != 0.0:
 
-	if self.outputIndex:
-	  o.write(' %i' % vertex)
+	  if self.outputIndex:
+	    o.write(' %i' % vertex)
 
-        for dim in range(3):
-          o.write(' %.12e' % self.pointCoords[coordCount + dim])
+          for dim in range(3):
+            o.write(' %.12e' % self.pointCoords[coordCount + dim])
 
-        for dim in range(3):
-          o.write(' %.12e' % normals[dim])
+          for dim in range(3):
+            o.write(' %.12e' % normals[dim])
 
-        o.write('\n')
+          o.write('\n')
         vertInd += 1
         coordCount += 3
 



More information about the cig-commits mailing list