API Reference for Enthought Tool Suite 3.0.1
The MayaVi application standalone script.
This script parses the command line arguments and launches MayaVi2 suitably. It is meant to be used by those using MayaVi2 as a standalone application.
MayaVi2 wiki page: http://svn.enthought.com/enthought/wiki/MayaVi
Author: Prabhu Ramachandran <prabhu_r@users.sf.net>
A global mayavi instance so we can close it correctly.
mayavi = None
Globals.
OFFSCREEN = False
This closes the mayavi2 application.
Returns if the given namespace contains a 'mayavi' name bound to a mayavi script instance.
Return the mayavi Script instance from the first available set of envisage engines registered in the registry.
This starts up the mayavi2 application.
A factory that creates an offscreen viewer.
Returns the options and arguments parsed via getopts.
Due to the special needs (order of args is important and repeated options will be supplied) of this command line parser we must use getopts and not optparse.
Processes the passed command line arguments.
app -- A MayaVi application instance.
opts -- The list of options returned by getopt.
args -- The remaining arguments returned by getopt.
Execfiles a given script. The name mayavi is bound to the mayavi script instance just like in the embedded interpreter. script_name is the name of the script to execute.
Note that this function uses execfile. You should be careful when using this.
It returns False if everything was OK and True if not.
A decorator to run a function from within mayavi. This lets users write a normal Python function and have that run from within mayavi. It implicitly assumes that the name 'mayavi' refers the the Script instance and will overwrite it if not.
| Local name | Refers to |
|---|---|
| abspath | os.path.abspath |
| exists | os.path.exists |
| get_data_dir | enthought.mayavi.scripts.util.get_data_dir |
| getopt | getopt |
| join | os.path.join |
| logging | logging |
| splitext | os.path.splitext |
| sys | sys |
| types | types |
© Copyright 2002-2008 Enthought, Inc.