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>VECReflect</TITLE>
9</HEAD>
10<BODY>
11<H1 align="left">VECReflect</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 VECReflect ( const Vec* <EM>src</EM>, const Vec* <EM>normal</EM>, Vec* <EM>dst</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" bgcolor="#ffffe8"><CODE><STRONG><EM>src</EM></STRONG></CODE></TD>
21<TD width="520">Pointer to incident <A href="../structures/Vec_VecPtr.html"><CODE>Vec</CODE></A>.&nbsp;<code><em><strong>src</strong></em></code> must point toward the surface.</TD>
22    </TR>
23    <TR>
24<TD width="120" bgcolor="#ffffe8"><CODE><STRONG><EM>normal</EM></STRONG></CODE></TD>
25<TD width="520">Pointer to <A href="../structures/Vec_VecPtr.html"><CODE>Vec</CODE></A> that is normal to the surface. <code><em><strong>normal</strong></em></code> must point away from the surface.</TD>
26    </TR>
27    <TR>
28<TD width="120" bgcolor="#ffffe8"><CODE><STRONG><EM>dst</EM></STRONG></CODE></TD>
29<TD width="520">Pointer to the unit vector <A href="../structures/Vec_VecPtr.html"><CODE>Vec</CODE></A> that is reflected. Acceptable if <code><em><strong>dst</strong></em> = <em><strong>src</strong></em></code> or <code><em><strong>dst</strong></em> = <em><strong>normal</strong></em></code>.</TD>
30    </TR>
31  </TBODY>
32</TABLE>
33</DIV>
34<H2 align="left">Return Values</H2>
35<P align="left">None.</P>
36<H2 align="left">Description</H2>
37<P>Reflects an incident vector across the normal vector such that the angle of incidence equals the angle of reflection. This function is intended for use in calculating surface reflections. </P>
38<P><STRONG>Note:</STRONG>  Although the incident vector does not need to be a unit matrix, the resultant vector is normalized. </P>
39
40
41<H2 align="left">See Also</H2>
42<P align="left"><A href="../structures/Vec_VecPtr.html"><CODE>Vec, VecPtr, </CODE></A><A href="VECHalfAngle.html"><CODE>VECHalfAngle</CODE></A></P>
43<H2>Revision History</H2>
44<P>2006/03/01 Initial version.</P>
45<hr>
46<P>CONFIDENTIAL</p>
47</BODY>
48</HTML>