POV-Ray : Newsgroups : povray.advanced-users : Colision testing ? : Re: Colision testing ? Server Time
29 Jul 2024 12:26:11 EDT (-0400)
  Re: Colision testing ?  
From: Hugo
Date: 22 Apr 2002 17:24:30
Message: <3cc47f8e$1@news.povray.org>
There are many ways to do this, but you will probably have to code them
yourself, because there is no single POV-Ray "keyword" for collision
detection.

The simplest way might be the fastest: If you have 5 objects, find the size
of each object. Choose 5 locations to put your objects. Place all objects.
Check if the location of object_1 + object_1_size, is within the range of
object_2 location + object_2_size, object_3 + object_3_size ..etc.. You will
need to use a little math to check this, but I think you understand the
idea.

This idea does not consider the shape of the objects, only it's bounding
box, so it's very simple. Some people here have coded greater things, but I
don't know if they have released their code to the public.. They should
have, you know.. Heh.. ;o)

Regards,
Hugo


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.