de.enough.polish.graphics3d.gles.nodes
Class Quad

java.lang.Object
  extended by de.enough.polish.graphics3d.gles.nodes.Actorx
      extended by de.enough.polish.graphics3d.gles.nodes.Quad

public class Quad
extends Actorx

Quad shape node

Optionally supporting 2d texture

Author:
Anders Bo Pedersen, anders@wicore.dk

Field Summary
protected  javax.microedition.khronos.opengles.GL11 gl11
           
static byte[] QUAD_TEXT_COORDS
           
static byte[] QUAD_VERTS
           
protected  java.nio.ByteBuffer texBuf
           
protected  java.nio.ByteBuffer texCordsBuf
           
protected  int texHeight
           
protected  int[] texName
           
protected  int texWidth
           
protected  java.nio.ByteBuffer vertBuf
           
 
Fields inherited from class de.enough.polish.graphics3d.gles.nodes.Actorx
children, gl10, parent, rXx, rYx, rZx, sXx, sYx, sZx, tXx, tYx, tZx
 
Constructor Summary
Quad(javax.microedition.khronos.opengles.GL gl)
           
Quad(javax.microedition.khronos.opengles.GL gl, Image texture)
           
 
Method Summary
protected  void renderActor()
           
 void setTexture(Image img)
           
 void setTexture(String path)
           
protected  void updateActor()
           
 
Methods inherited from class de.enough.polish.graphics3d.gles.nodes.Actorx
addChild, getChild, getNumChildren, removeChild, removeChild, render, setRotateXx, setRotateYx, setRotateZx, setScalex, setTranslationx, toString, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

QUAD_VERTS

public static final byte[] QUAD_VERTS

QUAD_TEXT_COORDS

public static final byte[] QUAD_TEXT_COORDS

vertBuf

protected java.nio.ByteBuffer vertBuf

texCordsBuf

protected java.nio.ByteBuffer texCordsBuf

texBuf

protected java.nio.ByteBuffer texBuf

texName

protected int[] texName

texWidth

protected int texWidth

texHeight

protected int texHeight

gl11

protected javax.microedition.khronos.opengles.GL11 gl11
Constructor Detail

Quad

public Quad(javax.microedition.khronos.opengles.GL gl)

Quad

public Quad(javax.microedition.khronos.opengles.GL gl,
            Image texture)
Method Detail

setTexture

public void setTexture(String path)

setTexture

public void setTexture(Image img)

renderActor

protected void renderActor()
Specified by:
renderActor in class Actorx

updateActor

protected void updateActor()
Specified by:
updateActor in class Actorx