-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
filter() shader uniforms stop working if you use more than one #6466
Comments
Wonder if this is related to #6430 where the uniforms seem to get set at the wrong time. |
For that one, I assume it's because Lines 384 to 387 in 1c2273d
Once we can get it to go past that, we'll probably run into this issue too though! |
If we solve #6430 by auto-binding p5.js/src/webgl/p5.RendererGL.js Lines 1050 to 1059 in 3d62084
Lines 396 to 400 in c5f5abb
Then, we aren't dynamically regenerating new shaders every frame, and this issue would go away. |
Most appropriate sub-area of p5.js?
p5.js version
main branch
Web browser and version
Firefox, Chrome
Operating System
macOS 14
Steps to reproduce this
Steps:
filter()
The uniforms don't get passed in or updated.
Snippet:
Live: https://editor.p5js.org/davepagurek/sketches/IQyixHYPt
Causes
It seems to be because of this section of code:
p5.js/src/webgl/p5.RendererGL.js
Lines 1050 to 1059 in 3d62084
If you switch filter shaders from one to another, it creates a new shader object. This means that the shader actually being run is not the one you are setting the uniforms on.
The text was updated successfully, but these errors were encountered: