- 1.7
- 1.6
- 1.5
- Beta
- Examples (for 1.6a)
- Misc
Commands to change the current model's view.
Syntax:
void axisrotateview( | ax, | |
| ay, | ||
| az, | ||
angle); |
double | ax; |
double | ay; |
double | az; |
double | angle; |
Rotate the current view angle degrees about an axis defined between the supplied point {ax,ay,az} and the origin.
Syntax:
void getview( | ); |
Outputs the 3x3 rotation matrix, the camera position vector, and the z-rotation of the camera for the current model's view. The list of numbers may be passed directly to the 'setview' command to re-create the view exactly.
For example:
getview();
Syntax:
void orthographic( | ); |
Set the view for all models to be an orthographic projection.
For example:
orthographic();
Syntax:
void perspective( | ); |
Set the view for all models to be a perspective projection.
For example:
perspective();
Syntax:
void resetview( | ); |
Resets the view rotation and zoom for the current model.
For example:
resetview();
Syntax:
void rotateview( | rotx, | |
roty); |
double | rotx; |
double | roty; |
Rotates the current view by rotx degrees around the x axis and roty degrees around the y axis.
For example:
rotateview(10.0, 0.0);
Syntax:
void setview( | ax, | |
| ay, | ||
| az, | ||
| bx, | ||
| by, | ||
| bz, | ||
| cx, | ||
| cy, | ||
| cz, | ||
| x, | ||
| y, | ||
z); |
double | ax; |
double | ay; |
double | az; |
double | bx; |
double | by; |
double | bz; |
double | cx; |
double | cy; |
double | cz; |
double | x; |
double | y; |
double | z; |
void setview( | ax, | |
| ay, | ||
| az, | ||
| bx, | ||
| by, | ||
| bz, | ||
| cx, | ||
| cy, | ||
| cz, | ||
| x, | ||
| y, | ||
| z, | ||
zrot); |
double | ax; |
double | ay; |
double | az; |
double | bx; |
double | by; |
double | bz; |
double | cx; |
double | cy; |
double | cz; |
double | x; |
double | y; |
double | z; |
double | zrot; |
Sets the current view to the rotation matrix, camera vector, and (if supplied) camera rotation (''zrot'') specified. The 10-number output of getview can be passed to 'setview' to recreate the old camera rotation and position.
For example:
setview(1, 0, 0 ,0, 0, 1, 0, -1, 0, 0.0, 0.0, -10.0);
sets a view with the z axis pointing up, and the y axis normal to the screen (i.e. rotated 90 degrees around the x axis)
Syntax:
void speedtest( | nrenders = 100); |
int | nrenders = 100; |
Performs a quick speed test based on rendering of the current model and general view.
For example:
speedtest();
spins the current model for the default of 100 rendering passes.
speedtest(2000);
spins the current model for 2000 rendering passes.
Syntax:
void translateview( | x, | |
| y, | ||
z); |
double | x; |
double | y; |
double | z; |
Translates the camera viewing the current model.
For example:
translateview(0.0, 0.0, 1.0);
Syntax:
void viewalong( | x, | |
| y, | ||
z); |
double | x; |
double | y; |
double | z; |
Sets the current view so that it is along the specified vector.
For example:
viewalong(0, 0, -1);
view the current model along the negative z-axis.

