POV-Ray : Newsgroups : povray.advanced-users : Random placement of objects : Re: Random placement of objects Server Time
26 Jun 2024 05:28:09 EDT (-0400)
  Re: Random placement of objects  
From: MichaelJF
Date: 29 Aug 2013 13:55:00
Message: <web.521f89a39c8700268507740b0@news.povray.org>
I just played around a bit, since collision detection would be a nice thing. It
seems that intersections of solid objects gives a finite bounding box if there
is an intersection and an infinity one

box { <-10000000000,10000000000> }

if there is no intersection. May be one of the more experienced users here knows
the answer. It seems to work with spheres and boxes.

But one has to store all objects in an Array since one has to test every new one
against all existing. In special cases there are optimisations. May be you would
like to study the code of Jonathan Hunts "pebbles". You find the link within the
POV Hall of Fame.

Best regards,
Michael


Post a reply to this message

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