irr::core::aabbox3d< T >
头文件:<aabbox3d.h>
三维立体空间的边界轴
public功能函数:
构造函数:
1.aabbox3d(T minx,T miny,T min z,T maxx,Tmaxy,T maxz)
构造函数,单值非容器值
2.aabbox3d(const vector3d< T > &init)
构造函数,只用一个点
3.aabbox3d(const vector3d< T > &min, const vector3d< T > &max)
构造函数,使用容器点
功能函数:
1.addInternalBox ( const aabbox3d< T > & b )
增加一个边界盒子,参数为边界盒子
2.core::aabbox3d< T >::addInternalPoint ( T x, T y, T z )
增加一个点到边界盒子
3.addInternalPoint ( const vector3d< T > & p )
增加一个点到边界盒子
4.classifyPlaneRelation ( const plane3d< T > & plane )
判断边界盒子与plane3d的位置,若在之前,返回ISREL3D_FRONT,在之后返回ISREL3D_BACK ,在之间返回ISREL3D_CLIPPED
5.getArea ( )
获取边界盒子的表面积(平方单位)
6.getCenter ( )
获取边界盒子的中心
7.getEdges ( vector3d< T > * edges )
获取边界盒子的所有顶点到一个数组
8.getExtent ( )
获取盒子的距离(取两点最大距离)
9.getInterpolated ( const aabbox3d< T > & other, f32 d )
d=0返回other,d=1返回this,介于两者之间返回两者的混合
10.getVolume ( )
获取边界盒子的体积(立方单位)
11.intersectsWithBox ( const aabbox3d< T > & other )
判断是否与另一个轴对齐是否相交,是返回true,否返回false
12.intersectsWithLine ( const vector3d< T > & linemiddle, const vector3d< T > &linevect,
T halflength )
测试是否盒子与线相交
linemiddle:线的中点
linevect:矢量线
halflength:线的一半长
如果相交返回true,否则返回false
13.isEmpty ( )
判断盒子是否为空,是则返回true,否返回false
14.isFullInside ( const aabbox3d< T > & other )
是否完全在其他盒子之内
15.isPointInside ( const vector3d< T > & p )
是否某点在盒子之内
16.isPointTotalInside ( const vector3d< T > & p )
是否某点在盒子之内且不在边界之上
17.
operator!= ( const aabbox3d< T > & other )
operator== ( const aabbox3d< T > & other )
重载操作符,判断两个盒子关系
18.repair ( )
19.reset ( const vector3d< T > & initValue )
重置边界到点盒
20.reset ( const aabbox3d< T > & initValue )
采用盒子重置当前盒子