This section lists some simple useful command line options
mayavi 
--display DISPLAY 
Use DISPLAY for the X display. This option makes sense only when running MayaVi under X.
mayavi 
-g WIDTHxHEIGHT+XOFF+YOFF  
Set the geometry of the main window when it is
launched.  The arguments that can be passed follow the standard X
convention and include the width, height, x offset and y offset of the
window.  This option is also available through
--geometry
mayavi 
-h  
This prints all the available command line options and
exits.  Also available through
--help
mayavi 
-V  
This prints the MayaVi version on the command
line and exits.  Also available through  .  --version
 
mayavi 
filename.mv  
This loads a previously saved MayaVi visualization.
This section lists some advanced command line options. This section is intended for those who already understand how MayaVi works. If you are new to MayaVi it is recommended that you read the rest of the guide and then get back here when you need more advanced command line options.
mayavi 
-d vtk_file.vtk 
Opens a VTK file (even the new XML format is supported)
passed as the argument.  Also available through
--vtk 
mayavi 
-x plot3d_xyz_file  
This opens a PLOT3D co-ordinate file passed as the
argument.  Also available through  . 
--plot3d-xyz  
mayavi 
-q plot3d_q_file  
This opens a PLOT3D solution file passed as the
argument.  Please note that this option must  always
 follow a -q or --plot3d-xyz option.  Also available
through  .
 --plot3d-q  
mayavi 
-e ensight_case_file 
Opens an EnSight case file passed as the argument.  Also
available through --ensight 
mayavi 
-m module-name  
The passed module name is loaded in the current
ModuleManager.  The module name must be a valid one if not you will
get an error message. Also available through  . 
--module  
mayavi 
-f filter-name  
The passed filter name is loaded in the current
ModuleManager.  The filter name must be a valid one if not you will
get an error message. Also available through  .  If the filter is the
--filter  UserDefined filter then it could be specified
as UserDefined:vtkSomeFilter where
vtkSomeFilter is a valid VTK class.  In this
case the filter will not prompt you for the VTK filter to
use.
mayavi 
-z saved-visualization-file  
Loads a previously saved MayaVi visualization file
passed as the argument.  Also available through   and 
--viz   .
 --visualization
 
mayavi 
-M module-manager-file  
Loads a module manager saved to a file.  If a file
that does not exist is given this will simply create a new module
manager that can be populated with filters and modules.  Also
available through  .  --module-mgr 
mayavi 
-w vrml2-file  
Imports a VRML2 scene given an appropriate file.  Also
available through  .
 --vrml  
mayavi 
-3 3DStudio-file  
Imports a 3D Studio scene given an appropriate file.
Also available through  .  --3ds 
mayavi 
-n  
Creates a new window.  Any options passed after this
will apply to this newly created window.  Also available through
 .
 --new-window  
Here are a few interesting examples.
% mayavi examples/heart.mv
This command loads an existing visualization.
% mayavi -z examples/heart.mv -n -z examples/other.mv
 This command loads the heart.mv saved
visualization in one window, creates a new window and loads the
other.mv in the other.
%mayavi -d examples/heart.vtk -m Axes -m GridPlane \>-M new -f Threshold -m IsoSurface \>-n -d examples/heart.vtk -m Outline -m ContourGridPlane
 This command loads a VTK data file called
heart.vtk, loads the Axes,
GridPlane modules in one
ModuleManager.  Then creates a new
ModuleManager and loads a
Threshold filter and an
IsoSurface module in it.  It then opens a new
visualization window, loads the VTK data file,
heart.vtk, the modules
Outline and
ContourGridPlane in it.
The provided options make it possible to construct very useful visualizations from the command line.