home *** CD-ROM | disk | FTP | other *** search
/ Graphics Plus / Graphics Plus.iso / general / raytrace / radiance / nextrad.lha / NeXtRad / render.h < prev    next >
Encoding:
Text File  |  1993-02-22  |  1.3 KB  |  46 lines

  1. /* render.h */
  2. /* written by : Jason R. Wilson   2/23/93 */
  3.  
  4. /* provides routines for rasterization, hidden surface removal,
  5.     and smooth linear interpolated shading */
  6.  
  7. #import "datastruct.h"
  8.  
  9. /*----------------------------------------------------------------------*/
  10.  
  11. typedef struct edgelistcell
  12. /* assume convex polygons */
  13. {
  14.    int Xpos1, Xpos2; /* assume Xpos1 <= Xpos2 */
  15.    double RIntensity1,RIntensity2;
  16.    double GIntensity1,GIntensity2;
  17.    double BIntensity1,BIntensity2;
  18.    double Depth1,Depth2;
  19.    double uValue1,uValue2;
  20.    double vValue1,vValue2;
  21.    double nValue1,nValue2;
  22.    Boolean OneHere;
  23. }
  24. EdgeListCell;
  25. /*----------------------------------------------------------------------*/
  26.  
  27.  
  28.  
  29. void RasterizeEdge (EdgeListCell *EdgeList,VisVertexCell *a,
  30.             VisVertexCell *b,int winWidth,int winHeight,
  31.                     Window ViewWindow);
  32.             
  33. /* This routine Rasterizes an Edge and adds the information to the edge */
  34. /* list. */
  35.  
  36.  
  37.  
  38. void RenderObject (ObjectCell* Object,double **Zbuffer,Color **ScreenMap,
  39.                    Window ViewWindow,double *MaxIntensity,
  40.            int winWidth,int winHeight,
  41.            Vector uvector, Vector vvector, Vector nvector, Point rpoint);
  42.            
  43. /* This function renders the object using Zbuffer hidden surface removal */
  44. /* and linear interpolation */
  45.  
  46.