TrifocalTensor.h
Go to the documentation of this file.
00001 /*
00002  * This file is part of ALVAR, A Library for Virtual and Augmented Reality.
00003  *
00004  * Copyright 2007-2012 VTT Technical Research Centre of Finland
00005  *
00006  * Contact: VTT Augmented Reality Team <alvar.info@vtt.fi>
00007  *          <http://www.vtt.fi/multimedia/alvar.html>
00008  *
00009  * ALVAR is free software; you can redistribute it and/or modify it under the
00010  * terms of the GNU Lesser General Public License as published by the Free
00011  * Software Foundation; either version 2.1 of the License, or (at your option)
00012  * any later version.
00013  *
00014  * This library is distributed in the hope that it will be useful, but WITHOUT
00015  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00016  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
00017  * for more details.
00018  *
00019  * You should have received a copy of the GNU Lesser General Public License
00020  * along with ALVAR; if not, see
00021  * <http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html>.
00022  */
00023 
00024 #ifndef __TRIFOCAL_TENSOR__
00025 #define __TRIFOCAL_TENSOR__
00026 
00027 #include "Alvar.h"
00028 #include <cxcore.h>
00029 #include "Pose.h"
00030 
00037 namespace alvar {
00038 
00070   class ALVAR_EXPORT TrifocalTensor {
00071   private:
00072     double T[3][3][3];
00073     double projectAxis(const CvPoint2D64f &p0, const CvPoint2D64f &p1, int l);
00074 
00075   public:
00076     TrifocalTensor();
00077 
00084     TrifocalTensor(const Pose &P1, const Pose &P2);
00085 
00093     TrifocalTensor(const Pose &P0, const Pose &P1, const Pose &P2);
00094 
00095     ~TrifocalTensor();
00096   
00107     void computeTensor(const Pose &P1, const Pose &P2);
00108   
00115     void computeTensor(const Pose &P0, const Pose &P1, const Pose &P2);
00116   
00128     void project(const CvPoint2D64f &p0, const CvPoint2D64f &p1, CvPoint2D64f &p2);
00129   
00146     double projectError(const CvPoint2D64f &p0, const CvPoint2D64f &p1, const CvPoint2D64f &p2);
00147   };
00148 
00149 } // namespace alvar
00150 
00151 #endif // __TRIFOCAL_TENSOR__


ar_track_alvar
Author(s): Scott Niekum
autogenerated on Thu Jun 6 2019 21:12:54