Integration with DART Dynamic Animation and Robotics Toolkit.
Conversion of nodes and shapes for visualizing physics simulation.
This library depends on the DART library and is built if
WITH_DART is enabled when building Magnum Integration. To use this library with CMake, put FindMagnumIntegration.cmake into your
modules/ directory, request the
Dart component of the
MagnumIntegration package and link to the
find_package(MagnumIntegration REQUIRED Dart) # ... target_link_libraries(your-app PRIVATE MagnumIntegration::Dart)
Additionally, if you're using Magnum as a CMake subproject, bundle the magnum-integration repository and do the following before calling
find_package(). Using DART itself as a CMake subproject isn't tested at the moment, so you need to provide it as a system dependency and point
CMAKE_PREFIX_PATH to its installation dir if necessary.
set(WITH_DART ON CACHE BOOL "" FORCE) add_subdirectory(magnum-integration EXCLUDE_FROM_ALL)
DART is using Eigen for mathematics and you might want to use the EigenIntegration library for easy conversion between Eigen and Magnum math types. See also the DART Physics example, Downloading and building integration libraries and Integration library usage with CMake for more information.
Optional<ShapeData> Magnum:: DartIntegration:: convertShapeNode(dart::dynamics::ShapeNode& shapeNode,
Trade:: AbstractImporter* importer = nullptr)
dart::dynamics::ShapeNode to meshes and material data.
ShapeNode is not supported. The following DART shapes are supported:
The following DART shapes are not yet supported:
PlaneShape(this is an infinite plane with normal)
importer argument is an optional instance of Trade::
dart::dynamics::ShapeNode with a shape of type
dart::dynamics::MeshShape. As a consequence, you can omit it you do not want to load such a
dart::dynamics::ShapeNode. On the contrary, when you are trying to load a
dart::dynamics::MeshShape and the importer is a
nullptr, the function will return Corrade::