Hi, Cesar I have tested a little both versions. In many colors they give me the same results. But, in other cases, your version give me results that looks similar to the original color. Here are two examples:
Color to aproximate: r:85, g:0, b:255
Cesar: r:31, g:82, b:138
SkripT: r:79, g:110, b:140
Color to aproximate: r:255, g:85, b:255
Cesar: r:245, g:207, b:178
SkripT: r:255, g:255, b:255
In other cases where they gave me different results, was difficult to say which of one was closer to the original color because is a very subjective fact. Finally I maintain your version because looks more professional calculating the difference with the distance between points
Cheers.
Bookmarks