[cig-commits] r20381 - short/3D/PyLith/branches/v1.7-stable/examples/meshing/surface_nurbs/triangles

brad at geodynamics.org brad at geodynamics.org
Mon Jun 18 19:23:35 PDT 2012


Author: brad
Date: 2012-06-18 19:23:34 -0700 (Mon, 18 Jun 2012)
New Revision: 20381

Modified:
   short/3D/PyLith/branches/v1.7-stable/examples/meshing/surface_nurbs/triangles/mkfacets.py
Log:
Fixed call to triangulate.

Modified: short/3D/PyLith/branches/v1.7-stable/examples/meshing/surface_nurbs/triangles/mkfacets.py
===================================================================
--- short/3D/PyLith/branches/v1.7-stable/examples/meshing/surface_nurbs/triangles/mkfacets.py	2012-06-19 00:04:11 UTC (rev 20380)
+++ short/3D/PyLith/branches/v1.7-stable/examples/meshing/surface_nurbs/triangles/mkfacets.py	2012-06-19 02:23:34 UTC (rev 20381)
@@ -5,7 +5,7 @@
 # meshing package if you have installed it.
 
 # Import necessary packages.
-import subprocess
+import os
 # import pdb
 # pdb.set_trace()
 
@@ -15,10 +15,7 @@
 facetsOut = "ruapehu-nzmg-1km.fac"
 
 # Triangulate the points to get connectivities.
-c = open(connectFile, 'w')
-triCall = ["triangulate", vertexFile, "-V"]
-retCode = subprocess.Popen(triCall, stdout=c)
-c.close()
+os.system('triangulate '+vertexFile+' > '+connectFile)
 
 # Read connectivities and vertices.
 v = open(vertexFile, 'r')



More information about the CIG-COMMITS mailing list