Wednesday, January 20, 2010

Adjusting a color’s brightness using the ColorUtil class

Here’s a handy little trick, compliments of the ColorUtil class. The ColorUtil class has a couple useful methods if you ever need to change a color’s brightness using either a linear brightness adjustment (ColorUtil.adjustBrightness()) or a scaled brightness adjustment (ColorUtil.adjustBrightness2()). Mind you, I have no idea what that linear brightness versus scaled brightness actually means, so I’ll show both methods side-by-side.

Full code after the jump.

(more…)

flex color brightness

No comments:

Post a Comment

Your comments is appreciate.