VolumeJ
Class VJLight

java.lang.Object
  |
  +--VolumeJ.VJLight

public class VJLight
extends java.lang.Object

This class implements a volume rendering light, and adds to methods to manipulate the light. Use objectify to transform the light position into another coordinate system (for example, the same coordinate system as the gradient, usually object space). Currently only monochrome lightsare supported. Copyright (c) 2001-2002, Michael Abramoff. All rights reserved.


Field Summary
 float diffuse
           
 float specular
           
 float tx
           
 float ty
           
 float tz
           
 
Constructor Summary
VJLight(float x, float y, float z, float diffuse, float specular)
          Create a new light.
 
Method Summary
 float getDiffuse()
           
 float getSpecular()
           
 float getx()
           
 float gety()
           
 float getz()
           
 void objectify(VJMatrix m)
          Transform the position of this light into another coordinate system.
 java.lang.String toLongString()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

tx

public float tx

ty

public float ty

tz

public float tz

diffuse

public float diffuse

specular

public float specular
Constructor Detail

VJLight

public VJLight(float x,
               float y,
               float z,
               float diffuse,
               float specular)
Create a new light. The light comes from x, y, z.
Parameters:
x - the x-position of the light (usually in viewspace).
y - the y-position of the light (usually in viewspace).
z - the z-position of the light (usually in viewspace).
diffuse - the amount of light diffuse reflection cast by this light.
specular - the amount of specular reflection cast by this light.
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

toLongString

public java.lang.String toLongString()

objectify

public void objectify(VJMatrix m)
Transform the position of this light into another coordinate system. Usually from viewspace to objectspace.
Parameters:
m - the transformation matrix.

getSpecular

public float getSpecular()

getDiffuse

public float getDiffuse()

getx

public float getx()

gety

public float gety()

getz

public float getz()