aboutsummaryrefslogtreecommitdiffstats
path: root/make/config/jogl/glx-CustomJavaCode.java
blob: ed126a5c9582461bf1b2ed5dcb5b09afcb953adc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64

  /** Interface to C language function: <br> - Alias for: <br> <code> XVisualInfo *  glXGetVisualFromFBConfigSGIX, glXGetVisualFromFBConfig(Display *  dpy, GLXFBConfig config); </code>    */
  public static XVisualInfo glXGetVisualFromFBConfig(long dpy, long config)
  {
    final long __addr_ = glxProcAddressTable._addressof_glXGetVisualFromFBConfig;
    if (__addr_ == 0) {
        throw new GLException("Method \"glXGetVisualFromFBConfig\" not available");
    }
    java.nio.ByteBuffer _res;
    _res = dispatch_glXGetVisualFromFBConfig(dpy, config, __addr_);
    if (_res == null) return null;
    return XVisualInfo.create(_res);
  }

  /** Entry point to C language function: - Alias for: <br> <code> XVisualInfo *  glXGetVisualFromFBConfigSGIX, glXGetVisualFromFBConfig(Display *  dpy, GLXFBConfig config); </code>    */
  private static native java.nio.ByteBuffer dispatch_glXGetVisualFromFBConfig(long dpy, long config, long procAddr);


  /** Entry point to C language function: <code> GLXFBConfig *  glXChooseFBConfig(Display *  dpy, int screen, const int *  attribList, int *  nitems); </code> <br>Part of CORE FUNC
      @param attribList a direct only {@link java.nio.IntBuffer}
      @param nitems a direct only {@link java.nio.IntBuffer}   */
  public static PointerBuffer glXChooseFBConfig(long dpy, int screen, IntBuffer attribList, IntBuffer nitems)  {

    if (!Buffers.isDirect(attribList))
      throw new GLException("Argument \"attribList\" is not a direct buffer");
    if (!Buffers.isDirect(nitems))
      throw new GLException("Argument \"nitems\" is not a direct buffer");
    final long __addr_ = glxProcAddressTable._addressof_glXChooseFBConfig;
    if (__addr_ == 0) {
      throw new GLException("Method \"glXChooseFBConfig\" not available");
    }
    final ByteBuffer _res;
    _res = dispatch_glXChooseFBConfig(dpy, screen, attribList, Buffers.getDirectBufferByteOffset(attribList), nitems, Buffers.getDirectBufferByteOffset(nitems), __addr_);
    if (_res == null) return null;
    Buffers.nativeOrder(_res);
    return PointerBuffer.wrap(_res);
  }

  /** Entry point to C language function: <code> GLXFBConfig *  glXChooseFBConfig(Display *  dpy, int screen, const int *  attribList, int *  nitems); </code> <br>Part of CORE FUNC
      @param attribList a direct only {@link java.nio.IntBuffer}
      @param nitems a direct only {@link java.nio.IntBuffer}   */
  private static native ByteBuffer dispatch_glXChooseFBConfig(long dpy, int screen, Object attribList, int attribList_byte_offset, Object nitems, int nitems_byte_offset, long procAddress);


  /** Entry point to C language function: <code> XVisualInfo *  glXChooseVisual(Display *  dpy, int screen, int *  attribList); </code> <br>Part of <code>GLX_VERSION_1_X</code>
      @param attribList a direct only {@link java.nio.IntBuffer}   */
  public static XVisualInfo glXChooseVisual(long dpy, int screen, IntBuffer attribList)  {

    if (!Buffers.isDirect(attribList))
      throw new GLException("Argument \"attribList\" is not a direct buffer");
    final long __addr_ = glxProcAddressTable._addressof_glXChooseVisual;
    if (__addr_ == 0) {
      throw new GLException("Method \"glXChooseVisual\" not available");
    }
    final ByteBuffer _res;
    _res = dispatch_glXChooseVisual(dpy, screen, attribList, Buffers.getDirectBufferByteOffset(attribList), __addr_);
    if (_res == null) return null;
    return XVisualInfo.create(Buffers.nativeOrder(_res));
  }

  /** Entry point to C language function: <code> XVisualInfo *  glXChooseVisual(Display *  dpy, int screen, int *  attribList); </code> <br>Part of <code>GLX_VERSION_1_X</code>
      @param attribList a direct only {@link java.nio.IntBuffer}   */
  private static native ByteBuffer dispatch_glXChooseVisual(long dpy, int screen, Object attribList, int attribList_byte_offset, long procAddress);