Code: Select all
m_triangle[j] = btVector3(
					graphicsbase[0]*meshScaling.getX(),
					graphicsbase[1]*meshScaling.getY(),
					graphicsbase[2]*meshScaling.getZ());
Code: Select all
btTriangleIndexVertexArray* indexVertexArrays = new btTriangleIndexVertexArray(
		nIndices/3,
		const_cast<int *>(pIndices),
		sizeof(int)*3,
		nVertices,
		const_cast<float *>(pVertices),
		sizeof(Float)*3);
	m_pbtTriMeshShape = new btBvhTriangleMeshShape(indexVertexArrays);
	btTransform tr;
	tr.setIdentity();
	tr.setOrigin(btVector3(x,y,z));
	btVector3 localInertia(0,0,0);
//	m_pbtTriMeshShape->calculateLocalInertia(0,localInertia);
	m_pbtMotionState = new btDefaultMotionState(tr);
	m_pbtBody = new btRigidBody(0,m_pbtMotionState,m_pbtTriMeshShape,localInertia);
	g_DynamicsWorld->addRigidBody(m_pbtBody);
Any help as to what I'm doing wrong would be appreciated. Thanks!

