Package org.lwjgl.openxr
Class XrHandJointVelocityEXT
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.openxr.XrHandJointVelocityEXT
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class XrHandJointVelocityEXT extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceDescribes the velocity of a hand joint.Valid Usage (Implicit)
- The
XR_EXT_hand_trackingextension must be enabled prior to usingXrHandJointVelocityEXT velocityFlagsmust be a valid combination ofXrSpaceVelocityFlagBitsvaluesvelocityFlagsmust not be 0
See Also
XrHandJointVelocitiesEXT,XrVector3fLayout
struct XrHandJointVelocityEXT { XrSpaceVelocityFlagsvelocityFlags();XrVector3flinearVelocity();XrVector3fangularVelocity(); }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classXrHandJointVelocityEXT.BufferAn array ofXrHandJointVelocityEXTstructs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intANGULARVELOCITY
LINEARVELOCITYThe struct member offsets.static intSIZEOFThe struct size in bytes.static intVELOCITYFLAGSThe struct member offsets.
-
Constructor Summary
Constructors Constructor Description XrHandJointVelocityEXT(java.nio.ByteBuffer container)Creates aXrHandJointVelocityEXTinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description XrVector3fangularVelocity()the relative angular velocity of the hand joint with respect to the correspondingXrHandJointsLocateInfoEXT::baseSpace.XrHandJointVelocityEXTangularVelocity(java.util.function.Consumer<XrVector3f> consumer)Passes theangularVelocity()field to the specifiedConsumer.XrHandJointVelocityEXTangularVelocity(XrVector3f value)Copies the specifiedXrVector3fto theangularVelocity()field.static XrHandJointVelocityEXTcalloc()Returns a newXrHandJointVelocityEXTinstance allocated withmemCalloc.static XrHandJointVelocityEXT.Buffercalloc(int capacity)Returns a newXrHandJointVelocityEXT.Bufferinstance allocated withmemCalloc.static XrHandJointVelocityEXT.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXrHandJointVelocityEXT.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XrHandJointVelocityEXTcalloc(org.lwjgl.system.MemoryStack stack)Returns a newXrHandJointVelocityEXTinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XrHandJointVelocityEXTcreate()Returns a newXrHandJointVelocityEXTinstance allocated withBufferUtils.static XrHandJointVelocityEXT.Buffercreate(int capacity)Returns a newXrHandJointVelocityEXT.Bufferinstance allocated withBufferUtils.static XrHandJointVelocityEXTcreate(long address)Returns a newXrHandJointVelocityEXTinstance for the specified memory address.static XrHandJointVelocityEXT.Buffercreate(long address, int capacity)Create aXrHandJointVelocityEXT.Bufferinstance at the specified memory.static XrHandJointVelocityEXTcreateSafe(long address)static XrHandJointVelocityEXT.BuffercreateSafe(long address, int capacity)XrVector3flinearVelocity()the relative linear velocity of the hand joint with respect to and expressed in the reference frame of the correspondingXrHandJointsLocateInfoEXT::baseSpace, in units of meters per second.XrHandJointVelocityEXTlinearVelocity(java.util.function.Consumer<XrVector3f> consumer)Passes thelinearVelocity()field to the specifiedConsumer.XrHandJointVelocityEXTlinearVelocity(XrVector3f value)Copies the specifiedXrVector3fto thelinearVelocity()field.static XrHandJointVelocityEXTmalloc()Returns a newXrHandJointVelocityEXTinstance allocated withmemAlloc.static XrHandJointVelocityEXT.Buffermalloc(int capacity)Returns a newXrHandJointVelocityEXT.Bufferinstance allocated withmemAlloc.static XrHandJointVelocityEXT.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXrHandJointVelocityEXT.Bufferinstance allocated on the specifiedMemoryStack.static XrHandJointVelocityEXTmalloc(org.lwjgl.system.MemoryStack stack)Returns a newXrHandJointVelocityEXTinstance allocated on the specifiedMemoryStack.static XrVector3fnangularVelocity(long struct)Unsafe version ofangularVelocity().static voidnangularVelocity(long struct, XrVector3f value)Unsafe version ofangularVelocity.static XrVector3fnlinearVelocity(long struct)Unsafe version oflinearVelocity().static voidnlinearVelocity(long struct, XrVector3f value)Unsafe version oflinearVelocity.static longnvelocityFlags(long struct)Unsafe version ofvelocityFlags().static voidnvelocityFlags(long struct, long value)Unsafe version ofvelocityFlags.XrHandJointVelocityEXTset(long velocityFlags, XrVector3f linearVelocity, XrVector3f angularVelocity)Initializes this struct with the specified values.XrHandJointVelocityEXTset(XrHandJointVelocityEXT src)Copies the specified struct data to this struct.intsizeof()longvelocityFlags()a bitfield, with bit masks defined inXrSpaceVelocityFlagBits, to indicate which members contain valid data.XrHandJointVelocityEXTvelocityFlags(long value)Sets the specified value to thevelocityFlags()field.
-
-
-
Constructor Detail
-
XrHandJointVelocityEXT
public XrHandJointVelocityEXT(java.nio.ByteBuffer container)
Creates aXrHandJointVelocityEXTinstance at the current position of the specifiedByteBuffercontainer. Changes to the buffer's content will be visible to the struct instance and vice versa.The created instance holds a strong reference to the container object.
-
-
Method Detail
-
sizeof
public int sizeof()
- Specified by:
sizeofin classorg.lwjgl.system.Struct
-
velocityFlags
public long velocityFlags()
a bitfield, with bit masks defined inXrSpaceVelocityFlagBits, to indicate which members contain valid data. If none of the bits are set, no other fields in this structure should be considered to be valid or meaningful.
-
linearVelocity
public XrVector3f linearVelocity()
the relative linear velocity of the hand joint with respect to and expressed in the reference frame of the correspondingXrHandJointsLocateInfoEXT::baseSpace, in units of meters per second.
-
angularVelocity
public XrVector3f angularVelocity()
the relative angular velocity of the hand joint with respect to the correspondingXrHandJointsLocateInfoEXT::baseSpace. The vector’s direction is expressed in the reference frame of the correspondingXrHandJointsLocateInfoEXT::baseSpaceand is parallel to the rotational axis of the hand joint. The vector’s magnitude is the relative angular speed of the hand joint in radians per second. The vector follows the right-hand rule for torque/rotation.
-
velocityFlags
public XrHandJointVelocityEXT velocityFlags(long value)
Sets the specified value to thevelocityFlags()field.
-
linearVelocity
public XrHandJointVelocityEXT linearVelocity(XrVector3f value)
Copies the specifiedXrVector3fto thelinearVelocity()field.
-
linearVelocity
public XrHandJointVelocityEXT linearVelocity(java.util.function.Consumer<XrVector3f> consumer)
Passes thelinearVelocity()field to the specifiedConsumer.
-
angularVelocity
public XrHandJointVelocityEXT angularVelocity(XrVector3f value)
Copies the specifiedXrVector3fto theangularVelocity()field.
-
angularVelocity
public XrHandJointVelocityEXT angularVelocity(java.util.function.Consumer<XrVector3f> consumer)
Passes theangularVelocity()field to the specifiedConsumer.
-
set
public XrHandJointVelocityEXT set(long velocityFlags, XrVector3f linearVelocity, XrVector3f angularVelocity)
Initializes this struct with the specified values.
-
set
public XrHandJointVelocityEXT set(XrHandJointVelocityEXT src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static XrHandJointVelocityEXT malloc()
Returns a newXrHandJointVelocityEXTinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static XrHandJointVelocityEXT calloc()
Returns a newXrHandJointVelocityEXTinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static XrHandJointVelocityEXT create()
Returns a newXrHandJointVelocityEXTinstance allocated withBufferUtils.
-
create
public static XrHandJointVelocityEXT create(long address)
Returns a newXrHandJointVelocityEXTinstance for the specified memory address.
-
createSafe
@Nullable public static XrHandJointVelocityEXT createSafe(long address)
-
malloc
public static XrHandJointVelocityEXT.Buffer malloc(int capacity)
Returns a newXrHandJointVelocityEXT.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static XrHandJointVelocityEXT.Buffer calloc(int capacity)
Returns a newXrHandJointVelocityEXT.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static XrHandJointVelocityEXT.Buffer create(int capacity)
Returns a newXrHandJointVelocityEXT.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static XrHandJointVelocityEXT.Buffer create(long address, int capacity)
Create aXrHandJointVelocityEXT.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static XrHandJointVelocityEXT.Buffer createSafe(long address, int capacity)
-
malloc
public static XrHandJointVelocityEXT malloc(org.lwjgl.system.MemoryStack stack)
Returns a newXrHandJointVelocityEXTinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static XrHandJointVelocityEXT calloc(org.lwjgl.system.MemoryStack stack)
Returns a newXrHandJointVelocityEXTinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static XrHandJointVelocityEXT.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXrHandJointVelocityEXT.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static XrHandJointVelocityEXT.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXrHandJointVelocityEXT.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nvelocityFlags
public static long nvelocityFlags(long struct)
Unsafe version ofvelocityFlags().
-
nlinearVelocity
public static XrVector3f nlinearVelocity(long struct)
Unsafe version oflinearVelocity().
-
nangularVelocity
public static XrVector3f nangularVelocity(long struct)
Unsafe version ofangularVelocity().
-
nvelocityFlags
public static void nvelocityFlags(long struct, long value)Unsafe version ofvelocityFlags.
-
nlinearVelocity
public static void nlinearVelocity(long struct, XrVector3f value)Unsafe version oflinearVelocity.
-
nangularVelocity
public static void nangularVelocity(long struct, XrVector3f value)Unsafe version ofangularVelocity.
-
-