aboutsummaryrefslogtreecommitdiffstats
path: root/make/config/nativewindow
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2014-02-23 14:51:06 +0100
committerSven Gothel <[email protected]>2014-02-23 14:51:06 +0100
commit3352601e0860584509adf2b76f993d03893ded4b (patch)
tree974fccc8c0eb2f5ad9d4ffd741dfc35869ed67b5 /make/config/nativewindow
parentf51933f0ebe9ae030c26c066e59a728ce08b8559 (diff)
parentc67de337a8aaf52e36104c3f13e273aa19d21f1f (diff)
Merge branch 'master' into stash_glyphcache
Conflicts: make/scripts/tests.sh src/jogl/classes/com/jogamp/graph/curve/OutlineShape.java src/jogl/classes/com/jogamp/graph/curve/Region.java src/jogl/classes/com/jogamp/graph/curve/opengl/GLRegion.java src/jogl/classes/com/jogamp/graph/curve/opengl/RegionRenderer.java src/jogl/classes/com/jogamp/graph/curve/opengl/Renderer.java src/jogl/classes/com/jogamp/graph/curve/opengl/TextRenderer.java src/jogl/classes/com/jogamp/graph/font/Font.java src/jogl/classes/com/jogamp/opengl/math/VectorUtil.java src/jogl/classes/jogamp/graph/curve/text/GlyphShape.java src/jogl/classes/jogamp/graph/curve/text/GlyphString.java src/jogl/classes/jogamp/graph/font/typecast/TypecastFont.java src/jogl/classes/jogamp/graph/font/typecast/TypecastGlyph.java src/jogl/classes/jogamp/graph/font/typecast/TypecastRenderer.java
Diffstat (limited to 'make/config/nativewindow')
-rw-r--r--make/config/nativewindow/jawt-macosx.cfg2
-rw-r--r--make/config/nativewindow/x11-CustomJavaCode.java29
2 files changed, 27 insertions, 4 deletions
diff --git a/make/config/nativewindow/jawt-macosx.cfg b/make/config/nativewindow/jawt-macosx.cfg
index 20260f693..5f6bbfd21 100644
--- a/make/config/nativewindow/jawt-macosx.cfg
+++ b/make/config/nativewindow/jawt-macosx.cfg
@@ -8,7 +8,7 @@ Opaque long NSView *
Opaque long CALayer *
CustomCCode #include <inttypes.h>
-CustomCCode #include </usr/include/machine/types.h>
+CustomCCode #include <machine/types.h>
StructPackage JAWT_MacOSXDrawingSurfaceInfo jogamp.nativewindow.jawt.macosx
EmitStruct JAWT_MacOSXDrawingSurfaceInfo
diff --git a/make/config/nativewindow/x11-CustomJavaCode.java b/make/config/nativewindow/x11-CustomJavaCode.java
index 73439fcc7..d1e011184 100644
--- a/make/config/nativewindow/x11-CustomJavaCode.java
+++ b/make/config/nativewindow/x11-CustomJavaCode.java
@@ -1,4 +1,19 @@
+ /** Interface to C language function: <br> <code> XRenderPictFormat * XRenderFindVisualFormat(Display * dpy, const Visual * visual); </code> */
+ public static boolean XRenderFindVisualFormat(long dpy, long visual, XRenderPictFormat dest) {
+ if( dest == null ) {
+ throw new RuntimeException("dest is null");
+ }
+ final ByteBuffer destBuffer = dest.getBuffer();
+ if( !Buffers.isDirect(destBuffer) ) {
+ throw new RuntimeException("dest buffer is not direct");
+ }
+ return XRenderFindVisualFormat1(dpy, visual, destBuffer);
+ }
+ /** Entry point to C language function: <code> XVisualInfo * XGetVisualInfo(Display * , long, XVisualInfo * , int * ); </code> */
+ private static native boolean XRenderFindVisualFormat1(long dpy, long visual, ByteBuffer xRenderPictFormat);
+
+
/** Interface to C language function: <br> <code> XVisualInfo * XGetVisualInfo(Display * , long, XVisualInfo * , int * ); </code> */
public static XVisualInfo[] XGetVisualInfo(long arg0, long arg1, XVisualInfo arg2, int[] arg3, int arg3_offset)
{
@@ -24,16 +39,24 @@
/** Entry point to C language function: <code> XVisualInfo * XGetVisualInfo(Display * , long, XVisualInfo * , int * ); </code> */
private static native java.nio.ByteBuffer XGetVisualInfo1(long arg0, long arg1, java.nio.ByteBuffer arg2, Object arg3, int arg3_byte_offset);
- public static native long DefaultVisualID(long display, int screen);
+ public static native int GetVisualIDFromWindow(long display, long window);
+
+ public static native int DefaultVisualID(long display, int screen);
- public static native long CreateDummyWindow(long display, int screen_index, int visualID, int width, int height);
- public static native void DestroyDummyWindow(long display, long window);
+ public static native long CreateWindow(long parent, long display, int screen_index, int visualID, int width, int height, boolean input, boolean visible);
+ public static native void DestroyWindow(long display, long window);
+ public static native void SetWindowPosSize(long display, long window, int x, int y, int width, int height);
public static Point GetRelativeLocation(long display, int screen_index, long src_win, long dest_win, int src_x, int src_y) {
return (Point) GetRelativeLocation0(display, screen_index, src_win, dest_win, src_x, src_y);
}
private static native Object GetRelativeLocation0(long display, int screen_index, long src_win, long dest_win, int src_x, int src_y);
+ public static boolean QueryExtension(long display, String extensionName) {
+ return QueryExtension0(display, extensionName);
+ }
+ private static native boolean QueryExtension0(long display, String extensionName);
+
public static native int XCloseDisplay(long display);
public static native void XUnlockDisplay(long display);
public static native void XLockDisplay(long display);