Class RenderArea

  • All Implemented Interfaces:
    com.jogamp.nativewindow.awt.AWTPrintLifecycle, com.jogamp.nativewindow.OffscreenLayerOption, com.jogamp.nativewindow.WindowClosingProtocol, com.jogamp.opengl.GLEventListener, IRenderArea, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible
    Direct Known Subclasses:
    RenderAreaInteractive

    public class RenderArea
    extends com.jogamp.newt.awt.NewtCanvasAWT
    implements com.jogamp.opengl.GLEventListener, IRenderArea
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.awt.Component

        java.awt.Component.BaselineResizeBehavior
      • Nested classes/interfaces inherited from interface com.jogamp.nativewindow.awt.AWTPrintLifecycle

        com.jogamp.nativewindow.awt.AWTPrintLifecycle.Context
      • Nested classes/interfaces inherited from interface com.jogamp.nativewindow.WindowClosingProtocol

        com.jogamp.nativewindow.WindowClosingProtocol.WindowClosingMode
    • Field Summary

      • Fields inherited from class com.jogamp.newt.awt.NewtCanvasAWT

        DEBUG
      • Fields inherited from class java.awt.Component

        BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
      • Fields inherited from interface com.jogamp.nativewindow.awt.AWTPrintLifecycle

        DEFAULT_PRINT_TILE_SIZE
      • Fields inherited from interface java.awt.image.ImageObserver

        ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
    • Constructor Summary

      Constructors 
      Constructor Description
      RenderArea()  
      RenderArea​(boolean enableStereo)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void activateStereo​(boolean activated)
      Activates or deactivates raw stereo.
      void display​(com.jogamp.opengl.GLAutoDrawable drawable)  
      void dispose()
      Dispose area resources.
      void dispose​(com.jogamp.opengl.GLAutoDrawable drawable)  
      SoSceneManager.AntialiasingModes getAntialiasingMode()
      Gets the antialiasing mode.
      float getAntialiasingQuality()
      Gets the antialiasing quality value.
      java.awt.Canvas getComponent()
      Gets the parent component of this render area.
      SoGLRenderAction getGLRenderAction()
      Gets the GLRenderAction used for rendering.
      int getStillSuperSamplingDelay()
      Gets delay for supersampling when "still" (not interacting).
      float getStillSuperSamplingQuality()
      Gets quality for supersampling when "still" (not interacting).
      SoGLRenderAction.TransparencyTypes getTransparencyType()
      Gets the global transparency algorithm to use when rendering.
      void init​(com.jogamp.opengl.GLAutoDrawable drawable)  
      boolean isRawStereoAvailable()
      Gets availability of raw stereo.
      void reshape​(com.jogamp.opengl.GLAutoDrawable drawable, int x, int y, int width, int height)  
      void scheduleRedraw()
      Schedules a redraw for some time in the near future.
      void setAntialiasingMode​(SoSceneManager.AntialiasingModes mode)
      Sets the antialiasing mode.
      void setAntialiasingQuality​(float quality)
      Sets the antialiasing quality value.
      void setGLRenderAction​(SoGLRenderAction ra)
      Sets the GLRenderAction used for rendering.
      void setSceneGraph​(SoNode sceneGraph)
      Sets the scene graph.
      void setStillSuperSamplingDelay​(int delay)
      Sets delay for supersampling when "still" (not interacting).
      void setStillSuperSamplingQuality​(float quality)
      Sets quality for supersampling when "still" (not interacting).
      void setTransparencyType​(SoGLRenderAction.TransparencyTypes type)
      Sets the global transparency algorithm to use when rendering.
      • Methods inherited from class com.jogamp.newt.awt.NewtCanvasAWT

        addNotify, destroy, getDefaultCloseOperation, getGraphicsConfiguration, getNativeWindow, getNEWTChild, getShallUseOffscreenLayer, getSkipJAWTDestroy, isApplet, isAWTEventPassThrough, isOffscreenLayerSurfaceEnabled, paint, print, releasePrint, removeNotify, reshape, setDefaultCloseOperation, setNEWTChild, setShallUseOffscreenLayer, setSkipJAWTDestroy, setupPrint, update
      • Methods inherited from class java.awt.Canvas

        createBufferStrategy, createBufferStrategy, getAccessibleContext, getBufferStrategy
      • Methods inherited from class java.awt.Component

        action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, bounds, checkImage, checkImage, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, deliverEvent, disable, dispatchEvent, doLayout, enable, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getAlignmentX, getAlignmentY, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentAt, getComponentAt, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeys, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, invalidate, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusCycleRoot, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, layout, list, list, list, list, list, locate, location, lostFocus, minimumSize, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, preferredSize, prepareImage, prepareImage, printAll, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeys, setFocusTraversalKeysEnabled, setFont, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setMixingCutoutShape, setName, setPreferredSize, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle, validate
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • RenderArea

        public RenderArea()
      • RenderArea

        public RenderArea​(boolean enableStereo)
    • Method Detail

      • setGLRenderAction

        public void setGLRenderAction​(SoGLRenderAction ra)
        Description copied from interface: IRenderArea
        Sets the GLRenderAction used for rendering.
        Specified by:
        setGLRenderAction in interface IRenderArea
        Parameters:
        ra - the GLRenderAction used for rendering
      • getAntialiasingQuality

        public float getAntialiasingQuality()
        Description copied from interface: IRenderArea
        Gets the antialiasing quality value.
        Specified by:
        getAntialiasingQuality in interface IRenderArea
        Returns:
        the antialiasing quality, factor in the range [0.0,1.0].
      • setAntialiasingQuality

        public void setAntialiasingQuality​(float quality)
        Description copied from interface: IRenderArea
        Sets the antialiasing quality value.

        Default value is 0.0. The value 0.0 turns off antialiasing.

        Specified by:
        setAntialiasingQuality in interface IRenderArea
        Parameters:
        quality - The quality is a factor in the range [0.0,1.0].
      • getStillSuperSamplingQuality

        public float getStillSuperSamplingQuality()
        Description copied from interface: IRenderArea
        Gets quality for supersampling when "still" (not interacting).
        Specified by:
        getStillSuperSamplingQuality in interface IRenderArea
        Returns:
        the quality for supersampling, factor in the range [0.0,1.0].
      • setStillSuperSamplingQuality

        public void setStillSuperSamplingQuality​(float quality)
        Description copied from interface: IRenderArea
        Sets quality for supersampling when "still" (not interacting).

        When quality is greater than 0, still images will be automatically supersampled. Default value is 0.0. Use the value 0.0 to turn off still supersampling. 0.5 is a typical value.

        Specified by:
        setStillSuperSamplingQuality in interface IRenderArea
        Parameters:
        quality - The quality is a factor in the range [0.0,1.0].
      • getStillSuperSamplingDelay

        public int getStillSuperSamplingDelay()
        Description copied from interface: IRenderArea
        Gets delay for supersampling when "still" (not interacting).
        Specified by:
        getStillSuperSamplingDelay in interface IRenderArea
        Returns:
        the delay for supersampling in milliseconds.
      • setStillSuperSamplingDelay

        public void setStillSuperSamplingDelay​(int delay)
        Description copied from interface: IRenderArea
        Sets delay for supersampling when "still" (not interacting).

        If greater than 0, images will be supersampled after the specified delay. Default value is 0. The delay is in milliseconds.

        Specified by:
        setStillSuperSamplingDelay in interface IRenderArea
        Parameters:
        delay - The delay for supersampling in milliseconds.
      • getComponent

        public java.awt.Canvas getComponent()
        Description copied from interface: IRenderArea
        Gets the parent component of this render area.
        Specified by:
        getComponent in interface IRenderArea
        Returns:
        the parent component
      • activateStereo

        public void activateStereo​(boolean activated)
        Description copied from interface: IRenderArea
        Activates or deactivates raw stereo.
        Specified by:
        activateStereo in interface IRenderArea
        Parameters:
        activated - true to activate raw stereo
      • isRawStereoAvailable

        public boolean isRawStereoAvailable()
        Description copied from interface: IRenderArea
        Gets availability of raw stereo.
        Specified by:
        isRawStereoAvailable in interface IRenderArea
        Returns:
        true if the raw stereo is available
      • setSceneGraph

        public void setSceneGraph​(SoNode sceneGraph)
        Description copied from interface: IRenderArea
        Sets the scene graph. This is the Open Inventor scene which will be traversed for rendering and event processing.
        Specified by:
        setSceneGraph in interface IRenderArea
        Parameters:
        sceneGraph - the scene graph
      • scheduleRedraw

        public void scheduleRedraw()
        Description copied from interface: IRenderArea
        Schedules a redraw for some time in the near future.
        Specified by:
        scheduleRedraw in interface IRenderArea
      • init

        public void init​(com.jogamp.opengl.GLAutoDrawable drawable)
        Specified by:
        init in interface com.jogamp.opengl.GLEventListener
      • dispose

        public void dispose​(com.jogamp.opengl.GLAutoDrawable drawable)
        Specified by:
        dispose in interface com.jogamp.opengl.GLEventListener
      • dispose

        public void dispose()
        Description copied from interface: IRenderArea
        Dispose area resources.
        Specified by:
        dispose in interface IRenderArea
      • display

        public void display​(com.jogamp.opengl.GLAutoDrawable drawable)
        Specified by:
        display in interface com.jogamp.opengl.GLEventListener
      • reshape

        public void reshape​(com.jogamp.opengl.GLAutoDrawable drawable,
                            int x,
                            int y,
                            int width,
                            int height)
        Specified by:
        reshape in interface com.jogamp.opengl.GLEventListener