home *** CD-ROM | disk | FTP | other *** search
/ SGI Developer Toolbox 6.1 / SGI Developer Toolbox 6.1 - Disc 4.iso / src / exampleCode / cap / README < prev    next >
Encoding:
Text File  |  1994-08-02  |  1.0 KB  |  24 lines

  1.  
  2.                         Simple capping demonstration
  3.  
  4.      This program renders capped and intersected objects.  It uses stencil
  5.      and user-defined clipping planes to compute and light the internal 
  6.      surfaces (where they are exposed by a clipping plane) and to highlight
  7.      intersections of solids.  All in Just 1200 lines of code!
  8.  
  9.         
  10.  
  11.         When a polygonal surface representation of a solid object is
  12.         clipped, the inside of the "solid" is revealed.  This
  13.         program demonstrates a technique to "cap" the solid, so that
  14.         it appears solid even when clipped.  In order to do this, it
  15.         draws each object twice, once to render the visible surfaces,
  16.         and again counting the number of accesses at each pixel.
  17.         Finally, the clipping planes themselves are drawn, with pixels
  18.         actually modified only where the pixel access count in the
  19.         stencil buffer is odd (i.e. where the inside of a solid was
  20.         revealed).
  21.         
  22.  
  23. type "make demo" to run the program
  24.