H9 Deep Shadows on vex shaded sprites

   7966   7   1
User Avatar
Member
77 posts
Joined: July 2006
Offline
I'm having troubles rendering transparent depth map shadows on particle sprites. I'm using the shader from Miguel Perez Senent's meteor tutorial.
I think I have everything set up correctly, but I end up with rendering artifacts that don't appear when I use raytraced shadows.

I've attached an image illustrating the problem and a scene file.
Any help would be appreciated.

Thanks!
~Mike D.

Attachments:
particleSpriteSmoke_deepShadows_07.hipnc (249.4 KB)
deepShadows.jpg (31.2 KB)

User Avatar
Member
41 posts
Joined: March 2006
Offline
Mm… I can't see the problem. Everything seems to be fine…
User Avatar
Member
77 posts
Joined: July 2006
Offline
Thanks for having a look Miguel.

(edit: deleted unnecessary image)
Edited by - Oct. 26, 2007 12:26:27
User Avatar
Member
41 posts
Joined: March 2006
Offline
I think you have misunderstood me I know it renders with airtfacs, It happens to me too. But I can't see why.
User Avatar
Member
12448 posts
Joined: July 2005
Offline
Perhaps you're under-sampling your DSM?

If you play with a combination of increasing your shadowmap resolution, fiddling with your shadow bias and increasing your shadow softness do you get better results?
Jason Iversen, Technology Supervisor & FX Pipeline/R+D Lead @ Weta FX
also, http://www.odforce.net [www.odforce.net]
User Avatar
Member
77 posts
Joined: July 2006
Offline
Thanks Jason!

That seems to be having the right effect. Putting the shadow bias at .5 and cranking the shadow softness to 10 got rid of most of the artifacts. The shadow map resolution surprisingly didn't seem to have much of an effect.

I'll start messing around with some of the other quality attributes and see what I can come up with.

~Mike D.
User Avatar
Member
1002 posts
Joined: July 2005
Offline
I'm pretty sure that this is an expected artifact when rendering shadow maps for sprites. If the sprites are always rendered facing the camera or light, then the shadow map will be generated with different geometry than the final render - leading to a shadow map that shadows only half of each sprite. Increasing the shadow bias by the sprite size should eliminate this artifact, but may produce images that are brighter than they should be.

Andrew
User Avatar
Member
12 posts
Joined: Jan. 2006
Offline
Just a note on what I've found so far with this.

Andrew, thanks for the insight there. It's nice to have a rough formula for figuring these things out.

Keeping that in mind, I'd suggest keeping the sprite size as small as possible and increasing the number particles so you can keep the shadow bias lower. Too much shadow bias and your shadows become really inaccurate.

Balancing the bias with softness as Jason mentioned then gets pretty nice results.

The last trick is to duplicate your lights and offset them a bit. Lower the intensity of both so they don't over-light the scene and you'll get automatic blurring of the shadows as the renderer multiplies the offset shadow values together.

This gives you a little more room to lower the shadow bias and softness and still get good results quickly.

I can't express how happy this makes me. I may actually finish my thesis now!!
  • Quick Links