|
|
On Fri, 14 Jan 2000 13:19:24 -0000, "Tom Melly"
<tom### [at] tomandluforce9couk> wrote:
>Hi, has anyone got any general advice/links/macros/whatever on collision
>detection in POV?
It's a rather complex task and it does not have an unique non-discrete
solution. While you could work out methods for simple primitives
(spheres, planes and boxes come to mind), general objects will require
some means of tesselation. One way which pops up into my poor
insomnia-mutilated brain is to trace a bunch of rays (say a hundred)
using, for example, Nathan's jittered spiral method, save those in an
array, and then check them against the bounds of another object. This
will be useful for the rocks-on-a-height-field case you seem to be
most interested in. Of course at least one of the objects has to have
a simple insideness test (like most primatives do).
Detecting collision of two meshes (with the face- and vertex indices
known) is another thing. It is no new thing as it's done in many
commercial packages, one just has to look around and find it. Ken's
links on povray.org whould be a good starter.
Peter Popov
pet### [at] usanet
ICQ: 15002700
Post a reply to this message
|
|