release/4.3a0
dellaert 2014-12-03 16:51:22 +01:00
parent c7676f1012
commit 316bde9427
1 changed files with 20 additions and 4 deletions

View File

@ -102,14 +102,30 @@ Examples
An example of implementing a Manifold is here:
// GTSAM type
class Rot2 {
...
class Chart {
...
}
}
namespace gtsam {
namespace traits {
// types:
template<typename T>
struct SomeAssociatedType<T>::type
template<>
struct DefaultChart<Rot2> {
typedef Rot2::Chart type;
}
template<>
struct Manifold<Rot2::Chart> {
typedef Rot2 type;
}
template<>
struct Vector<Rot2::Chart> {
typedef Vector2 type;
}
}