POV-Ray : Newsgroups : povray.advanced-users : function pigment problems : Re: function pigment problems Server Time
5 Jul 2024 15:47:54 EDT (-0400)
  Re: function pigment problems  
From: sooperFoX
Date: 17 Dec 2007 06:45:01
Message: <web.4766608fd746c09b943b35b60@news.povray.org>
"Slime" <fak### [at] emailaddress> wrote:
> pigment {
>      function { Fn(x, y, z) / 1000 }
>      color_map {
>        [ 0 color Color1 ]
>        [ 1 color Color2 * 1000 ]
>      }
>    }
>
> I'm not sure I completely understand your process but this might at least
> set you on the right track. The 1000 can be as large as it needs to be.

Thanks, Slime, that works wonderfully!

The theory is that if I pre-render every possible angle for a light source, then
I can multiply each angle's image by the colour of the light coming from that
angle (which I read directly from an HDR image map) and add the images together
and I end up with pretty much the same result as if I'd used the image map as a
sky sphere.

The advantage is that once I have my pre-rendered images I can change the
lighting and it takes less than a minute to combine and render all the images,
instead of however many hours it might take to render the complete scene each
time.

Of course it take several hours to render the set.. :) It's a trade-off. But you
can store away the set for later use, then if you get a new light probe and want
to see how it might looks for a scene you can find out very quickly.

I got the idea from an article on Paul Debevec's site where he actually built a
"light stage" that does exactly this, but in the real world - you put a live
object (e.g. a person) inside the thing, take lots of photos with light coming
from different directions, then you can composite the object into a synthetic
scene and re-light to any specifications.

http://www.debevec.org/Research/LS/

The site seems to be down right now, but you can still find the text by typing
'Light stage' into google and using the cache link.

- sooperFoX


Post a reply to this message

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