Problems with tinted background on easyCam example

I’ve made a simple game using easyCam example: two boxes (one on the left and one on the right side) and one ball running from one side to another. The boxes are controlled (up and down) by the players. Now, I’ve put a few sounds on the game and they work well, but I want to put an image as background and I cant… the image looks strange and red/pink colored. With some tries I solved the positioning problems, but I cant solve the color problems.

Can you suggest something?

Cheers!

if an image looks ‘tinted’, it might be because you called ofSetColor() without setting it back. if you do this:

  
  
void draw() {  
img.draw(0, 0);  
ofSetColor(255, 0, 0);  
ofCircle(50, 50, 10); // red circle  
}  
  

then the image will be tinted red. you can fix that one of two ways:

  
  
void draw() {  
img.draw(0, 0);  
ofPushStyle();  
ofSetColor(255, 0, 0);  
ofCircle(50, 50, 10); // red circle  
ofPopStyle();  
}  
  

or:

  
  
void draw() {  
ofSetColor(255); // back to white  
img.draw(0, 0);  
ofSetColor(255, 0, 0);  
ofCircle(50, 50, 10); // red circle  
}