NAME

glScaled, glScalef - multiply the current matrix by a general scaling matrix

C SPECIFICATION

void ggllSSccaalleedd( GLdouble _x,
               GLdouble _y,
               GLdouble _z )
void ggllSSccaalleeff( GLfloat _x,
               GLfloat _y,
               GLfloat _z )

delim $$

PARAMETERS

_x, _y, _z
Specify scale factors along the _x, _y, and _z axes, respectively.

DESCRIPTION

ggllSSccaallee produces a nonuniform scaling along the _x, _y, and _z axes. The three parameters indicate the desired scale factor along each of the three axes.

The current matrix (see ggllMMaattrriixxMMooddee) is multiplied by this scale matrix, and the product replaces the current matrix as if ggllSSccaallee were called with the following matrix as its argument:

left ( ~ down 20 matrix { ccol { ~"x" above ~0 above ~0 above ~0 } ccol { ~0 above ~"y" above ~0 above ~0 } ccol { ~0 above ~0 above ~"z" above ~0 } ccol { ~0 above ~0 above ~0 above ~1} } ~~ right )

If the matrix mode is either GGLL__MMOODDEELLVVIIEEWW or GGLL__PPRROOJJEECCTTIIOONN, all objects drawn after ggllSSccaallee is called are scaled.

Use ggllPPuusshhMMaattrriixx and ggllPPooppMMaattrriixx to save and restore the unscaled coordinate system.

NOTES

If scale factors other than 1 are applied to the modelview matrix and lighting is enabled, lighting often appears wrong. In that case, enable automatic normalization of normals by calling ggllEEnnaabbllee with the argument GGLL__NNOORRMMAALLIIZZEE.

ERRORS

GGLL__IINNVVAALLIIDD__OOPPEERRAATTIIOONN is generated if ggllSSccaallee is executed between the execution of ggllBBeeggiinn and the corresponding execution of ggllEEnndd.

ASSOCIATED GETS

ggllGGeett with argument GGLL__MMAATTRRIIXX__MMOODDEE
ggllGGeett with argument GGLL__CCOOLLOORR__MMAATTRRIIXX
ggllGGeett with argument GGLL__MMOODDEELLVVIIEEWW__MMAATTRRIIXX
ggllGGeett with argument GGLL__PPRROOJJEECCTTIIOONN__MMAATTRRIIXX
ggllGGeett with argument GGLL__TTEEXXTTUURREE__MMAATTRRIIXX

SEE ALSO

ggllMMaattrriixxMMooddee((33GG)), ggllMMuullttMMaattrriixx((33GG)), ggllPPuusshhMMaattrriixx((33GG)), ggllRRoottaattee((33GG)), ggllTTrraannssllaattee((33GG))