java.lang.Object
technology.sola.engine.graphics.renderer.Layer
Layers contain a queue of
DrawItem
to ensure a particular draw order.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
The default order for aDrawItem
that is added to this Layer. -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
DEFAULT_ORDER
public static final int DEFAULT_ORDERThe default order for aDrawItem
that is added to this Layer.- See Also:
-
-
Constructor Details
-
Layer
Creates a Layer with an identifier name.- Parameters:
name
- the name of the layer
-
-
Method Details
-
add
- Parameters:
drawItem
- theDrawItem
to be drawn
-
add
- Parameters:
drawItem
- theDrawItem
to be drawnorder
- higher numbers will be drawn later
-
draw
Draw this Layer to aRenderer
.- Parameters:
renderer
- theRenderer
to draw to
-
isActive
public boolean isActive()Return if this layer is active or not. A layer that is not active will not render any of itsDrawItem
s.- Returns:
- true if active
-
setActive
public void setActive(boolean isActive) Sets the active state of this layer.- Parameters:
isActive
- the new active state
-
getName
- Returns:
- the identifier name of this layer
-