Overview | Package | Class | Use | Tree | Index | Help
| NASA World Wind
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## gov.nasa.worldwind.awt
Class WorldWindowGLCanvas

    java.lang.Object
      java.awt.Component
          java.awt.Canvas
              javax.media.opengl.GLCanvas
                  gov.nasa.worldwind.awt.WorldWindowGLCanvas

All Implemented Interfaces:
  WorldWindow, ImageObserver, MenuContainer, Serializable, Accessible, ComponentEvents, GLAutoDrawable, GLDrawable

    public class WorldWindowGLCanvas

extends GLCanvas
implements WorldWindow

`WorldWindowGLCanvas` is an AWT component for displaying World Wind `Model`s (globe and layers). This implementation is a heavyweight AWT component. It derives from `GLCanvas` and therefore also provides a general `GLDrawable` for OpenGL rendering.

See Also:
  Serialized Form

Nested Class Summary

Nested classes/interfaces inherited from class java.awt.Canvas
`Canvas.AccessibleAWTCanvas`

Nested classes/interfaces inherited from class java.awt.Component
`Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy`

Field Summary

Fields inherited from class java.awt.Component
`BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT`

Fields inherited from interface java.awt.image.ImageObserver
`ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH`

Constructor Summary
`WorldWindowGLCanvas()` Constructs a new `WorldWindowGLCanvas` window on the default graphics device.
`WorldWindowGLCanvas(WorldWindowGLCanvas shareWith)` Constructs a new `WorldWindowGLCanvas` window on the default graphics device that will share graphics resources with another `WorldWindowGLCanvas` window.
`WorldWindowGLCanvas(WorldWindowGLCanvas shareWith, GraphicsDevice device)` Constructs a new `WorldWindowGLCanvas` window that will share graphics resources with another `WorldWindowGLCanvas` window.

Method Summary
`void` | `addPositionListener(PositionListener listener)`
`void` | `addRenderingListener(RenderingListener listener)`
`void` | `addSelectListener(SelectListener listener)`
`InputHandler` | `getInputHandler()`
`Model` | `getModel()` Returns the window's current model.
`SceneController` | `getSceneController()` Returns the scene controller assocciated with this instance.
`View` | `getView()` Returns this window's current view.
`PickedObjectList` | `pick(Point pickPoint)`
`void` | `removePositionListener(PositionListener listener)`
`void` | `removeRenderingListener(RenderingListener listener)`
`void` | `removeSelectListener(SelectListener listener)`
`void` | `setInputHandler(InputHandler eventSource)`
`void` | `setModel(Model model)` Sets the model to display in this window.
`void` | `setModelAndView(Model model, View view)` Sets the model to display in this window and the view used to display it.
`void` | `setView(View view)` Sets the view to use when displaying this window's model.

Methods inherited from class javax.media.opengl.GLCanvas
`addGLEventListener, addNotify, createContext, display, getAutoSwapBufferMode, getChosenGLCapabilities, getContext, getGL, paint, removeGLEventListener, removeNotify, reshape, setAutoSwapBufferMode, setGL, setRealized, swapBuffers, 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, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, deliverEvent, disable, disableEvents, dispatchEvent, doLayout, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getAlignmentX, getAlignmentY, getBackground, getBounds, getBounds, getColorModel, getComponentAt, getComponentAt, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeys, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, 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, paramString, postEvent, preferredSize, prepareImage, prepareImage, print, printAll, processComponentEvent, processEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeys, setFocusTraversalKeysEnabled, setFont, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setName, setPreferredSize, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle, validate`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Methods inherited from interface javax.media.opengl.GLAutoDrawable
`repaint`

Methods inherited from interface javax.media.opengl.GLDrawable
`getHeight, getWidth, setSize`

Methods inherited from interface javax.media.opengl.ComponentEvents
`addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, addPropertyChangeListener, addPropertyChangeListener, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener`

Constructor Detail

### WorldWindowGLCanvas

    public WorldWindowGLCanvas()

  Constructs a new `WorldWindowGLCanvas` window on the default graphics device.

