Skip to content

fix: use .sample() instead of texture() for depth uniform node in par…#1220

Merged
braedonsaunders merged 1 commit into
mainfrom
claude/fix-texture-error-AGWnI
Jan 31, 2026
Merged

fix: use .sample() instead of texture() for depth uniform node in par…#1220
braedonsaunders merged 1 commit into
mainfrom
claude/fix-texture-error-AGWnI

Conversation

@braedonsaunders

Copy link
Copy Markdown
Owner

…ticle system

The depth texture uniform was incorrectly being passed to TSL's texture() function, which expects a raw THREE.Texture instance. Since depthTextureUniform is a uniform node (created via uniform()), it should be sampled using the .sample() method instead.

This fixes the error: "THREE.TSL: texture( value ) function expects a valid instance of THREE.Texture()"

https://claude.ai/code/session_01FPPzpcLbkwCHCBRJGLpe86

…ticle system

The depth texture uniform was incorrectly being passed to TSL's texture()
function, which expects a raw THREE.Texture instance. Since depthTextureUniform
is a uniform node (created via uniform()), it should be sampled using the
.sample() method instead.

This fixes the error: "THREE.TSL: texture( value ) function expects a valid
instance of THREE.Texture()"

https://claude.ai/code/session_01FPPzpcLbkwCHCBRJGLpe86
@braedonsaunders braedonsaunders merged commit 2c5308d into main Jan 31, 2026
3 of 4 checks passed
@braedonsaunders braedonsaunders deleted the claude/fix-texture-error-AGWnI branch February 2, 2026 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants