X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;ds=sidebyside;f=lib%2FmaracasVisuLib%2Fsrc%2Finterface%2FwxWindows%2Fwidgets%2FwxVtkClipping3DView.cxx;h=a53f035ec2421be2185950c90eba8b1759fb709a;hb=4dcdcabb81ce9f9e9b7ccdb86a64995d7b18ea23;hp=29a97c76572c3fa240fc9122b13375b4f3bda1f5;hpb=e4ef2b5df5aac431ff3b806f83b7dd5e55e89d86;p=creaMaracasVisu.git diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkClipping3DView.cxx b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkClipping3DView.cxx index 29a97c7..a53f035 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkClipping3DView.cxx +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkClipping3DView.cxx @@ -40,7 +40,8 @@ wxVtkClipping3DView::wxVtkClipping3DView(wxVtk3DBaseView* wxvtk3Dbaseview) } //------------------------------------------------------------------- -wxVtkClipping3DView::~wxVtkClipping3DView(){ +wxVtkClipping3DView::~wxVtkClipping3DView() +{ if (_boxWidgetVolume!=NULL) { _boxWidgetVolume -> Delete(); } if (_boxWidgetS1!=NULL) { _boxWidgetS1 -> Delete(); } if (_vtkclipping3Ddataviewer!=NULL) { delete _vtkclipping3Ddataviewer; } @@ -153,7 +154,8 @@ wxVtk3DBaseView* wxVtkClipping3DView::GetWxvtk3Dbaseview()throw(char*) return _wxvtk3Dbaseview; } //------------------------------------------------------------------- -void wxVtkClipping3DView::Configure(){ +void wxVtkClipping3DView::Configure() +{ _wxvtk3Dbaseview->Configure(); // Actors are added to the renderer. @@ -224,11 +226,14 @@ void wxVtkClipping3DView::Configure(){ // _boxWidgetVolume->GetPlanes( vtkplanes ); +//EED 27/05/2013 +// _wxvtk3Dbaseview->GetRenderer()->ResetCamera (); +// _wxvtk3Dbaseview->GetCamera()->Dolly(1.2); + // An initial camera view is created. The Dolly() method moves // the camera towards the FocalPoint, thereby enlarging the image. - _wxvtk3Dbaseview->GetRenderer()->SetActiveCamera(_wxvtk3Dbaseview->GetCamera()); - _wxvtk3Dbaseview->GetRenderer()->ResetCamera (); - _wxvtk3Dbaseview->GetCamera()->Dolly(1.5); + _wxvtk3Dbaseview->ResetCamera(); + // Set a background color for the renderer and set the size of the // render window (expressed in pixels). @@ -241,11 +246,12 @@ void wxVtkClipping3DView::Configure(){ // near plane clips out objects in front of the plane; the far plane // clips out objects behind the plane. This way only what is drawn // between the planes is actually rendered. - _wxvtk3Dbaseview->GetRenderer()->ResetCameraClippingRange(); +//EEDUPS _wxvtk3Dbaseview->GetRenderer()->ResetCameraClippingRange(); _vtkclipping3Ddataviewer->SetRenderer(this->GetWxvtk3Dbaseview()->GetRenderer()); _vtkclipping3Ddataviewer->SetInteractor(this->GetWxvtk3Dbaseview()->GetWxVTKRenderWindowInteractor()); + } //------------------------------------------------------------------- void wxVtkClipping3DView::SetVtkClipping3DDataViewer(vtkClipping3DDataViewer *vtkclipping3Ddataviewer)