POV-Ray : Newsgroups : povray.binaries.images : Sunglasses / One way glass : Re: Sunglasses / One way glass Server Time
9 Aug 2024 11:24:37 EDT (-0400)
  Re: Sunglasses / One way glass  
From: Slime
Date: 13 Feb 2005 02:33:33
Message: <420f02cd$1@news.povray.org>
> > Maybe it's because both the front and back surface of the glass is
> > mirrored, and the light is reflecting back and forth?
>
> It would be. I'm just past considering myself a newbie, but not at the
> point where I know how to apply a different surface to the back of an
> object. (Lens is sphere - smaller_sphere)

I think there are two issues here:
 - internal reflections bouncing back and forth within the lens are
undesired
 - you want the lens to look different depending on whether you look through
the front or the back

To fix the first problem, simply specify an interior_texture on the whole
object which has no reflection:

interior_texture {
pigment {rgbt 1}
}

Then any rays which pass through the object will only be affected by the
texture information on the outer surface; when they hit the inner surface on
the way out, they'll just pass right through.

The second thing, if I understand it right, can be taken care of by using a
different texture on each sphere. On the "outer" sphere, which creates the
surface that we're currently looking through, make your dark-sunglass
texture which has very little transparency and lots of reflection. On the
"inner" sphere, the one being cut out of the outer one, apply a
mostly-transparent texture with reflection. Then the appearance of the lens
will change depending on which way you look through it.

So you'll end up with this:

difference {
sphere {...
texture {dark_texture}
}
sphere {...
texture {clear_texture}
}
interior_texture {
pigment {rgbt 1}
}
}

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

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