OPCODE Collision Detection Library, example code

Hello,

I would like to use the collision detection routine from the OPCODE library, newest version 1.3
There exist documentations, e.g. Opcode.pdf and OpcodeUserManual.pdf, but they do not agree with
the source code, neither the current nor the previous version 1.2.

Does anyone have a simple and working example to check if to meshes collide?
I only would like to define the meshes using triangles and connectivities (no callback function).

I have compiled the OPCODE library statically and dynamically using no callbacks but pointers successfully, but failed to build up a small example as listed below.
Thanks in advance!

Regards
Oliver

#include <Opcode.h>
using namespace Opcode;

int main(void)
{
IceMaths::IndexedTriangle *Tri0 = new IceMaths::IndexedTriangle[10];
IceMaths::Point *Pnt0 = new IceMaths::Point[10];
MeshInterface Mesh0;
Mesh0.SetNbTriangles(10);
Mesh0.SetNbVertices(10);
Mesh0.SetPointers(Tri0, Pnt0);

OPCODECREATE OPCC;
OPCC.SetMeshInterface(&Mesh0);
OPCC.Build();

AABBTreeCollider TC;
TC.SetFirstContact(true);
TC.SetFullBoxBoxTest(false);
TC.SetFullPrimBoxTest(false);
TC.SetTemporalCoherence(false);
Topic archived. No new replies allowed.