fmmatrix(3W)
fminitpagematrix, fmsetpagematrix, fmgetpagematrix, fmscalepagematrix, fmrotatepagematrix, fmconcatpagematrix - font manager page matrix operations
As shipped in IRIX 6.5.7. Unchanged since IRIX 6.5.
NAME fminitpagematrix, fmsetpagematrix, fmgetpagematrix, fmscalepagematrix, fmrotatepagematrix, fmconcatpagematrix - font manager page matrix operations SYNOPSIS #include <fmclient.h> void fminitpagematrix() void fmsetpagematrix(m) double m[3][2]; void fmgetpagematrix(m) double m[3][2]; void fmscalepagematrix(x) double x; void fmrotatepagematrix(angle) double angle; void fmconcatpagematrix(m) double m[3][2]; DESCRIPTION The argument m points to a 3x2 matrix of doubles, of which you need fill in only the first two rows when loading values. (The third row is reserved for future development and is currently ignored.) This matrix is a two dimensional transformation matrix that you can multiply against the page matrix. (The page matrix is independent of the hardware matrix stack.) You can use this multiplication of the page matrix to scale and rotate text. For more information on two-dimensional transformation matrices, see Chapter 7, "Geometrical Transformations" in Fundamentals of Interactive Computer Graphics by J.D. Foley and A. Van Dam, (Addison- Wesley, 1982). Changing the page matrix changes the page, which you can visualize as a transparent sheet that lies on top of the window. Distorting this sheet changes the appearance of text rendered on it. If you rotate the page, you rotate the text in the window. If you stretch or compress the page (scale the page) you stretch or compress the text on the page. If you are not familiar with using transformation matrices, you should avoid the routines that require the m matrix. Fortunately, you can still perform scales or rotations on the page matrix. Use the fmscalepagematrix and fmrotatepagematrix routines. Currently, the only way to render rotated text is to alter the page matrix. However, you do not always need to scale the page matrix (call fmscalepagematrix) to render text of a different size. In fact, the preferred method for scaling text often is to call fmscalefont. This associates a scaling factor to a given font, which, as in PostScript, begins as a 1-point-high set of characters. But, getting back to the page matrix, use: fminitpagematrix to initialize the page matrix to an identity matrix. fmsetpagematrix to load the page matrix with the floating point values supplied in matrix m. fmgetpagematrix to return the current page matrix in the matrix supplied by the client. fmscalepagematrix to uniformly scale the page matrix by x. fmrotatepagematrix to rotate the page matrix by the specified angle, where the angle (measured in degrees) increases up from the x axis. fmconcatpagematrix to post concatenate the m matrix (supplied by the client) with the current page matrix. SEE ALSO fminit(3W), fmgetfontinfo(3W), fmprstr(3W), fmscalefont(3W), fmsetfont(3W). NOTE This routine is available only in immediate mode.