@lovo/matter 0.4.1 → 0.6.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/CHANGELOG.md CHANGED
@@ -1,5 +1,33 @@
1
1
  # @lovo/matter
2
2
 
3
+ ## 0.6.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 24ec05d: Add color-space-aware interpolation. `colorRamp` and the new `mixColor` primitive
8
+ accept `colorSpace` ('linear' | 'oklab' | 'oklch' | 'lch' | 'hsl' | 'hsv',
9
+ default 'oklab') and `hueInterpolation` ('shorter' | 'longer' | 'increasing' |
10
+ 'decreasing', default 'shorter'). LinearGradient, SimplexNoise, and MeshGradient
11
+ gain matching props. Foundation fix: hex colors now decode to linear-sRGB (true
12
+ color), and the LCH conversion's green coefficient was corrected. This shifts the
13
+ default appearance of those components (pre-1.0 breaking color change).
14
+
15
+ ## 0.5.0
16
+
17
+ ### Minor Changes
18
+
19
+ - c67eb98: Rename engine exports to spelled-out, domain-accurate names (breaking).
20
+
21
+ - `fbm` → `fractalNoise` (and `FBMOptions` → `FractalNoiseOptions`)
22
+ - `noise` → `simplexNoise`
23
+ - `sdfCircle` → `signedDistanceFieldCircle`
24
+ - `time` → `elapsedTime`
25
+ - `Vec2` → `Vector2`
26
+
27
+ `TSLNode`, `voronoi`, `colorRamp`, `quantize`, `displace`, `cursorRipple`, and `filmGrain` are unchanged.
28
+
29
+ **Migration:** one-pass find-and-replace in your imports and call sites. No behavioral changes.
30
+
3
31
  ## 0.4.1
4
32
 
5
33
  ### Patch Changes
package/README.md CHANGED
@@ -15,18 +15,18 @@ npm install @lovo/matter three
15
15
 
16
16
  ## What's inside
17
17
 
18
- - **TSL primitives**: `fbm`, `voronoi`, `colorRamp`, `quantize`, and a handful of others — composable shader fragments for procedural visuals.
18
+ - **TSL primitives**: `fractalNoise`, `voronoi`, `colorRamp`, `quantize`, and a handful of others — composable shader fragments for procedural visuals.
19
19
  - **Renderer**: thin wrapper around `WebGPURenderer` that handles canvas resize, DPR, and `setClearColor`.
20
20
  - **Scheduler**: visibility/intersection-aware render loop that pauses when the canvas is off-screen or the tab is hidden.
21
21
 
22
22
  ## Minimal usage
23
23
 
24
24
  ```typescript
25
- import { fbm, colorRamp } from '@lovo/matter'
25
+ import { fractalNoise, colorRamp } from '@lovo/matter'
26
26
  import { uv, vec3, time } from 'three/tsl'
27
27
 
28
28
  // Inside your TSL fragment graph:
29
- const noise = fbm(uv().mul(4).add(time.mul(0.1)))
29
+ const noise = fractalNoise(uv().mul(4).add(time.mul(0.1)))
30
30
  const color = colorRamp(noise, [
31
31
  { stop: 0.0, color: vec3(0.05, 0.05, 0.1) },
32
32
  { stop: 1.0, color: vec3(0.3, 0.5, 0.95) },