Jump to content

Light shader, how to generate shadowmaps


haggi

Recommended Posts

For learning reasons I try to create my own lights. Writing a light shader worked fine and so did the shadow shader which produces raytraced shadows. But how can I create shadowmaps automatically? If I use a houdini light which uses shadowmaps, these are automatically created. How can I do it for my own shader to be able to use shadowmaps?

For testing I used a v_rayshadow with the z-Depth option for depth map shadows. Here it is the same, the shadowmap is not automatically generated. "Auto generate Shadow Maps" is turned on in mantra render node.

Link to comment
Share on other sites

For learning reasons I try to create my own lights. Writing a light shader worked fine and so did the shadow shader which produces raytraced shadows. But how can I create shadowmaps automatically? If I use a houdini light which uses shadowmaps, these are automatically created. How can I do it for my own shader to be able to use shadowmaps?

For testing I used a v_rayshadow with the z-Depth option for depth map shadows. Here it is the same, the shadowmap is not automatically generated. "Auto generate Shadow Maps" is turned on in mantra render node.

This is a soho thing. Basically once soho encounters a "hlight" object with generate shadow maps parameter turned on, it triggers appropriate snippet in the ifd file. I usually overwrite Houdini's own OTL to add new functionality, so I don't have this problem. Anyway, take a look on the end of ifd.py and wranglers/HoudiniLightIFD.py in $HH/soho directory.

hth,

skk.

Link to comment
Share on other sites

This is a soho thing. Basically once soho encounters a "hlight" object with generate shadow maps parameter turned on, it triggers appropriate snippet in the ifd file. I usually overwrite Houdini's own OTL to add new functionality, so I don't have this problem. Anyway, take a look on the end of ifd.py and wranglers/HoudiniLightIFD.py in $HH/soho directory.

Thanks, great info.

Link to comment
Share on other sites

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...