arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2606.15352eess.IVcs.CVcs.GR
收藏

色度门控、可微分的OKLCH插值:用于减少色偏的连续Oklab回退

Chroma-gated, differentiable OKLCH interpolation: Continuous Oklab fallback for color-cast reduction

Independent Researcher(独立研究者)

Naoyuki Uchida

AI总结:

针对OKLCH插值在中性轴附近的两种色偏问题,提出一种可微分的色度门控函数,连续混合OKLCH和线性Oklab路径,在不依赖端点测试的情况下统一处理两种色偏,并验证了其有效性。

摘要:

OKLCH——Ottosson的Oklab颜色空间的圆柱形式(亮度、色度、色调)——是CSS Color 4推荐的用于渐变和color-mix()的插值空间,现已广泛部署。然而,其极坐标参数化在中性轴附近以两种方式产生色偏:(1)两个彩色端点之间的色调间绕行,经过非预期的色调(蓝色到黄色明显经过绿色);(2)当一个端点为消色差时,产生离线弯曲。现有补救措施统一为二值化——仅在消色差端点触发的阈值开关——因此它们仅处理(2);对于彩色对,它们都退化为原始OKLCH,未处理(1)色调间色偏。我们引入连续Oklab回退(COFb),一个单参数、可微分的色度门控$w(C)=C^n/(C^n+σ^n)$,随着色度下降,将OKLCH路径连续混合到线性Oklab路径。单个门控减少了二值化家族未处理的(1)色偏,并统一处理(1)和(2),无需任何端点测试。我们刻画了一个色偏-色调权衡边界,采用默认值($n=1$,有理Michaelis-Menten形式;对于典型sRGB调色板,$σ\approx0.19$,基于归一化无关的半色偏准则),并符号验证了门控的性质。在默认值下,COFb将色调间路径绕行减半(平均横向偏差-49.5%,色度加权色调偏移-35.5%)。我们还说明了该方法的局限性:仅针对(2),二值化开关仍然更好,并且像任何笛卡尔混合一样,COFb不保持色度。在部署中,COFb完全在普通Oklab (a,b)到sRGB中运行,因此它作为一种回退,在无法使用现代CSS颜色插值(color-mix(in oklch)等)的场合——旧引擎、图像和视频管线或GPU着色器——提供相同的减少色偏的渐变。

英文摘要:

OKLCH -- the cylindrical (lightness, chroma, hue) form of Ottosson's Oklab color space -- is the interpolation space recommended by CSS Color 4 for gradients and color-mix(), and it is now broadly deployed. Its polar parameterization, however, casts color near the neutral axis in two ways: (1) an inter-hue detour between two chromatic endpoints that sweeps through an unintended hue (blue to yellow visibly passing through green), and (2) an off-line bow when one endpoint is achromatic. Existing remedies are uniformly two-valued -- a threshold switch that fires only at an achromatic endpoint -- so they address only (2); on chromatic pairs every one of them reduces to raw OKLCH, leaving the (1) inter-hue cast untreated. We introduce Continuous Oklab fallback (COFb), a one-parameter, differentiable chroma gate $w(C)=C^n/(C^n+σ^n)$ that continuously blends the OKLCH path toward the linear Oklab path as chroma falls. A single gate reduces the (1) cast that the two-valued family leaves untreated and unifies the handling of (1) and (2) without any endpoint test. We characterize a cast-hue trade-off frontier, adopt a default ($n=1$, the rational Michaelis-Menten form; $σ\approx0.19$ for a typical sRGB palette, from a normalization-independent cast-half criterion), and verify the gate's properties symbolically. At the default, COFb halves the inter-hue path detour (mean lateral deviation -49.5%, chroma-weighted hue excursion -35.5%). We also state the method's limits: on (2) alone the two-valued switch remains better, and like any Cartesian blend COFb does not preserve chroma. In deployment, COFb runs entirely in plain Oklab (a,b) to sRGB, so it serves as a fallback that delivers the same cast-reduced gradients where modern CSS color interpolation (color-mix(in oklch) and the like) is unavailable -- older engines, image and video pipelines, or GPU shaders.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