APIdia Launch Partner
Top Description Inners Fields Constructors Methods
sun.java2d.opengl

pack-priv final Class OGLContext

extends BufferedContext
Class Inheritance
Imports
java.lang.annotation.Native, sun.java2d.pipe.BufferedContext, .RenderBuffer, .RenderQueue, sun.java2d.pipe.hw.ContextCapabilities

Note that the RenderQueue lock must be acquired before calling any of the methods in this class.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class

Field Summary

Inherited from sun.java2d.pipe.BufferedContext:
currentContextNO_CONTEXT_FLAGSSRC_IS_OPAQUEUSE_MASK

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
pack-priv static final native String

Returns:

an id string for the adapter
getOGLIdString
()

Returns a string representing adapter id (vendor, renderer, version).

pack-priv static void
invalidateCurrentContext()

Invalidates the currentContext field to ensure that we properly revalidate the OGLContext (make it current, etc.) next time through the validate() method.

pack-priv static void
setScratchSurface(OGLGraphicsConfig gc)

Convenience method that delegates to setScratchSurface() below.

pack-priv static void
setScratchSurface(long pConfigInfo)

Makes the given GraphicsConfig's context current to its associated "scratch surface".

Inherited from sun.java2d.pipe.BufferedContext:
getRenderQueueinvalidateContextvalidateContextvalidateContext

Constructor Detail

OGLContextback to summary
pack-priv OGLContext(RenderQueue rq)

Method Detail

getOGLIdStringback to summary
pack-priv static final native String getOGLIdString()

Returns a string representing adapter id (vendor, renderer, version). Must be called on the rendering thread.

Returns:String

an id string for the adapter

invalidateCurrentContextback to summary
pack-priv static void invalidateCurrentContext()

Invalidates the currentContext field to ensure that we properly revalidate the OGLContext (make it current, etc.) next time through the validate() method. This is typically invoked from methods that affect the current context state (e.g. disposing a context or surface).

setScratchSurfaceback to summary
pack-priv static void setScratchSurface(OGLGraphicsConfig gc)

Convenience method that delegates to setScratchSurface() below.

setScratchSurfaceback to summary
pack-priv static void setScratchSurface(long pConfigInfo)

Makes the given GraphicsConfig's context current to its associated "scratch surface". Each GraphicsConfig maintains a native context (GLXContext on Unix, HGLRC on Windows) as well as a native pbuffer known as the "scratch surface". By making the context current to the scratch surface, we are assured that we have a current context for the relevant GraphicsConfig, and can therefore perform operations depending on the capabilities of that GraphicsConfig. For example, if the GraphicsConfig supports the GL_ARB_texture_non_power_of_two extension, then we should be able to make a non-pow2 texture for this GraphicsConfig once we make the context current to the scratch surface. This method should be used for operations with an OpenGL texture as the destination surface (e.g. a sw->texture blit loop), or in those situations where we may not otherwise have a current context (e.g. when disposing a texture-based surface).

sun.java2d.opengl back to summary

pack-priv Class OGLContext.OGLContextCaps

extends ContextCapabilities
Class Inheritance

Field Summary

Modifier and TypeField and Description
pack-priv static final int
CAPS_DOUBLEBUFFERED

Indicates that the context is doublebuffered.

pack-priv static final int
CAPS_EXT_BIOP_SHADER

Indicates the presence of the GL_ARB_fragment_shader extension.

pack-priv static final int
CAPS_EXT_FBOBJECT

Indicates the presence of the GL_EXT_framebuffer_object extension.

pack-priv static final int
CAPS_EXT_GRAD_SHADER

Indicates the presence of the GL_ARB_fragment_shader extension.

pack-priv static final int
CAPS_EXT_LCD_SHADER

Indicates the presence of the GL_ARB_fragment_shader extension.

pack-priv static final int
CAPS_EXT_TEXBARRIER

Indicates the presence of the GL_NV_texture_barrier extension.

pack-priv static final int
CAPS_EXT_TEXRECT

Indicates the presence of the GL_ARB_texture_rectangle extension.

Inherited from sun.java2d.pipe.hw.ContextCapabilities:
adapterIdcapsCAPS_EMPTYCAPS_MULTITEXTURECAPS_PS20CAPS_PS30CAPS_RT_PLAIN_ALPHACAPS_RT_TEXTURE_ALPHACAPS_RT_TEXTURE_OPAQUECAPS_TEXNONPOW2CAPS_TEXNONSQUAREFIRST_PRIVATE_CAP

Constructor Summary

AccessConstructor and Description
pack-priv
OGLContextCaps(int caps, String adapterId)

Method Summary

Modifier and TypeMethod and Description
public String
toString()

Overrides sun.java2d.pipe.hw.ContextCapabilities.toString.

Returns a string representation of the object.

Inherited from sun.java2d.pipe.hw.ContextCapabilities:
getAdapterIdgetCaps

Field Detail

CAPS_DOUBLEBUFFEREDback to summary
pack-priv static final int CAPS_DOUBLEBUFFERED

Indicates that the context is doublebuffered.

Annotations
@Native
CAPS_EXT_BIOP_SHADERback to summary
pack-priv static final int CAPS_EXT_BIOP_SHADER

Indicates the presence of the GL_ARB_fragment_shader extension. This cap will only be set if the biopshader system property has been enabled and the hardware meets our minimum requirements.

Annotations
@Native
CAPS_EXT_FBOBJECTback to summary
pack-priv static final int CAPS_EXT_FBOBJECT

Indicates the presence of the GL_EXT_framebuffer_object extension. This cap will only be set if the fbobject system property has been enabled and we are able to create an FBO with depth buffer.

Annotations
@Native
CAPS_EXT_GRAD_SHADERback to summary
pack-priv static final int CAPS_EXT_GRAD_SHADER

Indicates the presence of the GL_ARB_fragment_shader extension. This cap will only be set if the gradshader system property has been enabled and the hardware meets our minimum requirements.

Annotations
@Native
CAPS_EXT_LCD_SHADERback to summary
pack-priv static final int CAPS_EXT_LCD_SHADER

Indicates the presence of the GL_ARB_fragment_shader extension. This cap will only be set if the lcdshader system property has been enabled and the hardware supports the minimum number of texture units

Annotations
@Native
CAPS_EXT_TEXBARRIERback to summary
pack-priv static final int CAPS_EXT_TEXBARRIER

Indicates the presence of the GL_NV_texture_barrier extension.

Annotations
@Native
CAPS_EXT_TEXRECTback to summary
pack-priv static final int CAPS_EXT_TEXRECT

Indicates the presence of the GL_ARB_texture_rectangle extension.

Annotations
@Native

Constructor Detail

OGLContextCapsback to summary
pack-priv OGLContextCaps(int caps, String adapterId)

Method Detail

toStringback to summary
public String toString()

Overrides sun.java2d.pipe.hw.ContextCapabilities.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Annotations
@Override