]> Creatis software - bbtk.git/blob - packages/vtk/src/bbvtkSphereList.h
b23b99a0c99aff092c852f953f008f7b1cc52002
[bbtk.git] / packages / vtk / src / bbvtkSphereList.h
1 #ifndef __bbvtkSphereList_h_INCLUDED__
2 #define __bbvtkSphereList_h_INCLUDED__
3 #include "bbvtk_EXPORT.h"
4 #include "bbtkAtomicBlackBox.h"
5 #include "iostream"
6
7 #include <vtkPolyDataMapper.h>
8 #include <vtkRenderer.h>
9 #include <vtkSphereSource.h>
10 #include <vtkLinearTransform.h>
11
12
13 namespace bbvtk
14 {
15
16 class bbvtk_EXPORT SphereList
17  : 
18    public bbtk::AtomicBlackBox
19 {
20   BBTK_BLACK_BOX_INTERFACE(SphereList,bbtk::AtomicBlackBox);
21
22         BBTK_DECLARE_INPUT(Renderer ,vtkRenderer*);
23         BBTK_DECLARE_INPUT(lstPointX,std::vector<double>);
24         BBTK_DECLARE_INPUT(lstPointY,std::vector<double>);
25         BBTK_DECLARE_INPUT(lstPointZ,std::vector<double>);
26         BBTK_DECLARE_INPUT(lstRadio ,std::vector<double>);
27         BBTK_DECLARE_INPUT(Colour   ,std::vector<double>);
28         BBTK_DECLARE_INPUT(Opacity  ,double);
29         BBTK_DECLARE_INPUT(Spacing   ,std::vector<double>);
30         BBTK_DECLARE_INPUT(Transform   ,vtkLinearTransform*);
31
32   BBTK_DECLARE_OUTPUT(ActorList,std::vector<vtkActor*>);
33
34   BBTK_PROCESS(Process);
35   void Process();
36
37   std::vector<vtkActor *> sphereActor;
38   std::vector<vtkPolyDataMapper *> sphereMapper;
39   std::vector<vtkSphereSource *> vtkSphere;
40
41 };
42
43 BBTK_BEGIN_DESCRIBE_BLACK_BOX(SphereList,bbtk::AtomicBlackBox);
44         BBTK_NAME("SphereList");
45         BBTK_AUTHOR("InfoTeam  CREATIS");
46         BBTK_DESCRIPTION("Builds a sphere list actor given four vectors (X, Y, Z, radius).");
47         BBTK_CATEGORY("");
48         BBTK_INPUT(SphereList,Renderer,"Renderer",vtkRenderer*,"");
49         BBTK_INPUT(SphereList,lstPointX,"List of X coordinates. Requirement: same size as vector Y and vector Z.",std::vector<double>,"");
50         BBTK_INPUT(SphereList,lstPointY,"List of Y coordinates. Requirement: same size as vector X and vector Z.",std::vector<double>,"");
51         BBTK_INPUT(SphereList,lstPointZ,"List of Z coordinates. Requirement: same size as vector X and vector Y.",std::vector<double>,"");
52         BBTK_INPUT(SphereList,lstRadio,"List of Radio values",std::vector<double>,"");
53         BBTK_INPUT(SphereList,Colour,"Colour RGB values for the spheres (3 first values of the vector for the first sphere, following values for the second sphere, etc.)",std::vector<double>,"");
54         BBTK_INPUT(SphereList,Opacity,"Opacity of the spheres",double,"");
55         BBTK_INPUT(SphereList,Spacing,"(default [1 1 1]) Spacing vector [sx sy sz]",std::vector<double>,"");
56 BBTK_INPUT(SphereList,Transform,"vtkTransform",vtkLinearTransform*,"");
57
58  BBTK_OUTPUT(SphereList,ActorList,"List of the sphere actors",std::vector<vtkActor*>,"");
59
60 BBTK_END_DESCRIBE_BLACK_BOX(SphereList);
61 }
62 // EO namespace bbvtk
63
64 #endif // __bbvtkSphereList_h_INCLUDED__
65