|
Aviatrix3D 2.1.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.j3d.aviatrix3d.output.graphics.BaseSurface org.j3d.aviatrix3d.output.graphics.PbufferSurface
public class PbufferSurface
Implementation of a drawable surface that only renders to an offscreen pbuffer.
Resizing information
Pbuffers cannot be resized, so all queries to add and remove resize
listeners are silently ignored. However, we do something a little
different. When the listener add request is received, we immediately
call the listener with the size of this surface. This allows applications
that depend on getting some resize information (eg using our utility
ViewportResizeManager
class)
to still behave consistently.
Beyond this initial call, no resize events will ever be generated. Listeners are never kept by the implementation.
Field Summary |
---|
Fields inherited from class org.j3d.aviatrix3d.output.graphics.BaseSurface |
---|
alphaCutoff, canCreatePBuffers, canvas, canvasContext, canvasDescriptor, canvasRenderer, errorReporter, FAILED_CONTEXT_MSG, initComplete, numRenderables, renderableList, rendererMap, sharedSurface, singleThreaded, surfaceMonitor, terminate, useTwoPassTransparent |
Fields inherited from interface org.j3d.aviatrix3d.pipeline.graphics.GraphicsOutputDevice |
---|
ALTERNATE_FRAME_STEREO, NO_STEREO, QUAD_BUFFER_STEREO, TWO_CANVAS_STEREO |
Constructor Summary | |
---|---|
PbufferSurface(javax.media.opengl.GLCapabilities caps,
BaseSurface sharedSurface,
int width,
int height)
Construct a surface shares it's GL context with the given surface. |
|
PbufferSurface(javax.media.opengl.GLCapabilities caps,
javax.media.opengl.GLCapabilitiesChooser chooser,
BaseSurface sharedSurface,
int width,
int height)
Construct a surface shares it's GL context with the given surface. |
|
PbufferSurface(javax.media.opengl.GLCapabilities caps,
javax.media.opengl.GLCapabilitiesChooser chooser,
int width,
int height)
Construct a surface that requires the given set of capabilities. |
|
PbufferSurface(javax.media.opengl.GLCapabilities caps,
int width,
int height)
Construct a surface that requires the given set of capabilities. |
Method Summary | |
---|---|
void |
addGraphicsResizeListener(GraphicsResizeListener l)
Add a resize listener instance to this surface. |
java.lang.Object |
getSurfaceObject()
Get the underlying object that this surface is rendered to. |
void |
removeGraphicsResizeListener(GraphicsResizeListener l)
Remove a resize listener from this surface. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PbufferSurface(javax.media.opengl.GLCapabilities caps, int width, int height) throws PbufferUnavailableException
caps
- A set of required capabilities for this canvas.width
- The width of the surface in pixelsheight
- The height of the surface in pixels
PbufferUnavailableException
- When JOGL tells us that pbuffers
are not available on this platform or capabilitiespublic PbufferSurface(javax.media.opengl.GLCapabilities caps, javax.media.opengl.GLCapabilitiesChooser chooser, int width, int height) throws PbufferUnavailableException
caps
- A set of required capabilities for this canvas.chooser
- Custom algorithm for selecting one of the available
GLCapabilities for the component;width
- The width of the surface in pixelsheight
- The height of the surface in pixels
PbufferUnavailableException
- When JOGL tells us that pbuffers
are not available on this platform or capabilitiespublic PbufferSurface(javax.media.opengl.GLCapabilities caps, BaseSurface sharedSurface, int width, int height) throws PbufferUnavailableException
If the sharedSurface parameter is null, then this is just treated as an ordinary non-shared frame. The return flag will be set appropriately.
caps
- A set of required capabilities for this canvas.sharedSurface
- The surface that you'd like this surface to share
the GL context with, if possible. May be null.width
- The width of the surface in pixelsheight
- The height of the surface in pixels
PbufferUnavailableException
- When JOGL tells us that pbuffers
are not available on this platform or capabilitiespublic PbufferSurface(javax.media.opengl.GLCapabilities caps, javax.media.opengl.GLCapabilitiesChooser chooser, BaseSurface sharedSurface, int width, int height) throws PbufferUnavailableException
If the sharedSurface parameter is null, then this is just treated as an ordinary non-shared frame. The return flag will be set appropriately.
caps
- A set of required capabilities for this canvas.chooser
- Custom algorithm for selecting one of the available
GLCapabilities for the component;sharedSurface
- The surface that you'd like this surface to share
the GL context with, if possible. May be null.width
- The width of the surface in pixelsheight
- The height of the surface in pixels
PbufferUnavailableException
- When JOGL tells us that pbuffers
are not available on this platform or capabilitiesMethod Detail |
---|
public java.lang.Object getSurfaceObject()
public void addGraphicsResizeListener(GraphicsResizeListener l)
l
- The new listener instance to addpublic void removeGraphicsResizeListener(GraphicsResizeListener l)
l
- The listener instance to remove
|
Aviatrix3D 2.1.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |