<html> <head> <title> TemplateOgre::ControllerFunction class Reference - OGRE Documentation</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <link type="text/css" rel="stylesheet" href="style.css"> </head> <body> <!-- Generated by Doxygen 1.2.16 --> <center> <a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="namespaces.html">Namespace List</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="classes.html">Alphabetical List</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="namespacemembers.html">Namespace Members</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="globals.html">File Members</a> <a class="qindex" href="pages.html">Related Pages</a> </center> <hr><h1>Ogre::ControllerFunction< T > Class Template Reference</h1>Subclasses of this class are responsible for performing a function on an input value for a <a class="el" href="classOgre_1_1Controller.html">Controller</a>. <a href="#_details">More...</a> <p> <code>#include <<a class="el" href="OgreController_8h-source.html">OgreController.h</a>></code> <p> Collaboration diagram for Ogre::ControllerFunction< T >:<p><center><img src="classOgre_1_1ControllerFunction__coll__graph.png" border="0" usemap="#Ogre_1_1ControllerFunction_3_01T_01_4__coll__map" alt="Collaboration graph"></center> <map name="Ogre_1_1ControllerFunction_3_01T_01_4__coll__map"> </map> <center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center><a href="classOgre_1_1ControllerFunction-members.html">List of all members.</a><table border=0 cellpadding=0 cellspacing=0> <tr><td colspan=2><br><h2>Public Methods</h2></td></tr> <tr><td nowrap align=right valign=top> </td><td valign=bottom><a class="el" href="classOgre_1_1ControllerFunction.html#Ogre_1_1ControllerFunctiona0">ControllerFunction</a> (bool deltaInput)</td></tr> <tr><td> </td><td><font size=-1><em>Constructor.</em> <a href="#Ogre_1_1ControllerFunctiona0"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top>virtual T </td><td valign=bottom><a class="el" href="classOgre_1_1ControllerFunction.html#Ogre_1_1ControllerFunctiona1">calculate</a> (T sourceValue)=0</td></tr> <tr><td colspan=2><br><h2>Protected Methods</h2></td></tr> <tr><td nowrap align=right valign=top>T </td><td valign=bottom><a class="el" href="classOgre_1_1ControllerFunction.html#Ogre_1_1ControllerFunctionb0">getAdjustedInput</a> (T input)</td></tr> <tr><td> </td><td><font size=-1><em>Gets the input value as adjusted by any delta.</em> <a href="#Ogre_1_1ControllerFunctionb0"></a><em></em></font><br><br></td></tr> <tr><td colspan=2><br><h2>Protected Attributes</h2></td></tr> <tr><td nowrap align=right valign=top>bool </td><td valign=bottom><a class="el" href="classOgre_1_1ControllerFunction.html#Ogre_1_1ControllerFunctionn0">mDeltaInput</a></td></tr> <tr><td> </td><td><font size=-1><em>If true, function will add imput values together and wrap at 1.0 before evaluating.</em> <a href="#Ogre_1_1ControllerFunctionn0"></a><em></em></font><br><br></td></tr> <tr><td nowrap align=right valign=top>T </td><td valign=bottom><a class="el" href="classOgre_1_1ControllerFunction.html#Ogre_1_1ControllerFunctionn1">mDeltaCount</a></td></tr> </table> <hr><a name="_details"></a><h2>Detailed Description</h2> <h3>template<typename T><br> class Ogre::ControllerFunction< T ></h3> Subclasses of this class are responsible for performing a function on an input value for a <a class="el" href="classOgre_1_1Controller.html">Controller</a>. <p> <dl compact><dt><b> Remarks: </b><dd> This abstract class provides the interface that needs to be supported for a custom function which can be 'plugged in' to a <a class="el" href="classOgre_1_1Controller.html">Controller</a> instance, which controls some object value based on an input value. For example, the WaveControllerFunction class provided by <a class="el" href="namespaceOgre.html">Ogre</a> allows you to use various waveforms to translate an input value to an output value. <p> You are free to create your own subclasses in order to define any function you wish. </dl> <p> <p> Definition at line <a class="el" href="OgreController_8h-source.html#l00047">47</a> of file <a class="el" href="OgreController_8h-source.html">OgreController.h</a>.<hr><h2>Constructor & Destructor Documentation</h2> <a name="Ogre_1_1ControllerFunctiona0" doxytag="Ogre::ControllerFunction::ControllerFunction"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" colspan="4"> template<typename T> </td> </tr> <tr> <td class="md" nowrap valign="top"> Ogre::ControllerFunction< T >::ControllerFunction </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">bool </td> <td class="mdname1" valign="top" nowrap> <em>deltaInput</em> </td> <td class="md" valign="top">) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Constructor. <p> <dl compact><dt><b> Parameters: </b><dd> <table border=0 cellspacing=2 cellpadding=0> <tr><td valign=top><em>deltaInput</em> </td><td> If true, signifies that the input will be a delta value such that the function should add it to an internal counter before calculating the output. </td></tr> </table> </dl> <p> Definition at line <a class="el" href="OgreController_8h-source.html#l00079">79</a> of file <a class="el" href="OgreController_8h-source.html">OgreController.h</a>. </td> </tr> </table> <hr><h2>Member Function Documentation</h2> <a name="Ogre_1_1ControllerFunctiona1" doxytag="Ogre::ControllerFunction::calculate"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" colspan="4"> template<typename T> </td> </tr> <tr> <td class="md" nowrap valign="top"> virtual T Ogre::ControllerFunction< T >::calculate </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">T </td> <td class="mdname1" valign="top" nowrap> <em>sourceValue</em> </td> <td class="md" valign="top">) </td> <td class="md" nowrap><code> [pure virtual]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> <p> Implemented in <a class="el" href="classOgre_1_1AnimationControllerFunction.html#Ogre_1_1AnimationControllerFunctiona1">Ogre::AnimationControllerFunction</a>, <a class="el" href="classOgre_1_1ScaleControllerFunction.html#Ogre_1_1ScaleControllerFunctiona1">Ogre::ScaleControllerFunction</a>, and <a class="el" href="classOgre_1_1WaveformControllerFunction.html#Ogre_1_1WaveformControllerFunctiona1">Ogre::WaveformControllerFunction</a>. </td> </tr> </table> <a name="Ogre_1_1ControllerFunctionb0" doxytag="Ogre::ControllerFunction::getAdjustedInput"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" colspan="4"> template<typename T> </td> </tr> <tr> <td class="md" nowrap valign="top"> T Ogre::ControllerFunction< T >::getAdjustedInput </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">T </td> <td class="mdname1" valign="top" nowrap> <em>input</em> </td> <td class="md" valign="top">) </td> <td class="md" nowrap><code> [protected]</code></td> </tr> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> Gets the input value as adjusted by any delta. <p> <p> Reimplemented in <a class="el" href="classOgre_1_1WaveformControllerFunction.html#Ogre_1_1WaveformControllerFunctionb0">Ogre::WaveformControllerFunction</a>. <p> Definition at line <a class="el" href="OgreController_8h-source.html#l00056">56</a> of file <a class="el" href="OgreController_8h-source.html">OgreController.h</a>. </td> </tr> </table> <hr><h2>Member Data Documentation</h2> <a name="Ogre_1_1ControllerFunctionn1" doxytag="Ogre::ControllerFunction::mDeltaCount"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" colspan="4"> template<typename T> </td> </tr> <tr> <td class="md" nowrap valign="top"> T Ogre::ControllerFunction< T >::mDeltaCount<code> [protected]</code> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> <p> Definition at line <a class="el" href="OgreController_8h-source.html#l00052">52</a> of file <a class="el" href="OgreController_8h-source.html">OgreController.h</a>. </td> </tr> </table> <a name="Ogre_1_1ControllerFunctionn0" doxytag="Ogre::ControllerFunction::mDeltaInput"></a><p> <table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" colspan="4"> template<typename T> </td> </tr> <tr> <td class="md" nowrap valign="top"> bool Ogre::ControllerFunction< T >::mDeltaInput<code> [protected]</code> </table> </td> </tr> </table> <table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td> <p> If true, function will add imput values together and wrap at 1.0 before evaluating. <p> <p> Definition at line <a class="el" href="OgreController_8h-source.html#l00051">51</a> of file <a class="el" href="OgreController_8h-source.html">OgreController.h</a>. </td> </tr> </table> <hr>The documentation for this class was generated from the following file:<ul> <li><a class="el" href="OgreController_8h-source.html">OgreController.h</a></ul> <p> Copyright © 2002-2003 by The OGRE Team<br /> Last modified Wed Jan 21 00:17:07 2004 </p> </body> </html>