com.threerings.opengl.util
Class SimpleOverlay

java.lang.Object
  extended by com.threerings.opengl.util.SimpleRenderable
      extended by com.threerings.opengl.util.SimpleOverlay
All Implemented Interfaces:
Compositable, Enqueueable
Direct Known Subclasses:
Compass, Root, Stats

public abstract class SimpleOverlay
extends SimpleRenderable

A base class for simple overlays that draw themselves in immediate mode.


Field Summary
 
Fields inherited from class com.threerings.opengl.util.SimpleRenderable
_batch, _ctx, _priority, _queue
 
Constructor Summary
SimpleOverlay(GlContext ctx)
          Creates a new simple overlay.
SimpleOverlay(GlContext ctx, String queue)
          Creates a new simple overlay.
SimpleOverlay(GlContext ctx, String queue, int priority)
          Creates a new simple overlay.
SimpleOverlay(GlContext ctx, String queue, int priority, boolean modifiesColorState, int primitiveCount)
          Creates a new simple overlay.
 
Method Summary
 void composite()
          Adds this object's Dependencys and Enqueueables to the compositor in preparation for rendering.
protected  RenderState[] createStates()
          Creates the state set for this object.
 
Methods inherited from class com.threerings.opengl.util.SimpleRenderable
createBatch, draw, enqueue, getStates
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleOverlay

public SimpleOverlay(GlContext ctx)
Creates a new simple overlay.


SimpleOverlay

public SimpleOverlay(GlContext ctx,
                     String queue)
Creates a new simple overlay.

Parameters:
queue - the name of the queue into which we place the batch.

SimpleOverlay

public SimpleOverlay(GlContext ctx,
                     String queue,
                     int priority)
Creates a new simple overlay.

Parameters:
queue - the name of the queue into which we place the batch.
priority - the priority level at which to enqueue the batch.

SimpleOverlay

public SimpleOverlay(GlContext ctx,
                     String queue,
                     int priority,
                     boolean modifiesColorState,
                     int primitiveCount)
Creates a new simple overlay.

Parameters:
queue - the name of the queue into which we place the batch.
priority - the priority level at which to enqueue the batch.
modifiesColorState - if true, invalidate the color state after calling the SimpleRenderable.draw() method.
primitiveCount - the primitive count to report to the renderer.
Method Detail

composite

public void composite()
Description copied from interface: Compositable
Adds this object's Dependencys and Enqueueables to the compositor in preparation for rendering.

Specified by:
composite in interface Compositable
Overrides:
composite in class SimpleRenderable

createStates

protected RenderState[] createStates()
Description copied from class: SimpleRenderable
Creates the state set for this object.

Overrides:
createStates in class SimpleRenderable