19 #include <vtkProperty.h>
31 vtkSmartPointer<vtkProp> prop = GetVtkProp(renderer);
32 if (!IsVisible(renderer))
34 prop->SetVisibility(
false);
39 prop->SetVisibility(
true);
40 UpdateVtkOverlay(renderer);
53 if (!renderer || !vtkrenderer)
56 vtkSmartPointer<vtkProp> vtkProp = GetVtkProp(renderer);
57 if (renderer && vtkrenderer && !vtkrenderer->HasViewProp(vtkProp))
59 vtkrenderer->AddViewProp(vtkProp);
73 if (!renderer || !vtkrenderer)
75 vtkSmartPointer<vtkProp> vtkProp = GetVtkProp(renderer);
76 if (vtkrenderer->HasViewProp(vtkProp))
78 vtkrenderer->RemoveViewProp(vtkProp);
85 GetVtkProp(renderer)->RenderOpaqueGeometry(renderer->
GetVtkRenderer());
virtual ~VtkOverlay()
virtual destructor in order to derive from this class
void AddToBaseRenderer(BaseRenderer *renderer) override
Adds the overlay to the specified renderer. Update Overlay should be called soon in order to apply al...
void RemoveFromRenderer(BaseRenderer *renderer, vtkRenderer *vtkrenderer) override
Removes the overlay from the specified renderer. It is not visible anymore then.
Organizes the rendering process.
static void Update(vtkPolyData *)
void Paint(BaseRenderer *renderer)
Paints the overlay.
void Update(BaseRenderer *renderer) override
Applies all properties and should be called before the rendering procedure.
VtkOverlay()
explicit constructor which disallows implicit conversions
static RenderingManager * GetInstance()
void RequestUpdate(vtkRenderWindow *renderWindow)
void RemoveFromBaseRenderer(BaseRenderer *renderer) override
Removes the overlay from the specified renderer. It is not visible anymore then.
vtkRenderer * GetVtkRenderer() const
void AddToRenderer(BaseRenderer *renderer, vtkRenderer *vtkrenderer) override
Adds the overlay to the specified renderer. Update Overlay should be called soon in order to apply al...