Why does the following not return precisely {0.99,0.5,0.49}?
Is there a way to avoid the discrepancy?
In[2089]:=
ImageData[
Show[Graphics[{FaceForm[RGBColor[0.99, 1/2, 0.490000]],
Polygon[{{0, 0}, {1, 0}, {1, 1}, {0, 1}}]}], ImageSize -> 20,
ImagePadding -> None]][[10, 10]]
Out[2089]= {0.988235, 0.501961, 0.490196}
c/255
wherec
is in interval[0,255]
for values of colors to be exact. Or use hexadecimalRGBColor["#ff0000"]
. $\endgroup$RGBColor[0.99, 1/2, 0.490000]
? Tryimg = Image[ConstantArray[RGBColor[0.99, 1/2, 0.490000], {20, 20}]]
. Verify withFlatten[ImageData[img], 1] // DeleteDuplicates
is{{0.99, 0.5, 0.49}}
. $\endgroup$