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>tex-wrap</TITLE>
9</HEAD>
10<BODY>
11<H1 align="left">tex-wrap</H1>
12
13<H2>Description</H2>
14<P>This program tests texture wrap modes. There are nine texture panels, and all combinations (three modes for s, t directions) are displayed at once. The user can change the scale of each texture coordinate and filter mode (near/linear).</P>
15<H2>Coverage</H2>
16<TABLE border="1" cellpadding="3" cellspacing="0.1" width="640">
17  <TBODY>
18    <TR>
19<TD width="30%" bgcolor="#C0C0C0"><EM><STRONG>Function</STRONG></EM></TD>
20<TD width="25%" bgcolor="#C0C0C0"><EM><STRONG>Parameters</STRONG></EM></TD>
21<TD width="45%" bgcolor="#C0C0C0"><EM><STRONG>Description</STRONG></EM></TD>
22    </TR>
23    <TR>
24<TD width="30%" rowspan="5"><A href="../../../gx/Texture/GXInitTexObj.html"><CODE>GXInitTexObj</CODE></A></TD>
25<TD width="25%">Pointer to image data.</TD>
26<TD width="45%">Appropriate value.</TD>
27    </TR>
28    <TR>
29<TD width="25%">Width and height</TD>
30<TD width="45%">Power of 2 only.</TD>
31    </TR>
32    <TR>
33<TD width="25%">Format</TD>
34<TD width="45%">Always <CODE>GX_TF_RGB5A3</CODE>.</TD>
35    </TR>
36    <TR>
37<TD width="25%">Wrap mode (s, t).</TD>
38<TD width="45%"><CODE>GX_CLAMP</CODE>, <CODE>GX_REPEAT</CODE>, <CODE>GX_MIRROR</CODE></TD>
39    </TR>
40    <TR>
41<TD width="25%">Mipmap</TD>
42<TD width="45%"><FONT face="Courier New">GX_TRUE</FONT> / <FONT face="Courier New">GX_FALSE</FONT></TD>
43    </TR>
44    <TR>
45<TD width="30%" rowspan="8"><A href="../../../gx/Texture/GXInitTexObjLOD.html"><CODE>GXInitTexObjLOD</CODE></A></TD>
46<TD width="25%">Reduction filter</TD>
47<TD width="45%"><CODE>GX_NEAR</CODE>, <CODE>GX_LINEAR</CODE>, <CODE>GX_NEAR_MIP_LIN</CODE>,&nbsp; <CODE>GX_LIN_MIP_LIN</CODE></TD>
48    </TR>
49    <TR>
50<TD width="25%">Magnification filter</TD>
51<TD width="45%"><CODE>GX_NEAR</CODE>, <CODE>GX_LINEAR</CODE></TD>
52    </TR>
53    <TR>
54<TD width="25%">Minimum LOD</TD>
55<TD width="45%">Always 0 (depends on tpl file).</TD>
56    </TR>
57    <TR>
58<TD width="25%">Max LOD</TD>
59<TD width="45%">Existing values (depends on tpl file).</TD>
60    </TR>
61    <TR>
62<TD width="25%">LOD bias</TD>
63<TD width="45%">Always 0 (depends on tpl file).</TD>
64    </TR>
65    <TR>
66<TD width="25%">Bias clamp</TD>
67<TD width="45%">Always <CODE>GX_FALSE</CODE>.</TD>
68    </TR>
69    <TR>
70<TD width="25%">Edge LOD enable</TD>
71<TD width="45%">always <CODE>GX_FALSE</CODE> (depends on tpl file).</TD>
72    </TR>
73    <TR>
74<TD width="25%">Anisotropic filter</TD>
75<TD width="45%">always <CODE>GX_ANISO_1</CODE>.</TD>
76    </TR>
77    <TR>
78<TD width="30%"><A href="../../../gx/Texture/GXLoadTexObj.html"><CODE>GXLoadTexObj</CODE></A></TD>
79<TD width="25%">Destination texture name.</TD>
80<TD width="45%">Always <CODE>GX_TEXMAP0</CODE>.</TD>
81    </TR>
82    <TR>
83<TD width="30%" rowspan="2"><A href="../../../gx/Tev/GXSetTevOp.html"><CODE>GXSetTevOp</CODE></A></TD>
84<TD width="25%">TEV stage ID</TD>
85<TD width="45%">Always <FONT face="Courier New">GX_TEVSTAGE0</FONT>.</TD>
86    </TR>
87    <TR>
88<TD width="25%">Operation mode</TD>
89<TD width="45%">Always <CODE>GX_REPLACE</CODE>.</TD>
90    </TR>
91  </TBODY>
92</TABLE>
93<H2>Operation Method</H2>
94<P>START exits the test.</P>
95<P>The Control Stick changes the scale of each s, t texture coordinate.</P>
96<P>The A Button changes the texture.</P>
97<P>The B Button changes filter mode (Near / Linear).</P>
98<P>The X Button resets texture coordinates.</P>
99<H2>Snapshot</H2>
100<P>Arrow texture is displayed.</P>
101<P>(s coordinate) Left: <code>GX_REPEAT</code>, Center: <code>GX_CLAMP</code>, Right: <code>GX_MIRROR<br></code>(t coordinate) Top: <code>GX_REPEAT</code>, Center: <code>GX_CLAMP</code>, Bottom:<CODE>GX_MIRROR</CODE></P>
102<P><IMG src="./images/tex-wrap-0.jpg" alt="tex-wrap-0.jpg (47056 bytes)" width="640" height="448"></P>
103<P>A test color pattern is displayed with linear filter. Only <CODE>GX_REPEAT</CODE> should make texture border gray.</P>
104<P><IMG src="./images/tex-wrap-1.jpg" alt="tex-wrap-1.jpg (34027 bytes)" width="640" height="448"></P>
105<H2>Data Files Required</H2>
106<P><CODE>$REVOLUTION_SDK_ROOT/dvddata/gxTests/tex-03.tpl</CODE></P>
107<H2>Revision History</H2>
108<P>2006/03/01 Initial version.</P>
109<hr>
110<P>CONFIDENTIAL</p>
111</BODY>
112</HTML>