![](/i/fill.gif) |
![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
In article <slr### [at] fwi com>, ron### [at] povray org
wrote:
> Media has the same issues as refraction, actually: it only gets
> calculated when you hit another face that points to the same
> interior. If you never do, media never happens.
Not quite as bad as the ior problem...you could take the media of the
faces at each end of the ray segment being sampled, and do something
like interpolate between the two while sampling, or compute both and
average their results, etc...with ior, you would have to predict the
path the ray would take, tracing curved rays...not fun.
But how useful would this be? For one thing, it would only work with
well-behaved meshes, and it wouldn't correspond to any physical
property, because there is no "right" way to do it...a better solution
would probably be to just note in the documentation that individual
triangles in a mesh can't have interiors. :-)
--
Christopher James Huff
Personal: chr### [at] mac com, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tag povray org, http://tag.povray.org/
<><
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On Wed, 03 Jan 2001 20:27:40 -0500, Chris Huff wrote:
>Not quite as bad as the ior problem...you could take the media of the
>faces at each end of the ray segment being sampled, and do something
>like interpolate between the two while sampling, or compute both and
>average their results, etc...with ior, you would have to predict the
>path the ray would take, tracing curved rays...not fun.
But you can't. POV only knows to calculate media because it thinks it's
leaving an area of one media and entering an area of the other. There
is no way to distinguish between the case you mention and the case of
hitting another object completely enclosed in the first object, so POV
will use the media specs of the first face you hit to color the ray
between the two faces, and then use the media specs of the second face
to color the ray that goes beyond the second face. That's just how it
works, and making it work any other way would be very difficult indeed.
There is a legitimate use for different interior statements on different
faces of a triangle union, and you could make the case that it should be
allowed in meshes, but the way it's done now actually is correct, and
any modification to it would break that correctness.
Picture a cube made of bicubic patches (because I hate triangles.) Give
each face of that cube the same interior (by assigning a material to the
union of faces; you can't do it any other way.) Now union another similar
cube, completely enclosed by the first cube and with a different interior.
You have a single union of bicubic patches with different interiors on
some faces, and it actually behaves correctly, physically speaking.
--
Ron Parker http://www2.fwi.com/~parkerr/traces.html
My opinions. Mine. Not anyone else's.
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
In article <slr### [at] fwi com>, ron### [at] povray org
wrote:
> But you can't. POV only knows to calculate media because it thinks it's
> leaving an area of one media and entering an area of the other. There
> is no way to distinguish between the case you mention and the case of
> hitting another object completely enclosed in the first object,
Ah, I see what you mean...it would only work with well-behaved meshes
that don't have any portion of the surface of other objects in their
interior...that is a problem.
--
Christopher James Huff
Personal: chr### [at] mac com, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tag povray org, http://tag.povray.org/
<><
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Chris Huff <chr### [at] mac com> wrote:
> In article <slr### [at] fwi com>, ron### [at] povray org
> wrote:
>> Media has the same issues as refraction, actually: it only gets
>> calculated when you hit another face that points to the same
>> interior. If you never do, media never happens.
> Not quite as bad as the ior problem...you could take the media of the
> faces at each end of the ray segment being sampled, and do something
> like interpolate between the two while sampling, or compute both and
> average their results, etc...with ior, you would have to predict the
> path the ray would take, tracing curved rays...not fun.
This wouldn't work, or rather, it'd give very strange effects. If you have
two rays that each impact two different surfaces, but intersect at a point,
there is no guarantee that the value at that point would be anything like
similar. Which means that from different angles, the object could look
completely different, because the rays calculated would be different. I'd
think you'd have to have an interpolation based upon *every* point used.
Maybe possible, but very expensive.
Geoff
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Chris Huff <chr### [at] mac com> wrote:
> In article <slr### [at] fwi com>, ron### [at] povray org
> wrote:
>> But you can't. POV only knows to calculate media because it thinks it's
>> leaving an area of one media and entering an area of the other. There
>> is no way to distinguish between the case you mention and the case of
>> hitting another object completely enclosed in the first object,
> Ah, I see what you mean...it would only work with well-behaved meshes
> that don't have any portion of the surface of other objects in their
> interior...that is a problem.
Is this correct? For some reason, I don't think it is, or at least it's
over-simplified. I've had two media objects, one within the other, and
gotten the media of both in the shared region. It seems that media is only
calcuated at the bounds of the actual object. Another object inside the
media object doesn't affect this, quite. But if the object inside is solid,
then the media should stop there, of course. If it's totally transparent,
we see the media of the surrounding object. If it's partially transparent,
the media is affected by that surface, but continues the computation for the
interior of the inside object. Have I got that right? If so, then I don't
see the problem with intersecting objects.
Geoff
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On 4 Jan 2001 08:06:39 -0500, Geoff Wedig wrote:
>Is this correct? For some reason, I don't think it is, or at least it's
>over-simplified. I've had two media objects, one within the other, and
>gotten the media of both in the shared region. It seems that media is only
>calcuated at the bounds of the actual object. Another object inside the
>media object doesn't affect this, quite. But if the object inside is solid,
>then the media should stop there, of course. If it's totally transparent,
>we see the media of the surrounding object. If it's partially transparent,
>the media is affected by that surface, but continues the computation for the
>interior of the inside object. Have I got that right? If so, then I don't
>see the problem with intersecting objects.
You're right, my explanation was oversimplified, to the extent that media
for both objects is calculated inside the inside object. But the media
in the larger enclosing object is actually calculated on three paths: First,
on the path from the outer object to the inner object. Then, on the path
inside the inner object. Finally, on the path from the inner object back to
the face of the outer object.
However, this doesn't change the fact that changing the way media is
calculated for triangles with different interiors would break existing
functionality.
--
Ron Parker http://www2.fwi.com/~parkerr/traces.html
My opinions. Mine. Not anyone else's.
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Ron Parker <ron### [at] povray org> wrote:
> On 4 Jan 2001 08:06:39 -0500, Geoff Wedig wrote:
>>Is this correct? For some reason, I don't think it is, or at least it's
>>over-simplified. I've had two media objects, one within the other, and
>>gotten the media of both in the shared region. It seems that media is only
>>calcuated at the bounds of the actual object. Another object inside the
>>media object doesn't affect this, quite. But if the object inside is solid,
>>then the media should stop there, of course. If it's totally transparent,
>>we see the media of the surrounding object. If it's partially transparent,
>>the media is affected by that surface, but continues the computation for the
>>interior of the inside object. Have I got that right? If so, then I don't
>>see the problem with intersecting objects.
> You're right, my explanation was oversimplified, to the extent that media
> for both objects is calculated inside the inside object. But the media
> in the larger enclosing object is actually calculated on three paths: First,
> on the path from the outer object to the inner object. Then, on the path
> inside the inner object. Finally, on the path from the inner object back to
> the face of the outer object.
> However, this doesn't change the fact that changing the way media is
> calculated for triangles with different interiors would break existing
> functionality.
I don't see that it'd *break* functionality. If there's a constant ior,
then everything should be as before. I do see a number of big problems for
it, though (which I've posted elsewhere)
Geoff
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On 4 Jan 2001 08:33:56 -0500, Geoff Wedig wrote:
>> However, this doesn't change the fact that changing the way media is
>> calculated for triangles with different interiors would break existing
>> functionality.
>
>I don't see that it'd *break* functionality. If there's a constant ior,
>then everything should be as before. I do see a number of big problems for
>it, though (which I've posted elsewhere)
You don't need a constant IOR either. The same example I gave for media,
that of a cube inside another cube, could apply to different IOR as well.
The point is, POV doesn't keep track of what *objects* it is in, it keeps
track of what *interiors* it is in. Refraction, media, attenuation, and
other interior effects are calculated when the ray hits a given interior
again, without regard for whether it's still in the object. (This isn't
exactly true, in that if the interiors don't "pair" right it will get
even more hopelessly confused, but it's close enough for our purposes.)
If you change the way POV acts when it encounters a surface with a different
interior from the last one it hit, you invalidate this method of bookkeeping.
If you invalidate this method of bookkeeping, you destroy the existing
property that allows well-formed unions of polygons, triangles, discs,
bezier patches, open cylinders and other surfaces of revolution, and other
patch objects to be treated as solid for the purposes of refraction, media,
attenuation, and so on.
--
Ron Parker http://www2.fwi.com/~parkerr/traces.html
My opinions. Mine. Not anyone else's.
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Ron Parker <ron### [at] povray org> wrote:
> On 4 Jan 2001 08:33:56 -0500, Geoff Wedig wrote:
>>> However, this doesn't change the fact that changing the way media is
>>> calculated for triangles with different interiors would break existing
>>> functionality.
>>
>>I don't see that it'd *break* functionality. If there's a constant ior,
>>then everything should be as before. I do see a number of big problems for
>>it, though (which I've posted elsewhere)
> You don't need a constant IOR either. The same example I gave for media,
> that of a cube inside another cube, could apply to different IOR as well.
> The point is, POV doesn't keep track of what *objects* it is in, it keeps
> track of what *interiors* it is in. Refraction, media, attenuation, and
> other interior effects are calculated when the ray hits a given interior
> again, without regard for whether it's still in the object. (This isn't
> exactly true, in that if the interiors don't "pair" right it will get
> even more hopelessly confused, but it's close enough for our purposes.)
> If you change the way POV acts when it encounters a surface with a different
> interior from the last one it hit, you invalidate this method of bookkeeping.
> If you invalidate this method of bookkeeping, you destroy the existing
> property that allows well-formed unions of polygons, triangles, discs,
> bezier patches, open cylinders and other surfaces of revolution, and other
> patch objects to be treated as solid for the purposes of refraction, media,
> attenuation, and so on.
You may be right, though it does bring up an interesting question. If I do
a CSG intersection between two objects with different interiors. What does
it do for media and ior and the like? It would seem that that you could CSG
up any mesh you wanted, though it'd be painful to do that way, with each
surface with the desired interiors, but I'm not certain about the results.
So what happens?
Geoff
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On 4 Jan 2001 12:18:41 -0500, Geoff Wedig wrote:
>You may be right, though it does bring up an interesting question. If I do
>a CSG intersection between two objects with different interiors. What does
>it do for media and ior and the like? It would seem that that you could CSG
>up any mesh you wanted, though it'd be painful to do that way, with each
>surface with the desired interiors, but I'm not certain about the results.
>So what happens?
The same thing that happens when you union together a bunch of triangles
that have different interiors: it does something that's not representative
of any physical property.
--
Ron Parker http://www2.fwi.com/~parkerr/traces.html
My opinions. Mine. Not anyone else's.
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |