Class dnx.ice.DNXRendGraphics3D
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class dnx.ice.DNXRendGraphics3D

java.lang.Object
   |
   +----dnx.ice.Graphics3D
           |
           +----dnx.ice.DNXRendGraphics3D

public class DNXRendGraphics3D
extends Graphics3D
A Graphics3D object encapsulates a framebuffer and state used in 3D rendering. It is a fairly low-level interface to whatever native 3D graphics system a platform provides.

Method Index

 o accumLoad(float)
Similar to accumulate, except that the values in the accumulation buffer are replaced with the contents of the color buffer multiplied by value.
 o accumMult(float)
Multiply the contents of the accumulation buffer by value.
 o accumReturn(float)
Multiply the contents of the accumulation buffer by value and load them into the color buffer.
 o accumulate(float)
Multiply the contents of the color buffer by value and add to the accumulation buffer.
 o beginRendering()
beginRendering must be called before rendering models.
 o clear(int)
Clear one or more buffers; the buffers parameter specifies which buffers will be cleared.
 o concatModelMatrix(Matrix4)
Push the product of a matrix and the current model matrix onto the stack
 o copyBuffers(Graphics3D, int)
Copy buffers from one viewport to another.
 o copyRect(Rectangle, int, int)
 o disableBackfaceCulling()
Disable back face culling.
 o disableFeature(int)
 o disableTwoSidedLighting()
Disable two-sided lighting.
 o doSetClearColor(int)
 o drawImage()
 o drawRect(Rectangle, Color)
 o drawRect(Rectangle, Color, float)
 o enableBackfaceCulling()
Enable back face culling.
 o enableFeature(int)
 o enableTwoSidedLighting()
Enable two-sided lighting calculations.
 o endRendering()
endRendering must be called after all models have been rendered and before paint is called.
 o finalize()
 o getModelMatrix(Matrix4)
Load the current model matrix into m.
 o getTextureMatrix(Matrix4)
Load the current texture matrix into m.
 o loadModelMatrix(Matrix4)
Push a transformation onto the model matrix stack.
 o loadTextureMatrix(Matrix4)
Push a transformation onto the texture transformation stack.
 o location()
 o paint(Graphics, int, int)
 o popLight()
Remove the top light off the light stack.
 o popModelMatrix()
Pop a transformation off the model transformation stack.
 o pushLight(Light)
Push a light onto the light stack.
 o rayPick(Model, Ray3, PickResult)
 o render(Model)
Render a model.
 o resetLights()
Remove all lights from the stack.
 o resetModelMatrix()
Pop all model transformations off the stack and set the current model transformation to the identity.
 o resize(Dimension)
Resize to the specified dimension
 o resize(int, int)
Resize to the specified height and width
 o rotateModel(float, float, float, float)
Rotate the model by angle radians about the axis [ ax, ay, az]
 o rotateModel(Quaternion)
 o scaleModel(float)
Scale the model uniformly on all axes
 o scaleModel(float, float, float)
Scale the model
 o setClearColor(Color)
Set the color to which the color buffer will be cleared when the clear method is invoked.
 o setClearColor(float, float, float)
Set the color to which the color buffer will be cleared when the clear method is invoked.
 o setClearDepth(float)
Set the depth to which the depth buffer will be cleared when the clear method is invoked.
 o setColorBufferMask(int)
 o setDepthBufferMask(int)
Enable or disable reading from or writing to the depth buffer.
 o setFog(Fog)
