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

Contents of /trunk/pyvisi/py_src/examples/velocityonplanecut.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1056 - (show annotations)
Thu Mar 22 06:52:08 2007 UTC (16 years ago) by jongui
File MIME type: text/x-python
File size: 958 byte(s)
Removed the use of StructuredPointsProbe and replaced it with MaskPoints in the Ellipsoid module. The masking of arrows and ellipsoids should now work for both point and cell data.
1 from esys.pyvisi import Scene, DataCollector, VelocityOnPlaneCut
2 from esys.pyvisi.constant import *
3
4 s = Scene(renderer = Renderer.ONLINE, num_viewport = 1, x_size = 1152,
5 y_size = 864)
6
7 dc1 = DataCollector(source = Source.XML)
8 #dc1.setFileName(file_name =
9 dc1.setFileName(file_name = "/home/jongui/data/laurent/slab/source/slab.xml")
10 # "/home/jongui/trunk/pyvisi/test/python/data_data/interior_3D.xml")
11 #dc1.setActiveVector("velocity_cell")
12
13 # NOTE: There is a difference between performing rotation then followed by
14 # translation and performing translation then followed by rotation.
15
16 # Create a velocity instance.
17 vopc1 = VelocityOnPlaneCut(scene = s, data_collector = dc1,
18 arrow = Arrow.THREE_D, color_mode = ColorMode.VECTOR)
19 vopc1.setScaleFactor(scale_factor = 100000)
20 #vopc1.setPlaneToXY(50000)
21 vopc1.setPlaneToXY()
22 vopc1.setRatio(3)
23 vopc1.randomOn()
24 vopc1.setRatio(25)
25 #vopc1.setDimension(x = 4, y = 4, z = 4)
26
27
28 s.render()
29

  ViewVC Help
Powered by ViewVC 1.1.26