AlignedBox3d incorrect corners
Submitted by sudev
Assigned to Nobody
Link to original bugzilla bug (#476)
Version: 3.1
Description
When you create a simple cube
Eigen::AlignedBox3d box(
Eigen::Vector3d::Zero(),
Eigen::Vector3d::Ones()
);
corner vectors were as follows:
std::cout
<< Eigen::AlignedBox3d::BottomLeftFloor << " "
<< box.corner(Eigen::AlignedBox3d::BottomLeftFloor)
<< std::endl
<< Eigen::AlignedBox3d::BottomRightFloor << " "
<< box.corner(Eigen::AlignedBox3d::BottomRightFloor)
<< std::endl
<< Eigen::AlignedBox3d::TopLeftFloor << " "
<< box.corner(Eigen::AlignedBox3d::TopLeftFloor)
<< std::endl
<< Eigen::AlignedBox3d::TopRightFloor << " "
<< box.corner(Eigen::AlignedBox3d::TopRightFloor)
<< std::endl
<< Eigen::AlignedBox3d::BottomLeftCeil << " "
<< box.corner(Eigen::AlignedBox3d::BottomLeftCeil)
<< std::endl
<< Eigen::AlignedBox3d::BottomRightCeil << " "
<< box.corner(Eigen::AlignedBox3d::BottomRightCeil)
<< std::endl
<< Eigen::AlignedBox3d::TopLeftCeil << " "
<< box.corner(Eigen::AlignedBox3d::TopLeftCeil)
<< std::endl
<< Eigen::AlignedBox3d::TopRightCeil << " "
<< box.corner(Eigen::AlignedBox3d::TopRightCeil)
<< std::endl;
E Vector Eigen CornerType True CornerType
0 [0, 0, 0] BottomLeftFloor --> Bottom Left Floor
1 [1, 0, 0] BottomRightFloor --> Bottom Left Ceil
2 [0, 1, 0] TopLeftFloor --> Bottom Right Floor
3 [1, 1, 0] TopRightFloor --> Bottom Right Ceil
4 [0, 0, 1] BottomLeftCeil --> Top Left Floor
5 [1, 0, 1] BottomRightCeil --> Top Left Ceil
6 [0, 1, 1] TopLeftCeil --> Top Right Floor
7 [1, 1, 1] TopRightCeil --> Top Right Ceil
I think the correct enum values should be as follows:
BottomLeftFloor = 0,
BottomRightFloor = 2,
TopLeftFloor = 4,
TopRightFloor = 6,
BottomLeftCeil = 1,
BottomRightCeil = 3,
TopLeftCeil = 5,
TopRightCeil = 7