Ejemplo n.º 1
0
 def Update(self, object=None):
     if object is not None:
         self.SetSTMTool(object)
     # Updating contourvalues:
     contourvalues = [self.GetSTMTool().GetContourValue()]
     try:  # Does IsoSurface2 exist ?
         self.GetIsoSurface2().SetContourValues(contourvalues)
     except AttributeError:  # No, do nothing
         pass
     self.UpdateVTKData()
     vtkAvatar.Update(self)
Ejemplo n.º 2
0
	def Update(self,object=None):
		"""Updates the avatar

		If the class was initializaed with a grid, it is forced to be 
		reread. Then the child avatars are asked to update themselves.
		"""
		# Is the grid set ?
		if hasattr(self,'_grid'): # Yes, update the vtkStructuredGrid
			self.GetVTKData().ReadFromGrid3D(self.GetGrid3D())
		# Update child avatars
		vtkAvatar.Update(self)
Ejemplo n.º 3
0
	def Update(self,object=None):
		"""Updates the avatar

		This method can be used if the grid has been changed or 
		modified. It forces the vtk data to be reread and then
		asks all the added avatars to update themselves.
		"""
		if object is not None:
			self.SetGrid3D(object)
		self.UpdateVTKData()
		vtkAvatar.Update(self)
Ejemplo n.º 4
0
    def Update(self, object=None):
        """Updates the avatar

		If the class was initialized with a (grid,probearray) they are
		forced to be reread. Then the child avatars are forced to
		update themselves.
		"""
        try:  # Is the grid and probearray defined ?
            self.GetGrid3D()
            self.GetProbeArray()
        except AttributeError:  # No, do nothing
            pass
        else:  # Yes, update the vtkstructuredgrids
            self.GetVTKData().ReadFromGrid3DProbeArray(self.GetGrid3D(),
                                                       self.GetProbeArray())
        # Updating added avatars
        vtkAvatar.Update(self)
Ejemplo n.º 5
0
 def Update(self, object=None):
     if object is not None:
         self.SetEigenState(object)
     self.UpdateVTKData()  # reading the vtkstructuredgrids
     vtkAvatar.Update(self)  # updating added avatars