ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/gen/mkillum.h
Revision: 2.7
Committed: Fri Sep 17 21:43:50 2004 UTC (19 years, 6 months ago) by greg
Content type: text/plain
Branch: MAIN
CVS Tags: rad3R7P2, rad3R7P1, rad3R6, rad3R6P1, rad3R8
Changes since 2.6: +20 -3 lines
Log Message:
Added -n option to mkillum for multiprocessing on shared memory machine

File Contents

# User Rev Content
1 greg 2.7 /* RCSid: $Id: mkillum.h,v 2.6 2003/11/21 07:15:30 greg Exp $ */
2 greg 1.1 /*
3     * Common definitions for mkillum
4     */
5 schorsch 2.3 #ifndef _RAD_MKILLUM_H_
6     #define _RAD_MKILLUM_H_
7 greg 1.2
8     #include "standard.h"
9     #include "object.h"
10 schorsch 2.3 #include "rtprocess.h"
11 schorsch 2.4
12     #ifdef __cplusplus
13     extern "C" {
14     #endif
15 greg 1.1 /* illum flags */
16 greg 1.3 #define IL_LIGHT 0x1 /* light rather than illum */
17     #define IL_COLDST 0x2 /* use color distribution */
18     #define IL_COLAVG 0x4 /* use average color */
19     #define IL_DATCLB 0x8 /* OK to clobber data file */
20 greg 1.1
21     struct illum_args {
22     int flags; /* flags from list above */
23     char matname[MAXSTR]; /* illum material name */
24     char datafile[MAXSTR]; /* distribution data file name */
25     int dfnum; /* data file number */
26 greg 1.2 char altmat[MAXSTR]; /* alternate material name */
27 greg 1.3 int sampdens; /* point sample density */
28 greg 1.1 int nsamps; /* # of samples in each direction */
29 greg 1.5 float minbrt; /* minimum average brightness */
30 greg 1.4 float col[3]; /* computed average color */
31 greg 1.1 }; /* illum options */
32    
33     struct rtproc {
34 greg 2.7 struct rtproc *next; /* next in list of processes */
35 schorsch 2.3 SUBPROC pd; /* rtrace pipe descriptors */
36 greg 1.1 float *buf; /* rtrace i/o buffer */
37     int bsiz; /* maximum rays for rtrace buffer */
38 greg 1.3 float **dest; /* destination for each ray result */
39 greg 1.1 int nrays; /* current length of rtrace buffer */
40     }; /* rtrace process */
41 schorsch 2.3
42 schorsch 2.5 extern void printobj(char *mod, register OBJREC *obj);
43     extern int average(register struct illum_args *il, float *da, int n);
44     extern void flatout(struct illum_args *il, float *da, int n, int m,
45     FVECT u, FVECT v, FVECT w);
46     extern void illumout(register struct illum_args *il, OBJREC *ob);
47     extern void roundout(struct illum_args *il, float *da, int n, int m);
48 schorsch 2.3
49 greg 2.7 /* The header file otypes.h has to follow definition of our struct's */
50     #define FUN_ARGLIST OBJREC *, struct illum_args *, struct rtproc *, char *
51 schorsch 2.3 #ifdef __cplusplus
52     }
53 greg 2.7 #include "otypes.h"
54     extern "C" {
55     #else
56     #include "otypes.h"
57 schorsch 2.3 #endif
58 greg 2.6
59 greg 2.7 extern int o_default(FUN_ARGLIST);
60     extern int o_face(FUN_ARGLIST);
61     extern int o_sphere(FUN_ARGLIST);
62     extern int o_ring(FUN_ARGLIST);
63     extern void raysamp(float res[3], FVECT org, FVECT dir, struct rtproc *rt0);
64     extern void rayflush(struct rtproc *rt, int doall);
65     extern struct rtproc *raywait(struct rtproc *rt0);
66    
67    
68     #ifdef __cplusplus
69     }
70     #endif
71 greg 2.6
72 schorsch 2.3 #endif /* _RAD_MKILLUM_H_ */
73