DAWG Tools - OKLab Color Inspector PRO - Perceptual Color Tools for Unity
Unity’s default Color.Lerp interpolates colors in RGB component space.
https://dawgtools.org/unity/
For UI and theme transitions, this often results in:
- Desaturated or “dirty” midpoints
- Perceived brightness dips
- Unintended hue shifts
- Inconsistent animation quality
The OKLab color space is designed so that distance and interpolation better match human perception.
This tool makes the difference visible, measurable, and actionable inside the Unity Editor.
OKLab interpolation produces smoother, visually consistent gradients and transitions because it operates in a perceptual color space rather than raw RGB component space.
Instead of guessing how a transition will look, you can:
- Compare Gamma RGB vs Linear RGB vs OKLab interpolation
- Inspect perceptual midpoints
- Measure ΔE distance between colors
- Validate contrast compliance before shipping
1. Typical Workflow
- Select two UI colors (e.g., Normal → Hover).
- Compare Unity RGB interpolation against OKLab interpolation.
- Inspect midpoint, hue drift, chroma, and contrast.
- Replace Color.Lerp with OKLabColor.Lerp in runtime code.
2. Who It’s For:
- UI / UX engineers
- Technical artists
- Tools programmers
- Teams implementing dynamic themes
- Developers who care about visual polish and accessibility
3. WHAT'S INCLUDED
Interpolation Comparison
Side-by-side preview of:
- Unity RGB (Gamma)
- Linear RGB
- OKLab interpolation
Instantly see how transitions differ visually and mathematically.
Perceptual Metrics
- ΔE (perceptual distance measurement)
- Live midpoint inspection
- Chroma comparison
- OKLab component breakdown (L, a, b)
- Hue angle visualization
Accessibility & Contrast Tools
- WCAG contrast ratio calculation
- AA / AAA / Large-text thresholds
- Automatic best-text color suggestion
- Contrast validation against background colors
Computed correctly in linear luminance space.
OKLab Utilities
- OKLabColor.Lerp runtime helper
- OKLab decomposition per color
- Copy helpers (Hex, OKLab values)
- Lock Lightness (L)Optional perceptual constraints:
Lock Chroma (C)