raytracer
Class Map

java.lang.Object
  extended by raytracer.Map

public class Map
extends java.lang.Object

a bumpmap or normalmap


Constructor Summary
Map(IPainter normalmap_)
           
Map(IPainter bumpmap_, double scale_, double deltax_, double deltay_)
           
 
Method Summary
 Map getCopy()
           
 void modify(IntersectionInfo ri)
          modifies the normal with the normal from the texture
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Map

public Map(IPainter bumpmap_,
           double scale_,
           double deltax_,
           double deltay_)
Parameters:
bumpmap_ - a painter as a height map
scale_ - scales the height (bumpiness)
deltax_ - step in x direction to compute normal
deltay_ - step in y direction to compute normal

Map

public Map(IPainter normalmap_)
Parameters:
normalmap_ - a painter as a normal map
Method Detail

modify

public void modify(IntersectionInfo ri)
modifies the normal with the normal from the texture

Parameters:
ri - information at the intersection point

getCopy

public Map getCopy()
Returns:
a copy of the map