]> Creatis software - creaMaracasVisu.git/blobdiff - lib/maracasVisuLib/src/interface/wxWindows/Contour/ContourCrownWidget.cxx
creaButtonContainer: doxygen 90%
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / Contour / ContourCrownWidget.cxx
index ba64844d8ef8dc08b5e16441471ef8e1bf7bd0b1..4ed87a8046dbdb7f7f0c15f610cbefac8592e301 100644 (file)
@@ -4,7 +4,8 @@
 #include <vtkImageMapToColors.h>
 #include <vtkImageActor.h>
 
-
+#include "wxVtk2DBaseView.h"
+#include "vtkLookupTable.h"
 
 //----------------------------------------------------------------------
   wxMaracasCoutourTool::wxMaracasCoutourTool(wxWindow *parent, wxVtkBaseView *wxvtkbaseview, vtkImageData* imagedata)
 
 
        _manContourControl_1->SetModelView( _mContourModel_1 , _mViewContour_1 );
-       this->wxvtkbaseview->GetInteractorStyleBaseView()->AddInteractorStyleMaracas( _manContourControl_1 );
+       ((vtkInteractorStyleBaseView*)this->wxvtkbaseview->GetInteractorStyleBaseView())->AddInteractorStyleMaracas( _manContourControl_1 );
        _manContourControl_1->CreateNewManualContour();
        _manContourControl_1->SetActive(false);
        _mViewContour_1->RefreshContour();
 
 
        _manContourControl_2->SetModelView( _mContourModel_2 , _mViewContour_2 );
-       this->wxvtkbaseview->GetInteractorStyleBaseView()->AddInteractorStyleMaracas( _manContourControl_2 );
+       ((vtkInteractorStyleBaseView*)this->wxvtkbaseview->GetInteractorStyleBaseView())->AddInteractorStyleMaracas( _manContourControl_2 );
        _manContourControl_2->CreateNewManualContour();
        _manContourControl_2->SetActive(false);
        _mViewContour_2->RefreshContour();
@@ -244,7 +245,7 @@ void wxMaracasCoutourTool::GetMinMaxPoint(int *minPoint,
                                                                                  )
 {
        int i;
-       int     np  = manualviewbaseecontour->GetNumberOfPoints( );  // number of control points
+       //int   np  = manualviewbaseecontour->GetNumberOfPoints( );  // number of control points // JPRx
 
 // JSTG 26-02-08 ---------------------------------------------------------------------------------------
        //int nps = manualviewbaseecontour->GetNumberOfPointsSpline(); // number of points in the spline
@@ -567,8 +568,9 @@ void wxMaracasCoutourTool::EreaseLastContour(wxCommandEvent& event)
        {
                while(!feof(fd))        
                {
-                       fscanf(fd,"");
-                       fscanf(fd," %s %d",&firstline,&size);
+//             //fscanf(fd," %s %d",&firstline,&size); // JPRx
+                       fscanf(fd," %s %d",firstline,&size);
+
                        _SizesC.push_back(size);
                        for(j=0; j<size; j++)
                        {
@@ -597,7 +599,7 @@ void wxMaracasCoutourTool::EreaseLastContour(wxCommandEvent& event)
        if(fd!=NULL)
        {
                int cont = 0;
-               for(i=0; i<_SizesC.size(); i++)
+               for(i=0; i<(int)(_SizesC.size()); i++)
                {
                        fprintf(fd,"\nNumberOfPoints %d", _SizesC[i] );
                        for(j=0; j<_SizesC[i]; j++)
@@ -637,8 +639,9 @@ void wxMaracasCoutourTool::EreaseLastCP(wxCommandEvent& event)
        {
                while(!feof(fd))        
                {
-                       fscanf(fd,"");
-                       fscanf(fd," %s %d",&firstline,&size);
+                       //fscanf(fd,"");  // ?? JPRx
+                       //fscanf(fd," %s %d",&firstline,&size);// JPRx
+                       fscanf(fd," %s %d",firstline,&size); 
                        _SizesC.push_back(size);
                        for(j=0; j<size; j++)
                        {
@@ -667,7 +670,7 @@ void wxMaracasCoutourTool::EreaseLastCP(wxCommandEvent& event)
        if(fd!=NULL)
        {
                int cont = 0;
-               for(i=0; i<_SizesC.size(); i++)
+               for(i=0; i<(int)(_SizesC.size()); i++)
                {
                        fprintf(fd,"\nNumberOfControlPoints %d", _SizesC[i] );
                        for(j=0; j<_SizesC[i]; j++)