Package org.lwjgl.glfw
Class GLFWGammaRamp
- All Implemented Interfaces:
AutoCloseable
,NativeResource
,Pointer
Describes the gamma ramp for a monitor.
Layout
struct GLFWgammaramp {
unsigned short * red()
;
unsigned short * green()
;
unsigned short * blue()
;
unsigned int size()
;
}
- Since:
- version 3.0
-
Nested Class Summary
Nested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidation
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
The struct alignment in bytes.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct size in bytes.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorDescriptionGLFWGammaRamp
(ByteBuffer container) Creates aGLFWGammaRamp
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescriptionblue()
an array of values describing the response of the blue channelblue
(ShortBuffer value) Sets the address of the specifiedShortBuffer
to theblue()
field.static GLFWGammaRamp
calloc()
Returns a newGLFWGammaRamp
instance allocated withmemCalloc
.static GLFWGammaRamp.Buffer
calloc
(int capacity) Returns a newGLFWGammaRamp.Buffer
instance allocated withmemCalloc
.static GLFWGammaRamp.Buffer
calloc
(int capacity, MemoryStack stack) Returns a newGLFWGammaRamp.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static GLFWGammaRamp
calloc
(MemoryStack stack) Returns a newGLFWGammaRamp
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static GLFWGammaRamp
Deprecated.static GLFWGammaRamp.Buffer
callocStack
(int capacity) Deprecated.static GLFWGammaRamp.Buffer
callocStack
(int capacity, MemoryStack stack) Deprecated.static GLFWGammaRamp
callocStack
(MemoryStack stack) Deprecated.static GLFWGammaRamp
create()
Returns a newGLFWGammaRamp
instance allocated withBufferUtils
.static GLFWGammaRamp.Buffer
create
(int capacity) Returns a newGLFWGammaRamp.Buffer
instance allocated withBufferUtils
.static GLFWGammaRamp
create
(long address) Returns a newGLFWGammaRamp
instance for the specified memory address.static GLFWGammaRamp.Buffer
create
(long address, int capacity) Create aGLFWGammaRamp.Buffer
instance at the specified memory.static GLFWGammaRamp
createSafe
(long address) static GLFWGammaRamp.Buffer
createSafe
(long address, int capacity) green()
an array of values describing the response of the green channelgreen
(ShortBuffer value) Sets the address of the specifiedShortBuffer
to thegreen()
field.static GLFWGammaRamp
malloc()
Returns a newGLFWGammaRamp
instance allocated withmemAlloc
.static GLFWGammaRamp.Buffer
malloc
(int capacity) Returns a newGLFWGammaRamp.Buffer
instance allocated withmemAlloc
.static GLFWGammaRamp.Buffer
malloc
(int capacity, MemoryStack stack) Returns a newGLFWGammaRamp.Buffer
instance allocated on the specifiedMemoryStack
.static GLFWGammaRamp
malloc
(MemoryStack stack) Returns a newGLFWGammaRamp
instance allocated on the specifiedMemoryStack
.static GLFWGammaRamp
Deprecated.static GLFWGammaRamp.Buffer
mallocStack
(int capacity) Deprecated.static GLFWGammaRamp.Buffer
mallocStack
(int capacity, MemoryStack stack) Deprecated.static GLFWGammaRamp
mallocStack
(MemoryStack stack) Deprecated.static ShortBuffer
nblue
(long struct) Unsafe version ofblue
.static void
nblue
(long struct, ShortBuffer value) Unsafe version ofblue
.static ShortBuffer
ngreen
(long struct) Unsafe version ofgreen
.static void
ngreen
(long struct, ShortBuffer value) Unsafe version ofgreen
.static ShortBuffer
nred
(long struct) Unsafe version ofred
.static void
nred
(long struct, ShortBuffer value) Unsafe version ofred
.static int
nsize
(long struct) Unsafe version ofsize()
.static void
nsize
(long struct, int value) Sets the specified value to thesize
field of the specifiedstruct
.red()
an array of values describing the response of the red channelred
(ShortBuffer value) Sets the address of the specifiedShortBuffer
to thered()
field.set
(ShortBuffer red, ShortBuffer green, ShortBuffer blue, int size) Initializes this struct with the specified values.set
(GLFWGammaRamp src) Copies the specified struct data to this struct.int
size()
the number of elements in each arraysize
(int value) Sets the specified value to thesize()
field.int
sizeof()
Returnssizeof(struct)
.static void
validate
(long struct) Validates pointer members that should not beNULL
.Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
Methods 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. -
RED
public static final int REDThe struct member offsets. -
GREEN
public static final int GREENThe struct member offsets. -
BLUE
public static final int BLUEThe struct member offsets. -
SIZE
public static final int SIZEThe struct member offsets.
-
-
Constructor Details
-
GLFWGammaRamp
Creates aGLFWGammaRamp
instance at the current position of the specifiedByteBuffer
container. 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:Struct
Returnssizeof(struct)
.- Specified by:
sizeof
in classStruct<GLFWGammaRamp>
-
red
an array of values describing the response of the red channel -
green
an array of values describing the response of the green channel -
blue
an array of values describing the response of the blue channel -
size
public int size()the number of elements in each array -
red
Sets the address of the specifiedShortBuffer
to thered()
field. -
green
Sets the address of the specifiedShortBuffer
to thegreen()
field. -
blue
Sets the address of the specifiedShortBuffer
to theblue()
field. -
size
Sets the specified value to thesize()
field. -
set
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 newGLFWGammaRamp
instance allocated withmemAlloc
. The instance must be explicitly freed. -
calloc
Returns a newGLFWGammaRamp
instance allocated withmemCalloc
. The instance must be explicitly freed. -
create
Returns a newGLFWGammaRamp
instance allocated withBufferUtils
. -
create
Returns a newGLFWGammaRamp
instance for the specified memory address. -
createSafe
-
malloc
Returns a newGLFWGammaRamp.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
Returns a newGLFWGammaRamp.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
Returns a newGLFWGammaRamp.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
Create aGLFWGammaRamp.Buffer
instance 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 newGLFWGammaRamp
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
Returns a newGLFWGammaRamp
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
malloc
Returns a newGLFWGammaRamp.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
calloc
Returns a newGLFWGammaRamp.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
nred
Unsafe version ofred
. -
ngreen
Unsafe version ofgreen
. -
nblue
Unsafe version ofblue
. -
nsize
public static int nsize(long struct) Unsafe version ofsize()
. -
nred
Unsafe version ofred
. -
ngreen
Unsafe version ofgreen
. -
nblue
Unsafe version ofblue
. -
nsize
public static void nsize(long struct, int value) Sets the specified value to thesize
field of the specifiedstruct
. -
validate
public static void validate(long struct) Validates pointer members that should not beNULL
.- Parameters:
struct
- the struct to validate
-