Created
March 30, 2012 16:48
-
-
Save garthhumphreys/2252774 to your computer and use it in GitHub Desktop.
RGBColor Macro
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* rgb color */ | |
#define RGBCOLOR(r,g,b) \ | |
[UIColor colorWithRed:r/256.f green:g/256.f blue:b/256.f alpha:1.f] | |
/* rgb color with alpha (rgba) */ | |
#define RGBACOLOR(r,g,b,a) \ | |
[UIColor colorWithRed:r/256.f green:g/256.f blue:b/256.f alpha:a] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment