1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
|
// Copyright (C) 1999-2018
// Smithsonian Astrophysical Observatory, Cambridge, MA, USA
// For conditions of distribution and use, see copyright notice in "copyright"
#ifndef __fvcontour_h__
#define __fvcontour_h__
#include "vector.h"
#include "contour.h"
#include "frscale.h"
#include "inversescale.h"
class FVContour {
public:
enum Method {SMOOTH, BLOCK};
private:
enum {top, right, bottom, left, none};
Base* parent_;
List<ContourLevel> lcontourlevel_;
char* colorName_;
int lineWidth_;
int dash_;
int dlist_[2];
Method method_;
int smooth_;
int numLevel_;
FrScale frScale_;
char* level_;
InverseScale* scale_;
void buildScale(FitsImage* fits);
void unity(FitsImage*);
void bin(FitsImage*);
void nobin(FitsImage*);
void convolve(FitsImage*, double*, double*, int);
double* tophat(int);
double* gaussian(int);
void build(long xdim, long ydim, double *image, Matrix&);
void trace(long xdim, long ydim, double cntr,
long xCell, long yCell, int side,
double** rows, char* useGrid, Matrix&, ContourLevel*);
public:
FVContour();
~FVContour();
List<ContourLevel>& lcontourlevel() {return lcontourlevel_;}
void create(Base*, FitsImage*, FrScale*,
const char*, int, int,
Method, int, int,
const char*);
void update(FitsImage*);
void update(FitsImage*, FrScale*);
void append(FitsImage*);
int isEmpty() {return lcontourlevel_.isEmpty();}
const char* methodName();
char* level() {return level_;}
int numLevel() {return numLevel_;}
int smooth() {return smooth_;}
FrScale* frScale() {return &frScale_;}
const char* getColorName() {return colorName_;}
int getDash() {return dash_;}
int getLineWidth() {return lineWidth_;}
};
#endif
|