]> Creatis software - creaRigidRegistration.git/blobdiff - PackRecalage/src/bbPackRecalageCalculateVectorBox.cxx
Fix some warnings
[creaRigidRegistration.git] / PackRecalage / src / bbPackRecalageCalculateVectorBox.cxx
index 997403c02aa2f9c7effd57ce1de4294ce3482778..0891bde5ccecb0060e0d1f3fd231580c107ceda7 100644 (file)
@@ -9,24 +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<float> newX1;
-               newX1.push_back((float)bbGetInputPointsX1()[0]);
-               std::vector<float> 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<std::string> nuevo("","");
-       bbSetInputLabels1(nuevo);*/
+       _vector = new PlanesOperations();
+       std::vector<int> nullVector;
+       bbSetInputPointsX1(nullVector);
+       bbSetInputPointsX2(nullVector); 
 }
 void CalculateVectorBox::bbUserInitializeProcessing()
 {