Announcement

Collapse
No announcement yet.

The relationship between Reflection Amount, Glossiness, and Diffuse.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • The relationship between Reflection Amount, Glossiness, and Diffuse.

    The relationship between Reflection Amount, Glossiness, and Diffuse has been one of those things I’ve always wanted to have a deeper understanding of in order to control these values in a more real-world physics based way during material creation.

    From a real-world dielectric material standpoint, 100% Reflectivity (specular) would be at one end of the reflection spectrum, while 100% Diffuse would be at the other end. Glossiness (roughness) serves as a transition between these two - in essence simulating the roughness of the material surface.

    So basically:
    The smoother the micro-surface of the material is, the more reflective (specular) it appears.
    The rougher the micro-surface of the material is, the more diffuse it appears.

    However, this isn’t how the glossiness parameter in V-Ray (or other renderers I’ve used for that matter) behaves:
    A Reflection value of 0.0 gives a 100% Diffuse surface.
    A Reflection value of 1.0 with a Glossiness value of 1.0 gives a 100% Reflective surface.
    A Reflection value of 1.0 with a Glossiness value of 0.0 gives a very reflective rough surface - with no diffuse color.

    Click image for larger version

Name:	vray_glossiness.jpg
Views:	1
Size:	92.1 KB
ID:	879698

    I understand this is happening because “zero glossiness is not equal to pure diffuse reflection for the Phong, Blinn and Ward models (simply because of the way their authors defined them)”. Reflection in these BRDFs is treated as a layer on top of the Diffuse component - so a reflection value of 1.0 will completely override the Diffuse component regardless of what value Glossiness is set to.

    So my first question is:
    Is there a specific reasoning behind why these BRDFs don’t treat the Glossiness value in the more ‘real-world’ sense outlined above? Are there BRDFs that do? Can this be implemented in V-Ray?

    My second (and possibly more immediately useful) question is:
    In the mean time, can we come up with a formula or ratio we can generally follow to emulate the real-world behavior of Glossiness? For instance, if I want to make a material that appears 50% Diffuse and 50% Reflective (specular) - is there some way to use those known values to find a corresponding Glossiness value that most closely reproduces what we’d see in real life? You could also go the other way and set your Glossiness to what you want visually, and then use this formula to figure out roughly what Reflection amount the material should have.

    Hope that makes sense! Looking forward to illuminating the subject a bit.
    Last edited by RockinAkin; 05-04-2014, 05:37 PM.
    Akin Bilgic | CGGallery.com
    Modeler & Generalist TD

    V-Ray Render Optimization
    V-Ray DMC Calculator

  • #2
    This dont make sense to me. More glossy surface does not mean more diffuse surface. Look at brushed chrome metals and so on.

    1st thing you should look at is Fresnel and ALWAYS use it. If you don't use it your material is not physically accurate. Either use simplified Fresnel or more complex one with curve if you have data to accurately and properly represent it.
    CGI - Freelancer - Available for work

    www.dariuszmakowski.com - come and look

    Comment


    • #3
      Originally posted by Dariusz Makowski (Dadal) View Post
      This dont make sense to me. More glossy surface does not mean more diffuse surface. Look at brushed chrome metals and so on.

      1st thing you should look at is Fresnel and ALWAYS use it. If you don't use it your material is not physically accurate. Either use simplified Fresnel or more complex one with curve if you have data to accurately and properly represent it.
      Yes of course. No one isn't using Fresnel - I hoped it was clear that I was just providing a simplified hypothetical to make it easier to understand what I'm talking about.

      From my understanding, you're incorrect in your first sentence - for dielectric materials, a rougher (less glossy) surface DOES mean a more diffuse surface and less specular reflectivity.
      Last edited by RockinAkin; 05-04-2014, 04:25 PM.
      Akin Bilgic | CGGallery.com
      Modeler & Generalist TD

      V-Ray Render Optimization
      V-Ray DMC Calculator

      Comment


      • #4
        HUmh, yea I'm still lost :- )

        If you want more accurate materials you need to turn your eyes towards scanned materials which will be a lot more accurate as well as limited in their flexibility.

        http://people.csail.mit.edu/addy/research/brdf/
        Last edited by Dariusz Makowski (Dadal); 05-04-2014, 04:34 PM.
        CGI - Freelancer - Available for work

        www.dariuszmakowski.com - come and look

        Comment


        • #5
          I was also under the impression that a rough surface doesn't mean a more diffuse surface. At the end of the day if you go down to the molecular level it doesn't make a difference?
          admin@masteringcgi.com.au

          ----------------------
          Mastering CGI
          CGSociety Folio
          CREAM Studios
          Mastering V-Ray Thread

          Comment


          • #6
            Originally posted by grantwarwick View Post
            I was also under the impression that a rough surface doesn't mean a more diffuse surface. At the end of the day if you go down to the molecular level it doesn't make a difference?
            Well it's the stuff that happens at the microscopic level that's exactly what these BRDFs are trying to simulate. The varying amounts of Specular Reflection, Glossiness, and Diffuse Reflection are all the result of the molecular makeup of a material.

            Lets take a material like wood (a dielectric) for example:
            Light hits and enters the surface of the wood, encounters the many different angles of the rough surface and open molecular structure. Some wavelengths of light get absorbed, while other get reflected back out in a wide angle of directions - making up the Diffuse color of the wood.
            However, if you were to smooth the surface of the wood with finer and finer sandpaper, the surface becomes more glossy (aka Specular reflective). In this case the light hits the smoother surface, some wavelengths still penetrate and get absorbed, while others get reflected in a narrower spread of angles - and if this spread of reflection gets narrow enough, you'll actually be able to see the sources of light in the reflection - making up the Specular reflection of the wood.

            So in this case, the only thing that's changed is the roughness (glossiness) of the material, and it's transitioned the material from diffuse reflective to specular reflective.

            (My explaination is a bit over-simplied, read Rens' writeup below instead - he did a much more thorough job of explaining it.)

            Last edited by RockinAkin; 06-04-2014, 12:52 PM.
            Akin Bilgic | CGGallery.com
            Modeler & Generalist TD

            V-Ray Render Optimization
            V-Ray DMC Calculator

            Comment


            • #7
              Keep in mind that the light coming from an object will come from both the surface and the subsurface of a material.

              If we're just talking about light being scattered back out and not about transmittance (refraction), then only the surface can produce a smooth specular reflection. Specular as in mirror-like.



              For most non-metals the biggest percentage of light being bounced back out will come from the sub-surface. The sub-surface is what gives the material its 'colour', meaning some wavelengths don't make it back out. For most materials it's as scattered as you can get (Lambert).

              The light being reflected from the surface will not be tinted; white light will be reflected as white light. The direction and/or roughness of the reflection depends on the topology of the surface, micro and macro. The amount of light reflected back depends on the material.

              So what happens when light hits a dielectric/non-metallic surface. First a part gets bounced back from the surface, this can be in several directions depending on the surface structure and the amount can be calculated with the Fresnel equation. The remainder will go through to the sub-surface where it's either absorbed and turned into heat or re-emitted. If it's not absorbed then it can go through in roughly the same direction it came in with, which is transmittance, think glass, or it can scatter around and go either back towards the surface and exit there or go deeper in and maybe go out the other side. As it will mostly scatter around quite a few times the direction is very randomised.

              Very dark materials might have more light being reflected from the surface than from the sub-surface, as the light just gets absorbed there. If the micro-topology is so that the surface reflection might actually hit another part of the surface it will start the game over and it might get reflected back from the surface again or go on to the sub-surface. In this case the Fresnel ratio of light coming from the surface will not hold up and this is more so the case when a surface gets rougher.



              For metals most of the light being reflected will come from the surface as opposed to non-metals where it's the sub-surface. Here the amount being reflected back from the surface is very wavelength-dependent this is what gives metals their 'colour', again opposed to non-metals.

              Light being reflected from the surface will get absorbed more or less easily depending on the wavelength of the light. Gold will reflect back more red light than blue light. White light will be reflected back yellow/orange in this case. Also here the direction will depend on the topology. The amount of light being reflected for each wavelength depends on the material.

              What goes through to the sub-surface is usually not a lot and there it's very readily absorbed. Metals do transmit/refract light though, but that's only visible in very veeery thin sheets. For our calculations we can pretty much discard the sub-surface part. Light gets reflected back from the surface according to the full Fresnel equations and it's important to calculate this for red, green and blue. Also here surface reflections might hit the surface again if the surface is rough.

              Because only metals reflect so much from their surface and because only surfaces can give mirror-like reflections only metals are used for mirrors. You'd see about 10 to 20 times less of yourself in a smooth piece of plastic. Actually if you look closely at a mirror you see two reflections, a faint one from the glass cover and one from the metal backside.



              In CG the sub-surface reflection going back out through the front surface is usually called Diffuse, Colour or Albedo. Light going through the sub-surface and out the other side is called Refraction, Translucency or Opacity. SSS shaders cover both these reflections.
              The surface reflection part is called Reflection and/or Specular.

              Technically speaking you should use only surface reflection parameters to describe a metal. Obviously though it's a lot easier to calculate a very rough surface compared to a very smooth surface as you don't have to trace as many rays. If you roughen the surface of a metal enough it will be much more effective to just set it with a Diffuse parameter instead of using Reflection and then wildly trace rays to get to the same result as a Lambert shader.



              To answer your question Akin, it would be nice to have a slider that goes from a 100% randomised Lambertian direction to 0% mirror-like reflection for surface reflections. The same goes for for transmittance. In the meantime you could progressively blend in the diffuse part the rougher a surface gets. It's not 100% technically correct especially where it's about 50% rough but it works well enough.



              I've said it here and on CGTalk a couple of times now, material parameters are named very confusingly. I'd like to see a shader where it's split up in surface and sub-surface and just a roughness and a direction (multiple lobes, closer to normal, etc.) parameter for both reflectance and transmittance.

              For a simple non-metal setup you can set the roughness for the surface and the sub-surface. If you want glass-like refractions you can lower the roughness for the sub-surface. You'd need an absorbtion parameter as well which will set both the depth and colour of the sub-surface (the Diffuse). This will allow for SSS results as well. Then set the IOR and you're done.

              For metals the sub-surface wouldn't matter and you could set the surface reflection by colour for ease of use or by entering the two Fresnel parameters for metals for red, green and blue each. Then adjust surface roughness.

              Of course I'd like to be able to tweak the amount of reflection vs. specular rays and things like that for speed, but for a simple setup that would make more sense and it would be a lot easier to understand what happens when light hits a surface without having to blend multiple Vray mats with SSS shaders and not understand why you're actually doing that; it's because there are different shaders for different kinds of roughness and transmittance.

              I'll try to put some pictures up on how that would look like.
              Rens Heeren
              Generalist
              WEBSITE - IMDB - LINKEDIN - OSL SHADERS

              Comment


              • #8
                Thanks for taking the time to write that up Rens! It's a very concise overview of a complex and muddied subject - much more clear than my simplified explaination.

                I agree! I'd love to have access to a shader that approaches it's material properties more inline with the real world - with the correct naming of each component. This is why I was asking if there are any BRDFs out there that behave more inline with what we've described, opening the door for a VRayPhysicalMtl shader or something in the future. There's probably much more to it than I'm aware of (which maybe Vlado can elaborate on), but one can dream.

                Originally posted by Rens View Post
                In the meantime you could progressively blend in the diffuse part the rougher a surface gets. It's not 100% technically correct especially where it's about 50% rough but it works well enough.

                Right, of course this is what most artists do when trying to replicate a material's appearance. But given that there's a relationship between Diffuse, Reflection, and Glossiness in dielectric materials - I was wondering in my original question if there's some sort of ratio or formula we can figure out that gives the closest results of how dielectric materials behave in the real world. Basically, if reflection is at 0.9, then using this formula we could find out that Glossiness should be set somewhere around 0.8 or something. It's a hack for sure - but it would be helpful until a more physically-based approach is available.
                Last edited by RockinAkin; 06-04-2014, 08:00 PM.
                Akin Bilgic | CGGallery.com
                Modeler & Generalist TD

                V-Ray Render Optimization
                V-Ray DMC Calculator

                Comment


                • #9
                  You're welcome! One note, the amount of light being reflected from a surface (reflectance) and surface roughness or Glossiness in this case aren't necessarily linked.

                  Reflectance is mostly a material property, as in gold has a different reflectance than steel and this is a value of how much of the light of a specific wavelength comes back.

                  Glossiness or roughness is dependent on surface topology and it defines the direction in which the rays scatter. Surface roughness can influence reflectance somewhat when the reflected ray hits the surface again.
                  Rens Heeren
                  Generalist
                  WEBSITE - IMDB - LINKEDIN - OSL SHADERS

                  Comment


                  • #10
                    Right. So in a way, the current BRDFs reflection model is more aligned to simulating conductors (metals) than dielectrics.

                    To use the example material Dadal mentioned earlier - making a brushed chrome material with the current BRDFs is a snap.
                    Akin Bilgic | CGGallery.com
                    Modeler & Generalist TD

                    V-Ray Render Optimization
                    V-Ray DMC Calculator

                    Comment


                    • #11
                      Originally posted by RockinAkin View Post
                      Right. So in a way, the current BRDFs reflection model is more aligned to simulating conductors (metals) than dielectrics.

                      To use the example material Dadal mentioned earlier - making a brushed chrome material with the current BRDFs is a snap.
                      I'm not sure but I think that current metal shaders are a bit wrong due to the bad Fresnel curve and so on. Can any1 confirm it? I think that metals + car paints are pretty bad at the moment...
                      CGI - Freelancer - Available for work

                      www.dariuszmakowski.com - come and look

                      Comment


                      • #12
                        Originally posted by Dariusz Makowski (Dadal) View Post
                        I'm not sure but I think that current metal shaders are a bit wrong due to the bad Fresnel curve and so on. Can any1 confirm it? I think that metals + car paints are pretty bad at the moment...
                        Technically yes - the current BRDFs are using a simplified fresnel equation - only IOR. For very accurate representation of metals the full fresnel equation is needed.
                        Akin Bilgic | CGGallery.com
                        Modeler & Generalist TD

                        V-Ray Render Optimization
                        V-Ray DMC Calculator

                        Comment


                        • #13
                          I was doing a bit more research into this and discovered that Maxwell Render's BSDF behaves very similarly to what Rens and I were talking about.
                          The material is a pure red color, and only the BSDF's 'roughness' parameter is changed in these images:

                          Akin Bilgic | CGGallery.com
                          Modeler & Generalist TD

                          V-Ray Render Optimization
                          V-Ray DMC Calculator

                          Comment


                          • #14
                            Fairly similar to my eyes?

                            Click image for larger version

Name:	lambert_vs_metal_gloss_0.jpg
Views:	1
Size:	33.9 KB
ID:	851796

                            Comment


                            • #15
                              Hey John! Yeah, they're fairly similar - what's happening in this scene? Is the top sphere a lambert and the bottom a reflective sphere with glossiness at 0?
                              If so where is the reflective sphere's diffuse red color coming from?
                              Akin Bilgic | CGGallery.com
                              Modeler & Generalist TD

                              V-Ray Render Optimization
                              V-Ray DMC Calculator

                              Comment

                              Working...
                              X