public class GLJPanel
extends javax.swing.JPanel
implements com.jogamp.opengl.awt.AWTGLAutoDrawable, com.jogamp.nativewindow.WindowClosingProtocol, com.jogamp.nativewindow.awt.AWTPrintLifecycle, com.jogamp.opengl.GLSharedContextSetter, com.jogamp.nativewindow.ScalableSurface
 The GLJPanel can be made transparent by creating it with a GLCapabilities
 object with alpha bits specified and calling setOpaque(boolean)(false).
 Pixels with resulting OpenGL alpha values less than 1.0 will be overlaid on
 any underlying Swing rendering.
 
 This component attempts to use hardware-accelerated rendering via FBO or
 pbuffers and falls back on to software rendering if none of the former are
 available using
 GLDrawableFactory.createOffscreenDrawable(..).
 
 A vertical-flip is required, if the drawable
 isGLOriented() and vertical flip is not skipped.
 In this case this component performs the required vertical flip to bring the
 content from OpenGL's orientation into AWT's orientation.
 In case GLSL based vertical-flip is not
 available, the CPU intensive
 System.arraycopy(..)
 is used line by line. See details about FBO
 and GLSL vertical flipping.
 
 For performance reasons, as well as for GL state
 sideeffects, skipping vertical flip is highly recommended!
 
 The OpenGL path is concluded by copying the rendered pixels an
 BufferedImage via
 glReadPixels(..) for later Java2D composition.
 
 Finally the Java2D compositioning takes place via via
 Graphics.drawImage(...) on the prepared BufferedImage as described
 above.
 
Please read Java2D OpenGL Remarks.
vertical flip is not
 skipped, a fragment shader is utilized to flip the FBO texture vertically.
 This hardware-accelerated step can be disabled via system property
 jogl.gljpanel.noglsl.
 
 The FBO / GLSL code path uses one texture-unit and binds the FBO texture to
 it's active texture-target, see setTextureUnit(int) and
 getTextureUnit().
 
 The active and dedicated texture-unit's GL.GL_TEXTURE_2D state is
 preserved via TextureState. 
 
The current gl-viewport is preserved.
 Warning (Bug 842): Certain GL states other than
 viewport and texture (see above) influencing rendering, will also influence
 the GLSL vertical flip, e.g. glFrontFace(GL.GL_CCW). It is recommended to reset those states to
 default when leaving the GLEventListener.display(GLAutoDrawable)
 method! We may change this behavior in the future, i.e. preserve all
 influencing states.
 
GLContext see the following note in the documentation
 overview:
 context sharing as
 well as GLSharedContextSetter.javax.swing.JComponent.AccessibleJComponentjava.awt.Component.BaselineResizeBehaviorTOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWBOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTDEFAULT_PRINT_TILE_SIZE| Constructor and Description | 
|---|
| GLJPanel()Creates a new GLJPanel component with a default set of OpenGL capabilities
 and using the default OpenGL capabilities selection mechanism. | 
| GLJPanel(com.jogamp.opengl.GLCapabilitiesImmutable userCapsRequest)Creates a new GLJPanel component with the requested set of OpenGL
 capabilities, using the default OpenGL capabilities selection mechanism. | 
| GLJPanel(com.jogamp.opengl.GLCapabilitiesImmutable userCapsRequest,
        com.jogamp.opengl.GLCapabilitiesChooser chooser)Creates a new GLJPanel component. | 
| Modifier and Type | Method and Description | 
|---|---|
| void | addGLEventListener(com.jogamp.opengl.GLEventListener listener) | 
| void | addGLEventListener(int index,
                  com.jogamp.opengl.GLEventListener listener) | 
| void | addNotify()Overridden to track when this component is added to a container. | 
| boolean | areAllGLEventListenerInitialized() | 
| com.jogamp.opengl.GLContext | createContext(com.jogamp.opengl.GLContext shareWith) | 
| void | destroy()Just an alias for removeNotify | 
| void | display() | 
| com.jogamp.opengl.GLEventListener | disposeGLEventListener(com.jogamp.opengl.GLEventListener listener,
                      boolean remove) | 
