修正Torus几何体输出AABB包围盒不正确问题
This commit is contained in:
@@ -1017,8 +1017,8 @@ namespace hgl::graph::inline_geometry
|
||||
float maxExtent = centerRadius + torusRadius;
|
||||
float minExtent = centerRadius - torusRadius;
|
||||
|
||||
aabb.SetMinMax(Vector3f(-maxExtent, -maxExtent, -torusRadius),
|
||||
Vector3f( maxExtent, maxExtent, torusRadius)); //也许不对,待测试
|
||||
aabb.SetMinMax(Vector3f(-torusRadius, -maxExtent, -maxExtent),
|
||||
Vector3f( torusRadius, maxExtent, maxExtent));
|
||||
|
||||
p->SetBoundingBox(aabb);
|
||||
}
|
||||
|
Reference in New Issue
Block a user