Announcement

Collapse
No announcement yet.

VrayMTL translucency curiosity

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

  • VrayMTL translucency curiosity

    Hi,

    over the months (and years) I've been slowly discovering all sorts of weird and hidden behaviors when it comes to how V-Ray handles translucency and SSS.

    - I've originally created a thread about SSS in VRayMTL, here: http://forums.chaosgroup.com/showthr...nslucency-work

    Now, I am finally at least slightly getting the grasp on how SSS in V-RayMTL works, and going back to this thread after a while, I've noticed one curious thing, and that is, that it seems VrayMTL translucency somehow work even when Fog Color is completely white, that it functions sort of similarly to 2sided mtl.


    - This brings me to the other thread, which I created, about having thin translucency right inside of VRayMTL, so that the translucent foliage does not lose energy: http://forums.chaosgroup.com/showthr...age-with-V-Ray

    In case Translucency in VrayMTL works as thin when fog color is 100% white, then that could resolve this issue.


    - This ties to another weirdness that I reported some time ago, where backside color of translucency in V-RayMTL seems to somehow affect result of V-Ray2sidedMTL:
    http://forums.chaosgroup.com/showthr...nslucency-work


    -Now, I tried it today, and it seems that some of the modes of translucency work as thin translucency when used with non modified fog color, and that only when fog color becomes non-zero, translucency becomes computed as an actual SSS volume, as shown in this video:
    https://www.youtube.com/watch?v=eDT3d6w2RGs

    You can see it actually does simple thin translucency, at least it appears so... but it just brings up a few questions:

    1, Why does not V-Ray use refraction color to conserve translucency energy. It seems that no matter if refraction color is RGB 1,1,1 or RGB 255, back side will transmit as much energy as what backside color is set to. So as shown in the video, user has to somehow preserve energy manually... I mean if front side diffuse color is RGB 255 and so is the back side color, doesn't that break energy conservation?

    2, What is the difference between hard wax and hybrid model? I've never ever spotted any...

    3, Backside color in VRayMTL seems to modify appearance of Vray2SidedMTL in which the given VRayMTL is plugged in, despite refraction color being set to 0. Does this mean 2SidedMTL uses same solution under the hood? But why wouldn't VrayMTL conserve energy then, when 2SidedMTL does?

    4, Is it safe to use this on a trees for example? Or is there better or slower performance compared to V-Ray2SidedMTL. Or could there be possibly some errors when it comes to media detection, as i am technically using refraction on meshes with no thickness...?

    5, Is there any documentation on these hidden behaviors? I mean Svetlozar has explained how it works with SSS fog set up, as actual SSS volume, but I have not found any description anywhere about how it's supposed to work if Fog Color is left set to white. All the more confusing that backside color affects 2SidedMTL too. This makes me curios if it was designed to work alone in VrayMTL or somehow in conjunction with 2SidedMTL.

    Thanks in advance

  • #2
    So little update, unfortunately I got excited too soon.

    When using this approach, the material indeed behaves translucent on the back side, but from the front side, it is still also refractive.

    I have tried using even as little as just 1,1,1 RGB for refraction, because it is irrelevant for translucency intensity, but even with such a low refraction, you can still directly see some very bright light sources refracted.

    So I end up with a material, that is glass from front side, but sheet of paper from back side

    This behaves even more weirdly. Some cleanup/unification in this area would be definitely welcome

    I still struggle to understand how was the original design supposed to work.

    Comment


    • #3
      The translucency in the VRayMtl material is specifically designed for objects with thickness. It is not "thin" translucency. I could add a translucency mode specifically for that, if you need it, just need to make sure I don't mess up anything else.

      Best regards,
      Vlado
      I only act like I know everything, Rogers.

      Comment


      • #4
        Originally posted by vlado View Post
        The translucency in the VRayMtl material is specifically designed for objects with thickness. It is not "thin" translucency. I could add a translucency mode specifically for that, if you need it, just need to make sure I don't mess up anything else.

        Best regards,
        Vlado
        Ah, okay, thanks. I am curious because it sure does look like thin translucency viewed from the back side. Also, I remeber seeing this particular approach on pretty much all evermotion foliage libraries. I always thought it was an error, until i noticed this behavior. Then I started to dig into it.

        I was also wondering:

        V-Ray 3 manual says that soft water and hard wax models are deprecated and that the hybrid model is way to go. Since there is some ongoing effort of modernization of V-Ray, how about deprecating soft and hard models, retaining only hybrid model, and then aside from thin model, add also the same thing that VRayScatterVolume material uses? I like ScatterVolumeMTL a lot more, because it's a lot easier to setup with just phase function. A lot more predictable, but also more tedious to setup with all the material blending.

        So I was thinking about modernized V-RayMTL, which would have 3 SSS modes, Thin, Simple, and Complex:

        - Thin mode would use refract color as translucency amount color, and scatter coeff, Fwd/Bck coeff and thickness parameters would be frozen when this mode is selected. Backside color will define color of the thin translucency.

        - Simple mode would use refract color as SSS effect multiplier, Fog Color as equivalent of scatter color in ScatterVolume, and Back-Side color as equivalent of sub-surface color in ScatterVolume. Scatter Coeff would be frozen, and Fwd/Bck coeff label would swap to phase function.

        - Complex mode would remain equivalent of Hybrid mode that's there now.

        Then, Back-Side color could be renamed to SSS color, to make it more self explanatory. If the translucency is only supposed to work with some volume, then Back-Side color is imho a bit confusing name, as it does not define color of back side, but color of the SSS volume.

        Lastly, one more step to make this even more intuitive would be to replace Fog Multiplier with Fog radius, in the same way it's in ScatterVolume or AlSurface. I always find it a bit counter-intuitive when tweaking fog depth/density.


        Anyway, this is not 3.5 request... more like an idea for distant future

        Comment


        • #5
          I wanted to write about this subject for so long. I'm glad someone actually took the time to do it.

          As I don't have anything to add about the problems with translucency in VrayMtl, since Recon442 post cover that pretty well. So I want to focus on my view of improvements:

          1) Make Translucency as a third parameter, separated from refraction, and with priority just above Diffuse. This would be the thin SSS. But light passes through the material like refraction, so this mode enables the use of SSS. This approach is pretty much standard in most renderers these days.

          2) Rename the current Translucency to what it really is, a Volumetric Scattering. For short, maybe call it Volume, Scattering or SSS.

          3) Rename Fog to Absorption and make it work as a distance in scene units.

          4) Rename the Back-Side color to Overall Color. This is because it's just a color multiplier on top of Fog color.

          5) Remove the Thickness parameter. Does it still help to improve performance?


          You could call it done, but IMO it could improve a bit more:

          -Change the items in the current translucency dropdown to:

          *Hybrid: Keep what we have now, maybe with a better name. I think it's important to keep not only for compatibility reasons but because it's still useful. In fact I find even the name appropriated because it's kind of a mix of a physical scattering but with some useful controls. Also, it's much, much faster than a physical mode.

          *Physical: The same effect as VrayScatterVolume, but now inside VrayMtl. No need to have the dropdown as in VrayScatterVolume to choose the mode, use just the default one there which is easier to setup anyway. Add/Remove and rename parameters on the UI accordingly.


          This seems like a good improvement in workflow since with that, there's no need to make 2Sided materials for thin translucency anymore, and with some gain in performance I guess. Also no need to make Blend materials for ScatterVolume too. And last but not least, separate Translucency from refraction allows to have translucent AND refractive materials. Or to have SSS effect that is a mix of translucency and refraction.

          Regards,
          -Eugenio
          Last edited by Midiaeffects; 21-01-2017, 10:54 PM.

          Comment

          Working...
          X