aboutsummaryrefslogtreecommitdiff
path: root/docs/doxygen/nel/animation_8cpp-source.html
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--docs/doxygen/nel/animation_8cpp-source.html369
1 files changed, 369 insertions, 0 deletions
diff --git a/docs/doxygen/nel/animation_8cpp-source.html b/docs/doxygen/nel/animation_8cpp-source.html
new file mode 100644
index 00000000..193206f2
--- /dev/null
+++ b/docs/doxygen/nel/animation_8cpp-source.html
@@ -0,0 +1,369 @@
+<!doctype html public "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
+<HTML>
+<HEAD>
+ <TITLE>nevrax.org : docs</TITLE>
+ <LINK REL=stylesheet TYPE="text/css" HREF="http://www.nevrax.org/inc/css/nevrax.css">
+ <link href="doxygen.css" rel="stylesheet" type="text/css">
+</HEAD>
+<BODY MARGINHEIGHT="0" MARGINWIDTH="0">
+
+<!-- uplinks -->
+<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0>
+ <TR>
+ <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD>
+ <TD WIDTH=140 BGCOLOR=#dddddd><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="16" BORDER=0 ALT=""></TD>
+ <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD>
+ <TD><IMG width=6 height=14 SRC="http://www.nevrax.org/inc/img/reddots.gif" ALT="#" VSPACE=2 HSPACE=2 BORDER=0 ></TD><TD VALIGN=middle>&nbsp;<A CLASS=uplinks HREF=http://www.nevrax.org><b>Home</B></FONT></A>&nbsp;&nbsp;&nbsp;</TD>
+ <TD><IMG width=6 height=14 SRC="http://www.nevrax.org/inc/img/reddots.gif" ALT="#" VSPACE=2 HSPACE=2 BORDER=0 ></TD><TD VALIGN=middle>&nbsp;<A CLASS=uplinks HREF=http://www.nevrax.com><b>nevrax.com</B></FONT></A>&nbsp;&nbsp;&nbsp;</TD>
+ </TR>
+</TABLE>
+
+<!-- banner Nevrax -->
+<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%>
+ <TR><TD BGCOLOR="#000000" BACKGROUND="http://www.nevrax.org/inc/img/black_banner.jpg"><A HREF="http://www.nevrax.org"><IMG SRC="http://www.nevrax.org/inc/img/nevrax.gif" WIDTH="170" HEIGHT="45" BORDER=0 ALT="Nevrax" ></A></TD></TR>
+</TABLE>
+
+<!-- main table -->
+<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 height=100%>
+ <TR>
+ <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="10" BORDER=0 ALT=""></TD>
+ <TD WIDTH=140 BGCOLOR=#dddddd VALIGN=TOP ALIGN=middle><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="10" BORDER=0 ALT="">
+
+ <!------ Begin Box ------>
+ <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=black><TR><TD><TABLE border=0 cellspacing=2 cellpadding=0 width=120><tr><TD ALIGN=middle bgcolor=black>
+ <FONT COLOR=white FACE="sans-serif"><B>Nevrax.org</B></FONT></TD></TR><tr><td colspan=2 bgcolor=#FFFFFF>
+ <TABLE cellspacing=0 cellpadding=1 border=0>
+ <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/news/" TITLE="Rubrique news"><img width=13 height=15 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-news.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/news/" TITLE="News">News</a></td></tr>
+ <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/mail/" TITLE="Rubrique mail"><img width=15 height=11 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-mail.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/mail/" TITLE="Mailing list archive">Mailing-list</a></td></tr>
+ <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/docs/" TITLE="Rubrique docs"><img width=14 height=16 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-docs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/docs/" TITLE="Documentation">Documentation</a></td></tr>
+ <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/cvs/" TITLE="Rubrique cvs"><img width=13 height=17 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-cvs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/cvs/" TITLE="CVS Web">CVS</a></td></tr>
+ <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/bugs/" TITLE="Rubrique bugs"><img width=20 height=16 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-bugs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/bugs/" TITLE="Bugtracking">Bugs</a></td></tr>
+ <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/GPL.php3" TITLE="Rubrique license"><img width=18 height=12 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-gpl.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/GPL.php3" TITLE="License">License</a></td></tr>
+ </TABLE>
+ </TD></TR></TABLE></TD></TR></TABLE>
+ <!------ End Box ------>
+
+ </TD>
+ <TD WIDTH=15><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD>
+ <TD ALIGN=left valign=top><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="10" BORDER=0 ALT="">
+
+<!-- title -->
+<TABLE background="http://www.nevrax.org/inc/img/redline.gif" CELLSPACING=0 CELLPADDING=0 BORDER=0 width=100%><tr><td>
+<A HREF="http://www.nevrax.org/docs/"><img src="http://www.nevrax.org/inc/img/t_docs.gif" ALT="Docs" HEIGHT=20 BORDER=0></A>
+</td><td><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="1" HEIGHT="1" BORDER=0 ALT="">
+</td></tr></table>
+&nbsp;
+
+<!-- block -->
+<TABLE bgcolor="#dddddd" CELLSPACING=0 CELLPADDING=0 BORDER=0 width=100%><tr><td width=1% valign=middle><img width=6 height=14 hspace=2 vspace=2 src="http://www.nevrax.org/inc/img/reddots.gif"></TD>
+ <TD><B>Documentation</B></TD>
+ <TD ALIGN=RIGHT>&nbsp;</td>
+</tr></table>
+<!-- Generated by Doxygen 1.2.14 -->
+<center>
+<a class="qindex" href="index.html">Main Page</a> &nbsp; <a class="qindex" href="namespaces.html">Namespace List</a> &nbsp; <a class="qindex" href="hierarchy.html">Class Hierarchy</a> &nbsp; <a class="qindex" href="classes.html">Alphabetical List</a> &nbsp; <a class="qindex" href="annotated.html">Compound List</a> &nbsp; <a class="qindex" href="files.html">File List</a> &nbsp; <a class="qindex" href="namespacemembers.html">Namespace Members</a> &nbsp; <a class="qindex" href="functions.html">Compound Members</a> &nbsp; <a class="qindex" href="globals.html">File Members</a> &nbsp; <a class="qindex" href="pages.html">Related Pages</a> &nbsp; <a class="qindexRef" doxygen="_cgi:http://www.nevrax.org/cgi-bin/nel-search.cgi" href="http://www.nevrax.org/cgi-bin/nel-search.cgi">Search</a> &nbsp; </center>
+<hr><h1>animation.cpp</h1><a href="animation_8cpp.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001
+00007 <font class="comment">/* Copyright, 2001 Nevrax Ltd.</font>
+00008 <font class="comment"> *</font>
+00009 <font class="comment"> * This file is part of NEVRAX NEL.</font>
+00010 <font class="comment"> * NEVRAX NEL is free software; you can redistribute it and/or modify</font>
+00011 <font class="comment"> * it under the terms of the GNU General Public License as published by</font>
+00012 <font class="comment"> * the Free Software Foundation; either version 2, or (at your option)</font>
+00013 <font class="comment"> * any later version.</font>
+00014 <font class="comment"></font>
+00015 <font class="comment"> * NEVRAX NEL is distributed in the hope that it will be useful, but</font>
+00016 <font class="comment"> * WITHOUT ANY WARRANTY; without even the implied warranty of</font>
+00017 <font class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU</font>
+00018 <font class="comment"> * General Public License for more details.</font>
+00019 <font class="comment"></font>
+00020 <font class="comment"> * You should have received a copy of the GNU General Public License</font>
+00021 <font class="comment"> * along with NEVRAX NEL; see the file COPYING. If not, write to the</font>
+00022 <font class="comment"> * Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,</font>
+00023 <font class="comment"> * MA 02111-1307, USA.</font>
+00024 <font class="comment"> */</font>
+00025
+00026 <font class="preprocessor">#include "<a class="code" href="std3d_8h.html">std3d.h</a>"</font>
+00027
+00028 <font class="preprocessor">#include "<a class="code" href="animation_8h.html">3d/animation.h</a>"</font>
+00029 <font class="preprocessor">#include "<a class="code" href="track_8h.html">3d/track.h</a>"</font>
+00030
+00031 <font class="preprocessor">#include "<a class="code" href="file_8h.html">nel/misc/file.h</a>"</font>
+00032 <font class="preprocessor">#include "<a class="code" href="path_8h.html">nel/misc/path.h</a>"</font>
+00033 <font class="preprocessor">#include "<a class="code" href="hierarchical__timer_8h.html">nel/misc/hierarchical_timer.h</a>"</font>
+00034
+00035 <font class="keyword">namespace </font>NL3D
+00036 {
+00037
+00038 <a class="code" href="hierarchical__timer_8h.html#a6">H_AUTO_DECL</a>( NL3D_UI_Animation )
+00039
+<a name="l00040"></a><a class="code" href="animation_8cpp.html#a0">00040</a> <font class="preprocessor">#define NL3D_HAUTO_UI_ANIMATION H_AUTO_USE( NL3D_UI_Animation )</font>
+00041 <font class="preprocessor"></font>
+00042
+00043 <font class="comment">// ***************************************************************************</font>
+00044
+<a name="l00045"></a><a class="code" href="classNL3D_1_1CAnimation.html#a0">00045</a> CAnimation::CAnimation() : _BeginTimeTouched(true), _EndTimeTouched(true), _AnimLoopTouched(true)
+00046 {
+00047 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00048 <a class="code" href="classNL3D_1_1CAnimation.html#o3">_MinEndTime</a> = -FLT_MAX;
+00049 }
+00050
+00051 <font class="comment">// ***************************************************************************</font>
+00052
+<a name="l00053"></a><a class="code" href="classNL3D_1_1CAnimation.html#a1">00053</a> CAnimation::~CAnimation ()
+00054 {
+00055 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00056 <font class="comment">// Delete all the pointers in the array</font>
+00057 <font class="keywordflow">for</font> (uint i=0; i&lt;<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>.size(); i++)
+00058 <font class="comment">// Delete</font>
+00059 <font class="keyword">delete</font> <a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>[i];
+00060 }
+00061
+00062 <font class="comment">// ***************************************************************************</font>
+00063
+<a name="l00064"></a><a class="code" href="classNL3D_1_1CAnimation.html#a6">00064</a> <font class="keywordtype">void</font> CAnimation::addTrack (<font class="keyword">const</font> std::string&amp; name, ITrack* pChannel)
+00065 {
+00066 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00067 <font class="comment">// Add an entry in the map</font>
+00068 <a class="code" href="classNL3D_1_1CAnimation.html#o1">_IdByName</a>.insert (TMapStringUInt::value_type (name, (uint32)<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>.size()));
+00069
+00070 <font class="comment">// Add an entry in the array</font>
+00071 <a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>.push_back (pChannel);
+00072
+00073 <font class="comment">// </font>
+00074 <a class="code" href="classNL3D_1_1CAnimation.html#z378_3">_BeginTimeTouched</a> = <a class="code" href="classNL3D_1_1CAnimation.html#z378_4">_EndTimeTouched</a> = <a class="code" href="classNL3D_1_1CAnimation.html#z378_5">_AnimLoopTouched</a>= <font class="keyword">true</font>;
+00075
+00076 }
+00077
+00078 <font class="comment">// ***************************************************************************</font>
+00079
+<a name="l00080"></a><a class="code" href="classNL3D_1_1CAnimation.html#a7">00080</a> <font class="keywordtype">void</font> CAnimation::serial (<a class="code" href="classNLMISC_1_1IStream.html">NLMISC::IStream</a>&amp; f)
+00081 {
+00082 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00083 <font class="comment">// Serial a header</font>
+00084 f.<a class="code" href="classNLMISC_1_1IStream.html#a30">serialCheck</a> ((uint32)'_LEN');
+00085 f.<a class="code" href="classNLMISC_1_1IStream.html#a30">serialCheck</a> ((uint32)'MINA');
+00086
+00087 <font class="comment">// Serial a version</font>
+00088 sint version=f.<a class="code" href="classNLMISC_1_1IStream.html#a29">serialVersion</a> (1);
+00089
+00090 <font class="comment">// Serial the name</font>
+00091 f.<a class="code" href="classNLMISC_1_1IStream.html#a5">serial</a> (<a class="code" href="classNL3D_1_1CAnimation.html#o0">_Name</a>);
+00092
+00093 <font class="comment">// Serial the name/id map</font>
+00094 f.<a class="code" href="classNLMISC_1_1IStream.html#a7">serialCont</a>(<a class="code" href="classNL3D_1_1CAnimation.html#o1">_IdByName</a>);
+00095
+00096 <font class="comment">// Serial the vector</font>
+00097 f.<a class="code" href="classNLMISC_1_1IStream.html#a22">serialContPolyPtr</a> (<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>);
+00098
+00099 <font class="comment">// Serial the min end time</font>
+00100 <font class="keywordflow">if</font> (version&gt;=1)
+00101 {
+00102 f.<a class="code" href="classNLMISC_1_1IStream.html#a5">serial</a> (<a class="code" href="classNL3D_1_1CAnimation.html#o3">_MinEndTime</a>);
+00103 }
+00104 }
+00105
+00106 <font class="comment">// ***************************************************************************</font>
+00107
+<a name="l00108"></a><a class="code" href="classNL3D_1_1CAnimation.html#a3">00108</a> <font class="keywordtype">void</font> CAnimation::getTrackNames (std::set&lt;std::string&gt;&amp; setString)<font class="keyword"> const</font>
+00109 <font class="keyword"></font>{
+00110 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00111 <font class="comment">// For each track name</font>
+00112 TMapStringUInt::const_iterator ite=<a class="code" href="classNL3D_1_1CAnimation.html#o1">_IdByName</a>.begin();
+00113 <font class="keywordflow">while</font> (ite!=<a class="code" href="classNL3D_1_1CAnimation.html#o1">_IdByName</a>.end())
+00114 {
+00115 <font class="comment">// Add the name in the map</font>
+00116 setString.insert (ite-&gt;first);
+00117
+00118 <font class="comment">// Next track</font>
+00119 ite++;
+00120 }
+00121 }
+00122
+00123 <font class="comment">// ***************************************************************************</font>
+00124
+<a name="l00125"></a><a class="code" href="classNL3D_1_1CAnimation.html#z377_2">00125</a> <a class="code" href="namespaceNL3D.html#a1">TAnimationTime</a> CAnimation::getBeginTime ()<font class="keyword"> const</font>
+00126 <font class="keyword"></font>{
+00127 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00128 <a class="code" href="animation_8cpp.html#a0">NL3D_HAUTO_UI_ANIMATION</a>;
+00129
+00130 <font class="keywordflow">if</font> (_BeginTimeTouched)
+00131 {
+00132 <font class="comment">// Track count</font>
+00133 uint trackCount=<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>.size();
+00134
+00135 <font class="comment">// Track count empty ?</font>
+00136 <font class="keywordflow">if</font> (trackCount==0)
+00137 <font class="keywordflow">return</font> 0.f;
+00138
+00139 <font class="comment">// Look for the lowest</font>
+00140 <a class="code" href="classNL3D_1_1CAnimation.html#z378_0">_BeginTime</a>=<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>[0]-&gt;getBeginTime ();
+00141
+00142 <font class="comment">// Scan all keys</font>
+00143 <font class="keywordflow">for</font> (uint <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>=1; <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>&lt;trackCount; <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>++)
+00144 {
+00145 <font class="keywordflow">if</font> (<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>[<a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>]-&gt;getBeginTime ()&lt;<a class="code" href="classNL3D_1_1CAnimation.html#z378_0">_BeginTime</a>)
+00146 <a class="code" href="classNL3D_1_1CAnimation.html#z378_0">_BeginTime</a>=<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>[<a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>]-&gt;getBeginTime ();
+00147 }
+00148
+00149 <a class="code" href="classNL3D_1_1CAnimation.html#z378_3">_BeginTimeTouched</a> = <font class="keyword">false</font>;
+00150 }
+00151
+00152 <font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1CAnimation.html#z378_0">_BeginTime</a>;
+00153 }
+00154
+00155 <font class="comment">// ***************************************************************************</font>
+00156
+<a name="l00157"></a><a class="code" href="classNL3D_1_1CAnimation.html#z377_3">00157</a> <a class="code" href="namespaceNL3D.html#a1">TAnimationTime</a> CAnimation::getEndTime ()<font class="keyword"> const</font>
+00158 <font class="keyword"></font>{
+00159 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00160 <a class="code" href="animation_8cpp.html#a0">NL3D_HAUTO_UI_ANIMATION</a>;
+00161
+00162 <font class="keywordflow">if</font> (_EndTimeTouched)
+00163 {
+00164 <font class="comment">// Track count</font>
+00165 uint trackCount=<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>.size();
+00166
+00167 <font class="comment">// Track count empty ?</font>
+00168 <font class="keywordflow">if</font> (trackCount==0)
+00169 <font class="keywordflow">return</font> 0.f;
+00170
+00171 <font class="comment">// Look for the highest</font>
+00172 <a class="code" href="classNL3D_1_1CAnimation.html#z378_1">_EndTime</a>=<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>[0]-&gt;getEndTime ();
+00173
+00174 <font class="comment">// Scan tracks keys</font>
+00175 <font class="keywordflow">for</font> (uint <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>=1; <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>&lt;trackCount; <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>++)
+00176 {
+00177 <font class="keywordflow">if</font> (<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>[<a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>]-&gt;getEndTime ()&gt;<a class="code" href="classNL3D_1_1CAnimation.html#z378_1">_EndTime</a>)
+00178 <a class="code" href="classNL3D_1_1CAnimation.html#z378_1">_EndTime</a>=<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>[<a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>]-&gt;getEndTime ();
+00179 }
+00180
+00181 <font class="comment">// Check min end time</font>
+00182 <font class="keywordflow">if</font> (<a class="code" href="classNL3D_1_1CAnimation.html#z378_1">_EndTime</a> &lt; <a class="code" href="classNL3D_1_1CAnimation.html#o3">_MinEndTime</a>)
+00183 <a class="code" href="classNL3D_1_1CAnimation.html#z378_1">_EndTime</a> = <a class="code" href="classNL3D_1_1CAnimation.html#o3">_MinEndTime</a>;
+00184
+00185 <a class="code" href="classNL3D_1_1CAnimation.html#z378_4">_EndTimeTouched</a> = <font class="keyword">false</font>;
+00186 }
+00187
+00188 <font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1CAnimation.html#z378_1">_EndTime</a>;
+00189 }
+00190
+00191 <font class="comment">// ***************************************************************************</font>
+<a name="l00192"></a><a class="code" href="classNL3D_1_1CAnimation.html#z377_4">00192</a> <font class="keywordtype">bool</font> CAnimation::allTrackLoop()<font class="keyword"> const</font>
+00193 <font class="keyword"></font>{
+00194 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00195 <a class="code" href="animation_8cpp.html#a0">NL3D_HAUTO_UI_ANIMATION</a>;
+00196
+00197 <font class="keywordflow">if</font>(_AnimLoopTouched)
+00198 {
+00199 <font class="comment">// Track count</font>
+00200 uint trackCount=<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>.size();
+00201
+00202 <font class="comment">// Default is true</font>
+00203 <a class="code" href="classNL3D_1_1CAnimation.html#z378_2">_AnimLoop</a>= <font class="keyword">true</font>;
+00204
+00205 <font class="comment">// Scan tracks keys</font>
+00206 <font class="keywordflow">for</font> (uint <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>=0; <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>&lt;trackCount; <a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>++)
+00207 {
+00208 <font class="keywordflow">if</font> (!<a class="code" href="classNL3D_1_1CAnimation.html#o2">_TrackVector</a>[<a class="code" href="driver__opengl__extension__def_8h.html#a384">t</a>]-&gt;getLoopMode())
+00209 {
+00210 <a class="code" href="classNL3D_1_1CAnimation.html#z378_2">_AnimLoop</a>= <font class="keyword">false</font>;
+00211 <font class="keywordflow">break</font>;
+00212 }
+00213 }
+00214 <a class="code" href="classNL3D_1_1CAnimation.html#z378_5">_AnimLoopTouched</a> = <font class="keyword">false</font>;
+00215 }
+00216
+00217 <font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1CAnimation.html#z378_2">_AnimLoop</a>;
+00218 }
+00219
+00220 <font class="comment">// ***************************************************************************</font>
+00221
+<a name="l00222"></a><a class="code" href="classNL3D_1_1CAnimation.html#z377_0">00222</a> UTrack* CAnimation::getTrackByName (<font class="keyword">const</font> <font class="keywordtype">char</font>* name)
+00223 {
+00224 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00225 <a class="code" href="animation_8cpp.html#a0">NL3D_HAUTO_UI_ANIMATION</a>;
+00226
+00227 <font class="comment">// Get track id</font>
+00228 uint <a class="code" href="driver__opengl__extension__def_8h.html#a356">id</a>=<a class="code" href="classNL3D_1_1CAnimation.html#a2">getIdTrackByName</a> (name);
+00229
+00230 <font class="comment">// Not found ?</font>
+00231 <font class="keywordflow">if</font> (<a class="code" href="driver__opengl__extension__def_8h.html#a356">id</a>==CAnimation::NotFound)
+00232 <font class="comment">// Error, return NULL</font>
+00233 <font class="keywordflow">return</font> NULL;
+00234 <font class="keywordflow">else</font>
+00235 <font class="comment">// No error, return the track</font>
+00236 <font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1CAnimation.html#a4">getTrack</a> (<a class="code" href="driver__opengl__extension__def_8h.html#a356">id</a>);
+00237 }
+00238
+00239 <font class="comment">// ***************************************************************************</font>
+00240
+<a name="l00241"></a><a class="code" href="classNL3D_1_1CAnimation.html#z377_1">00241</a> <font class="keywordtype">void</font> CAnimation::releaseTrack (UTrack* track)
+00242 {
+00243 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00244 <a class="code" href="animation_8cpp.html#a0">NL3D_HAUTO_UI_ANIMATION</a>;
+00245
+00246 <font class="comment">// Nothing to do</font>
+00247 }
+00248
+00249 <font class="comment">// ***************************************************************************</font>
+00250
+<a name="l00251"></a><a class="code" href="classNL3D_1_1CAnimation.html#a8">00251</a> <font class="keywordtype">void</font> CAnimation::setMinEndTime (<a class="code" href="namespaceNL3D.html#a1">TAnimationTime</a> minEndTime)
+00252 {
+00253 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00254 <a class="code" href="classNL3D_1_1CAnimation.html#o3">_MinEndTime</a> = minEndTime;
+00255 }
+00256
+00257 <font class="comment">// ***************************************************************************</font>
+00258
+<a name="l00259"></a><a class="code" href="classNL3D_1_1UAnimation.html#z3_0">00259</a> UAnimation* UAnimation::createAnimation (<font class="keyword">const</font> <font class="keywordtype">char</font>* sPath)
+00260 {
+00261 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00262 <a class="code" href="animation_8cpp.html#a0">NL3D_HAUTO_UI_ANIMATION</a>;
+00263
+00264 <font class="comment">// Allocate an animation</font>
+00265 std::auto_ptr&lt;CAnimation&gt; anim (<font class="keyword">new</font> CAnimation);
+00266
+00267 <font class="comment">// Read it</font>
+00268 <a class="code" href="classNLMISC_1_1CIFile.html">NLMISC::CIFile</a> <a class="code" href="cf__lexical_8cpp.html#a95">file</a>;
+00269 <font class="keywordflow">if</font> (file.<a class="code" href="classNLMISC_1_1CIFile.html#a3">open</a> ( <a class="code" href="classNLMISC_1_1CPath.html#d6">NLMISC::CPath::lookup</a>( sPath ) ) )
+00270 {
+00271 <font class="comment">// Serial the animation</font>
+00272 file.<a class="code" href="classNLMISC_1_1IStream.html#a5">serial</a> (*anim);
+00273
+00274 <font class="comment">// Return pointer</font>
+00275 CAnimation *ret=anim.release ();
+00276
+00277 <font class="comment">// Return the animation interface</font>
+00278 <font class="keywordflow">return</font> ret;
+00279 }
+00280 <font class="keywordflow">else</font>
+00281 <font class="keywordflow">return</font> NULL;
+00282 }
+00283
+00284 <font class="comment">// ***************************************************************************</font>
+00285
+<a name="l00286"></a><a class="code" href="classNL3D_1_1UAnimation.html#z3_1">00286</a> <font class="keywordtype">void</font> UAnimation::releaseAnimation (UAnimation* animation)
+00287 {
+00288 <a class="code" href="animation_8h.html#a0">NL3D_MEM_ANIMATION</a>
+00289 <a class="code" href="animation_8cpp.html#a0">NL3D_HAUTO_UI_ANIMATION</a>;
+00290
+00291 <font class="comment">// Cast the pointer</font>
+00292 CAnimation* release=(CAnimation*)animation;
+00293
+00294 <font class="comment">// Delete it</font>
+00295 <font class="keyword">delete</font> release;
+00296 }
+00297
+00298 <font class="comment">// ***************************************************************************</font>
+00299
+00300 } <font class="comment">// NL3D</font>
+</pre></div>
+
+<!-- footer -->
+<BR><FONT Size=+5>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </FONT>
+</TD>
+<TD WIDTH=15><IMG SRC=http://www.nevrax.org/inc/img/pixel.gif WIDTH=15 HEIGHT=15 BORDER=0 ALT=""></TD>
+</TR>
+</TABLE>
+</BODY>
+</HTML>