ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/common/cone.h
Revision: 2.3
Committed: Tue Feb 25 02:47:21 2003 UTC (21 years, 2 months ago) by greg
Content type: text/plain
Branch: MAIN
CVS Tags: rad3R5
Changes since 2.2: +2 -57 lines
Log Message:
Replaced inline copyright notice with #include "copyright.h"

File Contents

# User Rev Content
1 greg 2.3 /* RCSid $Id$ */
2 greg 1.1 /*
3     * cone.h - header file for cones (cones, cylinders, rings, cups, tubes).
4     *
5     * Storage of arguments in the cone structure is a little strange.
6     * To save space, we use an index into the real arguments of the
7     * object structure through ca. The indices are for the axis
8     * endpoints and radii: p0, p1, r0 and r1.
9     *
10     * 2/12/86
11     */
12    
13 greg 2.3 #include "copyright.h"
14 greg 2.2
15 greg 1.1 typedef struct cone {
16 greg 1.2 FLOAT *ca; /* cone arguments (o->oargs.farg) */
17 greg 1.1 char p0, p1; /* indices for endpoints */
18     char r0, r1; /* indices for radii */
19     FVECT ad; /* axis direction vector */
20 greg 1.2 FLOAT al; /* axis length */
21     FLOAT sl; /* side length */
22     FLOAT (*tm)[4]; /* pointer to transformation matrix */
23 greg 1.1 } CONE;
24    
25     #define CO_R0(co) ((co)->ca[(co)->r0])
26     #define CO_R1(co) ((co)->ca[(co)->r1])
27     #define CO_P0(co) ((co)->ca+(co)->p0)
28     #define CO_P1(co) ((co)->ca+(co)->p1)
29    
30 greg 2.2 #ifdef NOPROTO
31    
32 greg 1.1 extern CONE *getcone();
33 greg 2.2 extern void freecone();
34     extern void conexform();
35    
36     #else
37    
38     extern CONE *getcone(OBJREC *o, int getxf);
39     extern void freecone(OBJREC *o);
40     extern void conexform(CONE *co);
41    
42     #endif