POV-Ray : Newsgroups : povray.binaries.images : Behavior of bounded_by : Re: Behavior of bounded_by Server Time
28 May 2022 12:41:57 EDT (-0400)
  Re: Behavior of bounded_by  
From: Kenneth
Date: 18 Apr 2022 22:45:00
Message: <web.625e20f16202874b4cef624e6e066e29@news.povray.org>
Alain Martel <kua### [at] videotronca> wrote:

>
> You are incorrectly using bounded_by as an alternative for an intersection.
> ANY ray that hit the bounded_by shape will cause the bounded_by object
> to be evaluated, even if that part is actually outside the bounded_by
> object. Even if that part is in front of the bounded_by shape.
>

I use the 'intersection' method too-- usually with a box object. A generally
trusty method starts with getting the min_extent/max_extent of the final object,
then using those vector positions for the two box corners. (Before doing this, I
center the object on the origin, more or less-- then I can multiply the
found min_extent/max_extent vectors by, for example, 1.1, which expands the box
object slightly-- just to be safe.)

I guess an alternate method would be to do this to each individual part(?) of a
CSG object like yours; but in practice, I have never needed to do that.

I rarely if ever use bounded_by shapes anymore, for the reasons that Alain and
William P mentioned. I never know if or when they will be automatically removed,
defeating their purpose.

POV-ray's automatic bounding of objects seems to do well enough in most cases,
so I only use this box intersection trick when it seems absolutely necessary. Or
to 'close up' a triangle-mesh object that is not a totally closed mesh due to
mistakes in the mesh-making. (The same trick can be used to 'solidify'
height_fields.)


Post a reply to this message

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