org.xith3d.scenegraph
Class Texture2DCanvas.DrawCallback2D

java.lang.Object
  extended by org.xith3d.scenegraph.Texture2DCanvas.DrawCallback2D
Enclosing class:
Texture2DCanvas

public abstract static class Texture2DCanvas.DrawCallback2D
extends java.lang.Object


Constructor Summary
Texture2DCanvas.DrawCallback2D()
           
 
Method Summary
abstract  void drawTexture(Texture2DCanvas texCanvas, int texWidth, int texHeight)
          This callback is invoked, when the Texture needs to be redrawn.
 boolean needsRedraw(long nanoTime)
          Checks, if this callback needs to be redrawn.
 void setDirty(boolean dirty)
          Marks this draw callback dirty.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Texture2DCanvas.DrawCallback2D

public Texture2DCanvas.DrawCallback2D()
Method Detail

setDirty

public void setDirty(boolean dirty)
Marks this draw callback dirty. This tells the render system to call the drawTexture(Texture2DCanvas, int, int) method.

Parameters:
dirty -

needsRedraw

public boolean needsRedraw(long nanoTime)
Checks, if this callback needs to be redrawn.

Parameters:
nanoTime -
Returns:
true, if the texture should be redrawn.

drawTexture

public abstract void drawTexture(Texture2DCanvas texCanvas,
                                 int texWidth,
                                 int texHeight)
This callback is invoked, when the Texture needs to be redrawn.

Parameters:
texCanvas - the Texture2DCanvas to draw on.
texWidth - the (original) width of the texture
texHeight - the (original) height of the texture