From 47ed8a99485155c45f1aa3e99284d77522050263 Mon Sep 17 00:00:00 2001 From: "eduardo.davila@creatis.insa-lyon.fr" Date: Tue, 21 Apr 2026 10:28:01 +0200 Subject: [PATCH] #3546 Update VectorFilterDouble --- kernel/src/bbtkBlackBox.cxx | 1 - packages/itk/src/bbitkImageReader.h | 2 +- packages/itk/src/bbitkImageWriter.cxx | 10 +--------- packages/std/src/bbstdVectorFilterDouble.cxx | 19 ++++++++++++++++--- packages/std/src/bbstdVectorFilterDouble.h | 4 ++-- 5 files changed, 20 insertions(+), 16 deletions(-) diff --git a/kernel/src/bbtkBlackBox.cxx b/kernel/src/bbtkBlackBox.cxx index b74d65a..2b82947 100644 --- a/kernel/src/bbtkBlackBox.cxx +++ b/kernel/src/bbtkBlackBox.cxx @@ -101,7 +101,6 @@ namespace bbtk std::string name = p->GetObjectName();//b->bbGetNameWithParent(); bbtkDebugMessage("object",2,"##> BlackBox::Deleter(\""<bbGetDescriptor(); bbtkDebugMessage("object",2,"##> BlackBox::Deleter(\""<xzy, k1=1 nothing xyz->xyz, k1=2 xyz->yzx { double x,y,z; double xx,yy,zz; @@ -537,8 +537,8 @@ void VectorFilterDouble::Process() Out0.push_back( In0[2] ); // z } if (k1[0]==2) { - Out0.push_back( In0[2] ); // z - Out0.push_back( In0[1] ); // y + Out0.push_back( In0[2] ); // y + Out0.push_back( In0[1] ); // z Out0.push_back( In0[0] ); // x } } // if In0.size and k1.size @@ -561,6 +561,19 @@ void VectorFilterDouble::Process() } // if size k1 == 1 } // if Type 16 + if (bbGetInputType()==17) // 17 new order verctor use k1 + { + int i,size=bbGetInputk1().size(); + for (i=0;i,""); + BBTK_INPUT(VectorFilterDouble,Type,"default (0) -1=Erase line if In0==k1, 0=Erase consecutive duplicated lines, 1=Redimention Vectors, 2=Insert intermediat points,3=Adition k1, 4=Substraction k1, 5=Multilication k1, 6=Division k1, 7=Connect mesh X1,Y1,Z1,idxs1,X2,X2,X2,idx2, 8=Order All vectors with the logic of In0 (or the index k1 if exist) , 9=Invert Vectors, 10=Nearest Point in the vector. In3PointXYZ In0LstX In1LstY In2LstZ (Out0-index Out1-PointXYZ), 11=Mul Spacing (K1[spcX,spcY,spcZ]=Spacing), 12=Div Spacing (K1[spcX,spcY,spcZ]=Spacing), 13=Distance pointIn0 and pontIn1, 14=Select specific segments [k1] in In0=lstPx In1=lstPy In2=lstPz In3=lstIndex (if k1 empty all segments are selected) , 15 swhitch element in a point k1=0 xyz->xzy, k1=1 nothing xyz->xyz, k1=2 xyz->yzx , 16 switch In0 and In1 (k1=0 nothing, k1=1 swhich), 17 new order of out vectors k1[newIndex, newIndex, newIndex]",int,""); + BBTK_INPUT(VectorFilterDouble,k1,"(default [0]) nothing (Type0), k1[0]=new size vectors (Type 1) , nothing (Type2), k1[0] = Addition const. (Type 3), k1[0] = Substraction const. (Type 4), k1[0] = Multiplication const. (Type 5) , k1[0] = Division const. (Type 6), k1[0] In0..9 element base to be order (Type 8) , k1[spcX,spcY,spcZ] MulSpc In0_X,In1_Y,In2_Z (type 11), k1[spcX,spcY,spcZ] DivSpc In0_X,In1_Y,In2_Z (type 12) , k1[segment1, segment2,..] (type 14) , direction (type 15), direction (type 16), new index order for the output (type 17)",std::vector,""); BBTK_INPUT(VectorFilterDouble,In0,"Input vector",std::vector,""); BBTK_INPUT(VectorFilterDouble,In1,"Input vector",std::vector,""); BBTK_INPUT(VectorFilterDouble,In2,"Input vector",std::vector,""); -- 2.54.0