palette-shader 0.15.0 → 0.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +24 -24
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -191,16 +191,16 @@ Controls the 3-D color space the visualization is rendered in. Polar variants (`
|
|
|
191
191
|
|
|
192
192
|
**OK — Lab / LCH**
|
|
193
193
|
|
|
194
|
-
| Value
|
|
195
|
-
|
|
|
196
|
-
| `'oklab'`
|
|
197
|
-
| `'oklch'`
|
|
198
|
-
| `'oklchPolar'`
|
|
199
|
-
| `'oklchDiag'`
|
|
200
|
-
| `'oklrab'`
|
|
201
|
-
| `'oklrch'`
|
|
202
|
-
| `'oklrchPolar'`
|
|
203
|
-
| `'oklrchDiag'`
|
|
194
|
+
| Value | Shape | Description |
|
|
195
|
+
| --------------- | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
196
|
+
| `'oklab'` | cube | Raw OKLab: x→a, y→b, z→L. |
|
|
197
|
+
| `'oklch'` | cube | OKLab in cylindrical LCH coordinates. Ideal for chroma or lightness slices. |
|
|
198
|
+
| `'oklchPolar'` | wheel | Polar form of OKLch. |
|
|
199
|
+
| `'oklchDiag'` | diagonal | Complementary hue plane: lightness on the diagonal, signed chroma on the anti-diagonal. Two opposite hues share the same view — no gray band in the middle. |
|
|
200
|
+
| `'oklrab'` | cube | OKLab with toe-corrected lightness (Lr). Better perceptual uniformity in dark tones. |
|
|
201
|
+
| `'oklrch'` | cube | OKLrab in cylindrical LCH coordinates. |
|
|
202
|
+
| `'oklrchPolar'` | wheel | Polar form of OKLrch. |
|
|
203
|
+
| `'oklrchDiag'` | diagonal | Complementary hue plane in OKLrch. Same diagonal layout as `oklchDiag` with toe-corrected lightness. |
|
|
204
204
|
|
|
205
205
|
**CIE Lab / LCH — D65**
|
|
206
206
|
|
|
@@ -232,18 +232,18 @@ Controls the 3-D color space the visualization is rendered in. Polar variants (`
|
|
|
232
232
|
|
|
233
233
|
**Quantized RGB**
|
|
234
234
|
|
|
235
|
-
| Value | Shape | Description
|
|
236
|
-
| ------------ | ----- |
|
|
237
|
-
| `'rgb6bit'` | cube | 2-bit per channel (64 colors). Game Boy–era palettes.
|
|
238
|
-
| `'rgb8bit'` | cube | 3-3-2 bit (256 colors). CGA-style quantization.
|
|
239
|
-
| `'rgb12bit'` | cube | 4-bit per channel (4096 colors). Amiga / NTSC.
|
|
240
|
-
| `'rgb15bit'` | cube | 5-bit per channel (32768 colors). SVGA HiColor.
|
|
241
|
-
| `'rgb18bit'` | cube | 6-bit per channel (262144 colors). VGA.
|
|
235
|
+
| Value | Shape | Description |
|
|
236
|
+
| ------------ | ----- | ----------------------------------------------------- |
|
|
237
|
+
| `'rgb6bit'` | cube | 2-bit per channel (64 colors). Game Boy–era palettes. |
|
|
238
|
+
| `'rgb8bit'` | cube | 3-3-2 bit (256 colors). CGA-style quantization. |
|
|
239
|
+
| `'rgb12bit'` | cube | 4-bit per channel (4096 colors). Amiga / NTSC. |
|
|
240
|
+
| `'rgb15bit'` | cube | 5-bit per channel (32768 colors). SVGA HiColor. |
|
|
241
|
+
| `'rgb18bit'` | cube | 6-bit per channel (262144 colors). VGA. |
|
|
242
242
|
|
|
243
243
|
**Spectral**
|
|
244
244
|
|
|
245
|
-
| Value | Shape | Description
|
|
246
|
-
| ------------ | ----- |
|
|
245
|
+
| Value | Shape | Description |
|
|
246
|
+
| ------------ | ----- | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
247
247
|
| `'spectrum'` | cube | Visible light wavelengths (410–665 nm) plus purple line, modulated in OKLab. Inspired by censor's SpectroBoxWidget. X→wavelength, Y→lightness, Z→chroma scale. |
|
|
248
248
|
|
|
249
249
|
The OK-variants rely on Björn Ottosson's gamut-aware implementation and produce significantly more even hue distributions than the classic variants at the same GPU cost.
|
|
@@ -266,11 +266,11 @@ Controls how "nearest palette color" is determined per pixel.
|
|
|
266
266
|
|
|
267
267
|
**OK**
|
|
268
268
|
|
|
269
|
-
| Value | Description
|
|
270
|
-
| --------------- |
|
|
271
|
-
| `'oklab'` | **Default.** Euclidean distance in OKLab. Fast, perceptually uniform, excellent general-purpose choice.
|
|
272
|
-
| `'oklrab'` | Euclidean in OKLab with toe-corrected lightness. Slightly better uniformity in dark tones than OKLab.
|
|
273
|
-
| `'okLightness'` | Absolute lightness difference in OKLab (
|
|
269
|
+
| Value | Description | Cost |
|
|
270
|
+
| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ---- | ------------------------------------------------------- | --- |
|
|
271
|
+
| `'oklab'` | **Default.** Euclidean distance in OKLab. Fast, perceptually uniform, excellent general-purpose choice. | low |
|
|
272
|
+
| `'oklrab'` | Euclidean in OKLab with toe-corrected lightness. Slightly better uniformity in dark tones than OKLab. | low |
|
|
273
|
+
| `'okLightness'` | Absolute lightness difference in OKLab (` | ΔL | `). Ignores hue and chroma — groups by brightness only. | low |
|
|
274
274
|
| `'liMatch'` | Spatially varying blend: full OKLab distance at the left edge, pure lightness match at the right. Inspired by censor's li-match. Useful for visualising tonal structure. | low |
|
|
275
275
|
|
|
276
276
|
**CIE — D65**
|
package/package.json
CHANGED