Specular instead of lambertian for indirect

Hy everybody!

I'm Lucio, finally graduated with a thesis about tunnel lighting.

Now I'm keeping on it. And my present task is to try to obtain the best representation possible of asphalts.

Until now I used r-tables converted in Radiance's BRDF definitions the Antonutto's way (with a slightly modified calculation file), for direct contribution and using lambertian material (as requested by BRDF's definitions) for indirect light.

Now I'm going to measure asphalt photometry, with the hope of being able to individuate a Radiance specular material very close to asphalt behaviour. If it will be possible, I would then like to combine BRDF from r-table with specular materials instead of lambertian ones.

I know that I could run two simulations and then combine the results, but it would be much cleaner to be able to use a new kind of primitive able to use BRDF for direct light and a specular material for indirect light. Is it possible to develop such primitive? I'm not very skilled about programming , but I can always learn and help in developing such primitive, if you like. I guess that such kind of primitives could be handy even for other applications. What do you think about it?

Lucio

.. Caminante no hay
camino, solo se hace
camino al andar ..

          --- o
meglio ---

.. Caminante el
destino no es al
final de el viaje,
pero en todo el
andar ..

Hi Lucio,

I know that I could run two simulations and then combine the results, but it would be much cleaner to be able to use a new kind of primitive able to use BRDF for direct light and a specular material for indirect light. Is it possible to develop such primitive? I'm not very skilled about programming , but I can always learn and help in developing such primitive, if you like. I guess that such kind of primitives could be handy even for other applications. What do you think about it?

Do you want the specular part to be 'pure' -- that is, mirror-like? If so, this can be achieved easily enough by specifying a mixfunc with a fixed parameter, e.g.:

void metal specular_bit
0
5 0.1 0.1 0.1 1 0

void plasdata brdf_data
{your arguments here}

void mixfunc asphalt
4 specular_bit brdf_data 0.5 .
0

Since we are mixing half of each, you need to double each component (the specular_bit and the brdf_data), but otherwise this should work.

If, on the other hand, you want a specular component with a soft lobe, it gets a little trickier. Essentially, you want to modify your BRDF data such that the Gaussian model you are using for the specular_bit is taken out. The basic principle still applies, however.

I hope this makes sense.
-Greg

Thank you for your reply greg !

Actually I think mixfunc wouldn't fit my needs.

I try to explain what I would like to obtain from another perspective.

I would like to use a specular material representing asphalt (not mirror-like specular material). This will be obtained by trial and errors with metal primitives, using the closer rapresentation, if possible. It will lead surely to a certain error in representation, then, to minimize it, as i will have photometrics values and then BRDF definitions, I would like to use BRDF too.

If I am right, right now, BRDF can just be considered lambertian for the indirect calculation. I would like than to force Radiance to consider them specular (defining specular values by hand).

Is it possible? Is it hard? ANy suggestion for a different approach?

As about using mixfunc, if understood it right, the problem would be that direct calculation would be performed on both brdf and specular, leading me to a quite correct result (due to brdf), but influenced form the specular_bit.

As about the indirect calculation it would be influenced by specular (which is ok) but also from lambertian (indirect calculation of brdf).

Am I wrong?

Lucio

.Hi Lucio,
.
.> I know that I could run two simulations and then combine the
.> results, but it would be much cleaner to be able to use a new kind
.> of primitive able to use BRDF for direct light and a specular
.> material for indirect light. Is it possible to develop such
.> primitive? I'm not very skilled about programming , but I can
.> always learn and help in developing such primitive, if you like. I
.> guess that such kind of primitives could be handy even for other
.> applications. What do you think about it?
.
.Do you want the specular part to be 'pure' -- that is, mirror-like?
.If so, this can be achieved easily enough by specifying a mixfunc
.with a fixed parameter, e.g.:
.
.void metal specular_bit
.0
.0
.5 0.1 0.1 0.1 1 0
.
.void plasdata brdf_data
.{your arguments here}
.
.void mixfunc asphalt
.4 specular_bit brdf_data 0.5 .
.0
.0
.
.Since we are mixing half of each, you need to double each component
.(the specular_bit and the brdf_data), but otherwise this should work.
.
.If, on the other hand, you want a specular component with a soft
.lobe, it gets a little trickier. Essentially, you want to modify
.your BRDF data such that the Gaussian model you are using for the
.specular_bit is taken out. The basic principle still applies, however.
.
.I hope this makes sense.
.-Greg
.
._______________________________________________
.Radiance-general mailing list
[email protected]
.http://www.radiance-online.org/mailman/listinfo/radiance-general
.

.. Caminante no hay
camino, solo se hace
camino al andar ..

          --- o
meglio ---

.. Caminante el
destino no es al
final de el viaje,
pero en todo el
andar ..

Hi Lucio,

As about using mixfunc, if understood it right, the problem would be that direct calculation would be performed on both brdf and specular, leading me to a quite correct result (due to brdf), but influenced form the specular_bit.

This is why you would have to subtract the specular lobe from your BRDF model. In effect the BRDF would be a "correction" to the Gaussian lobe model, or at least the direct part. The indirect would be as good as it's going to be without writing your own BRDF sampler, which would be both difficult and extremely costly in any rendering you might do.

As about the indirect calculation it would be influenced by specular (which is ok) but also from lambertian (indirect calculation of brdf).

If the diffuse part of your reflectance model is zero, then there's no Lambertian calculation.

-Greg