Package org.lwjgl.util.shaderc
Class GLSLangVersion
- All Implemented Interfaces:
AutoCloseable,NativeResource,Pointer
struct glslang_version_t {
int major;
int minor;
int patch;
char const * flavor;
}-
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 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 size in bytes.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionGLSLangVersion(ByteBuffer container) Creates aGLSLangVersioninstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionstatic GLSLangVersioncalloc()Returns a newGLSLangVersioninstance allocated withmemCalloc.static GLSLangVersion.Buffercalloc(int capacity) Returns a newGLSLangVersion.Bufferinstance allocated withmemCalloc.static GLSLangVersion.Buffercalloc(int capacity, MemoryStack stack) Returns a newGLSLangVersion.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static GLSLangVersioncalloc(MemoryStack stack) Returns a newGLSLangVersioninstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static GLSLangVersioncreate()Returns a newGLSLangVersioninstance allocated withBufferUtils.static GLSLangVersion.Buffercreate(int capacity) Returns a newGLSLangVersion.Bufferinstance allocated withBufferUtils.static GLSLangVersioncreate(long address) Returns a newGLSLangVersioninstance for the specified memory address.static GLSLangVersion.Buffercreate(long address, int capacity) Create aGLSLangVersion.Bufferinstance at the specified memory.static @Nullable GLSLangVersioncreateSafe(long address) static @Nullable GLSLangVersion.BuffercreateSafe(long address, int capacity) flavor()intmajor()static GLSLangVersionmalloc()Returns a newGLSLangVersioninstance allocated withmemAlloc.static GLSLangVersion.Buffermalloc(int capacity) Returns a newGLSLangVersion.Bufferinstance allocated withmemAlloc.static GLSLangVersion.Buffermalloc(int capacity, MemoryStack stack) Returns a newGLSLangVersion.Bufferinstance allocated on the specifiedMemoryStack.static GLSLangVersionmalloc(MemoryStack stack) Returns a newGLSLangVersioninstance allocated on the specifiedMemoryStack.intminor()static ByteBuffernflavor(long struct) Unsafe version offlavor().static StringnflavorString(long struct) Unsafe version offlavorString().static intnmajor(long struct) Unsafe version ofmajor().static intnminor(long struct) Unsafe version ofminor().static intnpatch(long struct) Unsafe version ofpatch().intpatch()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. -
MAJOR
public static final int MAJORThe struct member offsets. -
MINOR
public static final int MINORThe struct member offsets. -
PATCH
public static final int PATCHThe struct member offsets. -
FLAVOR
public static final int FLAVORThe struct member offsets.
-
-
Constructor Details
-
GLSLangVersion
Creates aGLSLangVersioninstance 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<GLSLangVersion>
-
major
public int major()- Returns:
- the value of the
majorfield.
-
minor
public int minor()- Returns:
- the value of the
minorfield.
-
patch
public int patch()- Returns:
- the value of the
patchfield.
-
flavor
- Returns:
- a
ByteBufferview of the null-terminated string pointed to by theflavorfield.
-
flavorString
- Returns:
- the null-terminated string pointed to by the
flavorfield.
-
malloc
Returns a newGLSLangVersioninstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newGLSLangVersioninstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newGLSLangVersioninstance allocated withBufferUtils. -
create
Returns a newGLSLangVersioninstance for the specified memory address. -
createSafe
-
malloc
Returns a newGLSLangVersion.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newGLSLangVersion.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newGLSLangVersion.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aGLSLangVersion.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
malloc
Returns a newGLSLangVersioninstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newGLSLangVersioninstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
Returns a newGLSLangVersion.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
Returns a newGLSLangVersion.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
nmajor
public static int nmajor(long struct) Unsafe version ofmajor(). -
nminor
public static int nminor(long struct) Unsafe version ofminor(). -
npatch
public static int npatch(long struct) Unsafe version ofpatch(). -
nflavor
Unsafe version offlavor(). -
nflavorString
Unsafe version offlavorString().
-