|
|
@@ -33,9 +33,9 @@ static float const ciede2k[] = |
|
|
|
50.0000f, 0.0000f, 0.0000f, 50.0000f, -1.0000f, 2.0000f, 2.3669f, |
|
|
|
50.0000f, -1.0000f, 2.0000f, 50.0000f, 0.0000f, 0.0000f, 2.3669f, |
|
|
|
50.0000f, 2.4900f, -0.0010f, 50.0000f, -2.4900f, 0.0009f, 7.1792f, |
|
|
|
50.0000f, 2.4900f, -0.0010f, 50.0000f, -2.4900f, 0.0010f, 7.1792f, |
|
|
|
//50.0000f, 2.4900f, -0.0010f, 50.0000f, -2.4900f, 0.0011f, 7.2195f, |
|
|
|
//50.0000f, 2.4900f, -0.0010f, 50.0000f, -2.4900f, 0.0012f, 7.2195f, |
|
|
|
//50.0000f, 2.4900f, -0.0010f, 50.0000f, -2.4900f, 0.0010f, 7.1792f, |
|
|
|
50.0000f, 2.4900f, -0.0010f, 50.0000f, -2.4900f, 0.0011f, 7.2195f, |
|
|
|
50.0000f, 2.4900f, -0.0010f, 50.0000f, -2.4900f, 0.0012f, 7.2195f, |
|
|
|
50.0000f, -0.0010f, 2.4900f, 50.0000f, 0.0009f, -2.4900f, 4.8045f, |
|
|
|
//50.0000f, -0.0010f, 2.4900f, 50.0000f, 0.0010f, -2.4900f, 4.8045f, |
|
|
|
50.0000f, -0.0010f, 2.4900f, 50.0000f, 0.0011f, -2.4900f, 4.7461f, |
|
|
@@ -77,8 +77,13 @@ LOLUNIT_FIXTURE(ColorTest) |
|
|
|
float d1 = ciede2k[n + 6]; |
|
|
|
|
|
|
|
float d2 = Color::DistanceCIEDE2000(a, b); |
|
|
|
float d3 = Color::DistanceCIEDE2000(b, a); |
|
|
|
|
|
|
|
/* Check that our function works, and check that |
|
|
|
* it is symmetrical. */ |
|
|
|
LOLUNIT_SET_CONTEXT(n / 7); |
|
|
|
LOLUNIT_ASSERT_DOUBLES_EQUAL(d1, d2, 0.0001); |
|
|
|
LOLUNIT_ASSERT_DOUBLES_EQUAL(d2, d3, 0.0001); |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|