| void | flushGLRunnables() | 
| com.jogamp.opengl.GLAnimatorControl | getAnimator() | 
| boolean | getAutoSwapBufferMode() | 
| com.jogamp.opengl.GLCapabilitiesImmutable | getChosenGLCapabilities() | 
| com.jogamp.opengl.GLContext | getContext() | 
| int | getContextCreationFlags() | 
| float[] | getCurrentSurfaceScale(float[] result) | 
| com.jogamp.opengl.util.awt.AWTGLPixelBuffer.AWTGLPixelBufferProvider | getCustomPixelBufferProvider() | 
| com.jogamp.nativewindow.WindowClosingProtocol.WindowClosingMode | getDefaultCloseOperation() | 
| com.jogamp.opengl.GLDrawable | getDelegatedDrawable() | 
| java.lang.Thread | getExclusiveContextThread() | 
| com.jogamp.opengl.GLDrawableFactory | getFactory() | 
| com.jogamp.opengl.GL | getGL() | 
| com.jogamp.opengl.GLEventListener | getGLEventListener(int index) | 
| int | getGLEventListenerCount() | 
| boolean | getGLEventListenerInitState(com.jogamp.opengl.GLEventListener listener) | 
| com.jogamp.opengl.GLProfile | getGLProfile() | 
| long | getHandle() | 
| float[] | getMaximumSurfaceScale(float[] result) | 
| float[] | getMinimumSurfaceScale(float[] result) | 
| com.jogamp.nativewindow.NativeSurface | getNativeSurface() | 
| com.jogamp.opengl.GLCapabilitiesImmutable | getRequestedGLCapabilities() | 
| float[] | getRequestedSurfaceScale(float[] result) | 
| boolean | getSkipGLOrientationVerticalFlip() | 
| int | getSurfaceHeight() | 
| int | getSurfaceWidth() | 
| int | getTextureUnit()Returns the used texture unit, i.e. | 
| com.jogamp.common.util.locks.RecursiveLock | getUpstreamLock() | 
| java.lang.Object | getUpstreamWidget() | 
| boolean | initializeBackend(boolean offthread)Attempts to initialize the backend, if not initialized yet. | 
| boolean | invoke(boolean wait,
      com.jogamp.opengl.GLRunnable glRunnable) | 
| boolean | invoke(boolean wait,
      java.util.List<com.jogamp.opengl.GLRunnable> glRunnables) | 
| boolean | isGLOriented() | 
| boolean | isRealized() | 
| boolean | isThreadGLCapable() | 
| void | print(java.awt.Graphics graphics) | 
| void | releasePrint() | 
| com.jogamp.opengl.GLEventListener | removeGLEventListener(com.jogamp.opengl.GLEventListener listener) | 
| void | removeNotify()Overridden to track when this component is removed from a container. | 
| void | reshape(int x,
       int y,
       int width,
       int height)Overridden to cause  GLDrawableHelper.reshape(com.jogamp.opengl.GLAutoDrawable, int, int, int, int)to be called on all
 registeredGLEventListeners. | 
| void | setAnimator(com.jogamp.opengl.GLAnimatorControl animatorControl) | 
| void | setAutoSwapBufferMode(boolean enable) | 
| com.jogamp.opengl.GLContext | setContext(com.jogamp.opengl.GLContext newCtx,
          boolean destroyPrevCtx) | 
| void | setContextCreationFlags(int flags) | 
| com.jogamp.nativewindow.WindowClosingProtocol.WindowClosingMode | setDefaultCloseOperation(com.jogamp.nativewindow.WindowClosingProtocol.WindowClosingMode op) | 
| java.lang.Thread | setExclusiveContextThread(java.lang.Thread t) | 
| com.jogamp.opengl.GL | setGL(com.jogamp.opengl.GL gl) | 
| void | setGLEventListenerInitState(com.jogamp.opengl.GLEventListener listener,
                           boolean initialized) | 
