Torque3D Documentation / _generateds / tResponseCurve.cpp

tResponseCurve.cpp

Engine/source/math/util/tResponseCurve.cpp

More...

Public Functions

ConsoleDocClass(SimResponseCurve , "@brief A <a href="/coding/class/classresponsecurve/">ResponseCurve</a><<a href="/coding/file/types_8h/#types_8h_1a841d3674577a1e86afdc2f4845f46c4b">F32</a>> wrapped as <a href="/coding/file/pointer_8h/#pointer_8h_1aeeddce917cf130d62c370b8f216026dd">a</a> <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1aeab71244afb687f16d8c4f5ee9d6ef0e">SimObject.\n\n</a>" "Currently no applied use, not network ready, not intended " "<a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1a2732ab74fa0237854c2ba0f75f88a624">for</a> game development, <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1a2732ab74fa0237854c2ba0f75f88a624">for</a> editors or internal use <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1aeab71244afb687f16d8c4f5ee9d6ef0e">only.\n\n</a> " " @internal" )
DefineEngineMethod(SimResponseCurve , addPoint , void , (F32 value, F32 time) , "addPoint( <a href="/coding/file/types_8h/#types_8h_1a841d3674577a1e86afdc2f4845f46c4b">F32</a> <a href="/coding/file/pointer_8h/#pointer_8h_1a32aff7c6c4cd253fdf6563677afab5ce">value</a>, <a href="/coding/file/types_8h/#types_8h_1a841d3674577a1e86afdc2f4845f46c4b">F32</a> time )" )
DefineEngineMethod(SimResponseCurve , clear , void , () , "clear()" )
DefineEngineMethod(SimResponseCurve , getValue , F32 , (F32 time) , "getValue( <a href="/coding/file/types_8h/#types_8h_1a841d3674577a1e86afdc2f4845f46c4b">F32</a> time )" )

Detailed Description

Public Functions

ConsoleDocClass(SimResponseCurve , "@brief A <a href="/coding/class/classresponsecurve/">ResponseCurve</a><<a href="/coding/file/types_8h/#types_8h_1a841d3674577a1e86afdc2f4845f46c4b">F32</a>> wrapped as <a href="/coding/file/pointer_8h/#pointer_8h_1aeeddce917cf130d62c370b8f216026dd">a</a> <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1aeab71244afb687f16d8c4f5ee9d6ef0e">SimObject.\n\n</a>" "Currently no applied use, not network ready, not intended " "<a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1a2732ab74fa0237854c2ba0f75f88a624">for</a> game development, <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1a2732ab74fa0237854c2ba0f75f88a624">for</a> editors or internal use <a href="/coding/file/cmdscan_8cpp/#cmdscan_8cpp_1aeab71244afb687f16d8c4f5ee9d6ef0e">only.\n\n</a> " " @internal" )

DefineEngineMethod(SimResponseCurve , addPoint , void , (F32 value, F32 time) , "addPoint( <a href="/coding/file/types_8h/#types_8h_1a841d3674577a1e86afdc2f4845f46c4b">F32</a> <a href="/coding/file/pointer_8h/#pointer_8h_1a32aff7c6c4cd253fdf6563677afab5ce">value</a>, <a href="/coding/file/types_8h/#types_8h_1a841d3674577a1e86afdc2f4845f46c4b">F32</a> time )" )

DefineEngineMethod(SimResponseCurve , clear , void , () , "clear()" )

DefineEngineMethod(SimResponseCurve , getValue , F32 , (F32 time) , "getValue( <a href="/coding/file/types_8h/#types_8h_1a841d3674577a1e86afdc2f4845f46c4b">F32</a> time )" )

IMPLEMENT_CONOBJECT(SimResponseCurve )

 1
 2//-----------------------------------------------------------------------------
 3// Copyright (c) 2012 GarageGames, LLC
 4//
 5// Permission is hereby granted, free of charge, to any person obtaining a copy
 6// of this software and associated documentation files (the "Software"), to
 7// deal in the Software without restriction, including without limitation the
 8// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
 9// sell copies of the Software, and to permit persons to whom the Software is
10// furnished to do so, subject to the following conditions:
11//
12// The above copyright notice and this permission notice shall be included in
13// all copies or substantial portions of the Software.
14//
15// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
21// IN THE SOFTWARE.
22//-----------------------------------------------------------------------------
23
24#include "tResponseCurve.h"
25#include "console/engineAPI.h"
26
27IMPLEMENT_CONOBJECT( SimResponseCurve );
28
29ConsoleDocClass( SimResponseCurve,
30            "@brief A ResponseCurve<F32> wrapped as a SimObject.\n\n"
31            "Currently no applied use, not network ready, not intended "
32            "for game development, for editors or internal use only.\n\n "
33            "@internal");
34
35SimResponseCurve::SimResponseCurve()
36{
37
38}
39
40bool SimResponseCurve::onAdd()
41{
42   if ( !Parent::onAdd() )
43      return false;
44
45   return true;
46}
47
48void SimResponseCurve::onRemove()
49{
50   Parent::onRemove();
51}
52
53void SimResponseCurve::addPoint(F32 value, F32 time)
54{
55   mCurve.addPoint( value, time );
56}
57
58F32 SimResponseCurve::getValue(F32 time)
59{
60   return mCurve.getVal( time );
61}
62
63void SimResponseCurve::clear()
64{
65   mCurve.clear();
66}
67
68DefineEngineMethod( SimResponseCurve, addPoint, void, ( F32 value, F32 time ), , "addPoint( F32 value, F32 time )" )
69{
70   object->addPoint( value, time );
71}
72
73DefineEngineMethod( SimResponseCurve, getValue, F32, ( F32 time ), , "getValue( F32 time )" )
74{
75   return object->getValue( time );
76}
77
78DefineEngineMethod( SimResponseCurve, clear, void, (), , "clear()" )
79{
80   object->clear();
81}
82