Hello Guest

Triangle Mesh Ray Casting Collisions and Volumetric Objects

  • 0 Replies
  • 5220 Views
I am working on making a Game Engine using LWJGL, for it I'm trying to add implementation of ray collisions.

I am going to allow the following bound types, box, sphere, cylinder, capsule, cunvex hull, and triangle mesh.

All my objects in the game extend a class called RenderObject, which is where they setup the rendering for user defined shapes.

I would be able to figure out ray casting if I could figure out how to take the object verticies and create a volumetric mass, like some method of quickly knowing if a point is located inside an object, something along the lines of:

Code: [Select]
boolean collision = RenderObject.containsPointOfMass(float x, float y, float z);
How would I go about making the object into a volumetric object? Is there anything built in or semi-implemented?

Thanks in advanced.
The statement below is true.

The statement above is false.