gazebosim / gz-math

General purpose math library for robot applications.
https://gazebosim.org/libs/math
Apache License 2.0
55 stars 69 forks source link

Add function to update the axis-aligned box by a transform #75

Open osrf-migration opened 7 years ago

osrf-migration commented 7 years ago

Original report (archived issue) by Jennifer Buehler (Bitbucket: JenniferBuehler).


It would beuseful to have a function which updates the axis-aligned box coordinates/dimensions when it is transformed.

For example:

#!c++

ignition::math::Box UpdateAABB(const ignition::math::Box &_a, const ignition::math::Matrix4d &_m)

We could use the function as described in the book real-time collision detection by Christer Ericson, v. 1, p. 86, function UpdateAABB. It has been implemented in Gazebo's gazebo/physics/dart/DARTCollision.cc. It would be nice to add this function to ignition math.

osrf-migration commented 7 years ago

Original comment by Steve Peters (Bitbucket: Steven Peters, GitHub: scpeters).


I imagine it could also accept a pose since we can map a Pose to a transformation matrix.

osrf-migration commented 7 years ago

Original comment by Jennifer Buehler (Bitbucket: JenniferBuehler).


Yes, a pose would be possible too. A matrix is more general... maybe we can offer both and call the matrix version from the pose version.