-
Notifications
You must be signed in to change notification settings - Fork 826
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
[WIP] switch to WebGPU #4939
base: master
Are you sure you want to change the base?
[WIP] switch to WebGPU #4939
Conversation
Does it help if I say I don't care about shaders much (for now) for my use cases? Out of curiosity how do I test your PR? |
You may not care about shaders, but they're the heart of how MV (and 3D rendering in general) works, so If they aren't working, you'll definitely miss them. You can pull my branch and serve locally, but you'll mostly get black models. |
Ahh, okay got you, very important then. I'll hold off until then, was
expecting a uniformly lit model without it.
*Christopher Derrell*
*Head of Web Development*
<https://adtelligent.net/>
4 Sylvan Avenue, Kingston 5, Jamaica
(W) 1 (876) 616 8756 | (C) 1 (876) 567 7884
…On Wed, Dec 11, 2024 at 11:19 AM Emmett Lalish ***@***.***> wrote:
You may not care about shaders, but they're the heart of how MV (and 3D
rendering in general) works, so If they aren't working, you'll definitely
miss them. You can pull my branch and serve locally, but you'll mostly get
black models.
—
Reply to this email directly, view it on GitHub
<#4939 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AYO7RL3TAO65RAJWUPAZ6JT2FBQYPAVCNFSM6AAAAABRXR75R6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKMZWGQ2DSOJUGY>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
const cubeTarget = new CubeRenderTarget(256); | ||
(cubeTarget as any) | ||
.fromCubeTexture( | ||
this.threeRenderer, tmpTarget.texture, GENERATED_SIGMA); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here I'm relying on a WIP three.js PR: mrdoob/three.js#30165. There's still some problem, probably in that PR, because randomly the generated environment either throws or creates a black texture.
Now that Three.js supports WebGPU, and better yet,
WebGPURenderer
automatically falls back toWebGL2Renderer
on unsupported platforms, it's probably about time we started migrating. Amazingly, it sort of already works! Main problems I've noticed so far are with our custom shaders:custom blur shader for the generated environment. I think we can delete all this code and start using
getTextureLevel
instead, but that means we'll also have to transition fromscene.environment
to scene.environmentNode`.custom shadow shader. Just rewrite this in TSL - shouldn't be too complex.
We'll see how the rest goes... FYI @mrdoob.