Added a static dim function to Point3 for generic detection of dimension

release/4.3a0
Alex Cunningham 2010-02-16 20:21:03 +00:00
parent 529fc5536b
commit d895cb90dc
1 changed files with 3 additions and 0 deletions

View File

@ -20,6 +20,9 @@ namespace gtsam {
/** A 3D point */
class Point3: Testable<Point3>, public Lie<Point3> {
public:
/// dimension of the variable - used to autodetect sizes
static inline size_t dim() {return 3;}
private:
double x_, y_, z_;