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

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

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

revision 1001 by jongui, Wed Jan 31 07:17:43 2007 UTC revision 1002 by jongui, Wed Feb 28 06:51:33 2007 UTC
# Line 6  import vtk Line 6  import vtk
6    
7  class Arrow2D:  class Arrow2D:
8      """      """
9      Class that defines 2D arrow.      Class that defines 2D arrows.
10      """      """
11            
12      def __init__(self):      def __init__(self):
13          """          """
14          Initialise the 2D arrow.          Initialise the 2D arrows.
15          """          """
16    
17          self.__vtk_arrow2D = vtk.vtkGlyphSource2D()          self.__vtk_arrow2D = vtk.vtkGlyphSource2D()
# Line 19  class Arrow2D: Line 19  class Arrow2D:
19    
20      def __setupArrow2D(self):      def __setupArrow2D(self):
21          """          """
22          Setup the 2D arrow.          Setup the 2D arrows.
23          """          """
24    
25          # Use arrow instead of cone or sphere.          # Use arrows instead of cone or sphere.
26          self.__vtk_arrow2D.SetGlyphTypeToArrow()          self.__vtk_arrow2D.SetGlyphTypeToArrow()
27          # Fill the inside of the arrow.          # Fill the inside of the arrows.
28          self.__vtk_arrow2D.SetFilled(0)          self.__vtk_arrow2D.SetFilled(0)
29            
30      def _getOutput(self):      def _getOutput(self):
31          """          """
32          Return the output of the 2D arrow.          Return the output of the 2D arrows.
33    
34          @rtype: vtkPolyData          @rtype: vtkPolyData
35          @return: Polygonal data          @return: Polygonal data
# Line 43  class Arrow2D: Line 43  class Arrow2D:
43    
44  class Arrow3D:  class Arrow3D:
45      """      """
46      Class that defines 3D arrow.      Class that defines 3D arrows.
47      """      """
48    
49      def __init__(self):      def __init__(self):
50          """          """
51          Initialise the 3D arrow.          Initialise the 3D arrows.
52          """          """
53    
54          self.__vtk_arrow3D = vtk.vtkArrowSource()          self.__vtk_arrow3D = vtk.vtkArrowSource()
55                    
56      def _getOutput(self):      def _getOutput(self):
57          """          """
58          Return the output of the 3D arrow.          Return the output of the 3D arrows.
59    
60          @rtype: vtkPolyData          @rtype: vtkPolyData
61          @return Polygonal data          @return Polygonal data

Legend:
Removed from v.1001  
changed lines
  Added in v.1002

  ViewVC Help
Powered by ViewVC 1.1.26