background color of an image?

Ok crazy question, I know. 

But I’ll have to ask anyway…

I am getting loads and loads of logos from a server and some of them are black background with white logo and some are white background with black logo.

Is there any way you could imagine, that one could equalize all of them? so maybe black background gets inverted? 

The problem is, that the color picker only works for the screen, right? so there is no way to tell if the background of an image at a certain point (let’s say top left corner) is black or white. and I don’t want the user to see that a lot of logos are appearing and disappearing before anything else is loaded.

So any suggestions?

Cheers,

Phil

The color sample function does check the whole screen, but once you draw your logo, you can to the chromaKey filter to knock out the background based on the value you color sampled.

https://docs.coronalabs.com/api/library/display/colorSample.html

Rob

The color sample function does check the whole screen, but once you draw your logo, you can to the chromaKey filter to knock out the background based on the value you color sampled.

https://docs.coronalabs.com/api/library/display/colorSample.html

Rob