|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Here's a little question I've been thinking about for awhile, having to do
with CSG and an added bounded_by shape.
Say I construct a CSG shape out of POV-Ray primitives--using merge,
difference or intersection-- that has a final visible shape (dimensions or
volume) of exactly
<-2, 0, -3> to <2,12,5>
and I want to add a bounding box to it.
Is is safe to use the exact same dimensions for the bounding box? Or should
I use something like
<-2.0001,-.0001,-3.0001> to <2.0001, 12.0001,5.0001>
to take care of any possible floating-point inaccuracies? The POV docs seem
to indicate that it's not a problem, but I usually do it the latter way
because I just don't know. Do floating-point problems even occur with a
bounding shape?
Ken W.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Kenneth wrote:
> Here's a little question I've been thinking about for awhile, having to do
> with CSG and an added bounded_by shape.
>
> Say I construct a CSG shape out of POV-Ray primitives--using merge,
> difference or intersection-- that has a final visible shape (dimensions or
> volume) of exactly
> <-2, 0, -3> to <2,12,5>
> and I want to add a bounding box to it.
>
> Is is safe to use the exact same dimensions for the bounding box? Or should
> I use something like
> <-2.0001,-.0001,-3.0001> to <2.0001, 12.0001,5.0001>
> to take care of any possible floating-point inaccuracies? The POV docs seem
> to indicate that it's not a problem, but I usually do it the latter way
> because I just don't know. Do floating-point problems even occur with a
> bounding shape?
>
Use something like
> <-2.0001,-.0001,-3.0001> to <2.0001, 12.0001,5.0001>
> to take care of any possible floating-point inaccuracies.
As with any CGS Co-incident surfaces(pov Help 2.2.3.6.1)should be avoided.
Post a reply to this message
|
|
| |
| |
|
|
From: Warp
Subject: Re: CSG with a bounded_by shape -- any inaccuracies?
Date: 27 Sep 2006 12:45:35
Message: <451aaaaf@news.povray.org>
|
|
|
| |
| |
|
|
Leroy <lrw### [at] joplincom> wrote:
> Use something like
> > <-2.0001,-.0001,-3.0001> to <2.0001, 12.0001,5.0001>
> > to take care of any possible floating-point inaccuracies.
> As with any CGS Co-incident surfaces(pov Help 2.2.3.6.1)should be avoided.
You should do that with *CSG*, but bounding boxes are *not* CSG. The
same rules don't apply.
Bounding boxes don't need that extra space.
--
- Warp
Post a reply to this message
|
|
| |
| |
|
|
From: Warp
Subject: Re: CSG with a bounded_by shape -- any inaccuracies?
Date: 27 Sep 2006 12:49:02
Message: <451aab7d@news.povray.org>
|
|
|
| |
| |
|
|
Kenneth <kdw### [at] earthlinknet> wrote:
> Is is safe to use the exact same dimensions for the bounding box?
Yes. Bounding boxes only affect the test whether the object is
traced at all or not. If the ray hits the bounding box then it will
also be tested against the object.
The problem with coincident surfaces with CSG happens when it's
necessary to know which one of the two surfaces is closer (which is
necessary if the two surfaces have different textures). If they
are coincident, then it's not possible to know that, and which one
ends up being chosen depends on floating point inaccuracies.
However, with bounding box testing there's no "which surface is
closer?" test. It's just: Does it hit the bounding box? If yes,
then trace the object too.
(Note that the exact same ray is used to test the bounding box
and the object. The second ray does not start from the surface of
the bounding box. Thus there's no problem.)
--
- Warp
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp <war### [at] tagpovrayorg> wrote:
> Kenneth <kdw### [at] earthlinknet> wrote:
> > Is is safe to use the exact same dimensions for the bounding box?
>
> Yes. Bounding boxes only affect the test whether the object is
> traced at all or not. If the ray hits the bounding box then it will
> also be tested against the object.
>
> ...with bounding box testing there's no "which surface is
> closer?" test. It's just: Does it hit the bounding box? If yes,
> then trace the object too.
Many thanks!! One little worry eliminated.
Ken
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp wrote:
> You should do that with *CSG*, but bounding boxes are *not* CSG. The
> same rules don't apply.
>
> Bounding boxes don't need that extra space.
You Right!
I thought I knew what I knew but I didn't know I did not know it.
Maybe stupid people should not talk and then no one would know they
are stupid.
Post a reply to this message
|
|
| |
| |
|
|
From: Thomas de Groot
Subject: Re: CSG with a bounded_by shape -- any inaccuracies?
Date: 28 Sep 2006 07:43:44
Message: <451bb570@news.povray.org>
|
|
|
| |
| |
|
|
"Leroy" <lrw### [at] joplincom> schreef in bericht
news:451### [at] joplincom...
>
> You Right!
> I thought I knew what I knew but I didn't know I did not know it.
> Maybe stupid people should not talk and then no one would know they are
> stupid.
>
Now... why does this sound familiar to me?? :-)
Thomas
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |