Karma Shadow Matte

   23068   68   9
User Avatar
Member
8035 posts
Joined: 9月 2011
Offline
Tser
Thanks for the reply npetit, is there any way you could upload a simple scene comprising a Dome light with a hdr texture for lighting, a grid to capture the shadows (but is transparent) and a couple of objects casting shadows to replicate the image that I showed in a previous post.
Your expertise is greatly appreciated.
T.

It's not possible without rendering out the view of the hdr from that camera to use as a plate texture.
User Avatar
Member
57 posts
Joined: 12月 2014
Offline
Thanks jsmack, I didn't think it was possible as I have spent quite a bit of time trying to achieve it, I thought that I was missing something, well here's to hoping this gets implemented soon.
T.
User Avatar
Member
8035 posts
Joined: 9月 2011
Offline
Tser
Thanks jsmack, I didn't think it was possible as I have spent quite a bit of time trying to achieve it, I thought that I was missing something, well here's to hoping this gets implemented soon.
T.

generating a backing plate from an hdri is pretty quick, if you want to use the existing features for now.
User Avatar
スタッフ
404 posts
Joined: 2月 2008
Offline
You mentioned you wanted to see it in the viewport - I missed the bit about the shadow catcher needing to be transparent.

You won't be able to get the ground you're projecting the plate on to be transparent except where the shadows are, in a single render. The background plate lop projects the plate as a material onto the plate geometry (your ground) so you get proper interaction (light bounces and reflections) with your CG elements, sets its holdout mode to Background then uses LPE for the various passes.
The plate geometry also captures the diffuse bounces and reflections of the CG elements you are lighting, helping to integrate them onto the plate a whole lot better than just compositing shadows.
You can dive into the background plate LOP and edit the plate geo material to customize it however you need - so for example if you have more reflective areas on the plate you can set that up there.

In order to get the shadows on a transparent plate geo, you'd need to do some compositing, but if you need the ground the be transparent, it implies you are using the beauty to do some comp work, so this shouldn't be an issue?

Here's an example hip file with the background plate lop setup and the COP graph to either comp all the AOVs together to match the viewport (it'll be the same math in Nuke or whatever comp package you use) or get the shadows and alpha added to the CG element beauty.

Attachments:
BackgroundPlate_AOVs.hip (1.2 MB)
BackgroundPlateScreenGrab.jpg (1.2 MB)

User Avatar
Member
57 posts
Joined: 12月 2014
Offline
Thanks for that npetit, but I don't want to be compositing to get shadows and you are using Principal shaders instead of MaterialX. Also I am rendering in Houdini using Arnold not Nuke or any other compositor. If I wanted to add extra shadowing as a post I could, but that defeats the purpose. And to cap it off, I only want to be rendering using my GPU's. The work around that I am using at the moment with Karma XPU is to add textures and alpha maps to the grid to blend it into the Dome light Environment hdr which gives a fake ground that blends into the hdr's ground.
T.
User Avatar
Member
35 posts
Joined: 5月 2014
Offline
OneBigTree
dlee
Hi. Karma does not yet support shadow matte or have a shadow catcher. As a workaround you could output shadowed and unshadowed AOVs and take the difference to generate a shadow pass in comp.
Still no solution in 19.5?
What's the holdup?
Create a matte geometry, so add an extra AOV on Karma settings. You will see the shadow pass in mplay

Attachments:
image_2023-03-08_030932647.png (56.2 KB)

User Avatar
Member
57 posts
Joined: 12月 2014
Offline
Pavini
OneBigTree
dlee
Hi. Karma does not yet support shadow matte or have a shadow catcher. As a workaround you could output shadowed and unshadowed AOVs and take the difference to generate a shadow pass in comp.
Still no solution in 19.5?
What's the holdup?
Create a matte geometry, so add an extra AOV on Karma settings. You will see the shadow pass in mplay
Any chance for a working hip file which renders in XPU without compositing?
User Avatar
Member
57 posts
Joined: 12月 2014
Offline
Labs has an excellent SOP called physical_ambient_occlusion, I have been playing with it and I've found that if I use it on the wheels of my car and with a small grid with high poly count, merged with the wheels, set the grid to use a MaterialX material which has a mtlxgeompropvalue node to take the mask attribute from the SOP, I can use it to drive the transparency of the grid to give Ambient Occlusion under the tyres making the rest of the grid transparent.
I am also looking for a way to get the same from the shadows, is there a shadow SOP like the Labs physical_ambient_occlusion node?
User Avatar
Member
8035 posts
Joined: 9月 2011
Offline
Tser
Labs has an excellent SOP called physical_ambient_occlusion, I have been playing with it and I've found that if I use it on the wheels of my car and with a small grid with high poly count, merged with the wheels, set the grid to use a MaterialX material which has a mtlxgeompropvalue node to take the mask attribute from the SOP, I can use it to drive the transparency of the grid to give Ambient Occlusion under the tyres making the rest of the grid transparent.
I am also looking for a way to get the same from the shadows, is there a shadow SOP like the Labs physical_ambient_occlusion node?

There's "mask by feature", which can calculate shadows using a pointcloud as point light sources or a vector as a directional light source. It can also do ambient occlusion in the same node.
User Avatar
Member
57 posts
Joined: 12月 2014
Offline
Nailed it... Thanks for that jsmack, it works really well in XPU, now for some playing around...

Attachments:
Drop Shadows.png (955.8 KB)

User Avatar
Member
57 posts
Joined: 12月 2014
Offline
After a couple of days tinkering around, I created a subnetwork node to create the shadows and AO, it works really well for still shots and works perfectly with Karma XPU.
T.

Attachments:
ShadowCatcher.mp4 (12.7 MB)

User Avatar
Member
57 posts
Joined: 12月 2014
Offline
This is an example of what I really want:
Your text to link here... [www.youtube.com]
User Avatar
Member
175 posts
Joined: 1月 2015
Offline
Redshift has matte object. It makes it so easy to integrate the cg into the plate in the renderview, without doing allot of custom stuff just to get shadow and reflection into the background from the cg objects.

Just a toggle away on the mesh to get it working.

https://help.maxon.net/r3d/houdini/en-us/#html/Matte+Options.html?Highlight=matte [help.maxon.net]
User Avatar
Member
57 posts
Joined: 12月 2014
Offline
Heileif
Redshift has matte object. It makes it so easy to integrate the cg into the plate in the renderview, without doing allot of custom stuff just to get shadow and reflection into the background from the cg objects.

Just a toggle away on the mesh to get it working.

https://help.maxon.net/r3d/houdini/en-us/#html/Matte+Options.html?Highlight=matte [help.maxon.net]
Yeah, it looks like they have a good system, a bit the same as Arnold.
User Avatar
Member
162 posts
Joined: 8月 2015
Offline
Hello!
Wondering if there is any progress on this topic? I've started another topic as well and just run into this one too. Seems a bit cumbersome not to have proper shadow catcher as it is such a basic thing to have?
User Avatar
Member
274 posts
Joined: 3月 2011
Online
Mirko Jankovic
Hello!
Wondering if there is any progress on this topic? I've started another topic as well and just run into this one too. Seems a bit cumbersome not to have proper shadow catcher as it is such a basic thing to have?
I think you'll have to dig into the background plate (if you want to do that without the bkg plate), but the workflow remains the same, just use the background plate to set the shadow matte output. Not it works with XPU too.
Edited by guilhermecasagrandi - 2023年11月16日 08:34:29
User Avatar
Member
162 posts
Joined: 8月 2015
Offline
I was trying to get something with bgplate but still no luck. As OP mentioned earlier just need shadow on one mesh embedded as alpha in final render image.
Like that example he posted earlier with torus casting shadow on ground plane rendered in Arnold. I couldn't get similar result with background plate yet.
User Avatar
Member
8035 posts
Joined: 9月 2011
Offline
Mirko Jankovic
I was trying to get something with bgplate but still no luck. As OP mentioned earlier just need shadow on one mesh embedded as alpha in final render image.
Like that example he posted earlier with torus casting shadow on ground plane rendered in Arnold. I couldn't get similar result with background plate yet.

That's not how it works. The shadow matte is output as a set of AOVs for use in comp.
User Avatar
Member
162 posts
Joined: 8月 2015
Offline
That is how it works in couple other renders, how it worked for couple decades back really, and that is what I need for the project I'm currently trying to switch from Redshift to KarmaXPU.
I'm not the one doing comping and I have to deliver to the client what is asked for That why I'm trying to make it work like that
User Avatar
Member
8035 posts
Joined: 9月 2011
Offline
Mirko Jankovic
That is how it works in couple other renders, how it worked for couple decades back really, and that is what I need for the project I'm currently trying to switch from Redshift to KarmaXPU.
I'm not the one doing comping and I have to deliver to the client what is asked for That why I'm trying to make it work like that

I'm sure a simple precomp could generate what you need. I'm not aware of the ability to shuffle parts of aovs into the channel of another directly from the render, so some mini comp is probably required to conform to the desired spec.
  • Quick Links