1 |
< |
/* Copyright 1990 Regents of the University of California */ |
2 |
< |
|
3 |
< |
/* SCCSid "$SunId$ LBL" */ |
4 |
< |
|
1 |
> |
/* RCSid: $Id$ */ |
2 |
|
/* |
3 |
|
* x11raster.h - header file for X routines using images. |
4 |
|
* |
5 |
|
* 3/1/90 |
6 |
|
*/ |
7 |
+ |
#ifndef _RAD_X11RASTER_H_ |
8 |
+ |
#define _RAD_X11RASTER_H_ |
9 |
|
|
10 |
+ |
#ifdef __cplusplus |
11 |
+ |
extern "C" { |
12 |
+ |
#endif |
13 |
+ |
|
14 |
+ |
|
15 |
|
typedef struct { |
16 |
|
Display *disp; /* the display */ |
17 |
|
int screen; /* the screen */ |
26 |
|
Pixmap pm; /* storage on server side */ |
27 |
|
} XRASTER; |
28 |
|
|
29 |
+ |
extern Colormap newcmap(); |
30 |
+ |
|
31 |
|
extern unsigned long *map_rcolors(); |
32 |
|
|
33 |
|
extern Pixmap make_rpixmap(); |
34 |
|
|
35 |
|
extern XRASTER *make_raster(); |
36 |
|
|
37 |
< |
#define put_raster(d,xdst,ydst,xr) \ |
32 |
< |
patch_raster(d,0,0,xdst,ydst, \ |
37 |
> |
#define put_raster(d,xdst,ydst,xr) patch_raster(d,0,0,xdst,ydst, \ |
38 |
|
(xr)->image->width,(xr)->image->height,xr) |
39 |
|
|
40 |
< |
#define patch_raster(d,xsrc,ysrc,xdst,ydst,width,height,xr) \ |
41 |
< |
(((xr)->pm == 0) \ |
42 |
< |
? XPutImage((xr)->disp,d,(xr)->gc,(xr)->image,xsrc,ysrc, \ |
43 |
< |
xdst,ydst,width,height) \ |
44 |
< |
: XCopyArea((xr)->disp,(xr)->pm,d,(xr)->gc,xsrc,ysrc, \ |
40 |
< |
width,height,xdst,ydst)) |
40 |
> |
#ifdef __cplusplus |
41 |
> |
} |
42 |
> |
#endif |
43 |
> |
#endif /* _RAD_X11RASTER_H_ */ |
44 |
> |
|