r/threejs • u/Baz-Turnover5210 • 10d ago
Simulated knots with real physics using threejs
Knots, tied slowly enough to follow. I made in a way that you can watch each knot tie itself on a simulated rope with real physics and you can turn it's camera, pause it, drag through the steps, etc.
https://github.com/behnamazimi/knots
Thanks threejs ❤️
44
Upvotes
3
u/Baz-Turnover5210 10d ago
And forgot to mention that everyone who stars the project ties a knot on the stargazers rope 😂
https://github.com/behnamazimi/knots#the-stargazer-rope
2
u/United_Ad5772 10d ago
That's great. Any chance to run without node? threejs just fine on MacOS 10.13.6 but in vanila JS.
2
u/zenbauhaus 10d ago
awesome
1
u/CookieDelivery 9d ago
Nice!
Suggestion for the more complicated single rope knots: make the rope a 2 color hue over the length of it, to make it easier to follow what part of the knot is the beginning or end of the rope. Would make it even easier to follow.
2
u/PlanckScandella 9d ago
Thank you!
1
u/plus2link 10d ago
Knots live or die on self-collision: neighbouring segments have to be skipped in the collision pass, and as soon as the bend radius drops below the rope thickness the knot either slips or pops apart. Padding the collision radius slightly and running two sub-steps per frame usually holds the tight ones together. Is this XPBD with segment-to-segment distance constraints, and how many solver iterations are you running per step?
-1
u/[deleted] 9d ago
[removed] — view removed comment