Closed micuat closed 5 years ago
And the issue becomes significant with larger texture size
I noticed that it has nothing to do with id; but the width/height parameter slows down the texture function: https://github.com/processing/p5.js/blob/5f6b4ab7e1c1a680186e52a9a1ac3f63450e8406/src/core/p5.Element.js#L148
Closing as I wasn't able to detect framerate changes in 0.7.2 with the included example. If you can still repro then feel free to post something here and I will repoen
I found that
texture(...)
is slow when the img/canvas tag to be bound does not have an id (example code at the bottom)Nature of issue?
Most appropriate sub-area of p5.js?
Which platform were you using when you encountered this?
Details about the bug:
Compare the framerate with / without line 12: https://alpha.editor.p5js.org/micuat/sketches/ry-6oxxkQ