So, I have 100 blitz sprites which are all positioned on the same vertical plane. Because they're alpha blended, I'm getting a horrible side effect: when sprite a and sprite b overlap, sometimes a is rendered on top of b, other times it's vice versa. Yuck!
I figured the best way around this problem was to assign each sprite it's own entity order, to guarantee each sprite will be drawn in a specific order. Indeed, this worked fine.
However, I'm noticing a performance hit using this method. Without setting the EntityOrder of the sprites, I get 1-2ms, with EntityOrder used, I get 5-6ms. This isn't actually too much of a problem with the thing I'm messing around with, but on a more intensive project, I image this could be a pain.
Anyone else notice this performance hit using EntityOrder and/or know why it's happening?
Also, re the overlapping sprites problem detailed above, what would be the best way around this if I were to use a single surface sprite system? In that case, using EntityOrder isn't an option, obviously.
Cheers.
I figured the best way around this problem was to assign each sprite it's own entity order, to guarantee each sprite will be drawn in a specific order. Indeed, this worked fine.
However, I'm noticing a performance hit using this method. Without setting the EntityOrder of the sprites, I get 1-2ms, with EntityOrder used, I get 5-6ms. This isn't actually too much of a problem with the thing I'm messing around with, but on a more intensive project, I image this could be a pain.
Anyone else notice this performance hit using EntityOrder and/or know why it's happening?
Also, re the overlapping sprites problem detailed above, what would be the best way around this if I were to use a single surface sprite system? In that case, using EntityOrder isn't an option, obviously.
Cheers.