--- ray/src/hd/rhd_odraw.h 1998/12/28 19:32:29 3.6 +++ ray/src/hd/rhd_odraw.h 2003/07/14 22:24:00 3.11 @@ -1,19 +1,18 @@ -/* Copyright (c) 1998 Silicon Graphics, Inc. */ - -/* SCCSid "$SunId$ SGI" */ - +/* RCSid $Id: rhd_odraw.h,v 3.11 2003/07/14 22:24:00 schorsch Exp $ */ /* * Header for OpenGL cone drawing routines with depth buffer checks. + * + * Include after "standard.h" */ +#ifndef _RAD_RHD_ODRAW_H_ +#define _RAD_RHD_ODRAW_H_ -#undef NOPROTO -#define NOPROTO 1 #include "color.h" #include "tonemap.h" #include "rhdriver.h" -#ifndef int4 -#define int4 int +#ifdef __cplusplus +extern "C" { #endif extern struct ODview { @@ -28,8 +27,8 @@ extern struct ODview { int free; /* index for block free list */ float pthresh; /* proximity threshold */ } *bmap; /* low resolution image map */ - int4 *emap; /* low resolution edge presence map */ - int4 *pmap; /* high resolution presence map */ + int32 *emap; /* low resolution edge presence map */ + int32 *pmap; /* high resolution presence map */ GLfloat *dmap; /* high resolution depth map */ } *odView; /* our view list */ @@ -38,14 +37,14 @@ extern int odNViews; /* number of views in our list */ extern struct ODsamp { union ODfunion { float prox; /* viewpoint proximity */ - int4 next; /* next in free list */ + int32 next; /* next in free list */ } *f; /* free list next or proximity */ short (*ip)[2]; /* image position array */ TMbright *brt; /* encoded brightness array */ BYTE (*chr)[3]; /* encoded chrominance array */ BYTE (*rgb)[3]; /* tone-mapped color array */ - int4 *redraw; /* redraw flags */ + int32 *redraw; /* redraw flags */ int nsamp; /* total number of samples */ char *base; /* base of allocated memory */ } odS; /* sample values */ @@ -57,7 +56,7 @@ extern struct ODsamp { #define CLR4(f,i) FL4OP(f,i,&=~) #define TGL4(f,i) FL4OP(f,i,^=) #define FL4NELS(n) (((n)+0x1f)>>5) -#define CLR4ALL(f,n) bzero((char *)(f),FL4NELS(n)*sizeof(int4)) +#define CLR4ALL(f,n) memset((char *)(f),'\0',FL4NELS(n)*sizeof(int32)) #endif #define OMAXDEPTH 32000 /* maximum depth value */ @@ -137,3 +136,9 @@ and redraw them on the next call(s) to odUpdate(). If is non-zero, then clear the previous sample history. **********************************************************************/ + +#ifdef __cplusplus +} +#endif +#endif /* _RAD_RHD_ODRAW_H_ */ +