.\" Copyright (c) 1994 The Board of Trustees of The Leland Stanford .\" Junior University. All rights reserved. .\" .\" Permission to use, copy, modify and distribute this software and its .\" documentation for any purpose is hereby granted without fee, provided .\" that the above copyright notice and this permission notice appear in .\" all copies of this software and that you do not sell the software. .\" Commercial licensing is available by contacting the author. .\" .\" THE SOFTWARE IS PROVIDED "AS IS" AND WITHOUT WARRANTY OF ANY KIND, .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. .\" .\" Author: .\" Phil Lacroute .\" Computer Systems Laboratory .\" Electrical Engineering Dept. .\" Stanford University .\" .\" $Date: 1994/12/31 19:49:53 $ .\" $Revision: 1.1 $ .\" .\" Macros .\" .FS -- function start .\" is return type of function .\" name and arguments follow on next line .de FS .PD 0v .PP \\$1 .HP 8 .. .\" .FA -- function arguments .\" one argument declaration follows on next line .de FA .IP " " 4 .. .\" .FE -- function end .\" end of function declaration .de FE .PD .. .\" .DS -- display start .de DS .IP " " 4 .. .\" .DE -- display done .de DE .LP .. .TH vpScale 3 "" VolPack .SH NAME vpScale \- multiply the current transformation matrix by a scaling matrix .SH SYNOPSIS #include .sp .FS vpResult \fBvpScale(\fIvpc, sx, sy, sz\fB)\fR .FA vpContext \fI*vpc;\fR .FA double \fIsx\R; .FA double \fIsy\R; .FA double \fIsz\R; .FE .SH ARGUMENTS .IP \fIvpc\fR VolPack context from \fBvpCreateContext.\fR .IP \fIsx\fR Scale factor for the X dimension. .IP \fIsy\fR Scale factor for the Y dimension. .IP \fIsz\fR Scale factor for the Z dimension. .SH DESCRIPTION \fBvpScale\fR is used to multiply the current transformation matrix by a 4-by-4 scaling matrix. The arguments specify independent scale factors for each of the three cartesian axes. The scaling matrix is: .DS .ta 2C 6C 10C 14C sx 0 0 0 .br 0 sy 0 0 .br 0 0 sz 0 .br 0 0 0 1 .DE Use \fBvpCurrentMatrix\fR to set the current transformation matrix. By default, the scaling matrix is post-multiplied (M = M*S where M is the current matrix and S is the scaling matrix). The VP_CONCAT_MODE option to \fBvpSeti\fR can be used to select pre-multiplication. .SH "STATE VARIABLES" The current matrix concatenation parameters can be retrieved with the following state variable codes (see vpGeti(3)): VP_CURRENT_MATRIX, VP_CONCAT_MODE. .SH ERRORS The return value is always VP_OK. .SH SEE ALSO VolPack(3), vpCreateContext(3), vpCurrentMatrix(3)