Class XrPosef
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.openxr.XrPosef
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class XrPosef extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceLocation and orientation in a space.Description
A runtime must return
ERROR_POSE_INVALIDif theorientationnorm deviates by more than 1% from unit length.See Also
XrActionSpaceCreateInfo,XrCompositionLayerCylinderKHR,XrCompositionLayerEquirect2KHR,XrCompositionLayerEquirectKHR,XrCompositionLayerProjectionView,XrCompositionLayerQuad,XrCompositionLayerSpaceWarpInfoFB,XrControllerModelNodeStateMSFT,XrEventDataReferenceSpaceChangePending,XrGeometryInstanceCreateInfoFB,XrGeometryInstanceTransformFB,XrHandJointLocationEXT,XrHandMeshSpaceCreateInfoMSFT,XrHandTrackingAimStateFB,XrHandTrackingMeshFB,XrMarkerSpaceCreateInfoVARJO,XrQuaternionf,XrReferenceSpaceCreateInfo,XrSceneComponentLocationMSFT,XrSceneFrustumBoundMSFT,XrSceneOrientedBoxBoundMSFT,XrSpaceLocation,XrSpatialAnchorCreateInfoMSFT,XrSpatialAnchorSpaceCreateInfoMSFT,XrSpatialGraphNodeSpaceCreateInfoMSFT,XrVector2f,XrVector3f,XrVector4f,XrView,SetInputDeviceLocationEXTLayout
struct XrPosef {XrQuaternionforientation();XrVector3fposition; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classXrPosef.BufferAn array ofXrPosefstructs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intORIENTATION
POSITIONThe struct member offsets.static intSIZEOFThe struct size in bytes.
-
Constructor Summary
Constructors Constructor Description XrPosef(java.nio.ByteBuffer container)Creates aXrPosefinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static XrPosefcalloc()Returns a newXrPosefinstance allocated withmemCalloc.static XrPosef.Buffercalloc(int capacity)Returns a newXrPosef.Bufferinstance allocated withmemCalloc.static XrPosef.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXrPosef.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XrPosefcalloc(org.lwjgl.system.MemoryStack stack)Returns a newXrPosefinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XrPosefcreate()Returns a newXrPosefinstance allocated withBufferUtils.static XrPosef.Buffercreate(int capacity)Returns a newXrPosef.Bufferinstance allocated withBufferUtils.static XrPosefcreate(long address)Returns a newXrPosefinstance for the specified memory address.static XrPosef.Buffercreate(long address, int capacity)Create aXrPosef.Bufferinstance at the specified memory.static XrPosefcreateSafe(long address)static XrPosef.BuffercreateSafe(long address, int capacity)static XrPosefmalloc()Returns a newXrPosefinstance allocated withmemAlloc.static XrPosef.Buffermalloc(int capacity)Returns a newXrPosef.Bufferinstance allocated withmemAlloc.static XrPosef.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXrPosef.Bufferinstance allocated on the specifiedMemoryStack.static XrPosefmalloc(org.lwjgl.system.MemoryStack stack)Returns a newXrPosefinstance allocated on the specifiedMemoryStack.static XrQuaternionfnorientation(long struct)Unsafe version oforientation().static voidnorientation(long struct, XrQuaternionf value)Unsafe version oforientation.static XrVector3fnposition$(long struct)Unsafe version ofposition$().static voidnposition$(long struct, XrVector3f value)Unsafe version ofposition$.XrQuaternionforientation()anXrQuaternionfrepresenting the orientation within a space.XrPoseforientation(java.util.function.Consumer<XrQuaternionf> consumer)Passes theorientation()field to the specifiedConsumer.XrPoseforientation(XrQuaternionf value)Copies the specifiedXrQuaternionfto theorientation()field.XrVector3fposition$()anXrVector3frepresenting position within a space.XrPosefposition$(java.util.function.Consumer<XrVector3f> consumer)Passes theposition$()field to the specifiedConsumer.XrPosefposition$(XrVector3f value)Copies the specifiedXrVector3fto theposition$()field.XrPosefset(XrPosef src)Copies the specified struct data to this struct.XrPosefset(XrQuaternionf orientation, XrVector3f position$)Initializes this struct with the specified values.intsizeof()
-
-
-
Constructor Detail
-
XrPosef
public XrPosef(java.nio.ByteBuffer container)
Creates aXrPosefinstance 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
-
orientation
public XrQuaternionf orientation()
anXrQuaternionfrepresenting the orientation within a space.
-
position$
public XrVector3f position$()
anXrVector3frepresenting position within a space.
-
orientation
public XrPosef orientation(XrQuaternionf value)
Copies the specifiedXrQuaternionfto theorientation()field.
-
orientation
public XrPosef orientation(java.util.function.Consumer<XrQuaternionf> consumer)
Passes theorientation()field to the specifiedConsumer.
-
position$
public XrPosef position$(XrVector3f value)
Copies the specifiedXrVector3fto theposition$()field.
-
position$
public XrPosef position$(java.util.function.Consumer<XrVector3f> consumer)
Passes theposition$()field to the specifiedConsumer.
-
set
public XrPosef set(XrQuaternionf orientation, XrVector3f position$)
Initializes this struct with the specified values.
-
set
public XrPosef set(XrPosef src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static XrPosef malloc()
Returns a newXrPosefinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static XrPosef calloc()
Returns a newXrPosefinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static XrPosef create()
Returns a newXrPosefinstance allocated withBufferUtils.
-
create
public static XrPosef create(long address)
Returns a newXrPosefinstance for the specified memory address.
-
createSafe
@Nullable public static XrPosef createSafe(long address)
-
malloc
public static XrPosef.Buffer malloc(int capacity)
Returns a newXrPosef.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static XrPosef.Buffer calloc(int capacity)
Returns a newXrPosef.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static XrPosef.Buffer create(int capacity)
Returns a newXrPosef.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static XrPosef.Buffer create(long address, int capacity)
Create aXrPosef.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static XrPosef.Buffer createSafe(long address, int capacity)
-
malloc
public static XrPosef malloc(org.lwjgl.system.MemoryStack stack)
Returns a newXrPosefinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static XrPosef calloc(org.lwjgl.system.MemoryStack stack)
Returns a newXrPosefinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static XrPosef.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXrPosef.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static XrPosef.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXrPosef.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
norientation
public static XrQuaternionf norientation(long struct)
Unsafe version oforientation().
-
nposition$
public static XrVector3f nposition$(long struct)
Unsafe version ofposition$().
-
norientation
public static void norientation(long struct, XrQuaternionf value)Unsafe version oforientation.
-
nposition$
public static void nposition$(long struct, XrVector3f value)Unsafe version ofposition$.
-
-