POV-Ray : Newsgroups : povray.programming : why is mosaic preview required for radiosity? : Re: why is mosaic preview required for radiosity? Server Time
29 Jul 2024 10:29:17 EDT (-0400)
  Re: why is mosaic preview required for radiosity?  
From: Tomas Plachetka
Date: 17 Sep 1999 05:51:39
Message: <37E20F25.445EA951@uni-paderborn.de>
Niemenin Juha wrote:
> In povray.advanced-users Ron Parker <parkerr@fwi.com> wrote:
> : I think it would just run more slowly.  As far as I can tell, the
> : main purpose of the mosaic preview is to seed the cache with some 
> : good candidates for later lookups.  
> 
>   That may be right because you know a lot more about povray than I do, but
> I have the feeling that the precalculation part (which we see as "mosaic
> preview") is essential and that the radiosity method implemented by
> povray would not be possible without it.

I tried commenting out the mosaic preview. No, the mosaic preview 
is not essential - at least not for the "radiosity" code to run.
I ran both versions - with and without mosaic preview on a randomly
chosen scene. I cannot judge the quality of the picture yet. All I 
can say is that the .rca files (octrees with ambient illumination) 
do differ. But this is something what one could expect. :-)
The tracing times are (surprisingly?) almost the same.

>   Why do I think this way? Let's see the documentation:
<snip>

I rather believe the code. This is not to say that I'm the 
smartiest guy under the sun (I'm not), nor to criticise the 
quality of POV-Ray great documentation! What I mean is that 
reading the POV-Ray code is usually self-explanatory and 
instructive (well, the "radiosity" piece is an exception :-). 
No documentation, however good, can cover all the subtleties 
hidden in the code.

>   From this we can see that the 200 sample rays are not shot for each pixel
> but only once in a while. The rest is just interpolated from previous values.
>   Now, how can you interpolate previous values if you don't have them? You
> have previous values from the left and up of the image but not from the
> right and specially from down.
>   Just think about the first two pixels of the image. Ok, the ambient level
> of the first one would be fully calculated. How about the second one? You
> don't want to calculate its ambient level also but interpolate it. How can
> you do that when you only have one previous sample?
>   But we have a precalculated grid of ambient values so we can use them to
> interpolate.
>   This is why I think that the precalculation step is mandatory.
>   I may be wrong, though.

The interpolation is not dependent on any pixels, only on
previously computed ambient (illuminance) values stored in 
an octree (3D). When an ambient value for an intersection 
point is needed, the algorithm tries to reuse an already 
known value (or more ones) from the neighbourhood. If there 
is no known value in the neighbourhood, then the Monte Carlo 
shooting is performed.

The only reason for the mosaic preview seems to be a more
uniform initial distribution of the samples (as Ron says).

	y.


Post a reply to this message

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