-
Notifications
You must be signed in to change notification settings - Fork 0
/
vmtkSurfaceViewer.h
73 lines (51 loc) · 1.35 KB
/
vmtkSurfaceViewer.h
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
#ifndef VMTK_SURFACE_VIEWER_HPP_
#define VMTK_SURFACE_VIEWER_HPP_
using namespace std;
#include <vtkRenderer.h>
#include <vtkActor.h>
#include <vtkImageData.h>
#include <vtkPolyData.h>
#include <string>
#include "Uncopyable.h"
#include <log4cpp/Category.hh>
#include <log4cpp/PropertyConfigurator.hh>
class vmtkSurfaceViewer:public vtkObjectBase
{
public:
static vmtkSurfaceViewer* New();
void setRenderer(vtkRenderer*_renderer);
void buildViewWithTag();
void buildView();
void setSurface(vtkPolyData* _Surface);
void setDisplay(int _display);
void setOpacity(double _opacity);
protected:
virtual ~vmtkSurfaceViewer();
vmtkSurfaceViewer();
private:
int FlatInterpolation;
double color[3];
//renderer从外面传进来的实例,不是本类方法中形成的
vtkRenderer* renderer;
//外面传进来的
vtkPolyData * Surface;
//这里面Actor是在这里实例化的,为什么选择在这里实例化,它有一条删除的语句
vtkActor* Actor;
std::string ArrayName;
int DisplayCellData;
double ScalarRange[2];
int Grayscale;
std::string ColorMap;
int NumberOfColors;
double Opacity;
double Linewidth;
std::string Representation;
int Display;
std::string RegionTagArrayName;
std::map<double,int> TagSet;
int NumberOfRegions;
private:
vector<double> getEnumerateColorTransferFunctionParam(int NumberOfColors);
void SetSurfaceRepresentation(std::string Representation);
};
#endif