getAabb for plane returns min > max

ET3D
Posts: 4
Joined: Sun Oct 21, 2007 11:53 am

getAabb for plane returns min > max

Post by ET3D »

When I use getAabb on a body created from a static plane shape, I get min equal to the maximum float, and max equal to minimum float. Shouldn't this be the other way round?
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA

Re: getAabb for plane returns min > max

Post by Erwin Coumans »

ET3D wrote:When I use getAabb on a body created from a static plane shape, I get min equal to the maximum float, and max equal to minimum float. Shouldn't this be the other way round?
Are you sure you didn't swap min and max?

The implementation in btStaticPlaneShape.cpp looks fine:

Code: Select all

void btStaticPlaneShape::getAabb(const btTransform& t,btVector3& aabbMin,btVector3& aabbMax) const
{
	(void)t;
	aabbMin.setValue(btScalar(-1e30),btScalar(-1e30),btScalar(-1e30));
	aabbMax.setValue(btScalar(1e30),btScalar(1e30),btScalar(1e30));

}
Thanks,
Erwin
ET3D
Posts: 4
Joined: Sun Oct 21, 2007 11:53 am

Re: getAabb for plane returns min > max

Post by ET3D »

My mistake. It wasn't a plane but a GIMPACT shape. I'll try to look further into why this shape returns this strange AABB result.