BitmapToolkit Scol plugin
Functions | Variables
MathToolkit.cpp File Reference
#include "Prerequisites.h"
#include "Smoothers.h"

Go to the source code of this file.

Functions

int Random (int mi, int mx)
 
int destroySmootherObj (mmachine m, SCOL_PTR_TYPE handsys, int obj)
 
void pushValue (ISmoother *smoother, float value1, float value2, float value3)
 
void getSmoothedValue (ISmoother *smoother, float &value1, float &value2, float &value3)
 
void getExtrapolatedValue (ISmoother *smoother, float &value1, float &value2, float &value3)
 
int _CRsmoother (mmachine m)
 _CRsmoother : Create a new Smoother object
 
int _CLRsmoother (mmachine m)
 _CLRsmoother : Clears smoother state
 
int _DSsmoother (mmachine m)
 _DSsmoother : Destroys a Smoother object
 
int _PUSHsmootherValue1 (mmachine m)
 _PUSHsmootherValue1 : Push a new value to ObjSmoother
 
int _PUSHsmootherValue2 (mmachine m)
 _PUSHsmootherValue2 : Push a new vector2 value to ObjSmoother
 
int _PUSHsmootherValue3 (mmachine m)
 _PUSHsmootherValue3 : Push a new vector3 value to ObjSmoother
 
int _GETsmootherSmoothedValue1 (mmachine m)
 _GETsmootherSmoothedValue1 : Get last smoothed value from smoother as simple float
 
int _GETsmootherSmoothedValue2 (mmachine m)
 _GETsmootherSmoothedValue2 : Get last smoothed value from smoother as a tuple of 2 float
 
int _GETsmootherSmoothedValue3 (mmachine m)
 _GETsmootherSmoothedValue3 : Get last smoothed value from smoother as a tuple of 3 float
 
int _GETsmootherExtrapolatedValue1 (mmachine m)
 _GETsmootherExtrapolatedValue1 : Get an extrapolated value from smoother as simple float
 
int _GETsmootherExtrapolatedValue2 (mmachine m)
 _GETsmootherExtrapolatedValue2 : Get an extrapolated value from smoother as a tuple of 2 float
 
int _GETsmootherExtrapolatedValue3 (mmachine m)
 _GETsmootherExtrapolatedValue3 : Get an extrapolated value from smoother as a tuple of 3 float
 
int LoadMathToolkit (mmachine m)
 Load the packages in Scol virtual machine.
 

Variables

int OBJSMOOTHERSCOL
 
NativeDefinition base_math_tk []
 

Function Documentation

◆ destroySmootherObj()

int destroySmootherObj ( mmachine  m,
SCOL_PTR_TYPE  handsys,
int  obj 
)

Definition at line 21 of file MathToolkit.cpp.

◆ getExtrapolatedValue()

void getExtrapolatedValue ( ISmoother smoother,
float &  value1,
float &  value2,
float &  value3 
)

Definition at line 87 of file MathToolkit.cpp.

◆ getSmoothedValue()

void getSmoothedValue ( ISmoother smoother,
float &  value1,
float &  value2,
float &  value3 
)

Definition at line 53 of file MathToolkit.cpp.

◆ LoadMathToolkit()

int LoadMathToolkit ( mmachine  m)

Load the packages in Scol virtual machine.

Parameters
mmachine: the scol machine

Definition at line 624 of file MathToolkit.cpp.

◆ pushValue()

void pushValue ( ISmoother smoother,
float  value1,
float  value2,
float  value3 
)

Definition at line 33 of file MathToolkit.cpp.

◆ Random()

int Random ( int  mi,
int  mx 
)

Definition at line 12 of file MathToolkit.cpp.

Variable Documentation

◆ base_math_tk

