2017-08-01 14:30:58 +02:00
|
|
|
#ifndef B3_CONTACT4DATA_H
|
|
|
|
#define B3_CONTACT4DATA_H
|
|
|
|
|
|
|
|
#include "Bullet3Common/shared/b3Float4.h"
|
|
|
|
|
2019-01-03 14:26:51 +01:00
|
|
|
typedef struct b3Contact4Data b3Contact4Data_t;
|
2017-08-01 14:30:58 +02:00
|
|
|
|
|
|
|
struct b3Contact4Data
|
|
|
|
{
|
2019-01-03 14:26:51 +01:00
|
|
|
b3Float4 m_worldPosB[4];
|
|
|
|
// b3Float4 m_localPosA[4];
|
|
|
|
// b3Float4 m_localPosB[4];
|
|
|
|
b3Float4 m_worldNormalOnB; // w: m_nPoints
|
|
|
|
unsigned short m_restituitionCoeffCmp;
|
|
|
|
unsigned short m_frictionCoeffCmp;
|
2017-08-01 14:30:58 +02:00
|
|
|
int m_batchIdx;
|
2019-01-03 14:26:51 +01:00
|
|
|
int m_bodyAPtrAndSignBit; //x:m_bodyAPtr, y:m_bodyBPtr
|
2017-08-01 14:30:58 +02:00
|
|
|
int m_bodyBPtrAndSignBit;
|
|
|
|
|
2019-01-03 14:26:51 +01:00
|
|
|
int m_childIndexA;
|
|
|
|
int m_childIndexB;
|
2017-08-01 14:30:58 +02:00
|
|
|
int m_unused1;
|
|
|
|
int m_unused2;
|
|
|
|
};
|
|
|
|
|
|
|
|
inline int b3Contact4Data_getNumPoints(const struct b3Contact4Data* contact)
|
|
|
|
{
|
|
|
|
return (int)contact->m_worldNormalOnB.w;
|
|
|
|
};
|
|
|
|
|
|
|
|
inline void b3Contact4Data_setNumPoints(struct b3Contact4Data* contact, int numPoints)
|
|
|
|
{
|
|
|
|
contact->m_worldNormalOnB.w = (float)numPoints;
|
|
|
|
};
|
|
|
|
|
2019-01-03 14:26:51 +01:00
|
|
|
#endif //B3_CONTACT4DATA_H
|