/[escript]/trunk/pyvisi/examples/escript_scalarData3D.py
ViewVC logotype

Contents of /trunk/pyvisi/examples/escript_scalarData3D.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 605 - (show annotations)
Mon Mar 20 07:16:27 2006 UTC (14 years, 3 months ago) by gross
File MIME type: text/x-python
File size: 682 byte(s)
pyvisi with vtk runs noe on the altix
1 #!/usr/bin/env python
2
3
4 # $Id: escript_scalarData3D.py,v 1.3 2006/01/03 08:46:20 paultcochrane Exp $
5
6 from esys.escript import *
7 from esys import bruce
8
9 import numarray
10
11 from esys.pyvisi import *
12 from esys.pyvisi.renderers.vtk import *
13
14 online=False
15
16 brickDomain = bruce.Brick(9,9,9,10,10,10)
17 brickFunctionSpace = escript.ContinuousFunction(brickDomain)
18
19 domainData = brickFunctionSpace.getX()
20
21 # plotting scalar data in a 3D array
22 scalarData3D = sin(domainData[0])
23
24 scene = Scene()
25 plot = IsosurfacePlot(scene)
26 plot.setData(scalarData3D)
27 if online: scene.render(pause=True)
28
29 scene.save(fname="escript_scalarData3D_isosurfacePlot.png", format="png")
30
31 # vim: expandtab shiftwidth=4:

  ViewVC Help
Powered by ViewVC 1.1.26