Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork3.7k
Ported the stroke shader to WebGPU renderer#7915
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
src/webgpu/p5.RendererWebGPU.js Outdated
| ); | ||
| if(!structMatch){ | ||
| thrownewError(`Can't find a structdefinition for${structName}`); | ||
| thrownewError(`Can't find a structdefnition for${structName}`); |
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.
Looks like a character got lost in here?
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.
Hmm true sorry, growing pains from switching text editor
src/webgpu/shaders/line.js Outdated
| discard; | ||
| } | ||
| } | ||
| var col = HOOK_getFinalColor(vec4<f32>(inputs.color.rgb, 1.) * inputs.color.a); |
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.
oh I noticed this and updated it in the color shader too, but I had intended the hooks to always get un-multiplied alpha, so the multiplication by the alpha channel would happen after the hook instead of before. The GLSL version of this may need that update too
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.
Ok will update!
| console.log( | ||
| "🌸 p5.js says: Instancing is only supported in WebGL2 mode" | ||
| ); | ||
| } |
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.
Might be missing a } here
davepagurek left a comment
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.
Looks good, thanks for working on this!
a454ffe intoprocessing:webgpuUh oh!
There was an error while loading.Please reload this page.
Changes:
I've ported the WebGL/ GLSL stroke shader to the experimental WebGPU renderer. It also includes the hooks.
Screenshots of the change:
