file: brush.h
/* * brush.h - Contains definition of brush and prototypes for brush * related functions. */ #ifndef _BRUSH_H #define _BRUSH_H #include "XmdvTool.h" /* the different types of brush boundaries */ #define BOUND_STEP 0 #define BOUND_RAMP 1 /* the number of colors to allocate for each boundary */ #define NUM_BOUND_COL 10 /* * Brush structure definition */ typedef struct { double pos[MAXDIM]; double size[MAXDIM]; int enable; /* if this brush is on */ int display; /* display this brush? */ int bound; /* brush boundary type */ double bound_offset[MAXDIM]; /* boundary offset from min/max */ } Brush; /* function prototypes */ /* brush.c */ void InitBrush(void); int ChangeBrush(int); void ChangeBrushCB(Widget, XtPointer, XtPointer); void ResizeBrushCB(Widget, XtPointer, XtPointer); int CheckBrushCoverage(double *point, int brush); double PercentBrushCoverage(double *point, int brush); int CoverageRank(double *point); int PixelFromBrushCoverage(double *point); void EnableBrushCB(Widget w, XtPointer params, XtPointer call_data); void DisplayBrushCB(Widget w, XtPointer params, XtPointer call_data); void BoundaryStepCB(Widget w, XtPointer params, XtPointer call_data); void BoundaryRampCB(Widget w, XtPointer params, XtPointer call_data); int BoundaryColorAlloc(int brush_no, int num_colors); void BoundaryColorFree(int brush_no, int num_colors); void BoundaryColorInterpolate(int brush_no, int num_colors); #undef P #endif /* _BRUSH_H */
Back to Source File Index
C++ to HTML Conversion by ctoohtml