NativeDefinition base_math_tk[]
Initial value:
= {
{ "ObjSmoother", TYPTYPE, NULL, NULL },
{ "SMOOTHER_TYPE_UNDEFINED", TYPVAR, "I", SCOL_TYPTYPE(SMOOTHER_TYPE_UNDEFINED) },
{ "SMOOTHER_TYPE_FLOAT", TYPVAR, "I", SCOL_TYPTYPE(SMOOTHER_TYPE_FLOAT) },
{ "SMOOTHER_TYPE_VEC2", TYPVAR, "I", SCOL_TYPTYPE(SMOOTHER_TYPE_VEC2) },
{ "SMOOTHER_TYPE_VEC3", TYPVAR, "I", SCOL_TYPTYPE(SMOOTHER_TYPE_VEC3) },
{ "SMOOTHER_METHOD_UNDEFINED", TYPVAR, "I", SCOL_TYPTYPE(SMOOTHER_METHOD_UNDEFINED) },
{ "SMOOTHER_METHOD_LINEAR", TYPVAR, "I", SCOL_TYPTYPE(SMOOTHER_METHOD_LINEAR) },
{ "SMOOTHER_METHOD_DOUBLEEXP", TYPVAR, "I", SCOL_TYPTYPE(SMOOTHER_METHOD_DOUBLEEXP) },
{ "_CRsmoother", 5, "fun [Chn I I F F] ObjSmoother", _CRsmoother },
{ "_CLRsmoother", 1, "fun [ObjSmoother] ObjSmoother", _CLRsmoother },
{ "_DSsmoother", 1, "fun [ObjSmoother] I", _DSsmoother },
{ "_PUSHsmootherValue1", 2, "fun [ObjSmoother F] ObjSmoother", _PUSHsmootherValue1 },
{ "_PUSHsmootherValue2", 3, "fun [ObjSmoother F F] ObjSmoother", _PUSHsmootherValue2 },
{ "_PUSHsmootherValue3", 4, "fun [ObjSmoother F F F] ObjSmoother", _PUSHsmootherValue3 },
{ "_GETsmootherSmoothedValue1", 1, "fun [ObjSmoother] F", _GETsmootherSmoothedValue1 },
{ "_GETsmootherSmoothedValue2", 1, "fun [ObjSmoother] [F F]", _GETsmootherSmoothedValue2 },
{ "_GETsmootherSmoothedValue3", 1, "fun [ObjSmoother] [F F F]", _GETsmootherSmoothedValue3 },
{ "_GETsmootherExtrapolatedValue1", 1, "fun [ObjSmoother] F", _GETsmootherExtrapolatedValue1 },
{ "_GETsmootherExtrapolatedValue2", 1, "fun [ObjSmoother] [F F]", _GETsmootherExtrapolatedValue2 },
{ "_GETsmootherExtrapolatedValue3", 1, "fun [ObjSmoother] [F F F]", _GETsmootherExtrapolatedValue3 }
}
#define SMOOTHER_TYPE_VEC2
Definition Smoothers.h:9
#define SMOOTHER_TYPE_VEC3
Definition Smoothers.h:10
#define SMOOTHER_TYPE_FLOAT
Definition Smoothers.h:8
#define SMOOTHER_TYPE_UNDEFINED
Definition Smoothers.h:7
#define SMOOTHER_METHOD_LINEAR
Definition Smoothers.h:13
#define SMOOTHER_METHOD_UNDEFINED
Definition Smoothers.h:12
#define SMOOTHER_METHOD_DOUBLEEXP
Definition Smoothers.h:14
int _PUSHsmootherValue3(mmachine m)
_PUSHsmootherValue3 : Push a new vector3 value to ObjSmoother
int _GETsmootherExtrapolatedValue3(mmachine m)
_GETsmootherExtrapolatedValue3 : Get an extrapolated value from smoother as a tuple of 3 float
int _CLRsmoother(mmachine m)
_CLRsmoother : Clears smoother state
int _PUSHsmootherValue1(mmachine m)
_PUSHsmootherValue1 : Push a new value to ObjSmoother
int _PUSHsmootherValue2(mmachine m)
_PUSHsmootherValue2 : Push a new vector2 value to ObjSmoother
int _GETsmootherSmoothedValue2(mmachine m)
_GETsmootherSmoothedValue2 : Get last smoothed value from smoother as a tuple of 2 float
int _GETsmootherSmoothedValue1(mmachine m)
_GETsmootherSmoothedValue1 : Get last smoothed value from smoother as simple float
int _GETsmootherExtrapolatedValue2(mmachine m)
_GETsmootherExtrapolatedValue2 : Get an extrapolated value from smoother as a tuple of 2 float
int _GETsmootherExtrapolatedValue1(mmachine m)
_GETsmootherExtrapolatedValue1 : Get an extrapolated value from smoother as simple float
int _CRsmoother(mmachine m)
_CRsmoother : Create a new Smoother object
int _GETsmootherSmoothedValue3(mmachine m)
_GETsmootherSmoothedValue3 : Get last smoothed value from smoother as a tuple of 3 float
int _DSsmoother(mmachine m)
_DSsmoother : Destroys a Smoother object

Definition at line 592 of file MathToolkit.cpp.

◆ OBJSMOOTHERSCOL

int OBJSMOOTHERSCOL

Definition at line 10 of file MathToolkit.cpp.