Package org.lwjgl.bgfx
Class BGFXAttachment
- All Implemented Interfaces:
AutoCloseable,NativeResource,Pointer
struct bgfx_attachment_t {
bgfx_access_t access;
bgfx_texture_handle_t handle;
uint16_t mip;
uint16_t layer;
uint16_t numLayers;
uint8_t resolve;
}-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct member offsets.static final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionBGFXAttachment(ByteBuffer container) Creates aBGFXAttachmentinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionintaccess()access(int value) Sets the specified value to theaccessfield.static BGFXAttachmentcalloc()Returns a newBGFXAttachmentinstance allocated withmemCalloc.static BGFXAttachment.Buffercalloc(int capacity) Returns a newBGFXAttachment.Bufferinstance allocated withmemCalloc.static BGFXAttachment.Buffercalloc(int capacity, MemoryStack stack) Returns a newBGFXAttachment.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static BGFXAttachmentcalloc(MemoryStack stack) Returns a newBGFXAttachmentinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static BGFXAttachmentDeprecated.static BGFXAttachment.BuffercallocStack(int capacity) Deprecated.static BGFXAttachment.BuffercallocStack(int capacity, MemoryStack stack) Deprecated.static BGFXAttachmentcallocStack(MemoryStack stack) Deprecated.static BGFXAttachmentcreate()Returns a newBGFXAttachmentinstance allocated withBufferUtils.static BGFXAttachment.Buffercreate(int capacity) Returns a newBGFXAttachment.Bufferinstance allocated withBufferUtils.static BGFXAttachmentcreate(long address) Returns a newBGFXAttachmentinstance for the specified memory address.static BGFXAttachment.Buffercreate(long address, int capacity) Create aBGFXAttachment.Bufferinstance at the specified memory.static @Nullable BGFXAttachmentcreateSafe(long address) static @Nullable BGFXAttachment.BuffercreateSafe(long address, int capacity) shorthandle()handle(short value) Sets the specified value to thehandlefield.shortlayer()layer(short value) Sets the specified value to thelayerfield.static BGFXAttachmentmalloc()Returns a newBGFXAttachmentinstance allocated withmemAlloc.static BGFXAttachment.Buffermalloc(int capacity) Returns a newBGFXAttachment.Bufferinstance allocated withmemAlloc.static BGFXAttachment.Buffermalloc(int capacity, MemoryStack stack) Returns a newBGFXAttachment.Bufferinstance allocated on the specifiedMemoryStack.static BGFXAttachmentmalloc(MemoryStack stack) Returns a newBGFXAttachmentinstance allocated on the specifiedMemoryStack.static BGFXAttachmentDeprecated.static BGFXAttachment.BuffermallocStack(int capacity) Deprecated.static BGFXAttachment.BuffermallocStack(int capacity, MemoryStack stack) Deprecated.static BGFXAttachmentmallocStack(MemoryStack stack) Deprecated.shortmip()mip(short value) Sets the specified value to themipfield.static intnaccess(long struct) Unsafe version ofaccess().static voidnaccess(long struct, int value) Unsafe version ofaccess.static shortnhandle(long struct) Unsafe version ofhandle().static voidnhandle(long struct, short value) Unsafe version ofhandle.static shortnlayer(long struct) Unsafe version oflayer().static voidnlayer(long struct, short value) Unsafe version oflayer.static shortnmip(long struct) Unsafe version ofmip().static voidnmip(long struct, short value) Unsafe version ofmip.static shortnnumLayers(long struct) Unsafe version ofnumLayers().static voidnnumLayers(long struct, short value) Unsafe version ofnumLayers.static bytenresolve(long struct) Unsafe version ofresolve().static voidnresolve(long struct, byte value) Unsafe version ofresolve.shortnumLayers(short value) Sets the specified value to thenumLayersfield.byteresolve()resolve(byte value) Sets the specified value to theresolvefield.set(int access, short handle, short mip, short layer, short numLayers, byte resolve) Initializes this struct with the specified values.set(BGFXAttachment src) Copies the specified struct data to this struct.intsizeof()Returnssizeof(struct).Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toStringMethods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
ACCESS
public static final int ACCESSThe struct member offsets. -
HANDLE
public static final int HANDLEThe struct member offsets. -
MIP
public static final int MIPThe struct member offsets. -
LAYER
public static final int LAYERThe struct member offsets. -
NUMLAYERS
public static final int NUMLAYERSThe struct member offsets. -
RESOLVE
public static final int RESOLVEThe struct member offsets.
-
-
Constructor Details
-
BGFXAttachment
Creates aBGFXAttachmentinstance 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 Details
-
sizeof
public int sizeof()Description copied from class:StructReturnssizeof(struct).- Specified by:
sizeofin classStruct<BGFXAttachment>
-
access
public int access()- Returns:
- the value of the
accessfield.
-
handle
public short handle()- Returns:
- the value of the
handlefield.
-
mip
public short mip()- Returns:
- the value of the
mipfield.
-
layer
public short layer()- Returns:
- the value of the
layerfield.
-
numLayers
public short numLayers()- Returns:
- the value of the
numLayersfield.
-
resolve
public byte resolve()- Returns:
- the value of the
resolvefield.
-
access
Sets the specified value to theaccessfield. -
handle
Sets the specified value to thehandlefield. -
mip
Sets the specified value to themipfield. -
layer
Sets the specified value to thelayerfield. -
numLayers
Sets the specified value to thenumLayersfield. -
resolve
Sets the specified value to theresolvefield. -
set
public BGFXAttachment set(int access, short handle, short mip, short layer, short numLayers, byte resolve) Initializes this struct with the specified values. -
set
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
Returns a newBGFXAttachmentinstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newBGFXAttachmentinstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newBGFXAttachmentinstance allocated withBufferUtils. -
create
Returns a newBGFXAttachmentinstance for the specified memory address. -
createSafe
-
malloc
Returns a newBGFXAttachment.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newBGFXAttachment.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newBGFXAttachment.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aBGFXAttachment.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead. -
malloc
Returns a newBGFXAttachmentinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newBGFXAttachmentinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
Returns a newBGFXAttachment.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
Returns a newBGFXAttachment.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
naccess
public static int naccess(long struct) Unsafe version ofaccess(). -
nhandle
public static short nhandle(long struct) Unsafe version ofhandle(). -
nmip
public static short nmip(long struct) Unsafe version ofmip(). -
nlayer
public static short nlayer(long struct) Unsafe version oflayer(). -
nnumLayers
public static short nnumLayers(long struct) Unsafe version ofnumLayers(). -
nresolve
public static byte nresolve(long struct) Unsafe version ofresolve(). -
naccess
public static void naccess(long struct, int value) Unsafe version ofaccess. -
nhandle
public static void nhandle(long struct, short value) Unsafe version ofhandle. -
nmip
public static void nmip(long struct, short value) Unsafe version ofmip. -
nlayer
public static void nlayer(long struct, short value) Unsafe version oflayer. -
nnumLayers
public static void nnumLayers(long struct, short value) Unsafe version ofnumLayers. -
nresolve
public static void nresolve(long struct, byte value) Unsafe version ofresolve.
-