Applet and Command Line Parameters for JavaView

Applet Parameters:

Applets based on javaview.class allow the following parameters to control the visible geometry, adjust camera settings or configure the display. Some parameters are understood by jvLite.class applets too. Applet parameters must be included within the applet tag in an Html page like

<applet ....
    <param name=model value="../models/sampleTorus.jvx">
    <param name=boundingBox value=show>

Command line arguments:

Most parameters are valid both as applet parameters and as command line arguments. Command line arguments can be given as arguments of javaview:

bin\javaview  model=doc/models/sampleTorus.jvx  boundingBox=show

respectively when using the batch file:

bin\javaview.bat  model=doc/models/sampleTorus.jvx  boundingBox=show

or permanently written into both launch files.


Name Value Comment
codebase c:/JavaView

for example:

The JavaView codebase is the default root location on a local file system to search for images and models. Use menu Help->System Props to check the current codebase setting.
language [en] | de | sr

for example:

The language of JavaView menus and dialogs. Default language is Englisch. Use menu Help->Language to change the current language interactively.
jv-lic rsrc/jv-lic.lic

for example:

Location of the license file. By default, JavaView searches for the file
jv-rsrc rsrc/jv-rsrc.jvr

for example:

Location of the JavaView resource file which contains global preference settings of JavaView. Not publicly documented yet.
project classname

for example:

Launch a built-in project of JavaView. The built-in JavaView projects are found in the package vgp.* available in the archive vgpapp.jar. All projects are included in the JavaView executable.

Some projects require geometric models or images to be available.

Most projects have a project panel, and it often makes sense to show this panel. Use menu Inspector->Project or <ctrl-j> to show the panel, or command line arguments:

panel=project   control=show

Some projects allow to changes initial settings using applet parameters.

Currently not usable in conjunction with the parameter model.

vgp.curve.surface.PjSurfCurve, vgp.curve.geodesic.PjGeodesic, vgp.tutor.torusknot.PjTorusKnot, vgp.curve.cycloid.PjCycloid, vgp.curve.elastic.PjElasticCurve, vgp.tutor.parmCurve.PjParmCurve, vgp.game.life.PjLife, vgp.game.mines.PjMinesweeper, vgp.tutor.fractal.PjFractalImage, vgp.tutor.texture.PjTextureCube, vgp.discrete.harmonic.PjHarmonic, jv.loader.PjImportModel, vgp.tutor.model.PjModel, vgp.tutor.key.PjKeyframe, vgp.tutor.ode.PjExprOde, vgp.discrete.harmonic.PjHarmonic, vgp.tutor.rootFinder.PjRootFinder, vgp.surface.common.PjSurface, vgp.discrete.catenoid.PjCatenoid, vgp.minimal.weier.PjWeierstrass, vgp.tutor.parm.PjParmSurface, vgp.discrete.platonic.PjPlatonic, vgp.tutor.lsystem.PjLSystem, vgp.tutor.height.PjHeight, vgp.vector.lic.PjLIC


See animation.html.


Specify an initial geometry with using one and only one of the following parameters. The geometry may either be loaded from a file, or in a few cases supplied as string in the value section.

Name Value Comment
model "doc/models/sampleTorus.jvx" Load a geometry from the given file in any of the supported file formats. The path must be relative to the codebase of the applet.
mathematica "Graphics3D[...]" Full Mathematica graphics object as ASCII string.
maple "Plot3D(...)" Full Maple plot geometry as ASCII string.

Note, if the geometry is supplied as value string then this string must be enclosed with "bracket" and it may not contain any bracket " in its interior. Otherwise, the value will be terminated at the first interior bracket by the browser. As a workaround one may try to replace interior brackets with 'brackets', for example, Maple plots need this workaround.

Loading Camera and Display Settings from a File

The camera and display may be positioned either with the individual parameters (see below) or by loading a display configuration file JVD. Note, camera and display settings specified in a JVD file may be overwritten by individual applet or command line parameters. A JVD file is usually created by saving the current camera and display settings using FILE->SAVE->DISPLAY SETTINGS (JVD), or a file may be edited by hand.

Name Value Comment
displayFile "doc/models/sampleTorus.jvd" Load a display configuration file to configure the camera projection and other display parameters.

Interaction Modes (Left-Mouse Functionality)

By default, the left-mouse is initially either in rotation-orbit mode (3D geometries, perspective cameras) or in translation mode (2D geometries). Note, the initial transformation mode may be configured with a JVD file, but explicit setting will overwrite a JVD setting.


rotate |
rotate-xy |
scale |
translate |
translate-z |
initial |

