cz.cuni.jagrlib.piece
Class RenderDepthBuffer.TextureShader

java.lang.Object
  extended by cz.cuni.jagrlib.piece.RenderDepthBuffer.TextureShader
All Implemented Interfaces:
RenderDepthBuffer.HLineRenderer
Enclosing class:
RenderDepthBuffer

protected class RenderDepthBuffer.TextureShader
extends Object
implements RenderDepthBuffer.HLineRenderer

H-line renderer - external texture mapping (with optional perspective-correct interpolation).


Field Summary
protected  double[] color
           
protected  RasterGraphics output
           
protected  ImageFunction texture
           
 
Constructor Summary
RenderDepthBuffer.TextureShader(RasterGraphics out, ImageFunction tex)
           
 
Method Summary
 void renderHLine(int y, RenderDepthBuffer.PolyEdge e1, RenderDepthBuffer.PolyEdge e2)
          Render horizontal segment (H-line) from [ e1.x, y ] to [ e2.x, y ].
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

output

protected final RasterGraphics output

texture

protected final ImageFunction texture

color

protected final double[] color
Constructor Detail

RenderDepthBuffer.TextureShader

public RenderDepthBuffer.TextureShader(RasterGraphics out,
                                       ImageFunction tex)
Method Detail

renderHLine

public void renderHLine(int y,
                        RenderDepthBuffer.PolyEdge e1,
                        RenderDepthBuffer.PolyEdge e2)
Render horizontal segment (H-line) from [ e1.x, y ] to [ e2.x, y ].

Specified by:
renderHLine in interface RenderDepthBuffer.HLineRenderer