jogamp.nativewindow.jawt.JAWT_DrawingSurface Maven / Gradle / Ivy
/* !---- DO NOT EDIT: This file autogenerated by com/jogamp/gluegen/JavaEmitter.java on Sat Oct 19 05:21:24 CEST 2013 ----! */
package jogamp.nativewindow.jawt;
import java.nio.*;
import com.jogamp.gluegen.runtime.*;
import com.jogamp.common.os.*;
import com.jogamp.common.nio.*;
import jogamp.common.os.MachineDescriptionRuntime;
import java.security.*;
import jogamp.nativewindow.jawt.*;
import com.jogamp.common.os.Platform;
import com.jogamp.common.util.VersionNumber;
public class JAWT_DrawingSurface {
StructAccessor accessor;
private static final int mdIdx = MachineDescriptionRuntime.getStatic().ordinal();
private static final int[] JAWT_DrawingSurface_size = new int[] { 24 /* ARMle_EABI */, 24 /* X86_32_UNIX */, 48 /* X86_64_UNIX */, 24 /* X86_32_MACOS */, 24 /* X86_32_WINDOWS */, 48 /* X86_64_WINDOWS */, 24 /* SPARC_32_SUNOS */ };
public static int size() {
return JAWT_DrawingSurface_size[mdIdx];
}
public static JAWT_DrawingSurface create() {
return create(Buffers.newDirectByteBuffer(size()));
}
public static JAWT_DrawingSurface create(java.nio.ByteBuffer buf) {
return new JAWT_DrawingSurface(buf);
}
JAWT_DrawingSurface(java.nio.ByteBuffer buf) {
accessor = new StructAccessor(buf);
}
public java.nio.ByteBuffer getBuffer() {
return accessor.getBuffer();
}
/** Interface to C language function:
jint Lock(JAWT_DrawingSurface * ds);
*/
public int Lock() {
return Lock0(getBuffer());
}
/** Entry point to C language function: jint Lock(JAWT_DrawingSurface * ds);
*/
private native int Lock0(ByteBuffer jthis0);
/** Interface to C language function:
JAWT_DrawingSurfaceInfo * GetDrawingSurfaceInfo(JAWT_DrawingSurface * ds);
*/
public JAWT_DrawingSurfaceInfo GetDrawingSurfaceInfo() {
final ByteBuffer _res;
_res = GetDrawingSurfaceInfo0(getBuffer());
if (_res == null) return null;
return JAWT_DrawingSurfaceInfo.create(Buffers.nativeOrder(_res));
}
/** Entry point to C language function: JAWT_DrawingSurfaceInfo * GetDrawingSurfaceInfo(JAWT_DrawingSurface * ds);
*/
private native ByteBuffer GetDrawingSurfaceInfo0(ByteBuffer jthis0);
/** Interface to C language function:
void FreeDrawingSurfaceInfo(JAWT_DrawingSurfaceInfo * dsi);
*/
public void FreeDrawingSurfaceInfo(JAWT_DrawingSurfaceInfo dsi) {
FreeDrawingSurfaceInfo0(getBuffer(), ((dsi == null) ? null : dsi.getBuffer()));
}
/** Entry point to C language function: void FreeDrawingSurfaceInfo(JAWT_DrawingSurfaceInfo * dsi);
*/
private native void FreeDrawingSurfaceInfo0(ByteBuffer jthis0, ByteBuffer dsi);
/** Interface to C language function:
void Unlock(JAWT_DrawingSurface * ds);
*/
public void Unlock() {
Unlock0(getBuffer());
}
/** Entry point to C language function: void Unlock(JAWT_DrawingSurface * ds);
*/
private native void Unlock0(ByteBuffer jthis0);
}