clearer naming

This commit is contained in:
Martin Diehl 2015-10-09 06:26:18 +00:00
parent 61090c955d
commit 8fe443d068
2 changed files with 6 additions and 6 deletions

View File

@ -88,11 +88,11 @@ for name in filenames:
# --- write data -----------------------------------------------------------------------------------
if name:
writer = vtk.vtkXMLRectilinearGridWriter()
(head,tail) = os.path.split(name)
(directory,filename) = os.path.split(name)
writer.SetDataModeToBinary()
writer.SetCompressorTypeToZLib()
writer.SetFileName(os.path.join(head,'mesh_'+os.path.splitext(tail)[0]
+'.'+writer.GetDefaultFileExtension()))
writer.SetFileName(os.path.join(directory,os.path.splitext(filename)[0]
+'.'+writer.GetDefaultFileExtension()))
else:
writer = vtk.vtkDataSetWriter()
writer.WriteToOutputStringOn()

View File

@ -107,11 +107,11 @@ for name in filenames:
#--- write data -----------------------------------------------------------------------------------
if name:
writer = vtk.vtkXMLRectilinearGridWriter()
(head,tail) = os.path.split(name)
(directory,filename) = os.path.split(name)
writer.SetDataModeToBinary()
writer.SetCompressorTypeToZLib()
writer.SetFileName(os.path.join(head,'mesh_'+os.path.splitext(tail)[0]
+'.'+writer.GetDefaultFileExtension()))
writer.SetFileName(os.path.join(directory,os.path.splitext(filename)[0]
+'.'+writer.GetDefaultFileExtension()))
else:
writer = vtk.vtkDataSetWriter()
writer.WriteToOutputStringOn()