public class SoSFRotation extends SoSField
SbRotation
(an arbitrary rotation).
SoSFRotations are written to file as four floating point values separated by whitespace. The 4 values represent an axis of rotation followed by the amount of right-handed rotation about that axis, in radians. For example, a 180 degree rotation about the Y axis is:
NOTE: When you specify an0 1 0 3.14159265
SoSFRotation
value using setValue with 4 floating point values, those values will be interpreted as a quaternion (x, y, z, w) rather than an axis and a rotation. To specify an SoSFRotation
value using an axis and a rotation, you must use the following method: setValue(const SbVec3f &axis, float angle)
.
See also:
SoField.FieldTypes
Inventor.ConstructorCommand
VERBOSE_LEVEL, ZeroHandle
Constructor and Description |
---|
SoSFRotation(SoFieldContainer fieldContainer,
java.lang.String fieldName,
SoField.FieldTypes fieldType,
SbRotation defaultValue)
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
SbRotation |
getValue()
Returns this field's value.
|
void |
setValue(float[] q)
Sets the field to the given quaternion (x, y, z, w).
|
void |
setValue(float q0,
float q1,
float q2,
float q3)
Sets the field to the given quaternion (x, y, z, w).
|
void |
setValue(SbRotation newValue)
Sets this field to
newValue.
|
void |
setValue(SbRotationd rotd)
Convenience method that allows you to specify a field value using a double precision variable.
|
void |
setValue(SbVec3f axis,
float angle)
Sets the field to the rotation given by axis/angle.
|
appendConnection, appendConnection, connectFrom, connectFrom, disconnect, disconnect, disconnect, enableConnection, get, getConnectedEngine, getConnectedField, getContainer, getNumConnections, getValueSize, isConnected, isConnectedFromEngine, isConnectedFromField, isConnectedFromVRMLInterp, isConnectionEnabled, isDefault, isIgnored, set, setIgnored, touch
dispose, getNativeResourceHandle
public SoSFRotation(SoFieldContainer fieldContainer, java.lang.String fieldName, SoField.FieldTypes fieldType, SbRotation defaultValue)
public void setValue(float q0, float q1, float q2, float q3)
public void setValue(float[] q)
public void setValue(SbRotation newValue)
public SbRotation getValue()
public void setValue(SbRotationd rotd)
public void setValue(SbVec3f axis, float angle)
Generated on July 31, 2019, Copyright © Thermo Fisher Scientific. All rights reserved. http://www.openinventor.com