GINO Graphics Suite - GINO v9.0  

gRotate

Syntax

[C/C++:]
void gRotate2D(float angle);
void gRotate3D(int axis, float angle);
[F90:]
subroutine gRotate2D(angle)
subroutine gRotate3D(axis, angle)

integer, intent(in) :: axis
real, intent(in) :: angle

Arguments

axis
The axis about which the rotation is made

= GXAXIS, about the X-axis
= GYAXIS, about the Y-axis
= GZAXIS, about the Z-axis

angle
The angle in degrees through which rotation takes place

Description

The routines gRotate2D() and gRotate3D() superimposes a rotation of angle degrees in the current modelling transformation matrix. In the case of gRotate2D() the angle is with respect to the Z axis, but with gRotate3D() the rotation is about the axis specified in the first argument. Rotation is right-handed in sense with respect to the relevant axis.

In space mode (the default) this angle is specified with respect to the current space axes, while in picture mode (see gSetTransformMode()) the angle is specified with respect to the picture axes.

If transforming is not on before this routine is called then gRotate3D() switches it on.

See Also

gRotate2D Usage
gSetTransformMode