hmi.graphics.opengl.scenegraph
Class GLNodeMarker

java.lang.Object
  extended by hmi.graphics.opengl.scenegraph.GLNodeMarker
All Implemented Interfaces:
GLRenderObject

public class GLNodeMarker
extends Object
implements GLRenderObject

A simple sphere for usage as marker for VGL nodes

Author:
Job Zwiers

Field Summary
private  GLRenderObject geometry
           
private static int GRID
           
private  int index
           
private  String name
           
private static float RADIUS
           
private  float[] transformMatrix
           
private  boolean visible
           
 
Constructor Summary
GLNodeMarker(int index, String name)
           
GLNodeMarker(int index, String name, float radius, int grid)
           
 
Method Summary
 void glInit(GLRenderContext gl)
          Called during OpenGL initialization.
 void glRender(GLRenderContext gl)
          Rendering a light means: set position, taking into account the current ModelView transformation.
 void linkToTransformMatrix(float[] trafo)
           
 void setVisible(boolean vis)
          Determines whether the light source is visible, in the form of a small sphere, or not.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RADIUS

private static final float RADIUS
See Also:
Constant Field Values

GRID

private static final int GRID
See Also:
Constant Field Values

visible

private boolean visible

geometry

private GLRenderObject geometry

transformMatrix

private float[] transformMatrix

index

private int index

name

private String name
Constructor Detail

GLNodeMarker

public GLNodeMarker(int index,
                    String name,
                    float radius,
                    int grid)

GLNodeMarker

public GLNodeMarker(int index,
                    String name)
Method Detail

setVisible

public void setVisible(boolean vis)
Determines whether the light source is visible, in the form of a small sphere, or not. This is just a visualization of the position of the light, and has no effect on the OpenGL lighting itself.


linkToTransformMatrix

public void linkToTransformMatrix(float[] trafo)

glInit

public void glInit(GLRenderContext gl)
Description copied from interface: GLRenderObject
Called during OpenGL initialization.

Specified by:
glInit in interface GLRenderObject

glRender

public void glRender(GLRenderContext gl)
Rendering a light means: set position, taking into account the current ModelView transformation. Optionally, a small sphere is rendered, to indicate the position of the light.

Specified by:
glRender in interface GLRenderObject