X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=packages%2Fvtk%2Fsrc%2FbbvtkMaskPoint.cxx;fp=packages%2Fvtk%2Fsrc%2FbbvtkMaskPoint.cxx;h=061aa3d96dda3ed9a9d87a04d60b38d34350ddae;hb=360978002d02369e42cb4ab8008828613e3b8bf4;hp=58a2c739344f021adec9f3ad0871f92716aa2f94;hpb=9ca9c2a92d7d7f653ce424f477960e5a00ac0e8a;p=bbtk.git diff --git a/packages/vtk/src/bbvtkMaskPoint.cxx b/packages/vtk/src/bbvtkMaskPoint.cxx index 58a2c73..061aa3d 100644 --- a/packages/vtk/src/bbvtkMaskPoint.cxx +++ b/packages/vtk/src/bbvtkMaskPoint.cxx @@ -26,19 +26,24 @@ void MaskPoint::Process() // * TYPE is the C++ type of the input/output // (the one provided in the attribute 'type' of the tag 'input') -//EED 2017-01-01 Migration VTK7 -#if (VTK_MAJOR_VERSION <= 5) - maskpoints->SetInput( bbGetInputIn() ); -#endif -#if (VTK_MAJOR_VERSION >= 6) - maskpoints->SetInputData( bbGetInputIn() ); -#endif - maskpoints->SetOnRatio( bbGetInputRatio() ); - maskpoints->RandomModeOn(); - maskpoints->SetMaximumNumberOfPoints(5000); - maskpoints->Update(); - bbSetOutputOut( maskpoints->GetOutput() ); + if (bbGetInputActive()==true) + { + //EED 2017-01-01 Migration VTK7 + #if (VTK_MAJOR_VERSION <= 5) + maskpoints->SetInput( bbGetInputIn() ); + #endif + #if (VTK_MAJOR_VERSION >= 6) + maskpoints->SetInputData( bbGetInputIn() ); + #endif + + maskpoints->SetOnRatio( bbGetInputRatio() ); + maskpoints->RandomModeOff(); + // maskpoints->RandomModeOn(); + // maskpoints->SetMaximumNumberOfPoints(5000); + maskpoints->Update(); + bbSetOutputOut( maskpoints->GetOutput() ); + } // if Active } //===== // 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) @@ -48,6 +53,7 @@ void MaskPoint::bbUserSetDefaultValues() // SET HERE THE DEFAULT INPUT/OUTPUT VALUES OF YOUR BOX // Here we initialize the input 'In' to 0 + bbSetInputActive( true ); bbSetInputIn(NULL); bbSetOutputOut(NULL);