diff --git a/apps/gamut-mapping/methods.js b/apps/gamut-mapping/methods.js index f0af87187..519e37e44 100644 --- a/apps/gamut-mapping/methods.js +++ b/apps/gamut-mapping/methods.js @@ -23,6 +23,9 @@ const methods = { label: "Scale LH", description: "Runs Scale, sets L, H to those of the original color, then runs Scale again.", compute: (color) => { + if (color.inGamut("p3", { epsilon: 0 })) { + return color; + } let mappedColor = methods.scale.compute(color); let lch = color.to("oklch").coords; mappedColor.set({