Table of Contents
xyzview - Display 3-D point (velocity) and time data
xyzview is an program with which 3-D point
data can be interactively displayed. It was initially developed on an SGI
using the gl(3)
library, but using e.g. the VOGL emulator library (available
on most unix platforms) is quite an acceptable alternative if you don’t
have an SGI workstation.
It can also create a set of shadow particles
that represent the orbit of a selected star (see orbit=).
The following parameters are recognized
in any order if the keyword is also given:
- advance to next frame
- write viewfile with
- Viewing angles (xrot,yrot) are controlled
by the X and Y cursor position. In most VOGL library versions you will
have to depress the ’1’ key to get the same effect as on the SGI.
- Viewing scene (z viewing distance and field of view) are controlled by
the X and Y cursor position. In most VOGL library versions you will have
to depress the ’2’ key to get the same effect as on the SGI.
vectors (vscale and vskip) are controlled by the X and Y cursor position.
In most VOGL library versions you will have to depress the ’3’ key to get
the same effect as on the SGI.
color indices on the SGI GL are:
- Point data to display. This
file must be in xyzc or xyzuvwc format, usually created with snapxyz(1NEMO)
- Range of times to display. [Default: all].
factor for data.
- Max number of points to draw in fast mode.
- Draw a cube, scale units high.
- Process at least this many points.
- File with color table (binary) . Default: no colormap.
- Use full screen (no border). [Default: false].
- If given, set screen
- If given, set aspect ratio.
- Disable drawing
- Size of text in points. Default: 20
- ID message
- Output viewing parameters
number of frames to store for movies. 
- Star number (0=first)
to be selected to view the complete orbit of. This is done by creating pseudo-particles,
and hence is somewhat memory consumptive if a lot of snapshots are used.
If this option is used, all particles are loaded automatically. [Default:
- If set, snapshots from subsequent times will be automatically
loaded. This is equivalent to hitting the ’l’ (load all frames) as soon as
the first snapshot would have been loaded. Default: false.
BLACK 0 (background)
in VOGL switching between 1,2 and 3 mousebuttons does not preserve
the setting in the other frames. (orientation, zoom factor)
is a simple example of loading a movie when using the VOGL version (i.e.
on most non-SGI machines). First create a simulation with 33 frames using
hackcode1, then convert the snapshots to xyz frames, and startup xyzview
(note you need to set an environment variable VDEVICE):
hackcode1 out=r 64.dat tstop=4 freqout=8 > /dev/null
snapxyz r64.dat r64.xyz
setenv VDEVICE X11 (if not set yet)
now move the cursor in the window and depresss the ’1’ button and move the
cursor around. You will now interactively roam around in 3D-space. Unfortunately
(?) the cursor position is bound to a viewing angle in absolute screen
coordinates, and not where you last left it. This often confuses users when
they switch between buttons (keys) 1, 2 and 3.
Now switch to the ’2’ button
and instead of roaming around, you now zoom in and out of the picture. ’3’
is somewhat specialized, and attempts to visualize the velocity vectors
at the same time, for a subset of the particles.
Now we we load in all the
frames using the ’l’ key. If you like to do this under a certain zoom factor
and viewing angle, you can set those first with the 1,2,3 keys/cursor positions
and then ’l’ (load) all frames. With the ’m’ key you can switch between movie
mode and display mode. After the frames were loaded, you are still in display
mode. In display mode the 1/2/3 keys/buttons are bound to orientation/zoom/velocity
as you have seen before, in movie mode those are bound to backwards/continues/forwards
motion of the frames. The most useful mode is the continues mode. So, first
hit ’m’ (the ’4’ key is actually equivalent to the ’m’ key) to switch to movie
mode and then hit the ’2’ key and keep it depressed, and move the mouse back
and forth: the position is now bound to which frame will be displayed. If
you like to play with this movie at another viewing angle, hit ’m’ and play
with ’1’, ’2’ and ’3’ to select another viewing, then hit ’m’ again and with ’2’
roam around in time. Happy roaming.
To orient yourself, in rotation mode
when the mouse is in the center of the image, you will see an X-Y view with
the Z axis pointing outwards of the screen. Moving the cursor from the center
to the top, parallel to the screen-Y axis will give an X-Z view (the X axis
did not change position, the Y axis will now point into the screen away
from the observer.
VDEVICE set the display device (X11,postscript,ppostscript,cps,pcps)
src/nbody/xyz source code
Josh Barnes (original), Peter Teuben (animations, orbit viewing)
xx-xxx-90 V1.0 Created JEB
20-jan-93 V1.x minor mods for VOGL emulator PJT
30-mar-97 V2.0b formally released, added examples PJT
4-apr-97 V2.1a made the ’4’ key equivalent to ’m’ PJT
3-sep-00 V2.2 added orbit= orbit viewing PJT
10-dec-03 V3.0 added movie= PJT
Table of Contents