13 |
|
/* false color mapping data structure */ |
14 |
|
typedef struct { |
15 |
|
TMbright mbrmin, mbrmax; /* mapped min. & max. brightnesses */ |
16 |
< |
BYTE *lumap; /* false color luminance map */ |
17 |
< |
BYTE (*scale)[3]; /* false color ordinal scale */ |
16 |
> |
uby8 *lumap; /* false color luminance map */ |
17 |
> |
uby8 (*scale)[3]; /* false color ordinal scale */ |
18 |
|
} FCstruct; |
19 |
|
|
20 |
< |
extern BYTE fcDefaultScale[256][3]; /* default false color scale */ |
20 |
> |
extern uby8 fcDefaultScale[256][3]; /* default false color scale */ |
21 |
|
|
22 |
|
extern FCstruct * |
23 |
< |
fcInit(BYTE fcscale[256][3]); |
23 |
> |
fcInit(uby8 fcscale[256][3]); |
24 |
|
/* |
25 |
|
Allocate and initialize false color mapping data structure. |
26 |
|
|
53 |
|
*/ |
54 |
|
|
55 |
|
extern int |
56 |
< |
fcLinearMapping(FCstruct *fcs, TMstruct *tms, int pctile); |
56 |
> |
fcLinearMapping(FCstruct *fcs, TMstruct *tms, double pctile); |
57 |
|
/* |
58 |
|
Compute linear false color map. |
59 |
|
|
65 |
|
*/ |
66 |
|
|
67 |
|
extern int |
68 |
< |
fcLogMapping(FCstruct *fcs, TMstruct *tms, int pctile); |
68 |
> |
fcLogMapping(FCstruct *fcs, TMstruct *tms, double pctile); |
69 |
|
/* |
70 |
|
Compute logarithmic false color map. |
71 |
|
|
77 |
|
*/ |
78 |
|
|
79 |
|
extern int |
80 |
< |
fcMapPixels(FCstruct *fcs, BYTE *ps, TMbright *ls, int len); |
80 |
> |
fcMapPixels(FCstruct *fcs, uby8 *ps, TMbright *ls, int len); |
81 |
|
/* |
82 |
|
Apply false color mapping to pixel values. |
83 |
|
|
88 |
|
|
89 |
|
returns - 0 on success, TM_E_* on failure. |
90 |
|
*/ |
91 |
+ |
|
92 |
+ |
extern int |
93 |
+ |
fcIsLogMap(FCstruct *fcs); |
94 |
+ |
/* |
95 |
+ |
Determine if false color mapping is logarithmic. |
96 |
+ |
|
97 |
+ |
fcs - false color structure pointer. |
98 |
+ |
|
99 |
+ |
returns - 1 if map follows logarithmic mapping, -1 on error. |
100 |
+ |
*/ |
101 |
+ |
|
102 |
+ |
extern FCstruct * |
103 |
+ |
fcDup(FCstruct *fcs); |
104 |
+ |
/* |
105 |
+ |
Duplicate a false color structure. |
106 |
+ |
|
107 |
+ |
fcs - false color structure pointer. |
108 |
+ |
|
109 |
+ |
returns - duplicate structure, or NULL if no memory. |
110 |
+ |
*/ |
111 |
|
|
112 |
|
extern void |
113 |
|
fcDone(FCstruct *fcs); |