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 http-equiv="Content-Style-Type" content="text/css">
6<META name="GENERATOR" content="Microsoft FrontPage 5.0">
7<LINK rel="stylesheet" type="text/css" href="../CSS/revolution.css">
8<TITLE>GDSetTexCoordScale</TITLE>
9</HEAD>
10<BODY>
11<H1 align="left">GDSetTexCoordScale / GDSetTexCoordScale2 / GDSetTexCoordScaleAndTOEs</H1>
12
13<H2>Syntax</H2>
14<dl><dd><pre class="construction">
15#include &lt;revolution/gd.h&gt;
16
17void GDSetTexCoordScale (
18    <A href="../gx/Enumerated_Types/GXTexCoordID.html">GXTexCoordID</A> coord,
19    u16 s_scale, u16 t_scale );
20
21void GDSetTexCoordScale2 (
22    <A href="../gx/Enumerated_Types/GXTexCoordID.html">GXTexCoordID</A> coord,
23    u16 s_scale, GXBool s_bias, GXBool s_wrap,
24    u16 t_scale, GXBool t_bias, GXBool t_wrap );
25
26void GDSetTexCoordScaleAndTOEs (
27    <A href="../gx/Enumerated_Types/GXTexCoordID.html">GXTexCoordID</A> coord,
28    u16 s_scale, GXBool s_bias, GXBool s_wrap,
29    u16 t_scale, GXBool t_bias, GXBool t_wrap,
30    <A href="../gx/Enumerated_Types/GXBool.html">GXBool</A> line_offset, <A href="../gx/Enumerated_Types/GXBool.html">GXBool</A> point_offset );
31</pre></dd></dl>
32
33<H2>Arguments</H2>
34<TABLE class="arguments" border="1" >
35  <TBODY>
36    <TR>
37<TH><STRONG><EM><CODE>coord</CODE></EM></STRONG></TH>
38<TD>Which texture coordinate <a     href="../gx/Enumerated_Types/GXTexCoordID.html">ID</a> is being changed.</TD>
39    </TR>
40    <TR>
41<TH><STRONG><EM><CODE>s_scale</CODE></EM></STRONG></TH>
42<TD>Manual scale value for the computed S component (width) of the coordinate.</TD>
43    </TR>
44    <TR>
45<TH><STRONG><EM><CODE>s_bias</CODE></EM></STRONG></TH>
46<TD>Whether to apply biasing to the S component (only use with <CODE>GX_REPERT</CODE>).</TD>
47    </TR>
48    <TR>
49<TH><STRONG><EM><CODE>s_wrap</CODE></EM></STRONG></TH>
50<TD>Whether to apply cylindrical wrapping to the S component.</TD>
51    </TR>
52    <TR>
53<TH><STRONG><EM><CODE>t_scale</CODE></EM></STRONG></TH>
54<TD>Manual scale value for the computed T (height) component of the coordinate.</TD>
55    </TR>
56    <TR>
57<TH><STRONG><EM><CODE>t_bias</CODE></EM></STRONG></TH>
58<TD>Whether to apply biasing to the T component (only use with <CODE>GX_REPERT</CODE>).</TD>
59    </TR>
60    <TR>
61<TH><STRONG><EM><CODE>t_wrap</CODE></EM></STRONG></TH>
62<TD>Whether to apply cylindrical wrapping to the T component.</TD>
63    </TR>
64  </TBODY>
65</TABLE>
66
67<H2>Return Values</H2>
68<P>None.</P>
69
70<H2>Description</H2>
71<P>Unlike the GX library, the GD library does not automatically scale texture coordinates. Therefore, you must manually set the texture coordinate scale according to the size of the texture that each coordinate is used with. In addition to the scale values, you must also set the bias and cylindrical wrap bits. The bias setting is described in <a href="../gx/TexCoordGen/GXSetTexCoordBias.html"><code>GXSetTexCoordBias</code></a> function. The cylindrical mapping setting is described in <A href="../gx/TexCoordGen/GXSetTexCoordCylWrap.html"><CODE>GXSetTexCoordCylWrap</CODE></A> function. If you want to update only texture coordinate scale, you can use <code>GDSetTexCoordScale</code> function, otherwise <code>GDSetTexCoordScale2</code> function is more suitable.</P>
72<P>The function <code>GDSetTexCoordScaleAndTOEs</code> also lets you set the texture offset enable bits for the specified texture coordinate. The enable bit of the texture offset determines whether the texture offset is added to the texture coordinates at the opposite angle of lines and points. For details, see <a href="../gx/Geometry/GXEnableTexOffsets.html"><code>GXEnableTexOffsets</code></a>.</P>
73<P><code>GDSetTexCoordScale</code> function and <code>GDSetTexCoordScale2</code> function use the hardware mask register to avoid changing the texture-offset enable bits.</P>
74
75<H2>See Also</H2>
76<P class="reference">
77<A href="../gx/TexCoordGen/GXSetTexCoordScaleManually.html">GXSetTexCoordScaleManually</A>,
78<A href="../gx/TexCoordGen/GXSetTexCoordBias.html">GXSetTexCoordBias</A>,
79<A href="../gx/TexCoordGen/GXSetTexCoordCylWrap.html">GXSetTexCoordCylWrap</A>,
80<A href="../gx/Geometry/GXEnableTexOffsets.html">GXEnableTexOffsets</A>
81</P>
82
83<H2>Revision History</H2>
84<P>
852006/03/01 Initial version.<BR>
86</P>
87
88<hr><p>CONFIDENTIAL</p></body>
89</HTML>