Package org.lwjgl.system.jawt
Class JAWTDrawingSurface
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.system.jawt.JAWTDrawingSurface
-
- All Implemented Interfaces:
- java.lang.AutoCloseable, NativeResource, Pointer
public class JAWTDrawingSurface extends Struct
Structure for containing the underlying drawing information of a component.All operations on a JAWT_DrawingSurface MUST be performed from the same thread as the call to
GetDrawingSurface
.Member documentation
env
– Cached reference to the Java environment of the calling thread.If Lock(), Unlock(), GetDrawingSurfaceInfo() or FreeDrawingSurfaceInfo() are called from a different thread, this data member should be set before calling those functions.
target
– Cached reference to the target object.
Layout
struct JAWT_DrawingSurface { JNIEnv * env; jobject target; void * Lock; void * GetDrawingSurfaceInfo; void * FreeDrawingSurfaceInfo; void * Unlock; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static class
JAWTDrawingSurface.Buffer
An array ofJAWTDrawingSurface
structs.-
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
-
Field Summary
Fields Modifier and Type Field and Description static int
SIZEOF
The struct size in bytes.-
Fields inherited from interface org.lwjgl.system.Pointer
POINTER_SHIFT, POINTER_SIZE
-
-
Constructor Summary
Constructors Constructor and Description JAWTDrawingSurface(java.nio.ByteBuffer container)
Creates aJAWTDrawingSurface
instance at the current position of the specifiedByteBuffer
container.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description static JAWTDrawingSurface
calloc()
Returns a newJAWTDrawingSurface
instance allocated withmemCalloc
.static JAWTDrawingSurface.Buffer
calloc(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated withmemCalloc
.static JAWTDrawingSurface
callocStack()
Returns a newJAWTDrawingSurface
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static JAWTDrawingSurface.Buffer
callocStack(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static JAWTDrawingSurface.Buffer
callocStack(int capacity, MemoryStack stack)
Returns a newJAWTDrawingSurface.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static JAWTDrawingSurface
callocStack(MemoryStack stack)
Returns a newJAWTDrawingSurface
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static JAWTDrawingSurface
create()
Returns a newJAWTDrawingSurface
instance allocated withBufferUtils
.static JAWTDrawingSurface.Buffer
create(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated withBufferUtils
.static JAWTDrawingSurface
create(long address)
Returns a newJAWTDrawingSurface
instance for the specified memory address ornull
if the address isNULL
.static JAWTDrawingSurface.Buffer
create(long address, int capacity)
Create aJAWTDrawingSurface.Buffer
instance at the specified memory.long
env()
Returns the value of theenv
field.long
FreeDrawingSurfaceInfo()
Returns the value of theFreeDrawingSurfaceInfo
field.long
GetDrawingSurfaceInfo()
Returns the value of theGetDrawingSurfaceInfo
field.long
Lock()
Returns the value of theLock
field.static JAWTDrawingSurface
malloc()
Returns a newJAWTDrawingSurface
instance allocated withmemAlloc
.static JAWTDrawingSurface.Buffer
malloc(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated withmemAlloc
.static JAWTDrawingSurface
mallocStack()
Returns a newJAWTDrawingSurface
instance allocated on the thread-localMemoryStack
.static JAWTDrawingSurface.Buffer
mallocStack(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated on the thread-localMemoryStack
.static JAWTDrawingSurface.Buffer
mallocStack(int capacity, MemoryStack stack)
Returns a newJAWTDrawingSurface.Buffer
instance allocated on the specifiedMemoryStack
.static JAWTDrawingSurface
mallocStack(MemoryStack stack)
Returns a newJAWTDrawingSurface
instance allocated on the specifiedMemoryStack
.int
sizeof()
Returns thesizeof(struct)
.long
target()
Returns the value of thetarget
field.long
Unlock()
Returns the value of theUnlock
field.-
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Methods inherited from interface org.lwjgl.system.NativeResource
close
-
-
-
-
Constructor Detail
-
JAWTDrawingSurface
public JAWTDrawingSurface(java.nio.ByteBuffer container)
Creates aJAWTDrawingSurface
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()
Description copied from class:Struct
Returns thesizeof(struct)
.
-
env
public long env()
Returns the value of theenv
field.
-
target
public long target()
Returns the value of thetarget
field.
-
Lock
public long Lock()
Returns the value of theLock
field.
-
GetDrawingSurfaceInfo
public long GetDrawingSurfaceInfo()
Returns the value of theGetDrawingSurfaceInfo
field.
-
FreeDrawingSurfaceInfo
public long FreeDrawingSurfaceInfo()
Returns the value of theFreeDrawingSurfaceInfo
field.
-
Unlock
public long Unlock()
Returns the value of theUnlock
field.
-
malloc
public static JAWTDrawingSurface malloc()
Returns a newJAWTDrawingSurface
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static JAWTDrawingSurface calloc()
Returns a newJAWTDrawingSurface
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static JAWTDrawingSurface create()
Returns a newJAWTDrawingSurface
instance allocated withBufferUtils
.
-
create
public static JAWTDrawingSurface create(long address)
Returns a newJAWTDrawingSurface
instance for the specified memory address ornull
if the address isNULL
.
-
malloc
public static JAWTDrawingSurface.Buffer malloc(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static JAWTDrawingSurface.Buffer calloc(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static JAWTDrawingSurface.Buffer create(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static JAWTDrawingSurface.Buffer create(long address, int capacity)
Create aJAWTDrawingSurface.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
mallocStack
public static JAWTDrawingSurface mallocStack()
Returns a newJAWTDrawingSurface
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static JAWTDrawingSurface callocStack()
Returns a newJAWTDrawingSurface
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static JAWTDrawingSurface mallocStack(MemoryStack stack)
Returns a newJAWTDrawingSurface
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static JAWTDrawingSurface callocStack(MemoryStack stack)
Returns a newJAWTDrawingSurface
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static JAWTDrawingSurface.Buffer mallocStack(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static JAWTDrawingSurface.Buffer callocStack(int capacity)
Returns a newJAWTDrawingSurface.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static JAWTDrawingSurface.Buffer mallocStack(int capacity, MemoryStack stack)
Returns a newJAWTDrawingSurface.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static JAWTDrawingSurface.Buffer callocStack(int capacity, MemoryStack stack)
Returns a newJAWTDrawingSurface.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
-