### WorldWindowGLCanvas

    public WorldWindowGLCanvas(WorldWindowGLCanvas shareWith)

  Constructs a new `WorldWindowGLCanvas` window on the default graphics device that will share graphics resources with another `WorldWindowGLCanvas` window. The other window, `sharewith`, may not be null

  Parameters:
    `shareWith` - a `WorldWindowGLCanvas` with which to share graphics resources.
  Throws:
    `NullPointerException` - if shareWith is null
  See Also:
    `GLCanvas.GLCanvas(GLCapabilities,GLCapabilitiesChooser,GLContext,GraphicsDevice)`

### WorldWindowGLCanvas

    public WorldWindowGLCanvas(WorldWindowGLCanvas shareWith,
                               GraphicsDevice device)

  Constructs a new `WorldWindowGLCanvas` window that will share graphics resources with another `WorldWindowGLCanvas` window. The new window is created on the specified graphics device. Neither `shareWith` or `device` may be null.

  Parameters:
    `shareWith` - a `WorldWindowGLCanvas` with which to share graphics resources.
    `device` - the `GraphicsDevice` on which to create the window.
  Throws:
    `NullPointerException` - if `shareWith` is null
    `IllegalArgumentException` - if `deevice` is null
  See Also:
    `GLCanvas.GLCanvas(GLCapabilities,GLCapabilitiesChooser,GLContext,GraphicsDevice)`

Method Detail

### addPositionListener

    public void addPositionListener(PositionListener listener)

  Specified by:
    `addPositionListener` in interface `WorldWindow`

### addRenderingListener

    public void addRenderingListener(RenderingListener listener)

  Specified by:
    `addRenderingListener` in interface `WorldWindow`

### addSelectListener

    public void addSelectListener(SelectListener listener)

  Specified by:
    `addSelectListener` in interface `WorldWindow`

### getInputHandler

    public InputHandler getInputHandler()

  Specified by:
    `getInputHandler` in interface `WorldWindow`

### getModel

    public Model getModel()

  Description copied from interface: `WorldWindow`
  Returns the window's current model.

  Specified by:
    `getModel` in interface `WorldWindow`
  Returns:
    the window's current model

### getSceneController

    public SceneController getSceneController()

  Description copied from interface: `WorldWindow`
  Returns the scene controller assocciated with this instance.

  Specified by:
    `getSceneController` in interface `WorldWindow`
  Returns:
    The scene controller associated with the instance, or null if no scene controller is associated.

### getView

    public View getView()

  Description copied from interface: `WorldWindow`
  Returns this window's current view.

  Specified by:
    `getView` in interface `WorldWindow`
  Returns:
    the window's current view

### pick

    public PickedObjectList pick(Point pickPoint)

  Specified by:
    `pick` in interface `WorldWindow`

### removePositionListener

    public void removePositionListener(PositionListener listener)

  Specified by:
    `removePositionListener` in interface `WorldWindow`

### removeRenderingListener

    public void removeRenderingListener(RenderingListener listener)

  Specified by:
    `removeRenderingListener` in interface `WorldWindow`

### removeSelectListener

    public void removeSelectListener(SelectListener listener)

  Specified by:
    `removeSelectListener` in interface `WorldWindow`

### setInputHandler

    public void setInputHandler(InputHandler eventSource)

  Specified by:
    `setInputHandler` in interface `WorldWindow`

### setModel

    public void setModel(Model model)

  Description copied from interface: `WorldWindow`
  Sets the model to display in this window. If `null` is specified for the model, the current model, if any, is disassociated with the window.

  Specified by:
    `setModel` in interface `WorldWindow`
  Parameters:
    `model` - the model to display. May be `null`.

### setModelAndView

    public void setModelAndView(Model model,
                                View view)

  Description copied from interface: `WorldWindow`
  Sets the model to display in this window and the view used to display it. If `null` is specified for the model, the current model, if any, is disassociated with the window. If `null` is specified for the view, the current view, if any, is disassociated with the window.

  Specified by:
    `setModelAndView` in interface `WorldWindow`
  Parameters:
    `model` - the model to display. May be`null`.
    `view` - the view to use to display this window's model. May be`null`.

### setView

    public void setView(View view)

  Description copied from interface: `WorldWindow`
  Sets the view to use when displaying this window's model. If `null` is specified for the view, the current view, if any, is disassociated with the window.

  Specified by:
    `setView` in interface `WorldWindow`
  Parameters:
    `view` - the view to use to display this window's model. May be null.

Overview | Package | Class | Use | Tree | Index | Help
| NASA World Wind
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD