Class: OrientationInterpolator

X3D: 3.3
Component: Interpolation
Status:
fully implemented

x3dom.nodeTypes. OrientationInterpolator

The OrientationInterpolator node interpolates among a list of rotation values specified in the keyValue field to produce an SFRotation value_changed event. These rotations are absolute in object space and therefore are not cumulative. The keyValue field shall contain exactly as many rotations as there are key frames in the key field. An orientation represents the final position of an object after a rotation has been applied. An OrientationInterpolator interpolates between two orientations by computing the shortest path on the unit sphere between the two orientations. The interpolation is linear in arc length along this path. The results are undefined if the two orientations are diagonally opposite.

HTML Encoding and Default Values

<OrientationInterpolator key='[]' keyValue='[]' metadata='X3DMetadataObject' set_fraction='0' ></OrientationInterpolator>

Inheritance


Constructor

OrientationInterpolator(ctx)

Constructor for OrientationInterpolator

Parameters:
Name Type Argument Default Description
ctx Object <optional>
null context object, containing initial settings like namespace

Fields

These are the X3D / X3DOM fields of this node. Values should usually be received / set as strings via DOM functions (i.e., using setAttribute("myFieldName", "myFieldValue") and getAttribute("myFieldName")).
Name Type Default Value Range Inheritance Standard Description
key MFFloat [] X3DInterpolatorNode The key field contains the list of key times, the keyValue field contains values for the target field, one complete set of values for each key. Interpolator nodes containing no keys in the key field shall not produce any events. However, an input event that replaces an empty key field with one that contains keys will cause the interpolator node to produce events the next time that a set_fraction event is received.
keyValue MFRotation [] Defines the set of data points, that are used for interpolation. If two consecutive keyValue values exist such that the arc length between them is greater than π, the interpolation will take place on the arc complement. For example, the interpolation between the orientations (0, 1, 0, 0) and (0, 1, 0, 5.0) is equivalent to the rotation between the orientations (0, 1, 0, 2π) and (0, 1, 0, 5.0).
metadata SFNode X3DMetadataObject X3DInterpolatorNode Field to add metadata information
set_fraction SFFloat 0 X3DInterpolatorNode The set_fraction inputOnly field receives an SFFloat event and causes the interpolator node function to evaluate, resulting in a value_changed output event of the specified type with the same timestamp as the set_fraction event.