- free 3D rotation mode
- rotation keeps vertical z-axis
- uniform scaling
- translation in xy-directions of display
- translation in z-direction of display (only visible if perspective!= 0)
- initial pick mode to select initial conditions
- picking and dragging vertices of a geometry
directSelect Show | [Hide] enable direct selection of geometries when clicking on them (shortcut <shift-o>).


Default settings are marked with brackets like [option]. Do not type these brackets.

interest 3 doubles Target point of the camera in world coordinates, the point of interest. The default interest is the origin "0 0 0".
viewDir 3 doubles Viewing direction of the camera, need not be normalized but orthogonal to the upward direction upDir. The default viewing direction of the perspective camera is "0.137 0.824 -0.549".
upDir 3 doubles The upward pointing direction of the camera. Must be orthogonal to the viewing direction viewDir. In the display the upDir becomes the vertical direction in the display if roll is zero.
roll double Rotates the camera around the viewing direction such that in the display the projected upDir has an angle roll with the vertical direction of the display. The angle roll is given in (-Pi, Pi) and default value 0.
distance double The distance of the camera from the interest. By default the distance is adjusted to fit the initial geometry to fill the display to about 80%.
perspective double The perspective distortion of the scene. Default value is 0.5
autoRotate Show | [Hide] Enable the continuous rotation of the camera around the rotation direction rotDir. Rotation of the model in local coordinates will be available later.
rotDir 3 doubles The axis of rotation of the camera during autoRotate. By default rotDir is "0 1 0", that is the vertical axis of the display.


Default settings are marked with brackets like [option]. Do not type these brackets.

antiAlias Show | [Hide] Smooth drawing of edges, no jagging. Leads to slower rendering.
axes Show | [Hide] Show axes around the currently selected geometry.
background 3 integers Background color of the display, for example, "255 0 0" is red.
backgroundImage URL or
File name of a background image whose name must be relative to the codebase of the applet. GIF (including transparency) and JPG formats are supported.
backgroundImageFit Center | Fit |
Resize |
Positioning and tiling of the background image in the display.
border [Show] | Hide Border around the display to provide a sunken effect.
boundingBox Show | [Hide] Bounding box around the scene. Currently, the bounding box is shown around the selected geometry.
copyright Show | [Hide] Show copyright information at the bottom of the display.
depthcue [Show] | Hide Show parts of the geometry darker the farther they are away from the observer. Gives an impression of depth.
edgeAura Show | [Hide] Show a halo effect around edges. This effect is visible only if edges are visible, but faces are not shown.
foregroundImage URL or
File name of a foreground image whose name must be relative to the codebase of the applet. GIF (including transparency) and JPG formats are supported.
foregroundImageFit Center | Fit |
[Resize] |
Positioning and tiling of the foreground image in the display.
frame Show | [Hide] Show a coordinate frame in the lower left corner of the display. Very helpful if transformations in the local or ambient coordinate system are preformed.
sorting [Show] | Hide Use a depth-sort of all geometry items to generate a cheap hidden surface effect. This method is known as Painter's algorithm. See zBuffer for a more accurate but slower method.
zBuffer Show | [Hide] Hidden surface method used for self-intersecting geometries where the cheap sorting algorithm fails. This algorithm works on a raster image.
fastZBuffer Show | [Hide] (beta) Disable the antiAliasing method temporarily during interaction with a geometry. Available only if antiAliasing is active.

Note, display settings specified in a JVD file may be overwritten by applet parameters.

Control Windows and Dialogs

Default settings are marked with brackets like [option]. Do not type these brackets.

panel Project | Info | [Material] | Config | Texture | Camera | Display Select initial panel in the control window if the control window is opened. Some panels like Info, Material, Config and Texture require that a geometry is available which supplies these inspector panels. Otherwise, a default panel is selected which depends on the current applet and project.
console Show | [Hide] Show console window of JavaView with messages or warning information. A warning is indicated by a beep. Note, this console is additional to the Java console windows supplied by some browsers.
control Show | [Hide] Show control window with inspector panels, see parameter panel.

Application Only Command Line Arguments

When running JavaView as application then a few extra command line arguments are available. Default settings are marked with brackets like [option]. Do not type these brackets.

size widthxheight

for example:

Width and height of the JavaView display measured in pixels. Note, very small numbers might be automatically enlarged by the operating system to allow inclusion of border controls.
position widthxheight

for example:

Position of the upper left corner of the JavaView display measured in pixel coordinates. The upper left corner of the computer screen usually is (0,0).
menubar [Show] | Hide Visibility of the menu bar of the JavaView display.
© 1997-2017 Last modified: 22.06.2017 --- www.javaview.de --- The JavaView Project