Simon built this awesome animation that looks and moves like a hammock on Sunday, a coding challenge on Daniel Shiffman’s channel. In this challenge Simon used the toxiclibs physics library to create a 3D cloth in Processing (Java). Creating a 2D cloth involved programming particles and springs, looping them to one single row and later looping them to form a grid.
After the 2D cloth was ready, Simon turned it into a 3D cloth by adding the z-axis.