ios - Converting a value within 16-bit color range to a UIColor -
i have value in 1 number range , want convert number in 16 bit color range - 65536 colors. how can use value in 65536 colour range uicolor? have method convert hex value color, how 1 convert unsigned int hex value , accurate?
what best way color value within 65536 color range?
[uicolor colorwithred: (color>>11)/31.0 green: ((color>>5)&0x3f)/63.0 blue: (color&0x1f)/31.0 alpha: 1]
layout of 16-bit colors (source):
Comments
Post a Comment