Interpolator
- Last UpdatedDec 07, 2023
- 2 minute read
The Interpolator node generates a path starting from two or more keypoints.
-
Interpolator works for all the different float types: SFLOAT, SVEC2, SVEC4.
-
The engine supports only linear interpolation mode.
-
The interpolator node must contain one or more key nodes.
Platform support
This node is supported on XR-Windows platform only.
|
XR-WIN |
XR-P-WIN |
XR-P-IOS |
XR-P-AND |
XR-P-WASM |
|---|---|---|---|---|
|
Full support |
No support |
No support |
No support |
No support |
|
|
|
|
|
|
Code example
This is a code example for the Interpolator node.
<interpolator name="logo_rot" type="float" mode="linear">
<key alpha="0" value="0"/>
<key alpha="1" value="6.28"/>
</interpolator>
Position
The Interpolator node must be inside a context node, such as Context or Global.
Interpolator fields
These are the fields for Interpolator node. Only the node-specific fields are indicated, not fields obtained by inheritance.
Field inheritance: NodeBase > Interpolator
|
Fields |
Type |
Use |
Default value |
Description |
|---|---|---|---|---|
|
type |
sstring |
Mandatory |
Not set |
The type can be FLOAT, VEC2, or VEC4. The selected type is reflected on the value type output. |
Key attributes
These are the attributes for the alpha elements.
|
Attribute |
Type |
Use |
Default value |
Description |
|---|---|---|---|---|
|
alpha |
sfloat |
Optional |
Not set |
The interpolation input. Use this parameter to move output along the interpolated path. Values must be between minimum key alpha and maximum key alpha. By convention interpolation is usually interpolated between 0 and 1. |
|
value |
sstring |
Read only |
Not set |
The interpolation output value. |