X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=PackRecalage%2Fsrc%2FbbPackRecalageCalculateVectorBox.cxx;h=0891bde5ccecb0060e0d1f3fd231580c107ceda7;hb=1b82b60c6337722f1a97bc8f7d6eadcc90352017;hp=0290fcef7363e675eca122c7fdff9eef3c3a5830;hpb=2f92faf9b9fd4d6e5f557dbbf5094910c0addd6e;p=creaRigidRegistration.git diff --git a/PackRecalage/src/bbPackRecalageCalculateVectorBox.cxx b/PackRecalage/src/bbPackRecalageCalculateVectorBox.cxx index 0290fce..0891bde 100644 --- a/PackRecalage/src/bbPackRecalageCalculateVectorBox.cxx +++ b/PackRecalage/src/bbPackRecalageCalculateVectorBox.cxx @@ -9,25 +9,27 @@ namespace bbPackRecalage BBTK_ADD_BLACK_BOX_TO_PACKAGE(PackRecalage,CalculateVectorBox) BBTK_BLACK_BOX_IMPLEMENTATION(CalculateVectorBox,bbtk::AtomicBlackBox); void CalculateVectorBox::Process() -{ - - if(bbGetInputLabels1()[0].compare("") != 0) +{ + if(!bbGetInputPointsX1().empty() && !bbGetInputPointsX2().empty()) { - //std::vector newX1; - //newX1.push_back((float)bbGetInputPointsX1()[0]); - std::cout << "Points for first vector: " << bbGetInputPointsX1()[0] << " " << bbGetInputPointsX1()[1] << std::endl; - //std::vector newX2; - //newX2.push_back((float)bbGetInputPointsX2()[0]); + //Checks that all the vector points are defined + if(bbGetInputPointsX1()[1] != 0 && bbGetInputPointsX2()[1] != 0) + { + //_vector->SetData(bbGetInputPointsX1(), bbGetInputPointsX2(), bbGetInputPointsY1(), bbGetInputPointsY2(), bbGetInputPointsZ1(), bbGetInputPointsZ2()); + //_vector->Run(); + + //bbSetOutputOrigin(_vector->GetOrigin()); + //bbSetOutputOriginReslicer(_vector->GetOriginReslicer()); + //bbSetOutputOutAngle(_vector->GetAngle()); + } } } void CalculateVectorBox::bbUserSetDefaultValues() { - -// SET HERE THE DEFAULT INPUT/OUTPUT VALUES OF YOUR BOX -// Here we initialize the input 'In' to 0 - /* - std::vector nuevo("",""); - bbSetInputLabels1(nuevo);*/ + _vector = new PlanesOperations(); + std::vector nullVector; + bbSetInputPointsX1(nullVector); + bbSetInputPointsX2(nullVector); } void CalculateVectorBox::bbUserInitializeProcessing() {