Set the type of fog (i.e.
 o setMaterial(Material)
Set the current material
 o setModelRenderMode(int)
 o setModifiedMaterialColor(int)
Set the material component which will be modified by per-vertex and per-face colors in models.
 o setProjection(Projection)
Set the camera projection
 o setShadeMode(int)
Set the shade mode.
 o setTextureBlendMode(int)
 o setTextureCoordinateGeneration(TextureCoordinateGenerator)
Set the rules for automatically generating texture coordinates
 o setTextureFilter(int)
 o setTextureWrapping(boolean, boolean)
 o size()
Return the dimensions
 o translateModel(float, float, float)
Translate the model
 o useTexture(Texture)
Set the texture to be used when rendering models containing texture coordinates.

Methods

 o paint
  public void paint(Graphics g,
                    int x,
                    int y)
Overrides:
paint in class Graphics3D
 o beginRendering
  public void beginRendering()
beginRendering must be called before rendering models.
Overrides:
beginRendering in class Graphics3D
 o endRendering
  public void endRendering()
endRendering must be called after all models have been rendered and before paint is called.
Overrides:
endRendering in class Graphics3D
 o render
  public void render(Model model)
Render a model.
Overrides:
render in class Graphics3D
 o rayPick
  public boolean rayPick(Model model,
                         Ray3 ray,
                         PickResult result)
Overrides:
rayPick in class Graphics3D
 o size
  public Dimension size()
Return the dimensions
Overrides:
size in class Graphics3D
 o location
  public Point location()
Overrides:
location in class Graphics3D
 o resize
  public void resize(Dimension d)
Resize to the specified dimension
Overrides:
resize in class Graphics3D
 o resize
  public void resize(int width,
                     int height)
Resize to the specified height and width
Overrides:
resize in class Graphics3D
 o concatModelMatrix
  public void concatModelMatrix(Matrix4 m)
Push the product of a matrix and the current model matrix onto the stack
Overrides:
concatModelMatrix in class Graphics3D
 o loadModelMatrix
  public void loadModelMatrix(Matrix4 m)
Push a transformation onto the model matrix stack.
Overrides:
loadModelMatrix in class Graphics3D
 o popModelMatrix
  public void popModelMatrix()
Pop a transformation off the model transformation stack.
Overrides:
popModelMatrix in class Graphics3D
 o translateModel
  public void translateModel(float tx,
                             float ty,
                             float tz)
Translate the model
Overrides:
translateModel in class Graphics3D
 o scaleModel
  public void scaleModel(float sx,
                         float sy,
                         float sz)
Scale the model
Overrides:
scaleModel in class Graphics3D
 o scaleModel
  public void scaleModel(float s)
Scale the model uniformly on all axes
Overrides:
scaleModel in class Graphics3D
 o rotateModel
  public void rotateModel(float ax,
                          float ay,
                          float az,
                          float angle)
Rotate the model by angle radians about the axis [ ax, ay, az]
Overrides:
rotateModel in class Graphics3D
 o rotateModel
  public void rotateModel(Quaternion q)
Overrides:
rotateModel in class Graphics3D
 o resetModelMatrix
  public void resetModelMatrix()
Pop all model transformations off the stack and set the current model transformation to the identity.
Overrides:
resetModelMatrix in class Graphics3D
 o loadTextureMatrix
  public void loadTextureMatrix(Matrix4 m)
Push a transformation onto the texture transformation stack.
Overrides:
loadTextureMatrix in class Graphics3D
 o getModelMatrix
  public void getModelMatrix(Matrix4 m)
Load the current model matrix into m.
Overrides:
getModelMatrix in class Graphics3D
 o getTextureMatrix
  public void getTextureMatrix(Matrix4 m)
Load the current texture matrix into m.
Overrides:
getTextureMatrix in class Graphics3D
 o setModelRenderMode
  public void setModelRenderMode(int renderMode)
Overrides:
setModelRenderMode in class Graphics3D
 o setProjection
  public void setProjection(Projection p)
Set the camera projection
Overrides:
setProjection in class Graphics3D
 o setMaterial
  public void setMaterial(Material m)
Set the current material
Overrides:
setMaterial in class Graphics3D
 o setModifiedMaterialColor
  public void setModifiedMaterialColor(int color)
Set the material component which will be modified by per-vertex and per-face colors in models.
Overrides:
setModifiedMaterialColor in class Graphics3D
 o pushLight
  public void pushLight(Light l)
Push a light onto the light stack.
Overrides:
pushLight in class Graphics3D
See Also:
DirectionalLight, PointLight, SpotLight
 o popLight
  public void popLight()
Remove the top light off the light stack.
Overrides:
popLight in class Graphics3D
 o resetLights
  public void resetLights()
Remove all lights from the stack.
Overrides:
resetLights in class Graphics3D
 o setFog
  public void setFog(Fog f)
Set the type of fog (i.e. how colors are attenuated as distance from the viewer increases.) If the argument is null, fog is turned off.
Overrides:
setFog in class Graphics3D
 o setShadeMode
  public void setShadeMode(int shadeMode)
Set the shade mode.
Overrides:
setShadeMode in class Graphics3D
 o enableFeature
  public void enableFeature(int feature)
Overrides:
enableFeature in class Graphics3D
 o disableFeature
  public void disableFeature(int feature)
Overrides:
disableFeature in class Graphics3D
 o setTextureBlendMode
  public void setTextureBlendMode(int blendMode)
Overrides:
setTextureBlendMode in class Graphics3D
 o setTextureWrapping
  public void setTextureWrapping(boolean wrapU,
                                 boolean wrapV)
Overrides:
setTextureWrapping in class Graphics3D
 o setTextureFilter
  public void setTextureFilter(int filter)
Overrides:
setTextureFilter in class Graphics3D
 o setTextureCoordinateGeneration
  public void setTextureCoordinateGeneration(TextureCoordinateGenerator gen)
Set the rules for automatically generating texture coordinates
Overrides:
setTextureCoordinateGeneration in class Graphics3D
 o useTexture
  public void useTexture(Texture t)
Set the texture to be used when rendering models containing texture coordinates.
Overrides:
useTexture in class Graphics3D
 o setDepthBufferMask
  public void setDepthBufferMask(int mask)
Enable or disable reading from or writing to the depth buffer. This has no effect if a graphics context has no depth buffer.
Overrides:
setDepthBufferMask in class Graphics3D
 o setColorBufferMask
  public void setColorBufferMask(int mask)
Overrides:
setColorBufferMask in class Graphics3D
 o drawRect
  public void drawRect(Rectangle r,
                       Color c)
Overrides:
drawRect in class Graphics3D
 o drawRect
  public void drawRect(Rectangle r,
                       Color c,
                       float opacity)
Overrides:
drawRect in class Graphics3D
 o copyRect
  public void copyRect(Rectangle src,
                       int x,
                       int y)
Overrides:
copyRect in class Graphics3D
 o drawImage
  public void drawImage()
Overrides:
drawImage in class Graphics3D
 o copyBuffers
  public void copyBuffers(Graphics3D g,
                          int buffers)
Copy buffers from one viewport to another.
Overrides:
copyBuffers in class Graphics3D
 o setClearColor
  public void setClearColor(Color c)
Set the color to which the color buffer will be cleared when the clear method is invoked.
Overrides:
setClearColor in class Graphics3D
 o setClearColor
  public void setClearColor(float r,
                            float g,
                            float b)
Set the color to which the color buffer will be cleared when the clear method is invoked.
 o doSetClearColor
  public void doSetClearColor(int color)
 o setClearDepth
  public void setClearDepth(float depth)
Set the depth to which the depth buffer will be cleared when the clear method is invoked.
Overrides:
setClearDepth in class Graphics3D
 o clear
  public void clear(int buffers)
Clear one or more buffers; the buffers parameter specifies which buffers will be cleared.
Overrides:
clear in class Graphics3D
 o enableTwoSidedLighting
  public void enableTwoSidedLighting()
Enable two-sided lighting calculations. Surface normals of back facing polygons will be inverted for lighting calculations.
Overrides:
enableTwoSidedLighting in class Graphics3D
 o disableTwoSidedLighting
  public void disableTwoSidedLighting()
Disable two-sided lighting.
Overrides:
disableTwoSidedLighting in class Graphics3D
 o enableBackfaceCulling
  public void enableBackfaceCulling()
Enable back face culling. Back facing polygons will not be rendered. Turning on back face culling can speed up rendering significantly, although models which aren't 'solid' or which have inconsistently ordered polygons will not be rendered correctly.
Overrides:
enableBackfaceCulling in class Graphics3D
 o disableBackfaceCulling
  public void disableBackfaceCulling()
Disable back face culling.
Overrides:
disableBackfaceCulling in class Graphics3D
 o accumulate
  public void accumulate(float value)
Multiply the contents of the color buffer by value and add to the accumulation buffer. For this and all other accumulation buffer operations, float is clamped to [0, 1]. Accumulation has no effect if the Graphics3D has no accumulation buffer.
Overrides:
accumulate in class Graphics3D
 o accumLoad
  public void accumLoad(float value)
Similar to accumulate, except that the values in the accumulation buffer are replaced with the contents of the color buffer multiplied by value.
Overrides:
accumLoad in class Graphics3D
 o accumReturn
  public void accumReturn(float value)
Multiply the contents of the accumulation buffer by value and load them into the color buffer.
Overrides:
accumReturn in class Graphics3D
 o accumMult
  public void accumMult(float value)
Multiply the contents of the accumulation buffer by value.
Overrides:
accumMult in class Graphics3D
 o finalize
  public void finalize()
Overrides:
finalize in class Object

All Packages  Class Hierarchy  This Package  Previous  Next  Index