| void | setOpaque(boolean opaque) | 
| void | setPixelBufferProvider(com.jogamp.opengl.util.awt.AWTGLPixelBuffer.AWTGLPixelBufferProvider custom) | 
| void | setRealized(boolean realized) | 
| void | setRequestedGLCapabilities(com.jogamp.opengl.GLCapabilitiesImmutable caps)Set a new requested  GLCapabilitiesImmutablefor this GLJPanel
 allowing reconfiguration. | 
| void | setSharedAutoDrawable(com.jogamp.opengl.GLAutoDrawable sharedAutoDrawable) | 
| void | setSharedContext(com.jogamp.opengl.GLContext sharedContext) | 
| void | setSkipGLOrientationVerticalFlip(boolean v)Skip  isGLOriented()based vertical flip, which usually is
 required by the offscreen backend, see details about
 vertical flip and
 FBO / GLSL vertical flip. | 
| boolean | setSurfaceScale(float[] pixelScale) | 
| void | setTextureUnit(int v)Allows user to request a texture unit to be used, must be called before
 the first initialization, i.e. | 
| void | setupPrint(double scaleMatX,
          double scaleMatY,
          int numSamples,
          int tileWidth,
          int tileHeight) | 
| boolean | shouldPreserveColorBufferIfTranslucent()For a translucent GLJPanel (one for which  setOpaque(false) has been called), indicates whether the application
 should preserve the OpenGL color buffer (GL_COLOR_BUFFER_BIT) for correct
 rendering of the GLJPanel and underlying widgets which may show through
 portions of the GLJPanel with alpha values less than 1. | 
| void | swapBuffers() | 
| java.lang.String | toString() | 
getAccessibleContext, getUI, getUIClassID, setUI, updateUIaddAncestorListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintImmediately, paintImmediately, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, updateadd, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validateaction, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, transferFocus, transferFocusBackward, transferFocusUpCycleequals, getClass, hashCode, notify, notifyAll, wait, wait, waitaddComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, addPropertyChangeListener, addPropertyChangeListener, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListenerpublic GLJPanel()
         throws com.jogamp.opengl.GLException
See details about OpenGL context sharing.
com.jogamp.opengl.GLException - if no default profile is available for the default desktop device.public GLJPanel(com.jogamp.opengl.GLCapabilitiesImmutable userCapsRequest)
         throws com.jogamp.opengl.GLException
See details about OpenGL context sharing.
com.jogamp.opengl.GLException - if no GLCapabilities are given and no default profile is available for the
 default desktop device.public GLJPanel(com.jogamp.opengl.GLCapabilitiesImmutable userCapsRequest,
                com.jogamp.opengl.GLCapabilitiesChooser chooser)
         throws com.jogamp.opengl.GLException
See details about OpenGL context sharing.
com.jogamp.opengl.GLException - if no GLCapabilities are given and no default profile is available for the
 default desktop device.public final boolean initializeBackend(boolean offthread)
 If backend is already initialized method returns true.
 
 If offthread is true, initialization will kicked
 off on a short lived arbitrary thread and method returns
 immediately.
 If platform supports such arbitrary thread initialization method
 returns true, otherwise false.
 
 If offthread is false, initialization be
 performed on the current thread and method returns after
 initialization.
 Method returns true if initialization was successful,
 otherwise false.
 
offthread - current or background threadpublic final void setSharedContext(com.jogamp.opengl.GLContext sharedContext)
                            throws java.lang.IllegalStateException
setSharedContext in interface com.jogamp.opengl.GLSharedContextSetterjava.lang.IllegalStateExceptionpublic final void setSharedAutoDrawable(com.jogamp.opengl.GLAutoDrawable sharedAutoDrawable)
                                 throws java.lang.IllegalStateException
