shaders 2.2.0 → 2.2.2
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/dist/core/{AngularBlur-BJi-Edw-.js → AngularBlur-BTUdXC0g.js} +7 -6
- package/dist/core/{Ascii-B1KHvM1u.js → Ascii-Bu8ii7oo.js} +32 -31
- package/dist/core/Blob-C0G0efjG.js +170 -0
- package/dist/core/{Blur-bz9Ubr0x.js → Blur-BzUO9yxF.js} +14 -13
- package/dist/core/Bulge-BCXYAzig.js +104 -0
- package/dist/core/{CRTScreen-BnfROw0f.js → CRTScreen-cJ3XHrI9.js} +13 -12
- package/dist/core/{ChannelBlur-DhWT-55L.js → ChannelBlur-BEK1qzGn.js} +23 -22
- package/dist/core/{Checkerboard-CgWGd9t7.js → Checkerboard-BPkiSF5I.js} +16 -14
- package/dist/core/{ChromaFlow-DOVrymVB.js → ChromaFlow-AHO3C4o3.js} +18 -17
- package/dist/core/{ChromaticAberration-CyTSXY7j.js → ChromaticAberration-nVg3r1FK.js} +12 -11
- package/dist/core/{Circle-0WHV1HrM.js → Circle-C8ltF4BZ.js} +15 -13
- package/dist/core/{CursorTrail-3zQ5rtjh.js → CursorTrail-BeJGeovB.js} +17 -16
- package/dist/core/DiffuseBlur-BdGvOoBw.js +40 -0
- package/dist/core/{Dither-Cnbknfji.js → Dither-CpN3vGSh.js} +13 -12
- package/dist/core/DotGrid-BFUzeSQw.js +62 -0
- package/dist/core/{Duotone-BI4tJI3k.js → Duotone-_nR_o3-g.js} +8 -7
- package/dist/core/FilmGrain-BAKXXtLg.js +29 -0
- package/dist/core/FloatingParticles-Fv8JIzKk.js +161 -0
- package/dist/core/GlassTiles-5MyBj1ff.js +53 -0
- package/dist/core/{Glow-BD0t9E1L.js → Glow-DvJj7BB7.js} +12 -11
- package/dist/core/{Godrays-CPIAbymT.js → Godrays-cUzAKVXn.js} +24 -22
- package/dist/core/{Grayscale-BtOqK43k.js → Grayscale-oWIF3PV5.js} +3 -2
- package/dist/core/Grid-Bov7AA9m.js +51 -0
- package/dist/core/GridDistortion-CWYom5Dw.js +148 -0
- package/dist/core/Group-CPk-7fiA.js +18 -0
- package/dist/core/{Halftone-B_MuXCD8.js → Halftone-F7fsdu7W.js} +11 -10
- package/dist/core/{HueShift-CKG9M-d2.js → HueShift-CiS4hdtk.js} +3 -2
- package/dist/core/{ImageTexture-B6zFP2fB.js → ImageTexture-B3Q29OHX.js} +24 -22
- package/dist/core/Invert-Cyc4JHWc.js +21 -0
- package/dist/core/{LinearBlur-JFLMQBY4.js → LinearBlur-BTC54qzk.js} +12 -11
- package/dist/core/{LinearGradient-Ztg5Lzwj.js → LinearGradient-LEMeW0KM.js} +18 -16
- package/dist/core/Liquify-D2nzMDzq.js +140 -0
- package/dist/core/Pixelate-irPzmtQm.js +39 -0
- package/dist/core/{PolarCoordinates-qzU8gNXR.js → PolarCoordinates-Ck5ZWrQO.js} +21 -16
- package/dist/core/{Posterize-BkBU8tnN.js → Posterize-DICq_t96.js} +9 -8
- package/dist/core/{ProgressiveBlur-HAQf188T.js → ProgressiveBlur-BuORe3VH.js} +17 -16
- package/dist/core/{RadialGradient-DISqJuTZ.js → RadialGradient-D0cN67jm.js} +17 -15
- package/dist/core/RectangularCoordinates-1LIDaeHR.js +93 -0
- package/dist/core/{Ripples-CX8Qgnog.js → Ripples-DH71sFJc.js} +14 -12
- package/dist/core/{Saturation-DMxPYmIU.js → Saturation-DbSXtSeK.js} +10 -9
- package/dist/core/{SimplexNoise-B5ygfckG.js → SimplexNoise-DPGC2OPJ.js} +14 -12
- package/dist/core/{SineWave-KPFlP3Wk.js → SineWave-CkWtnzHF.js} +16 -14
- package/dist/core/{SolidColor-B8oxlGge.js → SolidColor-DaB-FHNX.js} +8 -6
- package/dist/core/{Spiral-CX22hUJ3.js → Spiral-CcyI8azF.js} +19 -17
- package/dist/core/Strands-Co4fkc05.js +126 -0
- package/dist/core/{Swirl-CIXreSgZ.js → Swirl-BoveqtNV.js} +18 -16
- package/dist/core/{TiltShift-J0UUcoh-.js → TiltShift-D53azmRe.js} +14 -13
- package/dist/core/{Tritone-E9eHvjJV.js → Tritone-Cg1rX-hL.js} +13 -12
- package/dist/core/{Twirl-ClhPpapm.js → Twirl-raO5pe5X.js} +20 -15
- package/dist/core/{Vibrance-CqnE9Zco.js → Vibrance-DtekSkcz.js} +8 -7
- package/dist/core/WaveDistortion-C65qO_cZ.js +133 -0
- package/dist/core/{ZoomBlur-CaGbSDG3.js → ZoomBlur-B97ZjhXe.js} +11 -10
- package/dist/core/{colorMixing-C_ESXyqX.js → colorMixing-DPZ-Td4U.js} +3 -3
- package/dist/core/edges-B-tVdqcI.js +16 -0
- package/dist/core/index.js +1333 -948
- package/dist/core/performanceTracker.d.ts +2 -0
- package/dist/core/performanceTracker.d.ts.map +1 -1
- package/dist/core/renderer.d.ts +12 -0
- package/dist/core/renderer.d.ts.map +1 -1
- package/dist/core/shaderRegistry.d.ts.map +1 -1
- package/dist/core/shaders/AngularBlur/index.d.ts.map +1 -1
- package/dist/core/shaders/AngularBlur/index.js +3 -3
- package/dist/core/shaders/Ascii/index.d.ts.map +1 -1
- package/dist/core/shaders/Ascii/index.js +2 -2
- package/dist/core/shaders/Blob/index.d.ts.map +1 -1
- package/dist/core/shaders/Blob/index.js +5 -5
- package/dist/core/shaders/Blur/index.d.ts.map +1 -1
- package/dist/core/shaders/Blur/index.js +2 -2
- package/dist/core/shaders/Bulge/index.d.ts.map +1 -1
- package/dist/core/shaders/Bulge/index.js +4 -4
- package/dist/core/shaders/CRTScreen/index.d.ts.map +1 -1
- package/dist/core/shaders/CRTScreen/index.js +2 -2
- package/dist/core/shaders/ChannelBlur/index.d.ts.map +1 -1
- package/dist/core/shaders/ChannelBlur/index.js +2 -2
- package/dist/core/shaders/Checkerboard/index.d.ts.map +1 -1
- package/dist/core/shaders/Checkerboard/index.js +4 -4
- package/dist/core/shaders/ChromaFlow/index.d.ts.map +1 -1
- package/dist/core/shaders/ChromaFlow/index.js +3 -3
- package/dist/core/shaders/ChromaticAberration/index.d.ts.map +1 -1
- package/dist/core/shaders/ChromaticAberration/index.js +3 -3
- package/dist/core/shaders/Circle/index.d.ts.map +1 -1
- package/dist/core/shaders/Circle/index.js +3 -3
- package/dist/core/shaders/CursorTrail/index.d.ts.map +1 -1
- package/dist/core/shaders/CursorTrail/index.js +4 -4
- package/dist/core/shaders/DiffuseBlur/index.d.ts.map +1 -1
- package/dist/core/shaders/DiffuseBlur/index.js +2 -2
- package/dist/core/shaders/Dither/index.d.ts.map +1 -1
- package/dist/core/shaders/Dither/index.js +3 -3
- package/dist/core/shaders/DotGrid/index.d.ts.map +1 -1
- package/dist/core/shaders/DotGrid/index.js +3 -3
- package/dist/core/shaders/Duotone/index.d.ts.map +1 -1
- package/dist/core/shaders/Duotone/index.js +4 -4
- package/dist/core/shaders/FilmGrain/index.d.ts.map +1 -1
- package/dist/core/shaders/FilmGrain/index.js +2 -2
- package/dist/core/shaders/FloatingParticles/index.d.ts.map +1 -1
- package/dist/core/shaders/FloatingParticles/index.js +3 -3
- package/dist/core/shaders/GlassTiles/index.d.ts.map +1 -1
- package/dist/core/shaders/GlassTiles/index.js +2 -2
- package/dist/core/shaders/Glow/index.d.ts.map +1 -1
- package/dist/core/shaders/Glow/index.js +2 -2
- package/dist/core/shaders/Godrays/index.d.ts.map +1 -1
- package/dist/core/shaders/Godrays/index.js +3 -3
- package/dist/core/shaders/Grayscale/index.d.ts.map +1 -1
- package/dist/core/shaders/Grayscale/index.js +2 -2
- package/dist/core/shaders/Grid/index.d.ts.map +1 -1
- package/dist/core/shaders/Grid/index.js +3 -3
- package/dist/core/shaders/GridDistortion/index.d.ts.map +1 -1
- package/dist/core/shaders/GridDistortion/index.js +4 -4
- package/dist/core/shaders/Group/index.d.ts.map +1 -1
- package/dist/core/shaders/Group/index.js +2 -2
- package/dist/core/shaders/Halftone/index.d.ts.map +1 -1
- package/dist/core/shaders/Halftone/index.js +3 -3
- package/dist/core/shaders/HueShift/index.d.ts.map +1 -1
- package/dist/core/shaders/HueShift/index.js +2 -2
- package/dist/core/shaders/ImageTexture/index.d.ts +1 -1
- package/dist/core/shaders/ImageTexture/index.d.ts.map +1 -1
- package/dist/core/shaders/ImageTexture/index.js +2 -2
- package/dist/core/shaders/Invert/index.d.ts.map +1 -1
- package/dist/core/shaders/Invert/index.js +2 -2
- package/dist/core/shaders/LinearBlur/index.d.ts.map +1 -1
- package/dist/core/shaders/LinearBlur/index.js +3 -3
- package/dist/core/shaders/LinearGradient/index.d.ts.map +1 -1
- package/dist/core/shaders/LinearGradient/index.js +4 -4
- package/dist/core/shaders/Liquify/index.d.ts.map +1 -1
- package/dist/core/shaders/Liquify/index.js +4 -4
- package/dist/core/shaders/Pixelate/index.d.ts.map +1 -1
- package/dist/core/shaders/Pixelate/index.js +2 -2
- package/dist/core/shaders/PolarCoordinates/index.d.ts.map +1 -1
- package/dist/core/shaders/PolarCoordinates/index.js +4 -4
- package/dist/core/shaders/Posterize/index.d.ts.map +1 -1
- package/dist/core/shaders/Posterize/index.js +2 -2
- package/dist/core/shaders/ProgressiveBlur/index.d.ts.map +1 -1
- package/dist/core/shaders/ProgressiveBlur/index.js +3 -3
- package/dist/core/shaders/RadialGradient/index.d.ts.map +1 -1
- package/dist/core/shaders/RadialGradient/index.js +4 -4
- package/dist/core/shaders/RectangularCoordinates/index.d.ts +38 -0
- package/dist/core/shaders/RectangularCoordinates/index.d.ts.map +1 -0
- package/dist/core/shaders/RectangularCoordinates/index.js +8 -0
- package/dist/core/shaders/Ripples/index.d.ts.map +1 -1
- package/dist/core/shaders/Ripples/index.js +4 -4
- package/dist/core/shaders/Saturation/index.d.ts.map +1 -1
- package/dist/core/shaders/Saturation/index.js +2 -2
- package/dist/core/shaders/SimplexNoise/index.d.ts.map +1 -1
- package/dist/core/shaders/SimplexNoise/index.js +4 -4
- package/dist/core/shaders/SineWave/index.d.ts.map +1 -1
- package/dist/core/shaders/SineWave/index.js +3 -3
- package/dist/core/shaders/SolidColor/index.d.ts.map +1 -1
- package/dist/core/shaders/SolidColor/index.js +3 -3
- package/dist/core/shaders/Spiral/index.d.ts.map +1 -1
- package/dist/core/shaders/Spiral/index.js +4 -4
- package/dist/core/shaders/Strands/index.d.ts.map +1 -1
- package/dist/core/shaders/Strands/index.js +4 -4
- package/dist/core/shaders/Swirl/index.d.ts.map +1 -1
- package/dist/core/shaders/Swirl/index.js +5 -5
- package/dist/core/shaders/TiltShift/index.d.ts.map +1 -1
- package/dist/core/shaders/TiltShift/index.js +3 -3
- package/dist/core/shaders/Tritone/index.d.ts.map +1 -1
- package/dist/core/shaders/Tritone/index.js +4 -4
- package/dist/core/shaders/Twirl/index.d.ts.map +1 -1
- package/dist/core/shaders/Twirl/index.js +4 -4
- package/dist/core/shaders/Vibrance/index.d.ts.map +1 -1
- package/dist/core/shaders/Vibrance/index.js +2 -2
- package/dist/core/shaders/WaveDistortion/index.d.ts.map +1 -1
- package/dist/core/shaders/WaveDistortion/index.js +6 -7
- package/dist/core/shaders/ZoomBlur/index.d.ts.map +1 -1
- package/dist/core/shaders/ZoomBlur/index.js +3 -3
- package/dist/core/telemetry/collector.d.ts.map +1 -1
- package/dist/core/telemetry/index.js +19 -19
- package/dist/core/{three.tsl-CgyjOhns.js → three.tsl-BqgDcRt9.js} +21 -20
- package/dist/core/{time-myrFQH-u.js → time-5uQ65blS.js} +1 -1
- package/dist/core/{transformations-Bs66Qh16.js → transformations-DBjTkQ5b.js} +1 -1
- package/dist/core/types.d.ts +85 -0
- package/dist/core/types.d.ts.map +1 -1
- package/dist/core/utilities/edges.d.ts +13 -2
- package/dist/core/utilities/edges.d.ts.map +1 -1
- package/dist/core/utilities/uvTransform.d.ts +20 -0
- package/dist/core/utilities/uvTransform.d.ts.map +1 -1
- package/dist/react/components/RectangularCoordinates.d.ts +31 -0
- package/dist/react/components/RectangularCoordinates.d.ts.map +1 -0
- package/dist/react/index.cjs +233 -233
- package/dist/react/index.d.ts +1 -0
- package/dist/react/index.d.ts.map +1 -1
- package/dist/react/index.js +16218 -15498
- package/dist/react/utils/generatePresetCode.cjs +2 -2
- package/dist/react/utils/generatePresetCode.d.ts.map +1 -1
- package/dist/react/utils/generatePresetCode.js +13 -1
- package/dist/registry.d.ts +3 -0
- package/dist/registry.js +376 -87
- package/dist/svelte/components/RectangularCoordinates.svelte.d.ts +19 -0
- package/dist/svelte/index.d.ts +1 -0
- package/dist/svelte/index.js +15766 -15088
- package/dist/svelte/utils/generatePresetCode.js +13 -1
- package/dist/vue/components/RectangularCoordinates.vue.d.ts +57 -0
- package/dist/vue/components/RectangularCoordinates.vue.d.ts.map +1 -0
- package/dist/vue/{generatePresetCode-B6Ks_W3s.js → generatePresetCode-D4V6rBae.js} +13 -1
- package/dist/vue/index.d.ts +1 -0
- package/dist/vue/index.d.ts.map +1 -1
- package/dist/vue/index.js +15240 -14552
- package/dist/vue/utils/generatePresetCode.d.ts.map +1 -1
- package/dist/vue/utils/generatePresetCode.js +1 -1
- package/package.json +6 -1
- package/dist/core/Blob-CBASKMfO.js +0 -168
- package/dist/core/Bulge-Ceythf-i.js +0 -99
- package/dist/core/DiffuseBlur-DLIKRsnf.js +0 -39
- package/dist/core/DotGrid-BkItF2C8.js +0 -60
- package/dist/core/FilmGrain-BAZORehh.js +0 -27
- package/dist/core/FloatingParticles-7wvOBUbD.js +0 -158
- package/dist/core/GlassTiles-C0y_PWTa.js +0 -48
- package/dist/core/Grid-Ro0Yi5WY.js +0 -49
- package/dist/core/GridDistortion-CuxRQdzs.js +0 -137
- package/dist/core/Group-DTXP-whY.js +0 -17
- package/dist/core/Invert-Cd7GK1vs.js +0 -20
- package/dist/core/Liquify-rmJGJAdt.js +0 -126
- package/dist/core/Pixelate-BIANS3t9.js +0 -34
- package/dist/core/Strands-Bv7RvyRC.js +0 -124
- package/dist/core/WaveDistortion-gecgVpvO.js +0 -129
- package/dist/core/edges-Cj8yVYgz.js +0 -10
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generatePresetCode.d.ts","sourceRoot":"","sources":["../../src/utils/generatePresetCode.ts"],"names":[],"mappings":"AAAA,UAAU,eAAe;IACvB,IAAI,EAAE,MAAM,CAAA;IACZ,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,QAAQ,CAAC,EAAE,eAAe,EAAE,CAAA;CAC7B;AAED,UAAU,YAAY;IACpB,UAAU,EAAE,eAAe,EAAE,CAAA;CAC9B;
|
|
1
|
+
{"version":3,"file":"generatePresetCode.d.ts","sourceRoot":"","sources":["../../src/utils/generatePresetCode.ts"],"names":[],"mappings":"AAAA,UAAU,eAAe;IACvB,IAAI,EAAE,MAAM,CAAA;IACZ,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,QAAQ,CAAC,EAAE,eAAe,EAAE,CAAA;CAC7B;AAED,UAAU,YAAY;IACpB,UAAU,EAAE,eAAe,EAAE,CAAA;CAC9B;AA+iBD,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,YAAY,GAAG,MAAM,CAyC/D;AAGD,eAAO,MAAM,mBAAmB,UAsD/B,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "shaders",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.2",
|
|
4
4
|
"description": "Declarative shader components for Vue, React, and Svelte",
|
|
5
5
|
"author": "Simon Le Marchant<https://github.com/marchantweb>",
|
|
6
6
|
"homepage": "https://shaders.com/",
|
|
@@ -314,6 +314,11 @@
|
|
|
314
314
|
"types": "./dist/core/shaders/ZoomBlur/index.d.ts",
|
|
315
315
|
"import": "./dist/core/shaders/ZoomBlur/index.js",
|
|
316
316
|
"require": "./dist/core/shaders/ZoomBlur/index.js"
|
|
317
|
+
},
|
|
318
|
+
"./core/RectangularCoordinates": {
|
|
319
|
+
"types": "./dist/core/shaders/RectangularCoordinates/index.d.ts",
|
|
320
|
+
"import": "./dist/core/shaders/RectangularCoordinates/index.js",
|
|
321
|
+
"require": "./dist/core/shaders/RectangularCoordinates/index.js"
|
|
317
322
|
}
|
|
318
323
|
},
|
|
319
324
|
"files": [
|
|
@@ -1,168 +0,0 @@
|
|
|
1
|
-
import { O as po, m as go } from "./three.tsl-CgyjOhns.js";
|
|
2
|
-
import { t as fo } from "./time-myrFQH-u.js";
|
|
3
|
-
import { i as bo, o as yo, r as p, t as xo } from "./transformations-Bs66Qh16.js";
|
|
4
|
-
import { t as Co } from "./colorMixing-C_ESXyqX.js";
|
|
5
|
-
go();
|
|
6
|
-
const vo = {
|
|
7
|
-
name: "Blob",
|
|
8
|
-
category: "Organic",
|
|
9
|
-
props: {
|
|
10
|
-
colorA: {
|
|
11
|
-
default: "#ff6b35",
|
|
12
|
-
transform: p,
|
|
13
|
-
description: "Primary color of the blob",
|
|
14
|
-
ui: {
|
|
15
|
-
type: "color",
|
|
16
|
-
label: "Color A"
|
|
17
|
-
}
|
|
18
|
-
},
|
|
19
|
-
colorB: {
|
|
20
|
-
default: "#e91e63",
|
|
21
|
-
transform: p,
|
|
22
|
-
description: "Secondary color of the blob",
|
|
23
|
-
ui: {
|
|
24
|
-
type: "color",
|
|
25
|
-
label: "Color B"
|
|
26
|
-
}
|
|
27
|
-
},
|
|
28
|
-
size: {
|
|
29
|
-
default: 0.5,
|
|
30
|
-
description: "Size of the blob",
|
|
31
|
-
ui: {
|
|
32
|
-
type: "range",
|
|
33
|
-
min: 0,
|
|
34
|
-
max: 1,
|
|
35
|
-
step: 0.01,
|
|
36
|
-
label: "Size"
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
deformation: {
|
|
40
|
-
default: 0.5,
|
|
41
|
-
description: "How organic and blobby the shape is (0 = circle, 1 = very blobby)",
|
|
42
|
-
ui: {
|
|
43
|
-
type: "range",
|
|
44
|
-
min: 0,
|
|
45
|
-
max: 1,
|
|
46
|
-
step: 0.01,
|
|
47
|
-
label: "Deformation"
|
|
48
|
-
}
|
|
49
|
-
},
|
|
50
|
-
softness: {
|
|
51
|
-
default: 0.5,
|
|
52
|
-
description: "Softness of the blob edges (combines edge width and transition curve)",
|
|
53
|
-
ui: {
|
|
54
|
-
type: "range",
|
|
55
|
-
min: 0,
|
|
56
|
-
max: 1,
|
|
57
|
-
step: 0.01,
|
|
58
|
-
label: "Softness"
|
|
59
|
-
}
|
|
60
|
-
},
|
|
61
|
-
highlightIntensity: {
|
|
62
|
-
default: 0.5,
|
|
63
|
-
description: "Intensity of specular highlight effect",
|
|
64
|
-
ui: {
|
|
65
|
-
type: "range",
|
|
66
|
-
min: 0,
|
|
67
|
-
max: 1,
|
|
68
|
-
step: 0.01,
|
|
69
|
-
label: "Highlight Intensity"
|
|
70
|
-
}
|
|
71
|
-
},
|
|
72
|
-
highlightX: {
|
|
73
|
-
default: 0.3,
|
|
74
|
-
description: "Light direction X component",
|
|
75
|
-
ui: {
|
|
76
|
-
type: "range",
|
|
77
|
-
min: -1,
|
|
78
|
-
max: 1,
|
|
79
|
-
step: 0.01,
|
|
80
|
-
label: "Highlight X"
|
|
81
|
-
}
|
|
82
|
-
},
|
|
83
|
-
highlightY: {
|
|
84
|
-
default: -0.3,
|
|
85
|
-
description: "Light direction Y component",
|
|
86
|
-
ui: {
|
|
87
|
-
type: "range",
|
|
88
|
-
min: -1,
|
|
89
|
-
max: 1,
|
|
90
|
-
step: 0.01,
|
|
91
|
-
label: "Highlight Y"
|
|
92
|
-
}
|
|
93
|
-
},
|
|
94
|
-
highlightZ: {
|
|
95
|
-
default: 0.4,
|
|
96
|
-
description: "Light direction Z component",
|
|
97
|
-
ui: {
|
|
98
|
-
type: "range",
|
|
99
|
-
min: -1,
|
|
100
|
-
max: 1,
|
|
101
|
-
step: 0.01,
|
|
102
|
-
label: "Highlight Z"
|
|
103
|
-
}
|
|
104
|
-
},
|
|
105
|
-
highlightColor: {
|
|
106
|
-
default: "#ffe11a",
|
|
107
|
-
transform: p,
|
|
108
|
-
description: "Color of the specular highlight",
|
|
109
|
-
ui: {
|
|
110
|
-
type: "color",
|
|
111
|
-
label: "Highlight Color"
|
|
112
|
-
}
|
|
113
|
-
},
|
|
114
|
-
speed: {
|
|
115
|
-
default: 0.5,
|
|
116
|
-
description: "Animation speed",
|
|
117
|
-
ui: {
|
|
118
|
-
type: "range",
|
|
119
|
-
min: 0,
|
|
120
|
-
max: 2,
|
|
121
|
-
step: 0.1,
|
|
122
|
-
label: "Speed"
|
|
123
|
-
}
|
|
124
|
-
},
|
|
125
|
-
seed: {
|
|
126
|
-
default: 1,
|
|
127
|
-
description: "Adjusts the starting state, useful for variation",
|
|
128
|
-
ui: {
|
|
129
|
-
type: "range",
|
|
130
|
-
min: 0,
|
|
131
|
-
max: 100,
|
|
132
|
-
step: 1,
|
|
133
|
-
label: "Seed"
|
|
134
|
-
}
|
|
135
|
-
},
|
|
136
|
-
center: {
|
|
137
|
-
default: {
|
|
138
|
-
x: 0.5,
|
|
139
|
-
y: 0.5
|
|
140
|
-
},
|
|
141
|
-
transform: yo,
|
|
142
|
-
description: "The center point of the blob",
|
|
143
|
-
ui: {
|
|
144
|
-
type: "position",
|
|
145
|
-
label: "Center Position"
|
|
146
|
-
}
|
|
147
|
-
},
|
|
148
|
-
colorSpace: {
|
|
149
|
-
default: "linear",
|
|
150
|
-
transform: bo,
|
|
151
|
-
description: "Color space for color interpolation",
|
|
152
|
-
ui: {
|
|
153
|
-
type: "select",
|
|
154
|
-
options: xo,
|
|
155
|
-
label: "Color Space"
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
},
|
|
159
|
-
fragmentNode: (g) => {
|
|
160
|
-
const { uniforms: i } = g, { vec2: f, vec3: c, vec4: X, float: o, screenUV: b, smoothstep: s, sin: e, length: y, viewportSize: x, pow: C, max: Y, normalize: v, dot: Z, reflect: D } = po, l = fo(g, i.speed, i.seed), S = i.colorA.uniform, A = i.colorB.uniform, I = i.size.uniform, m = i.deformation.uniform, B = i.softness.uniform, N = i.highlightIntensity.uniform, P = i.highlightX.uniform, _ = i.highlightY.uniform, R = i.highlightZ.uniform, T = i.highlightColor.uniform, z = B.mul(o(0.3)), L = B.mul(o(2)).add(o(0.5)), u = o(0.5), H = x.x.div(x.y), O = f(b.x.mul(H), b.y), k = f(i.center.uniform.x.mul(H), i.center.uniform.y.oneMinus()), t = O.sub(k), M = y(t), U = I, n = o(4), V = e(t.x.mul(n.mul(o(0.8))).add(l.mul(o(0.8)))).mul(e(t.y.mul(n.mul(o(0.7))).add(l.mul(o(0.6))))).add(e(t.x.mul(n.mul(o(1.2))).sub(t.y.mul(n.mul(o(0.9))).add(l.mul(o(0.4)))))).mul(o(0.15)).mul(m), j = e(t.x.mul(n.mul(o(1.4))).sub(l.mul(o(0.5)))).mul(e(t.y.mul(n.mul(o(1.1))).add(l.mul(o(0.7))))).mul(o(0.12)).mul(m).mul(s(o(0.15), o(0.25), u)), F = e(t.x.mul(n.mul(o(1.8))).add(t.y.mul(n.mul(o(1.6))).add(l.mul(o(0.3))))).add(e(t.x.mul(n.mul(o(0.6))).sub(l.mul(o(0.9))))).mul(o(0.1)).mul(m).mul(s(o(0.3), o(0.4), u)), G = e(t.x.mul(n.mul(o(2.2))).add(l.mul(o(0.2)))).mul(e(t.y.mul(n.mul(o(1.9))).sub(l.mul(o(0.8))))).mul(o(0.08)).mul(m).mul(s(o(0.45), o(0.55), u)), W = e(t.x.mul(n.mul(o(2.8))).sub(t.y.mul(n.mul(o(2.4))).add(l.mul(o(0.6))))).mul(o(0.06)).mul(m).mul(s(o(0.6), o(0.7), u)), q = e(t.x.mul(n.mul(o(3.2))).add(l.mul(o(1.1)))).add(e(t.y.mul(n.mul(o(3.5))).sub(l.mul(o(0.4))))).mul(o(0.04)).mul(m).mul(s(o(0.75), o(0.85), u)), E = V.add(j).add(F).add(G).add(W).add(q), h = U.add(E), w = C(s(h.add(z), h.sub(z), M), L), J = y(t), K = h, a = s(o(0), K, J), Q = o(1).sub(a.mul(o(0.1))), $ = v(c(t.x.mul(a.add(o(0.2))), t.y.mul(a.add(o(0.2))), Q)), oo = v(c(P, _, R)), to = c(o(0), o(0), o(1)), eo = D(oo.negate(), $), lo = o(32), io = C(Y(o(0), Z(eo, to)), lo), no = a.mul(o(0.5)).add(o(0.5)), so = io.mul(no).mul(N).mul(w), r = t.x.mul(o(3)), d = t.y.mul(o(3)), mo = e(r.add(l.mul(o(0.4)))).mul(e(d.add(l.mul(o(0.3))))).add(e(r.mul(o(0.7)).add(d.mul(o(0.8))).add(l.mul(o(0.2))))).mul(o(0.5)).add(o(0.5)), uo = e(r.mul(o(1.3)).sub(l.mul(o(0.5)))).mul(e(d.mul(o(1.1)).add(l.mul(o(0.6))))).add(e(r.mul(o(0.5)).sub(d.mul(o(0.6)).sub(l.mul(o(0.3)))))).mul(o(0.5)).add(o(0.5)), ao = mo.mul(o(0.6)).add(uo.mul(o(0.4))), ro = Co(S, A, s(o(0.1), o(0.9), ao), i.colorSpace.uniform).rgb, co = S.a.add(A.a).div(o(2)), ho = T.rgb.mul(so);
|
|
161
|
-
return X(ro.add(ho), co.mul(w));
|
|
162
|
-
}
|
|
163
|
-
};
|
|
164
|
-
var Ho = vo;
|
|
165
|
-
export {
|
|
166
|
-
vo as n,
|
|
167
|
-
Ho as t
|
|
168
|
-
};
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import { O as U, d as t, h as V, m as E } from "./three.tsl-CgyjOhns.js";
|
|
2
|
-
import { t as M } from "./edges-Cj8yVYgz.js";
|
|
3
|
-
import { a as R, o as z } from "./transformations-Bs66Qh16.js";
|
|
4
|
-
E();
|
|
5
|
-
const A = {
|
|
6
|
-
name: "Bulge",
|
|
7
|
-
category: "Distortions",
|
|
8
|
-
requiresRTT: !0,
|
|
9
|
-
requiresChild: !0,
|
|
10
|
-
props: {
|
|
11
|
-
center: {
|
|
12
|
-
default: {
|
|
13
|
-
x: 0.5,
|
|
14
|
-
y: 0.5
|
|
15
|
-
},
|
|
16
|
-
transform: z,
|
|
17
|
-
description: "The center point of the bulge effect",
|
|
18
|
-
ui: {
|
|
19
|
-
type: "position",
|
|
20
|
-
label: "Center"
|
|
21
|
-
}
|
|
22
|
-
},
|
|
23
|
-
strength: {
|
|
24
|
-
default: 1,
|
|
25
|
-
description: "The intensity of the bulge effect (positive = bulge out, negative = pinch in)",
|
|
26
|
-
ui: {
|
|
27
|
-
type: "range",
|
|
28
|
-
min: -1,
|
|
29
|
-
max: 1,
|
|
30
|
-
step: 0.01,
|
|
31
|
-
label: "Strength"
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
radius: {
|
|
35
|
-
default: 1,
|
|
36
|
-
description: "The radius of the bulge effect area",
|
|
37
|
-
ui: {
|
|
38
|
-
type: "range",
|
|
39
|
-
min: 0,
|
|
40
|
-
max: 5,
|
|
41
|
-
step: 0.01,
|
|
42
|
-
label: "Radius"
|
|
43
|
-
}
|
|
44
|
-
},
|
|
45
|
-
falloff: {
|
|
46
|
-
default: 0.5,
|
|
47
|
-
description: "Controls the smoothness of the transition (0 = hard edge, 1 = very smooth)",
|
|
48
|
-
ui: {
|
|
49
|
-
type: "range",
|
|
50
|
-
min: 0,
|
|
51
|
-
max: 1,
|
|
52
|
-
step: 0.01,
|
|
53
|
-
label: "Falloff"
|
|
54
|
-
}
|
|
55
|
-
},
|
|
56
|
-
edges: {
|
|
57
|
-
default: "stretch",
|
|
58
|
-
description: "How to handle edges when distortion pushes content out of bounds",
|
|
59
|
-
transform: R,
|
|
60
|
-
ui: {
|
|
61
|
-
type: "select",
|
|
62
|
-
options: [
|
|
63
|
-
{
|
|
64
|
-
label: "Stretch",
|
|
65
|
-
value: "stretch"
|
|
66
|
-
},
|
|
67
|
-
{
|
|
68
|
-
label: "Transparent",
|
|
69
|
-
value: "transparent"
|
|
70
|
-
},
|
|
71
|
-
{
|
|
72
|
-
label: "Mirror",
|
|
73
|
-
value: "mirror"
|
|
74
|
-
},
|
|
75
|
-
{
|
|
76
|
-
label: "Wrap",
|
|
77
|
-
value: "wrap"
|
|
78
|
-
}
|
|
79
|
-
],
|
|
80
|
-
label: "Edges"
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
},
|
|
84
|
-
fragmentNode: ({ uniforms: e, childNode: a, onCleanup: g }) => {
|
|
85
|
-
const { vec2: s, vec4: h, length: b, screenUV: i, viewportSize: l, convertToTexture: v, smoothstep: x } = U;
|
|
86
|
-
if (!a) return h(0, 0, 0, 0);
|
|
87
|
-
const o = v(a);
|
|
88
|
-
g(() => {
|
|
89
|
-
o?.renderTarget?.dispose && o.renderTarget.dispose();
|
|
90
|
-
});
|
|
91
|
-
const n = l.x.div(l.y), y = s(i.x.mul(n), i.y), u = s(e.center.uniform.x.mul(n), e.center.uniform.y.oneMinus()), c = y.sub(u), f = b(c), r = e.radius.uniform.mul(0.5), T = e.falloff.uniform, _ = x(r.mul(t(1).sub(T).sub(t(1e-3)).max(t(0))), r, f).oneMinus(), d = f.div(r), q = d.mul(d), w = V(t(0), t(1).sub(q)), C = _.mul(w), D = e.strength.uniform.negate().mul(C), F = t(1).add(D), S = c.mul(F), m = u.add(S), p = s(m.x.div(n), m.y);
|
|
92
|
-
return M(p, o.sample(p), o, e.edges.uniform);
|
|
93
|
-
}
|
|
94
|
-
};
|
|
95
|
-
var O = A;
|
|
96
|
-
export {
|
|
97
|
-
A as n,
|
|
98
|
-
O as t
|
|
99
|
-
};
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { O as R, m as V } from "./three.tsl-CgyjOhns.js";
|
|
2
|
-
V();
|
|
3
|
-
const w = {
|
|
4
|
-
name: "DiffuseBlur",
|
|
5
|
-
category: "Blurs",
|
|
6
|
-
requiresRTT: !0,
|
|
7
|
-
requiresChild: !0,
|
|
8
|
-
props: { intensity: {
|
|
9
|
-
default: 30,
|
|
10
|
-
description: "Intensity of the diffuse blur effect",
|
|
11
|
-
ui: {
|
|
12
|
-
type: "range",
|
|
13
|
-
min: 0,
|
|
14
|
-
max: 100,
|
|
15
|
-
step: 1,
|
|
16
|
-
label: "Intensity"
|
|
17
|
-
}
|
|
18
|
-
} },
|
|
19
|
-
fragmentNode: ({ uniforms: p, childNode: o, onCleanup: v }) => {
|
|
20
|
-
const { vec2: t, vec4: i, float: s, screenUV: x, convertToTexture: g, viewportSize: T, fract: h, sin: u, cos: y, dot: _, Fn: b } = R;
|
|
21
|
-
if (!o) return i(0, 0, 0, 0);
|
|
22
|
-
const n = g(o);
|
|
23
|
-
return v(() => {
|
|
24
|
-
n?.renderTarget?.dispose && n.renderTarget.dispose();
|
|
25
|
-
}), b(() => {
|
|
26
|
-
const a = x, q = p.intensity.uniform.mul(1), B = t(1).div(T), l = (e) => h(u(_(e, t(12.9898, 78.233).mul(2))).mul(43758.5453)), r = i(0).toVar(), c = 16;
|
|
27
|
-
for (let e = 0; e < c; e++) {
|
|
28
|
-
const d = a.mul(1e3).add(t(s(e * 11.7), s(e * 5.3))), C = l(d), D = l(d.add(t(73.2, 41.9))), f = C.mul(6.28318530718), m = D.sqrt().mul(q), S = t(y(f).mul(m), u(f).mul(m)).mul(B.x), z = a.add(S), I = n.sample(z);
|
|
29
|
-
r.assign(r.add(I));
|
|
30
|
-
}
|
|
31
|
-
return r.div(s(c));
|
|
32
|
-
})();
|
|
33
|
-
}
|
|
34
|
-
};
|
|
35
|
-
var O = w;
|
|
36
|
-
export {
|
|
37
|
-
w as n,
|
|
38
|
-
O as t
|
|
39
|
-
};
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { O as V, f as M, m as U } from "./three.tsl-CgyjOhns.js";
|
|
2
|
-
import { r as G } from "./transformations-Bs66Qh16.js";
|
|
3
|
-
U();
|
|
4
|
-
const I = {
|
|
5
|
-
name: "DotGrid",
|
|
6
|
-
category: "Shapes & Masks",
|
|
7
|
-
props: {
|
|
8
|
-
color: {
|
|
9
|
-
default: "#ffffff",
|
|
10
|
-
description: "The color of the dot",
|
|
11
|
-
transform: G,
|
|
12
|
-
ui: {
|
|
13
|
-
type: "color",
|
|
14
|
-
label: "Color"
|
|
15
|
-
}
|
|
16
|
-
},
|
|
17
|
-
density: {
|
|
18
|
-
default: 100,
|
|
19
|
-
description: "The number of dots on the longest canvas edge",
|
|
20
|
-
ui: {
|
|
21
|
-
type: "range",
|
|
22
|
-
min: 10,
|
|
23
|
-
max: 500,
|
|
24
|
-
step: 10,
|
|
25
|
-
label: "Density"
|
|
26
|
-
}
|
|
27
|
-
},
|
|
28
|
-
dotSize: {
|
|
29
|
-
default: 0.3,
|
|
30
|
-
description: "The size of each dot, zero (0) being invisible, one (1) filled the grid with no gaps",
|
|
31
|
-
ui: {
|
|
32
|
-
type: "range",
|
|
33
|
-
min: 0,
|
|
34
|
-
max: 1,
|
|
35
|
-
step: 0.01,
|
|
36
|
-
label: "Dot Size"
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
twinkle: {
|
|
40
|
-
default: 0,
|
|
41
|
-
description: "Intensity of the twinkle effect (0 = off, 1 = full twinkle)",
|
|
42
|
-
ui: {
|
|
43
|
-
type: "range",
|
|
44
|
-
min: 0,
|
|
45
|
-
max: 1,
|
|
46
|
-
step: 0.01,
|
|
47
|
-
label: "Twinkle"
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
},
|
|
51
|
-
fragmentNode: ({ uniforms: t }) => {
|
|
52
|
-
const { screenUV: f, vec4: m, vec2: u, smoothstep: p, length: o, floor: n, float: i, viewportSize: h, time: g, sin: y, mix: w } = V, s = f, l = t.density.uniform, r = t.dotSize.uniform, b = t.color.uniform, k = t.twinkle.uniform, a = h, x = a.x.div(a.y), d = u(s.x.mul(x), s.y.oneMinus()), e = d.mul(l), v = o(e.sub(n(e)).sub(0.5)), z = o(M(d.mul(l))), S = i(1).sub(p(r.mul(0.5), r.mul(0.5).add(z.mul(0.5)), v)), c = n(e), D = c.x.mul(12.9898).add(c.y.mul(78.233)).sin().mul(43758.5453).fract(), _ = y(g.mul(2).add(D.mul(6.28318))).mul(0.5).add(0.5), C = w(i(1), _, k), T = S.mul(C);
|
|
53
|
-
return m(b.rgb, T);
|
|
54
|
-
}
|
|
55
|
-
};
|
|
56
|
-
var N = I;
|
|
57
|
-
export {
|
|
58
|
-
I as n,
|
|
59
|
-
N as t
|
|
60
|
-
};
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { O as f, m as g } from "./three.tsl-CgyjOhns.js";
|
|
2
|
-
g();
|
|
3
|
-
const p = {
|
|
4
|
-
name: "FilmGrain",
|
|
5
|
-
category: "Effects",
|
|
6
|
-
requiresChild: !0,
|
|
7
|
-
props: { strength: {
|
|
8
|
-
default: 0.5,
|
|
9
|
-
description: "Intensity of the film grain noise",
|
|
10
|
-
ui: {
|
|
11
|
-
type: "range",
|
|
12
|
-
min: 0,
|
|
13
|
-
max: 1,
|
|
14
|
-
step: 0.01,
|
|
15
|
-
label: "Strength"
|
|
16
|
-
}
|
|
17
|
-
} },
|
|
18
|
-
fragmentNode: ({ uniforms: r, childNode: s }) => {
|
|
19
|
-
const { vec2: i, vec4: e, float: t, screenUV: o, sin: a, dot: l, fract: m } = f, c = r.strength.uniform, n = s || e(0, 0, 0, 0), u = m(a(l(o, i(t(12.9898), t(78.233)).mul(t(2)))).mul(t(43758.5453))).mul(t(2)).sub(t(1)).mul(c.mul(t(0.1)));
|
|
20
|
-
return e(n.rgb.add(u), n.a);
|
|
21
|
-
}
|
|
22
|
-
};
|
|
23
|
-
var h = p;
|
|
24
|
-
export {
|
|
25
|
-
p as n,
|
|
26
|
-
h as t
|
|
27
|
-
};
|
|
@@ -1,158 +0,0 @@
|
|
|
1
|
-
import { O as Z, m as $ } from "./three.tsl-CgyjOhns.js";
|
|
2
|
-
import { r as ee } from "./transformations-Bs66Qh16.js";
|
|
3
|
-
$();
|
|
4
|
-
const te = {
|
|
5
|
-
name: "FloatingParticles",
|
|
6
|
-
category: "Effects",
|
|
7
|
-
requiresRTT: !1,
|
|
8
|
-
props: {
|
|
9
|
-
randomness: {
|
|
10
|
-
default: 0.25,
|
|
11
|
-
description: "Randomness of particle animation",
|
|
12
|
-
ui: {
|
|
13
|
-
type: "range",
|
|
14
|
-
min: 0,
|
|
15
|
-
max: 1,
|
|
16
|
-
step: 0.01,
|
|
17
|
-
label: "Randomness"
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
|
-
speed: {
|
|
21
|
-
default: 0.25,
|
|
22
|
-
description: "Speed of particle movement",
|
|
23
|
-
ui: {
|
|
24
|
-
type: "range",
|
|
25
|
-
min: 0,
|
|
26
|
-
max: 1,
|
|
27
|
-
step: 0.01,
|
|
28
|
-
label: "Speed"
|
|
29
|
-
}
|
|
30
|
-
},
|
|
31
|
-
angle: {
|
|
32
|
-
default: 90,
|
|
33
|
-
description: "Movement angle in degrees (0=right, 90=down, 180=left, 270=up)",
|
|
34
|
-
ui: {
|
|
35
|
-
type: "range",
|
|
36
|
-
min: 0,
|
|
37
|
-
max: 360,
|
|
38
|
-
step: 1,
|
|
39
|
-
label: "Angle"
|
|
40
|
-
}
|
|
41
|
-
},
|
|
42
|
-
particleSize: {
|
|
43
|
-
default: 1,
|
|
44
|
-
description: "Size of particles",
|
|
45
|
-
ui: {
|
|
46
|
-
type: "range",
|
|
47
|
-
min: 0.1,
|
|
48
|
-
max: 20,
|
|
49
|
-
step: 0.1,
|
|
50
|
-
label: "Particle Size"
|
|
51
|
-
}
|
|
52
|
-
},
|
|
53
|
-
particleSoftness: {
|
|
54
|
-
default: 0,
|
|
55
|
-
description: "Edge softness of particles (0 = sharp, 1 = very soft)",
|
|
56
|
-
ui: {
|
|
57
|
-
type: "range",
|
|
58
|
-
min: 0,
|
|
59
|
-
max: 5,
|
|
60
|
-
step: 0.01,
|
|
61
|
-
label: "Particle Softness"
|
|
62
|
-
}
|
|
63
|
-
},
|
|
64
|
-
twinkle: {
|
|
65
|
-
default: 0.5,
|
|
66
|
-
description: "Intensity of the twinkle effect (0 = off, 1 = full twinkle)",
|
|
67
|
-
ui: {
|
|
68
|
-
type: "range",
|
|
69
|
-
min: 0,
|
|
70
|
-
max: 1,
|
|
71
|
-
step: 0.01,
|
|
72
|
-
label: "Twinkle"
|
|
73
|
-
}
|
|
74
|
-
},
|
|
75
|
-
count: {
|
|
76
|
-
default: 5,
|
|
77
|
-
description: "Number of particle layers",
|
|
78
|
-
ui: {
|
|
79
|
-
type: "range",
|
|
80
|
-
min: 1,
|
|
81
|
-
max: 5,
|
|
82
|
-
step: 1,
|
|
83
|
-
label: "Count"
|
|
84
|
-
}
|
|
85
|
-
},
|
|
86
|
-
particleColor: {
|
|
87
|
-
default: "#ffffff",
|
|
88
|
-
transform: ee,
|
|
89
|
-
description: "Color of the particles",
|
|
90
|
-
ui: {
|
|
91
|
-
type: "color",
|
|
92
|
-
label: "Particle Color"
|
|
93
|
-
}
|
|
94
|
-
},
|
|
95
|
-
speedVariance: {
|
|
96
|
-
default: 0.3,
|
|
97
|
-
description: "Per-layer speed variance (0 = all layers same speed, 1 = high variance)",
|
|
98
|
-
ui: {
|
|
99
|
-
type: "range",
|
|
100
|
-
min: 0,
|
|
101
|
-
max: 1,
|
|
102
|
-
step: 0.01,
|
|
103
|
-
label: "Speed Variance"
|
|
104
|
-
}
|
|
105
|
-
},
|
|
106
|
-
angleVariance: {
|
|
107
|
-
default: 30,
|
|
108
|
-
description: "Per-layer angle variance in degrees (0 = all layers same angle, 180 = full variance)",
|
|
109
|
-
ui: {
|
|
110
|
-
type: "range",
|
|
111
|
-
min: 0,
|
|
112
|
-
max: 180,
|
|
113
|
-
step: 1,
|
|
114
|
-
label: "Angle Variance"
|
|
115
|
-
}
|
|
116
|
-
},
|
|
117
|
-
particleDensity: {
|
|
118
|
-
default: 3,
|
|
119
|
-
description: "Particle density (lower = more spread out, higher = more dense)",
|
|
120
|
-
ui: {
|
|
121
|
-
type: "range",
|
|
122
|
-
min: 0.5,
|
|
123
|
-
max: 3,
|
|
124
|
-
step: 0.1,
|
|
125
|
-
label: "Particle Density"
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
|
-
},
|
|
129
|
-
fragmentNode: ({ uniforms: l, childNode: F }) => {
|
|
130
|
-
const { vec2: n, vec3: I, vec4: U, float: o, sin: u, cos: P, smoothstep: H, mix: B, min: h, floor: O, fract: V, length: E, dot: T, screenUV: j, viewportSize: L, time: b, Fn: d } = Z, G = d(([e]) => V(u(T(e, n(127.1, 311.7))).mul(43758.5453123))), N = d(([e]) => V(u(n(T(e, n(127.1, 311.7)), T(e, n(269.5, 183.3)))).mul(43758.5453))), J = d(([e, a]) => {
|
|
131
|
-
const s = N(e).sub(0.5), t = u(a), r = P(a);
|
|
132
|
-
return n(r.mul(s.x).sub(t.mul(s.y)).mul(0.66), t.mul(s.x).add(r.mul(s.y)).mul(0.66)).add(e).add(0.5);
|
|
133
|
-
}), K = d(([e]) => b.mul(l.randomness.uniform).mul(G(e).sub(0.5)).mul(2)), f = d(([e, a]) => {
|
|
134
|
-
const s = J(a, K(a));
|
|
135
|
-
return E(e.sub(s));
|
|
136
|
-
}), Q = d(([e]) => {
|
|
137
|
-
const a = O(e), s = V(e);
|
|
138
|
-
let t = f(e, a);
|
|
139
|
-
const r = l.particleSoftness.uniform, m = l.particleSize.uniform.mul(0.01), i = m.mul(0.6).add(r.mul(m.mul(2.4))), c = i.greaterThan(0.35), g = s.x.lessThan(0.4), x = s.x.greaterThan(0.6), w = s.y.lessThan(0.4), R = s.y.greaterThan(0.6), z = c.and(g), p = c.and(x), D = c.and(w), y = c.and(R);
|
|
140
|
-
t = z.select(h(t, f(e, a.add(n(-1, 0)))), t), t = p.select(h(t, f(e, a.add(n(1, 0)))), t), t = D.select(h(t, f(e, a.add(n(0, -1)))), t), t = y.select(h(t, f(e, a.add(n(0, 1)))), t);
|
|
141
|
-
const M = H(i, m.mul(0.6), t), _ = l.twinkle.uniform, v = a.x.mul(12.9898).add(a.y.mul(78.233)).sin().mul(43758.5453).fract(), C = u(b.mul(2).add(v.mul(6.28318))).mul(0.5).add(0.5), A = B(o(1), C, _);
|
|
142
|
-
return M.mul(A).mul(l.particleColor.uniform.rgb);
|
|
143
|
-
}), W = d(([e]) => {
|
|
144
|
-
const a = o(1.05), s = o(0.9), t = l.count.uniform, r = I(0).toVar(), m = o(1).toVar(), i = o(1).toVar(), c = n(0).toVar(), g = l.angle.uniform.mul(3.14159).div(180), x = n(P(g), u(g)), w = b.mul(x).mul(l.speed.uniform), R = l.speedVariance.uniform, z = l.angleVariance.uniform.mul(3.14159).div(180);
|
|
145
|
-
for (let p = 0; p < 4; p++) {
|
|
146
|
-
const D = o(p).lessThan(t).and(i.greaterThan(0.02)), y = N(n(i, o(p).mul(7.919))), M = o(1).add(y.x.sub(0.5).mul(R)), _ = y.y.sub(0.5).mul(z).mul(2), v = g.add(_), C = n(P(v), u(v)), A = w.mul(M).add(C.sub(x).mul(b).mul(l.speed.uniform)), Y = Q(e.mul(m).add(A).add(c)).mul(i);
|
|
147
|
-
r.assign(r.add(D.select(Y, I(0)))), c.assign(c.add(y.mul(10))), i.assign(i.mul(s)), m.assign(m.mul(a));
|
|
148
|
-
}
|
|
149
|
-
return r;
|
|
150
|
-
}), q = j.mul(2).sub(1), X = L.x.div(L.y), k = W(n(q.x.mul(X), q.y).mul(l.particleDensity.uniform)), S = E(k);
|
|
151
|
-
return F ? U(B(F.xyz, k, S.greaterThan(0.01).select(S, 0)), 1) : U(k, S);
|
|
152
|
-
}
|
|
153
|
-
};
|
|
154
|
-
var se = te;
|
|
155
|
-
export {
|
|
156
|
-
te as n,
|
|
157
|
-
se as t
|
|
158
|
-
};
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import { O as q, m as G } from "./three.tsl-CgyjOhns.js";
|
|
2
|
-
G();
|
|
3
|
-
const V = {
|
|
4
|
-
name: "GlassTiles",
|
|
5
|
-
category: "Distortions",
|
|
6
|
-
requiresRTT: !0,
|
|
7
|
-
requiresChild: !0,
|
|
8
|
-
props: {
|
|
9
|
-
intensity: {
|
|
10
|
-
default: 1,
|
|
11
|
-
description: "The intensity of the glass tiles effect",
|
|
12
|
-
ui: {
|
|
13
|
-
type: "range",
|
|
14
|
-
min: 0,
|
|
15
|
-
max: 5,
|
|
16
|
-
step: 0.1,
|
|
17
|
-
label: "Intensity"
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
|
-
tileCount: {
|
|
21
|
-
default: 100,
|
|
22
|
-
description: "Number of tiles across the shortest dimension",
|
|
23
|
-
ui: {
|
|
24
|
-
type: "range",
|
|
25
|
-
min: 1,
|
|
26
|
-
max: 200,
|
|
27
|
-
step: 1,
|
|
28
|
-
label: "Tile Count"
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
},
|
|
32
|
-
fragmentNode: ({ uniforms: a, childNode: l, dimensions: c, onCleanup: T }) => {
|
|
33
|
-
const { vec2: o, vec4: u, floor: g, mul: e, div: t, sub: d, add: m, screenUV: y, uniform: C, convertToTexture: v } = q;
|
|
34
|
-
if (!l)
|
|
35
|
-
return console.error("You must pass a child component into the Glass Tiles shader."), u(0);
|
|
36
|
-
const i = v(l);
|
|
37
|
-
T(() => {
|
|
38
|
-
i?.renderTarget?.dispose && i.renderTarget.dispose();
|
|
39
|
-
});
|
|
40
|
-
const s = C(c.width / c.height), p = y, x = a.intensity.uniform, n = a.tileCount.uniform, r = o(s.greaterThanEqual(1).select(e(n, s), n), s.lessThan(1).select(t(n, s), n)), f = t(g(e(p, r)), r), h = d(p, f), b = o(0.5, 0.5), _ = e(x, 0.025), U = m(m(h, e(d(t(h, t(o(1), r)), b), _)), f);
|
|
41
|
-
return u(i.sample(U));
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
var N = V;
|
|
45
|
-
export {
|
|
46
|
-
V as n,
|
|
47
|
-
N as t
|
|
48
|
-
};
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { O as k, m as v } from "./three.tsl-CgyjOhns.js";
|
|
2
|
-
import { r as b } from "./transformations-Bs66Qh16.js";
|
|
3
|
-
v();
|
|
4
|
-
const M = {
|
|
5
|
-
name: "Grid",
|
|
6
|
-
category: "Shapes & Masks",
|
|
7
|
-
props: {
|
|
8
|
-
color: {
|
|
9
|
-
default: "#ffffff",
|
|
10
|
-
transform: b,
|
|
11
|
-
description: "The color of the grid lines",
|
|
12
|
-
ui: {
|
|
13
|
-
type: "color",
|
|
14
|
-
label: "Color"
|
|
15
|
-
}
|
|
16
|
-
},
|
|
17
|
-
cells: {
|
|
18
|
-
default: 10,
|
|
19
|
-
description: "Number of cells along the shortest canvas edge (creates square cells)",
|
|
20
|
-
ui: {
|
|
21
|
-
type: "range",
|
|
22
|
-
min: 1,
|
|
23
|
-
max: 50,
|
|
24
|
-
step: 1,
|
|
25
|
-
label: "Cells"
|
|
26
|
-
}
|
|
27
|
-
},
|
|
28
|
-
thickness: {
|
|
29
|
-
default: 1,
|
|
30
|
-
description: "Thickness of grid lines (normalized, 0.0-1.0)",
|
|
31
|
-
ui: {
|
|
32
|
-
type: "range",
|
|
33
|
-
min: 0,
|
|
34
|
-
max: 5,
|
|
35
|
-
step: 0.1,
|
|
36
|
-
label: "Thickness"
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
},
|
|
40
|
-
fragmentNode: ({ uniforms: e }) => {
|
|
41
|
-
const { vec2: l, vec4: a, fract: d, max: m, screenUV: t, viewportSize: n, fwidth: f, smoothstep: r } = k, p = n.x.div(n.y), u = l(t.x.mul(p), t.y.oneMinus()), h = e.cells.uniform, i = u.mul(h), o = d(i), s = e.thickness.uniform.mul(0.01), g = o.x.min(o.x.oneMinus()), x = o.y.min(o.y.oneMinus()), c = f(i), y = m(r(s.add(c.x), s, g), r(s.add(c.y), s, x));
|
|
42
|
-
return a(e.color.uniform.rgb, e.color.uniform.a.mul(y));
|
|
43
|
-
}
|
|
44
|
-
};
|
|
45
|
-
var z = M;
|
|
46
|
-
export {
|
|
47
|
-
M as n,
|
|
48
|
-
z as t
|
|
49
|
-
};
|