Kram1032 wrote:well, there are, uh, let's count....
glossy transparent SSS
3*emitters (finally can be called materials - though, only in shaderlanguage, I guess... so probably unblendable...)
exit portal (doesn't *really* act as a material, unblendable )
*2-3 (at least) with tabulated spectrum options
~37 basic materials (not counting additional features like cauchy b) which now are highly combinable in a single shader language...
what they do (quick and dirty):
diffuse: standard non-reflecting material. Most simple of them all. Fast and effective for already many materials.... But most need something else.
diffuse transmitter: was introduced due to two things (I think):
SSS (eplained later) has one direct limitation and one for the impatient:
- It's very slow (especially with high scattering stuff)
- It's not texturable (yet)
diffuse transmitter basically is a material, that multiplies its colour to light which passes. Generally, Indigo wants volume-meshes but diffuse transmitter, besides NULL, is the only Material, REALLY allowing for flat surfaces (any non-transparent will work fine, too, but it's still better to use a volume)
A rather young material, in Indigo's history. It's a bit more realistic than diffuse, as it adds the option of backscattering to the render process... AFAIK (no guaranty for correctness), Diffuse shoots back rays at exactly the point they actually hit the surface, while Oren Nayar, based on an additional "roughness" treshold, scatters the rays around a bit "inside" the material, so that they can go out on a different place... - which is just perfect for clay, being a seemingly diffuse material which still scatters a lot. It's probably a solution for highly scattering materials, though both milk and candles (wax) will by far be approximated better with SSS... Clay is really the best example for when to use Oren Nayar.
the order of reflectivity might be
phong / phong (nk) / glossy transparent / glossy SSS
specular / specular transparent / standard SSS
phong has three factors:
colour (in rgb, usually... alternatively, as in EVERY case where you can put in "RGB", "tabulated spectrum", which might add a lot of realism to a material)
IoR (also a possible candidate for "tabulated spectrum", I think)
The exponent controls the amount of reflectivity, where
0 = entirely diffuse
infinite = entirely sharp (specular)
"perfect" mirrors (as specular) aren't quite realistic. You hardly ever will see a perfect mirror.
Also, many matte materials get totally white, when light hits them, so they aren't really diffuse, but "reflect" light but stray it quite a lot. That's an example for a very low exponent phong.
IoR controls more or less the strenght of a reflections. The higher Ior, the brighter reflections.
IoR = Reflection brightness
Exponent = Reflection sharpness
Colour = base mat (NOT reflection) colour
NK-phongs use special nk-data (something, called "complex IoR" with n being the actual IoR and k being an absorption value for a certain wavelenght) - nk replaces both colour and IoR by real measurement data from (mainly) metals. They more or less represent a preset tabulated spectrum, though they do NOT work for transparent materials (or better say, Indigo doesn't support transparent Phongs directly and the data can't be applied to other material types) That's, why Ono introduced tabulated spectrum...
NK is a very simple format. If you look into such a file, you can easily modify it and if you actually know what you're doing, you can even get colours you wanted.
Both NK data and the quite similar tabulated spectrum data seem to be rather hard to find, but Indigo already includes some very important nk-materials and some very encouraged users (CoolColJ and WytRaven) made some tabulated spectrum materials: CCJ made the tabulated Water and Wyt converted the whole collection of Schott Glasses (data from the company's own page) into usable tabulated spectrums.
Someone (who was it again? ) also did a diamond material. Water and Diamond both can be found in the Material libary and the glass stuff most likely via forum search....
Here is a list of all the nk-materials, included in Inidigo... http://deeppixel.uw.hu/projects/NK_materials.html
This actually is a huge group of materials:
first optional switch: transparent.
Here, glass first comes into the game.
If you do NOT activate transparent, specular is just like standard phong, except of three things:
1) Exponent isn't there, Specular acts as if it had an Exponent of Infinite
2) Colour now are absorption colours. Higher values actually make the material DARKER!
3) You can't use nk data.
if transparent is on, things change a bit:
Suddenly, IoR doesn't only control the reflectivity but also the refraction angle (which gets clear as soon as one understands how IoR works) http://en.wikipedia.org/wiki/Refractive_index
higher colour values will darken your colours and make it more absorbive. If you use RGB 1000 0 0, you actually get a very good cyan-pass-filter.
Also, you suddenly have more options:
cauchy b, which is a dispersion factor (extremely slow; the thing that causes rainbows)
glossy transparent, which suddenly adds the exponent back to the material (glossy transparent is more or less an transparent phong, but still without nk-support) Glossy Transparent is for example just what you need in case of frosted glass.
SSS (rather slow but impossible to avoid for realistic milk, wax, skin, cream, ........... The tabulated spectral water also uses SSS, although water scatters extremely weak. But that helps with stuff like under water sun rays, etc...)
All the last three options can be used at once, which probably is a worst case, especially if you activate the additional SSS option for spectrum or even henhey-greenstein spectrum, which is, just like cauchy b, a time overkill.
transparent specular in general is faster, the more absorption and slower, the less additional stuff it hast. Though, glossy transparent isn't significantly slower.
SSS vs. Glossy Transparent:
Glossy Transparent alone: Frosted Glass
SSS alone: Milk (although the reflection also might be blurry... so it could as well use glossy transparent but with rather high exponent.
SSS AND Glossy Transparent: Skin (which is very rough and pretty high scattering. The Exponent goes down to 10 in that special case!)
Yet an other SSS thingy: Skin
Skin isn't used that often. It's a two-layer model and it's a bit slow. The biggest problem is, that you need to model both layers, rather than Indigo searches the correct distance on its own. In many cases, it's actually easier (and often even faster) to use SSS than skin. Skin probably still is more accurate.
Atmosphere: If used in the way as intended, this is the BIGGEST time killer of all. It's a special material, simulating the sky. Or actually, it's two materials... This one is still too slow to lead to decent results in a reasonable time, except maybe if you run it through the ranch... It's a really great thing to play with, if you're interested in a *really* real atmosphere, with atmospheric scattering and such...
Ok... especially the specular section more than likely could be explained more precisely... So, now to the last few materials
NULL: Simply a totally invisible material. Was introduced for combination with Blend materials. NULL materials STILL have some odd behaviours... seemingly, they are far more complicated than it looks... especially with half transparent parts, I don't know how they might work exactly but for full black or white, they must be like "pass trough at hit; ray_bounce_counter++ " or "do not pass through at hit"
In many strange cases (improved a lot already), Null materials throw a shadow, although they're invisible....
Blend: Not really a material but something like the very first attempt on advanced material composition inside Indigo.
It has three thigs:
A (any Material to put in here)
B (any Material to put in here)
Blendfactor (linear: a*(x-1)+b*x; Gives, how strong a Material shows through. Can be textured as well)
Blends can also be blended, which leads to highly great variations of possible materials.
That would look like this:
Many material combinations, especially with specular, have highly undefined behaviour, but usually, it works as it should, anyway...
What I like to do, for instance, is to blend an SSS material (which can't be textured) with a diffuse transmitter (which just doesn't look real) to get textured SSS Works great, usually. (Still fake but less fake than other stuff, I guess...)
As said, this is NOT really a Material. What it does is, where you have an exit protal, as soon as it gets hit, light rays are proven to "find the sky" -> ray gets killed and values get calculated, based on that.
Anything around or behind an exit portal (based on it's normal direction and the relative position between cam and portal) gets cropped. If you'd only make an exit portal and a sun light inside a scene, what you'd get was a black scene with an opening, where you see the sky. That happens with BiDir on.
BiDir off somehow gives you the full sky. As you see, Exit Portals also have some undefined behaivours.
The sense of exit portals is, to use them behind windows in order to fasten up interior scenes a lot. As said, anything behind them gets invisible, except of the sky, HDR or Background light...
Thanks a lot for this explications. Very impressive.
This one is the first render of an old model for my next project .
I have a problem with the DOF, i can't figure how it work ( in Blender, it's MORE simple )