mirror of
https://github.com/ceres-solver/ceres-solver.git
synced 2026-08-29 08:34:37 +08:00
Allow to store pointers in ProductManifold
Change-Id: I32df7afab3a195efb0407b0d8f35dcd2d7cb95d2
This commit is contained in:
committed by
Sameer Agarwal
parent
9afe8cc45e
commit
b0aef211db
@@ -1548,6 +1548,13 @@ Manifolds can be copied and moved to :class:`ProductManifold`:
|
||||
ProductManifold<SubsetManifold, SubsetManifold> manifold(manifold1,
|
||||
manifold2);
|
||||
|
||||
In advanced use cases, manifolds can be dynamically allocated and passed as (smart) pointers:
|
||||
|
||||
.. code-block:: c++
|
||||
|
||||
ProductManifold<std::unique_ptr<QuaternionManifold>, EuclideanManifold<3>> se3
|
||||
{std::make_unique<QuaternionManifold>(), EuclideanManifold<3>{}};
|
||||
|
||||
In C++17, the template parameters can be left out as they are automatically
|
||||
deduced making the initialization much simpler:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user