]> Creatis software - creaContours.git/commitdiff
*** empty log message ***
authordonadio <donadio>
Wed, 15 Apr 2009 09:53:49 +0000 (09:53 +0000)
committerdonadio <donadio>
Wed, 15 Apr 2009 09:53:49 +0000 (09:53 +0000)
lib/Interface_ManagerContour_NDimensions/wxContourMainFrame.cxx
lib/Interface_ManagerContour_NDimensions/wxContourMainFrame.h
lib/Interface_ManagerContour_NDimensions/wxThresholdPanel.cxx [deleted file]
lib/Interface_ManagerContour_NDimensions/wxThresholdPanel.h [deleted file]

index d21f9a58b0c0b202d6768a10989a83f9407f3518..c126f7c3e2f21771a4445aacd571f4efdcd85f22 100644 (file)
@@ -225,6 +225,20 @@ void wxContourMainFrame::setVectImages( std::vector<vtkImageData*> images ){
                return configured;
        }
 
+
+       bool wxContourMainFrame::addNewPanel(wxPanel* panel)
+               {
+               bool configured = panel!=NULL;
+               configured &= panel!=NULL;
+               
+               if( configured )
+               {
+                       notebook->AddPage( panel, wxT("       Viewer       "), true );
+                       m_mgr.Update();
+               }
+               return configured;
+       }
+
        //------------------------------------------------------------------------------------------------------------
        //  Attributes getters and setters
        //------------------------------------------------------------------------------------------------------------
