Package org.lwjgl.bgfx
Class BGFXTextureInfo
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.bgfx.BGFXTextureInfo
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class BGFXTextureInfo extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceTexture info.Layout
struct bgfx_texture_info_t { bgfx_texture_format_tformat(); uint32_tstorageSize(); uint16_twidth(); uint16_theight(); uint16_tdepth(); uint16_tnumLayers(); uint8_tnumMips(); uint8_tbitsPerPixel(); boolcubeMap(); }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classBGFXTextureInfo.BufferAn array ofBGFXTextureInfostructs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intBITSPERPIXEL
CUBEMAP
DEPTH
FORMAT
HEIGHT
NUMLAYERS
NUMMIPSThe struct member offsets.static intSIZEOFThe struct size in bytes.static intSTORAGESIZE
WIDTHThe struct member offsets.
-
Constructor Summary
Constructors Constructor Description BGFXTextureInfo(java.nio.ByteBuffer container)Creates aBGFXTextureInfoinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description bytebitsPerPixel()format bits per pixelstatic BGFXTextureInfocalloc()Returns a newBGFXTextureInfoinstance allocated withmemCalloc.static BGFXTextureInfo.Buffercalloc(int capacity)Returns a newBGFXTextureInfo.Bufferinstance allocated withmemCalloc.static BGFXTextureInfo.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newBGFXTextureInfo.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static BGFXTextureInfocalloc(org.lwjgl.system.MemoryStack stack)Returns a newBGFXTextureInfoinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static BGFXTextureInfocallocStack()Deprecated.static BGFXTextureInfo.BuffercallocStack(int capacity)Deprecated.static BGFXTextureInfo.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static BGFXTextureInfocallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static BGFXTextureInfocreate()Returns a newBGFXTextureInfoinstance allocated withBufferUtils.static BGFXTextureInfo.Buffercreate(int capacity)Returns a newBGFXTextureInfo.Bufferinstance allocated withBufferUtils.static BGFXTextureInfocreate(long address)Returns a newBGFXTextureInfoinstance for the specified memory address.static BGFXTextureInfo.Buffercreate(long address, int capacity)Create aBGFXTextureInfo.Bufferinstance at the specified memory.static BGFXTextureInfocreateSafe(long address)static BGFXTextureInfo.BuffercreateSafe(long address, int capacity)booleancubeMap()texture is cubemapshortdepth()texture depthintformat()texture format.shortheight()texture heightstatic BGFXTextureInfomalloc()Returns a newBGFXTextureInfoinstance allocated withmemAlloc.static BGFXTextureInfo.Buffermalloc(int capacity)Returns a newBGFXTextureInfo.Bufferinstance allocated withmemAlloc.static BGFXTextureInfo.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newBGFXTextureInfo.Bufferinstance allocated on the specifiedMemoryStack.static BGFXTextureInfomalloc(org.lwjgl.system.MemoryStack stack)Returns a newBGFXTextureInfoinstance allocated on the specifiedMemoryStack.static BGFXTextureInfomallocStack()Deprecated.static BGFXTextureInfo.BuffermallocStack(int capacity)Deprecated.static BGFXTextureInfo.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static BGFXTextureInfomallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static bytenbitsPerPixel(long struct)Unsafe version ofbitsPerPixel().static booleanncubeMap(long struct)Unsafe version ofcubeMap().static shortndepth(long struct)Unsafe version ofdepth().static intnformat(long struct)Unsafe version offormat().static shortnheight(long struct)Unsafe version ofheight().static shortnnumLayers(long struct)Unsafe version ofnumLayers().static bytennumMips(long struct)Unsafe version ofnumMips().static intnstorageSize(long struct)Unsafe version ofstorageSize().shortnumLayers()number of layers in texture arraybytenumMips()number of MIP mapsstatic shortnwidth(long struct)Unsafe version ofwidth().intsizeof()intstorageSize()total amount of bytes required to store textureshortwidth()texture width
-
-
-
Constructor Detail
-
BGFXTextureInfo
public BGFXTextureInfo(java.nio.ByteBuffer container)
Creates aBGFXTextureInfoinstance 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
-
format
public int format()
texture format. One of:
-
storageSize
public int storageSize()
total amount of bytes required to store texture
-
width
public short width()
texture width
-
height
public short height()
texture height
-
depth
public short depth()
texture depth
-
numLayers
public short numLayers()
number of layers in texture array
-
numMips
public byte numMips()
number of MIP maps
-
bitsPerPixel
public byte bitsPerPixel()
format bits per pixel
-
cubeMap
public boolean cubeMap()
texture is cubemap
-
malloc
public static BGFXTextureInfo malloc()
Returns a newBGFXTextureInfoinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static BGFXTextureInfo calloc()
Returns a newBGFXTextureInfoinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static BGFXTextureInfo create()
Returns a newBGFXTextureInfoinstance allocated withBufferUtils.
-
create
public static BGFXTextureInfo create(long address)
Returns a newBGFXTextureInfoinstance for the specified memory address.
-
createSafe
@Nullable public static BGFXTextureInfo createSafe(long address)
-
malloc
public static BGFXTextureInfo.Buffer malloc(int capacity)
Returns a newBGFXTextureInfo.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static BGFXTextureInfo.Buffer calloc(int capacity)
Returns a newBGFXTextureInfo.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static BGFXTextureInfo.Buffer create(int capacity)
Returns a newBGFXTextureInfo.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static BGFXTextureInfo.Buffer create(long address, int capacity)
Create aBGFXTextureInfo.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static BGFXTextureInfo.Buffer createSafe(long address, int capacity)
-
mallocStack
@Deprecated public static BGFXTextureInfo mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static BGFXTextureInfo callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static BGFXTextureInfo mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static BGFXTextureInfo callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static BGFXTextureInfo.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static BGFXTextureInfo.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
mallocStack
@Deprecated public static BGFXTextureInfo.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static BGFXTextureInfo.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
malloc
public static BGFXTextureInfo malloc(org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTextureInfoinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static BGFXTextureInfo calloc(org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTextureInfoinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static BGFXTextureInfo.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTextureInfo.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static BGFXTextureInfo.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTextureInfo.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nformat
public static int nformat(long struct)
Unsafe version offormat().
-
nstorageSize
public static int nstorageSize(long struct)
Unsafe version ofstorageSize().
-
nwidth
public static short nwidth(long struct)
Unsafe version ofwidth().
-
nheight
public static short nheight(long struct)
Unsafe version ofheight().
-
ndepth
public static short ndepth(long struct)
Unsafe version ofdepth().
-
nnumLayers
public static short nnumLayers(long struct)
Unsafe version ofnumLayers().
-
nnumMips
public static byte nnumMips(long struct)
Unsafe version ofnumMips().
-
nbitsPerPixel
public static byte nbitsPerPixel(long struct)
Unsafe version ofbitsPerPixel().
-
ncubeMap
public static boolean ncubeMap(long struct)
Unsafe version ofcubeMap().
-
-