From d895cb90dc27419bed9df35273b9fb5e88b30f6c Mon Sep 17 00:00:00 2001 From: Alex Cunningham Date: Tue, 16 Feb 2010 20:21:03 +0000 Subject: [PATCH] Added a static dim function to Point3 for generic detection of dimension --- cpp/Point3.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpp/Point3.h b/cpp/Point3.h index e6d3dc7b3..48350edc5 100644 --- a/cpp/Point3.h +++ b/cpp/Point3.h @@ -20,6 +20,9 @@ namespace gtsam { /** A 3D point */ class Point3: Testable, public Lie { + public: + /// dimension of the variable - used to autodetect sizes + static inline size_t dim() {return 3;} private: double x_, y_, z_;