Package org.lwjgl.glfw
Class GLFWGammaRamp
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.glfw.GLFWGammaRamp
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class GLFWGammaRamp extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
Describes the gamma ramp for a monitor.Member documentation
red
– an array of values describing the response of the red channelgreen
– an array of values describing the response of the green channelblue
– an array of values describing the response of the blue channelsize
– the number of elements in each array
Layout
struct GLFWgammaramp { unsigned short * red; unsigned short * green; unsigned short * blue; unsigned int size; }
- Since:
- version 3.0
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GLFWGammaRamp.Buffer
An array ofGLFWGammaRamp
structs.
-
Constructor Summary
Constructors Constructor Description GLFWGammaRamp(java.nio.ByteBuffer container)
Creates aGLFWGammaRamp
instance at the current position of the specifiedByteBuffer
container.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.nio.ShortBuffer
blue()
Returns aShortBuffer
view of the data pointed to by theblue
field.GLFWGammaRamp
blue(java.nio.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
callocStack()
Returns a newGLFWGammaRamp
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static GLFWGammaRamp.Buffer
callocStack(int capacity)
Returns a newGLFWGammaRamp.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static GLFWGammaRamp.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRamp.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static GLFWGammaRamp
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRamp
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.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)
java.nio.ShortBuffer
green()
Returns aShortBuffer
view of the data pointed to by thegreen
field.GLFWGammaRamp
green(java.nio.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
mallocStack()
Returns a newGLFWGammaRamp
instance allocated on the thread-localMemoryStack
.static GLFWGammaRamp.Buffer
mallocStack(int capacity)
Returns a newGLFWGammaRamp.Buffer
instance allocated on the thread-localMemoryStack
.static GLFWGammaRamp.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRamp.Buffer
instance allocated on the specifiedMemoryStack
.static GLFWGammaRamp
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRamp
instance allocated on the specifiedMemoryStack
.static java.nio.ShortBuffer
nblue(long struct)
Unsafe version ofblue
.static void
nblue(long struct, java.nio.ShortBuffer value)
Unsafe version ofblue
.static java.nio.ShortBuffer
ngreen(long struct)
Unsafe version ofgreen
.static void
ngreen(long struct, java.nio.ShortBuffer value)
Unsafe version ofgreen
.static java.nio.ShortBuffer
nred(long struct)
Unsafe version ofred
.static void
nred(long struct, java.nio.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
.java.nio.ShortBuffer
red()
Returns aShortBuffer
view of the data pointed to by thered
field.GLFWGammaRamp
red(java.nio.ShortBuffer value)
Sets the address of the specifiedShortBuffer
to thered
field.GLFWGammaRamp
set(java.nio.ShortBuffer red, java.nio.ShortBuffer green, java.nio.ShortBuffer blue, int size)
Initializes this struct with the specified values.GLFWGammaRamp
set(GLFWGammaRamp src)
Copies the specified struct data to this struct.int
size()
Returns the value of thesize
field.GLFWGammaRamp
size(int value)
Sets the specified value to thesize
field.int
sizeof()
static void
validate(long struct)
Validates pointer members that should not beNULL
.static void
validate(long array, int count)
Callsvalidate(long)
for each struct contained in the specified struct array.
-
-
-
Constructor Detail
-
GLFWGammaRamp
public GLFWGammaRamp(java.nio.ByteBuffer container)
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 Detail
-
sizeof
public int sizeof()
- Specified by:
sizeof
in classorg.lwjgl.system.Struct
-
red
public java.nio.ShortBuffer red()
Returns aShortBuffer
view of the data pointed to by thered
field.
-
green
public java.nio.ShortBuffer green()
Returns aShortBuffer
view of the data pointed to by thegreen
field.
-
blue
public java.nio.ShortBuffer blue()
Returns aShortBuffer
view of the data pointed to by theblue
field.
-
size
public int size()
Returns the value of thesize
field.
-
red
public GLFWGammaRamp red(java.nio.ShortBuffer value)
Sets the address of the specifiedShortBuffer
to thered
field.
-
green
public GLFWGammaRamp green(java.nio.ShortBuffer value)
Sets the address of the specifiedShortBuffer
to thegreen
field.
-
blue
public GLFWGammaRamp blue(java.nio.ShortBuffer value)
Sets the address of the specifiedShortBuffer
to theblue
field.
-
size
public GLFWGammaRamp size(int value)
Sets the specified value to thesize
field.
-
set
public GLFWGammaRamp set(java.nio.ShortBuffer red, java.nio.ShortBuffer green, java.nio.ShortBuffer blue, int size)
Initializes this struct with the specified values.
-
set
public GLFWGammaRamp set(GLFWGammaRamp src)
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
public static GLFWGammaRamp malloc()
Returns a newGLFWGammaRamp
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static GLFWGammaRamp calloc()
Returns a newGLFWGammaRamp
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static GLFWGammaRamp create()
Returns a newGLFWGammaRamp
instance allocated withBufferUtils
.
-
create
public static GLFWGammaRamp create(long address)
Returns a newGLFWGammaRamp
instance for the specified memory address.
-
createSafe
@Nullable public static GLFWGammaRamp createSafe(long address)
-
malloc
public static GLFWGammaRamp.Buffer malloc(int capacity)
Returns a newGLFWGammaRamp.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static GLFWGammaRamp.Buffer calloc(int capacity)
Returns a newGLFWGammaRamp.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static GLFWGammaRamp.Buffer create(int capacity)
Returns a newGLFWGammaRamp.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static GLFWGammaRamp.Buffer create(long address, int capacity)
Create aGLFWGammaRamp.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static GLFWGammaRamp.Buffer createSafe(long address, int capacity)
-
mallocStack
public static GLFWGammaRamp mallocStack()
Returns a newGLFWGammaRamp
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static GLFWGammaRamp callocStack()
Returns a newGLFWGammaRamp
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static GLFWGammaRamp mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRamp
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static GLFWGammaRamp callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRamp
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static GLFWGammaRamp.Buffer mallocStack(int capacity)
Returns a newGLFWGammaRamp.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static GLFWGammaRamp.Buffer callocStack(int capacity)
Returns a newGLFWGammaRamp.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static GLFWGammaRamp.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRamp.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static GLFWGammaRamp.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRamp.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
nred
public static java.nio.ShortBuffer nred(long struct)
Unsafe version ofred
.
-
ngreen
public static java.nio.ShortBuffer ngreen(long struct)
Unsafe version ofgreen
.
-
nblue
public static java.nio.ShortBuffer nblue(long struct)
Unsafe version ofblue
.
-
nsize
public static int nsize(long struct)
Unsafe version ofsize()
.
-
nred
public static void nred(long struct, java.nio.ShortBuffer value)
Unsafe version ofred
.
-
ngreen
public static void ngreen(long struct, java.nio.ShortBuffer value)
Unsafe version ofgreen
.
-
nblue
public static void nblue(long struct, java.nio.ShortBuffer value)
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
-
validate
public static void validate(long array, int count)
Callsvalidate(long)
for each struct contained in the specified struct array.- Parameters:
array
- the struct array to validatecount
- the number of structs inarray
-
-