Announcement

Collapse
No announcement yet.

Shadows from shadow casting objects going through multiple different objects

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

  • Shadows from shadow casting objects going through multiple different objects

    I'm new to VRay in Maya.

    I want to create an isolated render of the shadow cast by an object onto the other geometry in the scene.

    I want ONLY the selected object to cast shadows, and everything else in the scene to receive shadow of that one object, so that I can use this shadow render as a matte/mask in a comp/composite.

    I'm adding a CG render (of the object) to a filmed background plate. The matte will be used to darken the background plate to create the shadow of the CG object as it moves through the scene. (Basic "CG added to live action comp" stuff.)

    Using a VRayMtlWrapper material with a base material (VRayMtl) I have set things up so that only the specific object (the highlighted spheres in the image below) casts shadow and the other geometry receives shadow.

    Click image for larger version

Name:	ChaosForumPost_geometry.png
Views:	221
Size:	79.0 KB
ID:	1164508Click image for larger version

Name:	ChaosForumPost_shadRender.png
Views:	107
Size:	152.9 KB
ID:	1164509 Click image for larger version

Name:	ChaosForumPost_MtlsGraph.png
Views:	101
Size:	161.9 KB
ID:	1164510​​

    HOWEVER, the problem is that the other geometry isn't blocking the shadow, so the shadow is also hitting the couch parts below the couch cushions and also hitting the floor below the couch. I need it to not do that.

    The shadow calculations seem to hit the top (or first encountered) surface of any geom in the scene, with no geometry stopping the shadow calculations.

    Click image for larger version

Name:	ChaosForumPost_geometry_separatedToShowIssueBetter.png
Views:	150
Size:	196.4 KB
ID:	1164511Click image for larger version

Name:	ChaosForumPost_shadRender_separatedToShowIssueBetter.png
Views:	100
Size:	309.8 KB
ID:	1164512

    I'm sure there must be some magical setting I need to set on the other geometry in the scene to stop that problem, but I can't figure out what that setting is.

    Can anyone help?
    Attached Files

  • #2
    I usually just do this with a couple of Object Properties nodes. Put all your shadowed surfaces into a Vray object properties node, then set that to "matte object", set alpha contribution to -1, and toggle on shadows and affects alpha. Put your shadow casting object into another object properties and set an override to turn primary visibility off. You will get your shadow in the alpha.

    Comment


    • #3
      I'll try that, but those are the same settings I'm using with the VRayMtlWrapper setup. The docs said they were equivalent.

      https://docs.chaos.com/display/VMAYA...eive%20shadows

      Comment

      Working...
      X