|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
javax.media.opengl.GLJPanel
gov.nasa.worldwind.awt.WorldWindowGLJPanel
public class WorldWindowGLJPanel
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.swing.JPanel |
|---|
JPanel.AccessibleJPanel |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary |
|---|
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| 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 | |
|---|---|
WorldWindowGLJPanel()
Constructs a new WorldWindowGLCanvas window on the default graphics device. |
|
WorldWindowGLJPanel(WorldWindowGLCanvas shareWith)
Constructs a new WorldWindowGLJPanel window on the default graphics device that will share graphics
resources with another WorldWindowGLJPanel window. |
|
WorldWindowGLJPanel(WorldWindowGLCanvas shareWith,
GraphicsDevice device)
Constructs a new WorldWindowGLJPanel window that will share graphics resources with another
WorldWindowGLJPanel window. |
|
| Method Summary | |
|---|---|
void |
addPositionListener(PositionListener listener)
Adds a position listener to this world window. |
void |
addRenderingListener(RenderingListener listener)
Adds a rendering listener to this world window. |
void |
addSelectListener(SelectListener listener)
Adds a select listener to this world window. |
AVList |
clearList()
|
AVList |
copy()
Returns a shallow copy of this AVList instance: the keys and values themselves are not cloned. |
void |
firePropertyChange(PropertyChangeEvent propertyChangeEvent)
Calls all registered property change listeners with the specified property change event. |
void |
firePropertyChange(String propertyName,
Object oldValue,
Object newValue)
Calls all property change listeners associated with the specified key. |
Position |
getCurrentPosition()
Returns the current latitude, longitude and altitude of the current cursor position, or null if the
cursor is not on the globe. |
Set<Map.Entry<String,Object>> |
getEntries()
|
InputHandler |
getInputHandler()
Returns the input handler associated with this instance. |
Model |
getModel()
Returns the window's current model. |
PickedObjectList |
getObjectsAtCurrentPosition()
Returns the World Wind ojbects at the current cursor position. |
Collection<PerformanceStatistic> |
getPerFrameStatistics()
Returns the active per-frame performance statistics such as number of tiles drawn in the most recent frame. |
SceneController |
getSceneController()
Returns the scene controller assocciated with this instance. |
String |
getStringValue(String key)
Returns the value for a specified key. |
TextureCache |
getTextureCache()
Returns the texture cache used by this World Window. |
Object |
getValue(String key)
Returns the value for a specified key. |
Collection<Object> |
getValues()
|
View |
getView()
Returns this window's current view. |
boolean |
hasKey(String key)
Indicates whether a key is in the collection. |
void |
redraw()
Causes a repaint event to be enqued with the window system for this world window. |
void |
redrawNow()
Immediately repaints the world window without waiting for a window system repaint event. |
void |
removeKey(String key)
Removes a specified key from the collection if the key exists, otherwise returns without affecting the collection. |
void |
removePositionListener(PositionListener listener)
Removes the specified position listener associated with this world window. |
void |
removeRenderingListener(RenderingListener listener)
Removes a specified rendering listener associated with this world window. |
void |
removeSelectListener(SelectListener listener)
Removes the specified select listener associated with this world window. |
void |
setInputHandler(InputHandler inputHandler)
Sets the input handler to use for this instance. |
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 |
setPerFrameStatisticsKeys(Set<String> keys)
Activates the per-frame performance statistic specified. |
void |
setValue(String key,
Object value)
Adds a key/value pair to the list. |
void |
setValues(AVList avList)
|
void |
setView(View view)
Sets the view to use when displaying this window's model. |
void |
shutdown()
Causes resources used by the World Window to be freed. |
| Methods inherited from class javax.media.opengl.GLJPanel |
|---|
addGLEventListener, addNotify, createContext, display, getAutoSwapBufferMode, getChosenGLCapabilities, getContext, getGL, paintComponent, removeGLEventListener, removeNotify, reshape, setAutoSwapBufferMode, setGL, setOpaque, setRealized, shouldPreserveColorBufferIfTranslucent, swapBuffers |
| Methods inherited from class javax.swing.JPanel |
|---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface gov.nasa.worldwind.avlist.AVList |
|---|
addPropertyChangeListener, addPropertyChangeListener, removePropertyChangeListener, removePropertyChangeListener |
| Methods inherited from interface javax.media.opengl.GLAutoDrawable |
|---|
repaint |
| Methods inherited from interface javax.media.opengl.GLDrawable |
|---|
getHeight, getWidth, setSize |
| Constructor Detail |
|---|
public WorldWindowGLJPanel()
WorldWindowGLCanvas window on the default graphics device.
public WorldWindowGLJPanel(WorldWindowGLCanvas shareWith)
WorldWindowGLJPanel window on the default graphics device that will share graphics
resources with another WorldWindowGLJPanel window. The other window, sharewith, may not be
null
shareWith - a WorldWindowGLJPanel with which to share graphics resources.
NullPointerException - if shareWith is nullGLCanvas.GLCanvas(GLCapabilities,GLCapabilitiesChooser,GLContext,GraphicsDevice)
public WorldWindowGLJPanel(WorldWindowGLCanvas shareWith,
GraphicsDevice device)
WorldWindowGLJPanel window that will share graphics resources with another
WorldWindowGLJPanel window. The new window is created on the specified graphics device. Neither
shareWith or device may be null.
shareWith - a WorldWindowGLCanvas with which to share graphics resources.device - the GraphicsDevice on which to create the window.
NullPointerException - if shareWith is null
IllegalArgumentException - if deevice is nullGLCanvas.GLCanvas(GLCapabilities,GLCapabilitiesChooser,GLContext,GraphicsDevice)| Method Detail |
|---|
public void addPositionListener(PositionListener listener)
WorldWindow
addPositionListener in interface WorldWindowlistener - The position listener to add.public void addRenderingListener(RenderingListener listener)
WorldWindow
addRenderingListener in interface WorldWindowlistener - The rendering listener to add to those notified of rendering events by this world window.public void addSelectListener(SelectListener listener)
WorldWindow
addSelectListener in interface WorldWindowlistener - The select listener to add.public AVList clearList()
clearList in interface AVListpublic AVList copy()
AVListAVList instance: the keys and values themselves are not cloned.
copy in interface AVListAVList.public void firePropertyChange(PropertyChangeEvent propertyChangeEvent)
AVList
firePropertyChange in interface AVListpropertyChangeEvent - the eventPropertyChangeSupport
public void firePropertyChange(String propertyName,
Object oldValue,
Object newValue)
AVListodValue and newValue are equal and non-null.
firePropertyChange in interface AVListfirePropertyChange in class ComponentpropertyName - the keyoldValue - the value associated with the key before the even causing the firing.newValue - the new value associated with the key.PropertyChangeSupportpublic Position getCurrentPosition()
WorldWindownull if the
cursor is not on the globe.
getCurrentPosition in interface WorldWindownull if the cursor is not positioned on the globe.public Set<Map.Entry<String,Object>> getEntries()
getEntries in interface AVListpublic InputHandler getInputHandler()
WorldWindow
getInputHandler in interface WorldWindownull if no input handler is associated.public Model getModel()
WorldWindow
getModel in interface WorldWindowpublic PickedObjectList getObjectsAtCurrentPosition()
WorldWindow
getObjectsAtCurrentPosition in interface WorldWindownull if no objects are under the cursor.public Collection<PerformanceStatistic> getPerFrameStatistics()
WorldWindow
getPerFrameStatistics in interface WorldWindowpublic SceneController getSceneController()
WorldWindow
getSceneController in interface WorldWindownull if no scene controller is
associated.public String getStringValue(String key)
AVListString.
getStringValue in interface AVListkey - the attribute name. May not be null.
null.public TextureCache getTextureCache()
WorldWindow
getTextureCache in interface WorldWindowpublic Object getValue(String key)
AVList
getValue in interface AVListkey - the attribute name. May not be null.
null.public Collection<Object> getValues()
getValues in interface AVListpublic View getView()
WorldWindow
getView in interface WorldWindowpublic boolean hasKey(String key)
AVList
hasKey in interface AVListkey - the attribute name. May not be null.
true if the key exists in the collection, otherwise false.public void redraw()
WorldWindow
redraw in interface WorldWindowpublic void redrawNow()
WorldWindow
redrawNow in interface WorldWindowpublic void removeKey(String key)
AVList
removeKey in interface AVListkey - the attribute name. May not be null.public void removePositionListener(PositionListener listener)
WorldWindow
removePositionListener in interface WorldWindowlistener - The listener to remove.public void removeRenderingListener(RenderingListener listener)
WorldWindow
removeRenderingListener in interface WorldWindowlistener - The rendering listener to remove.public void removeSelectListener(SelectListener listener)
WorldWindow
removeSelectListener in interface WorldWindowlistener - The select listener to remove.public void setInputHandler(InputHandler inputHandler)
WorldWindow
setInputHandler in interface WorldWindowinputHandler - The input handler to use for this world window. May by null if null
is specified, the current input handler, if any, is disassociated with the world window.public void setModel(Model model)
WorldWindownull is specified for the model, the current model, if
any, is disassociated with the window.
setModel in interface WorldWindowmodel - the model to display. May be null.
public void setModelAndView(Model model,
View view)
WorldWindownull 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.
setModelAndView in interface WorldWindowmodel - the model to display. May benull.view - the view to use to display this window's model. May benull.public void setPerFrameStatisticsKeys(Set<String> keys)
WorldWindow
setPerFrameStatisticsKeys in interface WorldWindowkeys - The statistics to activate.
public void setValue(String key,
Object value)
AVList
setValue in interface AVListkey - the attribute name. May not be null.value - the attribute value. May be null, in which case any existing value for the key is
removed from the collection.public void setValues(AVList avList)
setValues in interface AVListpublic void setView(View view)
WorldWindownull is specified for the view, the
current view, if any, is disassociated with the window.
setView in interface WorldWindowview - the view to use to display this window's model. May be null.public void shutdown()
WorldWindow
shutdown in interface WorldWindow
|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||