shaders 3.0.443 → 3.0.445
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/cli.js +2 -2
- package/dist/core/{AngularBlur-CJsRS1Ri.js → AngularBlur-D33jrcZd.js} +2 -2
- package/dist/core/{Arc-CNesL3S9.js → Arc-BG8Bpknl.js} +2 -2
- package/dist/core/{Ascii-z7til0PQ.js → Ascii-DE0vAAOX.js} +2 -2
- package/dist/core/{Aurora-BAuYUYGc.js → Aurora-Cu4JGjCD.js} +3 -3
- package/dist/core/{BarShift-qVwbTMcq.js → BarShift-o_IvV0t_.js} +5 -5
- package/dist/core/{BarnDoors-DrOAeSqj.js → BarnDoors-JraHuTwe.js} +2 -2
- package/dist/core/{Beam-BW6yblZw.js → Beam-DshQatlM.js} +2 -2
- package/dist/core/{Bend-B7PMQ3T5.js → Bend-KJzYWEJV.js} +4 -4
- package/dist/core/{Blob-CRJ5N0hK.js → Blob-BJxkqvOO.js} +3 -3
- package/dist/core/{BlockDissolve-D-6Wy66g.js → BlockDissolve-CsIQWUpY.js} +2 -2
- package/dist/core/{BlockNoise-Ct9Fae_7.js → BlockNoise-DVI-0PnC.js} +3 -3
- package/dist/core/{BlueNoise-Cu7rJuP0.js → BlueNoise-CzBN6i38.js} +2 -2
- package/dist/core/{Blur-BrdVVSPq.js → Blur-W95k4Lxz.js} +1 -1
- package/dist/core/{Boids-DIzUaLGM.js → Boids-BJ6wxFC8.js} +2 -2
- package/dist/core/{BokehBlur-yYb03spN.js → BokehBlur-CbOO__cN.js} +2 -2
- package/dist/core/{BrickPattern-BL_MOS_A.js → BrickPattern-eQv5DrKE.js} +3 -3
- package/dist/core/{BrightnessContrast-CiKimIcA.js → BrightnessContrast-CmH2DvaZ.js} +1 -1
- package/dist/core/{BrushedMetal-dvYjizvg.js → BrushedMetal-D-7M7ZuM.js} +5 -5
- package/dist/core/{Bulge-CogpoPKe.js → Bulge-KmBnaVMx.js} +4 -4
- package/dist/core/{CRTScreen-X64EnHMB.js → CRTScreen-t7dyfO5u.js} +1 -1
- package/dist/core/{CarbonFiber-CTy3P-Qk.js → CarbonFiber-D4jap49E.js} +4 -4
- package/dist/core/{Chalkboard-CnHUOHtc.js → Chalkboard-H6-0OXC3.js} +2 -2
- package/dist/core/{ChannelBlur-MwnpNLSZ.js → ChannelBlur-BKJfnu91.js} +1 -1
- package/dist/core/{CheckerWipe-CCNc70ye.js → CheckerWipe-acIaflfK.js} +2 -2
- package/dist/core/{Checkerboard-C97ZiLyQ.js → Checkerboard-NwKMLVHe.js} +2 -2
- package/dist/core/{Chevron-ABT6D1wM.js → Chevron-eBbFV2ud.js} +3 -3
- package/dist/core/{ChromaFlow-7tJQEFm9.js → ChromaFlow-ex7l4tTK.js} +2 -2
- package/dist/core/{ChromaticAberration-D7-fxyEd.js → ChromaticAberration-Bbi9vNxS.js} +2 -2
- package/dist/core/{Circle-I0DIAypS.js → Circle-DdFWEti1.js} +2 -2
- package/dist/core/{ColorWheel-CEqzzrN-.js → ColorWheel-BqcyPqcj.js} +3 -3
- package/dist/core/{CompressionArtifacts-C24nRoC3.js → CompressionArtifacts-DqWq-4h8.js} +1 -1
- package/dist/core/{ConcentricSpin-CAu-PGNH.js → ConcentricSpin-CtI1hKio.js} +5 -5
- package/dist/core/{ConicGradient-n12K5TLj.js → ConicGradient-HmImN4LO.js} +3 -3
- package/dist/core/{ContourLines-FOStIWDr.js → ContourLines-BMom2vMu.js} +2 -2
- package/dist/core/{CornerPin-DsUVMFcX.js → CornerPin-D_-luriU.js} +3 -3
- package/dist/core/{Crescent-9i_5WPA-.js → Crescent-CY6MeN9V.js} +2 -2
- package/dist/core/{Cross-HiA69xGL.js → Cross-ClImej9a.js} +2 -2
- package/dist/core/{Crystal-BBjEm9m4.js → Crystal-CMrqHLFD.js} +4 -4
- package/dist/core/{CurlNoise-1jifziI0.js → CurlNoise-C_QZBT5m.js} +3 -3
- package/dist/core/{CursorRipples-D4agAYHK.js → CursorRipples-Bmlex_IF.js} +2 -2
- package/dist/core/{CursorTrail-C-FrY0e2.js → CursorTrail-B68x1Cv-.js} +3 -3
- package/dist/core/{DataMosh-DXcM1I4Y.js → DataMosh-FZQWg5Ui.js} +1 -1
- package/dist/core/{DiamondGradient-CQ5jeKEc.js → DiamondGradient-C0hD1lNN.js} +3 -3
- package/dist/core/{DiamondWipe-B1EXgweH.js → DiamondWipe-B8rFSwsV.js} +2 -2
- package/dist/core/{DiffuseBlur-CmD97dHb.js → DiffuseBlur--Gn4bDwC.js} +2 -2
- package/dist/core/{DisplacementMap-JV_CNJfU.js → DisplacementMap-DQk8S4sK.js} +4 -4
- package/dist/core/{Dither-NJDWpGb3.js → Dither-rB9M7FS7.js} +2 -2
- package/dist/core/{DotGrid-B2w7RFcv.js → DotGrid-DszAbmy5.js} +3 -3
- package/dist/core/{DropShadow-CLWp-bon.js → DropShadow-BS3S178o.js} +2 -2
- package/dist/core/{Duotone-Be2jx-jZ.js → Duotone-Cf_ybegD.js} +2 -2
- package/dist/core/{Ellipse-BR6qXidK.js → Ellipse-DY8FgSSx.js} +2 -2
- package/dist/core/{Emboss-C8ElxLo3.js → Emboss-RxgVyKyU.js} +4 -4
- package/dist/core/{Engraving-D67DM--1.js → Engraving-C0OuioUr.js} +2 -2
- package/dist/core/{ErosionNoise-FeEMQOkR.js → ErosionNoise-B-I3VFiY.js} +2 -2
- package/dist/core/{Exposure-CZ1gfqpf.js → Exposure-360tdOrT.js} +1 -1
- package/dist/core/{FallingLines-ifuQ01oA.js → FallingLines-4sVKJMDj.js} +3 -3
- package/dist/core/{FilmGrain-p5sawa_f.js → FilmGrain-CgzuRidb.js} +1 -1
- package/dist/core/{FilmStock-BD5wv1TV.js → FilmStock-BW9k3EPE.js} +1 -1
- package/dist/core/{Flip-MKiLH9jJ.js → Flip-DqdxtYHS.js} +2 -2
- package/dist/core/{FloatingParticles-Bn8CmtwG.js → FloatingParticles-BI8Y9Gcv.js} +2 -2
- package/dist/core/{FlowField-BdFeRmif.js → FlowField-CV0Is569.js} +5 -5
- package/dist/core/{Flower-BwDBwcSk.js → Flower-IaNzANoa.js} +2 -2
- package/dist/core/{FlowingGradient-RYOS36eB.js → FlowingGradient-CEAAa11t.js} +3 -3
- package/dist/core/{FlutedGlass-Ong8W4Ih.js → FlutedGlass-CF6mZMq4.js} +3 -3
- package/dist/core/{Fog-C-X8msRb.js → Fog-D9OYGwhY.js} +2 -2
- package/dist/core/{Form3D-BZ_vaLWe.js → Form3D-CJKutcFA.js} +3 -3
- package/dist/core/{FractalNoise-BPj8RPkE.js → FractalNoise-DelBWQyb.js} +3 -3
- package/dist/core/{Frost-DmxlFu63.js → Frost-Br7b9n4L.js} +5 -5
- package/dist/core/{GaborNoise-Boc8ieHd.js → GaborNoise-DViNgIse.js} +3 -3
- package/dist/core/{Glass-D5p21MIw.js → Glass-IwPea9h1.js} +4 -4
- package/dist/core/{GlassTiles-BP4CzdI3.js → GlassTiles-DpPHPKv7.js} +3 -5
- package/dist/core/{Glitch-cJguD7jS.js → Glitch-CKmX-agV.js} +1 -1
- package/dist/core/{Glow-BabfcnwS.js → Glow-CVcVetaa.js} +1 -1
- package/dist/core/{Godrays-BpiKSlNR.js → Godrays-CNNHJzNz.js} +3 -3
- package/dist/core/{Goo-BaQEtOyr.js → Goo-BUXnhwTk.js} +5 -5
- package/dist/core/{GradientMap-BtKtW-4M.js → GradientMap-DqGEXRl9.js} +2 -2
- package/dist/core/{Grayscale-Bgwugyvv.js → Grayscale-DiJAjdx3.js} +1 -1
- package/dist/core/{Grid-5cEDkyWX.js → Grid-utmP7uyR.js} +2 -2
- package/dist/core/{GridDistortion-Byf4G720.js → GridDistortion-Bn6D5dfC.js} +3 -3
- package/dist/core/{Group-DUEQSUir.js → Group-u-o7qE0Y.js} +1 -1
- package/dist/core/{HTMLInCanvas-uW1O3Z-R.js → HTMLInCanvas-sK9HN-gI.js} +1 -1
- package/dist/core/{Halftone-BiSLVvGF.js → Halftone-C5La06l6.js} +2 -2
- package/dist/core/{Heart-RAGeVEVH.js → Heart-CGLx1F8D.js} +2 -2
- package/dist/core/{Heatmap-Ds65scO7.js → Heatmap-CE5DLeJp.js} +5 -5
- package/dist/core/{HexGrid-H1N5Y1XD.js → HexGrid-CqB-yMWN.js} +2 -2
- package/dist/core/{Hologram-DpDfyeSz.js → Hologram-CctodmpA.js} +5 -5
- package/dist/core/{Holographic-Ckubuqn8.js → Holographic-DSz4qfkn.js} +5 -5
- package/dist/core/{HueShift-C_a5UVHy.js → HueShift-Cfq-ijQP.js} +1 -1
- package/dist/core/{ImageTexture-CM-dPJQ4.js → ImageTexture-DdzAYFTi.js} +1 -1
- package/dist/core/{InkFlow-CY7sCKpI.js → InkFlow-CCPfoQXs.js} +2 -2
- package/dist/core/{Invert-DhHrtwHQ.js → Invert-CtUHcYmv.js} +1 -1
- package/dist/core/{IrisWipe-BnOMUdEV.js → IrisWipe-DWVFMn81.js} +2 -2
- package/dist/core/{IsometricCubes-CXPz62PB.js → IsometricCubes-m-mYnbqN.js} +2 -2
- package/dist/core/{Kaleidoscope-CSgi0E5B.js → Kaleidoscope-DMNLVgx6.js} +4 -4
- package/dist/core/{KeyFrames-C3I4poq8.js → KeyFrames-jgrfR3Hj.js} +2 -2
- package/dist/core/{LensFlare-DxvbKXgt.js → LensFlare-CuWJsfwE.js} +3 -3
- package/dist/core/{LightEdge-niXz_FAk.js → LightEdge-WMxb-xKB.js} +5 -5
- package/dist/core/{LightLeak-B7Pt1tt4.js → LightLeak-DfOngFp7.js} +3 -3
- package/dist/core/{LinearBlur-CXNcduWQ.js → LinearBlur-iLXYGof_.js} +2 -2
- package/dist/core/{LinearGradient-CYiaWIXd.js → LinearGradient-DLrJban6.js} +3 -3
- package/dist/core/{LinearWipe-gwLhEveK.js → LinearWipe-C_fWBl4i.js} +2 -2
- package/dist/core/{LiquidMetal-D0sgLjcd.js → LiquidMetal-DHM8kVNr.js} +5 -5
- package/dist/core/{Liquify-h08a8S-C.js → Liquify-FQWL8j4t.js} +4 -4
- package/dist/core/{MagneticFilings-BlNWPVwS.js → MagneticFilings-BUzSkycD.js} +2 -2
- package/dist/core/{Marble-bps2lOWc.js → Marble-BnHffB3C.js} +3 -3
- package/dist/core/{Mirror-8miSUAyZ.js → Mirror-B_v4FunG.js} +3 -3
- package/dist/core/{MultiPointGradient-C-9_Q6CM.js → MultiPointGradient-5NGBm90u.js} +2 -2
- package/dist/core/{Neon-RDh1tAjH.js → Neon-BjBSg2FR.js} +4 -4
- package/dist/core/{NoiseDissolve-DjlWGdUc.js → NoiseDissolve-kDP6-h9F.js} +2 -2
- package/dist/core/{ObjectTracker-DW4aEBRv.js → ObjectTracker-vU1bVmIJ.js} +3 -3
- package/dist/core/{PagePeel-JsbScYi4.js → PagePeel-BgDvgtIV.js} +1 -1
- package/dist/core/{Paper-BGTU0GOF.js → Paper-_alN4JdS.js} +1 -1
- package/dist/core/{Parallelogram-RC3MxzlN.js → Parallelogram--Cil139y.js} +2 -2
- package/dist/core/{ParticleField-XypD7Eru.js → ParticleField-DZ7um7tu.js} +1 -1
- package/dist/core/{ParticleFlow-DBw7m9C6.js → ParticleFlow-CmRP2S8W.js} +2 -2
- package/dist/core/{Particles-CvpZvfe3.js → Particles-DFw2E9SE.js} +3 -3
- package/dist/core/{PerlinNoise-CHVaarmz.js → PerlinNoise-BmNpwJtM.js} +3 -3
- package/dist/core/{Perspective-zyCZAb3_.js → Perspective-DVcUW7jR.js} +4 -4
- package/dist/core/{PixelSort-B-zefB9S.js → PixelSort-Bz5dIrqH.js} +1 -1
- package/dist/core/{PixelThrow-BZ6erf3G.js → PixelThrow-DEMX8VOw.js} +2 -2
- package/dist/core/{Pixelate-D1e7buDQ.js → Pixelate-D-eWrHTE.js} +1 -1
- package/dist/core/{Plasma-CBrx8Xu-.js → Plasma-C_EIkpQi.js} +3 -3
- package/dist/core/{Plastic-CcS4iAJM.js → Plastic-CYeefb91.js} +5 -5
- package/dist/core/{PolarCoordinates-B9SuYLgF.js → PolarCoordinates-DmpUBdGX.js} +3 -3
- package/dist/core/{Polygon-N0l1KfIO.js → Polygon-DEEUdZd6.js} +2 -2
- package/dist/core/{Posterize-u2et79Pv.js → Posterize-B8oVbNZL.js} +1 -1
- package/dist/core/{Prism-BnDsPBcD.js → Prism-Btijlm0t.js} +3 -3
- package/dist/core/{ProgressiveBlur-D9FiTJQy.js → ProgressiveBlur-BoRFh6Tn.js} +2 -2
- package/dist/core/{RadialGradient-C4oB78ya.js → RadialGradient-CNDiMPZM.js} +3 -3
- package/dist/core/{RadialWipe-Dzb7i6wy.js → RadialWipe-C213vCrJ.js} +2 -2
- package/dist/core/{RandomBars-DO9j43mN.js → RandomBars-hOY9hNS7.js} +2 -2
- package/dist/core/{ReactionDiffusion-DG1NSPhM.js → ReactionDiffusion--UjME4_r.js} +2 -2
- package/dist/core/{RectangularCoordinates-Ck1gXdGx.js → RectangularCoordinates-DB7rPJ2Z.js} +3 -3
- package/dist/core/{ReflectivePlane-DFQDgLYC.js → ReflectivePlane-D92GjNLR.js} +2 -2
- package/dist/core/{Repeater-CT35_BhW.js → Repeater-CJjylN6O.js} +2 -2
- package/dist/core/{Ring-DywDgKDv.js → Ring-CJYQP2Qm.js} +2 -2
- package/dist/core/{RippleWipe-ePWlg-DT.js → RippleWipe-DJlrObO0.js} +2 -2
- package/dist/core/{Ripples-fTSMeqiE.js → Ripples-Brj67b7H.js} +3 -3
- package/dist/core/{RoundedRect-B0lxuFfM.js → RoundedRect-3vfFsHAl.js} +2 -2
- package/dist/core/{Saturation-ClaD54dk.js → Saturation-lx3DV3Up.js} +1 -1
- package/dist/core/{Scratches-D8ZIBZ50.js → Scratches-CMFr8AfL.js} +3 -3
- package/dist/core/{Sharpness-CsnT4s1o.js → Sharpness-ByZbUAd0.js} +1 -1
- package/dist/core/{Shatter-D_V7GBel.js → Shatter-B1_rLacw.js} +2 -2
- package/dist/core/{SimplexNoise-tI2G3Wzn.js → SimplexNoise-zItLLG1j.js} +3 -3
- package/dist/core/{SineWave-BGsYyEFg.js → SineWave-BvrhRcvv.js} +3 -3
- package/dist/core/{SliceWipe-s4pWdINK.js → SliceWipe-9bUWTClo.js} +1 -1
- package/dist/core/{Smoke-C3SLe_rD.js → Smoke-YixCTJbh.js} +3 -3
- package/dist/core/{SmokeFill-BuKZtbX8.js → SmokeFill-Cccbyi4g.js} +4 -4
- package/dist/core/{SmokeFlow-5fnVH2a9.js → SmokeFlow-DJ3sQPH1.js} +3 -3
- package/dist/core/{Solarize-TP85IPV7.js → Solarize-CZeTsJG8.js} +1 -1
- package/dist/core/{SolidColor-16e4q89i.js → SolidColor-DB8l6xRl.js} +1 -1
- package/dist/core/{Spherize-C4qsnql6.js → Spherize-BdYP0Auv.js} +3 -3
- package/dist/core/{Spiral-rPHDFACm.js → Spiral-PPqgFMRM.js} +3 -3
- package/dist/core/{Star-BDFhZWLo.js → Star-mgLhY4e_.js} +2 -2
- package/dist/core/{Stone-CCXo9IgA.js → Stone-CehIcoVu.js} +2 -2
- package/dist/core/{Strands-DCzYUsCX.js → Strands-Dzj-5h31.js} +3 -3
- package/dist/core/{Stretch-CjhYXAth.js → Stretch-C82iJhQu.js} +4 -4
- package/dist/core/{Stripes-CN2TFWGw.js → Stripes-C3XL9mWC.js} +3 -3
- package/dist/core/{StudioBackground-I_XxtKjr.js → StudioBackground-CDpLmvMH.js} +3 -3
- package/dist/core/{SunBurst-CGQkdsXl.js → SunBurst-fFeTV8O4.js} +3 -3
- package/dist/core/{Surface3D-CpCPTs0u.js → Surface3D-BFGuR3YZ.js} +2 -2
- package/dist/core/{Swirl-BCnlG3G8.js → Swirl-DGZs_YDx.js} +3 -3
- package/dist/core/{Teardrop-DX-YZkNC.js → Teardrop-DN7t-3HU.js} +2 -2
- package/dist/core/{Text-oI5d7_UD.js → Text-DuQnSDiW.js} +6 -5
- package/dist/core/{ThinFilm-CEYaV4nn.js → ThinFilm-DhQXCGw9.js} +4 -4
- package/dist/core/{TiltShift-C8GluqAm.js → TiltShift-CpHBxw5I.js} +2 -2
- package/dist/core/{TimeTrail-CPiSo5Of.js → TimeTrail-j89dMqNU.js} +2 -2
- package/dist/core/{Tint-NA7BO-Qk.js → Tint-WmBROyUm.js} +2 -2
- package/dist/core/{Trapezoid-BOGSQvW5.js → Trapezoid-RrEwHfyH.js} +2 -2
- package/dist/core/{TriangularGrid-Zx3I4CqA.js → TriangularGrid-D7r3Nhss.js} +3 -3
- package/dist/core/{Tritone-Bl69W4Y4.js → Tritone-BREi33uL.js} +2 -2
- package/dist/core/{Truchet-RJI0-v6x.js → Truchet-CTjP4x60.js} +2 -2
- package/dist/core/{Twirl-CrIawDs2.js → Twirl-Bvk8-3JT.js} +4 -4
- package/dist/core/{VHS-B12KbScc.js → VHS-et86dWDU.js} +1 -1
- package/dist/core/{VenetianBlinds-CGfPlhGd.js → VenetianBlinds-Bv0f2lFw.js} +2 -2
- package/dist/core/{Vesica-DekjxkHL.js → Vesica-BV2Sz5VV.js} +2 -2
- package/dist/core/{Vibrance-DKKduAD8.js → Vibrance-Q9Mrvfs-.js} +1 -1
- package/dist/core/{VideoTexture-1xg_a680.js → VideoTexture-BUY69Gqp.js} +1 -1
- package/dist/core/{Vignette-CDRCMNb2.js → Vignette-DyScJQWj.js} +2 -2
- package/dist/core/{Voronoi-EWj3WFqv.js → Voronoi-DxoT7iRa.js} +3 -3
- package/dist/core/{Water-BdGrOEuE.js → Water-CE1rY4LR.js} +5 -5
- package/dist/core/{Watercolor-BGIcnGZu.js → Watercolor-Buk5FkKR.js} +2 -2
- package/dist/core/{WaveDistortion-BNlrOaur.js → WaveDistortion-Ca6y77xt.js} +5 -5
- package/dist/core/{WaveletNoise-Jv-694xX.js → WaveletNoise-Y7LdptK_.js} +3 -3
- package/dist/core/{Weave-HNS6xvOs.js → Weave-CTpPvAhK.js} +2 -2
- package/dist/core/{WebcamTexture-DVKxGpWI.js → WebcamTexture-85gdzpo_.js} +3 -2
- package/dist/core/{Wool-D7uM0JRs.js → Wool-DJJkx7S2.js} +2 -2
- package/dist/core/{WorleyNoise-DsDWmRCp.js → WorleyNoise-C_CHhfMF.js} +3 -3
- package/dist/core/{ZoomBlur-S2GfQojf.js → ZoomBlur-8tmVWx1n.js} +2 -2
- package/dist/core/{coords-0A7CojvN.js → coords-BkIjixe_.js} +717 -44
- package/dist/core/{glass-BjUqcmHP.js → glass-sOqjtPJD.js} +1 -1
- package/dist/core/gpu/composer.d.ts +7 -0
- package/dist/core/gpu/composer.d.ts.map +1 -1
- package/dist/core/gpu/index.d.ts +22 -3
- package/dist/core/gpu/index.d.ts.map +1 -1
- package/dist/core/gpu/kit/edges.d.ts +19 -1
- package/dist/core/gpu/kit/edges.d.ts.map +1 -1
- package/dist/core/gpu/kit/index.d.ts +1 -0
- package/dist/core/gpu/kit/index.d.ts.map +1 -1
- package/dist/core/gpu/kit/sampling.d.ts +34 -0
- package/dist/core/gpu/kit/sampling.d.ts.map +1 -0
- package/dist/core/gpu/kit/sdf.d.ts.map +1 -1
- package/dist/core/gpu/kit/uvTransform.d.ts +13 -3
- package/dist/core/gpu/kit/uvTransform.d.ts.map +1 -1
- package/dist/core/gpu/passManager.d.ts +5 -1
- package/dist/core/gpu/passManager.d.ts.map +1 -1
- package/dist/core/gpu/porters.d.ts +1 -0
- package/dist/core/gpu/porters.d.ts.map +1 -1
- package/dist/core/gpu/root.d.ts +26 -4
- package/dist/core/gpu/root.d.ts.map +1 -1
- package/dist/core/gpu/support.d.ts +119 -0
- package/dist/core/gpu/support.d.ts.map +1 -0
- package/dist/core/gpu/uniformStore.d.ts.map +1 -1
- package/dist/core/index.d.ts +3 -0
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js +457 -358
- package/dist/core/{noiseColor-w3B94vmT.js → noiseColor-CY6QVFgB.js} +2 -2
- package/dist/core/{porters-B1jqpcE3.js → porters-Bl3WB9VW.js} +2 -2
- package/dist/core/presetRenderer.d.ts +13 -1
- package/dist/core/presetRenderer.d.ts.map +1 -1
- package/dist/core/registry.js +199 -198
- package/dist/core/shaderRegistry-CSTwovjI.js +425 -0
- package/dist/core/shaders/AngularBlur/index.js +5 -4
- package/dist/core/shaders/Arc/index.js +5 -4
- package/dist/core/shaders/Ascii/index.js +5 -4
- package/dist/core/shaders/Aurora/index.js +5 -4
- package/dist/core/shaders/BarShift/index.js +5 -4
- package/dist/core/shaders/BarnDoors/index.js +5 -4
- package/dist/core/shaders/Beam/index.js +5 -4
- package/dist/core/shaders/Bend/index.js +5 -4
- package/dist/core/shaders/Blob/index.js +5 -4
- package/dist/core/shaders/BlockDissolve/index.js +5 -4
- package/dist/core/shaders/BlockNoise/index.js +6 -5
- package/dist/core/shaders/BlueNoise/index.js +6 -5
- package/dist/core/shaders/Blur/index.js +5 -4
- package/dist/core/shaders/Boids/index.js +5 -4
- package/dist/core/shaders/BokehBlur/index.js +5 -4
- package/dist/core/shaders/BrickPattern/index.js +5 -4
- package/dist/core/shaders/BrightnessContrast/index.js +5 -4
- package/dist/core/shaders/BrushedMetal/index.js +7 -6
- package/dist/core/shaders/Bulge/index.js +5 -4
- package/dist/core/shaders/CRTScreen/index.js +5 -4
- package/dist/core/shaders/CarbonFiber/index.js +7 -6
- package/dist/core/shaders/Chalkboard/index.js +5 -4
- package/dist/core/shaders/ChannelBlur/index.js +5 -4
- package/dist/core/shaders/CheckerWipe/index.js +5 -4
- package/dist/core/shaders/Checkerboard/index.js +5 -4
- package/dist/core/shaders/Chevron/index.js +5 -4
- package/dist/core/shaders/ChromaFlow/index.js +5 -4
- package/dist/core/shaders/ChromaticAberration/index.js +5 -4
- package/dist/core/shaders/Circle/index.js +5 -4
- package/dist/core/shaders/ColorWheel/index.js +5 -4
- package/dist/core/shaders/CompressionArtifacts/index.js +5 -4
- package/dist/core/shaders/ConcentricSpin/index.js +5 -4
- package/dist/core/shaders/ConicGradient/index.js +5 -4
- package/dist/core/shaders/ContourLines/index.js +5 -4
- package/dist/core/shaders/CornerPin/index.js +5 -4
- package/dist/core/shaders/Crescent/index.js +5 -4
- package/dist/core/shaders/Cross/index.js +5 -4
- package/dist/core/shaders/Crystal/index.js +7 -6
- package/dist/core/shaders/CurlNoise/index.js +6 -5
- package/dist/core/shaders/CursorRipples/index.js +5 -4
- package/dist/core/shaders/CursorTrail/index.js +5 -4
- package/dist/core/shaders/DataMosh/index.js +5 -4
- package/dist/core/shaders/DiamondGradient/index.js +5 -4
- package/dist/core/shaders/DiamondWipe/index.js +5 -4
- package/dist/core/shaders/DiffuseBlur/index.js +5 -4
- package/dist/core/shaders/DisplacementMap/index.js +5 -4
- package/dist/core/shaders/Dither/index.js +5 -4
- package/dist/core/shaders/DotGrid/index.js +5 -4
- package/dist/core/shaders/DropShadow/index.js +5 -4
- package/dist/core/shaders/Duotone/index.js +5 -4
- package/dist/core/shaders/Ellipse/index.js +5 -4
- package/dist/core/shaders/Emboss/index.js +7 -6
- package/dist/core/shaders/Engraving/index.js +5 -4
- package/dist/core/shaders/ErosionNoise/index.js +6 -5
- package/dist/core/shaders/Exposure/index.js +5 -4
- package/dist/core/shaders/FallingLines/index.js +5 -4
- package/dist/core/shaders/FilmGrain/index.js +5 -4
- package/dist/core/shaders/FilmStock/index.js +5 -4
- package/dist/core/shaders/Flip/index.js +5 -4
- package/dist/core/shaders/FloatingParticles/index.js +5 -4
- package/dist/core/shaders/FlowField/index.js +5 -4
- package/dist/core/shaders/Flower/index.js +5 -4
- package/dist/core/shaders/FlowingGradient/index.js +5 -4
- package/dist/core/shaders/FlutedGlass/index.js +5 -4
- package/dist/core/shaders/Fog/index.js +5 -4
- package/dist/core/shaders/Form3D/index.js +5 -4
- package/dist/core/shaders/FractalNoise/index.js +5 -4
- package/dist/core/shaders/Frost/index.js +7 -6
- package/dist/core/shaders/GaborNoise/index.js +6 -5
- package/dist/core/shaders/Glass/index.js +7 -6
- package/dist/core/shaders/GlassTiles/index.d.ts.map +1 -1
- package/dist/core/shaders/GlassTiles/index.js +5 -4
- package/dist/core/shaders/Glitch/index.js +5 -4
- package/dist/core/shaders/Glow/index.js +5 -4
- package/dist/core/shaders/Godrays/index.js +5 -4
- package/dist/core/shaders/Goo/index.js +7 -6
- package/dist/core/shaders/GradientMap/index.js +5 -4
- package/dist/core/shaders/Grayscale/index.js +5 -4
- package/dist/core/shaders/Grid/index.js +5 -4
- package/dist/core/shaders/GridDistortion/index.js +5 -4
- package/dist/core/shaders/Group/index.js +5 -4
- package/dist/core/shaders/HTMLInCanvas/index.js +5 -4
- package/dist/core/shaders/Halftone/index.js +5 -4
- package/dist/core/shaders/Heart/index.js +5 -4
- package/dist/core/shaders/Heatmap/index.js +7 -6
- package/dist/core/shaders/HexGrid/index.js +5 -4
- package/dist/core/shaders/Hologram/index.js +7 -6
- package/dist/core/shaders/Holographic/index.js +7 -6
- package/dist/core/shaders/HueShift/index.js +5 -4
- package/dist/core/shaders/ImageTexture/index.js +5 -4
- package/dist/core/shaders/InkFlow/index.js +5 -4
- package/dist/core/shaders/Invert/index.js +5 -4
- package/dist/core/shaders/IrisWipe/index.js +5 -4
- package/dist/core/shaders/IsometricCubes/index.js +5 -4
- package/dist/core/shaders/Kaleidoscope/index.js +5 -4
- package/dist/core/shaders/KeyFrames/index.js +5 -4
- package/dist/core/shaders/LensFlare/index.js +5 -4
- package/dist/core/shaders/LightEdge/index.js +7 -6
- package/dist/core/shaders/LightLeak/index.js +5 -4
- package/dist/core/shaders/LinearBlur/index.js +5 -4
- package/dist/core/shaders/LinearGradient/index.js +5 -4
- package/dist/core/shaders/LinearWipe/index.js +5 -4
- package/dist/core/shaders/LiquidMetal/index.js +7 -6
- package/dist/core/shaders/Liquify/index.js +5 -4
- package/dist/core/shaders/MagneticFilings/index.js +5 -4
- package/dist/core/shaders/Marble/index.js +5 -4
- package/dist/core/shaders/Mirror/index.js +5 -4
- package/dist/core/shaders/MultiPointGradient/index.js +5 -4
- package/dist/core/shaders/Neon/index.js +6 -5
- package/dist/core/shaders/NoiseDissolve/index.js +5 -4
- package/dist/core/shaders/ObjectTracker/index.js +6 -5
- package/dist/core/shaders/PagePeel/index.js +5 -4
- package/dist/core/shaders/Paper/index.js +5 -4
- package/dist/core/shaders/Parallelogram/index.js +5 -4
- package/dist/core/shaders/ParticleField/index.js +5 -4
- package/dist/core/shaders/ParticleFlow/index.js +5 -4
- package/dist/core/shaders/Particles/index.js +6 -5
- package/dist/core/shaders/PerlinNoise/index.js +6 -5
- package/dist/core/shaders/Perspective/index.js +5 -4
- package/dist/core/shaders/PixelSort/index.js +5 -4
- package/dist/core/shaders/PixelThrow/index.js +5 -4
- package/dist/core/shaders/Pixelate/index.js +5 -4
- package/dist/core/shaders/Plasma/index.js +5 -4
- package/dist/core/shaders/Plastic/index.js +7 -6
- package/dist/core/shaders/PolarCoordinates/index.js +5 -4
- package/dist/core/shaders/Polygon/index.js +5 -4
- package/dist/core/shaders/Posterize/index.js +5 -4
- package/dist/core/shaders/Prism/index.js +5 -4
- package/dist/core/shaders/ProgressiveBlur/index.js +5 -4
- package/dist/core/shaders/RadialGradient/index.js +5 -4
- package/dist/core/shaders/RadialWipe/index.js +5 -4
- package/dist/core/shaders/RandomBars/index.js +5 -4
- package/dist/core/shaders/ReactionDiffusion/index.js +5 -4
- package/dist/core/shaders/RectangularCoordinates/index.js +5 -4
- package/dist/core/shaders/ReflectivePlane/index.js +5 -4
- package/dist/core/shaders/Repeater/index.js +5 -4
- package/dist/core/shaders/Ring/index.js +5 -4
- package/dist/core/shaders/RippleWipe/index.js +5 -4
- package/dist/core/shaders/Ripples/index.js +5 -4
- package/dist/core/shaders/RoundedRect/index.js +5 -4
- package/dist/core/shaders/Saturation/index.js +5 -4
- package/dist/core/shaders/Scratches/index.js +6 -5
- package/dist/core/shaders/Sharpness/index.js +5 -4
- package/dist/core/shaders/Shatter/index.js +5 -4
- package/dist/core/shaders/SimplexNoise/index.js +5 -4
- package/dist/core/shaders/SineWave/index.js +5 -4
- package/dist/core/shaders/SliceWipe/index.js +5 -4
- package/dist/core/shaders/Smoke/index.js +5 -4
- package/dist/core/shaders/SmokeFill/index.js +7 -6
- package/dist/core/shaders/SmokeFlow/index.js +5 -4
- package/dist/core/shaders/Solarize/index.js +5 -4
- package/dist/core/shaders/SolidColor/index.js +2 -2
- package/dist/core/shaders/Spherize/index.d.ts.map +1 -1
- package/dist/core/shaders/Spherize/index.js +5 -4
- package/dist/core/shaders/Spiral/index.js +5 -4
- package/dist/core/shaders/Star/index.js +5 -4
- package/dist/core/shaders/Stone/index.js +4 -3
- package/dist/core/shaders/Strands/index.js +5 -4
- package/dist/core/shaders/Stretch/index.js +5 -4
- package/dist/core/shaders/Stripes/index.js +5 -4
- package/dist/core/shaders/StudioBackground/index.js +5 -4
- package/dist/core/shaders/SunBurst/index.js +5 -4
- package/dist/core/shaders/Surface3D/index.js +5 -4
- package/dist/core/shaders/Swirl/index.js +5 -4
- package/dist/core/shaders/Teardrop/index.js +5 -4
- package/dist/core/shaders/Text/index.d.ts.map +1 -1
- package/dist/core/shaders/Text/index.js +6 -5
- package/dist/core/shaders/ThinFilm/index.js +6 -5
- package/dist/core/shaders/TiltShift/index.js +5 -4
- package/dist/core/shaders/TimeTrail/index.js +5 -4
- package/dist/core/shaders/Tint/index.js +5 -4
- package/dist/core/shaders/Trapezoid/index.js +5 -4
- package/dist/core/shaders/TriangularGrid/index.js +5 -4
- package/dist/core/shaders/Tritone/index.js +5 -4
- package/dist/core/shaders/Truchet/index.js +5 -4
- package/dist/core/shaders/Twirl/index.js +5 -4
- package/dist/core/shaders/VHS/index.js +5 -4
- package/dist/core/shaders/VenetianBlinds/index.js +5 -4
- package/dist/core/shaders/Vesica/index.js +5 -4
- package/dist/core/shaders/Vibrance/index.js +5 -4
- package/dist/core/shaders/VideoTexture/index.js +5 -4
- package/dist/core/shaders/Vignette/index.js +5 -4
- package/dist/core/shaders/Voronoi/index.js +5 -4
- package/dist/core/shaders/Water/index.js +7 -6
- package/dist/core/shaders/Watercolor/index.js +5 -4
- package/dist/core/shaders/WaveDistortion/index.js +5 -4
- package/dist/core/shaders/WaveletNoise/index.js +6 -5
- package/dist/core/shaders/Weave/index.js +5 -4
- package/dist/core/shaders/WebcamTexture/index.js +5 -4
- package/dist/core/shaders/Wool/index.js +4 -3
- package/dist/core/shaders/WorleyNoise/index.js +5 -4
- package/dist/core/shaders/ZoomBlur/index.js +5 -4
- package/dist/core/{shapeEffectBounds-DRyn6AvG.js → shapeEffectBounds-Cl58vRlg.js} +1 -1
- package/dist/core/support-6QRFK3xB.js +74 -0
- package/dist/core/telemetry/collector.d.ts.map +1 -1
- package/dist/core/telemetry/index.js +6 -5
- package/dist/core/utilities/boundingBox.d.ts +14 -0
- package/dist/core/utilities/boundingBox.d.ts.map +1 -1
- package/dist/core/utilities/transformations/index.js +1 -1
- package/dist/js/bundle.js +162 -162
- package/dist/js/createShader.d.ts.map +1 -1
- package/dist/js/createShader.js +43 -13
- package/dist/js/createSharedDevice.d.ts +11 -9
- package/dist/js/createSharedDevice.d.ts.map +1 -1
- package/dist/js/createSharedDevice.js +2 -1
- package/dist/js/index.d.ts +2 -0
- package/dist/js/index.d.ts.map +1 -1
- package/dist/js/index.js +2 -1
- package/dist/js/types.d.ts +40 -10
- package/dist/js/types.d.ts.map +1 -1
- package/dist/react/Shader.js +27 -11
- package/dist/react/bundle.js +159 -159
- package/dist/react/engine/Shader.d.ts +7 -0
- package/dist/react/engine/Shader.d.ts.map +1 -1
- package/dist/react/index.d.ts +2 -0
- package/dist/react/index.d.ts.map +1 -1
- package/dist/react/index.js +2 -1
- package/dist/solid/engine/Preview.js +1 -0
- package/dist/solid/engine/Shader.d.ts +7 -0
- package/dist/solid/engine/Shader.d.ts.map +1 -1
- package/dist/solid/engine/Shader.js +29 -10
- package/dist/solid/index.d.ts +2 -0
- package/dist/solid/index.d.ts.map +1 -1
- package/dist/solid/index.js +6 -1
- package/dist/svelte/engine/Shader.svelte.d.ts +7 -0
- package/dist/svelte/index.d.ts +2 -0
- package/dist/svelte/index.js +27 -11
- package/dist/svelte/source/engine/Shader.svelte +49 -13
- package/dist/svelte/source/index.js +2 -0
- package/dist/vue/Shader.vue_vue_type_script_setup_true_lang.js +41 -24
- package/dist/vue/engine/Shader.vue.d.ts +9 -1
- package/dist/vue/engine/Shader.vue.d.ts.map +1 -1
- package/dist/vue/index.d.ts +2 -0
- package/dist/vue/index.d.ts.map +1 -1
- package/dist/vue/index.js +2 -1
- package/package.json +1 -13
- package/dist/core/shaderRegistry-BrbiIqjD.js +0 -425
- package/dist/pixi/createShaderSprite.d.ts +0 -54
- package/dist/pixi/createShaderSprite.d.ts.map +0 -1
- package/dist/pixi/index.d.ts +0 -20
- package/dist/pixi/index.d.ts.map +0 -1
- package/dist/pixi/index.js +0 -153
- /package/dist/core/{fonts-BLmvxkGd.js → fonts-BtGjHq1w.js} +0 -0
- /package/dist/core/{noiseStylize-4za6Obes.js → noiseStylize-BsZQT7ig.js} +0 -0
- /package/dist/core/{transformations-P50Uo_Ju.js → transformations-t0d2-uSX.js} +0 -0
package/dist/core/index.js
CHANGED
|
@@ -1,264 +1,280 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import "./
|
|
3
|
-
import "./
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import "./
|
|
7
|
-
import
|
|
8
|
-
import {
|
|
9
|
-
import "./
|
|
10
|
-
import "./
|
|
11
|
-
import "./
|
|
12
|
-
import "./
|
|
13
|
-
import "./
|
|
14
|
-
import "./
|
|
15
|
-
import "./
|
|
16
|
-
import "./
|
|
17
|
-
import "./
|
|
18
|
-
import "./
|
|
19
|
-
import "./
|
|
20
|
-
import "./
|
|
21
|
-
import "./
|
|
22
|
-
import "./
|
|
23
|
-
import "./
|
|
24
|
-
import "./
|
|
25
|
-
import "./
|
|
26
|
-
import "./
|
|
27
|
-
import
|
|
28
|
-
import "./
|
|
29
|
-
import "./
|
|
30
|
-
import "./
|
|
31
|
-
import "./
|
|
32
|
-
import "./
|
|
33
|
-
import "./
|
|
34
|
-
import "./
|
|
35
|
-
import "./
|
|
36
|
-
import "./
|
|
37
|
-
import "./
|
|
38
|
-
import "./
|
|
39
|
-
import "./
|
|
40
|
-
import "./
|
|
41
|
-
import "./
|
|
42
|
-
import "./
|
|
43
|
-
import "./
|
|
44
|
-
import "./
|
|
45
|
-
import "./
|
|
46
|
-
import "./
|
|
47
|
-
import "./
|
|
48
|
-
import "./
|
|
49
|
-
import "./
|
|
50
|
-
import "./
|
|
51
|
-
import "./
|
|
52
|
-
import "./
|
|
53
|
-
import "./
|
|
54
|
-
import "./
|
|
55
|
-
import "./
|
|
56
|
-
import "./
|
|
57
|
-
import "./
|
|
58
|
-
import "./
|
|
59
|
-
import "./
|
|
60
|
-
import "./
|
|
61
|
-
import "./
|
|
62
|
-
import "./
|
|
63
|
-
import "./
|
|
64
|
-
import "./
|
|
65
|
-
import "./
|
|
66
|
-
import "./
|
|
67
|
-
import "./
|
|
68
|
-
import "./
|
|
69
|
-
import "./
|
|
70
|
-
import "./
|
|
71
|
-
import "./
|
|
72
|
-
import "./
|
|
73
|
-
import "./
|
|
74
|
-
import "./
|
|
75
|
-
import "./
|
|
76
|
-
import "./
|
|
77
|
-
import "./
|
|
78
|
-
import "./
|
|
79
|
-
import "./
|
|
80
|
-
import "./
|
|
81
|
-
import "./
|
|
82
|
-
import "./
|
|
83
|
-
import "./
|
|
84
|
-
import "./
|
|
85
|
-
import "./
|
|
86
|
-
import "./
|
|
87
|
-
import "./
|
|
88
|
-
import "./
|
|
89
|
-
import "./
|
|
90
|
-
import "./
|
|
91
|
-
import "./
|
|
92
|
-
import "./
|
|
93
|
-
import "./
|
|
94
|
-
import "./
|
|
95
|
-
import "./
|
|
96
|
-
import "./
|
|
97
|
-
import "./
|
|
98
|
-
import "./
|
|
99
|
-
import "./
|
|
100
|
-
import "./
|
|
101
|
-
import "./
|
|
102
|
-
import "./
|
|
103
|
-
import "./
|
|
104
|
-
import "./
|
|
105
|
-
import "./
|
|
106
|
-
import "./
|
|
107
|
-
import "./
|
|
108
|
-
import "./
|
|
109
|
-
import "./
|
|
110
|
-
import "./
|
|
111
|
-
import "./
|
|
112
|
-
import "./
|
|
113
|
-
import "./
|
|
114
|
-
import "./
|
|
115
|
-
import "./
|
|
116
|
-
import "./
|
|
117
|
-
import "./
|
|
118
|
-
import "./
|
|
119
|
-
import "./
|
|
120
|
-
import "./
|
|
121
|
-
import "./
|
|
122
|
-
import "./
|
|
123
|
-
import "./
|
|
124
|
-
import "./
|
|
125
|
-
import "./
|
|
126
|
-
import "./
|
|
127
|
-
import "./
|
|
128
|
-
import "./
|
|
129
|
-
import "./
|
|
130
|
-
import "./
|
|
131
|
-
import "./
|
|
132
|
-
import "./
|
|
133
|
-
import "./
|
|
134
|
-
import "./
|
|
135
|
-
import "./
|
|
136
|
-
import "./
|
|
137
|
-
import "./
|
|
138
|
-
import "./
|
|
139
|
-
import "./
|
|
140
|
-
import "./
|
|
141
|
-
import "./
|
|
142
|
-
import "./
|
|
143
|
-
import "./
|
|
144
|
-
import "./
|
|
145
|
-
import "./
|
|
146
|
-
import "./
|
|
147
|
-
import "./
|
|
148
|
-
import "./
|
|
149
|
-
import "./
|
|
150
|
-
import "./
|
|
151
|
-
import "./
|
|
152
|
-
import "./
|
|
153
|
-
import "./
|
|
154
|
-
import "./
|
|
155
|
-
import "./
|
|
156
|
-
import "./
|
|
157
|
-
import "./
|
|
158
|
-
import "./
|
|
159
|
-
import "./
|
|
160
|
-
import "./
|
|
161
|
-
import "./
|
|
162
|
-
import "./
|
|
163
|
-
import "./
|
|
164
|
-
import "./
|
|
165
|
-
import "./
|
|
166
|
-
import "./
|
|
167
|
-
import "./
|
|
168
|
-
import "./
|
|
169
|
-
import "./
|
|
170
|
-
import "./
|
|
171
|
-
import "./
|
|
172
|
-
import "./
|
|
173
|
-
import "./
|
|
174
|
-
import "./
|
|
175
|
-
import "./
|
|
176
|
-
import "./
|
|
177
|
-
import "./
|
|
178
|
-
import "./
|
|
179
|
-
import "./
|
|
180
|
-
import "./
|
|
181
|
-
import "./
|
|
182
|
-
import "./
|
|
183
|
-
import "./
|
|
184
|
-
import "./
|
|
185
|
-
import "./
|
|
186
|
-
import "./
|
|
187
|
-
import "./
|
|
188
|
-
import "./
|
|
189
|
-
import "./
|
|
190
|
-
import "./
|
|
191
|
-
import "./
|
|
192
|
-
import "./
|
|
193
|
-
import "./
|
|
194
|
-
import "./
|
|
195
|
-
import "./
|
|
196
|
-
import "./
|
|
197
|
-
import "./
|
|
198
|
-
import
|
|
1
|
+
import { $t as resolveBoundingBox, Cn as FieldHandle, Dt as packConvertedStops, En as updateFieldValue, Ot as packStops, Qt as isIdentityBoundingBox, S as maxPixelRatioForDevice, Ut as collectStructuralHashInputs, Wt as composeNodeTree, Y as createComputeDispatcher, Zt as DEFAULT_BOUNDING_BOX, en as boundingBoxToUVParams, kt as getAnimatedTimeState, nn as screenUVToBoxLocal$1, t as SystemUniforms, tn as needsTransformation, wn as createUniformStore, zt as SHARED_SAMPLER_LAYOUT } from "./coords-BkIjixe_.js";
|
|
2
|
+
import { a as getWebGPUSupport, c as isWebGPUSupported, i as getGpuUnusableReason, l as markGpuUnusable, n as debugError, o as isGpuUnavailableError, r as debugWarn, s as isShadersDebug, t as GpuUnavailableError, u as setShadersDebug } from "./support-6QRFK3xB.js";
|
|
3
|
+
import "./glass-sOqjtPJD.js";
|
|
4
|
+
import "./Neon-BjBSg2FR.js";
|
|
5
|
+
import "./Emboss-RxgVyKyU.js";
|
|
6
|
+
import "./Form3D-CJKutcFA.js";
|
|
7
|
+
import "./ThinFilm-DhQXCGw9.js";
|
|
8
|
+
import { o as transformColorSpace } from "./transformations-t0d2-uSX.js";
|
|
9
|
+
import { _ as sortStops, a as buildDimensionalPlan, c as isDimensionalValue, d as colorToRGBA, f as setColorSpaceModeGpu, g as resolveStops, h as colorStopsTransform, i as boxHalfExtentsUV, l as resolveDimensionalProp, n as rootPassthrough, o as buildExtraSizeProps, p as MAX_COLOR_STOPS, r as createGpuUniformsMap, s as isDimensionalProp, u as setShaderCanvasDimensions } from "./porters-Bl3WB9VW.js";
|
|
10
|
+
import "./AngularBlur-D33jrcZd.js";
|
|
11
|
+
import "./Arc-BG8Bpknl.js";
|
|
12
|
+
import "./Ascii-DE0vAAOX.js";
|
|
13
|
+
import "./Aurora-Cu4JGjCD.js";
|
|
14
|
+
import "./BarnDoors-JraHuTwe.js";
|
|
15
|
+
import "./BarShift-o_IvV0t_.js";
|
|
16
|
+
import "./Beam-DshQatlM.js";
|
|
17
|
+
import "./Bend-KJzYWEJV.js";
|
|
18
|
+
import "./Blob-BJxkqvOO.js";
|
|
19
|
+
import "./BlockDissolve-CsIQWUpY.js";
|
|
20
|
+
import "./noiseColor-CY6QVFgB.js";
|
|
21
|
+
import "./BlockNoise-DVI-0PnC.js";
|
|
22
|
+
import "./BlueNoise-CzBN6i38.js";
|
|
23
|
+
import "./Blur-W95k4Lxz.js";
|
|
24
|
+
import "./Boids-BJ6wxFC8.js";
|
|
25
|
+
import "./BokehBlur-CbOO__cN.js";
|
|
26
|
+
import "./BrickPattern-eQv5DrKE.js";
|
|
27
|
+
import "./BrightnessContrast-CmH2DvaZ.js";
|
|
28
|
+
import { a as SVG3D_TYPES, c as isVolumetricShapeType, i as SVG3D_DEFAULTS, l as shape3dBoundingRadius, n as SHAPE3D_DEFAULTS, o as is3dShapeType, r as SHAPE3D_TYPES, s as isSvg3dShapeType } from "./shapeEffectBounds-Cl58vRlg.js";
|
|
29
|
+
import "./BrushedMetal-D-7M7ZuM.js";
|
|
30
|
+
import "./Bulge-KmBnaVMx.js";
|
|
31
|
+
import "./CarbonFiber-D4jap49E.js";
|
|
32
|
+
import "./Chalkboard-H6-0OXC3.js";
|
|
33
|
+
import "./ChannelBlur-BKJfnu91.js";
|
|
34
|
+
import "./Checkerboard-NwKMLVHe.js";
|
|
35
|
+
import "./CheckerWipe-acIaflfK.js";
|
|
36
|
+
import "./Chevron-eBbFV2ud.js";
|
|
37
|
+
import "./ChromaFlow-ex7l4tTK.js";
|
|
38
|
+
import "./ChromaticAberration-Bbi9vNxS.js";
|
|
39
|
+
import "./Circle-DdFWEti1.js";
|
|
40
|
+
import "./ColorWheel-BqcyPqcj.js";
|
|
41
|
+
import "./CompressionArtifacts-DqWq-4h8.js";
|
|
42
|
+
import "./ConcentricSpin-CtI1hKio.js";
|
|
43
|
+
import "./ConicGradient-HmImN4LO.js";
|
|
44
|
+
import "./ContourLines-BMom2vMu.js";
|
|
45
|
+
import "./CornerPin-D_-luriU.js";
|
|
46
|
+
import "./Crescent-CY6MeN9V.js";
|
|
47
|
+
import "./Cross-ClImej9a.js";
|
|
48
|
+
import "./CRTScreen-t7dyfO5u.js";
|
|
49
|
+
import "./Crystal-CMrqHLFD.js";
|
|
50
|
+
import "./CurlNoise-C_QZBT5m.js";
|
|
51
|
+
import "./CursorRipples-Bmlex_IF.js";
|
|
52
|
+
import "./CursorTrail-B68x1Cv-.js";
|
|
53
|
+
import "./DataMosh-FZQWg5Ui.js";
|
|
54
|
+
import "./DiamondGradient-C0hD1lNN.js";
|
|
55
|
+
import "./DiamondWipe-B8rFSwsV.js";
|
|
56
|
+
import "./DiffuseBlur--Gn4bDwC.js";
|
|
57
|
+
import "./DisplacementMap-DQk8S4sK.js";
|
|
58
|
+
import "./Dither-rB9M7FS7.js";
|
|
59
|
+
import "./DotGrid-DszAbmy5.js";
|
|
60
|
+
import "./DropShadow-BS3S178o.js";
|
|
61
|
+
import "./Duotone-Cf_ybegD.js";
|
|
62
|
+
import "./Ellipse-DY8FgSSx.js";
|
|
63
|
+
import "./Engraving-C0OuioUr.js";
|
|
64
|
+
import "./ErosionNoise-B-I3VFiY.js";
|
|
65
|
+
import "./Exposure-360tdOrT.js";
|
|
66
|
+
import "./FallingLines-4sVKJMDj.js";
|
|
67
|
+
import "./FilmGrain-CgzuRidb.js";
|
|
68
|
+
import "./FilmStock-BW9k3EPE.js";
|
|
69
|
+
import "./Flip-DqdxtYHS.js";
|
|
70
|
+
import "./FloatingParticles-BI8Y9Gcv.js";
|
|
71
|
+
import "./Flower-IaNzANoa.js";
|
|
72
|
+
import "./FlowField-CV0Is569.js";
|
|
73
|
+
import "./FlowingGradient-CEAAa11t.js";
|
|
74
|
+
import "./FlutedGlass-CF6mZMq4.js";
|
|
75
|
+
import "./Fog-D9OYGwhY.js";
|
|
76
|
+
import "./FractalNoise-DelBWQyb.js";
|
|
77
|
+
import "./Frost-Br7b9n4L.js";
|
|
78
|
+
import "./GaborNoise-DViNgIse.js";
|
|
79
|
+
import "./Glass-IwPea9h1.js";
|
|
80
|
+
import "./GlassTiles-DpPHPKv7.js";
|
|
81
|
+
import "./Glitch-CKmX-agV.js";
|
|
82
|
+
import "./Glow-CVcVetaa.js";
|
|
83
|
+
import "./Godrays-CNNHJzNz.js";
|
|
84
|
+
import "./Goo-BUXnhwTk.js";
|
|
85
|
+
import "./GradientMap-DqGEXRl9.js";
|
|
86
|
+
import "./Grayscale-DiJAjdx3.js";
|
|
87
|
+
import "./Grid-utmP7uyR.js";
|
|
88
|
+
import "./GridDistortion-Bn6D5dfC.js";
|
|
89
|
+
import "./Group-u-o7qE0Y.js";
|
|
90
|
+
import "./Halftone-C5La06l6.js";
|
|
91
|
+
import "./Heart-CGLx1F8D.js";
|
|
92
|
+
import "./Heatmap-CE5DLeJp.js";
|
|
93
|
+
import "./HexGrid-CqB-yMWN.js";
|
|
94
|
+
import "./Hologram-CctodmpA.js";
|
|
95
|
+
import "./Holographic-DSz4qfkn.js";
|
|
96
|
+
import "./HTMLInCanvas-sK9HN-gI.js";
|
|
97
|
+
import "./HueShift-Cfq-ijQP.js";
|
|
98
|
+
import "./ImageTexture-DdzAYFTi.js";
|
|
99
|
+
import "./InkFlow-CCPfoQXs.js";
|
|
100
|
+
import "./Invert-CtUHcYmv.js";
|
|
101
|
+
import "./IrisWipe-DWVFMn81.js";
|
|
102
|
+
import "./IsometricCubes-m-mYnbqN.js";
|
|
103
|
+
import "./Kaleidoscope-DMNLVgx6.js";
|
|
104
|
+
import "./KeyFrames-jgrfR3Hj.js";
|
|
105
|
+
import "./LensFlare-CuWJsfwE.js";
|
|
106
|
+
import "./LightEdge-WMxb-xKB.js";
|
|
107
|
+
import "./LightLeak-DfOngFp7.js";
|
|
108
|
+
import "./LinearBlur-iLXYGof_.js";
|
|
109
|
+
import "./LinearGradient-DLrJban6.js";
|
|
110
|
+
import "./LinearWipe-C_fWBl4i.js";
|
|
111
|
+
import "./LiquidMetal-DHM8kVNr.js";
|
|
112
|
+
import "./Liquify-FQWL8j4t.js";
|
|
113
|
+
import "./MagneticFilings-BUzSkycD.js";
|
|
114
|
+
import "./Marble-BnHffB3C.js";
|
|
115
|
+
import "./Mirror-B_v4FunG.js";
|
|
116
|
+
import "./MultiPointGradient-5NGBm90u.js";
|
|
117
|
+
import "./NoiseDissolve-kDP6-h9F.js";
|
|
118
|
+
import "./fonts-BtGjHq1w.js";
|
|
119
|
+
import "./ObjectTracker-vU1bVmIJ.js";
|
|
120
|
+
import "./PagePeel-BgDvgtIV.js";
|
|
121
|
+
import "./Paper-_alN4JdS.js";
|
|
122
|
+
import "./Parallelogram--Cil139y.js";
|
|
123
|
+
import "./ParticleField-DZ7um7tu.js";
|
|
124
|
+
import "./ParticleFlow-CmRP2S8W.js";
|
|
125
|
+
import "./Particles-DFw2E9SE.js";
|
|
126
|
+
import "./PerlinNoise-BmNpwJtM.js";
|
|
127
|
+
import "./Perspective-DVcUW7jR.js";
|
|
128
|
+
import "./Pixelate-D-eWrHTE.js";
|
|
129
|
+
import "./PixelSort-Bz5dIrqH.js";
|
|
130
|
+
import "./PixelThrow-DEMX8VOw.js";
|
|
131
|
+
import "./Plasma-C_EIkpQi.js";
|
|
132
|
+
import "./Plastic-CYeefb91.js";
|
|
133
|
+
import "./PolarCoordinates-DmpUBdGX.js";
|
|
134
|
+
import "./Polygon-DEEUdZd6.js";
|
|
135
|
+
import "./Posterize-B8oVbNZL.js";
|
|
136
|
+
import "./Prism-Btijlm0t.js";
|
|
137
|
+
import "./ProgressiveBlur-BoRFh6Tn.js";
|
|
138
|
+
import "./RadialGradient-CNDiMPZM.js";
|
|
139
|
+
import "./RadialWipe-C213vCrJ.js";
|
|
140
|
+
import "./RandomBars-hOY9hNS7.js";
|
|
141
|
+
import "./ReactionDiffusion--UjME4_r.js";
|
|
142
|
+
import "./RectangularCoordinates-DB7rPJ2Z.js";
|
|
143
|
+
import "./ReflectivePlane-D92GjNLR.js";
|
|
144
|
+
import "./Repeater-CJjylN6O.js";
|
|
145
|
+
import "./Ring-CJYQP2Qm.js";
|
|
146
|
+
import "./Ripples-Brj67b7H.js";
|
|
147
|
+
import "./RippleWipe-DJlrObO0.js";
|
|
148
|
+
import "./RoundedRect-3vfFsHAl.js";
|
|
149
|
+
import "./Saturation-lx3DV3Up.js";
|
|
150
|
+
import "./Scratches-CMFr8AfL.js";
|
|
151
|
+
import "./Sharpness-ByZbUAd0.js";
|
|
152
|
+
import "./Shatter-B1_rLacw.js";
|
|
153
|
+
import "./SimplexNoise-zItLLG1j.js";
|
|
154
|
+
import "./SineWave-BvrhRcvv.js";
|
|
155
|
+
import "./SliceWipe-9bUWTClo.js";
|
|
156
|
+
import "./Smoke-YixCTJbh.js";
|
|
157
|
+
import "./SmokeFill-Cccbyi4g.js";
|
|
158
|
+
import "./SmokeFlow-DJ3sQPH1.js";
|
|
159
|
+
import "./Solarize-CZeTsJG8.js";
|
|
160
|
+
import "./SolidColor-DB8l6xRl.js";
|
|
161
|
+
import "./Spherize-BdYP0Auv.js";
|
|
162
|
+
import "./Spiral-PPqgFMRM.js";
|
|
163
|
+
import "./Star-mgLhY4e_.js";
|
|
164
|
+
import "./noiseStylize-BsZQT7ig.js";
|
|
165
|
+
import "./Stone-CehIcoVu.js";
|
|
166
|
+
import "./Strands-Dzj-5h31.js";
|
|
167
|
+
import "./Stretch-C82iJhQu.js";
|
|
168
|
+
import "./Stripes-C3XL9mWC.js";
|
|
169
|
+
import "./StudioBackground-CDpLmvMH.js";
|
|
170
|
+
import "./SunBurst-fFeTV8O4.js";
|
|
171
|
+
import "./Surface3D-BFGuR3YZ.js";
|
|
172
|
+
import "./Swirl-DGZs_YDx.js";
|
|
173
|
+
import "./Teardrop-DN7t-3HU.js";
|
|
174
|
+
import "./Text-DuQnSDiW.js";
|
|
175
|
+
import "./TiltShift-CpHBxw5I.js";
|
|
176
|
+
import "./TimeTrail-j89dMqNU.js";
|
|
177
|
+
import "./Tint-WmBROyUm.js";
|
|
178
|
+
import "./Trapezoid-RrEwHfyH.js";
|
|
179
|
+
import "./TriangularGrid-D7r3Nhss.js";
|
|
180
|
+
import "./Tritone-BREi33uL.js";
|
|
181
|
+
import "./Truchet-CTjP4x60.js";
|
|
182
|
+
import "./Twirl-Bvk8-3JT.js";
|
|
183
|
+
import "./VenetianBlinds-Bv0f2lFw.js";
|
|
184
|
+
import "./Vesica-BV2Sz5VV.js";
|
|
185
|
+
import "./VHS-et86dWDU.js";
|
|
186
|
+
import "./Vibrance-Q9Mrvfs-.js";
|
|
187
|
+
import "./VideoTexture-BUY69Gqp.js";
|
|
188
|
+
import "./Vignette-DyScJQWj.js";
|
|
189
|
+
import "./Voronoi-DxoT7iRa.js";
|
|
190
|
+
import "./Water-CE1rY4LR.js";
|
|
191
|
+
import "./Watercolor-Buk5FkKR.js";
|
|
192
|
+
import "./WaveDistortion-Ca6y77xt.js";
|
|
193
|
+
import "./WaveletNoise-Y7LdptK_.js";
|
|
194
|
+
import "./Weave-CTpPvAhK.js";
|
|
195
|
+
import "./WebcamTexture-85gdzpo_.js";
|
|
196
|
+
import "./Wool-DJJkx7S2.js";
|
|
197
|
+
import "./WorleyNoise-C_CHhfMF.js";
|
|
198
|
+
import "./ZoomBlur-8tmVWx1n.js";
|
|
199
|
+
import { t as getAllShaders } from "./shaderRegistry-CSTwovjI.js";
|
|
199
200
|
import * as d from "typegpu/data";
|
|
200
201
|
import tgpu, { common } from "typegpu";
|
|
201
202
|
var OPTIONAL_FEATURES = ["float32-filterable", "timestamp-query"];
|
|
202
203
|
var rootsByDevice = /* @__PURE__ */ new WeakMap();
|
|
203
204
|
var lostCallbacks = /* @__PURE__ */ new WeakMap();
|
|
204
205
|
var lostDevices = /* @__PURE__ */ new WeakSet();
|
|
205
|
-
var
|
|
206
|
+
var defaultRootPromise = null;
|
|
207
|
+
var destroyedDefaultRoots = /* @__PURE__ */ new WeakSet();
|
|
206
208
|
async function acquireRoot(options = {}) {
|
|
207
|
-
if (options.device) {
|
|
209
|
+
if (options.device && !lostDevices.has(options.device)) {
|
|
208
210
|
const device = options.device;
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
rootsByDevice.set(device, root);
|
|
214
|
-
}
|
|
215
|
-
wireDeviceLost(root, options.onDeviceLost);
|
|
216
|
-
return {
|
|
217
|
-
root,
|
|
218
|
-
device,
|
|
219
|
-
adapter: options.adapter,
|
|
220
|
-
createdDevice: false
|
|
221
|
-
};
|
|
222
|
-
}
|
|
223
|
-
let replacement;
|
|
224
|
-
for (;;) {
|
|
225
|
-
const cached = replacementRoots.get(device);
|
|
226
|
-
if (!cached) break;
|
|
227
|
-
const cachedCtx = await cached.catch(() => null);
|
|
228
|
-
if (cachedCtx && !lostDevices.has(cachedCtx.device)) {
|
|
229
|
-
replacement = cached;
|
|
230
|
-
break;
|
|
231
|
-
}
|
|
232
|
-
if (replacementRoots.get(device) === cached) replacementRoots.delete(device);
|
|
211
|
+
let root = rootsByDevice.get(device);
|
|
212
|
+
if (!root) {
|
|
213
|
+
root = tgpu.initFromDevice({ device });
|
|
214
|
+
rootsByDevice.set(device, root);
|
|
233
215
|
}
|
|
234
|
-
|
|
235
|
-
console.warn("[gpu] injected GPU device was lost — creating a replacement device for recovery");
|
|
236
|
-
replacement = createOwnRoot();
|
|
237
|
-
replacementRoots.set(device, replacement);
|
|
238
|
-
}
|
|
239
|
-
const ctx$1 = await replacement;
|
|
240
|
-
wireDeviceLost(ctx$1.root, options.onDeviceLost);
|
|
216
|
+
const release$1 = wireDeviceLost(root, options.onDeviceLost);
|
|
241
217
|
return {
|
|
242
|
-
root
|
|
243
|
-
device
|
|
244
|
-
adapter:
|
|
245
|
-
createdDevice: false
|
|
218
|
+
root,
|
|
219
|
+
device,
|
|
220
|
+
adapter: options.adapter,
|
|
221
|
+
createdDevice: false,
|
|
222
|
+
release: release$1
|
|
246
223
|
};
|
|
247
224
|
}
|
|
248
|
-
|
|
249
|
-
|
|
225
|
+
if (options.device) debugWarn("[gpu] injected GPU device was lost — falling back to the shared default device");
|
|
226
|
+
const ctx = await acquireDefaultRoot();
|
|
227
|
+
const release = wireDeviceLost(ctx.root, options.onDeviceLost);
|
|
250
228
|
return {
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
229
|
+
root: ctx.root,
|
|
230
|
+
device: ctx.device,
|
|
231
|
+
adapter: ctx.adapter,
|
|
232
|
+
createdDevice: false,
|
|
233
|
+
release
|
|
254
234
|
};
|
|
255
235
|
}
|
|
236
|
+
async function acquireDefaultRoot() {
|
|
237
|
+
for (;;) {
|
|
238
|
+
const cached = defaultRootPromise;
|
|
239
|
+
if (!cached) break;
|
|
240
|
+
const ctx = await cached.catch(() => null);
|
|
241
|
+
if (ctx && !destroyedDefaultRoots.has(cached) && !lostDevices.has(ctx.device)) return ctx;
|
|
242
|
+
if (defaultRootPromise === cached) defaultRootPromise = null;
|
|
243
|
+
}
|
|
244
|
+
const pending = createOwnRoot();
|
|
245
|
+
defaultRootPromise = pending;
|
|
246
|
+
try {
|
|
247
|
+
return await pending;
|
|
248
|
+
} catch (error) {
|
|
249
|
+
if (defaultRootPromise === pending) defaultRootPromise = null;
|
|
250
|
+
throw error;
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
function destroyDefaultGpuDevice() {
|
|
254
|
+
const pending = defaultRootPromise;
|
|
255
|
+
defaultRootPromise = null;
|
|
256
|
+
if (!pending) return;
|
|
257
|
+
destroyedDefaultRoots.add(pending);
|
|
258
|
+
pending.then((ctx) => {
|
|
259
|
+
lostDevices.add(ctx.device);
|
|
260
|
+
try {
|
|
261
|
+
ctx.root.destroy();
|
|
262
|
+
} catch {}
|
|
263
|
+
}).catch(() => {});
|
|
264
|
+
}
|
|
256
265
|
async function createOwnRoot() {
|
|
257
|
-
if (typeof navigator === "undefined" || !navigator.gpu) throw new
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
266
|
+
if (typeof navigator === "undefined" || !navigator.gpu) throw new GpuUnavailableError("unsupported", "[gpu] WebGPU is not available in this environment (navigator.gpu is undefined).");
|
|
267
|
+
let root;
|
|
268
|
+
try {
|
|
269
|
+
root = await tgpu.init({
|
|
270
|
+
adapter: { powerPreference: "high-performance" },
|
|
271
|
+
device: { optionalFeatures: OPTIONAL_FEATURES }
|
|
272
|
+
});
|
|
273
|
+
} catch (error) {
|
|
274
|
+
const info = await getWebGPUSupport();
|
|
275
|
+
throw new GpuUnavailableError(info.supported ? "no-device" : info.reason ?? "init-failed", void 0, { cause: error });
|
|
276
|
+
}
|
|
277
|
+
if (!root.device) throw new GpuUnavailableError("no-device", "[gpu] adapter returned no device.");
|
|
262
278
|
rootsByDevice.set(root.device, root);
|
|
263
279
|
return {
|
|
264
280
|
root,
|
|
@@ -282,10 +298,13 @@ function wireDeviceLost(root, onDeviceLost) {
|
|
|
282
298
|
root.device.lost.then((info) => {
|
|
283
299
|
lostDevices.add(device);
|
|
284
300
|
if (info.reason === "destroyed") return;
|
|
285
|
-
for (const cb of lostCallbacks.get(device) ?? []) cb(info);
|
|
301
|
+
for (const cb of [...lostCallbacks.get(device) ?? []]) cb(info);
|
|
286
302
|
});
|
|
287
303
|
}
|
|
288
|
-
if (onDeviceLost)
|
|
304
|
+
if (!onDeviceLost) return () => {};
|
|
305
|
+
const set = callbacks;
|
|
306
|
+
set.add(onDeviceLost);
|
|
307
|
+
return () => set.delete(onDeviceLost);
|
|
289
308
|
}
|
|
290
309
|
function structuralHash(inputs) {
|
|
291
310
|
let h = 2166136261;
|
|
@@ -387,7 +406,8 @@ function createPassManager(root, options) {
|
|
|
387
406
|
const { textureManager, dispatcher } = options;
|
|
388
407
|
const canvasFormat = options.canvasFormat ?? preferredCanvasFormat();
|
|
389
408
|
const rttFormat = options.rttFormat ?? "rgba16float";
|
|
390
|
-
const
|
|
409
|
+
const deviceMaxSampled = root.device?.limits?.maxSampledTexturesPerShaderStage;
|
|
410
|
+
const maxSampled = options.maxSampledTextures ?? (typeof deviceMaxSampled === "number" && deviceMaxSampled > 0 ? deviceMaxSampled : 16);
|
|
391
411
|
const vertex = options.fullScreenTriangle ?? common.fullScreenTriangle;
|
|
392
412
|
const rttTextures = /* @__PURE__ */ new Map();
|
|
393
413
|
const liveTextures = /* @__PURE__ */ new Set();
|
|
@@ -402,7 +422,7 @@ function createPassManager(root, options) {
|
|
|
402
422
|
nearestRepeat: s.nearestRepeat
|
|
403
423
|
});
|
|
404
424
|
} catch (e) {
|
|
405
|
-
|
|
425
|
+
debugError(`[${LABEL}] failed to build sampler bind group:`, e);
|
|
406
426
|
return;
|
|
407
427
|
}
|
|
408
428
|
}
|
|
@@ -436,16 +456,16 @@ function createPassManager(root, options) {
|
|
|
436
456
|
const media = mediaResources?.[key];
|
|
437
457
|
const resource = rt ?? media;
|
|
438
458
|
if (!resource) {
|
|
439
|
-
|
|
459
|
+
debugError(`[${LABEL}] pass "${fragment.entry}" reads unknown texture "${key}"`);
|
|
440
460
|
return;
|
|
441
461
|
}
|
|
442
462
|
entries[key] = resource.texture;
|
|
443
463
|
}
|
|
444
|
-
if (fragment.reads.length > maxSampled)
|
|
464
|
+
if (fragment.reads.length > maxSampled) debugWarn(`[${LABEL}] pass samples ${fragment.reads.length} textures (> device limit ~${maxSampled}); composition may fail on this device.`);
|
|
445
465
|
try {
|
|
446
466
|
return root.createBindGroup(fragment.textureLayout, entries);
|
|
447
467
|
} catch (e) {
|
|
448
|
-
|
|
468
|
+
debugError(`[${LABEL}] failed to build texture bind group:`, e);
|
|
449
469
|
return;
|
|
450
470
|
}
|
|
451
471
|
}
|
|
@@ -462,7 +482,7 @@ function createPassManager(root, options) {
|
|
|
462
482
|
if (keys.length === 1) {
|
|
463
483
|
const getSource = externalSources.get(keys[0]);
|
|
464
484
|
if (!getSource) {
|
|
465
|
-
|
|
485
|
+
debugError(`[${LABEL}] external read "${keys[0]}" has no registered source`);
|
|
466
486
|
return;
|
|
467
487
|
}
|
|
468
488
|
return textureManager.createExternalTextureBinding({
|
|
@@ -552,7 +572,7 @@ function createPassManager(root, options) {
|
|
|
552
572
|
const bg = pass.externalBinding?.update() ?? null;
|
|
553
573
|
if (!bg) {
|
|
554
574
|
if (!pass.externalSkipLogged) {
|
|
555
|
-
|
|
575
|
+
debugWarn(`[${LABEL}] external texture not ready — skipping pass (${pass.fragment.externalReads.join(", ")})`);
|
|
556
576
|
pass.externalSkipLogged = true;
|
|
557
577
|
}
|
|
558
578
|
return;
|
|
@@ -1141,6 +1161,8 @@ var PerformanceTracker = class {
|
|
|
1141
1161
|
this.lastGpuTime = null;
|
|
1142
1162
|
}
|
|
1143
1163
|
};
|
|
1164
|
+
var MAX_UNCAPTURED_VALIDATION_ERRORS = 32;
|
|
1165
|
+
var MAX_CONSECUTIVE_RENDER_ERRORS = 5;
|
|
1144
1166
|
var globalEventManager = (() => {
|
|
1145
1167
|
let instanceCount = 0;
|
|
1146
1168
|
const callbacks = /* @__PURE__ */ new Set();
|
|
@@ -1149,7 +1171,7 @@ var globalEventManager = (() => {
|
|
|
1149
1171
|
try {
|
|
1150
1172
|
cb[key](arg);
|
|
1151
1173
|
} catch (error) {
|
|
1152
|
-
|
|
1174
|
+
debugError("[Shaders] Error in pointer handler:", error);
|
|
1153
1175
|
}
|
|
1154
1176
|
});
|
|
1155
1177
|
};
|
|
@@ -1261,6 +1283,13 @@ function shaderRendererGPU() {
|
|
|
1261
1283
|
let firstRenderPending = false;
|
|
1262
1284
|
let onDeviceLostCallback = null;
|
|
1263
1285
|
let deviceLostFired = false;
|
|
1286
|
+
let failureReason = null;
|
|
1287
|
+
let onUnavailableCallback = null;
|
|
1288
|
+
let hasNotifiedUnavailable = false;
|
|
1289
|
+
let uncapturedErrorDevice = null;
|
|
1290
|
+
let uncapturedErrorHandler = null;
|
|
1291
|
+
let uncapturedValidationErrors = 0;
|
|
1292
|
+
let consecutiveRenderErrors = 0;
|
|
1264
1293
|
const performanceTracker = new PerformanceTracker();
|
|
1265
1294
|
const frameParams = {
|
|
1266
1295
|
deltaTime: 0,
|
|
@@ -1351,7 +1380,7 @@ function shaderRendererGPU() {
|
|
|
1351
1380
|
aspectRatio: aspectRatio()
|
|
1352
1381
|
};
|
|
1353
1382
|
};
|
|
1354
|
-
const bboxActive = (node) => !!node.metadata.boundingBox && !!node.boundingBoxDeclaration;
|
|
1383
|
+
const bboxActive = (node) => !!node.metadata.boundingBox && !!node.boundingBoxDeclaration && !isIdentityBoundingBox(node.metadata.boundingBox);
|
|
1355
1384
|
const computeNodeBoundsUV = (node) => {
|
|
1356
1385
|
const decl = node.boundingBoxDeclaration;
|
|
1357
1386
|
if (!decl || !node.uniforms) return null;
|
|
@@ -1756,7 +1785,7 @@ function shaderRendererGPU() {
|
|
|
1756
1785
|
const parts = [];
|
|
1757
1786
|
for (const [id, node] of nodes) {
|
|
1758
1787
|
const m = node.metadata;
|
|
1759
|
-
|
|
1788
|
+
parts.push(`aopac:${id}:${(m.opacity ?? 1) < 1}`);
|
|
1760
1789
|
const sc = node.uniforms.stopCount?.value;
|
|
1761
1790
|
if (typeof sc === "number") parts.push(`stops:${id}:${sc > 1 ? sc : 0}`);
|
|
1762
1791
|
for (const [prop, u] of Object.entries(node.uniforms)) {
|
|
@@ -1816,17 +1845,17 @@ function shaderRendererGPU() {
|
|
|
1816
1845
|
try {
|
|
1817
1846
|
for (const cb of bc.ir.onCleanup) cb();
|
|
1818
1847
|
} catch (e) {
|
|
1819
|
-
|
|
1848
|
+
debugError("[gpu] composition onCleanup error:", e);
|
|
1820
1849
|
}
|
|
1821
1850
|
try {
|
|
1822
1851
|
bc.passManager.dispose();
|
|
1823
1852
|
} catch (e) {
|
|
1824
|
-
|
|
1853
|
+
debugError("[gpu] passManager dispose error:", e);
|
|
1825
1854
|
}
|
|
1826
1855
|
try {
|
|
1827
1856
|
bc.store.destroy();
|
|
1828
1857
|
} catch (e) {
|
|
1829
|
-
|
|
1858
|
+
debugError("[gpu] store destroy error:", e);
|
|
1830
1859
|
}
|
|
1831
1860
|
liveCompositions.delete(bc);
|
|
1832
1861
|
if (boundComposition === bc) boundComposition = null;
|
|
@@ -1858,6 +1887,7 @@ function shaderRendererGPU() {
|
|
|
1858
1887
|
requestRender();
|
|
1859
1888
|
};
|
|
1860
1889
|
const requestRender = () => {
|
|
1890
|
+
if (failureReason) return;
|
|
1861
1891
|
if (frameLoop.running) return;
|
|
1862
1892
|
if (pendingRenderRAF !== null) return;
|
|
1863
1893
|
if (typeof requestAnimationFrame !== "function") return;
|
|
@@ -1867,6 +1897,7 @@ function shaderRendererGPU() {
|
|
|
1867
1897
|
});
|
|
1868
1898
|
};
|
|
1869
1899
|
const registerNode = (id, fragmentNodeFunc, parentId, metadata, uniforms = {}, componentDefinition, domCanvas) => {
|
|
1900
|
+
if (failureReason) return;
|
|
1870
1901
|
if (fragmentNodeFunc === null) {
|
|
1871
1902
|
const queueIndex = pendingRegistrationQueue.findIndex((item) => item.id === id);
|
|
1872
1903
|
if (queueIndex !== -1) {
|
|
@@ -2017,7 +2048,7 @@ function shaderRendererGPU() {
|
|
|
2017
2048
|
const newOpacity = metadata.opacity;
|
|
2018
2049
|
node.metadata.opacity = newOpacity;
|
|
2019
2050
|
writeSyntheticScalar(node, "_opacity", newOpacity);
|
|
2020
|
-
if (
|
|
2051
|
+
if (oldOpacity >= 1 !== newOpacity >= 1) needsRecompose = true;
|
|
2021
2052
|
}
|
|
2022
2053
|
if (metadata.renderOrder !== void 0 && node.metadata.renderOrder !== metadata.renderOrder) {
|
|
2023
2054
|
node.metadata.renderOrder = metadata.renderOrder;
|
|
@@ -2104,10 +2135,12 @@ function shaderRendererGPU() {
|
|
|
2104
2135
|
if (metadata.boundingBox !== void 0 && metadata.boundingBox !== null && node.boundingBoxDeclaration !== void 0) {
|
|
2105
2136
|
const wasActive = bboxActive(node);
|
|
2106
2137
|
node.metadata.boundingBox = metadata.boundingBox;
|
|
2107
|
-
|
|
2138
|
+
const nowActive = bboxActive(node);
|
|
2139
|
+
if (wasActive !== nowActive) needsRecompose = true;
|
|
2140
|
+
else if (nowActive) {
|
|
2108
2141
|
const bb = bboxFieldValues(node);
|
|
2109
2142
|
if (bb) for (const [k, v] of Object.entries(bb)) writeSyntheticScalar(node, `_bbox_${k}`, v);
|
|
2110
|
-
}
|
|
2143
|
+
}
|
|
2111
2144
|
} else if (metadata.boundingBox === null) {
|
|
2112
2145
|
if (node.metadata.boundingBox !== void 0) {
|
|
2113
2146
|
node.metadata.boundingBox = void 0;
|
|
@@ -2287,7 +2320,7 @@ function shaderRendererGPU() {
|
|
|
2287
2320
|
height: bufH
|
|
2288
2321
|
});
|
|
2289
2322
|
} catch (e) {
|
|
2290
|
-
|
|
2323
|
+
debugError("[gpu] composition onResize error:", e);
|
|
2291
2324
|
}
|
|
2292
2325
|
for (const node of nodes.values()) {
|
|
2293
2326
|
if (transformActive(node)) writeSyntheticScalar(node, "_xform_aspectRatio", aspectRatio());
|
|
@@ -2371,11 +2404,11 @@ function shaderRendererGPU() {
|
|
|
2371
2404
|
for (const cb of callbacks) try {
|
|
2372
2405
|
cb(frameParams);
|
|
2373
2406
|
} catch (e) {
|
|
2374
|
-
|
|
2407
|
+
debugError("[gpu] render callback error:", e);
|
|
2375
2408
|
}
|
|
2376
2409
|
};
|
|
2377
2410
|
const renderFrameInternal = (overrideDeltaTime) => {
|
|
2378
|
-
if (!canRender()) return;
|
|
2411
|
+
if (failureReason || !canRender()) return;
|
|
2379
2412
|
const now = performance.now();
|
|
2380
2413
|
let delta;
|
|
2381
2414
|
if (overrideDeltaTime !== void 0) delta = overrideDeltaTime;
|
|
@@ -2398,29 +2431,29 @@ function shaderRendererGPU() {
|
|
|
2398
2431
|
frameParams.dimensions.height = currentHeight;
|
|
2399
2432
|
let built = null;
|
|
2400
2433
|
let renderComp = null;
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
desiredHash
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2434
|
+
try {
|
|
2435
|
+
runFrameSequence({
|
|
2436
|
+
updateDrivers: () => {
|
|
2437
|
+
updateMouseDrivers();
|
|
2438
|
+
updateAnimatedTime();
|
|
2439
|
+
updateChildBounds();
|
|
2440
|
+
},
|
|
2441
|
+
ensureComposition: () => {
|
|
2442
|
+
if (structuralDirty || desiredHash === null) {
|
|
2443
|
+
desiredHash = computeStructuralHash();
|
|
2444
|
+
structuralDirty = false;
|
|
2445
|
+
}
|
|
2446
|
+
if (desiredHash === null) return false;
|
|
2447
|
+
built = pipelineCache.getOrBuild(desiredHash, () => buildComposition(desiredHash));
|
|
2448
|
+
bindComposition(built);
|
|
2449
|
+
return !!boundComposition;
|
|
2450
|
+
},
|
|
2451
|
+
beforeRender: () => runCallbacks(boundComposition.ir.onBeforeRender),
|
|
2452
|
+
flush: () => {
|
|
2453
|
+
writeSystemUniforms(boundComposition.store);
|
|
2454
|
+
boundComposition.store.flush();
|
|
2455
|
+
},
|
|
2456
|
+
render: () => {
|
|
2424
2457
|
if (enablePerformanceTracking) performance.mark("shader-gpu-start");
|
|
2425
2458
|
renderComp = pipelineCache.renderValue ?? built;
|
|
2426
2459
|
renderComp?.passManager.render(context, frameParams);
|
|
@@ -2435,20 +2468,22 @@ function shaderRendererGPU() {
|
|
|
2435
2468
|
performance.clearMarks("shader-gpu-end");
|
|
2436
2469
|
} catch {}
|
|
2437
2470
|
}
|
|
2438
|
-
}
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
|
|
2471
|
+
},
|
|
2472
|
+
markReady: () => {
|
|
2473
|
+
pipelineCache.markReady(desiredHash);
|
|
2474
|
+
if (firstRenderPending && !hasEmittedReady) {
|
|
2475
|
+
hasEmittedReady = true;
|
|
2476
|
+
firstRenderPending = false;
|
|
2477
|
+
if (onReadyCallback) queueMicrotask(onReadyCallback);
|
|
2478
|
+
}
|
|
2479
|
+
},
|
|
2480
|
+
afterRender: () => runCallbacks((renderComp ?? boundComposition).ir.onAfterRender)
|
|
2481
|
+
});
|
|
2482
|
+
consecutiveRenderErrors = 0;
|
|
2483
|
+
} catch (error) {
|
|
2484
|
+
noteRenderFailure(error);
|
|
2485
|
+
return;
|
|
2486
|
+
}
|
|
2452
2487
|
if (enablePerformanceTracking) {
|
|
2453
2488
|
performance.mark("shader-cpu-end");
|
|
2454
2489
|
try {
|
|
@@ -2463,21 +2498,22 @@ function shaderRendererGPU() {
|
|
|
2463
2498
|
performanceTracker.recordFrame(performance.now() - now);
|
|
2464
2499
|
};
|
|
2465
2500
|
const renderFrame = () => renderFrameInternal(void 0);
|
|
2466
|
-
const renderAndWait = async () => {
|
|
2501
|
+
const renderAndWait = async (options) => {
|
|
2502
|
+
if (failureReason) return;
|
|
2467
2503
|
if (!canRender()) throw new Error("Renderer is not ready");
|
|
2468
2504
|
const wasAnimating = frameLoop.running;
|
|
2469
2505
|
if (wasAnimating) stopAnimation();
|
|
2470
2506
|
lastRenderTime = 0;
|
|
2471
2507
|
renderFrame();
|
|
2472
|
-
if (root) await awaitGpuIdle(root);
|
|
2508
|
+
if (root && options?.waitForGpu !== false) await awaitGpuIdle(root);
|
|
2473
2509
|
if (wasAnimating) startAnimation();
|
|
2474
2510
|
};
|
|
2475
|
-
const renderSyntheticFrame = async (deltaSeconds) => {
|
|
2511
|
+
const renderSyntheticFrame = async (deltaSeconds, options) => {
|
|
2476
2512
|
renderFrameInternal(deltaSeconds);
|
|
2477
|
-
if (root) await awaitGpuIdle(root);
|
|
2513
|
+
if (root && options?.waitForGpu !== false) await awaitGpuIdle(root);
|
|
2478
2514
|
};
|
|
2479
2515
|
const startAnimation = () => {
|
|
2480
|
-
if (frameLoop.running || !shouldAnimate) return;
|
|
2516
|
+
if (failureReason || frameLoop.running || !shouldAnimate) return;
|
|
2481
2517
|
performanceTracker.setRendering(true);
|
|
2482
2518
|
frameLoop.start();
|
|
2483
2519
|
};
|
|
@@ -2587,22 +2623,94 @@ function shaderRendererGPU() {
|
|
|
2587
2623
|
pendingRegistrationQueue = [];
|
|
2588
2624
|
for (const q of queue) registerNode(q.id, q.definition.fragment, q.parentId, q.metadata, q.uniforms, q.definition, q.domCanvas);
|
|
2589
2625
|
};
|
|
2626
|
+
const fail = (reason, error) => {
|
|
2627
|
+
if (failureReason) return;
|
|
2628
|
+
failureReason = reason;
|
|
2629
|
+
markGpuUnusable(reason);
|
|
2630
|
+
debugError(`[gpu] renderer stopped (${reason}):`, error);
|
|
2631
|
+
try {
|
|
2632
|
+
cleanup();
|
|
2633
|
+
} catch (e) {
|
|
2634
|
+
debugError("[gpu] cleanup during failure threw:", e);
|
|
2635
|
+
}
|
|
2636
|
+
if (!hasNotifiedUnavailable && onUnavailableCallback) {
|
|
2637
|
+
hasNotifiedUnavailable = true;
|
|
2638
|
+
const cb = onUnavailableCallback;
|
|
2639
|
+
queueMicrotask(() => {
|
|
2640
|
+
try {
|
|
2641
|
+
cb(reason, error);
|
|
2642
|
+
} catch (e) {
|
|
2643
|
+
debugError("[gpu] onUnavailable callback threw:", e);
|
|
2644
|
+
}
|
|
2645
|
+
});
|
|
2646
|
+
}
|
|
2647
|
+
};
|
|
2648
|
+
const noteRenderFailure = (error) => {
|
|
2649
|
+
if (isGpuUnavailableError(error)) {
|
|
2650
|
+
fail(error.reason, error);
|
|
2651
|
+
return;
|
|
2652
|
+
}
|
|
2653
|
+
consecutiveRenderErrors++;
|
|
2654
|
+
if (consecutiveRenderErrors === 1) debugError("[gpu] render error:", error);
|
|
2655
|
+
if (consecutiveRenderErrors >= MAX_CONSECUTIVE_RENDER_ERRORS) fail("render-failed", error);
|
|
2656
|
+
};
|
|
2657
|
+
const attachUncapturedErrorHandler = (device) => {
|
|
2658
|
+
if (!device || typeof device.addEventListener !== "function") return;
|
|
2659
|
+
detachUncapturedErrorHandler();
|
|
2660
|
+
uncapturedErrorDevice = device;
|
|
2661
|
+
uncapturedErrorHandler = (event) => {
|
|
2662
|
+
try {
|
|
2663
|
+
event.preventDefault();
|
|
2664
|
+
} catch {}
|
|
2665
|
+
const gpuError = event.error;
|
|
2666
|
+
debugError("[gpu] uncaptured device error:", gpuError);
|
|
2667
|
+
if (typeof GPUOutOfMemoryError !== "undefined" && gpuError instanceof GPUOutOfMemoryError) {
|
|
2668
|
+
fail("out-of-memory", gpuError);
|
|
2669
|
+
return;
|
|
2670
|
+
}
|
|
2671
|
+
if (typeof GPUInternalError !== "undefined" && gpuError instanceof GPUInternalError) {
|
|
2672
|
+
fail("gpu-error", gpuError);
|
|
2673
|
+
return;
|
|
2674
|
+
}
|
|
2675
|
+
uncapturedValidationErrors++;
|
|
2676
|
+
if (uncapturedValidationErrors >= MAX_UNCAPTURED_VALIDATION_ERRORS) fail("gpu-error", gpuError);
|
|
2677
|
+
};
|
|
2678
|
+
device.addEventListener("uncapturederror", uncapturedErrorHandler);
|
|
2679
|
+
};
|
|
2680
|
+
const detachUncapturedErrorHandler = () => {
|
|
2681
|
+
if (uncapturedErrorDevice && uncapturedErrorHandler) try {
|
|
2682
|
+
uncapturedErrorDevice.removeEventListener("uncapturederror", uncapturedErrorHandler);
|
|
2683
|
+
} catch {}
|
|
2684
|
+
uncapturedErrorDevice = null;
|
|
2685
|
+
uncapturedErrorHandler = null;
|
|
2686
|
+
};
|
|
2590
2687
|
const fireDeviceLost = (reason) => {
|
|
2591
2688
|
if (deviceLostFired) return;
|
|
2592
2689
|
deviceLostFired = true;
|
|
2593
2690
|
try {
|
|
2594
2691
|
stopAnimation();
|
|
2595
2692
|
} catch {}
|
|
2596
|
-
if (onDeviceLostCallback)
|
|
2597
|
-
|
|
2598
|
-
|
|
2599
|
-
|
|
2600
|
-
|
|
2601
|
-
|
|
2602
|
-
|
|
2693
|
+
if (onDeviceLostCallback) {
|
|
2694
|
+
const cb = onDeviceLostCallback;
|
|
2695
|
+
queueMicrotask(() => {
|
|
2696
|
+
try {
|
|
2697
|
+
cb(reason);
|
|
2698
|
+
} catch (e) {
|
|
2699
|
+
debugError("[gpu] onDeviceLost callback threw:", e);
|
|
2700
|
+
}
|
|
2701
|
+
});
|
|
2702
|
+
return;
|
|
2703
|
+
}
|
|
2704
|
+
fail("device-lost", reason);
|
|
2603
2705
|
};
|
|
2604
2706
|
const initialize = async (options) => {
|
|
2605
2707
|
if (options.context !== void 0) throw new Error("[gpu] initialize({ context }) is not supported — this renderer is WebGPU-only. Remove the WebGL `context` option.");
|
|
2708
|
+
if (failureReason) return;
|
|
2709
|
+
const pageWide = getGpuUnusableReason();
|
|
2710
|
+
if (pageWide) {
|
|
2711
|
+
fail(pageWide);
|
|
2712
|
+
return;
|
|
2713
|
+
}
|
|
2606
2714
|
if (isInitialized || isInitializing) return;
|
|
2607
2715
|
const { canvas, resizeTarget, enablePerformanceTracking: enableTracking = false, colorSpace = "p3-linear", toneMapping = "linear", gpu, forceFullFrameRate: forceFullFps = false, observeElement: shouldObserveElement = true, timeOrigin: initialTimeOrigin } = options;
|
|
2608
2716
|
if (initialTimeOrigin != null) sharedTimeOrigin = initialTimeOrigin;
|
|
@@ -2625,6 +2733,7 @@ function shaderRendererGPU() {
|
|
|
2625
2733
|
});
|
|
2626
2734
|
if (abort.signal.aborted) return;
|
|
2627
2735
|
root = rootCtx.root;
|
|
2736
|
+
attachUncapturedErrorHandler(root.device);
|
|
2628
2737
|
pixelRatio = basePixelRatio();
|
|
2629
2738
|
const lim = root.device.limits?.maxTextureDimension2D;
|
|
2630
2739
|
if (typeof lim === "number" && lim > 0) cachedMaxTextureDim = lim;
|
|
@@ -2688,7 +2797,11 @@ function shaderRendererGPU() {
|
|
|
2688
2797
|
if (currentWidth > 0 && currentHeight > 0) renderFrame();
|
|
2689
2798
|
if (shouldAnimate) startAnimation();
|
|
2690
2799
|
} catch (error) {
|
|
2691
|
-
|
|
2800
|
+
const reason = isGpuUnavailableError(error) ? error.reason : "init-failed";
|
|
2801
|
+
isInitializing = false;
|
|
2802
|
+
if (initializationAbortController === abort) initializationAbortController = null;
|
|
2803
|
+
fail(reason, error);
|
|
2804
|
+
return;
|
|
2692
2805
|
} finally {
|
|
2693
2806
|
isInitializing = false;
|
|
2694
2807
|
if (initializationAbortController === abort) initializationAbortController = null;
|
|
@@ -2721,6 +2834,10 @@ function shaderRendererGPU() {
|
|
|
2721
2834
|
pendingRenderRAF = null;
|
|
2722
2835
|
}
|
|
2723
2836
|
stopAnimation();
|
|
2837
|
+
detachUncapturedErrorHandler();
|
|
2838
|
+
try {
|
|
2839
|
+
rootCtx?.release?.();
|
|
2840
|
+
} catch {}
|
|
2724
2841
|
pipelineCache.clear();
|
|
2725
2842
|
for (const c of [...liveCompositions]) disposeComposition(c);
|
|
2726
2843
|
boundComposition = null;
|
|
@@ -2764,6 +2881,8 @@ function shaderRendererGPU() {
|
|
|
2764
2881
|
firstRenderPending = false;
|
|
2765
2882
|
onDeviceLostCallback = null;
|
|
2766
2883
|
deviceLostFired = false;
|
|
2884
|
+
uncapturedValidationErrors = 0;
|
|
2885
|
+
consecutiveRenderErrors = 0;
|
|
2767
2886
|
};
|
|
2768
2887
|
const getPerformanceStats = () => {
|
|
2769
2888
|
const nodeCount = Math.max(0, nodes.size - 1);
|
|
@@ -2866,6 +2985,21 @@ function shaderRendererGPU() {
|
|
|
2866
2985
|
setOnDeviceLost: (callback) => {
|
|
2867
2986
|
onDeviceLostCallback = callback;
|
|
2868
2987
|
},
|
|
2988
|
+
setOnUnavailable: (callback) => {
|
|
2989
|
+
onUnavailableCallback = callback;
|
|
2990
|
+
if (callback && failureReason && !hasNotifiedUnavailable) {
|
|
2991
|
+
hasNotifiedUnavailable = true;
|
|
2992
|
+
const reason = failureReason;
|
|
2993
|
+
queueMicrotask(() => {
|
|
2994
|
+
try {
|
|
2995
|
+
callback(reason);
|
|
2996
|
+
} catch (e) {
|
|
2997
|
+
debugError("[gpu] onUnavailable callback threw:", e);
|
|
2998
|
+
}
|
|
2999
|
+
});
|
|
3000
|
+
}
|
|
3001
|
+
},
|
|
3002
|
+
getFailureReason: () => failureReason,
|
|
2869
3003
|
__testing: {
|
|
2870
3004
|
needsTransformation,
|
|
2871
3005
|
findChildNodes,
|
|
@@ -2957,12 +3091,12 @@ function createRendererFromJSON(preset, options) {
|
|
|
2957
3091
|
registerPresetNodes();
|
|
2958
3092
|
coreRenderer.stopAnimation();
|
|
2959
3093
|
}
|
|
2960
|
-
async function renderFrame() {
|
|
3094
|
+
async function renderFrame(options$1) {
|
|
2961
3095
|
if (!coreRenderer.isInitialized()) {
|
|
2962
|
-
|
|
3096
|
+
debugWarn("[presetRenderer] Renderer not yet initialized, skipping frame");
|
|
2963
3097
|
return;
|
|
2964
3098
|
}
|
|
2965
|
-
await coreRenderer.renderAndWait();
|
|
3099
|
+
await coreRenderer.renderAndWait(options$1);
|
|
2966
3100
|
}
|
|
2967
3101
|
function updatePreset(newPreset) {
|
|
2968
3102
|
nodeIdMap.forEach((_, nodeId) => {
|
|
@@ -3031,7 +3165,9 @@ function createRendererFromJSON(preset, options) {
|
|
|
3031
3165
|
renderFrame,
|
|
3032
3166
|
updatePreset,
|
|
3033
3167
|
getGPUContext,
|
|
3034
|
-
dispose
|
|
3168
|
+
dispose,
|
|
3169
|
+
setOnUnavailable: coreRenderer.setOnUnavailable,
|
|
3170
|
+
getFailureReason: coreRenderer.getFailureReason
|
|
3035
3171
|
};
|
|
3036
3172
|
}
|
|
3037
3173
|
function resolveMaskDependencies(nodes) {
|
|
@@ -3111,41 +3247,4 @@ const boxLocalToScreenUV = (bx, by, g) => {
|
|
|
3111
3247
|
y: sqy + g.centerY
|
|
3112
3248
|
};
|
|
3113
3249
|
};
|
|
3114
|
-
|
|
3115
|
-
x: {
|
|
3116
|
-
value: 0,
|
|
3117
|
-
unit: "uv"
|
|
3118
|
-
},
|
|
3119
|
-
y: {
|
|
3120
|
-
value: 0,
|
|
3121
|
-
unit: "uv"
|
|
3122
|
-
},
|
|
3123
|
-
width: {
|
|
3124
|
-
value: 1,
|
|
3125
|
-
unit: "uv"
|
|
3126
|
-
},
|
|
3127
|
-
height: {
|
|
3128
|
-
value: 1,
|
|
3129
|
-
unit: "uv"
|
|
3130
|
-
},
|
|
3131
|
-
origin: "top-left",
|
|
3132
|
-
rotation: 0
|
|
3133
|
-
};
|
|
3134
|
-
function resolveBoundingBox(bbox) {
|
|
3135
|
-
if (!bbox || typeof bbox !== "object") return void 0;
|
|
3136
|
-
const dim = (d$1, fallback) => d$1 && typeof d$1 === "object" ? {
|
|
3137
|
-
value: d$1.value ?? fallback.value,
|
|
3138
|
-
unit: d$1.unit ?? fallback.unit
|
|
3139
|
-
} : { ...fallback };
|
|
3140
|
-
return {
|
|
3141
|
-
x: dim(bbox.x, DEFAULT_BOUNDING_BOX.x),
|
|
3142
|
-
y: dim(bbox.y, DEFAULT_BOUNDING_BOX.y),
|
|
3143
|
-
width: dim(bbox.width, DEFAULT_BOUNDING_BOX.width),
|
|
3144
|
-
height: dim(bbox.height, DEFAULT_BOUNDING_BOX.height),
|
|
3145
|
-
origin: bbox.origin ?? "top-left",
|
|
3146
|
-
rotation: bbox.rotation ?? 0,
|
|
3147
|
-
...bbox.cornerRadius ? { cornerRadius: bbox.cornerRadius } : {},
|
|
3148
|
-
...bbox.lockAspect !== void 0 ? { lockAspect: bbox.lockAspect } : {}
|
|
3149
|
-
};
|
|
3150
|
-
}
|
|
3151
|
-
export { DEFAULT_BOUNDING_BOX, MAX_COLOR_STOPS, SHAPE3D_DEFAULTS, SHAPE3D_TYPES, SVG3D_DEFAULTS, SVG3D_TYPES, boxLocalToScreenUV, createGpuUniformsMap, createRendererFromJSON, is3dShapeType, isDimensionalValue, isSvg3dShapeType, isVolumetricShapeType, resolveBoundingBox, resolveMaskDependencies, resolveStops, rootPassthrough, screenUVToBoxLocal, shaderRendererGPU, shape3dBoundingRadius, sortStops };
|
|
3250
|
+
export { DEFAULT_BOUNDING_BOX, GpuUnavailableError, MAX_COLOR_STOPS, SHAPE3D_DEFAULTS, SHAPE3D_TYPES, SVG3D_DEFAULTS, SVG3D_TYPES, boxLocalToScreenUV, createGpuUniformsMap, createRendererFromJSON, debugError, debugWarn, destroyDefaultGpuDevice, getWebGPUSupport, is3dShapeType, isDimensionalValue, isGpuUnavailableError, isShadersDebug, isSvg3dShapeType, isVolumetricShapeType, isWebGPUSupported, resolveBoundingBox, resolveMaskDependencies, resolveStops, rootPassthrough, screenUVToBoxLocal, setShadersDebug, shaderRendererGPU, shape3dBoundingRadius, sortStops };
|