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>GXSetTevIndWarp</TITLE>
9</HEAD>
10<BODY>
11<H1 align="left">GXSetTevIndWarp</H1>
12
13<H2>Syntax</H2>
14<dl><dd><pre class="construction">
15#include &lt;revolution/gx.h&gt;
16
17void GXSetTevIndWarp( <A href="../Enumerated_Types/GXTevStageID.html">GXTevStageID</A> tev_stage,
18                      <A href="../Enumerated_Types/GXIndTexStageID.html">GXIndTexStageID</A> ind_stage,
19                      <A href="../Enumerated_Types/GXBool.html">GXBool</A> signed_offsets,
20                      <A href="../Enumerated_Types/GXBool.html">GXBool</A> replace_mode,
21                      <A href="../Enumerated_Types/GXIndTexMtxID.html">GXIndTexMtxID</A> matrix_sel);
22</pre></dd></dl>
23
24<H2>Arguments</H2>
25<TABLE class="arguments" border="1" >
26  <TBODY>
27    <TR>
28      <TH>tev_stage</TH>
29      <TD>TEV stage to be set. Accepted values are: <CODE>GX_TEVSTAGE0</CODE>, <CODE>GX_TEVSTAGE1</CODE>, <CODE>GX_TEVSTAGE2</CODE>, ... , <CODE>GX_TEVSTAGE15</CODE>.</TD>
30    </TR>
31    <TR>
32      <TH>ind_stage</TH>
33      <TD>The indirect stage results used with this TEV stage. <BR>Accepted values are: <CODE>GX_INDTEXSTAGE0</CODE>, <CODE>GX_INDTEXSTAGE1</CODE>, <CODE>GX_INDTEXSTAGE2</CODE> and <CODE>GX_INDTEXSTAGE3</CODE>.</TD>
34    </TR>
35    <TR>
36      <TH>signed_offsets</TH>
37      <TD>Specifies whether the 8-bit offset is signed and biased (<CODE>GX_TRUE</CODE>) or unsigned (<CODE>GX_FALSE</CODE>).</TD>
38    </TR>
39    <TR>
40      <TH>replace_mode</TH>
41      <TD>Specifies whether the offset will replace the regular texture coordinates (<CODE>GX_TRUE</CODE>) or be added to them (<CODE>GX_FALSE</CODE>).</TD>
42    </TR>
43    <TR>
44      <TH>matrix_sel</TH>
45      <TD>Specifies the indirect matrix and scale value for the offset. Accepted values are:<BR>
46      <TABLE class="arguments" border="1" >
47        <TBODY>
48          <TR>
49            <TD bgcolor="#C0C0C0">Name</TD>
50            <TD bgcolor="#C0C0C0">Indirect Matrix and Scale Value Used</TD>
51          </TR>
52          <TR>
53            <TH>GX_ITM_0</TH>
54            <TD>Indirect matrix 0 and matrix scale value 0.</TD>
55          </TR>
56          <TR>
57            <TH>GX_ITM_1</TH>
58            <TD>Indirect matrix 1 and matrix scale value 1.</TD>
59          </TR>
60          <TR>
61            <TH>GX_ITM_2</TH>
62            <TD>Indirect matrix 2 and matrix scale value 2.</TD>
63          </TR>
64        </TBODY>
65      </TABLE>
66      </TD>
67    </TR>
68  </TBODY>
69</TABLE>
70
71<H2>Return Values</H2>
72<P>None.</P>
73
74<H2>Description</H2>
75<P>This function allows an indirect map to warp or distort the texture coordinates used with a regular TEV stage lookup.&nbsp;The indirect map must have 8-bit offsets, which may be signed or unsigned.&nbsp;<B>Signed</B> means <B>biased</B>; if <SPAN class="argument">signed_offsets</SPAN> is <CODE>GX_TRUE</CODE>, 128 is subtracted from the values looked up from the indirect map.&nbsp;The indirect results can either modify or completely replace the regular texture coordinates.&nbsp;The indirect matrix and scale can be used to modify the indirect offsets.</P>
76<p>For users who want to learn more, the following code sample uses the <code><a href="GXSetTevIndirect.html">GXSetTevIndirect</a></code> function to perform operations equivalent to this function.</p>
77<DL><DD><code>{<br> &nbsp;&nbsp;GXSetTevIndirect(<br> &nbsp;&nbsp;&nbsp;&nbsp;tev_stage, &nbsp;&nbsp;&nbsp;// tev stage<br> &nbsp;&nbsp;&nbsp;&nbsp;ind_stage, &nbsp;&nbsp;&nbsp;// indirect stage<br> &nbsp;&nbsp;&nbsp;&nbsp;GX_ITF_8,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;// format<br> &nbsp;&nbsp;&nbsp;&nbsp;(signed_offset) ? GX_ITB_STU : GX_ITB_NONE, // bias<br> &nbsp;&nbsp;&nbsp;&nbsp;(replace_mode) ? GX_ITW_0 : GX_ITW_OFF, &nbsp;&nbsp;&nbsp;&nbsp;//
78  matrix select<br> &nbsp;&nbsp;&nbsp;&nbsp;wrap,&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//
79  wrap direct S<br> &nbsp;&nbsp;&nbsp;&nbsp;wrap,&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//
80  wrap direct T<br> &nbsp;&nbsp;&nbsp;&nbsp;FALSE, &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//
81  add prev stage output?<br>&nbsp;&nbsp;&nbsp;&nbsp;FALSE, &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//
82  use unmodified TC for LOD?<br>&nbsp;&nbsp;&nbsp;&nbsp;GX_ITBA_OFF &nbsp;&nbsp;// bump alpha select<br> &nbsp;&nbsp;);<br> }<br> <br></code></DD></DL>
83
84<H2>See Also</H2>
85<P class="reference">
86<A href="GXSetTevIndirect.html">GXSetTevIndirect</A>
87</P>
88
89<H2>Revision History</H2>
90<P>
912006/03/01 Initial version.<br>
92</P>
93
94<hr><p>CONFIDENTIAL</p></body>
95</HTML>