/[escript]/trunk/pyvisi/py_src/examples/velocity.py
ViewVC logotype

Diff of /trunk/pyvisi/py_src/examples/velocity.py

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

revision 973 by jongui, Tue Feb 13 02:03:23 2007 UTC revision 974 by jongui, Thu Feb 15 04:36:38 2007 UTC
# Line 9  dc1.setFileName(file_name = Line 9  dc1.setFileName(file_name =
9          "/home/jongui/trunk/pyvisi/test/python/data_data/interior_3D.xml")          "/home/jongui/trunk/pyvisi/test/python/data_data/interior_3D.xml")
10    
11  # Create a velocity instance in the first viewport.  # Create a velocity instance in the first viewport.
12  v1 = Velocity(scene = s, data_collector = dc1, vector = None,  v1 = Velocity(scene = s, data_collector = dc1, vector = None, scalar = None,
13          viewport = Viewport.SOUTH_WEST, arrow = Arrow.THREE_D,          viewport = Viewport.SOUTH_WEST, arrow = Arrow.THREE_D,
14          color_mode = ColorMode.VECTOR, lut = Lut.COLOR, outline = True)          color_mode = ColorMode.VECTOR, lut = Lut.COLOR, outline = True)
15  v1.setRepresentationToWireframe()  v1.setRepresentationToWireframe()
# Line 18  v1.setScaleModeByScalar() Line 18  v1.setScaleModeByScalar()
18  v1.setDimension(2,2,2)  v1.setDimension(2,2,2)
19    
20  # Create a velocity instance in the second viewport.  # Create a velocity instance in the second viewport.
21  v2 = Velocity(scene = s, data_collector = dc1, vector = None,  v2 = Velocity(scene = s, data_collector = dc1, vector = None, scalar = None,
22          viewport = Viewport.NORTH_WEST, arrow = Arrow.THREE_D,          viewport = Viewport.NORTH_WEST, arrow = Arrow.THREE_D,
23          color_mode = ColorMode.SCALAR, lut = Lut.COLOR, outline = True)          color_mode = ColorMode.SCALAR, lut = Lut.COLOR, outline = True)
24  v2.setColor(Color.BLUE)  v2.setColor(Color.BLUE)
25  v2.setScaleFactor(0.2)  v2.setScaleFactor(0.2)
26    
27  # Create a velocity instance in the third viewport.  # Create a velocity instance in the third viewport.
28  v3 = Velocity(scene = s, data_collector = dc1, vector = None,  v3 = Velocity(scene = s, data_collector = dc1, vector = None, scalar = None,
29          viewport = Viewport.NORTH_EAST, arrow = Arrow.TWO_D,          viewport = Viewport.NORTH_EAST, arrow = Arrow.TWO_D,
30          color_mode = ColorMode.VECTOR, lut = Lut.GREY_SCALE, outline = True)          color_mode = ColorMode.VECTOR, lut = Lut.GREY_SCALE, outline = True)
31  v3.setScaleFactor(0.2)  v3.setScaleFactor(0.2)
32  v3.setDimension(4,4,4)  v3.setDimension(4,4,4)
33    
34  # Create a velocity instance in the fourth viewport.  # Create a velocity instance in the fourth viewport.
35  v4 = Velocity(scene = s, data_collector = dc1, vector = None,  v4 = Velocity(scene = s, data_collector = dc1, vector = None, scalar = None,
36          viewport = Viewport.SOUTH_EAST,  arrow = Arrow.TWO_D,          viewport = Viewport.SOUTH_EAST,  arrow = Arrow.TWO_D,
37          color_mode = ColorMode.SCALAR, lut = Lut.COLOR, outline = True)          color_mode = ColorMode.SCALAR, lut = Lut.COLOR, outline = True)
38  v4.setOpacity(0.5)  v4.setOpacity(0.5)

Legend:
Removed from v.973  
changed lines
  Added in v.974

  ViewVC Help
Powered by ViewVC 1.1.26