]> Creatis software - creaVtk.git/commitdiff
#2453 creaVtk Feature New Normal - Stream Lines segmentation by Scalars
authordavila <eduardo.davila@creatis.insa-lyon.fr>
Thu, 25 Sep 2014 12:38:48 +0000 (14:38 +0200)
committerdavila <eduardo.davila@creatis.insa-lyon.fr>
Thu, 25 Sep 2014 12:38:48 +0000 (14:38 +0200)
bbtk_creaVtk_PKG/src/bbcreaVtkStreamLineNumeration.cxx
lib/creaVtk/creaVtkStreamLine.cpp

index f15352e0e7764cc1a25ac898d8dec08f9aad9968..578b30c936eb98dfa40b817ca9c758c98fbf009c 100644 (file)
@@ -10,8 +10,6 @@
 #include <vtkPolyData.h>
 #include "vtkIdList.h"
 
-
-
 namespace bbcreaVtk
 {
 
@@ -35,15 +33,11 @@ void StreamLineNumeration::Process()
 //    * TYPE is the C++ type of the input/output
 //      (the one provided in the attribute 'type' of the tag 'input')
 
-//    bbSetOutputOut( bbGetInputIn() );
-//    std::cout << "Output value = " <<bbGetOutputOut() << std::endl;
-
-
        std::string namascalararray="creaNumeration";
 
        if (bbGetInputStreamLinesIn()!=NULL)
        {
-               vtkIdList *_vtkidlist = vtkIdList::New();
+               vtkIdList               *_vtkidlist             = vtkIdList::New();
                vtkCellArray    *vtkcellarray           = bbGetInputStreamLinesIn()->GetLines();
                long int                nLinesCell                      = vtkcellarray->GetNumberOfCells(); 
                long int                ii,iLine;
@@ -70,8 +64,9 @@ void StreamLineNumeration::Process()
 
        bbSetOutputStreamLinesOut( bbGetInputStreamLinesIn() );
        bbSetOutputNameOfScalarArray( namascalararray );
-  
+    
 }
+
 //===== 
 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
 //===== 
index fedfcb6e1f431184563a9e37301caa55f8f13673..51685afb696fcdfeda105521262d2f2cfc910009 100644 (file)
@@ -58,7 +58,6 @@ void creaVtkStreamLine::SetPolyData( vtkPolyData* polydata)
 //---------------------------------------------
 void creaVtkStreamLine::Process()
 {
-       printf("EED creaVtkStreamLine::Process Start \n");
 
        if (_polydata!=NULL)
        {
@@ -106,11 +105,9 @@ void creaVtkStreamLine::Process()
 
                        _polydata->Modified();
 
-       printf("EED creaVtkStreamLine::Process 0 %p \n", _polydata);
 
                        if (GetTypeForm()==0) 
                        {
-       printf("EED creaVtkStreamLine::Process 1 \n");
                                _tubefilter->SetInput( _polydata );
                                _tubefilter->SetRadius( GetScaleFactor() );     
                                _tubefilter->SetNumberOfSides(12);
@@ -121,7 +118,6 @@ void creaVtkStreamLine::Process()
                        } 
                        if (GetTypeForm()==1) 
                        {
-       printf("EED creaVtkStreamLine::Process 2 \n");
                                _ribbonfilter->SetInput( _polydata );
                                _ribbonfilter->SetWidth( GetScaleFactor() );    
                                _ribbonfilter->SetWidthFactor( GetScaleFactor()*10 );
@@ -132,10 +128,8 @@ void creaVtkStreamLine::Process()
                        }                       
                        if (GetTypeForm()==2) 
                        {
-       printf("EED creaVtkStreamLine::Process 3 \n");
                                _streamMapper2->SetInput( _polydata );
                        }                       
-       printf("EED creaVtkStreamLine::Process 4 \n");
 //EED                  _streamMapper2->SetLookupTable(vGreenToRedLut);
 
 /*                     
@@ -147,27 +141,19 @@ for (int ivelocity=0; ivelocity<=4000; ivelocity++ )
 }
 _polydata->GetPointData()->AddArray(_velocity);
 */
-                       printf("EED creaVtkStreamLine::Process A \n" );
 
-                       vtkPointData    *data   = _polydata->GetPointData();
-
-printf("EED -------------------------------------------\n");
-                       _polydata->Print(std::cout);
-printf("EED -------------------------------------------\n");
-                       data->Print(std::cout);
-printf("EED -------------------------------------------\n");
 
 //                     vtkFieldData    *data   = _polydata->GetFieldData();
 //                     vtkDataArray    *da             = pointdata->GetArray("Normals");
                        
-                       int i,sizeDa = data->GetNumberOfArrays();
-                       printf("EED creaVtkStreamLine::Process  sizeDa %d \n", sizeDa );
-                       for (i=0;i<sizeDa;i++)
-                       {
-                               printf("EED creaVtkStreamLine::Process-name %d, %s \n", i, data->GetArrayName(i) );
-                               data->GetArray(i)->Print(std::cout);
-printf("EED -------------------------------------------\n");
-                       }
+//                     vtkPointData    *data   = _polydata->GetPointData();
+//                     int i,sizeDa = data->GetNumberOfArrays();
+//                     printf("EED creaVtkStreamLine::Process  sizeDa %d \n", sizeDa );
+//                     for (i=0;i<sizeDa;i++)
+//                     {
+//                             printf("EED creaVtkStreamLine::Process-name %d, %s \n", i, data->GetArrayName(i) );
+//                             data->GetArray(i)->Print(std::cout);
+//                     }
 
 
 
@@ -252,7 +238,6 @@ printf("EED -------------------------------------------\n");
        VisibilityActor(); 
    } // polydata
 
-       printf("EED creaVtkStreamLine::Process End \n");
 
 }