Status Cloth: Today's Cloth Simulation and the Role of Machine Learning

1Article by Yuri Ilyin
In the field of traditional art, there are certain indicators of the skill of a painter or a sculptor. The quality of cloth folds is among them. It takes years, if not decades, for traditional artists to achieve mastery in depicting cloth. Some of the greatest names in the history of Western art owe the honour precisely to their excellence at representing drapings - on canvas or in stone. Gian Lorenzo Bernini, for example, one of the creators of the Baroque style of sculpture, is exalted for his incredible depiction of cloth in marble. And for a very good reason:

Reference: Wikimedia
Incidentally, cloth simulation is a challenging matter for CG artists as well.
Soft Physics: Still a Hard Nut to Crack
Simulating convincing cloth is less computationally demanding than simulating fluids, of course, but it is still a process involving physics and interaction of cloth and underlying objects. So getting physically correct and visually convincing results may still pose a problem.
When Pixar Animation Studios was working on their masterpiece "Up!" in the second half of the 2000s, they had to develop their own programs to simulate cloth on the caricatured humans - it proved to be more difficult than to create and animate 10,000 balloons flying the house into the sky!
These days the Pixar team includes the 'digital tailors' who have a sole responsibility to develop clothing pieces for all the characters.
Business Insider has an interesting article/video that covers Pixar's workflow dedicated to cloth simulation. Particularly notable is that every next animated feature by Pixar tends to require more rendering power than the previous one, and the advancements in the cloth simulation toolset is one of the reasons for that.
"It's Pixar's blending of state-of-the-art technology grounded in hard math and physics with imaginative fashion and art direction that makes its costume-design language so appealing", the article reads.
On the other hand, there are recent advancements in the real-time cloth simulations, like those in the Unreal Engine 5. It might have just revolutionized the way cloth is depicted in the real-time environment. But more of that later.
The Traditional Routes
Traditionally - as much as it may be called a tradition at all - there are three types of cloth simulation used in CG: physical, particle/energy and geometric. The last one, in fact, is only good for static renders.
Physics-based technique treats cloth like a grid of particles connected with springs. This allows the model to account for stretch or tension, stiffness, and weight.
It is then described by a relatively simple equation, and as such it is probably the least computationally intensive method usable in the dynamic environment.
Particle/energy methods are more complex: the dynamic cloth is treated as a network of particles interacting directly: it is the energy interactions of the particles that are used to determine the cloth's shape at any given moment.
Geometric methods have been known since the mid-1980s, when Jerry Weil devised a way to approximate the cloth as a collection of cables and using hyperbolic cosine (catenary) curves. Again, it's not quite good for dynamic cloth simulation, but does a fine job for static renders.
Today every professional 3D graphics suite has some kind of cloth sim.
Houdini uses the Vellum solver - a simulation framework that uses extended Position Based Dynamics. Its main advantage is "controllability, stability, and ability to produce believable results quickly". Other than cloth it can also be used to create hair, soft bodies, balloons, and grains.

Reference: SideFX
Artists familiar with other cloth simulation tools (like the one in Blender) know how much of an issue stability can be. At the same time video demos showing the dynamic cloth simulation in action look very realistic: the cloth behaves just the way it should.
Maya has nCloth as its primary weapon for cloth simulation.
When a mesh is marked as an nCloth object, vertices are considered 'particles', edges are considered 'links', and for every particle there are also cross links added automatically. nCloth can be used for rigid body visualization too.
3ds Max has a combo of Cloth and Garment Maker modifiers complementing each other. Garment Maker is intended for designing clothes from 2D splines, "similarly to the way real clothes are made, by stitching together flat pieces of cloth."
How computationally intensive it is depends on, of course, the number of polygons involved - the finer the mesh is, the more time it takes to compute the cloth behavior, but the more believable the result is. The same is true for every cloth sim, apparently.
Blender has its own cloth simulation system, pretty robust, albeit comparably slowish. It may be difficult to get a firm grasp on it at first, but once you're on good terms with it, results can be great. Besides a few years ago the suites developers added a cloth deformation brush for sculpting mode, that if used properly, can deform mesh in a very cloth-y way.
Then there are standalone solutions like Clo3D and Marvelous Designer.
Clo3D is more tailored (pun intended) for fashion design/apparel development thanks to its wide range of tools.
Marvelous Designer is more focused on visual fidelity and animation. Lately it has become a de-facto industry standard, enabling extremely detailed apparel and very efficient simulation of complex fabric movements.

Reference: Marvelous Designer
It also integrates just fine with Maya, Blender, Max, Cinema 4D, etc. Blender users acknowledge that Marvelous Designer is just way better at anything pertaining to cloth than Blender's own toolset.
It is necessary to mention that, when it comes to animation, cloth interactions with other objects and deformations need to be computed for each frame.
In Blender it's a torturously long process, and a wrong setting may result in something very ugly, requiring to 'rebake' everything. Besides, the resulting cache may grow blasphemously huge.
But it's just the way it works.
Big Deal with ML
And what about the presumed revolution from Epic Games? Unreal Engine 5 introduced the Machine Learning Cloth Simulation System.
From the description:
"The system provides higher fidelity than the traditional physics-based model by using a trained dataset that can be used in real-time to produce results that were previously only achievable with offline simulation".
Looks like a good bid for victory, even though it still requires a lot of preparation effort: literally, training a model based on the in-game character's skeletal pose.

Reference: Epic Games
For AAA game development, it is probably the best route to take. Given that Unreal has already established a foothold in cinema and TV, it's entirely possible that the ML-based approach to cloth simulation will eventually make its way into big-budget productions as well.





























