Open Inventor Release 2023.2.3
 
Loading...
Searching...
No Matches
SoInterpolate.h File Reference

Go to the source code of this file.

Classes

class  SoInterpolate
 Base class for all interpolator engines. More...
 
class  SoInterpolateFloat
 Interpolates floating-point values. More...
 
class  SoInterpolateRotation
 Interpolates rotation values. More...
 
class  SoInterpolateVec2f
 Interpolates 2D floating-point vectors. More...
 
class  SoInterpolateVec3f
 Interpolates 3D floating-point vectors. More...
 
class  SoInterpolateVec4f
 Interpolates 4D floating-point vectors. More...
 

Macros

#define SO_INTERPOLATE_HEADER(className)
 
#define SO_INTERPOLATE_SOURCE(className, type, valType, defaultVal0, defaultVal1, interpVal)
 
#define SO_INTERPOLATE_INITCLASS(className, classPrintName)
 
#define SO_INTERPOLATE_EXITCLASS(className)
 

Macro Definition Documentation

◆ SO_INTERPOLATE_EXITCLASS

#define SO_INTERPOLATE_EXITCLASS (   className)
Value:
\
void \
className::exitClass() \
{ \
SO_ENGINE_EXIT_CLASS(className); \
}

Definition at line 216 of file SoInterpolate.h.

◆ SO_INTERPOLATE_HEADER

#define SO_INTERPOLATE_HEADER (   className)
Value:
\
SO_ENGINE_HEADER(className); \
\
private: \
~className(); \ \
virtual void evaluate(); \
\
private:\
static void initClass(); \
static void exitClass(); \
\
public: \ \
className()

Definition at line 142 of file SoInterpolate.h.

◆ SO_INTERPOLATE_INITCLASS

#define SO_INTERPOLATE_INITCLASS (   className,
  classPrintName 
)
Value:
\
void \
className::initClass() \
{ \
SO__ENGINE_INIT_CLASS(className, classPrintName, SoInterpolate); \
}
Base class for all interpolator engines.

Definition at line 208 of file SoInterpolate.h.

◆ SO_INTERPOLATE_SOURCE

#define SO_INTERPOLATE_SOURCE (   className,
  type,
  valType,
  defaultVal0,
  defaultVal1,
  interpVal 
)
Value:
\
SO_ENGINE_SOURCE(className)/*;*/ \
\
className::className() \
{ \
SO_ENGINE_CONSTRUCTOR(className); \
SO_ENGINE_ADD_INPUT(alpha, (0.0)); \
SO_ENGINE_ADD_INPUT(input0, defaultVal0); \
SO_ENGINE_ADD_INPUT(input1, defaultVal1); \
SO_ENGINE_ADD_OUTPUT(output, type); \
isBuiltIn = TRUE; \
} \
\
className::~className() \
{ \
} \
\
void \
className::evaluate() \
{ \
int n0 = input0.getNum(); \
int n1 = input1.getNum(); \
float a = alpha.getValue(); \
for (int i=findMax(n0,n1)-1; i>=0; i--) { \
valType v0 = input0[clamp(i,n0)]; \
valType v1 = input1[clamp(i,n1)]; \
SO_ENGINE_OUTPUT(output, type, set1Value(i, interpVal)); \
} \
}
#define TRUE
Possible value of SbBool.
Definition SbBase.h:77

Definition at line 167 of file SoInterpolate.h.