setSharedAutoDrawable in interface com.jogamp.opengl.GLSharedContextSetterjava.lang.IllegalStateExceptionpublic com.jogamp.opengl.util.awt.AWTGLPixelBuffer.AWTGLPixelBufferProvider getCustomPixelBufferProvider()
public void setPixelBufferProvider(com.jogamp.opengl.util.awt.AWTGLPixelBuffer.AWTGLPixelBufferProvider custom)
                            throws java.lang.IllegalArgumentException,
                                   java.lang.IllegalStateException
custom - custom AWTGLPixelBuffer.AWTGLPixelBufferProviderjava.lang.IllegalArgumentException - if custom is nulljava.lang.IllegalStateException - if backend is already realized, i.e. this instanced already painted once.public final java.lang.Object getUpstreamWidget()
getUpstreamWidget in interface com.jogamp.opengl.GLAutoDrawablepublic final com.jogamp.common.util.locks.RecursiveLock getUpstreamLock()
getUpstreamLock in interface com.jogamp.opengl.GLAutoDrawablepublic final boolean isThreadGLCapable()
isThreadGLCapable in interface com.jogamp.opengl.GLAutoDrawablepublic void display()
display in interface com.jogamp.opengl.GLAutoDrawablepublic void destroy()
destroy in interface com.jogamp.opengl.GLAutoDrawablepublic final boolean setSurfaceScale(float[] pixelScale)
setSurfaceScale in interface com.jogamp.nativewindow.ScalableSurfacepublic final float[] getRequestedSurfaceScale(float[] result)
getRequestedSurfaceScale in interface com.jogamp.nativewindow.ScalableSurfacepublic final float[] getCurrentSurfaceScale(float[] result)
getCurrentSurfaceScale in interface com.jogamp.nativewindow.ScalableSurfacepublic float[] getMinimumSurfaceScale(float[] result)
getMinimumSurfaceScale in interface com.jogamp.nativewindow.ScalableSurfacepublic float[] getMaximumSurfaceScale(float[] result)
getMaximumSurfaceScale in interface com.jogamp.nativewindow.ScalableSurfacepublic void addNotify()
addNotify in class java.awt.ComponentaddNotify in class javax.swing.JComponentpublic void removeNotify()
removeNotify in class
 java.awt.ComponentremoveNotify in class javax.swing.JComponentpublic void reshape(int x,
                    int y,
                    int width,
                    int height)
GLDrawableHelper.reshape(com.jogamp.opengl.GLAutoDrawable, int, int, int, int) to be called on all
 registered GLEventListeners. Subclasses which override this method
 must call super.reshape() in their reshape() method in order to function
 properly.
 
reshape in class javax.swing.JComponentpublic void setupPrint(double scaleMatX,
                       double scaleMatY,
                       int numSamples,
                       int tileWidth,
                       int tileHeight)
setupPrint in interface com.jogamp.nativewindow.awt.AWTPrintLifecyclepublic void releasePrint()
releasePrint in interface com.jogamp.nativewindow.awt.AWTPrintLifecyclepublic void print(java.awt.Graphics graphics)
print in class javax.swing.JComponentpublic void setOpaque(boolean opaque)
setOpaque in class javax.swing.JComponentpublic void addGLEventListener(com.jogamp.opengl.GLEventListener listener)
addGLEventListener in interface com.jogamp.opengl.GLAutoDrawablepublic void addGLEventListener(int index,
                               com.jogamp.opengl.GLEventListener listener)
addGLEventListener in interface com.jogamp.opengl.GLAutoDrawablepublic int getGLEventListenerCount()
getGLEventListenerCount in interface com.jogamp.opengl.GLAutoDrawablepublic com.jogamp.opengl.GLEventListener getGLEventListener(int index)
                                                     throws java.lang.IndexOutOfBoundsException
getGLEventListener in interface com.jogamp.opengl.GLAutoDrawablejava.lang.IndexOutOfBoundsExceptionpublic boolean areAllGLEventListenerInitialized()
areAllGLEventListenerInitialized in interface com.jogamp.opengl.GLAutoDrawablepublic boolean getGLEventListenerInitState(com.jogamp.opengl.GLEventListener listener)
getGLEventListenerInitState in interface com.jogamp.opengl.GLAutoDrawablepublic void setGLEventListenerInitState(com.jogamp.opengl.GLEventListener listener,
                                        boolean initialized)
