--- ray/src/rt/aniso.c 1998/12/16 18:14:57 2.33 +++ ray/src/rt/aniso.c 2003/02/25 02:47:22 2.35 @@ -1,13 +1,12 @@ -/* Copyright (c) 1998 Silicon Graphics, Inc. */ - #ifndef lint -static char SCCSid[] = "$SunId$ SGI"; +static const char RCSid[] = "$Id: aniso.c,v 2.35 2003/02/25 02:47:22 greg Exp $"; #endif - /* * Shading functions for anisotropic materials. */ +#include "copyright.h" + #include "ray.h" #include "otypes.h" @@ -16,17 +15,10 @@ static char SCCSid[] = "$SunId$ SGI"; #include "random.h" -extern double specthresh; /* specular sampling threshold */ -extern double specjitter; /* specular sampling jitter */ - -extern int backvis; /* back faces visible? */ - #ifndef MAXITER #define MAXITER 10 /* maximum # specular ray attempts */ #endif -static agaussamp(), getacoords(); - /* * This routine implements the anisotropic Gaussian * model described by Ward in Siggraph `92 article. @@ -68,7 +60,11 @@ typedef struct { double pdot; /* perturbed dot product */ } ANISODAT; /* anisotropic material data */ +static void getacoords(); +static void agaussamp(); + +static void diraniso(cval, np, ldir, omega) /* compute source contribution */ COLOR cval; /* returned coefficient */ register ANISODAT *np; /* material data */ @@ -182,6 +178,7 @@ double omega; /* light source size */ } +int m_aniso(m, r) /* shade ray that hit something anisotropic */ register OBJREC *m; register RAY *r; @@ -307,7 +304,7 @@ register RAY *r; } -static +static void getacoords(r, np) /* set up coordinate system */ RAY *r; register ANISODAT *np; @@ -337,7 +334,7 @@ register ANISODAT *np; } -static +static void agaussamp(r, np) /* sample anisotropic gaussian specular */ RAY *r; register ANISODAT *np;