GLDrawable using GLDrawableFactory,
an instance of this class is passed,
describing the desired capabilities that a rendering context
must support, such as the OpenGL profile, color depth and whether stereo is enabled.GLDrawables are then reflected by their own
GLCapabilites instance, which can be queried with GLDrawable#getChosenGLCapabilities().
| Modifier and Type | Field and Description |
|---|---|
| private int | |
| private int | |
| private int | |
| private int | |
| private int | |
| private boolean | |
| private GLProfile | |
| private boolean | |
| private boolean | |
| private boolean | |
| private int | |
| private boolean | |
| private String | |
| private int | |
| private boolean |
| Access | Constructor and Description |
|---|---|
| public | GLCapabilities(final GLProfile
GLProfile, or null for the default GLProfile glp)Creates a GLCapabilities object. |
| Modifier and Type | Method and Description |
|---|---|
| public Object | clone()
Overrides com. |
| public Object | cloneMutable()
Overrides com. Implements com. |
| public int | compareTo(final CapabilitiesImmutable
the object to be compared. o)Overrides com. Implements java. |
| public GLCapabilities | Returns: this instanceCopies all |
| public boolean | equals(final Object
the reference object with which to compare. obj)Overrides com. Implements com. |
| public final int | getAccumAlphaBits()
Implements com. |
| public final int | getAccumBlueBits()
Implements com. |
| public final int | getAccumGreenBits()
Implements com. |
| public final int | getAccumRedBits()
Implements com. |
| public final int | getDepthBits()
Implements com. |
| public final boolean | getDoubleBuffered()
Implements com. |
| public final GLProfile | getGLProfile()
Implements com. |
| public final boolean | getHardwareAccelerated()
Implements com. |
| public final int | getNumSamples()
Implements com. |
| public final boolean | getSampleBuffers()
Implements com. |
| public final String | getSampleExtension()
Implements com. |
| public final int | getStencilBits()
Implements com. |
| public final boolean | getStereo()
Implements com. |
| public int | hashCode()
Overrides com. Implements com. |
| public final boolean | isFBO()
Implements com. |
| public final boolean | isPBuffer()
Implements com. |
| public void | setAccumAlphaBits(final int accumAlphaBits)
Sets number of bits requested for accumulation buffer's alpha component. |
| public void | setAccumBlueBits(final int accumBlueBits)
Sets the number of bits requested for the accumulation buffer's blue component. |
| public void | setAccumGreenBits(final int accumGreenBits)
Sets the number of bits requested for the accumulation buffer's green component. |
| public void | setAccumRedBits(final int accumRedBits)
Sets the number of bits requested for the accumulation buffer's red component. |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | setNumSamples(final int numSamples)
If sample buffers are enabled, indicates the number of buffers to be allocated. |
| public void | |
| public void | |
| public void | setSampleExtension(final String se)
Sets the desired extension for full-scene antialiasing
(FSAA), default is |
| public void | |
| public void | |
| public StringBuilder | toString(StringBuilder sink)
Overrides com. Implements com. |
| public String | toString()
Overrides com. Implements com. |
| accumAlphaBits | back to summary |
|---|---|
| private int accumAlphaBits | |
| accumBlueBits | back to summary |
|---|---|
| private int accumBlueBits | |
| accumGreenBits | back to summary |
|---|---|
| private int accumGreenBits | |
| accumRedBits | back to summary |
|---|---|
| private int accumRedBits | |
| depthBits | back to summary |
|---|---|
| private int depthBits | |
| doubleBuffered | back to summary |
|---|---|
| private boolean doubleBuffered | |
| glProfile | back to summary |
|---|---|
| private GLProfile glProfile | |
| hardwareAccelerated | back to summary |
|---|---|
| private boolean hardwareAccelerated | |
| isFBO | back to summary |
|---|---|
| private boolean isFBO | |
| isPBuffer | back to summary |
|---|---|
| private boolean isPBuffer | |
| numSamples | back to summary |
|---|---|
| private int numSamples | |
| sampleBuffers | back to summary |
|---|---|
| private boolean sampleBuffers | |
| sampleExtension | back to summary |
|---|---|
| private String sampleExtension | |
| stencilBits | back to summary |
|---|---|
| private int stencilBits | |
| stereo | back to summary |
|---|---|
| private boolean stereo | |
| GLCapabilities | back to summary |
|---|---|
| public GLCapabilities(final GLProfile glp) throws GLException Creates a GLCapabilities object. All attributes are in a default state.
| |
| clone | back to summary |
|---|---|
| public Object clone() Overrides com. Doc from java. Creates and returns a copy of this object. The precise meaning
of "copy" may depend on the class of the object. The general
intent is that, for any object will be true, and that the expression:x.clone() != x will bex.clone().getClass() == x.getClass() true, but these are not absolute requirements.
While it is typically the case that:
will bex.clone().equals(x) true, this is not an absolute requirement.
By convention, the returned object should be obtained by calling
By convention, the object returned by this method should be independent
of this object (which is being cloned). To achieve this independence,
it may be necessary to modify one or more fields of the object returned
by | |
| cloneMutable | back to summary |
|---|---|
| public Object cloneMutable() Overrides com. Implements com. Doc from com. Get a mutable clone from this instance.
| |
| compareTo | back to summary |
|---|---|
| public int compareTo(final CapabilitiesImmutable o) Overrides com. Implements java. comparing hw/sw, stereo, multisample, stencil, RGBA and depth only
| |
| copyFrom | back to summary |
|---|---|
| public GLCapabilities copyFrom(final GLCapabilitiesImmutable source) Copies all
| |
| equals | back to summary |
|---|---|
| public boolean equals(final Object obj) Overrides com. Implements com. Doc from com. Equality over the immutable attributes of both objects
| |
| getAccumAlphaBits | back to summary |
|---|---|
| public final int getAccumAlphaBits() Implements com. Doc from com. Returns the number of bits for the accumulation buffer's alpha component. On some systems only the accumulation buffer depth, which is the sum of the red, green, and blue bits, is considered.
| |
| getAccumBlueBits | back to summary |
|---|---|
| public final int getAccumBlueBits() Implements com. Doc from com. Returns the number of bits for the accumulation buffer's blue component. On some systems only the accumulation buffer depth, which is the sum of the red, green, and blue bits, is considered.
| |
| getAccumGreenBits | back to summary |
|---|---|
| public final int getAccumGreenBits() Implements com. Doc from com. Returns the number of bits for the accumulation buffer's green component. On some systems only the accumulation buffer depth, which is the sum of the red, green, and blue bits, is considered.
| |
| getAccumRedBits | back to summary |
|---|---|
| public final int getAccumRedBits() Implements com. Doc from com. Returns the number of bits for the accumulation buffer's red component. On some systems only the accumulation buffer depth, which is the sum of the red, green, and blue bits, is considered.
| |
| getDepthBits | back to summary |
|---|---|
| public final int getDepthBits() Implements com. Doc from com. Returns the number of depth buffer bits.
| |
| getDoubleBuffered | back to summary |
|---|---|
| public final boolean getDoubleBuffered() Implements com. Doc from com. Returns whether double-buffering is requested, available or chosen. Default is true.
| |
| getGLProfile | back to summary |
|---|---|
| public final GLProfile getGLProfile() Implements com. Doc from com. Returns the GL profile you desire or used by the drawable.
| |
| getHardwareAccelerated | back to summary |
|---|---|
| public final boolean getHardwareAccelerated() Implements com. Doc from com. Returns whether hardware acceleration is requested, available or chosen. Default is true.
| |
| getNumSamples | back to summary |
|---|---|
| public final int getNumSamples() Implements com. Doc from com. Returns the number of sample buffers to be allocated if sample buffers are enabled, otherwise returns 0. Default is 0 due to disable sample buffers per default.
| |
| getSampleBuffers | back to summary |
|---|---|
| public final boolean getSampleBuffers() Implements com. Doc from com. Returns whether sample buffers for full-scene antialiasing (FSAA) should be allocated for this drawable. Default is false.
| |
| getSampleExtension | back to summary |
|---|---|
| public final String getSampleExtension() Implements com. Doc from com. Returns the extension for full-scene antialiasing (FSAA).
Default is
| |
| getStencilBits | back to summary |
|---|---|
| public final int getStencilBits() Implements com. Doc from com. Returns the number of stencil buffer bits. Default is 0.
| |
| getStereo | back to summary |
|---|---|
| public final boolean getStereo() Implements com. Doc from com. Returns whether stereo is requested, available or chosen. Default is false.
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides com. Implements com. Doc from com. hash code over the immutable attributes of both objects
| |
| isFBO | back to summary |
|---|---|
| public final boolean isFBO() Implements com. Doc from com. Returns whether FBO offscreen mode is requested, available or chosen. Default is false.
For chosen capabilities, only the selected offscreen surface is set to
| |
| isPBuffer | back to summary |
|---|---|
| public final boolean isPBuffer() Implements com. Doc from com. Returns whether pbuffer offscreen mode is requested, available or chosen. Default is false.
For chosen capabilities, only the selected offscreen surface is set to
| |
| setAccumAlphaBits | back to summary |
|---|---|
| public void setAccumAlphaBits(final int accumAlphaBits) Sets number of bits requested for accumulation buffer's alpha component. On some systems only the accumulation buffer depth, which is the sum of the red, green, and blue bits, is considered. | |
| setAccumBlueBits | back to summary |
|---|---|
| public void setAccumBlueBits(final int accumBlueBits) Sets the number of bits requested for the accumulation buffer's blue component. On some systems only the accumulation buffer depth, which is the sum of the red, green, and blue bits, is considered. | |
| setAccumGreenBits | back to summary |
|---|---|
| public void setAccumGreenBits(final int accumGreenBits) Sets the number of bits requested for the accumulation buffer's green component. On some systems only the accumulation buffer depth, which is the sum of the red, green, and blue bits, is considered. | |
| setAccumRedBits | back to summary |
|---|---|
| public void setAccumRedBits(final int accumRedBits) Sets the number of bits requested for the accumulation buffer's red component. On some systems only the accumulation buffer depth, which is the sum of the red, green, and blue bits, is considered. | |
| setDepthBits | back to summary |
|---|---|
| public void setDepthBits(final int depthBits) Sets the number of bits requested for the depth buffer. | |
| setDoubleBuffered | back to summary |
|---|---|
| public void setDoubleBuffered(final boolean enable) Enables or disables double buffering. | |
| setFBO | back to summary |
|---|---|
| public void setFBO(final boolean enable) Requesting offscreen FBO mode.
If enabled this method also invokes Defaults to false. Requesting offscreen FBO mode disables the offscreen auto selection. | |
| setGLProfile | back to summary |
|---|---|
| public void setGLProfile(final GLProfile profile) Sets the GL profile you desire | |
| setHardwareAccelerated | back to summary |
|---|---|
| public void setHardwareAccelerated(final boolean enable) Enables or disables hardware acceleration. | |
| setNumSamples | back to summary |
|---|---|
| public void setNumSamples(final int numSamples) If sample buffers are enabled, indicates the number of buffers to be allocated. Defaults to 2.
| |
| setPBuffer | back to summary |
|---|---|
| public void setPBuffer(final boolean enable) Requesting offscreen pbuffer mode.
If enabled this method also invokes Defaults to false. Requesting offscreen pbuffer mode disables the offscreen auto selection. | |
| setSampleBuffers | back to summary |
|---|---|
| public void setSampleBuffers(final boolean enable) Defaults to false. | |
| setSampleExtension | back to summary |
|---|---|
| public void setSampleExtension(final String se) Sets the desired extension for full-scene antialiasing
(FSAA), default is | |
| setStencilBits | back to summary |
|---|---|
| public void setStencilBits(final int stencilBits) Sets the number of bits requested for the stencil buffer. | |
| setStereo | back to summary |
|---|---|
| public void setStereo(final boolean enable) Enables or disables stereo viewing. | |
| toString | back to summary |
|---|---|
| public StringBuilder toString(StringBuilder sink) Overrides com. Implements com. Doc from com. Return a textual representation of this object. Use the given StringBuilder [optional].
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides com. Implements com. Returns a textual representation of this GLCapabilities object.
| |