Class AbstractDisplayLayerOGL2D<S>
java.lang.Object
repast.simphony.visualizationOGL2D.AbstractDisplayLayerOGL2D<S>
- Record Components:
S- the Style type
- All Implemented Interfaces:
IDisplayLayer<saf.v3d.scene.VSpatial>
- Direct Known Subclasses:
NetworkLayerOGL2D,StyledDisplayLayerOGL2D
public abstract class AbstractDisplayLayerOGL2D<S>
extends Object
implements IDisplayLayer<saf.v3d.scene.VSpatial>
Abstract base class for OGL2D display layers.
- Author:
- Nick Collier
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds the specified object to the layer.voidNo-op for ogl based code as the displaying the GLAutoDrawable will reflect the updates.getStyle()Gets the style used by this display layer.saf.v3d.scene.VSpatialgetVisualItem(Object obj) Gets the visual item that represents the specified object in the display.voidremoveObject(Object obj) Removes this specified object from this layer.voidSets the style used by this display layer.abstract voidupdate(LayoutUpdater updater) Updates the displayed nodes by applying styles etc.
-
Field Details
-
MODEL_OBJECT_KEY
- See Also:
-
LABEL_KEY
- See Also:
-
style
-
layer
protected saf.v3d.scene.VLayer layer -
toBeAdded
-
toBeRemoved
-
objMap
-
labelLayers
-
-
Constructor Details
-
AbstractDisplayLayerOGL2D
-
-
Method Details
-
getStyle
Gets the style used by this display layer.- Returns:
- the style used by this display layer.
-
setStyle
Sets the style used by this display layer.- Parameters:
style- the new style
-
addObject
Description copied from interface:IDisplayLayerAdds the specified object to the layer.- Specified by:
addObjectin interfaceIDisplayLayer<S>- Parameters:
obj- the object to add
-
applyUpdates
public void applyUpdates()No-op for ogl based code as the displaying the GLAutoDrawable will reflect the updates. Nothing needs to be done here.- Specified by:
applyUpdatesin interfaceIDisplayLayer<S>
-
getVisualItem
Gets the visual item that represents the specified object in the display.- Specified by:
getVisualItemin interfaceIDisplayLayer<S>- Parameters:
obj- the object whose visual representation we want to get- Returns:
- the visual item that represents the specified object in the display.
-
removeObject
Removes this specified object from this layer.- Specified by:
removeObjectin interfaceIDisplayLayer<S>- Parameters:
obj- the object to remove
-
update
Updates the displayed nodes by applying styles etc. The display is not updated to reflect these changes.- Specified by:
updatein interfaceIDisplayLayer<S>- Parameters:
updater- used to update the layout and position information
-