Announcement

Collapse
No announcement yet.

Reflections traced through refract mats get refract envirnmnt not reflect envirnmnt

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

  • Reflections traced through refract mats get refract envirnmnt not reflect envirnmnt

    We're running into an interesting problem. The general rule with transparency and matting is that if you want your transparency to work (and not have halos around your objects) you need to render with a black background.

    But when we follow this method, we're getting less reflections from our environment when that environment is traced through an object with refraction

    The second image (no-alpha-details.jpg) is an example with a VRay sky in the Max Environment slot and no VRay overrides. The glass is simple 1.6 IOR with affect alphas and affect shadows checked on .

    Now, if we setup for a black background by putting black in the Max Environment slot and moving the VRay Sky to the VRay Environment Overrides, we get the first image (alpha-details.jpg).

    Notice how there is significantly less reflection on the chair. As far as I can tell, it appears that the reflection on the seat is using what is traced from the refraction of the glass. In this case since our environment refraction is black (necessary to avoid the alpha pre-multiplying halos) we're getting black in the glass refraction, and hence, black in the chair reflection instead of the reflection environment.

    Is there any way to solve this? I would expect to get the same reflection results as in the first example, but I'm unsure whether this is a bug, or if it isn't, how to achieve the same results.
    Attached Files
    Last edited by Dynedain; 23-10-2008, 11:40 AM.

  • #2
    You can use local environment maps in the materials and the environment priority options to make them interact in the way you want.

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

    Comment


    • #3
      Originally posted by vlado View Post
      You can use local environment maps in the materials and the environment priority options to make them interact in the way you want.

      Best regards,
      Vlado

      But then we would have to set the environment on every material that might exhibit this behavior, correct? That's incredibly tedious for an archviz scene where you can have hundreds of materials.

      And I'm not sure what you mean by environment priority options.

      Comment


      • #4
        In the VRayMtl Options rollout, there is an environment priority setting. It determines how environment overrides of different materials override one another.

        In general unfortuntely, like with the matte/shadow stuff, there is no "logical" default behaviour for this; there are cases where the behaviour you describe would be unwanted.

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

        Comment


        • #5
          Putting the VRaySky in the chair's environment slot produces the same problematic effect. I assume this is because the chair is technically not reflecting the environment, it's reflecting the glass.

          Putting the VRaySky in the Glass' environment slot produces the right effect on the chair, but brings back the haloing problem because the glass no longer has a black refractive environment.

          Is there an example somewhere as to how to utilize the environment priority setting? The help files are rather vague and me flipping values is having no noticeable effect in this situation.

          Comment


          • #6
            Solved it (with lots of help from Suurland on the IRC):

            Give your glass material a black VRayColor map as its environment map and an environment priority of -1.

            Max 2009 file and render attached. (the teapot is behind the glass)
            Attached Files

            Comment

            Working...
            X