Drawing sprites that is partially off the screen. Effect performance?

I do sprite culling so I don’t draw sprites that are completely off screen. I do draw sprites that are partially in the screen. Should I cutoff the sprites so only the visible part is drawn or should I not even bother like I am right now? I’m just worried it may cause perf issues if there are parts of the sprite that is drawn offscreen.

The GPU will do the culling for you - cutting off the sprites on your own will be much slower. (Pixel Shader will not get called for pixels out of screen)

You are fine drawing partially sprites, it doesn’t affect performance. Not sending sprites at all because they are fully out of screen is a benefit but you do that already, so you’re fine

1 Like