Set a player to the 3D-surface

Started by
0 comments, last by Tom Sloper 7 years, 5 months ago

Hi!

I have a 3D-surface that consits of triangles. I want to place a player onto this surface, i.e. I have to count a Z-coord using X and Y coords of triangles. Many advices say I have to cast a ray from the player standing point vertically and thus find a crossing with a triangle plane. But actually that mean check crossing with every triangle forming our 3D-surface, moving from one triangle to another in vertex buffer, cause we don't have access to those triangles through coords - but only through their numbers in a vertex buffer. That way doesn't look very optimal. Optimization looks kinda simple: split surface onto sections, which may be accessed through the coords. But that's only my assumptions.

So, how exectly that problem is usually solved in a modern games? I think there are some standard algorithms.

Advertisement
Closing in deference to http://www.gamedev.net/topic/683639-place-a-player-onto-the-3d-surface/

-- Tom Sloper -- sloperama.com

This topic is closed to new replies.

Advertisement