
jogamp.nativewindow.x11.XVisualInfo Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jogl-all-noawt Show documentation
Show all versions of jogl-all-noawt Show documentation
Java™ Binding for the OpenGL® API (Without AWT)
The newest version!
/* !---- DO NOT EDIT: This file autogenerated by com/jogamp/gluegen/JavaEmitter.java on Sat Oct 10 03:10:18 CEST 2015 ----! */
package jogamp.nativewindow.x11;
import java.nio.*;
import com.jogamp.gluegen.runtime.*;
import com.jogamp.common.os.*;
import com.jogamp.common.nio.*;
import jogamp.common.os.MachineDataInfoRuntime;
import java.nio.*;
import java.util.*;
import com.jogamp.nativewindow.util.Point;
import com.jogamp.common.util.Bitfield;
public class XVisualInfo {
StructAccessor accessor;
private static final int mdIdx = MachineDataInfoRuntime.getStatic().ordinal();
private final MachineDataInfo md;
private static final int[] XVisualInfo_size = new int[] { 40 /* ARM_MIPS_32 */, 40 /* X86_32_UNIX */, 40 /* X86_32_MACOS */, 40 /* PPC_32_UNIX */, 40 /* SPARC_32_SUNOS */, 40 /* X86_32_WINDOWS */, 64 /* LP64_UNIX */, 48 /* X86_64_WINDOWS */ };
private static final int[] visual_offset = new int[] { 0 /* ARM_MIPS_32 */, 0 /* X86_32_UNIX */, 0 /* X86_32_MACOS */, 0 /* PPC_32_UNIX */, 0 /* SPARC_32_SUNOS */, 0 /* X86_32_WINDOWS */, 0 /* LP64_UNIX */, 0 /* X86_64_WINDOWS */ };
//private static final int[] visual_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 8 /* LP64_UNIX */, 8 /* X86_64_WINDOWS */ };
private static final int[] visualid_offset = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 8 /* LP64_UNIX */, 8 /* X86_64_WINDOWS */ };
//private static final int[] visualid_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 8 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
private static final int[] screen_offset = new int[] { 8 /* ARM_MIPS_32 */, 8 /* X86_32_UNIX */, 8 /* X86_32_MACOS */, 8 /* PPC_32_UNIX */, 8 /* SPARC_32_SUNOS */, 8 /* X86_32_WINDOWS */, 16 /* LP64_UNIX */, 12 /* X86_64_WINDOWS */ };
//private static final int[] screen_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 4 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
private static final int[] depth_offset = new int[] { 12 /* ARM_MIPS_32 */, 12 /* X86_32_UNIX */, 12 /* X86_32_MACOS */, 12 /* PPC_32_UNIX */, 12 /* SPARC_32_SUNOS */, 12 /* X86_32_WINDOWS */, 20 /* LP64_UNIX */, 16 /* X86_64_WINDOWS */ };
//private static final int[] depth_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 4 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
private static final int[] c_class_offset = new int[] { 16 /* ARM_MIPS_32 */, 16 /* X86_32_UNIX */, 16 /* X86_32_MACOS */, 16 /* PPC_32_UNIX */, 16 /* SPARC_32_SUNOS */, 16 /* X86_32_WINDOWS */, 24 /* LP64_UNIX */, 20 /* X86_64_WINDOWS */ };
//private static final int[] c_class_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 4 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
private static final int[] red_mask_offset = new int[] { 20 /* ARM_MIPS_32 */, 20 /* X86_32_UNIX */, 20 /* X86_32_MACOS */, 20 /* PPC_32_UNIX */, 20 /* SPARC_32_SUNOS */, 20 /* X86_32_WINDOWS */, 32 /* LP64_UNIX */, 24 /* X86_64_WINDOWS */ };
//private static final int[] red_mask_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 8 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
private static final int[] green_mask_offset = new int[] { 24 /* ARM_MIPS_32 */, 24 /* X86_32_UNIX */, 24 /* X86_32_MACOS */, 24 /* PPC_32_UNIX */, 24 /* SPARC_32_SUNOS */, 24 /* X86_32_WINDOWS */, 40 /* LP64_UNIX */, 28 /* X86_64_WINDOWS */ };
//private static final int[] green_mask_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 8 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
private static final int[] blue_mask_offset = new int[] { 28 /* ARM_MIPS_32 */, 28 /* X86_32_UNIX */, 28 /* X86_32_MACOS */, 28 /* PPC_32_UNIX */, 28 /* SPARC_32_SUNOS */, 28 /* X86_32_WINDOWS */, 48 /* LP64_UNIX */, 32 /* X86_64_WINDOWS */ };
//private static final int[] blue_mask_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 8 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
private static final int[] colormap_size_offset = new int[] { 32 /* ARM_MIPS_32 */, 32 /* X86_32_UNIX */, 32 /* X86_32_MACOS */, 32 /* PPC_32_UNIX */, 32 /* SPARC_32_SUNOS */, 32 /* X86_32_WINDOWS */, 56 /* LP64_UNIX */, 36 /* X86_64_WINDOWS */ };
//private static final int[] colormap_size_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 4 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
private static final int[] bits_per_rgb_offset = new int[] { 36 /* ARM_MIPS_32 */, 36 /* X86_32_UNIX */, 36 /* X86_32_MACOS */, 36 /* PPC_32_UNIX */, 36 /* SPARC_32_SUNOS */, 36 /* X86_32_WINDOWS */, 60 /* LP64_UNIX */, 40 /* X86_64_WINDOWS */ };
//private static final int[] bits_per_rgb_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 4 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
public static int size() {
return XVisualInfo_size[mdIdx];
}
public static XVisualInfo create() {
return create(Buffers.newDirectByteBuffer(size()));
}
public static XVisualInfo create(java.nio.ByteBuffer buf) {
return new XVisualInfo(buf);
}
XVisualInfo(java.nio.ByteBuffer buf) {
md = MachineDataInfo.StaticConfig.values()[mdIdx].md;
accessor = new StructAccessor(buf);
}
public java.nio.ByteBuffer getBuffer() {
return accessor.getBuffer();
}
/** Setter for native field visual
: CType[(PointerType) 'Visual *' -> (Visual) * , size [fixed false, lnx64 8], [const[false], pointer*1]], with array length of 1
*/
public XVisualInfo setVisual(long val) {
accessor.setLongAt(visual_offset[mdIdx], val, md.pointerSizeInBytes());
return this;
}
/** Getter for native field visual
: CType[(PointerType) 'Visual *' -> (Visual) * , size [fixed false, lnx64 8], [const[false], pointer*1]], with array length of 1
*/
public long getVisual() {
return accessor.getLongAt(visual_offset[mdIdx], md.pointerSizeInBytes());
}
/** Setter for native field visualid
: CType[(IntType) typedef 'VisualID', size [fixed false, lnx64 8], [const[false], int]] */
public XVisualInfo setVisualid(long val) {
accessor.setLongAt(visualid_offset[mdIdx], val, md.longSizeInBytes());
return this;
}
/** Getter for native field visualid
: CType[(IntType) typedef 'VisualID', size [fixed false, lnx64 8], [const[false], int]] */
public long getVisualid() {
return accessor.getLongAt(visualid_offset[mdIdx], md.longSizeInBytes());
}
/** Setter for native field screen
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public XVisualInfo setScreen(int val) {
accessor.setIntAt(screen_offset[mdIdx], val, md.intSizeInBytes());
return this;
}
/** Getter for native field screen
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public int getScreen() {
return accessor.getIntAt(screen_offset[mdIdx], md.intSizeInBytes());
}
/** Setter for native field depth
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public XVisualInfo setDepth(int val) {
accessor.setIntAt(depth_offset[mdIdx], val, md.intSizeInBytes());
return this;
}
/** Getter for native field depth
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public int getDepth() {
return accessor.getIntAt(depth_offset[mdIdx], md.intSizeInBytes());
}
/** Setter for native field c_class
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public XVisualInfo setC_class(int val) {
accessor.setIntAt(c_class_offset[mdIdx], val, md.intSizeInBytes());
return this;
}
/** Getter for native field c_class
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public int getC_class() {
return accessor.getIntAt(c_class_offset[mdIdx], md.intSizeInBytes());
}
/** Setter for native field red_mask
: CType[(IntType) 'long', size [fixed false, lnx64 8], [const[false], int]] */
public XVisualInfo setRed_mask(long val) {
accessor.setLongAt(red_mask_offset[mdIdx], val, md.longSizeInBytes());
return this;
}
/** Getter for native field red_mask
: CType[(IntType) 'long', size [fixed false, lnx64 8], [const[false], int]] */
public long getRed_mask() {
return accessor.getLongAt(red_mask_offset[mdIdx], md.longSizeInBytes());
}
/** Setter for native field green_mask
: CType[(IntType) 'long', size [fixed false, lnx64 8], [const[false], int]] */
public XVisualInfo setGreen_mask(long val) {
accessor.setLongAt(green_mask_offset[mdIdx], val, md.longSizeInBytes());
return this;
}
/** Getter for native field green_mask
: CType[(IntType) 'long', size [fixed false, lnx64 8], [const[false], int]] */
public long getGreen_mask() {
return accessor.getLongAt(green_mask_offset[mdIdx], md.longSizeInBytes());
}
/** Setter for native field blue_mask
: CType[(IntType) 'long', size [fixed false, lnx64 8], [const[false], int]] */
public XVisualInfo setBlue_mask(long val) {
accessor.setLongAt(blue_mask_offset[mdIdx], val, md.longSizeInBytes());
return this;
}
/** Getter for native field blue_mask
: CType[(IntType) 'long', size [fixed false, lnx64 8], [const[false], int]] */
public long getBlue_mask() {
return accessor.getLongAt(blue_mask_offset[mdIdx], md.longSizeInBytes());
}
/** Setter for native field colormap_size
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public XVisualInfo setColormap_size(int val) {
accessor.setIntAt(colormap_size_offset[mdIdx], val, md.intSizeInBytes());
return this;
}
/** Getter for native field colormap_size
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public int getColormap_size() {
return accessor.getIntAt(colormap_size_offset[mdIdx], md.intSizeInBytes());
}
/** Setter for native field bits_per_rgb
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public XVisualInfo setBits_per_rgb(int val) {
accessor.setIntAt(bits_per_rgb_offset[mdIdx], val, md.intSizeInBytes());
return this;
}
/** Getter for native field bits_per_rgb
: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */
public int getBits_per_rgb() {
return accessor.getIntAt(bits_per_rgb_offset[mdIdx], md.intSizeInBytes());
}
// --- Begin CustomJavaCode .cfg declarations
public static XVisualInfo create(XVisualInfo s) { final ByteBuffer bb = Buffers.newDirectByteBuffer(s.getBuffer().capacity()); final XVisualInfo d = XVisualInfo.create(bb); d.getBuffer().put(s.getBuffer()); d.getBuffer().rewind(); s.getBuffer().rewind(); return d; }
public String toString() {
return "XVisualInfo[size "+size()+"/"+getBuffer().capacity()+", visual 0x"+Long.toHexString(getVisual())+
", visual-id 0x"+Long.toHexString(getVisualid())+", c-class "+getC_class()+", cmap-size "+getColormap_size()+", depth "+getDepth()+
", rgb["+Bitfield.Util.bitCount((int)getRed_mask())+", "+Bitfield.Util.bitCount((int)getRed_mask())+", "+Bitfield.Util.bitCount((int)getRed_mask())+" - "+getBits_per_rgb()+"]]";
}
// ---- End CustomJavaCode .cfg declarations
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy