Changeset 16011 for trunk/Ohana/src/kapa2/include/structures.h
- Timestamp:
- Jan 6, 2008, 1:41:58 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/Ohana/src/kapa2/include/structures.h (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/kapa2/include/structures.h
r14590 r16011 2 2 /**************** Graphic carries X info around ****************/ 3 3 typedef struct { 4 Display *display; 5 int screen; 4 Display *display; // X display pointer 5 int screen; // X screen number 6 6 int depth; 7 7 Window window; 8 8 Visual *visual; 9 int visualclass; 10 int Nbits; 9 int visualclass; // is visual dynamic? (XXX change name?) 10 int Nbits; // pixel depth in bits (8, 16, 24, 32) 11 11 GC gc; 12 12 XFontStruct *font; … … 14 14 int x, y; 15 15 unsigned int dx, dy; 16 XColor cmap[256];16 XColor *cmap; 17 17 Colormap colormap; 18 unsigned long fore; 19 unsigned long back; 20 unsigned long *color; 21 unsigned long pixels[256]; 22 unsigned long overlay_color[NOVERLAYS]; 23 int Npixels; 24 int Ncolors; 18 unsigned long *color; // graph plotting colors 19 int Ncolors; 20 21 unsigned long *pixels; // image pixel colors 22 int Npixels; // number of pixels 23 24 int ColorScaleMode; // single colormap for all images?? 25 int nRed; 26 int nBlue; 27 int nGreen; 28 29 unsigned long fore; // basic foreground color 30 unsigned long back; // basic background color 31 32 unsigned long overlay_color[NOVERLAYS]; // image plotting colors 25 33 } Graphic; 26 34 … … 58 66 } TextBox; 59 67 68 /*** 3C color cube histogram tree thingy ***/ 69 typedef struct CCNode { 70 // for the moment, this structure is specific to the color-histogram analysis. if 71 // this were a void *pointer and we defined some additional apis, we could use this 72 // structure to track any 3D space 73 int count; 74 int pixel; 75 char bottom; 76 float min[3]; // min value for each of the 3 dimensions for this node 77 float mid[3]; // mid-point for each of the 3 dimensions for this node 78 float max[3]; // max value for each of the 3 dimensions for this node 79 struct CCNode *sub[2][2][2]; 80 } CCNode; 81 60 82 /**************** general structures ****************/ 61 83 typedef struct { … … 125 147 } KapaGraphWidget; 126 148 149 typedef struct { 150 // data associated with this image element 151 Matrix matrix; /* data for picture */ 152 double zero, range; /* zero, range for picture to cmap */ 153 double max, min; /* zero, range for data to z-value */ 154 double start, slope; /* zero, range for cmap to pixels */ 155 Coords coords; 156 char file[1024]; /* name of file */ 157 char name[1024]; /* name of buffer */ 158 } KapaImageChannel; 159 127 160 // a single image in the display window 128 161 typedef struct { … … 139 172 Button grey_button; 140 173 Button rainbow_button; 141 Button puns_button;174 Button heat_button; 142 175 Button overlay_button[NOVERLAYS]; 143 176 … … 149 182 int DecimalDegrees; 150 183 151 // data associated with this image element 184 double X, Y; /* image pixel at screen center */ 185 int expand; /* zoomscale */ 186 double x, y, z; /* last pointer coords */ 187 152 188 Overlay overlay[NOVERLAYS]; 153 189 Overlay tickmarks; 154 Matrix matrix; /* data for picture */ 155 double X, Y; /* image pixel at screen center */ 156 int expand; /* zoomscale */ 157 double zero, range; /* zero, range for picture to cmap */ 158 double max, min; /* zero, range for data to z-value */ 159 double start, slope; /* zero, range for cmap to pixels */ 160 double x, y, z; /* last pointer coords */ 161 Coords coords; 162 char file[1024]; /* name of file */ 163 char name[1024]; /* name of buffer */ 190 191 unsigned short *pixmap; // lookup table for image pixel value to pixel index 192 int nPixels; 193 194 KapaImageChannel *image; 195 KapaImageChannel channel[NCHANNELS]; 164 196 } KapaImageWidget; 165 197
Note:
See TracChangeset
for help on using the changeset viewer.
