From 803877e98b79df963f17d83da7203fd972674d9e Mon Sep 17 00:00:00 2001 From: Eduardo Davila Date: Mon, 20 Apr 2009 09:16:02 +0000 Subject: [PATCH] OK --- .../wxContourGUIExample.cxx | 4 --- .../interfSegmentationPanels.cxx | 26 ++++++++++++------- .../PanelBullEyeOptions.cxx | 2 +- .../wxContourMainFrame.cxx | 20 +++++++------- .../wxContourViewPanel.cxx | 14 +++++----- .../wxInstantChooserPanel.cxx | 8 +++--- .../KernelManagerContour.cxx | 11 ++++---- 7 files changed, 44 insertions(+), 41 deletions(-) diff --git a/appli/wxContourGUIExample/wxContourGUIExample.cxx b/appli/wxContourGUIExample/wxContourGUIExample.cxx index 307361e..3990807 100644 --- a/appli/wxContourGUIExample/wxContourGUIExample.cxx +++ b/appli/wxContourGUIExample/wxContourGUIExample.cxx @@ -2,7 +2,6 @@ // Class definition include //---------------------------------------------------------------------------------------------------------------- - #include "wxContourGUIExample.h" #include "wxContourMainFrame.h" //#include "OutlineModelManager.h" @@ -28,9 +27,6 @@ //#include "SomeEnvironment.h" //#include "ReaderEnvironment.h" - - - //#include "interfMainPanel.h" diff --git a/lib/Interface_Icons_NDimensions/interfSegmentationPanels.cxx b/lib/Interface_Icons_NDimensions/interfSegmentationPanels.cxx index 4345971..b4e1696 100644 --- a/lib/Interface_Icons_NDimensions/interfSegmentationPanels.cxx +++ b/lib/Interface_Icons_NDimensions/interfSegmentationPanels.cxx @@ -126,20 +126,27 @@ void interfSegmentationPanelVTK::setLabel(wxString tmpString){ interfSegmentationPanelITK::interfSegmentationPanelITK(wxWindow * parent) : wxPanel(parent, -1, wxDefaultPosition, wxDefaultSize, wxBORDER_SUNKEN) { - int sizeZ = interfMainPanel::getInstance()->GetImageDataSizeZ(); +// int sizeZ = interfMainPanel::getInstance()->GetImageDataSizeZ(); //int sizeZ = _theViewPanel->getSceneManager()->GetImageDataSizeZ(); double range[2]; //_theViewPanel->getSceneManager()->GetImageDataRange(range); interfMainPanel::getInstance()->GetImageDataRange(range); //The labels - wxStaticText * distance = new wxStaticText(this, wxID_ANY, wxT("Initial Distance"), wxPoint(5, 5)); - wxStaticText * sigma = new wxStaticText(this, wxID_ANY, wxT("Sigma"), wxPoint(5, 30)); - wxStaticText * alfa = new wxStaticText(this, wxID_ANY, wxT("Sigmoid Alfa"), wxPoint(5, 55)); - wxStaticText * beta = new wxStaticText(this, wxID_ANY, wxT("Sigmoid Beta"), wxPoint(5, 80)); - wxStaticText * propagation = new wxStaticText(this, wxID_ANY, wxT("Propagation Scaling"),wxPoint(5, 105)); - wxStaticText * iterations = new wxStaticText(this, wxID_ANY, wxT("Iterations"), wxPoint(5, 130)); - wxStaticText * infStrength = new wxStaticText(this, wxID_ANY, wxT("Inflation Strength"), wxPoint(5, 155)); + //wxStaticText * distance = + new wxStaticText(this, wxID_ANY, wxT("Initial Distance"), wxPoint(5, 5)); + //wxStaticText * sigma = + new wxStaticText(this, wxID_ANY, wxT("Sigma"), wxPoint(5, 30)); + //wxStaticText * alfa = + new wxStaticText(this, wxID_ANY, wxT("Sigmoid Alfa"), wxPoint(5, 55)); + //wxStaticText * beta = + new wxStaticText(this, wxID_ANY, wxT("Sigmoid Beta"), wxPoint(5, 80)); + //wxStaticText * propagation = + new wxStaticText(this, wxID_ANY, wxT("Propagation Scaling"),wxPoint(5, 105)); + //wxStaticText * iterations = + new wxStaticText(this, wxID_ANY, wxT("Iterations"), wxPoint(5, 130)); + //wxStaticText * infStrength = + new wxStaticText(this, wxID_ANY, wxT("Inflation Strength"), wxPoint(5, 155)); //Text Controls @@ -152,7 +159,8 @@ interfSegmentationPanelITK::interfSegmentationPanelITK(wxWindow * parent) _infStrength = new wxTextCtrl(this, wxID_ANY, wxT("3.0"), wxPoint(98,155), wxSize(80, 20), 0, wxDefaultValidator, wxTextCtrlNameStr); //El boton - wxButton * bot = new wxButton(this, 6, wxT("One Slice"), wxPoint(98, 180), wxSize(70, 25), 0, wxDefaultValidator, wxT("button")); + //wxButton * bot = + new wxButton(this, 6, wxT("One Slice"), wxPoint(98, 180), wxSize(70, 25), 0, wxDefaultValidator, wxT("button")); //Conexion del boton con su respectivo manejador Connect(6, wxEVT_COMMAND_BUTTON_CLICKED,(wxObjectEventFunction) &interfSegmentationPanelITK::onSegmentationOneSlice); diff --git a/lib/Interface_ManagerContour_NDimensions/PanelBullEyeOptions.cxx b/lib/Interface_ManagerContour_NDimensions/PanelBullEyeOptions.cxx index 68137c5..9ad2938 100644 --- a/lib/Interface_ManagerContour_NDimensions/PanelBullEyeOptions.cxx +++ b/lib/Interface_ManagerContour_NDimensions/PanelBullEyeOptions.cxx @@ -210,7 +210,7 @@ double PanelBullEyeOptions::GetAngOfCrownSection(int nCrown,int section) } else { angle = this->_lstBullEyeDetailAngle[nCrown]->GetValue(); } - double numOfSec = (double)GetNumberOfSections(nCrown); +// double numOfSec = (double)GetNumberOfSections(nCrown); double deltaSec = GetAngDeltaOfCrownSection(nCrown); return angle + section*deltaSec ; } diff --git a/lib/Interface_ManagerContour_NDimensions/wxContourMainFrame.cxx b/lib/Interface_ManagerContour_NDimensions/wxContourMainFrame.cxx index 4ca7174..365cd88 100644 --- a/lib/Interface_ManagerContour_NDimensions/wxContourMainFrame.cxx +++ b/lib/Interface_ManagerContour_NDimensions/wxContourMainFrame.cxx @@ -1024,25 +1024,25 @@ void wxContourMainFrame::SegmentationOneSliceITK(int x, int y, int z, wxString d typedef unsigned short OutputPixelType2; typedef itk::Image< OutputPixelType2, Dimension > OutputImageType2; - //Definición del thresholder + //DefiniciÛn del thresholder typedef itk::BinaryThresholdImageFilter< InternalImageType, OutputImageType > ThresholdingFilterType; - //Definición del primer filtro de conversión de pixeles + //DefiniciÛn del primer filtro de conversiÛn de pixeles typedef itk::CastImageFilter< OutputImageType, OutputImageType2 > CastFilterType; - //Definición del segundo tipo de conversión de pixeles + //DefiniciÛn del segundo tipo de conversiÛn de pixeles typedef itk::CastImageFilter< OutputImageType2, InternalImageType > CastFilterType2; - //Tercer tipo de conversión + //Tercer tipo de conversiÛn typedef itk::RescaleIntensityImageFilter< InternalImageType, OutputImageType > CastFilterType3; - //Cuarto tipo de conversión + //Cuarto tipo de conversiÛn typedef itk::RescaleIntensityImageFilter< OutputImageType, OutputImageType > CastFilterType4; @@ -1055,7 +1055,7 @@ void wxContourMainFrame::SegmentationOneSliceITK(int x, int y, int z, wxString d thresholder->SetOutsideValue( 255 ); thresholder->SetInsideValue( 0 ); - //Definción de conexiónes entre VTK e ITK y el writer + //DefinciÛn de conexiÛnes entre VTK e ITK y el writer typedef itk::VTKImageToImageFilter ConnectorType; typedef itk::ImageToVTKImageFilter ConnectorType2; typedef itk::ImageFileWriter< OutputImageType > WriterType; @@ -1271,7 +1271,7 @@ myfile.open ("C:/Creatis/example2.txt"); std::cout<<" x Anterior "< currentSelection = _sceneManager->getSelectedObjects(); - int elementsSelected = currentSelection.size(); +// int elementsSelected = currentSelection.size(); bool ctrlKey = _sceneManager->isCtrlPressed(); char toolCommand = _sceneManager->getLastKeyCode(); diff --git a/lib/Interface_ManagerContour_NDimensions/wxInstantChooserPanel.cxx b/lib/Interface_ManagerContour_NDimensions/wxInstantChooserPanel.cxx index 0bc1fed..ea1cfea 100644 --- a/lib/Interface_ManagerContour_NDimensions/wxInstantChooserPanel.cxx +++ b/lib/Interface_ManagerContour_NDimensions/wxInstantChooserPanel.cxx @@ -153,7 +153,7 @@ DEFINE_EVENT_TYPE( wxINSTANT_CHOOSER_CHANGE ) } else { - for(int i=0; i<_concepts->size(); i++) + for(int i=0; i< (int)(_concepts->size()); i++) { changeResolutionAtConceptControl( (*_concepts)[i] ); } @@ -194,7 +194,7 @@ DEFINE_EVENT_TYPE( wxINSTANT_CHOOSER_CHANGE ) { int size = _concepts->size(); wxConceptControl * aConcept = NULL; - int accum = 0; +// int accum = 0; for(int i = 0; i < eventConcept->getNumCheckBox();i++){ if(i!=groupID){ @@ -264,7 +264,7 @@ DEFINE_EVENT_TYPE( wxINSTANT_CHOOSER_CHANGE ) void wxInstantChooserPanel :: setInstant(std::vector choiceInstant) { int max = _concepts->size(); - if( choiceInstant.size() == max ) + if( (int)(choiceInstant.size()) == max ) { int i = 0; while(i< max) @@ -473,7 +473,7 @@ DEFINE_EVENT_TYPE( wxINSTANT_CHOOSER_CHANGE ) bool isChecked = false; int i,size = _concepts->size(); - wxConceptControl * aConcept = NULL; +// wxConceptControl * aConcept = NULL; for ( i=0; igetName().compare( theConceptName ) == 0 ) diff --git a/lib/kernel_ManagerContour_NDimensions/KernelManagerContour.cxx b/lib/kernel_ManagerContour_NDimensions/KernelManagerContour.cxx index 30cff36..9d3f861 100644 --- a/lib/kernel_ManagerContour_NDimensions/KernelManagerContour.cxx +++ b/lib/kernel_ManagerContour_NDimensions/KernelManagerContour.cxx @@ -76,7 +76,7 @@ std::vector KernelManagerContour::getVectImages(){ } void KernelManagerContour::setVectImages(std::vector vectimg){ - for(int i = 0; i < vectimg.size(); i++){ + for(int i = 0; i < (int)(vectimg.size()); i++){ vtkImageData* img = vectimg[i]; vtkImageChangeInformation* change = vtkImageChangeInformation::New(); change->SetInformationInput(img); @@ -103,7 +103,7 @@ void KernelManagerContour::initializeEnvironment(std::string datadir){ std::map* axesMap = new std::map(); std::map* outlinesMap = new std::map(); - for(int i = 0; i < vectimages.size(); i++){ + for(int i = 0; i < (int)(vectimages.size()); i++){ vtkImageData* selectedimage = vectimages[i]; ImageSourceThing * thing = new ImageSourceThing(selectedimage); std::string imgstring = "Source Image "+intToString(i+1); @@ -343,7 +343,7 @@ manualContourModel* KernelManagerContour::GetPoints(int z,int type, std::vector< for (int j=0 ; jAddPoint( (*vecCtrlPointX)[j] , (*vecCtrlPointY)[j] , -900 ); + manModelContour->AddPoint( (*vecCtrlPointX)[j] , (*vecCtrlPointY)[j] , 900 ); //-------------------------------------------------------------------- } // for j @@ -356,7 +356,6 @@ manualContourModel* KernelManagerContour::GetPoints(int z,int type, std::vector< }// ifSliceKeyContourExist return manModelContour; - } manualContourModel * KernelManagerContour::factoryManualContourModel(int typeContour) @@ -400,7 +399,7 @@ std::vector KernelManagerContour::getOutlinesNameAtInstant(std::vec Instant instant(&tempvector); std::vector vectcont = modelManager->getOutlinesAtInstant( &instant ); std::vector vectname; - for(int i = 0; i < vectcont.size(); i++){ + for(int i = 0; i < (int)(vectcont.size()); i++){ ContourThing **contourthing = vectcont[i]; vectname.push_back((*contourthing)->getName()); } @@ -436,7 +435,7 @@ void KernelManagerContour::getConceptsInformation(std::vector& conc vtkImageData* KernelManagerContour::getImageAtInstant(std::vector inst){ int index = inst[5]-1; - if(index < vectimages.size()&&index!=_currentIndex){ + if(index < (int)(vectimages.size())&&index!=_currentIndex){ _currentIndex=index; return vectimages[index]; } -- 2.45.1