Jump to content

How to render object always on top/in front of another object?


zbugni

Recommended Posts

Hey everyone, basically what I have is this:

PigHeadOverlap.thumb.png.3d17faa2294729e9ce42ab1c71a8f81c.png

and what I want is this:

PigOnGrid.thumb.png.b5e0cbb7d071c43ffff9242ad620d095.png

Obviously, it looks like I could just move the pig head up in space haha. But I have a more specific case that requires the pig head to be visible through the plane giving the ILLUSION that it's on top of it. Put simply, I want the pig head to always be drawn/rendered on top of the plane, regardless of depth/occlusion.

It's really easy to achieve this with compositing, but I'm hoping to pull this off at render time using materials in Mantra. I'm open to some complicated node setups (maybe turning the plane transparent wherever the pig head is behind it???) But hopefully it's just an easy setting that I've missed. Thanks so much in advance!

Link to comment
Share on other sites

15 hours ago, Librarian said:

@zbugni hm..maybe to use trick with bbox in for-loop and somehow export CAM-coordinates in mat Shop ..but how ????? hm

This is an awesome setup that gets me inspired! But yeah, I have no idea how to get the result I want in a shading context. I don't actually want to move the pig head physically. I just want it to always be visible, even if it's behind an object in space.

Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...