I get an output that says ExtendedSRGB
. I have given the output that I got below:
I need to display the SRGB
colour in a UIView
, so it appears something like:
self.view.backgroundColor = SRGB VALUES
But, unlike RGB
values SRGB
values range from 0..1
. Therefore, how can I display colour.
[ (kCGColorSpaceICCBased; kCGColorSpaceModelRGB; sRGB IEC61966-2.1)] ( 0.745098 0.745098 1 1 )
Try the code below :
As per sRGV values, output is :
For more stuff, Refer to links:
https://codexample.org/questions/779247/how-do-i-compare-2-uicolor-objects-which-are-kcgcolorspacemodelrgb-and-uiextendedsrgbcolorspace-instances-in-logs.c iOS - color on xcode simulator is different from the color on device hex colors in iOS are not accurate
Hope will be helping!