setGLEventListenerInitState in interface com.jogamp.opengl.GLAutoDrawablepublic com.jogamp.opengl.GLEventListener disposeGLEventListener(com.jogamp.opengl.GLEventListener listener,
                                                                boolean remove)
disposeGLEventListener in interface com.jogamp.opengl.GLAutoDrawablepublic com.jogamp.opengl.GLEventListener removeGLEventListener(com.jogamp.opengl.GLEventListener listener)
removeGLEventListener in interface com.jogamp.opengl.GLAutoDrawablepublic void setAnimator(com.jogamp.opengl.GLAnimatorControl animatorControl)
setAnimator in interface com.jogamp.opengl.GLAutoDrawablepublic com.jogamp.opengl.GLAnimatorControl getAnimator()
getAnimator in interface com.jogamp.opengl.GLAutoDrawablepublic final java.lang.Thread setExclusiveContextThread(java.lang.Thread t)
                                                 throws com.jogamp.opengl.GLException
setExclusiveContextThread in interface com.jogamp.opengl.GLAutoDrawablecom.jogamp.opengl.GLExceptionpublic final java.lang.Thread getExclusiveContextThread()
getExclusiveContextThread in interface com.jogamp.opengl.GLAutoDrawablepublic boolean invoke(boolean wait,
                      com.jogamp.opengl.GLRunnable glRunnable)
               throws java.lang.IllegalStateException
invoke in interface com.jogamp.opengl.GLAutoDrawablejava.lang.IllegalStateExceptionpublic boolean invoke(boolean wait,
                      java.util.List<com.jogamp.opengl.GLRunnable> glRunnables)
               throws java.lang.IllegalStateException
invoke in interface com.jogamp.opengl.GLAutoDrawablejava.lang.IllegalStateExceptionpublic void flushGLRunnables()
flushGLRunnables in interface com.jogamp.opengl.GLAutoDrawablepublic com.jogamp.opengl.GLContext createContext(com.jogamp.opengl.GLContext shareWith)
createContext in interface com.jogamp.opengl.GLAutoDrawablecreateContext in interface com.jogamp.opengl.GLDrawablepublic void setRealized(boolean realized)
setRealized in interface com.jogamp.opengl.GLDrawablepublic boolean isRealized()
isRealized in interface com.jogamp.opengl.GLDrawablepublic com.jogamp.opengl.GLContext setContext(com.jogamp.opengl.GLContext newCtx,
                                              boolean destroyPrevCtx)
setContext in interface com.jogamp.opengl.GLAutoDrawablepublic final com.jogamp.opengl.GLDrawable getDelegatedDrawable()
getDelegatedDrawable in interface com.jogamp.opengl.GLAutoDrawablepublic com.jogamp.opengl.GLContext getContext()
getContext in interface com.jogamp.opengl.GLAutoDrawablepublic com.jogamp.opengl.GL getGL()
getGL in interface com.jogamp.opengl.GLAutoDrawablepublic com.jogamp.opengl.GL setGL(com.jogamp.opengl.GL gl)
setGL in interface com.jogamp.opengl.GLAutoDrawablepublic void setAutoSwapBufferMode(boolean enable)
setAutoSwapBufferMode in interface com.jogamp.opengl.GLAutoDrawablepublic boolean getAutoSwapBufferMode()
getAutoSwapBufferMode in interface com.jogamp.opengl.GLAutoDrawablepublic void swapBuffers()
swapBuffers in interface com.jogamp.opengl.GLDrawablepublic void setContextCreationFlags(int flags)
setContextCreationFlags in interface com.jogamp.opengl.GLAutoDrawablepublic int getContextCreationFlags()
getContextCreationFlags in interface com.jogamp.opengl.GLAutoDrawablepublic boolean shouldPreserveColorBufferIfTranslucent()
setOpaque(false) has been called), indicates whether the application
 should preserve the OpenGL color buffer (GL_COLOR_BUFFER_BIT) for correct
 rendering of the GLJPanel and underlying widgets which may show through
 portions of the GLJPanel with alpha values less than 1. Most Swing
 implementations currently expect the GLJPanel to be completely cleared
 (e.g., by glClear(GL_COLOR_BUFFER_BIT |
    GL_DEPTH_BUFFER_BIT)), but for certain optimized Swing
 implementations which use OpenGL internally, it may be possible to perform
 OpenGL rendering using the GLJPanel into the same OpenGL drawable as the
 Swing implementation uses.public int getSurfaceWidth()
