Package org.lwjgl.system.linux
Class Visual
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.system.linux.Visual
-
- All Implemented Interfaces:
- java.lang.AutoCloseable, NativeResource, Pointer
public class Visual extends Struct
Visual structure; contains information about colormapping possible.Layout
struct Visual { void * ext_data; VisualID visualid; int class; unsigned long red_mask; unsigned long green_mask; unsigned long blue_mask; int bits_per_rgb; int map_entries; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static classVisual.BufferAn array ofVisualstructs.-
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
-
Field Summary
Fields Modifier and Type Field and Description static intSIZEOFThe struct size in bytes.-
Fields inherited from interface org.lwjgl.system.Pointer
POINTER_SHIFT, POINTER_SIZE
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description intbits_per_rgb()Returns the value of thebits_per_rgbfield.Visualbits_per_rgb(int value)Sets the specified value to thebits_per_rgbfield.longblue_mask()Returns the value of theblue_maskfield.Visualblue_mask(long value)Sets the specified value to theblue_maskfield.static Visualcalloc()static Visual.Buffercalloc(int capacity)Returns a newVisual.Bufferinstance allocated withmemCalloc.static VisualcallocStack()Returns a newVisualinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static Visual.BuffercallocStack(int capacity)Returns a newVisual.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static Visual.BuffercallocStack(int capacity, MemoryStack stack)Returns a newVisual.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VisualcallocStack(MemoryStack stack)Returns a newVisualinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.intclass$()Returns the value of theclass$field.Visualclass$(int value)Sets the specified value to theclassfield.static Visualcreate()Returns a newVisualinstance allocated withBufferUtils.static Visual.Buffercreate(int capacity)Returns a newVisual.Bufferinstance allocated withBufferUtils.static Visualcreate(long address)static Visual.Buffercreate(long address, int capacity)Create aVisual.Bufferinstance at the specified memory.longext_data()Returns the value of theext_datafield.Visualext_data(long value)Sets the specified value to theext_datafield.longgreen_mask()Returns the value of thegreen_maskfield.Visualgreen_mask(long value)Sets the specified value to thegreen_maskfield.static Visualmalloc()static Visual.Buffermalloc(int capacity)Returns a newVisual.Bufferinstance allocated withmemAlloc.static VisualmallocStack()Returns a newVisualinstance allocated on the thread-localMemoryStack.static Visual.BuffermallocStack(int capacity)Returns a newVisual.Bufferinstance allocated on the thread-localMemoryStack.static Visual.BuffermallocStack(int capacity, MemoryStack stack)Returns a newVisual.Bufferinstance allocated on the specifiedMemoryStack.static VisualmallocStack(MemoryStack stack)Returns a newVisualinstance allocated on the specifiedMemoryStack.intmap_entries()Returns the value of themap_entriesfield.Visualmap_entries(int value)Sets the specified value to themap_entriesfield.Visualnset(long struct)Unsafe version ofset.longred_mask()Returns the value of thered_maskfield.Visualred_mask(long value)Sets the specified value to thered_maskfield.Visualset(long ext_data, long visualid, int class$, long red_mask, long green_mask, long blue_mask, int bits_per_rgb, int map_entries)Initializes this struct with the specified values.Visualset(Visual src)Copies the specified struct data to this struct.intsizeof()Returns thesizeof(struct).longvisualid()Returns the value of thevisualidfield.Visualvisualid(long value)Sets the specified value to thevisualidfield.-
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Methods inherited from interface org.lwjgl.system.NativeResource
close
-
-
-
-
Constructor Detail
-
Visual
public Visual(java.nio.ByteBuffer container)
Creates aVisualinstance 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:StructReturns thesizeof(struct).
-
ext_data
public long ext_data()
Returns the value of theext_datafield.
-
visualid
public long visualid()
Returns the value of thevisualidfield.
-
class$
public int class$()
Returns the value of theclass$field.
-
red_mask
public long red_mask()
Returns the value of thered_maskfield.
-
green_mask
public long green_mask()
Returns the value of thegreen_maskfield.
-
blue_mask
public long blue_mask()
Returns the value of theblue_maskfield.
-
bits_per_rgb
public int bits_per_rgb()
Returns the value of thebits_per_rgbfield.
-
map_entries
public int map_entries()
Returns the value of themap_entriesfield.
-
ext_data
public Visual ext_data(long value)
Sets the specified value to theext_datafield.
-
visualid
public Visual visualid(long value)
Sets the specified value to thevisualidfield.
-
class$
public Visual class$(int value)
Sets the specified value to theclassfield.
-
red_mask
public Visual red_mask(long value)
Sets the specified value to thered_maskfield.
-
green_mask
public Visual green_mask(long value)
Sets the specified value to thegreen_maskfield.
-
blue_mask
public Visual blue_mask(long value)
Sets the specified value to theblue_maskfield.
-
bits_per_rgb
public Visual bits_per_rgb(int value)
Sets the specified value to thebits_per_rgbfield.
-
map_entries
public Visual map_entries(int value)
Sets the specified value to themap_entriesfield.
-
set
public Visual set(long ext_data, long visualid, int class$, long red_mask, long green_mask, long blue_mask, int bits_per_rgb, int map_entries)
Initializes this struct with the specified values.
-
set
public Visual set(Visual src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static Visual malloc()
-
calloc
public static Visual calloc()
-
create
public static Visual create()
Returns a newVisualinstance allocated withBufferUtils.
-
create
public static Visual create(long address)
-
malloc
public static Visual.Buffer malloc(int capacity)
Returns a newVisual.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static Visual.Buffer calloc(int capacity)
Returns a newVisual.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static Visual.Buffer create(int capacity)
Returns a newVisual.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static Visual.Buffer create(long address, int capacity)
Create aVisual.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
mallocStack
public static Visual mallocStack()
Returns a newVisualinstance allocated on the thread-localMemoryStack.
-
callocStack
public static Visual callocStack()
Returns a newVisualinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static Visual mallocStack(MemoryStack stack)
Returns a newVisualinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static Visual callocStack(MemoryStack stack)
Returns a newVisualinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
mallocStack
public static Visual.Buffer mallocStack(int capacity)
Returns a newVisual.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static Visual.Buffer callocStack(int capacity)
Returns a newVisual.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static Visual.Buffer mallocStack(int capacity, MemoryStack stack)
Returns a newVisual.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
callocStack
public static Visual.Buffer callocStack(int capacity, MemoryStack stack)
Returns a newVisual.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
-