Skip to main content
Glama
convertCubehelixToRgb.js529 B
import { degToRad, M } from './constants.js'; const convertCubehelixToRgb = ({ h, s, l, alpha }) => { let res = { mode: 'rgb' }; h = (h === undefined ? 0 : h + 120) * degToRad; let amp = s === undefined ? 0 : s * l * (1 - l); let cosh = Math.cos(h); let sinh = Math.sin(h); res.r = l + amp * (M[0] * cosh + M[1] * sinh); res.g = l + amp * (M[2] * cosh + M[3] * sinh); res.b = l + amp * (M[4] * cosh + M[5] * sinh); if (alpha !== undefined) res.alpha = alpha; return res; }; export default convertCubehelixToRgb;

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