Announcement

Collapse
No announcement yet.

HDRi Set - VrayMtlWrapper with GI (VrayDomeLight)

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

  • HDRi Set - VrayMtlWrapper with GI (VrayDomeLight)

    Hi,

    I've experimented a lot with HDRi lighting since I started using Vray back in '06. I'm photographing my own high-res images and is very passionate when it comes to the accuracy of the IBL.
    Some time ago I started combining my HDRi-techniques with image-based modelling, and had some nice results with the VrayMtlWrapper as a shadow catcher:



    Using this technique I got the benefit of showing the shadows onto the background image, as well as having the shadows showing up correctly, with transparency, in reflections.
    However, this only works when I map the background image (the HDR environment map) to the camera using camera map projection.

    The current scene I'm developing uses another technique, much like the HDR set discussed in the end chapters of Christian Blochs' "The HDRI Handbook 2.0" and also shown in Scott Metzger's demostration of a new MARI enviroment painting technique.
    I've build a simple set based off of a single HDR image (courtesy of aversis.be), and you can see the setup here:



    Now, here enters the problem.
    Since this is no longer a standard spherical projection of the HDRi backplate, I can't use camera map projection to get my ground objects to work as shadow catchers.
    So instead, I've added a new plane which has the same UVs and texture as the environment, but no self-illumination and is also put in a VrayMtlWrapper-material. But this produces the typical black render. Example added in the bottom of this post.
    The problem lies in, I believe, the way the VrayMtlWrapper-material handles GI light, or even directlight from a VrayDomeLight or fully enclosed VrayMeshLight. I've added a quick demonstration of this:



    This I could get around then using camera map projection, by turning off Receive GI on the shadow catcher. But this, unfortunately, has no positive effects on this setup.

    Hopefully, this wasn't too long of a tuesday morning read, and hopefully, some of you might have experienced this particular version of the endless shadow/matte-line of issues.

    Edit:

    I'm gonna share some render results and settings/parameters:



    As can be seen above, the VrayMtlWrapper get it's shadows as expected (alpha), but show nothing other than blackness in render. To the right I've hidden the ground plane, showing only the environment (VrayLight, Mesh). This has the correct look, minus the missing shadows. I need some way to have the shadows and ambient occlusion masked onto this underlaying light object, without having to resort to compositing in external software. The reason for this is I have to be able to do quick test renders for clients that show correct lighting, and don't have time to composite on the shadows for each new render.
    Last edited by Jorq1H; 30-07-2013, 07:04 AM.

  • #2
    Hi,

    The problem lies in, I believe, the way the VrayMtlWrapper-material handles GI light, or even directlight from a VrayDomeLight or fully enclosed VrayMeshLight.
    That's because V-Ray Wrapper Mtl catches the shadows produced by the direct lighting and the GI ones as well. unchecking the "Receive GI" will help in this case.
    Would it be possible to test your scene?
    If yes, you could send it to support@chaosgroup.com and add this thread as a note.

    We will make some further investigation directly on your scene.
    Tashko Zashev | chaos.com
    Chaos Support Representative | contact us

    Comment


    • #3
      Originally posted by tashko.zashev View Post
      Hi,

      That's because V-Ray Wrapper Mtl catches the shadows produced by the direct lighting and the GI ones as well. unchecking the "Receive GI" will help in this case.
      Unfortunately, this doesn't help in this particular setup. In the example I showed the light source is based on the entire scene, not just the light sources in the HDR map. So there's direct light cast from every surface.
      I'm going to try and change this to where only the light sources in the HDR map emits light, and the rest is the for light bounces and color bleed. This, though, takes away the collective ambient light, but this should probably be recreated with a low-res, blurry env map free of direct light sources. Which means a lot of photo editing.
      But then again, this is going against the very thing I'm trying to achieve with this technique.

      Would it be possible to test your scene?
      If yes, you could send it to support@chaosgroup.com and add this thread as a note.

      We will make some further investigation directly on your scene.
      I think the current scene has too many variables to give a coherent idea of what I'm trying to achieve. I've instead tried to get my thought process down in a few, simple point:
      • Model and texture an environment based off of one or several HDR maps.
      • Let this environment emit the light stored in the 32-bit texture.
      • Use the same (or an instance of) environment to catch shadows created from this lighting.
      • Thus let the finished render have accurate lighting/shadows/reflections/refractions in every position within the environment, without compositing.


      I'm not sure this is doable in Vray, but I haven't tried everything just yet. Also, any input from you guys reading this is much appreciated.

      And also, I'll try to make a simpler scene like this, with royalty-free maps, to package and upload here for you guys to test as well.
      Last edited by Jorq1H; 02-08-2013, 01:32 AM.

      Comment


      • #4
        Thank you very much for the images and explanations.
        Would is be possible to prepare a simple scene for us ?
        Svetlozar Draganov | Senior Manager 3D Support | contact us
        Chaos & Enscape & Cylindo are now one!

        Comment


        • #5
          I've uploaded a new and quickly thrown-together example here:

          Link (100 MB)

          The environment is modeled after aversis.be's newest free, non-commercial HDR map. This resolution of the map is the same as most of my other projects.
          In the scene I've put the environment (not renderable), a VrayMeshLight based on the environment object, and 3 spheres. The point of this scene is to get accurate shadows from the mesh light onto a shadow catcher. I've not added any material wrappers to this scene.
          The environment mesh has a subdivide modifier on it to get more accurate mapping, in case anyone thinks the mesh topology looks overly complicated.




          Anyone interested in trying this themselves are more than welcome to!

          Comment


          • #6
            Hello again and thank you very much for the example scene and description of the issue.
            I didn't realize earlier but now I can see that you are trying to catch shadows by completely isolating the background on a single pass.
            The way that V-Ray Matte works is to render background image where a camera-ray hits Matte-surface - since in your scene there is no background image but black color the shadow-catcher result will be always black because Vray ignores all objects behind it and hits directly the background.

            In order to achieve the result you want you have to use VrayWrapperMtl with a combination of Background image, which in this case leads to another challenge.
            Somehow Background image mapping must be synchronized with the image-based-modeled-geometry - which if I am not wrong is not possible because 3DSMax doesn't provide possibility to add UV-modifier to background image or to project it from a different camera.

            The only workaround which I can think of so far is to hide all objects in the scene except the VrayMeshLight , render the scene and save the image, then add this image into the background slot and unhide all other objects. Now the background image will be synced with the image-based-modeling and the shadow-catcher should produce the correct shadows over the correct background.
            Svetlozar Draganov | Senior Manager 3D Support | contact us
            Chaos & Enscape & Cylindo are now one!

            Comment


            • #7
              Originally posted by Jorq1H View Post
              I've uploaded a new and quickly thrown-together example here:

              Link (100 MB)
              The link is broken. Any way to get the scene back up?

              thanks!
              Guido.

              Comment

              Working...
              X