For the Moveit project, I implemented a function that allows extending an AlignedBox with another AlignedBox transformed by an affine transform.
I just had the idea that it could be moved directly to Eigen if other people agree such a function makes sense. For Moveit, it does, since we merge a lot of AABBs from robot links to create one big AABB of the whole robot. So what do you think about it?
There already are two extend() implementations in Eigen::AlignedBox - one for extending with points, the other for extending by another (untransformed) AlignedBox.
I have two suggestions on how this could be ported into Eigen and I'm not sure which one would be better, so please comment.
1) Add method `extend(const AlignedBox &b, AffineTransform &a)`.
2) Add method `transform(AffineTransform &a)` that would just apply the transform on the current AlignedBox. Merging with another one could be made using the already existing `extend(AlignedBox &b)` method.
Implementation is here:
I would go for option 2, unless combining both operations really makes a difference.
It might actually be simpler to just overload operator*(Transform,AlignedBox).
The implementation you link to actually implements the requested functionality only for boxes centered at the origin.
See related PR: https://bitbucket.org/eigen/eigen/pull-requests/650/added-alignedbox-operator-isometry .
For consistency with Hyperplane and ParametrizedLine we should use a transform() method.
-- GitLab Migration Automatic Message --
This bug has been migrated to gitlab.com's GitLab instance and has been closed from further activity.
You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.com/libeigen/eigen/issues/1623.