Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I'm trying to change texture color by aplying mask, which is exactly the same texture but with changed color and alpha < 150. I'm doing smth like this:

spriteBatch.Draw(pic, Vector2.Zero, Color.White);
spriteBatch.Draw(pic, Vector2.Zero, newColor);  //for exmaple (150,150,150,50)

The problem is with fps, it drops from 30 to 25, when i'm trying to do this with 3 different textures at the same time.
if i change this line

spriteBatch.Draw(pic, Vector2.Zero, newColor);


spriteBatch.Draw(whiteBlankPicture, new Rectangle(0,0, pic.Width, pic.Height), newColor); //whiteBlankPicture texture 1x1 pixel

fps dont drops and stay normal. What is the problem?

share|improve this question
Just wondering - what are the dimensions of pic and whiteBlankPicture? –  Nick Caplinger Jun 7 '13 at 14:49
Are you recoloring your unmodified texture every draw? That could be hindering your frame-rate –  UnderscoreZero Jun 7 '13 at 15:40
dimension of pic less that 800x480.whiteBlankPicture - 1x1. No i'm not recoloring every draw. –  Feusp Jun 8 '13 at 6:27
How often are you calling this batch to draw? –  Thraka Jan 10 at 4:22
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.