00001
00002
00003
00004
00005
00018 #ifndef _SIGN3DVIEWER_H
00019 #define _SIGN3DVIEWER_H
00020
00021 #include <SignDLL.h>
00022 #include <SignViewer.h>
00023
00024 class vtkRenderer;
00025 class vtkVolume;
00026 class vtkFollower;
00027 class vtkPolyDataMapper;
00028 class vtkVectorText;
00029 class SignVolume;
00030
00031 typedef std::vector<SignVolume*> VolumeVector;
00032
00033 class SIGN_EXPORT Sign3DViewer : public SignViewer
00034 {
00035 public:
00036 vtkTypeRevisionMacro(Sign3DViewer,SignViewer);
00037 virtual void PrintSelf(ostream& os, vtkIndent indent);
00038
00040 static Sign3DViewer *New();
00041
00043 void AddAnnotationActorsToRenderer(vtkVolume* vol);
00044
00046 void RemoveAnnotationActorsFromRenderer();
00047
00049 void SetAnnotationActorVisibility(bool visibility);
00050
00052 void AddVolume(SignVolume *volume);
00053
00055 void RemoveVolume(SignVolume *volume);
00056
00058 void Cycle();
00059
00061 VolumeVector volumes;
00062
00064 void SetBackground(float r, float g, float b);
00065
00066 protected:
00067 Sign3DViewer();
00068 ~Sign3DViewer();
00069 virtual void CreateWidget();
00070
00071 private:
00072 vtkFollower *actorR,*actorL,*actorA,*actorP,*actorS,*actorI;
00073 vtkVectorText *textR,*textL,*textA,*textP,*textS,*textI;
00074 vtkPolyDataMapper *pdmR,*pdmL,*pdmA,*pdmP,*pdmS,*pdmI;
00075 int actorScale;
00076
00077 static void ObjectAddedCallback(vtkObject* caller,unsigned long event,void* data,void* calldata);
00078
00079 Sign3DViewer(const Sign3DViewer&);
00080 void operator=(const Sign3DViewer&);
00081
00082 };
00083
00084 #endif