@@ -1705,8 +1719,6 @@ void wxContourMainFrame::onThreshold(int minVal, int maxVal)
        //Assign a fake color for the upper image, and set the white as transparent
        for(int i = range[0]; i < range[1]; i++)
        {
-               //std::cout<<"Int equal: " << i << std::endl;
-               
                if( i >= minVal && i <= maxVal )
                {
                        lookup->SetTableValue(i, 1.0, 0.0, 0.0, 1);
@@ -1739,30 +1751,10 @@ void wxContourMainFrame::onThreshold(int minVal, int maxVal)
                viewer->GetRenderer()->AddActor( upperImageActor );
                viewer->Render();
 
-               //wxThresholdPanel * panel = new wxThresholdPanel( viewer, notebook );
-
-               //onThresholdPanel(panel);
-
                RefreshInterface();
-
-               //baseImageActor = vtkImageActor::New( );
-               //baseImageActor->SetInput( mBox->bbGetInputImage1() );
 }
 
 
-bool wxContourMainFrame::onThresholdPanel(wxPanel* panel)
-       {
-       bool configured = panel!=NULL;
-       configured &= panel!=NULL;
-       
-       if( configured )
-       {
-               notebook->AddPage( panel, wxT("       Threshold       "), true );
-               m_mgr.Update();
-       }
-       return configured;
-}
-
 void wxContourMainFrame::showAxis(bool show)
 {
        _theViewPanel->SetVisibleAxis(show);
index 981eb92192ef7661359d25317c420d66bb6c68cd..ffad5e36ad5633dbec8f7cb85b3f69565226307a 100644 (file)
@@ -27,9 +27,6 @@
 //#include "wxVtkBaseView_SceneManager.h"
 #include "wxInstantChooserPanel.h"
 #include "wxContourViewPanel.h"
-#include "wxThresholdPanel.h"
-
-
 
 //#include "ContourWorkspace.h"
 #include "ContourExtractData.h"
@@ -139,6 +136,8 @@ class wxContourMainFrame : public wxPanel {
 
        bool configurePanels( );
 
+       bool addNewPanel(wxPanel* panel);
+
        wxAuiNotebook * createNotebook();
 
        void createInstantChooserPanel(wxAuiNotebook * parent);
@@ -258,11 +257,8 @@ class wxContourMainFrame : public wxPanel {
 
        //AD
        void onMirror();
-
        void onThreshold(int minVal, int maxVal);
 
-       bool onThresholdPanel(wxPanel* panel);
-
 //==================================================================================================== 
 
        void showAxis(bool show);
diff --git a/lib/Interface_ManagerContour_NDimensions/wxThresholdPanel.cxx b/lib/Interface_ManagerContour_NDimensions/wxThresholdPanel.cxx
deleted file mode 100644 (file)
index 9914cee..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-//----------------------------------------------------------------------------------------------------------------
-// Class definition include
-//----------------------------------------------------------------------------------------------------------------
-#include "wxThresholdPanel.h"
-
-
-//----------------------------------------------------------------------------------------------------------------
-// Other includes
-//----------------------------------------------------------------------------------------------------------------
-       
-       //------------------------------------------------------------------------------------------------------------
-       // Constructors & Destructors
-       //------------------------------------------------------------------------------------------------------------
-
-       wxThresholdPanel :: wxThresholdPanel ( vtkImageViewer2 * theViewer, wxWindow *parent, const wxPoint& pos, const wxSize& size,long style, int vertStart, int vertEnd, int horzStart, int horzEnd )       
-       :wxPanel(parent, -1, pos, size, style)          
-       {               
-               //wxBoxSizer *topsizer = new wxBoxSizer(wxVERTICAL);
-               
-               vtkRenderWindowInteractor *iren = vtkRenderWindowInteractor::New();
-               theViewer->SetupInteractor(iren);
-
-               //crea::creawxVTKRenderWindowInteractor  * mInteractor = new crea::creawxVTKRenderWindowInteractor(this,-1);
-               //mInteractor->UseCaptureMouseOn();
-               //theViewer->SetupInteractor ( mInteractor );
-                 
-               //theViewer->Render();
-               //theViewer->GetRenderer()->ResetCamera();
-
-               //topsizer-> Add( iren ,1,wxGROW  ,0);
-               SetAutoLayout( true );
-               //SetSizer( topsizer );     
-               Layout(); 
-       }
-       
-
-       wxThresholdPanel :: ~wxThresholdPanel()
-       {
-               
-       }
\ No newline at end of file
diff --git a/lib/Interface_ManagerContour_NDimensions/wxThresholdPanel.h b/lib/Interface_ManagerContour_NDimensions/wxThresholdPanel.h
deleted file mode 100644 (file)
index 4815a25..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-#ifndef __wxThresholdPanel_INCLUDED_H__
-#define __wxThresholdPanel_INCLUDED_H__
-
-
-// -----------------------------------------------------------------------------------------------------------
-// WX headers inclusion.
-// For compilers that support precompilation, includes <wx/wx.h>.
-// -----------------------------------------------------------------------------------------------------------
-
-#include <wx/wxprec.h>
-#ifdef __BORLANDC__
-#pragma hdrstop
-#endif
-#ifndef WX_PRECOMP
-#include <wx/wx.h>
-#endif
-
-
-//------------------------------------------------------------------------------------------------------------
-// Includes
-//------------------------------------------------------------------------------------------------------------
-
-#include "creawxVTKRenderWindowInteractor.h"
-#include "vtkImageViewer2.h"
-#include "vtkRenderWindowInteractor.h"
-
-//------------------------------------------------------------------------------------------------------------
-// Class definition
-//------------------------------------------------------------------------------------------------------------
-
-class wxThresholdPanel : public wxPanel 
-{
-public:
-
-       //------------------------------------------------------------------------------------------------------------
-       // Constructors & Destructors
-       //------------------------------------------------------------------------------------------------------------
-       
-       wxThresholdPanel( vtkImageViewer2 * theViewer, wxWindow *parent, const wxPoint& pos=wxDefaultPosition, const wxSize& size = wxDefaultSize,long style= wxDEFAULT_FRAME_STYLE | wxSUNKEN_BORDER, int vertStart=1, int vertEnd=1, int horzStart=1, int horzEnd=1 );
-
-       ~wxThresholdPanel();
-
-       //------------------------------------------------------------------------------------------------------------
-       // Creational and initialization methods
-       //------------------------------------------------------------------------------------------------------------
-
-
-       //------------------------------------------------------------------------------------------------------------
-       // Methods for capturing events from the horizontal bar
-       //------------------------------------------------------------------------------------------------------------
-
-
-
-       //------------------------------------------------------------------------------------------------------------
-       //  Other functional methods
-       //------------------------------------------------------------------------------------------------------------
-
-
-
-       //------------------------------------------------------------------------------------------------------------
-       // Attributtes
-       //------------------------------------------------------------------------------------------------------------
-private:
-       
-       //------------------------------------------------------------------------------------------------------------
-       //  Private methods
-       //------------------------------------------------------------------------------------------------------------
-
-};
-#endif