Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WebGPURenderer: Add batch texture to cacheKey #28039

Merged

Conversation

RenaudRohlinger
Copy link
Collaborator

@RenaudRohlinger RenaudRohlinger commented Apr 1, 2024

Related issue: #27937 (comment)

Description

The update of the BatchedMesh texture wasn't properly translated in the Node System. This PR fix the issue by adding the batch texture ID to the cacheKey.

New working example:
https://raw.githack.com/renaudrohlinger/three.js/utsubo/fix/batch-dynamic/examples/webgpu_mesh_batch.html

/cc @mrdoob @sunag

This contribution is funded by Utsubo

@RenaudRohlinger RenaudRohlinger added this to the r164 milestone Apr 1, 2024
@RenaudRohlinger RenaudRohlinger merged commit 478d475 into mrdoob:dev Apr 1, 2024
11 checks passed
@sunag
Copy link
Collaborator

sunag commented Apr 1, 2024

I think we'll need something like this reference( 'matricesTexture', 'textureLoad' ).uv( ... ) for TSL, so we can reuse the cache key.

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