1 #include "bbPackRecalageCalculateVectorBox.h"
2 #include "bbPackRecalagePackage.h"
6 namespace bbPackRecalage
9 BBTK_ADD_BLACK_BOX_TO_PACKAGE(PackRecalage,CalculateVectorBox)
10 BBTK_BLACK_BOX_IMPLEMENTATION(CalculateVectorBox,bbtk::AtomicBlackBox);
11 void CalculateVectorBox::Process()
14 if(!bbGetInputPointsX1().empty() && !bbGetInputPointsX2().empty())
16 //Checks that all the vector points are defined
17 if(bbGetInputPointsX1()[1] != NULL && bbGetInputPointsX2()[1] != NULL)
19 _vector->SetData(bbGetInputPointsX1(), bbGetInputPointsX2(), bbGetInputPointsY1(), bbGetInputPointsY2(), bbGetInputPointsZ1(), bbGetInputPointsZ2());
22 bbSetOutputOrigin(_vector->GetOrigin());
23 bbSetOutputOriginReslicer(_vector->GetOriginReslicer());
24 bbSetOutputOutAngle(_vector->GetAngle());
28 void CalculateVectorBox::bbUserSetDefaultValues()
30 _vector = new VectorMath();
31 std::vector<int> nullVector;
32 bbSetInputPointsX1(nullVector);
33 bbSetInputPointsX2(nullVector);
35 void CalculateVectorBox::bbUserInitializeProcessing()
38 // THE INITIALIZATION METHOD BODY :
40 // but this is where you should allocate the internal/output pointers
45 void CalculateVectorBox::bbUserFinalizeProcessing()
48 // THE FINALIZATION METHOD BODY :
50 // but this is where you should desallocate the internal/output pointers
55 // EO namespace bbPackRecalage