espresso3d.engine.renderer
Class E3DGeometryRenderer

java.lang.Object
  extended byespresso3d.engine.base.E3DEngineItem
      extended byespresso3d.engine.renderer.E3DGeometryRenderer

public class E3DGeometryRenderer
extends E3DEngineItem

Author:
espresso3d This performs the raw, lowlevel geometry rendering. Usually only called by the engine itself.

Field Summary
 java.nio.FloatBuffer colorBuffer
           
static int MAX_BUFFER_SIZE
           
 java.nio.FloatBuffer texCoordBuffer
           
 java.nio.FloatBuffer texCoordDetail0Buffer
           
 java.nio.FloatBuffer texCoordDetail1Buffer
           
 java.nio.FloatBuffer vertexBuffer
           
 
Constructor Summary
E3DGeometryRenderer(E3DEngine engine)
           
 
Method Summary
 void disableAllTextureUnits()
           
 void disableArbPointSprite()
          Anytime after engine initialization, ARB point sprite rendering can be disabled.
 void initBlendedNonTexturedGeometryRenderer()
          Sets OGL environment up to render blended, non textured geometry.
 void initBlendedTexturedGeometryRenderer()
          Sets OGL environment up to render blended, textured geometry.
 void initLineRenderer()
          Sets OGL environment up to render lines Disables textures, and vertex arrays
 void initPointRenderer()
          Sets the OGL environment up to render points Disables textures, and vertex arrays
 void initSolidNonTexturedGeometryRenderer()
          Sets OGL environment up to render solid, non-textured geometry.
 void initSolidTexturedGeometryRenderer()
          Sets OGL environment up to render solid, textured geometry.
 void renderItem(E3DRenderable renderableItem)
          Automatically render an E3DRenderable
 void renderLine(E3DLine line)
           
 void renderLineList(java.util.ArrayList lineList)
           
 void renderParticle(E3DParticle particle)
           
 void renderParticleSystem(E3DParticleSystem particleSystem)
           
 void renderPoint(E3DPoint point)
          Sets up the OGL environment to render geometry with transparent portions in the texture.
 void renderPointList(java.util.ArrayList pointList)
           
 void renderQuad(E3DEngine engine, E3DQuad quad, int renderMode)
           
 void renderQuadList(E3DEngine engine, java.util.ArrayList quadList, int renderMode)
           
 void renderTriangle(E3DEngine engine, E3DTriangle triangle, int renderMode)
           
 void renderTriangleList(E3DEngine engine, java.util.ArrayList triangleList, int renderMode)
           
 void setupTextureUnits(int glTextureID, int detail0TextureID, int detail1TextureID)
           
 
Methods inherited from class espresso3d.engine.base.E3DEngineItem
getEngine, setEngine
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MAX_BUFFER_SIZE

public static final int MAX_BUFFER_SIZE
See Also:
Constant Field Values

vertexBuffer

public java.nio.FloatBuffer vertexBuffer

texCoordBuffer

public java.nio.FloatBuffer texCoordBuffer

colorBuffer

public java.nio.FloatBuffer colorBuffer

texCoordDetail0Buffer

public java.nio.FloatBuffer texCoordDetail0Buffer

texCoordDetail1Buffer

public java.nio.FloatBuffer texCoordDetail1Buffer
Constructor Detail

E3DGeometryRenderer

public E3DGeometryRenderer(E3DEngine engine)
Method Detail

disableArbPointSprite

public void disableArbPointSprite()
Anytime after engine initialization, ARB point sprite rendering can be disabled. Once disabled, it cannot be re-enabled until the next engine initialization. This is typically not necessary, but is available in case point sprites aren't giving the desired rendering effects.


renderItem

public void renderItem(E3DRenderable renderableItem)
Automatically render an E3DRenderable

Parameters:
renderableItem -

initPointRenderer

public void initPointRenderer()
Sets the OGL environment up to render points Disables textures, and vertex arrays


initLineRenderer

public void initLineRenderer()
Sets OGL environment up to render lines Disables textures, and vertex arrays


initSolidTexturedGeometryRenderer

public void initSolidTexturedGeometryRenderer()
Sets OGL environment up to render solid, textured geometry. No alpha blending occurs. Texture mapping, depth testing (GL_LEQUAL), and vertex arrays are enabled


initSolidNonTexturedGeometryRenderer

public void initSolidNonTexturedGeometryRenderer()
Sets OGL environment up to render solid, non-textured geometry. No alpha blending occurs. Depth testing (GL_LEQUAL), and vertex arrays are enabled Texture mapping is disabled


initBlendedTexturedGeometryRenderer

public void initBlendedTexturedGeometryRenderer()
Sets OGL environment up to render blended, textured geometry. Texture mapping, depth test, and vertex arrays are enabled. GL_SRC_ALPHA, GL_ONE is used for the blend function Depth mask is disabled


initBlendedNonTexturedGeometryRenderer

public void initBlendedNonTexturedGeometryRenderer()
Sets OGL environment up to render blended, non textured geometry. Depth test, and vertex arrays are enabled. GL_SRC_ALPHA, GL_ONE is used for the blend function Depth mask is disabled, Texture mapping is disabled


setupTextureUnits

public void setupTextureUnits(int glTextureID,
                              int detail0TextureID,
                              int detail1TextureID)

disableAllTextureUnits

public void disableAllTextureUnits()

renderPoint

public void renderPoint(E3DPoint point)
Sets up the OGL environment to render geometry with transparent portions in the texture.


renderPointList

public void renderPointList(java.util.ArrayList pointList)

renderLine

public void renderLine(E3DLine line)

renderLineList

public void renderLineList(java.util.ArrayList lineList)

renderTriangle

public void renderTriangle(E3DEngine engine,
                           E3DTriangle triangle,
                           int renderMode)

renderTriangleList

public void renderTriangleList(E3DEngine engine,
                               java.util.ArrayList triangleList,
                               int renderMode)

renderQuad

public void renderQuad(E3DEngine engine,
                       E3DQuad quad,
                       int renderMode)

renderQuadList

public void renderQuadList(E3DEngine engine,
                           java.util.ArrayList quadList,
                           int renderMode)

renderParticleSystem

public void renderParticleSystem(E3DParticleSystem particleSystem)

renderParticle

public void renderParticle(E3DParticle particle)