/[escript]/trunk/pyvisi/py_src/carpet.py
ViewVC logotype

Diff of /trunk/pyvisi/py_src/carpet.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1209 by jongui, Mon Jul 2 05:46:49 2007 UTC revision 1210 by jongui, Tue Jul 3 05:47:34 2007 UTC
# Line 159  class Carpet(DataSetMapper, Actor3D, War Line 159  class Carpet(DataSetMapper, Actor3D, War
159          if(self.__modified):          if(self.__modified):
160              # Get the bounds of the object in the form of              # Get the bounds of the object in the form of
161              # (xmin, xmax, ymin, ymax, zmin, zmax).              # (xmin, xmax, ymin, ymax, zmin, zmax).
162              bounds = self.__data_collector._getDataCollectorOutput().GetBounds()              bounds = \
163                        self.__data_collector._getDataCollectorOutput().GetBounds()
164              # Length of the z-axis (max - min). Assumption is made that if the              # Length of the z-axis (max - min). Assumption is made that if the
165              # length of the z-axis is equal to zero, the the data set is 2D.              # length of the z-axis is equal to zero, the the data set is 2D.
166              # Otherwise, the data set is 3D. However, there are exceptions              # Otherwise, the data set is 3D. However, there are exceptions
# Line 167  class Carpet(DataSetMapper, Actor3D, War Line 168  class Carpet(DataSetMapper, Actor3D, War
168              # of non-zero, but such exceptions are not taken into account here.              # of non-zero, but such exceptions are not taken into account here.
169              z_axis_length = bounds[5] - bounds[4]              z_axis_length = bounds[5] - bounds[4]
170    
171              if(self.__cell_to_point == True): #Converts cell data to point data.              if(self.__cell_to_point == True): #Convert cell data to point data.
172                  c2p = CellDataToPointData(\                  c2p = CellDataToPointData(\
173                          self.__data_collector._getDataCollectorOutput())                          self.__data_collector._getDataCollectorOutput())
174                  if(z_axis_length != 0): # A cutter is used for 3D data.                  if(z_axis_length != 0): # A cutter is used for 3D data.
# Line 176  class Carpet(DataSetMapper, Actor3D, War Line 177  class Carpet(DataSetMapper, Actor3D, War
177                      self._setupWarp(self._getCutterOutput())                      self._setupWarp(self._getCutterOutput())
178                  elif(z_axis_length == 0): # A cutter is not used for 2D data.                  elif(z_axis_length == 0): # A cutter is not used for 2D data.
179                      self._setupWarp(c2p._getCellToPointOutput())                      self._setupWarp(c2p._getCellToPointOutput())
180    
181              elif(self.__cell_to_point == False): # No conversion happens.                elif(self.__cell_to_point == False): # No conversion happens.  
182                  if(z_axis_length != 0): # A cutter is used for 3D data.                  if(z_axis_length != 0): # A cutter is used for 3D data.
183                      self._setupCutter(\                      self._setupCutter(\

Legend:
Removed from v.1209  
changed lines
  Added in v.1210

  ViewVC Help
Powered by ViewVC 1.1.26