ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/rt/rpaint.h
(Generate patch)

Comparing ray/src/rt/rpaint.h (file contents):
Revision 2.2 by greg, Sat Feb 22 02:07:29 2003 UTC vs.
Revision 2.10 by greg, Wed Oct 5 17:20:55 2011 UTC

# Line 1 | Line 1
1 < /* RCSid: $Id$ */
1 > /* RCSid $Id$ */
2   /*
3   *  rpaint.h - header file for image painting.
4   */
5 + #ifndef _RAD_RPAINT_H_
6 + #define _RAD_RPAINT_H_
7  
6 /* ====================================================================
7 * The Radiance Software License, Version 1.0
8 *
9 * Copyright (c) 1990 - 2002 The Regents of the University of California,
10 * through Lawrence Berkeley National Laboratory.   All rights reserved.
11 *
12 * Redistribution and use in source and binary forms, with or without
13 * modification, are permitted provided that the following conditions
14 * are met:
15 *
16 * 1. Redistributions of source code must retain the above copyright
17 *         notice, this list of conditions and the following disclaimer.
18 *
19 * 2. Redistributions in binary form must reproduce the above copyright
20 *       notice, this list of conditions and the following disclaimer in
21 *       the documentation and/or other materials provided with the
22 *       distribution.
23 *
24 * 3. The end-user documentation included with the redistribution,
25 *           if any, must include the following acknowledgment:
26 *             "This product includes Radiance software
27 *                 (http://radsite.lbl.gov/)
28 *                 developed by the Lawrence Berkeley National Laboratory
29 *               (http://www.lbl.gov/)."
30 *       Alternately, this acknowledgment may appear in the software itself,
31 *       if and wherever such third-party acknowledgments normally appear.
32 *
33 * 4. The names "Radiance," "Lawrence Berkeley National Laboratory"
34 *       and "The Regents of the University of California" must
35 *       not be used to endorse or promote products derived from this
36 *       software without prior written permission. For written
37 *       permission, please contact [email protected].
38 *
39 * 5. Products derived from this software may not be called "Radiance",
40 *       nor may "Radiance" appear in their name, without prior written
41 *       permission of Lawrence Berkeley National Laboratory.
42 *
43 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
44 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
45 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
46 * DISCLAIMED.   IN NO EVENT SHALL Lawrence Berkeley National Laboratory OR
47 * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
48 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
49 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
50 * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
51 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
52 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
53 * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
54 * SUCH DAMAGE.
55 * ====================================================================
56 *
57 * This software consists of voluntary contributions made by many
58 * individuals on behalf of Lawrence Berkeley National Laboratory.   For more
59 * information on Lawrence Berkeley National Laboratory, please see
60 * <http://www.lbl.gov/>.
61 */
62
8   #include  "driver.h"
64
9   #include  "view.h"
10  
11 + #ifdef __cplusplus
12 + extern "C" {
13 + #endif
14 +
15 + #ifdef _WIN32           /* stupid Windows name collisions */
16 + #undef COORD
17 + #define COORD   radCOORD
18 + #undef RECT
19 + #define RECT    radRECT
20 + #endif
21 +
22   typedef short  COORD;           /* an image coordinate */
23  
24   typedef struct pnode {
25          struct pnode  *kid;             /* children */
26          COORD  x, y;                    /* position */
27 +        COORD  xmin, ymin, xmax, ymax;  /* rectangle */
28          COLOR  v;                       /* value */
29   }  PNODE;                       /* a paint node */
30  
# Line 90 | Line 46 | extern VIEW  ourview;          /* current view parameters */
46   extern VIEW  oldview;           /* previous view parameters */
47   extern int  hresolu, vresolu;   /* image resolution */
48  
49 + extern int  newparam;           /* parameter setting changed */
50 +
51 + extern char  *dvcname;          /* output device name */
52 +
53 + extern char  rifname[];         /* rad input file name */
54 +
55 + extern int  psample;            /* pixel sample size */
56 + extern double  maxdiff;         /* max. sample difference */
57 +
58   extern int  greyscale;          /* map colors to brightness? */
59  
60   extern int  pdepth;             /* image depth in current frame */
# Line 99 | Line 64 | extern double  exposure;       /* exposure for scene */
64  
65   extern struct driver  *dev;     /* driver functions */
66  
67 < #ifdef NOPROTO
67 > extern int  nproc;              /* number of processes */
68  
104 extern void     devopen();
105 extern void     devclose();
106 extern void     printdevices();
107 extern void     fillreserves();
108 extern void     freereserves();
109 extern void     command();
110 extern void     rsample();
111 extern int      refine();
112 extern void     getframe();
113 extern void     getrepaint();
114 extern void     getview();
115 extern void     lastview();
116 extern void     saveview();
117 extern void     loadview();
118 extern void     getaim();
119 extern void     getmove();
120 extern void     getrotate();
121 extern void     getpivot();
122 extern void     getexposure();
123 extern int      getparam();
124 extern void     setparam();
125 extern void     traceray();
126 extern void     writepict();
127 extern int      getrect();
128 extern int      getinterest();
129 extern float    *greyof();
130 extern void     paint();
131 extern void     newimage();
132 extern void     redraw();
133 extern void     repaint();
134 extern void     paintrec();
135 extern PNODE    *findrect();
136 extern void     scalepict();
137 extern void     getpictcolrs();
138 extern void     freepkids();
139 extern void     newview();
140 extern void     moveview();
141 extern void     pcopy();
142 extern void     zoomview();
143
144 #else
69                                  /* defined in rview.c */
70   extern void     devopen(char *dname);
71   extern void     devclose(void);
72   extern void     printdevices(void);
149 extern void     fillreserves(void);
150 extern void     freereserves(void);
73   extern void     command(char *prompt);
74   extern void     rsample(void);
75 < extern int      refine(PNODE *p, int xmin, int ymin,
154 <                                int xmax, int ymax, int pd);
75 > extern int      refine(PNODE *p, int pd);
76                                  /* defined in rv2.c */
77   extern void     getframe(char *s);
78   extern void     getrepaint(char *s);
# Line 159 | Line 80 | extern void    getview(char *s);
80   extern void     lastview(char *s);
81   extern void     saveview(char *s);
82   extern void     loadview(char *s);
83 + extern void     getfocus(char *s);
84   extern void     getaim(char *s);
85   extern void     getmove(char *s);
86   extern void     getrotate(char *s);
# Line 172 | Line 94 | extern void    writepict(char *s);
94   extern int      getrect(char *s, RECT *r);
95   extern int      getinterest(char *s, int direc, FVECT vec, double *mp);
96   extern float    *greyof(COLOR col);
97 < extern void     paint(PNODE *p, int xmin, int ymin, int xmax, int ymax);
98 < extern void     newimage(void);
97 > extern int      paint(PNODE *p);
98 > extern int      waitrays(void);
99 > extern void     newimage(char *s);
100   extern void     redraw(void);
101   extern void     repaint(int xmin, int ymin, int xmax, int ymax);
102 < extern void     paintrect(PNODE *p, int xmin, int ymin,
103 <                                int xmax, int ymax, RECT *r);
104 < extern PNODE    *findrect(int x, int y, PNODE *p, RECT *r, int pd);
102 > extern void     paintrect(PNODE *p, RECT *r);
103 > extern PNODE    *findrect(int x, int y, PNODE *p, int pd);
104 > extern void     compavg(PNODE *p);
105   extern void     scalepict(PNODE *p, double sf);
106   extern void     getpictcolrs(int yoff, COLR *scan, PNODE *p,
107                          int xsiz, int ysiz);
# Line 188 | Line 111 | extern void    moveview(double angle, double elev, double
111   extern void     pcopy(PNODE *p1, PNODE *p2);
112   extern void     zoomview(VIEW *vp, double zf);
113  
114 +
115 + #ifdef __cplusplus
116 + }
117   #endif
118 + #endif /* _RAD_RPAINT_H_ */
119 +

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines