Skip to main content
Glama
convertRgbToLab65.js522 B
import convertRgbToXyz65 from '../xyz65/convertRgbToXyz65.js'; import convertXyz65ToLab65 from './convertXyz65ToLab65.js'; const convertRgbToLab65 = rgb => { let res = convertXyz65ToLab65(convertRgbToXyz65(rgb)); // Fixes achromatic RGB colors having a _slight_ chroma due to floating-point errors // and approximated computations in sRGB <-> CIELab. // See: https://github.com/d3/d3-color/pull/46 if (rgb.r === rgb.b && rgb.b === rgb.g) { res.a = res.b = 0; } return res; }; export default convertRgbToLab65;

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/MatheusgVentura/Project-One'

If you have feedback or need assistance with the MCP directory API, please join our Discord server