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.NativeResourceDescribes 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; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static classGLFWGammaRamp.BufferAn array ofGLFWGammaRampstructs.
-
Field Summary
Fields Modifier and Type Field and Description static intSIZEOFThe struct size in bytes.
-
Constructor Summary
Constructors Constructor and Description GLFWGammaRamp(java.nio.ByteBuffer container)Creates aGLFWGammaRampinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.nio.ShortBufferblue()Returns aShortBufferview of the data pointed to by thebluefield.GLFWGammaRampblue(java.nio.ShortBuffer value)Sets the address of the specifiedShortBufferto thebluefield.static GLFWGammaRampcalloc()Returns a newGLFWGammaRampinstance allocated withmemCalloc.static GLFWGammaRamp.Buffercalloc(int capacity)Returns a newGLFWGammaRamp.Bufferinstance allocated withmemCalloc.static GLFWGammaRampcallocStack()Returns a newGLFWGammaRampinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static GLFWGammaRamp.BuffercallocStack(int capacity)Returns a newGLFWGammaRamp.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static GLFWGammaRamp.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newGLFWGammaRamp.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static GLFWGammaRampcallocStack(org.lwjgl.system.MemoryStack stack)Returns a newGLFWGammaRampinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static GLFWGammaRampcreate()Returns a newGLFWGammaRampinstance allocated withBufferUtils.static GLFWGammaRamp.Buffercreate(int capacity)Returns a newGLFWGammaRamp.Bufferinstance allocated withBufferUtils.static GLFWGammaRampcreate(long address)Returns a newGLFWGammaRampinstance for the specified memory address ornullif the address isNULL.static GLFWGammaRamp.Buffercreate(long address, int capacity)Create aGLFWGammaRamp.Bufferinstance at the specified memory.java.nio.ShortBuffergreen()Returns aShortBufferview of the data pointed to by thegreenfield.GLFWGammaRampgreen(java.nio.ShortBuffer value)Sets the address of the specifiedShortBufferto thegreenfield.static GLFWGammaRampmalloc()Returns a newGLFWGammaRampinstance allocated withmemAlloc.static GLFWGammaRamp.Buffermalloc(int capacity)Returns a newGLFWGammaRamp.Bufferinstance allocated withmemAlloc.static GLFWGammaRampmallocStack()Returns a newGLFWGammaRampinstance allocated on the thread-localMemoryStack.static GLFWGammaRamp.BuffermallocStack(int capacity)Returns a newGLFWGammaRamp.Bufferinstance allocated on the thread-localMemoryStack.static GLFWGammaRamp.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newGLFWGammaRamp.Bufferinstance allocated on the specifiedMemoryStack.static GLFWGammaRampmallocStack(org.lwjgl.system.MemoryStack stack)Returns a newGLFWGammaRampinstance allocated on the specifiedMemoryStack.GLFWGammaRampnset(long struct)Unsafe version ofset.java.nio.ShortBufferred()Returns aShortBufferview of the data pointed to by theredfield.GLFWGammaRampred(java.nio.ShortBuffer value)Sets the address of the specifiedShortBufferto theredfield.GLFWGammaRampset(GLFWGammaRamp src)Copies the specified struct data to this struct.GLFWGammaRampset(java.nio.ShortBuffer red, java.nio.ShortBuffer green, java.nio.ShortBuffer blue, int size)Initializes this struct with the specified values.intsize()Returns the value of thesizefield.GLFWGammaRampsize(int value)Sets the specified value to thesizefield.intsizeof()Returns thesizeof(struct).static voidvalidate(long struct)Validates pointer members that should not beNULL.static voidvalidate(long array, int count)CallsGLFWGammaRamp.validate(long)for each struct contained in the specified struct array.
-
-
-
Constructor Detail
-
GLFWGammaRamp
public GLFWGammaRamp(java.nio.ByteBuffer container)
Creates aGLFWGammaRampinstance 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()
Description copied from class:org.lwjgl.system.StructReturns thesizeof(struct).- Specified by:
sizeofin classorg.lwjgl.system.Struct
-
red
public java.nio.ShortBuffer red()
Returns aShortBufferview of the data pointed to by theredfield.
-
green
public java.nio.ShortBuffer green()
Returns aShortBufferview of the data pointed to by thegreenfield.
-
blue
public java.nio.ShortBuffer blue()
Returns aShortBufferview of the data pointed to by thebluefield.
-
size
public int size()
Returns the value of thesizefield.
-
red
public GLFWGammaRamp red(java.nio.ShortBuffer value)
Sets the address of the specifiedShortBufferto theredfield.
-
green
public GLFWGammaRamp green(java.nio.ShortBuffer value)
Sets the address of the specifiedShortBufferto thegreenfield.
-
blue
public GLFWGammaRamp blue(java.nio.ShortBuffer value)
Sets the address of the specifiedShortBufferto thebluefield.
-
size
public GLFWGammaRamp size(int value)
Sets the specified value to thesizefield.
-
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.
-
nset
public GLFWGammaRamp nset(long struct)
Unsafe version ofset.
-
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 newGLFWGammaRampinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static GLFWGammaRamp calloc()
Returns a newGLFWGammaRampinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static GLFWGammaRamp create()
Returns a newGLFWGammaRampinstance allocated withBufferUtils.
-
create
public static GLFWGammaRamp create(long address)
Returns a newGLFWGammaRampinstance for the specified memory address ornullif the address isNULL.
-
malloc
public static GLFWGammaRamp.Buffer malloc(int capacity)
Returns a newGLFWGammaRamp.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static GLFWGammaRamp.Buffer calloc(int capacity)
Returns a newGLFWGammaRamp.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static GLFWGammaRamp.Buffer create(int capacity)
Returns a newGLFWGammaRamp.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static GLFWGammaRamp.Buffer create(long address, int capacity)
Create aGLFWGammaRamp.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
mallocStack
public static GLFWGammaRamp mallocStack()
Returns a newGLFWGammaRampinstance allocated on the thread-localMemoryStack.
-
callocStack
public static GLFWGammaRamp callocStack()
Returns a newGLFWGammaRampinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static GLFWGammaRamp mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRampinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static GLFWGammaRamp callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newGLFWGammaRampinstance allocated on the specifiedMemoryStackand 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.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static GLFWGammaRamp.Buffer callocStack(int capacity)
Returns a newGLFWGammaRamp.Bufferinstance allocated on the thread-localMemoryStackand 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.Bufferinstance 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.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
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)CallsGLFWGammaRamp.validate(long)for each struct contained in the specified struct array.- Parameters:
array- the struct array to validatecount- the number of structs inarray
-
-