ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/gen/genblinds.c
(Generate patch)

Comparing ray/src/gen/genblinds.c (file contents):
Revision 2.14 by greg, Tue Jun 30 18:16:30 2020 UTC vs.
Revision 2.15 by greg, Sat Jul 25 19:23:09 2020 UTC

# Line 15 | Line 15 | static const char      RCSid[] = "$Id$";
15   *              rcurv  -  curvature radius of slats (up:>0;down:<0;flat:=0)
16   */
17  
18 < #include  <stdio.h>
19 < #include <stdlib.h>
18 > #include  "rtio.h"
19 > #include  <stdlib.h>
20   #include  <math.h>
21 #include  <string.h>
21  
22 + #ifndef PI
23   #define  PI             3.14159265358979323846
24 + #endif
25   #define  DELTA          3.  /*  MINIMAL SUSTAINED ANGLE IN DEGREES */
26  
27   double  baseflat[4][3], baseblind[4][3][180];
# Line 32 | Line 33 | int  nslats,  nsurf;
33  
34   static void makeflat(double w, double d, double a);
35   static void printslat(int n);
35 static void printhead(register int  ac, register char  **av);
36  
37
37   void
38   makeflat(
39          double w,
# Line 67 | Line 66 | printslat(                     /* print slat # n */
66          int  n
67   )
68   {
69 <        register int  i, k;
69 >        int  i, k;
70  
71          for (k=0; k < nsurf; k++)  {
72                  printf("\n%s polygon %s.%d.%d\n", material, name, n, k);
# Line 81 | Line 80 | printslat(                     /* print slat # n */
80   }
81  
82  
84 void
85 printhead(              /* print command header */
86        register int  ac,
87        register char  **av
88 )
89 {
90        putchar('#');
91        while (ac--) {
92                putchar(' ');
93                fputs(*av++, stdout);
94        }
95        putchar('\n');
96 }
97
98
83   int
84   main(
85          int  argc,
# Line 201 | Line 185 | main(
185          }
186      }
187  
188 <    printhead(argc, argv);
189 <
188 >    fputs("# ", stdout);
189 >    printargs(argc, argv, stdout);
190 >
191  
192      /* REPEAT THE BASIC CURVED OR FLAT SLAT TO GET THE OVERALL BLIND */
193  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines