GetClosestColor implemented
This commit is contained in:
parent
376253996e
commit
cac788b6a6
3 changed files with 22 additions and 0 deletions
|
|
@ -76,6 +76,14 @@ internal static class Internal
|
|||
return _timespan.ToString();
|
||||
}
|
||||
}
|
||||
internal static int GetDiff(Color color, Color baseColor)
|
||||
{
|
||||
int a = color.A - baseColor.A,
|
||||
r = color.R - baseColor.R,
|
||||
g = color.G - baseColor.G,
|
||||
b = color.B - baseColor.B;
|
||||
return a * a + r * r + g * g + b * b;
|
||||
}
|
||||
}
|
||||
|
||||
public class InternalSheduler
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue