raphaelameaume / fragment

[alpha] A web development environment for creative coding
https://fragment.tools
MIT License
828 stars 19 forks source link

Reset p5 matrix before sketch update #112

Closed raphaelameaume closed 6 months ago

raphaelameaume commented 6 months ago

The P5GLRenderer and P5Renderer are now calling .resetMatrix() before sketch update/draw calls in order to match the behaviour of p5.js used in the examples or the editor.

The absence of this call caused various issues due to the remaining of transforms of the p5 context and was preventing the port from p5.js working sketches to Fragment by copy-pasting them as it was initially intended.