freshfork / p5.EasyCam

A p5.js library for easy 3D camera control.
https://freshfork.github.io/p5.EasyCam
MIT License
138 stars 33 forks source link

Importing p5.js with threejs #11

Open Binary010100 opened 3 years ago

Binary010100 commented 3 years ago

Can I use this 3d camera with three.js?

jwdunn1 commented 3 years ago

Sort of. The EasyCam library at present is coupled with the p5js renderer. Perhaps it could be decoupled at some point in the future. Meanwhile, there is the option of overlaying two canvases and using the p5 EasyCam instance to dynamically inform the threejs camera within the update loop. Here's how: https://editor.p5js.org/jwdunn1/sketches/NxiklckeZ (Not perfect, but reasonable.)

Binary010100 commented 3 years ago

Thank you so much !