public class Java2D
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static int |
FBOBJECT |
static int |
FLIP_BACKBUFFER |
static int |
PBUFFER |
static int |
TEXTURE |
static int |
UNDEFINED |
static int |
WINDOW |
Constructor and Description |
---|
Java2D() |
Modifier and Type | Method and Description |
---|---|
static long |
createOGLContextOnSurface(java.awt.Graphics g,
long shareCtx)
(Mac OS X-specific) Creates a new OpenGL context on the surface
associated with the given Graphics object, sharing textures and
display lists with the specified (CGLContextObj) share context.
|
static void |
destroyOGLContext(long ctx)
(Mac OS X-specific) Destroys the given OpenGL context.
|
static GLContext |
filterShareContext(GLContext shareContext)
Returns either the given GLContext or a substitute one with
which clients should share textures and display lists.
|
static java.awt.Rectangle |
getOGLScissorBox(java.awt.Graphics g)
Returns the OpenGL scissor region associated with the given
Graphics object, taking into account all clipping regions, etc.
|
static java.lang.Object |
getOGLSurfaceIdentifier(java.awt.Graphics g)
Returns an opaque "surface identifier" associated with the given
Graphics object.
|
static int |
getOGLSurfaceType(java.awt.Graphics g)
Returns the underlying surface type for the given Graphics
object.
|
static int |
getOGLTextureType(java.awt.Graphics g)
Returns the underlying texture target of the given Graphics
object assuming it is rendering to an FBO.
|
static java.awt.Rectangle |
getOGLViewport(java.awt.Graphics g,
int componentWidth,
int componentHeight)
Returns the OpenGL viewport associated with the given Graphics
object, assuming that the Graphics object is associated with a
component of the specified width and height.
|
static GLContext |
getShareContext(java.awt.GraphicsConfiguration gc)
Returns the GLContext associated with the Java2D "share
context", with which all contexts created by JOGL must share
textures and display lists when the FBO option is enabled for
the Java2D/OpenGL pipeline.
|
static void |
invokeWithOGLContextCurrent(java.awt.Graphics g,
java.lang.Runnable r)
Makes current the OpenGL context associated with the passed
Graphics object and runs the given Runnable on the Queue
Flushing Thread in one atomic action.
|
static boolean |
invokeWithOGLSharedContextCurrent(java.awt.GraphicsConfiguration g,
java.lang.Runnable r)
Makes current the "shared" OpenGL context associated with the
given GraphicsConfiguration object, allowing JOGL to share
server-side OpenGL objects like textures and display lists with
this context when necessary.
|
static boolean |
isFBOEnabled() |
static boolean |
isOGLPipelineActive() |
static boolean |
isQueueFlusherThread() |
static boolean |
makeOGLContextCurrentOnSurface(java.awt.Graphics g,
long ctx)
(Mac OS X-specific) Makes the given OpenGL context current on
the surface associated with the given Graphics object.
|
public static final int UNDEFINED
public static final int WINDOW
public static final int PBUFFER
public static final int TEXTURE
public static final int FLIP_BACKBUFFER
public static final int FBOBJECT
public static boolean isOGLPipelineActive()
public static boolean isFBOEnabled()
public static boolean isQueueFlusherThread()
public static void invokeWithOGLContextCurrent(java.awt.Graphics g, java.lang.Runnable r) throws GLException
GLException
public static boolean invokeWithOGLSharedContextCurrent(java.awt.GraphicsConfiguration g, java.lang.Runnable r) throws GLException
GLException
public static java.awt.Rectangle getOGLViewport(java.awt.Graphics g, int componentWidth, int componentHeight)
public static java.awt.Rectangle getOGLScissorBox(java.awt.Graphics g)
public static java.lang.Object getOGLSurfaceIdentifier(java.awt.Graphics g)
public static int getOGLSurfaceType(java.awt.Graphics g)
public static int getOGLTextureType(java.awt.Graphics g)
public static GLContext filterShareContext(GLContext shareContext)
public static GLContext getShareContext(java.awt.GraphicsConfiguration gc)
public static long createOGLContextOnSurface(java.awt.Graphics g, long shareCtx)
public static boolean makeOGLContextCurrentOnSurface(java.awt.Graphics g, long ctx)
public static void destroyOGLContext(long ctx)
Copyright 2005 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.