getSurfaceWidth in interface com.jogamp.opengl.GLDrawablepublic int getSurfaceHeight()
getSurfaceHeight in interface com.jogamp.opengl.GLDrawablepublic boolean isGLOriented()
 Method returns a valid value only after the backend has been
 initialized, either eagerly or
 manually via the first display call.
 Method always returns a valid value when called from within a
 GLEventListener.
 
isGLOriented in interface com.jogamp.opengl.GLDrawablepublic final void setSkipGLOrientationVerticalFlip(boolean v)
isGLOriented() based vertical flip, which usually is
 required by the offscreen backend, see details about
 vertical flip and
 FBO / GLSL vertical flip.
 
 If set to true, user needs to flip the OpenGL rendered scene
 if isGLOriented() == true, e.g. via the projection
 matrix.
 See constraints of isGLOriented().
 
public final boolean getSkipGLOrientationVerticalFlip()
public com.jogamp.opengl.GLCapabilitiesImmutable getChosenGLCapabilities()
getChosenGLCapabilities in interface com.jogamp.opengl.GLDrawablepublic final com.jogamp.opengl.GLCapabilitiesImmutable getRequestedGLCapabilities()
getRequestedGLCapabilities in interface com.jogamp.opengl.GLDrawablepublic final void setRequestedGLCapabilities(com.jogamp.opengl.GLCapabilitiesImmutable caps)
GLCapabilitiesImmutable for this GLJPanel
 allowing reconfiguration.
 
 Method shall be invoked from the AWT-EDT
 thread. In case it is not invoked on the AWT-EDT thread, an attempt is
 made to do so.
 
 Method will dispose a previous realized GLContext
 and offscreen backend!
 
caps - new capabilities.public final com.jogamp.opengl.GLProfile getGLProfile()
getGLProfile in interface com.jogamp.opengl.GLDrawablepublic com.jogamp.nativewindow.NativeSurface getNativeSurface()
getNativeSurface in interface com.jogamp.nativewindow.NativeSurfaceHoldergetNativeSurface in interface com.jogamp.opengl.GLDrawablepublic long getHandle()
getHandle in interface com.jogamp.opengl.GLDrawablepublic final com.jogamp.opengl.GLDrawableFactory getFactory()
getFactory in interface com.jogamp.opengl.GLDrawablepublic final int getTextureUnit()
If implementation uses a texture-unit, it will be known only after the first initialization, i.e. display call.
public final void setTextureUnit(int v)
display() call.
 
 Defaults to 0.
 
v - requested texture unitgetTextureUnit()public com.jogamp.nativewindow.WindowClosingProtocol.WindowClosingMode getDefaultCloseOperation()
getDefaultCloseOperation in interface com.jogamp.nativewindow.WindowClosingProtocolpublic com.jogamp.nativewindow.WindowClosingProtocol.WindowClosingMode setDefaultCloseOperation(com.jogamp.nativewindow.WindowClosingProtocol.WindowClosingMode op)
setDefaultCloseOperation in interface com.jogamp.nativewindow.WindowClosingProtocolpublic java.lang.String toString()
toString in interface com.jogamp.opengl.GLDrawabletoString in class java.awt.Component