Replies: 1 comment
-
|
Hi @123uiui |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
`static float randomVertices7[20][3] = {
{ 0.875709, 0.000000, 0.000000 },
{ 0.734122, 0.000000, 0.533371 },
{ 0.313272, 0.000000, 0.964153 },
{ -0.328454, 0.000000, 1.010877 },
{ -0.863303, 0.000000, 0.627226 },
{ -1.047619, 0.000000, 0.000000 },
{ -0.836285, 0.000000, -0.607597 },
{ -0.367963, 0.000000, -1.132475 },
{ 0.338421, 0.000000, -1.041554 },
{ 0.683973, 0.000000, -0.496935 },
{ 0.836693, 0.1, 0.000000 },
{ 0.799592, 0.1, 0.580938 },
{ 0.314927, 0.1, 0.969246 },
{ -0.297332, 0.1, 0.915093 },
{ -0.693421, 0.1, 0.503800 },
{ -0.851336, 0.1, 0.000000 },
{ -0.796614, 0.1, -0.578774 },
{ -0.309294, 0.1, -0.951908 },
{ 0.307749, 0.1, -0.947155 },
{ 0.869869, 0.1, -0.631997 }
};
static void createPrism()
{
const PxVec3 * vertices = reinterpret_cast<const physx::PxVec3*>(&randomVertices7[0][0]);
int verticesCount =20;
physx::PxConvexMeshDesc convexDesc;
convexDesc.points.count = verticesCount;
convexDesc.points.stride = sizeof(PxVec3);
convexDesc.points.data = vertices;
convexDesc.flags = PxConvexFlag::eCOMPUTE_CONVEX | PxConvexFlag::eFAST_INERTIA_COMPUTATION;
//convexDesc.vertexLimit = 32;
PxTolerancesScale scale;
PxCookingParams params(scale);
params.buildGPUData=true;
PxConvexMesh* convexMesh = PxCreateConvexMesh(params, convexDesc,gPhysics->getPhysicsInsertionCallback());
}
`
Here is the code I added to this case, and it threw the exception shown in the image below.I don't know how to resolve this.is it a bug?
Beta Was this translation helpful? Give feedback.
All reactions