From cdf7b02838a0ef34ca77f0899a224bb3e1f3e164 Mon Sep 17 00:00:00 2001 From: alex-mcneilly Date: Wed, 28 May 2025 14:16:45 -0700 Subject: [PATCH] add assets to assets.json and update source URL --- examples/assets.json | 4 ++++ examples/vfx-particle-simulation/index.html | 8 +++----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/examples/assets.json b/examples/assets.json index 5bf3f63..9baf0b5 100644 --- a/examples/assets.json +++ b/examples/assets.json @@ -23,6 +23,10 @@ "url": "https://forge.dev/assets/splats/fireplace.spz", "directory": "splats" }, + "snow-street.spz": { + "url": "https://forge-gfx.github.io/assets/splats/snow-street.spz", + "directory": "splats" + }, "branzino-amarin.spz": { "url": "https://forge.dev/assets/splats/food/branzino-amarin.spz", "directory": "splats/food" diff --git a/examples/vfx-particle-simulation/index.html b/examples/vfx-particle-simulation/index.html index a9f5772..2b607db 100644 --- a/examples/vfx-particle-simulation/index.html +++ b/examples/vfx-particle-simulation/index.html @@ -69,9 +69,7 @@ handleResize(); window.addEventListener("resize", handleResize); - // const backgroundURL = await getAssetFileURL("snow-street.spz"); - const backgroundURL = - "./snow-street.spz"; + const backgroundURL = await getAssetFileURL("snow-street.spz"); const background = new SplatMesh({ url: backgroundURL }); background.quaternion.set(1, 0, 0, 0); scene.add(background); @@ -221,9 +219,9 @@ controls.update(dt, camera); // camera movement - const targetZ = 91; + const targetZ = 90.5; const startZ = 104; - const duration = 90; + const duration = 9; const progress = Math.min(1, t / duration); const smoothProgress = Math.sin(progress * Math.PI * 0.5); camera.position.z = startZ + (targetZ - startZ) * smoothProgress;