@3driseai/3drise-viewer 0.1.26 → 0.1.28
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/animationsV2/ClipPlayer.d.ts +3 -0
- package/dist/animationsV2/ClipPlayer.d.ts.map +1 -1
- package/dist/animationsV2/ClipPlayer.js +67 -8
- package/dist/animationsV2/ClipsRuntime.d.ts +39 -0
- package/dist/animationsV2/ClipsRuntime.d.ts.map +1 -1
- package/dist/animationsV2/ClipsRuntime.js +245 -14
- package/dist/animationsV2/appliers.d.ts +5 -0
- package/dist/animationsV2/appliers.d.ts.map +1 -1
- package/dist/animationsV2/appliers.js +25 -7
- package/dist/animationsV2/index.d.ts +1 -1
- package/dist/animationsV2/index.d.ts.map +1 -1
- package/dist/animationsV2/normalize.d.ts.map +1 -1
- package/dist/animationsV2/normalize.js +18 -7
- package/dist/animationsV2/sequenceUtils.d.ts +42 -1
- package/dist/animationsV2/sequenceUtils.d.ts.map +1 -1
- package/dist/animationsV2/sequenceUtils.js +103 -3
- package/dist/animationsV2/types.d.ts +20 -0
- package/dist/animationsV2/types.d.ts.map +1 -1
- package/dist/components/AdvancedGrid.d.ts +8 -2
- package/dist/components/AdvancedGrid.d.ts.map +1 -1
- package/dist/components/AdvancedGrid.js +31 -14
- package/dist/components/AnimatedObject.d.ts.map +1 -1
- package/dist/components/AnimatedObject.js +7 -5
- package/dist/components/ApollonianGrid.d.ts +25 -0
- package/dist/components/ApollonianGrid.d.ts.map +1 -0
- package/dist/components/ApollonianGrid.js +80 -0
- package/dist/components/Bubbles.d.ts +7 -1
- package/dist/components/Bubbles.d.ts.map +1 -1
- package/dist/components/Bubbles.js +42 -22
- package/dist/components/ChladniGrid.d.ts +8 -4
- package/dist/components/ChladniGrid.d.ts.map +1 -1
- package/dist/components/ChladniGrid.js +31 -13
- package/dist/components/CircuitGrid.d.ts +8 -11
- package/dist/components/CircuitGrid.d.ts.map +1 -1
- package/dist/components/CircuitGrid.js +31 -13
- package/dist/components/CloudsGenerator.d.ts +1 -1
- package/dist/components/CloudsGenerator.js +1 -1
- package/dist/components/ConformalGrid.d.ts +25 -0
- package/dist/components/ConformalGrid.d.ts.map +1 -0
- package/dist/components/ConformalGrid.js +97 -0
- package/dist/components/ContourGrid.d.ts +8 -14
- package/dist/components/ContourGrid.d.ts.map +1 -1
- package/dist/components/ContourGrid.js +31 -13
- package/dist/components/EffectsGenerator.d.ts +7 -1
- package/dist/components/EffectsGenerator.d.ts.map +1 -1
- package/dist/components/EffectsGenerator.js +39 -38
- package/dist/components/EnvironmentManager.d.ts +4 -4
- package/dist/components/EnvironmentManager.d.ts.map +1 -1
- package/dist/components/FlowNetGrid.d.ts +8 -4
- package/dist/components/FlowNetGrid.d.ts.map +1 -1
- package/dist/components/FlowNetGrid.js +31 -13
- package/dist/components/FractalGrid.d.ts +8 -12
- package/dist/components/FractalGrid.d.ts.map +1 -1
- package/dist/components/FractalGrid.js +31 -13
- package/dist/components/GirihGrid.d.ts +8 -1
- package/dist/components/GirihGrid.d.ts.map +1 -1
- package/dist/components/GirihGrid.js +31 -13
- package/dist/components/Glyphs.d.ts +7 -1
- package/dist/components/Glyphs.d.ts.map +1 -1
- package/dist/components/Glyphs.js +40 -34
- package/dist/components/GravWaveGrid.d.ts +8 -1
- package/dist/components/GravWaveGrid.d.ts.map +1 -1
- package/dist/components/GravWaveGrid.js +31 -13
- package/dist/components/GridsGenerator.d.ts +9 -3
- package/dist/components/GridsGenerator.d.ts.map +1 -1
- package/dist/components/GridsGenerator.js +41 -18
- package/dist/components/HexGrid.d.ts +8 -10
- package/dist/components/HexGrid.d.ts.map +1 -1
- package/dist/components/HexGrid.js +31 -13
- package/dist/components/HilbertGrid.d.ts +25 -0
- package/dist/components/HilbertGrid.d.ts.map +1 -0
- package/dist/components/HilbertGrid.js +93 -0
- package/dist/components/HyperbolicGrid.d.ts +8 -4
- package/dist/components/HyperbolicGrid.d.ts.map +1 -1
- package/dist/components/HyperbolicGrid.js +31 -13
- package/dist/components/LandscapeBuilder.d.ts +1 -1
- package/dist/components/LandscapeBuilder.d.ts.map +1 -1
- package/dist/components/LandscapeBuilder.js +1 -1
- package/dist/components/LandscapeObject.d.ts +1 -1
- package/dist/components/LandscapeObject.d.ts.map +1 -1
- package/dist/components/LandscapeObject.js +1 -1
- package/dist/components/LensingGrid.d.ts +25 -0
- package/dist/components/LensingGrid.d.ts.map +1 -0
- package/dist/components/LensingGrid.js +81 -0
- package/dist/components/MoireGrid.d.ts +8 -12
- package/dist/components/MoireGrid.d.ts.map +1 -1
- package/dist/components/MoireGrid.js +31 -13
- package/dist/components/ObjectNode.d.ts.map +1 -1
- package/dist/components/ObjectNode.js +2 -2
- package/dist/components/ObjectsRenderer.d.ts.map +1 -1
- package/dist/components/ObjectsRenderer.js +37 -3
- package/dist/components/OceanBuilder.d.ts +1 -1
- package/dist/components/OceanBuilder.js +1 -1
- package/dist/components/ParastichyGrid.d.ts +25 -0
- package/dist/components/ParastichyGrid.d.ts.map +1 -0
- package/dist/components/ParastichyGrid.js +82 -0
- package/dist/components/ParticlesGenerator.d.ts.map +1 -1
- package/dist/components/ParticlesGenerator.js +6 -0
- package/dist/components/PhyllotaxisGrid.d.ts +25 -0
- package/dist/components/PhyllotaxisGrid.d.ts.map +1 -0
- package/dist/components/PhyllotaxisGrid.js +95 -0
- package/dist/components/QuasiGrid.d.ts +8 -11
- package/dist/components/QuasiGrid.d.ts.map +1 -1
- package/dist/components/QuasiGrid.js +31 -13
- package/dist/components/RadarGrid.d.ts +8 -13
- package/dist/components/RadarGrid.d.ts.map +1 -1
- package/dist/components/RadarGrid.js +31 -13
- package/dist/components/ReactionDiffusionGrid.d.ts +8 -1
- package/dist/components/ReactionDiffusionGrid.d.ts.map +1 -1
- package/dist/components/ReactionDiffusionGrid.js +33 -139
- package/dist/components/SceneBuilder.js +1 -1
- package/dist/components/SkySystem.d.ts +1 -1
- package/dist/components/SparklesBurst.d.ts +7 -1
- package/dist/components/SparklesBurst.d.ts.map +1 -1
- package/dist/components/SparklesBurst.js +31 -28
- package/dist/components/TerrainBuilder.d.ts +1 -1
- package/dist/components/TerrainBuilder.d.ts.map +1 -1
- package/dist/components/TerrainBuilder.js +1 -1
- package/dist/components/TruchetGrid.d.ts +25 -0
- package/dist/components/TruchetGrid.d.ts.map +1 -0
- package/dist/components/TruchetGrid.js +82 -0
- package/dist/components/VoronoiGrid.d.ts +8 -10
- package/dist/components/VoronoiGrid.d.ts.map +1 -1
- package/dist/components/VoronoiGrid.js +31 -13
- package/dist/components/WallpaperGrid.d.ts +8 -1
- package/dist/components/WallpaperGrid.d.ts.map +1 -1
- package/dist/components/WallpaperGrid.js +33 -210
- package/dist/components/effects/AuraEffect.d.ts +8 -3
- package/dist/components/effects/AuraEffect.d.ts.map +1 -1
- package/dist/components/effects/AuraEffect.js +49 -24
- package/dist/components/effects/AuroraEffect.d.ts +8 -3
- package/dist/components/effects/AuroraEffect.d.ts.map +1 -1
- package/dist/components/effects/AuroraEffect.js +45 -25
- package/dist/components/effects/BlackHoleEffect.d.ts +8 -3
- package/dist/components/effects/BlackHoleEffect.d.ts.map +1 -1
- package/dist/components/effects/BlackHoleEffect.js +42 -21
- package/dist/components/effects/ConstellationEffect.d.ts +8 -3
- package/dist/components/effects/ConstellationEffect.d.ts.map +1 -1
- package/dist/components/effects/ConstellationEffect.js +49 -23
- package/dist/components/effects/DandelionSeedsEffect.d.ts +7 -2
- package/dist/components/effects/DandelionSeedsEffect.d.ts.map +1 -1
- package/dist/components/effects/DandelionSeedsEffect.js +19 -9
- package/dist/components/effects/DataStreamEffect.d.ts +8 -3
- package/dist/components/effects/DataStreamEffect.d.ts.map +1 -1
- package/dist/components/effects/DataStreamEffect.js +54 -26
- package/dist/components/effects/DnaHelixEffect.d.ts +8 -3
- package/dist/components/effects/DnaHelixEffect.d.ts.map +1 -1
- package/dist/components/effects/DnaHelixEffect.js +62 -30
- package/dist/components/effects/FallingLeavesEffect.d.ts +7 -2
- package/dist/components/effects/FallingLeavesEffect.d.ts.map +1 -1
- package/dist/components/effects/FallingLeavesEffect.js +19 -9
- package/dist/components/effects/FieldLinesEffect.d.ts +8 -3
- package/dist/components/effects/FieldLinesEffect.d.ts.map +1 -1
- package/dist/components/effects/FieldLinesEffect.js +30 -20
- package/dist/components/effects/Fire.d.ts +8 -3
- package/dist/components/effects/Fire.d.ts.map +1 -1
- package/dist/components/effects/Fire.js +47 -10
- package/dist/components/effects/FireflySwarmEffect.d.ts +7 -2
- package/dist/components/effects/FireflySwarmEffect.d.ts.map +1 -1
- package/dist/components/effects/FireflySwarmEffect.js +19 -9
- package/dist/components/effects/Flares.d.ts +10 -3
- package/dist/components/effects/Flares.d.ts.map +1 -1
- package/dist/components/effects/Flares.js +53 -56
- package/dist/components/effects/ForcefieldEffect.d.ts +8 -3
- package/dist/components/effects/ForcefieldEffect.d.ts.map +1 -1
- package/dist/components/effects/ForcefieldEffect.js +52 -33
- package/dist/components/effects/GalaxyEffect.d.ts +7 -2
- package/dist/components/effects/GalaxyEffect.d.ts.map +1 -1
- package/dist/components/effects/GalaxyEffect.js +19 -9
- package/dist/components/effects/HarmonicShellEffect.d.ts +8 -3
- package/dist/components/effects/HarmonicShellEffect.d.ts.map +1 -1
- package/dist/components/effects/HarmonicShellEffect.js +30 -22
- package/dist/components/effects/HologramEffect.d.ts +8 -3
- package/dist/components/effects/HologramEffect.d.ts.map +1 -1
- package/dist/components/effects/HologramEffect.js +52 -23
- package/dist/components/effects/IceCrystalsEffect.d.ts +8 -3
- package/dist/components/effects/IceCrystalsEffect.d.ts.map +1 -1
- package/dist/components/effects/IceCrystalsEffect.js +36 -21
- package/dist/components/effects/IceHaloEffect.d.ts +7 -2
- package/dist/components/effects/IceHaloEffect.d.ts.map +1 -1
- package/dist/components/effects/IceHaloEffect.js +19 -9
- package/dist/components/effects/LichtenbergEffect.d.ts +7 -2
- package/dist/components/effects/LichtenbergEffect.d.ts.map +1 -1
- package/dist/components/effects/LichtenbergEffect.js +19 -9
- package/dist/components/effects/LightningEffect.d.ts +8 -3
- package/dist/components/effects/LightningEffect.d.ts.map +1 -1
- package/dist/components/effects/LightningEffect.js +54 -32
- package/dist/components/effects/MoleculesEffect.d.ts +8 -3
- package/dist/components/effects/MoleculesEffect.d.ts.map +1 -1
- package/dist/components/effects/MoleculesEffect.js +31 -21
- package/dist/components/effects/MurmurationEffect.d.ts +7 -2
- package/dist/components/effects/MurmurationEffect.d.ts.map +1 -1
- package/dist/components/effects/MurmurationEffect.js +19 -9
- package/dist/components/effects/NeuralNetworkEffect.d.ts +8 -3
- package/dist/components/effects/NeuralNetworkEffect.d.ts.map +1 -1
- package/dist/components/effects/NeuralNetworkEffect.js +66 -33
- package/dist/components/effects/OrbEffect.d.ts +8 -3
- package/dist/components/effects/OrbEffect.d.ts.map +1 -1
- package/dist/components/effects/OrbEffect.js +89 -42
- package/dist/components/effects/PlanetaryRingsEffect.d.ts +7 -2
- package/dist/components/effects/PlanetaryRingsEffect.d.ts.map +1 -1
- package/dist/components/effects/PlanetaryRingsEffect.js +19 -9
- package/dist/components/effects/PortalEffect.d.ts +8 -3
- package/dist/components/effects/PortalEffect.d.ts.map +1 -1
- package/dist/components/effects/PortalEffect.js +41 -25
- package/dist/components/effects/ShockwaveEffect.d.ts +7 -2
- package/dist/components/effects/ShockwaveEffect.d.ts.map +1 -1
- package/dist/components/effects/ShockwaveEffect.js +19 -9
- package/dist/components/effects/SmokePlumeEffect.d.ts +8 -3
- package/dist/components/effects/SmokePlumeEffect.d.ts.map +1 -1
- package/dist/components/effects/SmokePlumeEffect.js +30 -20
- package/dist/components/effects/SmokeRibbon.d.ts +8 -2
- package/dist/components/effects/SmokeRibbon.d.ts.map +1 -1
- package/dist/components/effects/SmokeRibbon.js +34 -24
- package/dist/components/effects/SmokeRingEffect.d.ts +8 -3
- package/dist/components/effects/SmokeRingEffect.d.ts.map +1 -1
- package/dist/components/effects/SmokeRingEffect.js +33 -21
- package/dist/components/effects/StrangeAttractorEffect.d.ts +8 -3
- package/dist/components/effects/StrangeAttractorEffect.d.ts.map +1 -1
- package/dist/components/effects/StrangeAttractorEffect.js +30 -20
- package/dist/components/effects/VolumetricFogEffect.d.ts +8 -3
- package/dist/components/effects/VolumetricFogEffect.d.ts.map +1 -1
- package/dist/components/effects/VolumetricFogEffect.js +38 -20
- package/dist/components/effects/WaterCausticsEffect.d.ts +7 -2
- package/dist/components/effects/WaterCausticsEffect.d.ts.map +1 -1
- package/dist/components/effects/WaterCausticsEffect.js +19 -9
- package/dist/components/effects/index.d.ts +0 -1
- package/dist/components/effects/index.d.ts.map +1 -1
- package/dist/components/effects/index.js +0 -1
- package/dist/components/index.d.ts +14 -1
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +7 -1
- package/dist/components/landscape/LandscapeMesh.js +1 -1
- package/dist/components/landscape/types.d.ts +1 -1
- package/dist/components/landscape/types.d.ts.map +1 -1
- package/dist/components/particles/MagneticBottleParticles.d.ts +17 -0
- package/dist/components/particles/MagneticBottleParticles.d.ts.map +1 -0
- package/dist/components/particles/MagneticBottleParticles.js +618 -0
- package/dist/components/particles/ShapeBurstParticles.d.ts +17 -0
- package/dist/components/particles/ShapeBurstParticles.d.ts.map +1 -0
- package/dist/components/particles/ShapeBurstParticles.js +588 -0
- package/dist/components/particles/ShapeFlowParticles.d.ts +17 -0
- package/dist/components/particles/ShapeFlowParticles.d.ts.map +1 -0
- package/dist/components/particles/ShapeFlowParticles.js +755 -0
- package/dist/components/particles/index.d.ts +6 -0
- package/dist/components/particles/index.d.ts.map +1 -1
- package/dist/components/particles/index.js +3 -0
- package/dist/components/terrain/types.d.ts +1 -1
- package/dist/components/terrain/types.d.ts.map +1 -1
- package/dist/components/volumetricClouds/VolumetricCloudsPass.d.ts +1 -1
- package/dist/components/volumetricClouds/VolumetricCloudsPass.d.ts.map +1 -1
- package/dist/components/volumetricClouds/types.d.ts +1 -1
- package/dist/components/volumetricClouds/types.d.ts.map +1 -1
- package/dist/components/water/types.d.ts +1 -1
- package/dist/components/water/types.d.ts.map +1 -1
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/hooks/index.js +1 -0
- package/dist/hooks/useConfigDriver.d.ts +22 -0
- package/dist/hooks/useConfigDriver.d.ts.map +1 -0
- package/dist/hooks/useConfigDriver.js +43 -0
- package/dist/hooks/useConfigLive.d.ts +1 -1
- package/dist/hooks/useConfigLive.d.ts.map +1 -1
- package/dist/hooks/useLandscapeMaps.d.ts +1 -1
- package/dist/hooks/useLandscapeMaps.d.ts.map +1 -1
- package/dist/hooks/useOceanMaterial.d.ts +1 -1
- package/dist/hooks/useThunder.d.ts +1 -1
- package/dist/index.d.ts +1 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -2
- package/dist/interactions/index.d.ts +2 -1
- package/dist/interactions/index.d.ts.map +1 -1
- package/dist/interactions/index.js +1 -1
- package/dist/interactions/runner.d.ts +18 -3
- package/dist/interactions/runner.d.ts.map +1 -1
- package/dist/interactions/runner.js +25 -2
- package/dist/operations/catalogue/curlSmoke.d.ts +3 -0
- package/dist/operations/catalogue/curlSmoke.d.ts.map +1 -0
- package/dist/operations/catalogue/curlSmoke.js +178 -0
- package/dist/operations/catalogue/displayImage.d.ts.map +1 -1
- package/dist/operations/catalogue/displayImage.js +1 -0
- package/dist/operations/catalogue/dissolve.d.ts +3 -0
- package/dist/operations/catalogue/dissolve.d.ts.map +1 -0
- package/dist/operations/catalogue/dissolve.js +57 -0
- package/dist/operations/catalogue/emberAsh.d.ts +3 -0
- package/dist/operations/catalogue/emberAsh.d.ts.map +1 -0
- package/dist/operations/catalogue/emberAsh.js +171 -0
- package/dist/operations/catalogue/fade.d.ts.map +1 -1
- package/dist/operations/catalogue/fade.js +1 -0
- package/dist/operations/catalogue/flip.d.ts +3 -0
- package/dist/operations/catalogue/flip.d.ts.map +1 -0
- package/dist/operations/catalogue/flip.js +69 -0
- package/dist/operations/catalogue/flock.d.ts +3 -0
- package/dist/operations/catalogue/flock.d.ts.map +1 -0
- package/dist/operations/catalogue/flock.js +163 -0
- package/dist/operations/catalogue/focus.d.ts.map +1 -1
- package/dist/operations/catalogue/focus.js +1 -0
- package/dist/operations/catalogue/frame.d.ts +3 -0
- package/dist/operations/catalogue/frame.d.ts.map +1 -0
- package/dist/operations/catalogue/frame.js +44 -0
- package/dist/operations/catalogue/frost.d.ts +3 -0
- package/dist/operations/catalogue/frost.d.ts.map +1 -0
- package/dist/operations/catalogue/frost.js +111 -0
- package/dist/operations/catalogue/fxInstances.d.ts +21 -0
- package/dist/operations/catalogue/fxInstances.d.ts.map +1 -0
- package/dist/operations/catalogue/fxInstances.js +47 -0
- package/dist/operations/catalogue/fxPoints.d.ts +22 -0
- package/dist/operations/catalogue/fxPoints.d.ts.map +1 -0
- package/dist/operations/catalogue/fxPoints.js +70 -0
- package/dist/operations/catalogue/glow.d.ts.map +1 -1
- package/dist/operations/catalogue/glow.js +2 -1
- package/dist/operations/catalogue/heatCracks.d.ts +3 -0
- package/dist/operations/catalogue/heatCracks.d.ts.map +1 -0
- package/dist/operations/catalogue/heatCracks.js +134 -0
- package/dist/operations/catalogue/hologram.d.ts +3 -0
- package/dist/operations/catalogue/hologram.d.ts.map +1 -0
- package/dist/operations/catalogue/hologram.js +118 -0
- package/dist/operations/catalogue/inkBloom.d.ts +3 -0
- package/dist/operations/catalogue/inkBloom.d.ts.map +1 -0
- package/dist/operations/catalogue/inkBloom.js +156 -0
- package/dist/operations/catalogue/ivy.d.ts +13 -0
- package/dist/operations/catalogue/ivy.d.ts.map +1 -0
- package/dist/operations/catalogue/ivy.js +469 -0
- package/dist/operations/catalogue/jelly.d.ts +3 -0
- package/dist/operations/catalogue/jelly.d.ts.map +1 -0
- package/dist/operations/catalogue/jelly.js +50 -0
- package/dist/operations/catalogue/kintsugi.d.ts +3 -0
- package/dist/operations/catalogue/kintsugi.d.ts.map +1 -0
- package/dist/operations/catalogue/kintsugi.js +173 -0
- package/dist/operations/catalogue/lidarScan.d.ts +3 -0
- package/dist/operations/catalogue/lidarScan.d.ts.map +1 -0
- package/dist/operations/catalogue/lidarScan.js +240 -0
- package/dist/operations/catalogue/liquidMetal.d.ts +3 -0
- package/dist/operations/catalogue/liquidMetal.d.ts.map +1 -0
- package/dist/operations/catalogue/liquidMetal.js +122 -0
- package/dist/operations/catalogue/metalize.d.ts +3 -0
- package/dist/operations/catalogue/metalize.d.ts.map +1 -0
- package/dist/operations/catalogue/metalize.js +135 -0
- package/dist/operations/catalogue/moveToFront.d.ts.map +1 -1
- package/dist/operations/catalogue/moveToFront.js +1 -0
- package/dist/operations/catalogue/orbit.d.ts +3 -0
- package/dist/operations/catalogue/orbit.d.ts.map +1 -0
- package/dist/operations/catalogue/orbit.js +29 -0
- package/dist/operations/catalogue/particleSwarm.d.ts +3 -0
- package/dist/operations/catalogue/particleSwarm.d.ts.map +1 -0
- package/dist/operations/catalogue/particleSwarm.js +138 -0
- package/dist/operations/catalogue/petalPeel.d.ts +3 -0
- package/dist/operations/catalogue/petalPeel.d.ts.map +1 -0
- package/dist/operations/catalogue/petalPeel.js +137 -0
- package/dist/operations/catalogue/petrify.d.ts +3 -0
- package/dist/operations/catalogue/petrify.d.ts.map +1 -0
- package/dist/operations/catalogue/petrify.js +94 -0
- package/dist/operations/catalogue/portal.d.ts +3 -0
- package/dist/operations/catalogue/portal.d.ts.map +1 -0
- package/dist/operations/catalogue/portal.js +224 -0
- package/dist/operations/catalogue/print3d.d.ts +3 -0
- package/dist/operations/catalogue/print3d.d.ts.map +1 -0
- package/dist/operations/catalogue/print3d.js +275 -0
- package/dist/operations/catalogue/rainBeads.d.ts +3 -0
- package/dist/operations/catalogue/rainBeads.d.ts.map +1 -0
- package/dist/operations/catalogue/rainBeads.js +223 -0
- package/dist/operations/catalogue/restPose.d.ts +21 -0
- package/dist/operations/catalogue/restPose.d.ts.map +1 -0
- package/dist/operations/catalogue/restPose.js +55 -0
- package/dist/operations/catalogue/rimLight.d.ts +3 -0
- package/dist/operations/catalogue/rimLight.d.ts.map +1 -0
- package/dist/operations/catalogue/rimLight.js +72 -0
- package/dist/operations/catalogue/sandErosion.d.ts +3 -0
- package/dist/operations/catalogue/sandErosion.d.ts.map +1 -0
- package/dist/operations/catalogue/sandErosion.js +167 -0
- package/dist/operations/catalogue/shaderLayers.d.ts +74 -0
- package/dist/operations/catalogue/shaderLayers.d.ts.map +1 -0
- package/dist/operations/catalogue/shaderLayers.js +322 -0
- package/dist/operations/catalogue/shatter.d.ts +3 -0
- package/dist/operations/catalogue/shatter.d.ts.map +1 -0
- package/dist/operations/catalogue/shatter.js +267 -0
- package/dist/operations/catalogue/silkDrape.d.ts +3 -0
- package/dist/operations/catalogue/silkDrape.d.ts.map +1 -0
- package/dist/operations/catalogue/silkDrape.js +340 -0
- package/dist/operations/catalogue/spin.d.ts +3 -0
- package/dist/operations/catalogue/spin.d.ts.map +1 -0
- package/dist/operations/catalogue/spin.js +42 -0
- package/dist/operations/catalogue/surfaceSample.d.ts +17 -0
- package/dist/operations/catalogue/surfaceSample.d.ts.map +1 -0
- package/dist/operations/catalogue/surfaceSample.js +187 -0
- package/dist/operations/catalogue/swirl.d.ts +3 -0
- package/dist/operations/catalogue/swirl.d.ts.map +1 -0
- package/dist/operations/catalogue/swirl.js +69 -0
- package/dist/operations/catalogue/teleport.d.ts +3 -0
- package/dist/operations/catalogue/teleport.d.ts.map +1 -0
- package/dist/operations/catalogue/teleport.js +213 -0
- package/dist/operations/catalogue/transitionField.d.ts +124 -0
- package/dist/operations/catalogue/transitionField.d.ts.map +1 -0
- package/dist/operations/catalogue/transitionField.js +278 -0
- package/dist/operations/catalogue/unweave.d.ts +3 -0
- package/dist/operations/catalogue/unweave.d.ts.map +1 -0
- package/dist/operations/catalogue/unweave.js +233 -0
- package/dist/operations/catalogue/visibility.d.ts.map +1 -1
- package/dist/operations/catalogue/visibility.js +1 -0
- package/dist/operations/catalogue/voxelize.d.ts +3 -0
- package/dist/operations/catalogue/voxelize.d.ts.map +1 -0
- package/dist/operations/catalogue/voxelize.js +148 -0
- package/dist/operations/catalogue/warmup.d.ts +22 -0
- package/dist/operations/catalogue/warmup.d.ts.map +1 -0
- package/dist/operations/catalogue/warmup.js +106 -0
- package/dist/operations/catalogue/zoom.d.ts.map +1 -1
- package/dist/operations/catalogue/zoom.js +1 -0
- package/dist/operations/index.d.ts +4 -2
- package/dist/operations/index.d.ts.map +1 -1
- package/dist/operations/index.js +4 -2
- package/dist/operations/objectEffects.d.ts +46 -0
- package/dist/operations/objectEffects.d.ts.map +1 -0
- package/dist/operations/objectEffects.js +136 -0
- package/dist/operations/registry.d.ts +7 -2
- package/dist/operations/registry.d.ts.map +1 -1
- package/dist/operations/registry.js +45 -3
- package/dist/operations/runtime.d.ts +40 -2
- package/dist/operations/runtime.d.ts.map +1 -1
- package/dist/operations/runtime.js +164 -8
- package/dist/operations/types.d.ts +29 -3
- package/dist/operations/types.d.ts.map +1 -1
- package/dist/operations/types.js +6 -0
- package/dist/operations/useObjectEffectLayers.d.ts +4 -0
- package/dist/operations/useObjectEffectLayers.d.ts.map +1 -0
- package/dist/operations/useObjectEffectLayers.js +42 -0
- package/dist/operations/useOperationsRuntime.d.ts.map +1 -1
- package/dist/operations/useOperationsRuntime.js +42 -4
- package/dist/presets/landscapePresets.d.ts +1 -1
- package/dist/presets/landscapePresets.d.ts.map +1 -1
- package/dist/presets/landscapePresets.js +1 -1
- package/dist/presets/landscapeTypes.d.ts +1 -1
- package/dist/presets/landscapeTypes.d.ts.map +1 -1
- package/dist/presets/landscapeTypes.js +1 -1
- package/dist/presets/oceanSurfacePresets.d.ts +1 -1
- package/dist/presets/terrainPresets.d.ts +1 -1
- package/dist/presets/terrainPresets.d.ts.map +1 -1
- package/dist/presets/volumetricCloudPresets.d.ts +1 -1
- package/dist/types/cloudConfigs.d.ts +2 -309
- package/dist/types/cloudConfigs.d.ts.map +1 -1
- package/dist/types/cloudConfigs.js +2 -339
- package/dist/types/gridConfigs.d.ts +103 -0
- package/dist/types/gridConfigs.d.ts.map +1 -1
- package/dist/types/index.d.ts +9 -9
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js +4 -4
- package/dist/types/landscapeConfigs.d.ts +2 -217
- package/dist/types/landscapeConfigs.d.ts.map +1 -1
- package/dist/types/landscapeConfigs.js +2 -256
- package/dist/types/oceanConfigs.d.ts +2 -289
- package/dist/types/oceanConfigs.d.ts.map +1 -1
- package/dist/types/oceanConfigs.js +2 -380
- package/dist/types/terrainConfigs.d.ts +2 -250
- package/dist/types/terrainConfigs.d.ts.map +1 -1
- package/dist/types/terrainConfigs.js +2 -292
- package/dist/utils/cloudUniforms.d.ts +1 -1
- package/dist/utils/configAnimations.d.ts +6 -0
- package/dist/utils/configAnimations.d.ts.map +1 -1
- package/dist/utils/configAnimations.js +14 -0
- package/dist/utils/gridConfig.d.ts +19 -0
- package/dist/utils/gridConfig.d.ts.map +1 -0
- package/dist/utils/gridConfig.js +52 -0
- package/dist/utils/handleCloudsAnimations.d.ts +1 -1
- package/dist/utils/handleCloudsAnimations.js +1 -1
- package/dist/utils/hasHoverAnimation.d.ts.map +1 -1
- package/dist/utils/hasHoverAnimation.js +0 -2
- package/dist/utils/landscapeUniforms.d.ts +1 -1
- package/dist/utils/landscapeUniforms.d.ts.map +1 -1
- package/dist/utils/oceanUniforms.d.ts +1 -1
- package/dist/utils/particleShape.d.ts +33 -0
- package/dist/utils/particleShape.d.ts.map +1 -0
- package/dist/utils/particleShape.js +207 -0
- package/dist/utils/particleTrails.d.ts.map +1 -1
- package/dist/utils/particleTrails.js +29 -14
- package/dist/utils/terrainUniforms.d.ts +1 -1
- package/dist/utils/terrainUniforms.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -1,218 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
* from a heightmap and textured through splat maps.
|
|
4
|
-
*
|
|
5
|
-
* This is NOT a mode of the procedural terrain and does not share a config with
|
|
6
|
-
* it. Terrain is an infinite camera-following clipmap generated from noise; a
|
|
7
|
-
* landscape is a finite tile whose shape and materials the user supplies. Both
|
|
8
|
-
* may be enabled in one scene; nothing here reads `terrainConfigs`.
|
|
9
|
-
*
|
|
10
|
-
* Declared in the viewer, next to the material that consumes it, for the same
|
|
11
|
-
* reason `terrainConfigs` and `oceanConfigs` are.
|
|
12
|
-
*/
|
|
13
|
-
/** Where a landscape is mounted. */
|
|
14
|
-
export type LandscapeHost = 'ground' | 'object';
|
|
15
|
-
/** How the heightmap's pixels encode elevation. */
|
|
16
|
-
export type HeightEncoding =
|
|
17
|
-
/** 8-bit red channel, 0..1. The common PNG export. */
|
|
18
|
-
'grayscale'
|
|
19
|
-
/** Mapbox / AWS Terrain-RGB: (r*65536 + g*256 + b) / 10 - 10000, in metres. */
|
|
20
|
-
| 'terrain-rgb'
|
|
21
|
-
/** Red and green as a 16-bit big-endian pair, 0..1. */
|
|
22
|
-
| 'rg16';
|
|
23
|
-
/** Where surface weights come from. */
|
|
24
|
-
export type SplatSource =
|
|
25
|
-
/** Authored splat maps, up to two, RGBA = four surfaces each. */
|
|
26
|
-
'maps'
|
|
27
|
-
/** Generated from the heightmap's own height and slope. */
|
|
28
|
-
| 'auto';
|
|
29
|
-
/**
|
|
30
|
-
* One material layer on the ground.
|
|
31
|
-
*
|
|
32
|
-
* `displacement` is the layer's own height map and it is what makes transitions
|
|
33
|
-
* read as material rather than as a cross-fade: at a boundary the higher surface
|
|
34
|
-
* wins per texel, so gravel comes through grass along the gravel's own grain.
|
|
35
|
-
* The reference project accepts this texture and never samples it.
|
|
36
|
-
*/
|
|
37
|
-
export interface LandscapeSurface {
|
|
38
|
-
/** Panel label only; the renderer never reads it. */
|
|
39
|
-
name: string;
|
|
40
|
-
/** Albedo. Required — a surface with no diffuse is skipped. */
|
|
41
|
-
diffuse: string;
|
|
42
|
-
/** Tangent-space normal map. Optional. */
|
|
43
|
-
normal?: string;
|
|
44
|
-
/** Height map for the height blend and, later, parallax. Optional; absent
|
|
45
|
-
* layers blend linearly, which is what the reference always does. */
|
|
46
|
-
displacement?: string;
|
|
47
|
-
/** How many times the texture tiles across the whole landscape. */
|
|
48
|
-
repeat: number;
|
|
49
|
-
/** Normal map strength. */
|
|
50
|
-
normalStrength: number;
|
|
51
|
-
/** 0 desaturates to luma, 1 leaves it alone, above 1 pushes. A luma lerp, not
|
|
52
|
-
* an HSV round trip — the reference does two colour-space conversions per
|
|
53
|
-
* sampled surface per pixel for this. */
|
|
54
|
-
saturation: number;
|
|
55
|
-
/** Multiplied into the albedo. */
|
|
56
|
-
tint: string;
|
|
57
|
-
/** Per-surface roughness. The reference has one value for the whole ground,
|
|
58
|
-
* so wet mud and dry rock shade identically. */
|
|
59
|
-
roughness: number;
|
|
60
|
-
/** Per-surface metalness. Almost always 0; wet rock is the exception. */
|
|
61
|
-
metalness: number;
|
|
62
|
-
/** 0 blends linearly, 1 lets the layer's own height decide the transition. */
|
|
63
|
-
heightBlend: number;
|
|
64
|
-
/** Break the repeat grid with stochastic tiling. Three fetches instead of
|
|
65
|
-
* one for this surface, and the difference between authored ground and
|
|
66
|
-
* wallpaper. Requires quality.stochastic. */
|
|
67
|
-
aperiodic: boolean;
|
|
68
|
-
/** Project on world axes instead of the tile's UV. Cliffs only — it doubles
|
|
69
|
-
* the fetches for this surface. Requires quality.triplanar. */
|
|
70
|
-
triplanar: boolean;
|
|
71
|
-
/** Flip the normal map's green channel (DirectX vs OpenGL convention). */
|
|
72
|
-
flipNormalY: boolean;
|
|
73
|
-
}
|
|
74
|
-
/** Height and slope rule for `splatSource: 'auto'`. */
|
|
75
|
-
export interface AutoSplatConfig {
|
|
76
|
-
/** Height fraction each surface is centred on, in surface order. The last
|
|
77
|
-
* surface is the rock layer and is placed by slope instead. */
|
|
78
|
-
bands: number[];
|
|
79
|
-
/** Width of each band, in height fractions. */
|
|
80
|
-
bandWidth: number;
|
|
81
|
-
/** Slope (0 flat, 1 vertical) where rock starts showing through. */
|
|
82
|
-
slopeStart: number;
|
|
83
|
-
/** Slope where the surface is bare rock. */
|
|
84
|
-
slopeEnd: number;
|
|
85
|
-
/** Break-up applied to the height before banding, so the bands are not
|
|
86
|
-
* contour lines. */
|
|
87
|
-
noise: number;
|
|
88
|
-
/** World size of that break-up. */
|
|
89
|
-
noiseSize: number;
|
|
90
|
-
}
|
|
91
|
-
export interface LandscapeConfig {
|
|
92
|
-
enabled: boolean;
|
|
93
|
-
host: LandscapeHost;
|
|
94
|
-
/** Required. Nothing renders without it. */
|
|
95
|
-
heightMap: string;
|
|
96
|
-
heightEncoding: HeightEncoding;
|
|
97
|
-
splatSource: SplatSource;
|
|
98
|
-
/** 0, 1 or 2 maps — 4 or 8 surfaces. */
|
|
99
|
-
splatMaps: string[];
|
|
100
|
-
autoSplat: AutoSplatConfig;
|
|
101
|
-
/** Baked ambient occlusion over the whole tile. Optional. */
|
|
102
|
-
aoMap?: string;
|
|
103
|
-
/** World units across the tile. */
|
|
104
|
-
size: number;
|
|
105
|
-
/** Heightmap 0..1 (or metres, for terrain-rgb) to world units. */
|
|
106
|
-
elevationScale: number;
|
|
107
|
-
/** World Y added after scaling. */
|
|
108
|
-
elevationBias: number;
|
|
109
|
-
/** Ground host only — the object host uses its transform. */
|
|
110
|
-
origin: [number, number, number];
|
|
111
|
-
/** Ground host only, in degrees. */
|
|
112
|
-
rotationY: number;
|
|
113
|
-
/** 0 samples the heightmap raw; above it, a bicubic filter over a widened
|
|
114
|
-
* footprint, which is what keeps an 8-bit heightmap off visible terracing. */
|
|
115
|
-
smoothness: number;
|
|
116
|
-
surfaces: LandscapeSurface[];
|
|
117
|
-
/** How many of the heaviest surface weights are sampled per pixel, 1..4.
|
|
118
|
-
* The single most effective cost dial in the material. */
|
|
119
|
-
surfaceSamples: number;
|
|
120
|
-
/** Large-scale albedo break-up, generated rather than sampled from a macro
|
|
121
|
-
* texture — the reference ships a 2.7 MB one for this. */
|
|
122
|
-
macroVariation: number;
|
|
123
|
-
/** World size of that break-up. */
|
|
124
|
-
macroSize: number;
|
|
125
|
-
aoIntensity: number;
|
|
126
|
-
envMapIntensity: number;
|
|
127
|
-
/** UI bookmarks. The renderer never reads any of these — they are what the
|
|
128
|
-
* Basic tab shows as the current selection, and what the AI agent will set
|
|
129
|
-
* when it learns to. */
|
|
130
|
-
preset?: string;
|
|
131
|
-
/** Biome id from `landscapeTypes.ts`. */
|
|
132
|
-
landscapeType?: string;
|
|
133
|
-
/** Terrain-shape folder the heightmap came from. */
|
|
134
|
-
shape?: string;
|
|
135
|
-
}
|
|
136
|
-
export interface LandscapeQualityConfig {
|
|
137
|
-
/** RTIN error budget in world units — the maximum height a triangle may be
|
|
138
|
-
* wrong by. 0 puts a vertex on every heightmap texel. */
|
|
139
|
-
meshError: number;
|
|
140
|
-
/** The same budget on a slow GPU or a phone. */
|
|
141
|
-
mobileMeshError: number;
|
|
142
|
-
/** N x N index-buffer chunks over one shared vertex buffer, so the tile
|
|
143
|
-
* frustum-culls. Neighbouring chunks share vertices exactly, so there is no
|
|
144
|
-
* crack risk. */
|
|
145
|
-
chunks: number;
|
|
146
|
-
/** Edge of the square texture arrays every surface is resized into. 2048
|
|
147
|
-
* costs four times the memory of 1024 for detail you will not see past a
|
|
148
|
-
* few metres. */
|
|
149
|
-
arrayResolution: 512 | 1024 | 2048;
|
|
150
|
-
anisotropy: number;
|
|
151
|
-
/** Stochastic tiling for every surface flagged aperiodic. A material define,
|
|
152
|
-
* so turning it off compiles the code out. */
|
|
153
|
-
stochastic: boolean;
|
|
154
|
-
/** Enable the biplanar path for surfaces flagged triplanar. Also a define. */
|
|
155
|
-
triplanar: boolean;
|
|
156
|
-
castShadows: boolean;
|
|
157
|
-
receiveShadows: boolean;
|
|
158
|
-
wireframe: boolean;
|
|
159
|
-
}
|
|
160
|
-
export interface LandscapeSettings {
|
|
161
|
-
id: string;
|
|
162
|
-
type: 'landscape';
|
|
163
|
-
config: LandscapeConfig;
|
|
164
|
-
quality: LandscapeQualityConfig;
|
|
165
|
-
}
|
|
166
|
-
export declare const defaultLandscapeSurface: LandscapeSurface;
|
|
167
|
-
export declare const defaultAutoSplat: AutoSplatConfig;
|
|
168
|
-
export declare const defaultLandscapeConfig: LandscapeConfig;
|
|
169
|
-
export declare const defaultLandscapeQuality: LandscapeQualityConfig;
|
|
170
|
-
export declare const defaultLandscapeSettings: LandscapeSettings;
|
|
171
|
-
/** Hard ceiling. Two splat maps carry four channels each, and the index is packed
|
|
172
|
-
* as `i / MAX_SURFACES` in the weight pair. */
|
|
173
|
-
export declare const MAX_LANDSCAPE_SURFACES = 8;
|
|
174
|
-
/** The object host keeps the same material with a shorter list. */
|
|
175
|
-
export declare const MAX_OBJECT_SURFACES = 4;
|
|
176
|
-
export type LandscapePropertyGroup = 'maps' | 'form' | 'surface' | 'quality';
|
|
177
|
-
export interface LandscapePropertySchema {
|
|
178
|
-
key: string;
|
|
179
|
-
label: string;
|
|
180
|
-
group: LandscapePropertyGroup;
|
|
181
|
-
type?: 'number' | 'boolean' | 'texture' | 'select';
|
|
182
|
-
min?: number;
|
|
183
|
-
max?: number;
|
|
184
|
-
step?: number;
|
|
185
|
-
unit?: string;
|
|
186
|
-
options?: string[];
|
|
187
|
-
description: string;
|
|
188
|
-
advanced?: boolean;
|
|
189
|
-
/** Absent means both hosts. */
|
|
190
|
-
hosts?: LandscapeHost[];
|
|
191
|
-
}
|
|
192
|
-
export declare const LANDSCAPE_SCHEMA: LandscapePropertySchema[];
|
|
193
|
-
export declare const LANDSCAPE_AUTOSPLAT_SCHEMA: LandscapePropertySchema[];
|
|
194
|
-
export declare const LANDSCAPE_QUALITY_SCHEMA: LandscapePropertySchema[];
|
|
195
|
-
/** Config keys that are uniforms and nothing else. */
|
|
196
|
-
export declare const LANDSCAPE_LIVE_CONFIG_KEYS: readonly string[];
|
|
197
|
-
/** Quality keys that are uniforms, material flags or texture state. */
|
|
198
|
-
export declare const LANDSCAPE_LIVE_QUALITY_KEYS: readonly string[];
|
|
199
|
-
/**
|
|
200
|
-
* Keys that rebuild something, listed for the panel to explain itself with.
|
|
201
|
-
*
|
|
202
|
-
* meshError, chunks re-run RTIN and rebuild every index buffer
|
|
203
|
-
* arrayResolution repacks up to sixteen textures
|
|
204
|
-
* surfaceSamples changes a #define, so the shader recompiles
|
|
205
|
-
* stochastic, triplanar likewise
|
|
206
|
-
* size, heightMap, splatMaps, heightEncoding, splatSource, surfaces
|
|
207
|
-
* change the mesh or the arrays
|
|
208
|
-
*/
|
|
209
|
-
export declare const LANDSCAPE_REBUILD_KEYS: readonly string[];
|
|
210
|
-
/** Every surface field except the three texture slots is a uniform. */
|
|
211
|
-
export declare const LANDSCAPE_LIVE_SURFACE_KEYS: readonly string[];
|
|
212
|
-
/** Auto-splat is entirely uniforms — all four rows plus the band list. */
|
|
213
|
-
export declare const LANDSCAPE_LIVE_AUTOSPLAT_KEYS: readonly string[];
|
|
214
|
-
export declare function normalizeLandscapeSurface(raw: unknown, index?: number): LandscapeSurface;
|
|
215
|
-
export declare function normalizeLandscape(raw: unknown): LandscapeConfig | null;
|
|
216
|
-
export declare function normalizeLandscapeQuality(raw: unknown): LandscapeQualityConfig;
|
|
217
|
-
export declare function normalizeLandscapeSettings(raw: unknown): LandscapeSettings;
|
|
1
|
+
export type { AutoSplatConfig, HeightEncoding, LandscapeConfig, LandscapeHost, LandscapePropertyGroup, LandscapePropertySchema, LandscapeQualityConfig, LandscapeSettings, LandscapeSurface, SplatSource, } from '@3driseai/3drise-core';
|
|
2
|
+
export { LANDSCAPE_AUTOSPLAT_SCHEMA, LANDSCAPE_LIVE_AUTOSPLAT_KEYS, LANDSCAPE_LIVE_CONFIG_KEYS, LANDSCAPE_LIVE_QUALITY_KEYS, LANDSCAPE_LIVE_SURFACE_KEYS, LANDSCAPE_QUALITY_SCHEMA, LANDSCAPE_REBUILD_KEYS, LANDSCAPE_SCHEMA, MAX_LANDSCAPE_SURFACES, MAX_OBJECT_SURFACES, defaultAutoSplat, defaultLandscapeConfig, defaultLandscapeQuality, defaultLandscapeSettings, defaultLandscapeSurface, normalizeLandscape, normalizeLandscapeQuality, normalizeLandscapeSettings, normalizeLandscapeSurface, } from '@3driseai/3drise-core';
|
|
218
3
|
//# sourceMappingURL=landscapeConfigs.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"landscapeConfigs.d.ts","sourceRoot":"","sources":["../../src/types/landscapeConfigs.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"landscapeConfigs.d.ts","sourceRoot":"","sources":["../../src/types/landscapeConfigs.ts"],"names":[],"mappings":"AAEA,YAAY,EACV,eAAe,EACf,cAAc,EACd,eAAe,EACf,aAAa,EACb,sBAAsB,EACtB,uBAAuB,EACvB,sBAAsB,EACtB,iBAAiB,EACjB,gBAAgB,EAChB,WAAW,GACZ,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,0BAA0B,EAC1B,6BAA6B,EAC7B,0BAA0B,EAC1B,2BAA2B,EAC3B,2BAA2B,EAC3B,wBAAwB,EACxB,sBAAsB,EACtB,gBAAgB,EAChB,sBAAsB,EACtB,mBAAmB,EACnB,gBAAgB,EAChB,sBAAsB,EACtB,uBAAuB,EACvB,wBAAwB,EACxB,uBAAuB,EACvB,kBAAkB,EAClB,yBAAyB,EACzB,0BAA0B,EAC1B,yBAAyB,GAC1B,MAAM,uBAAuB,CAAC"}
|
|
@@ -1,256 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
* from a heightmap and textured through splat maps.
|
|
4
|
-
*
|
|
5
|
-
* This is NOT a mode of the procedural terrain and does not share a config with
|
|
6
|
-
* it. Terrain is an infinite camera-following clipmap generated from noise; a
|
|
7
|
-
* landscape is a finite tile whose shape and materials the user supplies. Both
|
|
8
|
-
* may be enabled in one scene; nothing here reads `terrainConfigs`.
|
|
9
|
-
*
|
|
10
|
-
* Declared in the viewer, next to the material that consumes it, for the same
|
|
11
|
-
* reason `terrainConfigs` and `oceanConfigs` are.
|
|
12
|
-
*/
|
|
13
|
-
// -----------------------------------------------------------------------------
|
|
14
|
-
// Defaults
|
|
15
|
-
// -----------------------------------------------------------------------------
|
|
16
|
-
export const defaultLandscapeSurface = {
|
|
17
|
-
name: 'Surface',
|
|
18
|
-
diffuse: '',
|
|
19
|
-
normal: '',
|
|
20
|
-
displacement: '',
|
|
21
|
-
repeat: 200,
|
|
22
|
-
normalStrength: 0.6,
|
|
23
|
-
saturation: 1,
|
|
24
|
-
tint: '#ffffff',
|
|
25
|
-
roughness: 0.9,
|
|
26
|
-
metalness: 0,
|
|
27
|
-
heightBlend: 0.6,
|
|
28
|
-
aperiodic: true,
|
|
29
|
-
triplanar: false,
|
|
30
|
-
flipNormalY: false,
|
|
31
|
-
};
|
|
32
|
-
export const defaultAutoSplat = {
|
|
33
|
-
bands: [0, 0.35, 0.75],
|
|
34
|
-
bandWidth: 0.45,
|
|
35
|
-
slopeStart: 0.35,
|
|
36
|
-
slopeEnd: 0.62,
|
|
37
|
-
noise: 0.12,
|
|
38
|
-
noiseSize: 400,
|
|
39
|
-
};
|
|
40
|
-
export const defaultLandscapeConfig = {
|
|
41
|
-
enabled: false,
|
|
42
|
-
host: 'ground',
|
|
43
|
-
heightMap: '',
|
|
44
|
-
heightEncoding: 'grayscale',
|
|
45
|
-
splatSource: 'auto',
|
|
46
|
-
splatMaps: [],
|
|
47
|
-
autoSplat: { ...defaultAutoSplat, bands: [...defaultAutoSplat.bands] },
|
|
48
|
-
aoMap: '',
|
|
49
|
-
size: 2048,
|
|
50
|
-
elevationScale: 300,
|
|
51
|
-
elevationBias: 0,
|
|
52
|
-
origin: [0, 0, 0],
|
|
53
|
-
rotationY: 0,
|
|
54
|
-
smoothness: 1,
|
|
55
|
-
surfaces: [],
|
|
56
|
-
surfaceSamples: 3,
|
|
57
|
-
macroVariation: 0.25,
|
|
58
|
-
macroSize: 900,
|
|
59
|
-
aoIntensity: 0.8,
|
|
60
|
-
envMapIntensity: 0.9,
|
|
61
|
-
preset: '',
|
|
62
|
-
};
|
|
63
|
-
export const defaultLandscapeQuality = {
|
|
64
|
-
meshError: 1.5,
|
|
65
|
-
mobileMeshError: 6,
|
|
66
|
-
chunks: 4,
|
|
67
|
-
arrayResolution: 1024,
|
|
68
|
-
anisotropy: 4,
|
|
69
|
-
stochastic: true,
|
|
70
|
-
triplanar: true,
|
|
71
|
-
castShadows: true,
|
|
72
|
-
receiveShadows: true,
|
|
73
|
-
wireframe: false,
|
|
74
|
-
};
|
|
75
|
-
export const defaultLandscapeSettings = {
|
|
76
|
-
id: '3drise-landscape',
|
|
77
|
-
type: 'landscape',
|
|
78
|
-
config: { ...defaultLandscapeConfig },
|
|
79
|
-
quality: { ...defaultLandscapeQuality },
|
|
80
|
-
};
|
|
81
|
-
/** Hard ceiling. Two splat maps carry four channels each, and the index is packed
|
|
82
|
-
* as `i / MAX_SURFACES` in the weight pair. */
|
|
83
|
-
export const MAX_LANDSCAPE_SURFACES = 8;
|
|
84
|
-
/** The object host keeps the same material with a shorter list. */
|
|
85
|
-
export const MAX_OBJECT_SURFACES = 4;
|
|
86
|
-
export const LANDSCAPE_SCHEMA = [
|
|
87
|
-
{ key: 'size', label: 'Size', group: 'form', min: 4, max: 40000, step: 4, unit: 'm', description: 'World units across the tile. The heightmap is square, so this is both sides.' },
|
|
88
|
-
{ key: 'elevationScale', label: 'Elevation', group: 'form', min: 0, max: 4000, step: 1, unit: 'm', description: 'World height of the heightmap’s full range. This is the knob that turns a relief map into mountains.' },
|
|
89
|
-
{ key: 'elevationBias', label: 'Base height', group: 'form', min: -2000, max: 2000, step: 1, unit: 'm', description: 'World Y added after scaling — where the lowest point of the heightmap sits.' },
|
|
90
|
-
{ key: 'rotationY', label: 'Rotation', group: 'form', min: 0, max: 360, step: 1, unit: 'deg', hosts: ['ground'], description: 'Turns the tile about its centre. The placed host uses its own transform instead.' },
|
|
91
|
-
{ key: 'smoothness', label: 'Smoothness', group: 'form', min: 0, max: 8, step: 0.05, description: 'Bicubic filtering of the heightmap over a widened footprint. Above 0 it is what keeps an 8-bit heightmap from rendering as terraced steps.' },
|
|
92
|
-
{ key: 'surfaceSamples', label: 'Surface samples', group: 'surface', min: 1, max: 4, step: 1, description: 'How many of the heaviest surface weights are blended per pixel. The strongest cost dial in the material — 2 is enough almost everywhere, and artefacts only show where three splat channels genuinely overlap.' },
|
|
93
|
-
{ key: 'macroVariation', label: 'Macro variation', group: 'surface', min: 0, max: 1, step: 0.005, description: 'Large-scale albedo break-up, generated rather than sampled. Without it a splat layer is one flat colour across hundreds of metres and the eye reads it as untextured.' },
|
|
94
|
-
{ key: 'macroSize', label: 'Macro size', group: 'surface', min: 50, max: 8000, step: 10, unit: 'm', description: 'World size of that break-up.' },
|
|
95
|
-
{ key: 'aoIntensity', label: 'AO intensity', group: 'surface', min: 0, max: 2, step: 0.01, description: 'Strength of the baked ambient occlusion map, when one is supplied.' },
|
|
96
|
-
{ key: 'envMapIntensity', label: 'Environment', group: 'surface', min: 0, max: 3, step: 0.01, description: 'How much the scene’s HDR environment lights the ground.' },
|
|
97
|
-
];
|
|
98
|
-
export const LANDSCAPE_AUTOSPLAT_SCHEMA = [
|
|
99
|
-
{ key: 'bandWidth', label: 'Band width', group: 'surface', min: 0.05, max: 1.5, step: 0.01, description: 'How far each surface reaches either side of its height band. Wide bands cross-fade; narrow ones stripe.' },
|
|
100
|
-
{ key: 'slopeStart', label: 'Rock from slope', group: 'surface', min: 0, max: 1, step: 0.005, description: 'Slope at which the last surface (rock) starts showing through. Splatting rock by slope rather than height is what makes a cliff read as a cliff at any altitude.' },
|
|
101
|
-
{ key: 'slopeEnd', label: 'Bare rock at slope', group: 'surface', min: 0, max: 1, step: 0.005, description: 'Slope at which the surface is fully rock.' },
|
|
102
|
-
{ key: 'noise', label: 'Band break-up', group: 'surface', min: 0, max: 1, step: 0.005, description: 'Jitters the height before banding, so the boundaries are not contour lines.' },
|
|
103
|
-
{ key: 'noiseSize', label: 'Break-up size', group: 'surface', min: 10, max: 4000, step: 5, unit: 'm', description: 'World size of that jitter.' },
|
|
104
|
-
];
|
|
105
|
-
export const LANDSCAPE_QUALITY_SCHEMA = [
|
|
106
|
-
{ key: 'meshError', label: 'Mesh error', group: 'quality', min: 0, max: 60, step: 0.1, unit: 'm', description: 'The most a triangle may be wrong by, vertically. Lower spends triangles on cliffs; 0 puts a vertex on every heightmap texel. Changing it rebuilds the mesh, so it commits on release.' },
|
|
107
|
-
{ key: 'chunks', label: 'Culling chunks', group: 'quality', min: 1, max: 12, step: 1, description: 'The tile is split into this many chunks per side over one shared vertex buffer, so it frustum-culls instead of drawing whole. More chunks cull better and cost more draw calls.' },
|
|
108
|
-
{ key: 'anisotropy', label: 'Anisotropy', group: 'quality', min: 1, max: 16, step: 1, description: 'Sharpness of ground textures at grazing angles — which on a landscape is most of the screen.' },
|
|
109
|
-
{ key: 'stochastic', label: 'Stochastic tiling', group: 'quality', type: 'boolean', description: 'Breaks the repeat grid on surfaces flagged for it, with a variance-preserving three-tap blend. Doubles the fetches for those surfaces and is the difference between authored ground and wallpaper.' },
|
|
110
|
-
{ key: 'triplanar', label: 'Triplanar', group: 'quality', type: 'boolean', description: 'Enables world-axis projection for surfaces flagged for it, so a cliff face is not a smear of stretched pixels. Biplanar in practice — two planes, not three.' },
|
|
111
|
-
{ key: 'castShadows', label: 'Cast shadows', group: 'quality', type: 'boolean', description: 'The landscape casts into the scene’s shadow map. It is bounded, so the sun’s shadow camera actually covers it — which is why this is possible here and not for the procedural terrain.' },
|
|
112
|
-
{ key: 'receiveShadows', label: 'Receive shadows', group: 'quality', type: 'boolean', description: 'Objects standing on the landscape cast onto it.' },
|
|
113
|
-
{ key: 'wireframe', label: 'Wireframe', group: 'quality', type: 'boolean', description: 'Draw the adaptive mesh itself. The fastest way to see what the error budget is buying.' },
|
|
114
|
-
];
|
|
115
|
-
// -----------------------------------------------------------------------------
|
|
116
|
-
// What can be driven live, and what cannot
|
|
117
|
-
// -----------------------------------------------------------------------------
|
|
118
|
-
//
|
|
119
|
-
// A slider drag fires on every pointer-move. Everything that is only a uniform
|
|
120
|
-
// can be written straight into the renderer at that rate; everything that
|
|
121
|
-
// rebuilds something cannot, and has to wait for the pointer to come up.
|
|
122
|
-
//
|
|
123
|
-
// These sets are the single statement of that split. The controller passes every
|
|
124
|
-
// key it has and the renderer's live handle drops the ones that are not here, so
|
|
125
|
-
// a rebuild key cannot half-apply — which is what `size` did before this existed:
|
|
126
|
-
// the triplanar scale is a uniform and moved during the drag while the mesh,
|
|
127
|
-
// built at the committed size, did not.
|
|
128
|
-
/** Config keys that are uniforms and nothing else. */
|
|
129
|
-
export const LANDSCAPE_LIVE_CONFIG_KEYS = [
|
|
130
|
-
'elevationScale',
|
|
131
|
-
'elevationBias',
|
|
132
|
-
'smoothness',
|
|
133
|
-
'macroVariation',
|
|
134
|
-
'macroSize',
|
|
135
|
-
'aoIntensity',
|
|
136
|
-
'envMapIntensity',
|
|
137
|
-
'rotationY',
|
|
138
|
-
];
|
|
139
|
-
/** Quality keys that are uniforms, material flags or texture state. */
|
|
140
|
-
export const LANDSCAPE_LIVE_QUALITY_KEYS = [
|
|
141
|
-
'wireframe',
|
|
142
|
-
'castShadows',
|
|
143
|
-
'receiveShadows',
|
|
144
|
-
'anisotropy',
|
|
145
|
-
];
|
|
146
|
-
/**
|
|
147
|
-
* Keys that rebuild something, listed for the panel to explain itself with.
|
|
148
|
-
*
|
|
149
|
-
* meshError, chunks re-run RTIN and rebuild every index buffer
|
|
150
|
-
* arrayResolution repacks up to sixteen textures
|
|
151
|
-
* surfaceSamples changes a #define, so the shader recompiles
|
|
152
|
-
* stochastic, triplanar likewise
|
|
153
|
-
* size, heightMap, splatMaps, heightEncoding, splatSource, surfaces
|
|
154
|
-
* change the mesh or the arrays
|
|
155
|
-
*/
|
|
156
|
-
export const LANDSCAPE_REBUILD_KEYS = [
|
|
157
|
-
'meshError',
|
|
158
|
-
'mobileMeshError',
|
|
159
|
-
'chunks',
|
|
160
|
-
'arrayResolution',
|
|
161
|
-
'surfaceSamples',
|
|
162
|
-
'stochastic',
|
|
163
|
-
'triplanar',
|
|
164
|
-
'size',
|
|
165
|
-
'heightMap',
|
|
166
|
-
'heightEncoding',
|
|
167
|
-
'splatSource',
|
|
168
|
-
'splatMaps',
|
|
169
|
-
'surfaces',
|
|
170
|
-
];
|
|
171
|
-
/** Every surface field except the three texture slots is a uniform. */
|
|
172
|
-
export const LANDSCAPE_LIVE_SURFACE_KEYS = [
|
|
173
|
-
'repeat',
|
|
174
|
-
'normalStrength',
|
|
175
|
-
'saturation',
|
|
176
|
-
'tint',
|
|
177
|
-
'roughness',
|
|
178
|
-
'metalness',
|
|
179
|
-
'heightBlend',
|
|
180
|
-
'aperiodic',
|
|
181
|
-
'triplanar',
|
|
182
|
-
'flipNormalY',
|
|
183
|
-
];
|
|
184
|
-
/** Auto-splat is entirely uniforms — all four rows plus the band list. */
|
|
185
|
-
export const LANDSCAPE_LIVE_AUTOSPLAT_KEYS = [
|
|
186
|
-
'bandWidth',
|
|
187
|
-
'slopeStart',
|
|
188
|
-
'slopeEnd',
|
|
189
|
-
'noise',
|
|
190
|
-
'noiseSize',
|
|
191
|
-
];
|
|
192
|
-
// =============================================================================
|
|
193
|
-
// Normalisation
|
|
194
|
-
// =============================================================================
|
|
195
|
-
//
|
|
196
|
-
// Same rule as the terrain, not the ocean: a blob with no heightMap renders
|
|
197
|
-
// nothing. There is no legacy landscape shape to migrate, and a landscape with
|
|
198
|
-
// no heightmap is not a landscape.
|
|
199
|
-
//
|
|
200
|
-
// Each block merges over its own defaults SEPARATELY, so a quality edit does not
|
|
201
|
-
// hand the mesh a new config object and re-run RTIN.
|
|
202
|
-
const isRecord = (v) => typeof v === 'object' && v !== null;
|
|
203
|
-
export function normalizeLandscapeSurface(raw, index = 0) {
|
|
204
|
-
const src = isRecord(raw) ? raw : {};
|
|
205
|
-
return {
|
|
206
|
-
...defaultLandscapeSurface,
|
|
207
|
-
name: typeof src.name === 'string' ? src.name : `Surface ${index + 1}`,
|
|
208
|
-
...src,
|
|
209
|
-
};
|
|
210
|
-
}
|
|
211
|
-
export function normalizeLandscape(raw) {
|
|
212
|
-
if (!isRecord(raw))
|
|
213
|
-
return null;
|
|
214
|
-
if (typeof raw.heightMap !== 'string' || raw.heightMap.length === 0)
|
|
215
|
-
return null;
|
|
216
|
-
const host = raw.host === 'object' ? 'object' : 'ground';
|
|
217
|
-
const limit = host === 'object' ? MAX_OBJECT_SURFACES : MAX_LANDSCAPE_SURFACES;
|
|
218
|
-
const surfaces = Array.isArray(raw.surfaces)
|
|
219
|
-
? raw.surfaces.slice(0, limit).map((s, i) => normalizeLandscapeSurface(s, i))
|
|
220
|
-
: [];
|
|
221
|
-
return {
|
|
222
|
-
...defaultLandscapeConfig,
|
|
223
|
-
...raw,
|
|
224
|
-
host,
|
|
225
|
-
surfaces,
|
|
226
|
-
splatMaps: Array.isArray(raw.splatMaps)
|
|
227
|
-
? raw.splatMaps.filter((s) => typeof s === 'string').slice(0, 2)
|
|
228
|
-
: [],
|
|
229
|
-
autoSplat: {
|
|
230
|
-
...defaultAutoSplat,
|
|
231
|
-
...(isRecord(raw.autoSplat) ? raw.autoSplat : {}),
|
|
232
|
-
bands: Array.isArray(raw.autoSplat?.bands)
|
|
233
|
-
? raw.autoSplat.bands
|
|
234
|
-
: [...defaultAutoSplat.bands],
|
|
235
|
-
},
|
|
236
|
-
origin: Array.isArray(raw.origin) && raw.origin.length === 3
|
|
237
|
-
? [...raw.origin]
|
|
238
|
-
: [...defaultLandscapeConfig.origin],
|
|
239
|
-
};
|
|
240
|
-
}
|
|
241
|
-
export function normalizeLandscapeQuality(raw) {
|
|
242
|
-
return {
|
|
243
|
-
...defaultLandscapeQuality,
|
|
244
|
-
...(isRecord(raw) ? raw : {}),
|
|
245
|
-
};
|
|
246
|
-
}
|
|
247
|
-
export function normalizeLandscapeSettings(raw) {
|
|
248
|
-
const source = isRecord(raw) ? raw : {};
|
|
249
|
-
const config = normalizeLandscape(source.config);
|
|
250
|
-
return {
|
|
251
|
-
id: typeof source.id === 'string' ? source.id : defaultLandscapeSettings.id,
|
|
252
|
-
type: 'landscape',
|
|
253
|
-
config: config ?? { ...defaultLandscapeConfig },
|
|
254
|
-
quality: normalizeLandscapeQuality(source.quality),
|
|
255
|
-
};
|
|
256
|
-
}
|
|
1
|
+
// Moved to @3driseai/3drise-core (src/environment/landscapeConfigs.ts). Re-exported for existing viewer imports.
|
|
2
|
+
export { LANDSCAPE_AUTOSPLAT_SCHEMA, LANDSCAPE_LIVE_AUTOSPLAT_KEYS, LANDSCAPE_LIVE_CONFIG_KEYS, LANDSCAPE_LIVE_QUALITY_KEYS, LANDSCAPE_LIVE_SURFACE_KEYS, LANDSCAPE_QUALITY_SCHEMA, LANDSCAPE_REBUILD_KEYS, LANDSCAPE_SCHEMA, MAX_LANDSCAPE_SURFACES, MAX_OBJECT_SURFACES, defaultAutoSplat, defaultLandscapeConfig, defaultLandscapeQuality, defaultLandscapeSettings, defaultLandscapeSurface, normalizeLandscape, normalizeLandscapeQuality, normalizeLandscapeSettings, normalizeLandscapeSurface, } from '@3driseai/3drise-core';
|