Class com.oroinc.yaray.Finish
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.oroinc.yaray.Finish

java.lang.Object
   |
   +----com.oroinc.yaray.Finish

public class Finish
extends Object
The finish of a surface.

Copyright © 1996, 1997 Original Reusable Objects, Inc. All rights reserved.

Author:
Daniel F. Savarese

Variable Index

 o brilliance
 o kAmbient
 o kDiffuse
 o kReflectivity
 o kSpecular
 o kTransmitted
 o nRefraction
 o roughness

Constructor Index

 o Finish()

Method Index

 o ambientColor(Color)
 o lightColor(World, int, GeometricVector, Ray, Color)
Returns the specular and diffuse reflection components of the finish color.
 o reflectionColor(World, GeometricVector, Ray)
Returns the pure reflection component of the finish color.
 o refractionColor(World, GeometricVector, Ray)
Returns the pure refraction component of the finish color.

Variables

 o kAmbient
  public float kAmbient
 o kDiffuse
  public float kDiffuse
 o kSpecular
  public float kSpecular
 o kReflectivity
  public float kReflectivity
 o kTransmitted
  public float kTransmitted
 o nRefraction
  public float nRefraction
 o brilliance
  public float brilliance
 o roughness
  public float roughness

Constructors

 o Finish
  public Finish()

Methods

 o ambientColor
  public Color ambientColor(Color color)
 o lightColor
  public Color lightColor(World world,
                          int lightIndex,
                          GeometricVector normal,
                          Ray intersection,
                          Color color)
Returns the specular and diffuse reflection components of the finish color.

Parameters:
world - A pointer to the world description.
lightIndex - The index into the world.lights[] array indicating the light for which the color is being computed.
normal - The surface normal at the point where the color is being computed.
intersection - The ray that intersects the object defining where the color is being computed.
color - The base color of the object at the intersection point.
 o reflectionColor
  public Color reflectionColor(World world,
                               GeometricVector normal,
                               Ray intersection)
Returns the pure reflection component of the finish color.

Parameters:
world - A pointer to the world description.
normal - The surface normal at the point where the color is being computed.
intersection - The ray that intersects the object defining where the color is being computed.
 o refractionColor
  public Color refractionColor(World world,
                               GeometricVector normal,
                               Ray intersection)
Returns the pure refraction component of the finish color.

Parameters:
world - A pointer to the world description.
normal - The surface normal at the point where the color is being computed.
intersection - The ray that intersects the object defining where the color is being computed.

All Packages  Class Hierarchy  This Package  Previous  Next  Index