2 #include "boxSurfaceObserver.h"
3 #include "vtkBoxWidget.h"
5 void boxSurfaceObserver::Execute(vtkObject *wdg, unsigned long eventId, void* calldata) { // virtual
6 vtkBoxWidget *boxwidget = reinterpret_cast<vtkBoxWidget*>(wdg);
7 boxwidget->GetPlanes(_planes);
9 if ( _vtkVolumeRayCastMapper != NULL )
11 _vtkVolumeRayCastMapper->RemoveAllClippingPlanes();
12 // vtkPlanes *planes = vtkPlanes::New();
13 // boxwidget->GetPlanes(planes);
14 // _vtkVolumeRayCastMapper->SetClippingPlanes(planes);
15 _vtkVolumeRayCastMapper->SetClippingPlanes(_planes);
18 // _actor->VisibilityOn();
21 //-------------------------------------------------------------------
22 void boxSurfaceObserver::SetPlanes(vtkPlanes *planes){
25 //-------------------------------------------------------------------
26 void boxSurfaceObserver::SetActor(vtkProp *actor){
30 //-------------------------------------------------------------------
31 void boxSurfaceObserver::SetvtkVolumeRayCastMapper(vtkVolumeRayCastMapper *vtkvolumeraycastmapper)
33 _vtkVolumeRayCastMapper = vtkvolumeraycastmapper;