Announcement

Collapse
No announcement yet.

LPE versus regular light select query

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

  • LPE versus regular light select query

    Trying to start to understand how to use LPEs, and immediately running into confusion. I have a simple test scene set up with one dome light and one rect light.

    The docs seem to say that when using a LPE, all lights are considered unless a light is added to the select set. I therefore have assumed that using.e.g. an indirect diffuse LPE without adding any lights to the set would give the same result as creating an "Indirect Diffuse" regular light select with ALL lights added to the set.

    However, I am getting different results with this two scenarios. Can anyone explain why?

  • #2
    Same goes for comparing with some of the standard AOVs, e.g. I would expect a LPE for "indirect specular" to return the same result as the standard reflection pass. They are close, but not exactly the same.

    Comment


    • #3
      Hi there

      Are you using Light Cache in your scene? This can occur with Light Path Expressions and Light Cache because of the way it is sampled. We are aware of this issue and have logged it for further developer investigation (Internal bug tracker : VMAYA-11778 )

      In the meantime here are some things you can try:
      • You can switch to rendering with Brute Force. The results should be the same then.
      • To get the same result with Light Cache, you can up your Retrace Threshold (In Render Setting under the GI tab in the Light Cache rollout). This can affect your render times a bit, but in a lot of scenarios it will be faster than using Brute Force
      • Alternatively, if you want to render with Light Cache and you're not going to use any Background overrides, replacing L with (L|B) at the end of the expression can give you the same result.
      As for indirect specular and reflection passes, they are slightly different as you have already stated. If you would like to have the same results as the Reflection pass you can use the full LPE for Reflection - C<R[GS]>(.+L|.*[OB]).

      I hope this helps and if you need further assistance feel free to message me and send a scene over so I can have a look at it.
      Petya Georgieva
      Product Specialist
      V-Ray for Maya

      www.chaos.com

      Comment


      • #4
        Yes, I was using light cache. Thanks for the explanation and solution (I'm just testing anyway but at some point this might be useful info). Switching to brute force does indeed then give the same results.

        At this point I'm also a little confused about terminology, whether it's specific to Vray or not. What is the difference between "indirect diffuse" and "GI"? Aren't they the same thing, for all intents and purposes? They now do render exactly the same. So why the two names and separate expressions/presets?

        Same goes for "indirect specular" and "reflection" -- why is there a distinction between them? And in actual fact, using brute force GI also resolves this difference, so that I get exactly the same result whether using a LPE with the indirect specular preset, LPE with the reflection preset (the reflection preset differs from the one you gave here? It's C<R[GS]>.+L) OR a regular reflection AOV all produce the same result. So there seems to be a huge amount of redundancy.

        I guess this might not be true of all scenes? I have a very simple test scene with one standard diffuse material, one standard material with a glass preset, and one fast SSS material with the pink skin preset. I'm using a simple dome light and HDRI, and an ordinary rect light.

        Just trying to really get a handle on what LPEs can do and how they might differ from using standard AOVs or light selects.

        Comment


        • #5
          Never mind, I've been digging deeper and am beginning to understand why these presets are included.
          Last edited by SonyBoy; 01-02-2023, 06:16 PM.

          Comment


          • #6
            At this moment the presets under Light select for the LPEs are made to match the corresponding modes of the Light Select render element (e.g. Light Select set to Indirect diffuse should match Light Select set to LPE with the expression C<RD>.+L) The presets for the render elements are a bit broader as they include rays ending in the Background or in Emissive objects. You can observe this by looking at the ends of the expressions - C<RD>.+L for indirect diffuse vs C<RD>(.+L|.*[OB]) for GI. This is done so the LPE presets for the render elements can match the results from the actual render elements. In a lot of scenes they will be identical (with Brute Force or Light Cache with a higher Retrace Threshold) but there will be cases where there will be a difference - e.g. if you have background overrides or emissive objects.
            As for the preset I gave you, that is actually the full preset for Reflection. Some of the beauty presets you see are incomplete and we're aware of that and have the fix internally. Until it makes its way to release builds, here's the correct expressions for reference:
            Reflection --> it should be C<R[GS]>(.+L|.*[OB])
            Refraction --> it should be C<Т[GS]>(.+L|.*[OB])
            SSS --> it should be C<TD>(.+L|.*[OB])
            As for how they differ from standard AOVs or light selects, they give you freedom to create more custom render elements suited for your project's specific needs​. With LPEs you can get specific render passes such as GI, Reflection etc for specific objects or materials. You can get standard AOVs and exclude influence from specific objects. You can "create" AOVs such as GI from Environment or Self Illumination or combine others. And you can limit all that to specific lights. While not always necessary, LPEs can be very powerful tools for compositing Hope this helps
            Last edited by petya.georgieva; 02-02-2023, 09:59 AM.
            Petya Georgieva
            Product Specialist
            V-Ray for Maya

            www.chaos.com

            Comment


            • #7
              "While not always necessary, LPEs can be very powerful tools for compositing"

              Yes indeed. Having dug a bit deeper I can see how powerful LPE's can be. I do wish there were some more practical examples in the docs to augment the rather dry technical info (for those of us whose heads quickly start to spin when presented with diagrams and wordy theoretical explanations), but maybe you're working on that. I'm still not entirely clear how to put an expression together, but maybe that will come in time with practice and the need to find a specific solution. In the meantime thanks for the teachings!

              Comment

              Working...
              X