Blender
V3.3
|
Go to the source code of this file.
Classes | |
struct | btMprCollisionDescription |
struct | btMprDistanceInfo |
struct | _btMprSupport_t |
struct | _btMprSimplex_t |
Macros | |
#define | BT_DEBUG_MPR1 |
2014 Oct, Erwin Coumans, Use templates to avoid void* casts More... | |
#define | BT_MPR_SQRT sqrt |
#define | BT_MPR_FMIN(x, y) ((x) < (y) ? (x) : (y)) |
#define | BT_MPR_FABS fabs |
#define | BT_MPR_TOLERANCE 1E-6f |
#define | BT_MPR_MAX_ITERATIONS 1000 |
Typedefs | |
typedef struct _btMprSupport_t | btMprSupport_t |
typedef struct _btMprSimplex_t | btMprSimplex_t |
Functions | |
btMprSupport_t * | btMprSimplexPointW (btMprSimplex_t *s, int idx) |
void | btMprSimplexSetSize (btMprSimplex_t *s, int size) |
int | btMprSimplexSize (const btMprSimplex_t *s) |
const btMprSupport_t * | btMprSimplexPoint (const btMprSimplex_t *s, int idx) |
void | btMprSupportCopy (btMprSupport_t *d, const btMprSupport_t *s) |
void | btMprSimplexSet (btMprSimplex_t *s, size_t pos, const btMprSupport_t *a) |
void | btMprSimplexSwap (btMprSimplex_t *s, size_t pos1, size_t pos2) |
int | btMprIsZero (float val) |
int | btMprEq (float _a, float _b) |
int | btMprVec3Eq (const btVector3 *a, const btVector3 *b) |
template<typename btConvexTemplate > | |
void | btFindOrigin (const btConvexTemplate &a, const btConvexTemplate &b, const btMprCollisionDescription &colDesc, btMprSupport_t *center) |
void | btMprVec3Set (btVector3 *v, float x, float y, float z) |
void | btMprVec3Add (btVector3 *v, const btVector3 *w) |
void | btMprVec3Copy (btVector3 *v, const btVector3 *w) |
void | btMprVec3Scale (btVector3 *d, float k) |
float | btMprVec3Dot (const btVector3 *a, const btVector3 *b) |
float | btMprVec3Len2 (const btVector3 *v) |
void | btMprVec3Normalize (btVector3 *d) |
void | btMprVec3Cross (btVector3 *d, const btVector3 *a, const btVector3 *b) |
void | btMprVec3Sub2 (btVector3 *d, const btVector3 *v, const btVector3 *w) |
void | btPortalDir (const btMprSimplex_t *portal, btVector3 *dir) |
int | portalEncapsulesOrigin (const btMprSimplex_t *portal, const btVector3 *dir) |
int | portalReachTolerance (const btMprSimplex_t *portal, const btMprSupport_t *v4, const btVector3 *dir) |
int | portalCanEncapsuleOrigin (const btMprSimplex_t *portal, const btMprSupport_t *v4, const btVector3 *dir) |
void | btExpandPortal (btMprSimplex_t *portal, const btMprSupport_t *v4) |
template<typename btConvexTemplate > | |
void | btMprSupport (const btConvexTemplate &a, const btConvexTemplate &b, const btMprCollisionDescription &colDesc, const btVector3 &dir, btMprSupport_t *supp) |
template<typename btConvexTemplate > | |
static int | btDiscoverPortal (const btConvexTemplate &a, const btConvexTemplate &b, const btMprCollisionDescription &colDesc, btMprSimplex_t *portal) |
template<typename btConvexTemplate > | |
static int | btRefinePortal (const btConvexTemplate &a, const btConvexTemplate &b, const btMprCollisionDescription &colDesc, btMprSimplex_t *portal) |
static void | btFindPos (const btMprSimplex_t *portal, btVector3 *pos) |
float | btMprVec3Dist2 (const btVector3 *a, const btVector3 *b) |
float | _btMprVec3PointSegmentDist2 (const btVector3 *P, const btVector3 *x0, const btVector3 *b, btVector3 *witness) |
float | btMprVec3PointTriDist2 (const btVector3 *P, const btVector3 *x0, const btVector3 *B, const btVector3 *C, btVector3 *witness) |
template<typename btConvexTemplate > | |
static void | btFindPenetr (const btConvexTemplate &a, const btConvexTemplate &b, const btMprCollisionDescription &colDesc, btMprSimplex_t *portal, float *depth, btVector3 *pdir, btVector3 *pos) |
static void | btFindPenetrTouch (btMprSimplex_t *portal, float *depth, btVector3 *dir, btVector3 *pos) |
static void | btFindPenetrSegment (btMprSimplex_t *portal, float *depth, btVector3 *dir, btVector3 *pos) |
template<typename btConvexTemplate > | |
int | btMprPenetration (const btConvexTemplate &a, const btConvexTemplate &b, const btMprCollisionDescription &colDesc, float *depthOut, btVector3 *dirOut, btVector3 *posOut) |
template<typename btConvexTemplate , typename btMprDistanceTemplate > | |
int | btComputeMprPenetration (const btConvexTemplate &a, const btConvexTemplate &b, const btMprCollisionDescription &colDesc, btMprDistanceTemplate *distInfo) |
#define BT_DEBUG_MPR1 |
2014 Oct, Erwin Coumans, Use templates to avoid void* casts
Definition at line 24 of file btMprPenetration.h.
Definition at line 64 of file btMprPenetration.h.
Definition at line 63 of file btMprPenetration.h.
#define BT_MPR_MAX_ITERATIONS 1000 |
Definition at line 67 of file btMprPenetration.h.
Definition at line 61 of file btMprPenetration.h.
#define BT_MPR_TOLERANCE 1E-6f |
Definition at line 66 of file btMprPenetration.h.
typedef struct _btMprSimplex_t btMprSimplex_t |
Definition at line 1 of file btMprPenetration.h.
typedef struct _btMprSupport_t btMprSupport_t |
Definition at line 1 of file btMprPenetration.h.
|
inline |
Definition at line 577 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), btMprEq(), btMprIsZero(), btMprVec3Add(), btMprVec3Copy(), btMprVec3Dist2(), btMprVec3Dot(), btMprVec3Len2(), btMprVec3Scale(), btMprVec3Sub2(), btVector3, P(), and t.
Referenced by btMprVec3PointTriDist2().
|
inline |
Definition at line 866 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), btMprPenetration(), btVector3, and pos.
|
static |
Definition at line 324 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), btFindOrigin(), btMprIsZero(), btMprSimplexPoint(), btMprSimplexPointW(), btMprSimplexSet(), btMprSimplexSetSize(), btMprSimplexSize(), btMprSimplexSwap(), btMprSupport(), btMprVec3Add(), btMprVec3Copy(), btMprVec3Cross(), btMprVec3Dot(), btMprVec3Eq(), btMprVec3Len2(), btMprVec3Normalize(), btMprVec3Scale(), btMprVec3Set(), btMprVec3Sub2(), btVector3, blender::math::dot(), and v.
Referenced by btMprPenetration().
|
inline |
Definition at line 274 of file btMprPenetration.h.
References btMprSimplexPoint(), btMprSimplexSet(), btMprVec3Cross(), btMprVec3Dot(), btVector3, blender::math::dot(), _btMprSupport_t::v, and v.
Referenced by btFindPenetr(), and btRefinePortal().
|
inline |
Definition at line 165 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), and center.
Referenced by btDiscoverPortal().
|
static |
Definition at line 730 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), BT_MPR_MAX_ITERATIONS, BT_MPR_SQRT, btExpandPortal(), btFindPos(), btMprIsZero(), btMprSimplexPoint(), btMprSupport(), btMprVec3Normalize(), btMprVec3PointTriDist2(), btPortalDir(), btVector3, portalReachTolerance(), pos, and v.
Referenced by btMprPenetration().
|
static |
Definition at line 793 of file btMprPenetration.h.
References BT_MPR_SQRT, btMprSimplexPoint(), btMprVec3Add(), btMprVec3Copy(), btMprVec3Len2(), btMprVec3Normalize(), btMprVec3Scale(), pos, v, v1, and v2.
Referenced by btMprPenetration().
|
static |
Definition at line 775 of file btMprPenetration.h.
References btMprSimplexPoint(), btMprVec3Add(), btMprVec3Copy(), btMprVec3Scale(), btVector3, pos, v1, and v2.
Referenced by btMprPenetration().
|
static |
Definition at line 497 of file btMprPenetration.h.
References usdtokens::b(), btMprIsZero(), btMprSimplexPoint(), btMprVec3Add(), btMprVec3Copy(), btMprVec3Cross(), btMprVec3Dot(), btMprVec3Scale(), btPortalDir(), btVector3, pos, sum(), v, v1, and v2.
Referenced by btFindPenetr().
Definition at line 138 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), and BT_MPR_FABS.
Referenced by _btMprVec3PointSegmentDist2(), btMprVec3Eq(), btMprVec3PointTriDist2(), and portalReachTolerance().
|
inline |
Definition at line 133 of file btMprPenetration.h.
References BT_MPR_FABS.
Referenced by _btMprVec3PointSegmentDist2(), btDiscoverPortal(), btFindPenetr(), btFindPos(), btMprVec3PointTriDist2(), portalCanEncapsuleOrigin(), and portalEncapsulesOrigin().
|
inline |
Definition at line 813 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), btDiscoverPortal(), btFindPenetr(), btFindPenetrSegment(), btFindPenetrTouch(), btRefinePortal(), and result.
Referenced by btComputeMprPenetration().
|
inline |
Definition at line 108 of file btMprPenetration.h.
References _btMprSimplex_t::ps.
Referenced by btDiscoverPortal(), btExpandPortal(), btFindPenetr(), btFindPenetrSegment(), btFindPenetrTouch(), btFindPos(), btPortalDir(), portalEncapsulesOrigin(), and portalReachTolerance().
|
inline |
Definition at line 84 of file btMprPenetration.h.
References _btMprSimplex_t::ps.
Referenced by btDiscoverPortal().
|
inline |
Definition at line 119 of file btMprPenetration.h.
References Freestyle::a, btMprSupportCopy(), pos, and _btMprSimplex_t::ps.
Referenced by btDiscoverPortal(), and btExpandPortal().
|
inline |
Definition at line 89 of file btMprPenetration.h.
References _btMprSimplex_t::last, and size().
Referenced by btDiscoverPortal().
|
inline |
Definition at line 103 of file btMprPenetration.h.
References _btMprSimplex_t::last.
Referenced by btDiscoverPortal().
|
inline |
Definition at line 124 of file btMprPenetration.h.
References btMprSupportCopy(), and _btMprSimplex_t::ps.
Referenced by btDiscoverPortal().
|
inline |
Definition at line 308 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), btVector3, _btMprSupport_t::v, _btMprSupport_t::v1, and _btMprSupport_t::v2.
Referenced by btDiscoverPortal(), btFindPenetr(), and btRefinePortal().
|
inline |
Definition at line 114 of file btMprPenetration.h.
Referenced by btMprSimplexSet(), and btMprSimplexSwap().
Definition at line 177 of file btMprPenetration.h.
Referenced by _btMprVec3PointSegmentDist2(), btDiscoverPortal(), btFindPenetrSegment(), btFindPenetrTouch(), btFindPos(), and btMprVec3PointTriDist2().
Definition at line 182 of file btMprPenetration.h.
Referenced by _btMprVec3PointSegmentDist2(), btDiscoverPortal(), btFindPenetrSegment(), btFindPenetrTouch(), btFindPos(), and btMprVec3PointTriDist2().
Definition at line 211 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), and btCross().
Referenced by btDiscoverPortal(), btExpandPortal(), btFindPos(), and btPortalDir().
Definition at line 570 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), btMprVec3Len2(), btMprVec3Sub2(), and btVector3.
Referenced by _btMprVec3PointSegmentDist2(), and btMprVec3PointTriDist2().
Definition at line 192 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), btDot(), and blender::math::dot().
Referenced by _btMprVec3PointSegmentDist2(), btDiscoverPortal(), btExpandPortal(), btFindPos(), btMprVec3Len2(), btMprVec3PointTriDist2(), portalCanEncapsuleOrigin(), portalEncapsulesOrigin(), and portalReachTolerance().
Definition at line 159 of file btMprPenetration.h.
References btMprEq().
Referenced by btDiscoverPortal().
Definition at line 200 of file btMprPenetration.h.
References btMprVec3Dot(), and v.
Referenced by _btMprVec3PointSegmentDist2(), btDiscoverPortal(), btFindPenetrSegment(), btMprVec3Dist2(), and btMprVec3Normalize().
Definition at line 205 of file btMprPenetration.h.
References BT_MPR_SQRT, btMprVec3Len2(), and btMprVec3Scale().
Referenced by btDiscoverPortal(), btFindPenetr(), btFindPenetrSegment(), and btPortalDir().
|
inline |
Definition at line 642 of file btMprPenetration.h.
References _btMprVec3PointSegmentDist2(), Freestyle::a, B, btMprEq(), btMprIsZero(), btMprVec3Add(), btMprVec3Copy(), btMprVec3Dist2(), btMprVec3Dot(), btMprVec3Scale(), btMprVec3Sub2(), btVector3, C, P(), r, t, v, and w().
Referenced by btFindPenetr().
Definition at line 187 of file btMprPenetration.h.
Referenced by _btMprVec3PointSegmentDist2(), btDiscoverPortal(), btFindPenetrSegment(), btFindPenetrTouch(), btFindPos(), btMprVec3Normalize(), and btMprVec3PointTriDist2().
Definition at line 172 of file btMprPenetration.h.
Referenced by btDiscoverPortal().
Definition at line 216 of file btMprPenetration.h.
Referenced by _btMprVec3PointSegmentDist2(), btDiscoverPortal(), btMprVec3Dist2(), btMprVec3PointTriDist2(), and btPortalDir().
|
inline |
Definition at line 221 of file btMprPenetration.h.
References btMprSimplexPoint(), btMprVec3Cross(), btMprVec3Normalize(), btMprVec3Sub2(), btVector3, and v.
Referenced by btFindPenetr(), btFindPos(), and btRefinePortal().
|
static |
Definition at line 461 of file btMprPenetration.h.
References Freestyle::a, usdtokens::b(), BT_MPR_MAX_ITERATIONS, btExpandPortal(), btMprSupport(), btPortalDir(), btVector3, portalCanEncapsuleOrigin(), portalEncapsulesOrigin(), and portalReachTolerance().
Referenced by btMprPenetration().
|
inline |
Definition at line 265 of file btMprPenetration.h.
References btMprIsZero(), btMprVec3Dot(), blender::math::dot(), and _btMprSupport_t::v.
Referenced by btRefinePortal().
|
inline |
Definition at line 233 of file btMprPenetration.h.
References btMprIsZero(), btMprSimplexPoint(), btMprVec3Dot(), blender::math::dot(), and v.
Referenced by btRefinePortal().
|
inline |
Definition at line 241 of file btMprPenetration.h.
References BT_MPR_FMIN, BT_MPR_TOLERANCE, btMprEq(), btMprSimplexPoint(), btMprVec3Dot(), dot3(), _btMprSupport_t::v, and v.
Referenced by btFindPenetr(), and btRefinePortal().