From: Eduardo DAVILA Date: Thu, 3 Jan 2019 15:57:53 +0000 (+0100) Subject: TemporalPicker X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=84bd7e760e867fc3fdb3e0b42247522fb1630cba;p=bbtk.git TemporalPicker --- diff --git a/packages/vtk/src/bbvtkTemporalPicker.cxx b/packages/vtk/src/bbvtkTemporalPicker.cxx index de51251..0afbc5d 100644 --- a/packages/vtk/src/bbvtkTemporalPicker.cxx +++ b/packages/vtk/src/bbvtkTemporalPicker.cxx @@ -30,6 +30,9 @@ //===== #include "bbvtkTemporalPicker.h" #include "bbvtkPackage.h" + +#include "creaVtk_MACROS.h" + namespace bbvtk { @@ -71,37 +74,59 @@ void TemporalPicker::Process() sizeY=ext[3]-ext[2]+1; sizeZ=ext[5]-ext[4]+1; + if (bbGetInputPoint().size()>=2) { int px=bbGetInputPoint()[0]; int py=bbGetInputPoint()[1]; - int pz=bbGetInputPoint()[2]; +//EED Eraseme int pz=bbGetInputPoint()[2]; + + int minX,maxX,minY,maxY; + minX = px-bbGetInputSizeRegion()-1; + maxX = px+bbGetInputSizeRegion()-1; + minY = py-bbGetInputSizeRegion()-1; + maxY = py+bbGetInputSizeRegion()-1; - if ((px>=0) && (px=0) && (py=0) && + (maxX=0) && + (maxY=0) && (i=0) && (j=0) && (i=0) && (jGetScalarComponentAsDouble(i, j, k, 0); numElem++; - }// i j +// }// if i j }// for j } // for i +*/ + + + if (numElem>0) { result.push_back( acum/numElem );