]> Creatis software - creaRigidRegistration.git/blobdiff - lib/VectorMath.h
*** empty log message ***
[creaRigidRegistration.git] / lib / VectorMath.h
index 9eafe8bf22c7e05b7f824637b28e86fd6112fdcd..a16e453094da9d2b28b2dce11d520f552fad9b5c 100644 (file)
@@ -8,17 +8,41 @@ class VectorMath{
 public: 
        VectorMath();
     ~VectorMath();
+
+       /*Sets all the vector points*/
        void SetData(std::vector<int> pointsX1, std::vector<int> pointsX2, std::vector<int> pointsY1, std::vector<int> pointsY2, std::vector<int> pointsZ1, std::vector<int> pointsZ2);
+       
+       /*Runs the calculations*/
        void Run();
+       
+       /*Returns the origin of the second vector*/
        std::vector<int> GetOrigin();
+
+       /*Returns the origin of the first vector*/
        std::vector<int> GetOriginReslicer();
+       
+       /*Returns the cross product of the two vectors*/
        void GetResult(double result[3]);
+
+       /*Rotation angle (dot product)*/
        double GetAngle();
+
+       /*Scale in X*/
        double GetScaleX();
+
+       /*Scale in Y*/
        double GetScaleY();
+
+       /*Scale in Z*/
        double GetScaleZ();
        
 private:
+       ///////////////////
+       /* Vector Points */
+       ///////////////////
+       
+       /*The points are defined by the following naming pattern: _point[axis(x,y or z)][vector(1 {first image} or 2{second image})][a{starting piont} or b{end point}]*/
+       
        int _pointx1a;
        int _pointx1b;
        int _pointx2a;
@@ -33,6 +57,10 @@ private:
        int _pointz1b;
        int _pointz2a;
        int _pointz2b;
+
+       //////////////////
+       /* Results   */
+       /////////////////
        
        std::vector<int> _origin;
        std::vector<int> _originReslicer;