POV-Ray : Newsgroups : povray.unofficial.patches : Re: Ray teleportation and multiple spaces : Re: Ray teleportation and multiple spaces Server Time
15 May 2024 01:02:59 EDT (-0400)
  Re: Ray teleportation and multiple spaces  
From: Daniel Dawson
Date: 6 Oct 2005 00:49:56
Message: <9ume13-n43.ln1@ddawson.foo>
You pick up and read article <43444e14$1@news.povray.org>, written by 
Florian Brucker  <tor### [at] torfboldcom>. It says:
>Would it be possible to have such a portal (A patch of Chris Huff called 
>it like this IIRC) working in both directions? Following example:

Well, a google search revealed just one post on here, in which Mr. Huff posts
an example image and a (now broken) link to a video. It looks exactly like what
I'm proposing. I see though he made it as a pigment. But to me, it acts more
like reflection and refraction, so it makes more sense to make it a finish
property.

I can't seem to locate the patch, though. None of the links I found are
working.

>A scene with just a plane in it, and on the plane stands a door frame. 

Very similar to my own vision of how this could be used. :-)

>Through the door you can see a room, but it's clear that the door must 
>be a portal, because you can see that the room itself is not on the 
>plane.

...which you could see by e.g. walking around the door frame...

>Up to this it could be done with the camera_pigment.

Not even this much. The image seen in the frame would be flat with camera_view,
so it wouldn't look right unless you were right in front of the door. The image
should have depth, so it looks as though what you see really is on the other
side of the door (aside from the fact there isn't really anything back there
when you look around it).

>But imagine 
>I want a light_source in the room to shine light on the plane, or an 
>object in the room to reflect the plane - this would not work currently, 
>right?

Certainly not with camera_view.

>One would need a surface which teleports incoming rays, depending 
>on which side of the surface they hit.
>
>Would this be possible? And would it be worth the effort?

I'm confident it is possible, although to make the light go both ways, you'd
need to have a portal on each end (or find a convenient way to define both ends
in one declaration, but I don't know about that). With a one-way portal, rays
would be emitted from the remote end and come to the viewing end, but any light
shining toward the portal would have no effect on the other end.

Another thing this seems to affect: photon mapping. We'd need to add something
like a 'portals' property for photons and add code to handle portals. One-way
portals would have the opposite effect on photons as on regular raytracing:
photons go only through the viewing end, due to the forward tracing.

-- 
| Email: Daniel Dawson <ddawson at icehouse.net>      ifMUD: DanDawson |
| Web: http://www.icehouse.net/ddawson/   PGP key: 'about' on web site |


Post a reply to this message

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