POV-Ray : Newsgroups : povray.newusers : The Mathematics Behind Spotlights : Re: The Mathematics Behind Spotlights Server Time
30 Jul 2024 00:19:24 EDT (-0400)
  Re: The Mathematics Behind Spotlights  
From: Slime
Date: 4 Dec 2004 17:34:56
Message: <41b23b90$1@news.povray.org>
> What if I told you that the SAME EFFECT could be obtained by creating some
> functions that *simulate* spotlight intensity at all points in it's cone
> and then using those functions in some EMITTING media which can be maybe
> 100 times faster than scattering media in a slightly detailed image (no
> joke).

This is a trick that I use fairly often to create media lighting effects.
There is, however, one crucial difference: the lack of shadows. Not just
shadows of objects, but self-shadowing of the media. In a dense scattering
media, you'll notice that parts farther away from the light are darker
because they are shadowed by the media closer to the light. That effect
doesn't happen with emitting media. If you're willing to live with this (and
often that's not a problem for me), then the shortcut is fine.

This is probably the biggest reason for the slowness of scattering media;
each sample (and there are many samples for each ray), requires a shadow ray
which also takes a number of samples.

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


Post a reply to this message

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