Skip to content

Improved webgpu reflection example #31409

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

Draft
wants to merge 7 commits into
base: dev
Choose a base branch
from
Draft

Improved webgpu reflection example #31409

wants to merge 7 commits into from

Conversation

mrdoob
Copy link
Owner

@mrdoob mrdoob commented Jul 14, 2025

Related issue: #31372

Description

Tried to make webgpu_reflection (current) simpler and prettier.

Screen.Recording.2025-07-14.at.4.47.41.PM_.mov

@mrdoob mrdoob added this to the r179 milestone Jul 14, 2025
mrdoob and others added 4 commits July 14, 2025 17:08
…rt, function or class

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
@mrdoob
Copy link
Owner Author

mrdoob commented Jul 14, 2025

Still far from ChatGPT's suggestion 😅

image

@Mugen87
Copy link
Collaborator

Mugen87 commented Jul 14, 2025

What I liked about the original code is that it demonstrates how to animate objects from a zero scale to the intended value since it gives the impression that things grow. This can be useful with all kinds of objects. Not just vegetation but also stuff like pillars could be animated like that.

I'm okay with all updates but I would prefer to keep the initial animation and let the tree "grow".

@mrdoob
Copy link
Owner Author

mrdoob commented Jul 14, 2025

What I liked about the original code is that it demonstrates how to animate objects from a zero scale to something the intended value since it gives the impresses that things grow. This can be useful with all kinds of objects. Not just vegetation but also stuff like pillars could be animated like that.

I removed that when I added the shadow and I noticed that the objects in the shadow didn't animate.

Seemed like a foot-gun.

@Mugen87
Copy link
Collaborator

Mugen87 commented Jul 14, 2025

I see. In this case, I'm okay with the simplification. Maybe I can come up with an approach for a different or new example that works with shadows as well...

@oosmoxiecode
Copy link
Contributor

Nice! 😸
Still have the original one up here: https://oosmoxiecode.com/archive/js_webgl/recursive_tree_cubes/
Could link to that one instead of the web archive if you like.

@Mugen87
Copy link
Collaborator

Mugen87 commented Jul 14, 2025

Could link to that one instead of the web archive if you like.

Done!

BTW. I'm a huge admirer of your WebGL demos! I was so much fun to port recursive_tree_cubes to our new TSL approach 😊 .

@Mugen87 Mugen87 mentioned this pull request Jul 14, 2025
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.

3 participants