Package org.lwjgl.openxr
Class XrCompositionLayerCylinderKHR
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.openxr.XrCompositionLayerCylinderKHR
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class XrCompositionLayerCylinderKHR extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceCylindrical layer composition info.Description
XrCompositionLayerCylinderKHRcontains the information needed to render a texture onto a cylinder when callingEndFrame.XrCompositionLayerCylinderKHRis an alias type for the base structXrCompositionLayerBaseHeaderused inXrFrameEndInfo.Valid Usage (Implicit)
- The
XR_KHR_composition_layer_cylinderextension must be enabled prior to usingXrCompositionLayerCylinderKHR typemust beTYPE_COMPOSITION_LAYER_CYLINDER_KHRnextmust beNULLor a valid pointer to the next structure in a structure chainlayerFlagsmust be 0 or a valid combination ofXrCompositionLayerFlagBitsvaluesspacemust be a validXrSpacehandleeyeVisibilitymust be a validXrEyeVisibilityvaluesubImagemust be a validXrSwapchainSubImagestructure
See Also
XrCompositionLayerBaseHeader,XrFrameEndInfo,XrPosef,XrSwapchainSubImage,EndFrameLayout
struct XrCompositionLayerCylinderKHR { XrStructureTypetype(); void const *next(); XrCompositionLayerFlagslayerFlags(); XrSpacespace(); XrEyeVisibility eyeVisibility;XrSwapchainSubImagesubImage();XrPosefpose(); floatradius(); floatcentralAngle(); floataspectRatio(); }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classXrCompositionLayerCylinderKHR.BufferAn array ofXrCompositionLayerCylinderKHRstructs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intASPECTRATIO
CENTRALANGLE
EYEVISIBILITY
LAYERFLAGS
NEXT
POSE
RADIUSThe struct member offsets.static intSIZEOFThe struct size in bytes.static intSPACE
SUBIMAGE
TYPEThe struct member offsets.
-
Constructor Summary
Constructors Constructor Description XrCompositionLayerCylinderKHR(java.nio.ByteBuffer container)Creates aXrCompositionLayerCylinderKHRinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description floataspectRatio()the ratio of the visible cylinder sectionwidth / height.XrCompositionLayerCylinderKHRaspectRatio(float value)Sets the specified value to theaspectRatio()field.static XrCompositionLayerCylinderKHRcalloc()Returns a newXrCompositionLayerCylinderKHRinstance allocated withmemCalloc.static XrCompositionLayerCylinderKHR.Buffercalloc(int capacity)Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated withmemCalloc.static XrCompositionLayerCylinderKHR.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XrCompositionLayerCylinderKHRcalloc(org.lwjgl.system.MemoryStack stack)Returns a newXrCompositionLayerCylinderKHRinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.floatcentralAngle()the angle of the visible section of the cylinder, based at 0 radians, in the range of[0, 2π).XrCompositionLayerCylinderKHRcentralAngle(float value)Sets the specified value to thecentralAngle()field.static XrCompositionLayerCylinderKHRcreate()Returns a newXrCompositionLayerCylinderKHRinstance allocated withBufferUtils.static XrCompositionLayerCylinderKHR.Buffercreate(int capacity)Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated withBufferUtils.static XrCompositionLayerCylinderKHRcreate(long address)Returns a newXrCompositionLayerCylinderKHRinstance for the specified memory address.static XrCompositionLayerCylinderKHR.Buffercreate(long address, int capacity)Create aXrCompositionLayerCylinderKHR.Bufferinstance at the specified memory.static XrCompositionLayerCylinderKHRcreate(XrCompositionLayerBaseHeader value)Downcasts the specifiedXrCompositionLayerBaseHeaderinstance toXrCompositionLayerCylinderKHR.static XrCompositionLayerCylinderKHR.Buffercreate(XrCompositionLayerBaseHeader.Buffer value)Downcasts the specifiedXrCompositionLayerBaseHeader.Bufferinstance toXrCompositionLayerCylinderKHR.Buffer.static XrCompositionLayerCylinderKHRcreateSafe(long address)static XrCompositionLayerCylinderKHR.BuffercreateSafe(long address, int capacity)inteyeVisibility()XrCompositionLayerCylinderKHReyeVisibility(int value)Sets the specified value to theeyeVisibilityfield.longlayerFlags()specifies options for the layer.XrCompositionLayerCylinderKHRlayerFlags(long value)Sets the specified value to thelayerFlags()field.static XrCompositionLayerCylinderKHRmalloc()Returns a newXrCompositionLayerCylinderKHRinstance allocated withmemAlloc.static XrCompositionLayerCylinderKHR.Buffermalloc(int capacity)Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated withmemAlloc.static XrCompositionLayerCylinderKHR.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated on the specifiedMemoryStack.static XrCompositionLayerCylinderKHRmalloc(org.lwjgl.system.MemoryStack stack)Returns a newXrCompositionLayerCylinderKHRinstance allocated on the specifiedMemoryStack.static floatnaspectRatio(long struct)Unsafe version ofaspectRatio().static voidnaspectRatio(long struct, float value)Unsafe version ofaspectRatio.static floatncentralAngle(long struct)Unsafe version ofcentralAngle().static voidncentralAngle(long struct, float value)Unsafe version ofcentralAngle.longnext()NULLor a pointer to the next structure in a structure chain.XrCompositionLayerCylinderKHRnext(long value)Sets the specified value to thenext()field.static intneyeVisibility(long struct)Unsafe version ofeyeVisibility().static voidneyeVisibility(long struct, int value)Unsafe version ofeyeVisibility.static longnlayerFlags(long struct)Unsafe version oflayerFlags().static voidnlayerFlags(long struct, long value)Unsafe version oflayerFlags.static longnnext(long struct)Unsafe version ofnext().static voidnnext(long struct, long value)Unsafe version ofnext.static XrPosefnpose(long struct)Unsafe version ofpose().static voidnpose(long struct, XrPosef value)Unsafe version ofpose.static floatnradius(long struct)Unsafe version ofradius().static voidnradius(long struct, float value)Unsafe version ofradius.static longnspace(long struct)Unsafe version ofspace().static voidnspace(long struct, XrSpace value)Unsafe version ofspace.static XrSwapchainSubImagensubImage(long struct)Unsafe version ofsubImage().static voidnsubImage(long struct, XrSwapchainSubImage value)Unsafe version ofsubImage.static intntype(long struct)Unsafe version oftype().static voidntype(long struct, int value)Unsafe version oftype.XrPosefpose()anXrPosefdefining the position and orientation of the center point of the view of the cylinder within the reference frame of thespace.XrCompositionLayerCylinderKHRpose(java.util.function.Consumer<XrPosef> consumer)Passes thepose()field to the specifiedConsumer.XrCompositionLayerCylinderKHRpose(XrPosef value)floatradius()the non-negative radius of the cylinder.XrCompositionLayerCylinderKHRradius(float value)Sets the specified value to theradius()field.XrCompositionLayerCylinderKHRset(int type, long next, long layerFlags, XrSpace space, int eyeVisibility, XrSwapchainSubImage subImage, XrPosef pose, float radius, float centralAngle, float aspectRatio)Initializes this struct with the specified values.XrCompositionLayerCylinderKHRset(XrCompositionLayerCylinderKHR src)Copies the specified struct data to this struct.intsizeof()longspace()theXrSpacein which theposeof the cylinder layer is evaluated over time.XrCompositionLayerCylinderKHRspace(XrSpace value)Sets the specified value to thespace()field.XrSwapchainSubImagesubImage()identifies the imageXrSwapchainSubImageto use.XrCompositionLayerCylinderKHRsubImage(java.util.function.Consumer<XrSwapchainSubImage> consumer)Passes thesubImage()field to the specifiedConsumer.XrCompositionLayerCylinderKHRsubImage(XrSwapchainSubImage value)Copies the specifiedXrSwapchainSubImageto thesubImage()field.inttype()theXrStructureTypeof this structure.XrCompositionLayerCylinderKHRtype(int value)Sets the specified value to thetype()field.XrCompositionLayerCylinderKHRtype$Default()Sets theTYPE_COMPOSITION_LAYER_CYLINDER_KHRvalue to thetype()field.static voidvalidate(long struct)Validates pointer members that should not beNULL.
-
-
-
Constructor Detail
-
XrCompositionLayerCylinderKHR
public XrCompositionLayerCylinderKHR(java.nio.ByteBuffer container)
Creates aXrCompositionLayerCylinderKHRinstance 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
-
type
public int type()
theXrStructureTypeof this structure.
-
next
public long next()
NULLor a pointer to the next structure in a structure chain. No such structures are defined in core OpenXR or this extension.
-
layerFlags
public long layerFlags()
specifies options for the layer.
-
space
public long space()
theXrSpacein which theposeof the cylinder layer is evaluated over time.
-
eyeVisibility
public int eyeVisibility()
- Returns:
- the value of the
eyeVisibilityfield.
-
subImage
public XrSwapchainSubImage subImage()
identifies the imageXrSwapchainSubImageto use.
-
pose
public XrPosef pose()
anXrPosefdefining the position and orientation of the center point of the view of the cylinder within the reference frame of thespace.
-
radius
public float radius()
the non-negative radius of the cylinder. Values of zero or floating point positive infinity are treated as an infinite cylinder.
-
centralAngle
public float centralAngle()
the angle of the visible section of the cylinder, based at 0 radians, in the range of[0, 2π). It grows symmetrically around the 0 radian angle.
-
aspectRatio
public float aspectRatio()
the ratio of the visible cylinder sectionwidth / height. The height of the cylinder is given by:(cylinder radius × cylinder angle) / aspectRatio.
-
type
public XrCompositionLayerCylinderKHR type(int value)
Sets the specified value to thetype()field.
-
type$Default
public XrCompositionLayerCylinderKHR type$Default()
Sets theTYPE_COMPOSITION_LAYER_CYLINDER_KHRvalue to thetype()field.
-
next
public XrCompositionLayerCylinderKHR next(long value)
Sets the specified value to thenext()field.
-
layerFlags
public XrCompositionLayerCylinderKHR layerFlags(long value)
Sets the specified value to thelayerFlags()field.
-
space
public XrCompositionLayerCylinderKHR space(XrSpace value)
Sets the specified value to thespace()field.
-
eyeVisibility
public XrCompositionLayerCylinderKHR eyeVisibility(int value)
Sets the specified value to theeyeVisibilityfield.
-
subImage
public XrCompositionLayerCylinderKHR subImage(XrSwapchainSubImage value)
Copies the specifiedXrSwapchainSubImageto thesubImage()field.
-
subImage
public XrCompositionLayerCylinderKHR subImage(java.util.function.Consumer<XrSwapchainSubImage> consumer)
Passes thesubImage()field to the specifiedConsumer.
-
pose
public XrCompositionLayerCylinderKHR pose(XrPosef value)
-
pose
public XrCompositionLayerCylinderKHR pose(java.util.function.Consumer<XrPosef> consumer)
Passes thepose()field to the specifiedConsumer.
-
radius
public XrCompositionLayerCylinderKHR radius(float value)
Sets the specified value to theradius()field.
-
centralAngle
public XrCompositionLayerCylinderKHR centralAngle(float value)
Sets the specified value to thecentralAngle()field.
-
aspectRatio
public XrCompositionLayerCylinderKHR aspectRatio(float value)
Sets the specified value to theaspectRatio()field.
-
set
public XrCompositionLayerCylinderKHR set(int type, long next, long layerFlags, XrSpace space, int eyeVisibility, XrSwapchainSubImage subImage, XrPosef pose, float radius, float centralAngle, float aspectRatio)
Initializes this struct with the specified values.
-
set
public XrCompositionLayerCylinderKHR set(XrCompositionLayerCylinderKHR src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static XrCompositionLayerCylinderKHR malloc()
Returns a newXrCompositionLayerCylinderKHRinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static XrCompositionLayerCylinderKHR calloc()
Returns a newXrCompositionLayerCylinderKHRinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static XrCompositionLayerCylinderKHR create()
Returns a newXrCompositionLayerCylinderKHRinstance allocated withBufferUtils.
-
create
public static XrCompositionLayerCylinderKHR create(long address)
Returns a newXrCompositionLayerCylinderKHRinstance for the specified memory address.
-
createSafe
@Nullable public static XrCompositionLayerCylinderKHR createSafe(long address)
-
create
public static XrCompositionLayerCylinderKHR create(XrCompositionLayerBaseHeader value)
Downcasts the specifiedXrCompositionLayerBaseHeaderinstance toXrCompositionLayerCylinderKHR.
-
malloc
public static XrCompositionLayerCylinderKHR.Buffer malloc(int capacity)
Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static XrCompositionLayerCylinderKHR.Buffer calloc(int capacity)
Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static XrCompositionLayerCylinderKHR.Buffer create(int capacity)
Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static XrCompositionLayerCylinderKHR.Buffer create(long address, int capacity)
Create aXrCompositionLayerCylinderKHR.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static XrCompositionLayerCylinderKHR.Buffer createSafe(long address, int capacity)
-
create
public static XrCompositionLayerCylinderKHR.Buffer create(XrCompositionLayerBaseHeader.Buffer value)
Downcasts the specifiedXrCompositionLayerBaseHeader.Bufferinstance toXrCompositionLayerCylinderKHR.Buffer.
-
malloc
public static XrCompositionLayerCylinderKHR malloc(org.lwjgl.system.MemoryStack stack)
Returns a newXrCompositionLayerCylinderKHRinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static XrCompositionLayerCylinderKHR calloc(org.lwjgl.system.MemoryStack stack)
Returns a newXrCompositionLayerCylinderKHRinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static XrCompositionLayerCylinderKHR.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static XrCompositionLayerCylinderKHR.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXrCompositionLayerCylinderKHR.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
ntype
public static int ntype(long struct)
Unsafe version oftype().
-
nnext
public static long nnext(long struct)
Unsafe version ofnext().
-
nlayerFlags
public static long nlayerFlags(long struct)
Unsafe version oflayerFlags().
-
nspace
public static long nspace(long struct)
Unsafe version ofspace().
-
neyeVisibility
public static int neyeVisibility(long struct)
Unsafe version ofeyeVisibility().
-
nsubImage
public static XrSwapchainSubImage nsubImage(long struct)
Unsafe version ofsubImage().
-
nradius
public static float nradius(long struct)
Unsafe version ofradius().
-
ncentralAngle
public static float ncentralAngle(long struct)
Unsafe version ofcentralAngle().
-
naspectRatio
public static float naspectRatio(long struct)
Unsafe version ofaspectRatio().
-
ntype
public static void ntype(long struct, int value)Unsafe version oftype.
-
nnext
public static void nnext(long struct, long value)Unsafe version ofnext.
-
nlayerFlags
public static void nlayerFlags(long struct, long value)Unsafe version oflayerFlags.
-
neyeVisibility
public static void neyeVisibility(long struct, int value)Unsafe version ofeyeVisibility.
-
nsubImage
public static void nsubImage(long struct, XrSwapchainSubImage value)Unsafe version ofsubImage.
-
nradius
public static void nradius(long struct, float value)Unsafe version ofradius.
-
ncentralAngle
public static void ncentralAngle(long struct, float value)Unsafe version ofcentralAngle.
-
naspectRatio
public static void naspectRatio(long struct, float value)Unsafe version ofaspectRatio.
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL.- Parameters:
struct- the struct to validate
-
-