POV-Ray : Newsgroups : povray.general : how to prevent overlapping random objects? : Re: how to prevent overlapping random objects? Server Time
29 Jul 2024 20:13:30 EDT (-0400)
  Re: how to prevent overlapping random objects?  
From: Warp
Date: 15 Aug 2010 15:06:02
Message: <4c683a9a@news.povray.org>
Simone <inf### [at] alienenterprisesde> wrote:
> So I basically want the bunch of cylinders to look like in the picture just
> without the 4 or 5 overlapping cylinders.

  Two possible solutions:

1) Develop a complicated algorithm in SDL which checks for the intersection
   of cylinders and which skips creating those cylinders which intersect
   with existing ones.

2) Since there are only a few intersecting cylinders, make a manual exception
   list in the form of hard-coded loop index values (in other words, when
   the loop counter reaches such a value, the coordinates of the cylinder
   are calculated as normal, but the cylinder itself will not be
   instantiated). You could use an array for this.

-- 
                                                          - Warp


Post a reply to this message

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