00001 ///////////////////////////////////////////////////////////////////////////////// 00002 // 00003 // This file is part of the TLIB computer vision library. 00004 // Copyright (C) 2003-2008 Sebastien Grange 00005 // Copyright (C) 2003-2007 VRAI Group, EPFL 00006 // All rights reserved. 00007 // 00008 // This library is free software; you can redistribute it and/or modify 00009 // it under the terms of the GNU General Public License("GPL") version 2 00010 // as published by the Free Software Foundation. 00011 // 00012 // <http://www.tuyphon.com/tlib> 00013 // 00014 ///////////////////////////////////////////////////////////////////////////////// 00015 00016 00017 #ifndef __TLLOCATION_H__ 00018 #define __TLLOCATION_H__ 00019 00020 00021 #include "tlVision.h" 00022 00023 00024 class tlLocation 00025 { 00026 public: 00027 00028 // image location [pixel] 00029 int x; 00030 int y; 00031 int disp; 00032 00033 // world location [m] 00034 float wx; 00035 float wy; 00036 float wz; 00037 00038 00039 // constructor 00040 tlLocation (); 00041 tlLocation (int x, int y, int disp = 0); 00042 virtual ~tlLocation (); 00043 00044 // management 00045 int setLocation (int x, int y, int disp = 0); 00046 int setLocation (tlPoint *point); 00047 int shift (int dx, int dy, int ddisp = 0); 00048 00049 // set world location 00050 int setWorldLocation (float wx, float wy, float wz); 00051 00052 // retrieval 00053 tlLocation *toLocation (); 00054 int toLocation (tlLocation *location); 00055 }; 00056 00057 00058 #endif 00059