On Thu, 1 Aug 2024 18:02:05 GMT, Andy Goryachev <ango...@openjdk.org> wrote:

>> I'm not sure this test needs to be that precise. And I'm fine with the 
>> threshold falling below 2.0/255.0 since it should be as small as possible (I 
>> even experimented briefly with lower numbers). I haven't run into an issue 
>> on the three platforms I've run this test on.
>
> Then the comment might not be technically correct, because it is possible to 
> have "two bit difference" in the integer color values, yet fail due to small 
> error intrinsic in floating point operations.
> 
> Example:
> 
> a=253 b=251 delta=0.007843137254902044 tol=0.00784313725490196
> 
> delta=0.007843137254902044
>   tol=0.00784313725490196  (2.0 / 255.0)

I've updated the constant as you suggested.

-------------

PR Review Comment: https://git.openjdk.org/jfx/pull/1473#discussion_r1700739626

Reply via email to