Next Previous Contents

3. Running the program

First we describe a simple example how to run partiview with a supplied sample dataset. Then we describe the different windows that partiview is made up of, and the different commands and keystrokes it listens to.

3.1 Example 1: Hipparcos Bright Star Catalogue 3-D viewing

Start the program using one of the sample "speck" files in the data directory:


       % cd partiview/data
       % ./hipbright
or
       % partiview

and this should come up with a display. You should probably enlarge the window a bit. Mine comes up in roughly a 300 by 300 display window, which may be a bit small (certainly on my screen :-)

Hit the TAB key to bring focus to the (one line) command window inbetween the log screen (top) and viewing screen (bottom). Type the commands


        fov 50                          (field of view 50 degrees)
        jump 0 0 0 80 70 60             (put yourself in the origin
                                        and look at euler angles
                                        RxRyRz (80,70,60)

and it should give a nice comfy view :-) If you ever get lost, use the jump command to go back to a known position and/or viewing angle, or just the center command.

partiview view

[spatial units are parsecs, angle units are degrees]

Now play with the display, use the 't', 'r', 'f' and 'o' keys in the viewing window and use the left and mouse buttons down to (carefully) move around a bit, and make yourself comfortable with moving around. Using the 't' button you get some idea of the distance of the stars by moving back and forth a little (the parallax trick). In fact, if you 't' around a little bit, you may see a green line flashing through the display. This is one of the RGB (xyz) axes attached to the (0,0,0) [our sun] position. You should see Procyon and Sirius exhibit pretty large parallaxes, but Orion is pretty steady since it is several hundred parsecs away. If you move the right mouse button you will zoom in/out and should see our Sun flash by with the red-green-blue axes.

The RGB axes represent the XYZ axes in a cartesian system. For the Hipparchos data the X (red) axis points to RA=0h, Y (green) axis to RA=6h, both in the equatorial plane, and the Z (blue) axis points to the equatorial north pole.

Try and use the middle mouse button (or the 'p' key) to click on Sirius or Procyon, and see if you can get it to view its properties. Now use the 'P' key to switch center to rotation to that star. Sirius is probably a good choice. Move around a bit, and try and get the sun and orion in the same view :-)

[NOTE: these Hipparcos data do not have reliably distance above 100-200 pc, so Orion's distances are probably uncertain to 30%]

A little bit on the types of motion, and what the mouse buttons do



              |     left            middle          right
              |     Button-1        Button-2        Button-3         Shift Button-1
------------------------------------------------------------------------------------
f (fly)       |     fly             'pick'          zoom
o (orbit)     |     orbit           'pick'          zoom
r (rotate)    |     rotate X/Y      'pick'          rotate Z (+bug?)    translate
t (translate) |     translate       'pick'          zoom

The point of origin for rotations can be changed with the 'P' button. First you can try and pick ('p' or Button-2) a point, and if found, hit 'P' to make this point the new rotation center default.


red   = X axis
green = Y axis
blue  = Z axis

3.2 Top Row

The top row, from left to right, shows the following buttons:

More

Nothting implemented here yet.

[g1]

Pulldown g1, g2, ... (or whichever group) is the currently selected group. See object command to make aliases which group is defined to what object. If multiple groups are defined, the next row below this contains a list of all the groups, and their aliases, so you can toggle them to be displayed.

[f]ly

Pulldown to select fly/orbit/rot/tran, which can also be activate by pressing the f/o/r/t keys inside the viewing window.

point

Toggle to turn the points on/off. See also the points command.

poly

Toggle to turn polygons on/off. See also the polygon command.

lbl

Toggle to turn labels on/off. See also the label command.

tex

Toggle to turn textures on/off. See also the texture command.

box

Toggle to turn boxes on/off. See also the boxes command.

#.###

The current displayed value of logslum lum (see below)

logslum lum

Slider controlling a datavar variable (the one selected as luminosity)

3.3 Group row (optional)

When more than one group has been activated (groups of particles or objects can have their own display properties, and be turned on and off at will), a new Group Row will appear as the 2nd row. You can then toggle the display of these groups.

3.4 Time Animation rows (Optional)

The third and fourth row from the top control playing sequences of time, including a trip meter. This time-control bar is only visible when the object has a nonzero time range. Of course when the group

T

The current time (or offset from the tripmeter)

trip

back

dial

|<

>|

+

Current last time where tripmeter was set. You can reset to the first frame with the command step 0

#.####

(Logarithmic) value denoting the speed of animation.

<<

toggle movie move backwards in time

>>

toggle movie move forwards in time

3.5 Camera (path) Animation row

The fifth (or 4th or 3rd, depending if Group and/or TIme rows are present) row from the top controls loading and playing sequences of moving through space

Load...

Brings up a filebrowser to load a .wf path file. This is a file with on each line 7 numbers: xyz location, RxRyRz viewing direction, and FOV (field of view).

Play

Play the currently loaded path

<< < [###] >>>

Control individual path frames

slider

Slider

3.6 Logfile window

The third window from the top contains a logfile of commands gives, and can be resized by dragging the bar between command window and viewing window. The Logfile windows also has a scroll bar on the left. You can direct the mouse to any previous command, and it will show up in the command window. Using the arrow keys this command can then be edited.

3.7 Command window

The Command window is a single line entry window, in which Control Commands can be given. Some commands show their result in the Logfile window, others on the originating console. (unlike Data Commands, which show no feedback). Up-arrow recalls previous commands, and can be edited using the arrow keys and a subset of the emacs control characters.

3.8 Viewing window

The (OpenGL) Viewing window is where all the action occurs. Typically this is where you give single keystroke commands and/or move the mouse for an interactive view of the data. It can be resized two ways: either by resizing the master window, or by picking up the separator between Viewing window and Command window above.

3.9 Example 2: a (starlab) animation

Setting up a small animation in for example Starlab can be done quite simply as follows:


  mkplummer -i -n 20 | mkmass -l 0.5 -u 10.0 | scale -s | kira -d 2 -D x10 > run1
     (lots of output from kira will still appear on the screen)
  partiview run1.cf
  cat run1.cf

     datavar 0 id
     datavar 1 mass
     datavar 2 clump
     kira data2 1
     eval every
     eval lum mass 0 0.01
     eval psize 100
     eval cment 1   1 .7 .3
     eval color clump exact
       

Alternatively, if you had started up partiview without any arguments, the following Control Command (see below) would have done the same


     add read run1.cf

3.10 Example 3: stereo viewing

The 's' key within the viewing window toggles stereo viewing. By default each object is split in a blue and a red part, that should be viewed with a pair of red(left)/blue(right) glasses. Red/Green glasses are also popular in the industry, and you need the change the color


Next Previous Contents