1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2<HTML>
3<HEAD>
4<META http-equiv="Content-Type" content="text/html; charset=windows-1252">
5<META name="GENERATOR" content="Microsoft FrontPage 5.0">
6<META http-equiv="Content-Style-Type" content="text/css">
7<LINK rel="stylesheet" type="text/css" href="../../CSS/revolution.css">
8<TITLE>MTXFrustum</TITLE>
9</HEAD>
10<BODY>
11<H1 align="left">MTXFrustum</H1>
12<H2 align="left">C Specification</H2>
13<BLOCKQUOTE><CODE><CODE>#include &lt;revolution/mtx.h&gt;</CODE></CODE></BLOCKQUOTE>
14<BLOCKQUOTE><CODE><CODE>void MTXFrustum (<BR> &nbsp;&nbsp;&nbsp; Mtx44 <EM>m</EM>,<BR> &nbsp;&nbsp;&nbsp; f32&nbsp;&nbsp; <EM>t</EM>,<BR> &nbsp;&nbsp;&nbsp; f32&nbsp;&nbsp; <EM>b</EM>,<BR> &nbsp;&nbsp;&nbsp; f32&nbsp;&nbsp; <EM>l</EM>,<BR> &nbsp;&nbsp;&nbsp; f32&nbsp;&nbsp; <EM>r</EM>,<BR> &nbsp;&nbsp;&nbsp; f32&nbsp;&nbsp; <EM>n</EM>,<BR> &nbsp;&nbsp;&nbsp; f32&nbsp;&nbsp; <EM>f</EM> );</CODE></CODE></BLOCKQUOTE>
15<H2 align="left">Arguments</H2>
16<DIV align="left">
17<TABLE border="1" cellpadding="3" cellspacing="0.1">
18  <TBODY>
19    <TR>
20<TD width="120" valign="top" align="left" bgcolor="#ffffe8"><CODE><STRONG><EM>m</EM></STRONG></CODE></TD>
21<TD width="520">New 4x4 parallel projection matrix.&nbsp;<code><em><strong>m</strong></em></code> may be either a <A href="../structures/Mtx44_Mtx44Ptr.html"><CODE>Mtx44</CODE></A> or a <A href="../structures/Mtx44_Mtx44Ptr.html"><CODE>Mtx44Ptr</CODE></A>..</TD>
22    </TR>
23    <TR>
24<TD width="120" valign="top" align="left" bgcolor="#ffffe8"><CODE><STRONG><EM>t</EM></STRONG></CODE></TD>
25<TD width="520">Top edge of view volume at the near clipping plane.</TD>
26    </TR>
27    <TR>
28<TD width="120" valign="top" align="left" bgcolor="#ffffe8"><CODE><STRONG><EM>b</EM></STRONG></CODE></TD>
29<TD width="520">Bottom edge of view volume at the near clipping plane.</TD>
30    </TR>
31    <TR>
32<TD width="120" valign="top" align="left" bgcolor="#ffffe8"><CODE><STRONG><EM>l</EM></STRONG></CODE></TD>
33<TD width="520">Left edge of view volume at the near clipping plane.</TD>
34    </TR>
35    <TR>
36<TD width="120" valign="top" align="left" bgcolor="#ffffe8"><CODE><STRONG><EM>r</EM></STRONG></CODE></TD>
37<TD width="520">Right edge of view volume at the near clipping plane.</TD>
38    </TR>
39    <TR>
40<TD width="120" valign="top" align="left" bgcolor="#ffffe8"><CODE><STRONG><EM>n</EM></STRONG></CODE></TD>
41<TD width="520">Positive distance to near clipping plane.</TD>
42    </TR>
43    <TR>
44<TD width="120" valign="top" align="left" bgcolor="#ffffe8"><CODE><STRONG><EM>f</EM></STRONG></CODE></TD>
45<TD width="520">Positive distance to far clipping plane.</TD>
46    </TR>
47  </TBODY>
48</TABLE>
49</DIV>
50<H2 align="left">Return Values</H2>
51<P align="left">None.</P>
52<H2 align="left">Description</H2>
53<P>Sets a 4&times;4 perspective projection matrix from viewing volume dimensions. This matrix is used by the <code>GX API</code> to convert points to screen space.</P>
54<P>For typical perspective projections, the axis of projection is the -z axis, so <code><em><strong>t</strong></em></code> = positive, <code><em><strong>b</strong></em></code> = <code>-<em><strong>t</strong></em></code>,<em><strong> <code>r</code></strong></em> = positive,<em><strong> <code>l</code></strong></em> = <code>-<em><strong>r</strong></em></code>. <CODE><EM><STRONG>n</STRONG></EM></CODE> and <CODE><EM><STRONG>f</STRONG></EM></CODE> must both be positive values representing the distance to the near and far clipping planes, respectively.</P>
55<P><B>Note:</B> <CODE><EM><STRONG>m</STRONG></EM></CODE> must possess a negative &quot;Z&quot; value in order to make converted points visible after projection in view space.</P>
56
57
58<H2 align="left">See Also</H2>
59<P align="left"><A href="../structures/Mtx_MtxPtr.html"><CODE>Mtx44, Mtx44Ptr</CODE></A>,
60<A href="MTXOrtho.html"><CODE>MTXOrtho</CODE></A>, <CODE><A href="MTXPerspective.html">MtxPerspective</A></CODE>&nbsp;</P>
61<H2>Revision History</H2>
62<P>2006/03/01 Initial version.</P>
63<hr>
64<P>CONFIDENTIAL</p>
65</BODY>
66</HTML>