FG min and max radius purpose

Everywhere people are suggesting to put the Final Gather max radius to 1/10th of my scene size and the min radius to 1/10th of the max radius value.

The way I see it is that the min radius will let small objects have a much more detailed shadowy effect around them. And the max radius will let me control the smoothness of the shadowy effect.

Let’s say for example that I am rendering the front wall of a small house, this scene is 40 unit wide, so I set the min/max radius to 0.4/4. Since I have small objects (door knobs, door lamps, etc)These setting should be enough to let me have a nice FG effect.

Now I am rendering a 40 story building that takes 400 units, why should I use min/max values of 4/40? I have the same small objects in this scene (the same door knobs and door lamps) shouldn’t I use the same small values I used in my first scene? I am a bit confused by all this min/max radius value.

Can anyone help me understand this principle better?

Thanks

Final Gathering works by shooting rays within a sampled hemispherical area above the shaded points on the surfaces in your scene… This creates “light,” though it is not light in a traditional sense… it is simply illumination based on the color and brightness of the sampled shaded points.

The Min/Max radius paramaters control how many samples Mental Ray is forced to make when doing FG calculations.

In the simplest terms, the max radius is the distance, in units, that the renderer can “travel” through a scene before it is forced to sample a point.

Any areas in between those sampled areas are interpolated from the sampled areas to “fill in” those aresa not sampled.

The min radius tells Mental Ray that if there are any samples within this distance, they must be used for interpolation.

Essentially you are saying to Mental Ray “don’t travel more than the Max distance to take a sample, and if there happens to be a sample present within the Min distance, use it to interpolate results.”

The Max distance tends to impact render quality far more than the Min distance.

Most of the time, the higher the Min/Max settings, the faster FG will go, as it doesn’t have to take as many samples… say if your Max radius is 5, Mental Ray is forced to sample every 5 units, but if it is 50, it doesn’t have to sample until every 50th unit… that is not to say it won’t sample in between where needed, it is just not “forced” to.

Even though higher values tend to make FG go faster, shading quality is lost because less samples are being considered. That is not to say that there will be more artifacts with shading, just that there will be less “value” to the shadows… sometimes to the point of no shadows being visible at all.

So, yes, you are right that smaller values will make shading on smaller objects appear better. The Min/Max values are not a precise science, really. Even though the general rule is 10% of the scene for Max, and 10% of that for Min, sometimes you want more shadow detail than those values will give you… and sometimes that is not so important, so you might want to set it higher to go faster.

It should also be noted that when using photon mapping (GI) in conjunction with FG, less FG rays are needed and you can get away with higher Min/Max values, since when FG is used along with GI, it acts as a “last bounce” of light. Its primary purpose when used with GI is to “smooth out” the photon map result, hence you can, and should, use less photons when also using FG. The general rule for this is that, when using FG, you cast 1/10 of the required photons cast when not using FG.

I hope that clears things up some, and I hope I didn’t mess up any of the information ; )

-Steve

Thanks that was a great answer!

When you say that Max distance tends to impact render quality far more than the Min distance, While testing different settings to try removing flickering to happend in a FG only rendered animation, I discovered that using values of 1/10 or 1/100 didn’t change the overall look that much, where if I would use values of 0.1/10 instead of 1/10 the overall look is a lot more different. With 0.1/10 settings, I would get sharper shadows effects but more flickering during the course of the animation.

Anyway, I will continue my testings with that in mind. It will surely help me understand what is going on.

Thanks again

actually, what you are saying at the min values makes sense… everything in my response was from personal experience and understanding except for the comment about min not affecting renderings as much as max… that comment comes directly out of “rendering with mental ray.”

however, since the min value is forcing the renderer to use samples within an area for interpolation, if you had a value of 1/10 and a value of 1/100, it is still using samples within that 1 unit range for interpolation, thus it should look highly similar…

I dunno, maybe I misread it.

Anyway, by and large, when I am just doing tests and don’t feel like measuring things, I just set it to 10/100 and it goes relatively fast… its high enough to cover even rather large scenes, and for smaller scenes, it cuts through real fast, even if its not as “deep” FG shading… but since I just about never do FG renders without GI, it works for me…

anyway, I don’t necessarily recommend using one value for all your FG tests, though, I am just lazy ; )

-Steve

So, does this mean, that the max radius has an influence on where MR samples FG (say, the distance would exceed the radius), whereas min radius only influences the inter/extrapolation of the results…?

-k

As far as I understand it, yes, thats how it works… but I am not 100% sure on that.

That info is taken from “Rendering With Mental Ray,” as well as personal experience, so I believe it’s correct… but, again, I am not 100% positive.

I am sure I don’t have to tell you that any information on Mental Ray anywhere is usually very convoluted and often-times self-contradictory, but to the best of my understanding, this is how it works ; )

-Steve

I own this book myself and it quite often leaves me confused (maybe its due to my bad english).

I’m still trying to get a flickerfree animation with HDR images (without success). So, it seems a good (full force)approach would be to first set the FG Rays really high and the min radius really small, leaving the max radius at a medium level (to soften it out)?
As you said, it’s very hard to get absolute truth about MR (especially in maya context).

-k

That’s exactly how I finaly made a almost-flicker free animation. By using low min/max (1/10) and extremely high rays. I am now at 50 000 in some scenes. Of course it takes forever to render, but it’s almost flicker free.