POV-Ray : Newsgroups : povray.general : Glass : Re: Glass Server Time
8 Aug 2024 10:22:09 EDT (-0400)
  Re: Glass  
From: Peter Popov
Date: 9 Jan 2001 02:16:28
Message: <c7el5tc1ci9jj2lg2mtj4gsn4qk3q81o6c@4ax.com>
On Tue, 9 Jan 2001 08:34:39 +0200, "J-Print News" <vir### [at] iconcoza>
wrote:

>I've been trying too figure out if PovRay renders glass correctly or not.

To an extent :)

>If you have a glass sphere that is slightly green (like normal window
>glass). With most ray tracers and renderers they just map a colour too the
>surface of the glass resulting in an even distribution of transparent green
>when rendered(like a balloon), with of course refraction added. In real life
>the centre of the sphere is actually darker because the light travels a
>longer distance through the middle of the sphere than near the edge.

In real life glass is green because it absorbs some blue and red. To
achieve the same effect, make your sphere clear white and add a
magenta absorbing media. It behaves in the exact same way as you are
asking. The surface does not need to have a color as it is infinitely
thin (in POV's way of thinking); think of it as coating. You can give
it a finish with reflection and specular highlights, of course.

>If PovRay doesn't do this, I think it should be easy too make something to
>do this: the longer the distance that the light travels through the object,
>the more light is absorbed. 

This is exactly what absorbing media does. 

You can also use light attenuation which is faster. In official POV it
is not very accurate, I think, but MegaPOV offers an alternative
formula which is real-life based.

Note: I may be thining of light fading here but I don't have Mega
installed yet to check out (did a full reinstall just yesterday).


Peter Popov ICQ : 15002700
Personal e-mail : pet### [at] vipbg
TAG      e-mail : pet### [at] tagpovrayorg


Post a reply to this message

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