multiple render target 1 color

Started by
0 comments, last by Razvan1024 13 years, 9 months ago
HY.
I would draw arbitrary shape shadow , each shadow must be written in a render target.
I would have 2 color : 0 and 1 , when the shadow is present i write 1(the color is 1) if the shadow is not present i write 0.
at the end the shadow is a shape filled with 1 and I'm would render each of 10 shadow shape with multiple render target , all at the max speed .
is possible to gainspeed with draw only two color?
thanks.
Advertisement
The biggest speed improvement you can make is draw all your shadows in the same shadow map. Maybe you can assign to every shadow a different color id (a 32 bit value that has only one bit as 1) and add the ids together when drawing the shadows in the same shadow map. This way you could render up to 32 shadows at once. If you increase the number of bits in the value you can render more shadows at once.

This topic is closed to new replies.

Advertisement