Jump to content
  • Advertisement
Sign in to follow this  
zipwax

Can I calculate 3 shadow maps at once in HLSL?

This topic is 2460 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I need to calculate shadow maps for 3 lights at once. Instead of using 3 shadow maps, I'd like to calculate all of them in one pass, using one shadow map, each light stuffing it's depth value into a single R, G, or B channel. I know, this gives me only 256 bits of precision per channel. Is this even possible?

Share this post


Link to post
Share on other sites
Advertisement
Did you mean 256 values in an 8 bit channel (truecolor)?

Use a 16 or 32 bit single channel depth buffer to have a good precision and divide it using a quad tree allocation to get many depth maps in one register.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!