diff --git a/examples/screenshots/webgpu_compute_particles_snow.jpg b/examples/screenshots/webgpu_compute_particles_snow.jpg index e3e85950fe3ff1..fb4bb58d6a3a7b 100644 Binary files a/examples/screenshots/webgpu_compute_particles_snow.jpg and b/examples/screenshots/webgpu_compute_particles_snow.jpg differ diff --git a/examples/webgpu_compute_particles_snow.html b/examples/webgpu_compute_particles_snow.html index 441a0bd6118ab0..4d9ab0a943bc3c 100644 --- a/examples/webgpu_compute_particles_snow.html +++ b/examples/webgpu_compute_particles_snow.html @@ -85,12 +85,14 @@ collisionCamera.layers.enable( 1 ); collisionPosRT = new THREE.RenderTarget( 1024, 1024 ); + collisionPosRT.texture.format = THREE.RedFormat; collisionPosRT.texture.type = THREE.HalfFloatType; collisionPosRT.texture.magFilter = THREE.NearestFilter; collisionPosRT.texture.minFilter = THREE.NearestFilter; collisionPosRT.texture.generateMipmaps = false; collisionPosMaterial = new THREE.MeshBasicNodeMaterial(); + collisionPosMaterial.blending = THREE.NoBlending; collisionPosMaterial.fog = false; collisionPosMaterial.toneMapped = false; collisionPosMaterial.colorNode = positionWorld.y; @@ -150,11 +152,11 @@ const rippleOnSurface = texture( collisionPosRT.texture, getCoord( position.xz ) ).toInspector( 'Collision Test', () => { - return texture( collisionPosRT.texture ).y; // .div( collisionCamera.position.y ); + return texture( collisionPosRT.texture ).r; // .div( collisionCamera.position.y ); } ); - const rippleFloorArea = rippleOnSurface.y.add( scale.x.mul( surfaceOffset ) ); + const rippleFloorArea = rippleOnSurface.r.add( scale.x.mul( surfaceOffset ) ); If( position.y.greaterThan( rippleFloorArea ), () => { diff --git a/package-lock.json b/package-lock.json index c6bdff10bfd512..4d259af06d5110 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2171,10 +2171,20 @@ } }, "node_modules/linkify-it": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-5.0.0.tgz", - "integrity": "sha512-5aHCbzQRADcdP+ATqnDuhhJ/MRIqDkZX5pyjFHRRysS8vZ5AbqGEoFIb6pYHPZ+L/OC2Lc+xT8uHVVR5CAK/wQ==", + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-5.0.1.tgz", + "integrity": "sha512-wVoTjP4Q6R0NW5hiZkVJaFZPWgtXfoGF+6LucL3/FtiNjmcHhYjEr5f1Kqjirc1nBW07J/ZuRFumqr2oqccEWg==", "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/markdown-it" + } + ], "license": "MIT", "dependencies": { "uc.micro": "^2.0.0" @@ -2228,15 +2238,25 @@ } }, "node_modules/markdown-it": { - "version": "14.1.1", - "resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-14.1.1.tgz", - "integrity": "sha512-BuU2qnTti9YKgK5N+IeMubp14ZUKUUw7yeJbkjtosvHiP0AZ5c8IAgEMk79D0eC8F23r4Ac/q8cAIFdm2FtyoA==", + "version": "14.2.0", + "resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-14.2.0.tgz", + "integrity": "sha512-1TGiQiJVRQ3NPmZH6sx5Cfnmg6GQm9jvC1ch4TK511NjSJvjzKLzn5pPfZRNZkRPZP0HqCioSndqH8v2nRaWVQ==", "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/markdown-it" + } + ], "license": "MIT", "dependencies": { "argparse": "^2.0.1", "entities": "^4.4.0", - "linkify-it": "^5.0.0", + "linkify-it": "^5.0.1", "mdurl": "^2.0.0", "punycode.js": "^2.3.1", "uc.micro": "^2.1.0"