jonobr1 / Physics

A requirified port of Traer Physics from Processing to JavaScript.
http://jonobr1.github.com/Physics
Other
195 stars 21 forks source link

Particles with size #10

Open deblocker opened 7 years ago

deblocker commented 7 years ago

What about add width & height to particles? Beside changes in distance calculation, what other changes would be required?

jonobr1 commented 7 years ago

I'm not totally sure what would have to change to implement this. In your opinion how would you like to use width and height attributes on particles?

deblocker commented 7 years ago

I need to implement a force-driven constrained layout for rectangular shapes, you could think something like cola.js (or maybe gridstack.js) but with more emphasis on x-y constraints. So for example, springs shall be attached to a side of the rectangle, particles shouldn't overlap and also not stick out from given boundaries.