|
Aviatrix3D 1.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Marker interface for all leaf objects that wish to implement custom rendering
capabilities beyond just the basic GL callbacks, combining the custom culling
of Cullable
with the rendering callbacks of RenderableComponent
.
This interface is used by programmers that require fairly complex implementation logic at the point of rendering. An example of this is volume rendering that requires a set of viewpoint-specific cutting planes to be generated every frame. This is not achievable using the standard renderable interfaces as they have no way of determining the current viewpoint and transformation stack during the rendering process. This is made worse by a node that could have multiple parents, thus multiple transformation paths to it within a single cull traversal. A developer uses this class to take the given culling information to generate a set of custom instructions that are passed back at culling time, then later passed back during the rendering phase.
Leaf
base class. Anywhere else in the scene graph hierarchy will be
ignored by the culling system. Classes that want to be culled as part of
a NodeComponent
should make use of either RenderableObject
or RenderableComponent
. Nodes further up the tree that provide
grouping and structural information, should implement the Cullable
interface.
Method Summary | |
boolean |
hasTransparency()
Check to see if this renderable object has anything that could be interpreted as an alpha value. |
boolean |
processCull(CullInstructions output,
javax.vecmath.Matrix4f vworldTx,
javax.vecmath.Matrix4f viewTransform,
javax.vecmath.Vector4f[] frustumPlanes,
float angularRes)
This node is being subjected to culling, so process the provided data and return the instructions to the culling system. |
void |
render(net.java.games.jogl.GL gl,
net.java.games.jogl.GLU glu,
java.lang.Object externalData)
Render object now using the pre-given set of custom rendering details. |
Method Detail |
public boolean hasTransparency()
public boolean processCull(CullInstructions output, javax.vecmath.Matrix4f vworldTx, javax.vecmath.Matrix4f viewTransform, javax.vecmath.Vector4f[] frustumPlanes, float angularRes)
render(GL, GLU, Object)
method is called, then formulate that now, and
hand it back as part of the query mechanism.
The culler will not make use of the children or numChildren variables as part of the culling system. Only the return value of this method is used to determine if this object should be placed into the queue for sorting and rendering.
output
- Fill in the cull information herevworldTx
- The transformation from the root of the scene to
this node according to the current traversal pathviewTransform
- The transformation from the root of the scene
graph to the active viewpointfrustumPlanes
- Listing of frustum planes in the order: right,
left, bottom, top, far, nearangularRes
- Angular resolution of the screen, or 0 if not
calculable from the available data.
public void render(net.java.games.jogl.GL gl, net.java.games.jogl.GLU glu, java.lang.Object externalData)
gl
- The GL context to render withglu
- The GL utility context to render withexternalData
- Some implementation-specific external data to
aid in the rendering that was generated in the processCull method.
|
Aviatrix3D 1.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |