Unity real time cloth simulation in Unity?

dom.lestat

New Member
Mar 29, 2024
2
0
Hi. Not sure if this is the right place to be asking this since most people here seen to be doing pre-rendered graphic novels, but it's worth a shot.
I'm new to developing 3D games and wanted to try something with VR. I've seen that a lot existing VR games like "VR Kanojo" or "Girl stuck in a hole" (among others) have some type of real time cloth simulation for the skirt, so the player can pull it up or off with the virtual hands. They are also not very CPU demanding from what I can see.

It really adds to the immersion so it's a must for me, but I've been struggling to find resources/tutorials related to the subject. Anybody knows where should I start searching to learn to do something like this? A tutorial, tool, search keyword, anything would help.

Thanks
 

60Points

Newbie
Game Developer
Nov 1, 2019
57
91
For clothing simulation, you have several options.

-The one included in Unity (I don't recommend it).
-Creating one based on rigidbodies and fixed joints, for example. (It reacts to collisions, and you can hold it using a joint in the hand that connects the rigid body, for instance.)
-DynamicBone: You can create something decent, very easy to use. (It has collisions to repel and attract, so you could use it for grabbing.)
-MagicaCloth: It yields pretty good results; I haven't tested it extensively.
-ObiCloth: Undoubtedly the most realistic, based on particles. It collides quite well against primitive colliders or distance fields. I quite like it; it's complex to master, but once you do, it's excellent. Currently, particle calculations are CPU-based, but I believe it will be available for GPU in a couple of months.




The choice will depend on the level of realism you want to achieve and the performance impact you can afford.

If you're aiming for a low vertex count and each part of the garment with bones, DynamicBone will undoubtedly be useful.

If you're aiming for high realism and don't mind the performance impact, ObiCloth is the way to go.
 
  • Red Heart
Reactions: dom.lestat

dom.lestat

New Member
Mar 29, 2024
2
0
For clothing simulation, you have several options.

-The one included in Unity (I don't recommend it).
-Creating one based on rigidbodies and fixed joints, for example. (It reacts to collisions, and you can hold it using a joint in the hand that connects the rigid body, for instance.)
-DynamicBone: You can create something decent, very easy to use. (It has collisions to repel and attract, so you could use it for grabbing.)
-MagicaCloth: It yields pretty good results; I haven't tested it extensively.
-ObiCloth: Undoubtedly the most realistic, based on particles. It collides quite well against primitive colliders or distance fields. I quite like it; it's complex to master, but once you do, it's excellent. Currently, particle calculations are CPU-based, but I believe it will be available for GPU in a couple of months.




The choice will depend on the level of realism you want to achieve and the performance impact you can afford.

If you're aiming for a low vertex count and each part of the garment with bones, DynamicBone will undoubtedly be useful.

If you're aiming for high realism and don't mind the performance impact, ObiCloth is the way to go.
Thanks for the thoughtful reply, it really helped. Obicloth looks amazing but for VR specially I would be uncomfortable pushing the simulation this much because VR on itself can be very taxing to the average player's PC. I'm gonna try DynamicBone first and see how it goes
 

WarmGourd

New Member
Mar 30, 2024
3
1
Hopefully you've found dynamic bone to be suitable, but just in case you're looking for something a little more feature rich at a comparable performance cost, you might want to try EZSoftBone on Github.

It was converted to open source some years ago and hasn't been updated much since but still works absolutely fine in the latest Unity versions. It has built in wind forces for that extra bit of realism and supports all of the standard Unity collider types out of the box.

Good luck with development.
 
May 19, 2022
114
59
For clothing simulation, you have several options.

-The one included in Unity (I don't recommend it).
-Creating one based on rigidbodies and fixed joints, for example. (It reacts to collisions, and you can hold it using a joint in the hand that connects the rigid body, for instance.)
-DynamicBone: You can create something decent, very easy to use. (It has collisions to repel and attract, so you could use it for grabbing.)
-MagicaCloth: It yields pretty good results; I haven't tested it extensively.
-ObiCloth: Undoubtedly the most realistic, based on particles. It collides quite well against primitive colliders or distance fields. I quite like it; it's complex to master, but once you do, it's excellent. Currently, particle calculations are CPU-based, but I believe it will be available for GPU in a couple of months.




The choice will depend on the level of realism you want to achieve and the performance impact you can afford.

If you're aiming for a low vertex count and each part of the garment with bones, DynamicBone will undoubtedly be useful.

If you're aiming for high realism and don't mind the performance impact, ObiCloth is the way to go.
Is this info really up to date? I haven't heard obicloth mentioned in years. Btw here's Magicka cloth 2 in
 

60Points

Newbie
Game Developer
Nov 1, 2019
57
91
Is this info really up to date? I haven't heard obicloth mentioned in years. Btw here's Magicka cloth 2 in
Yes, it has evolved a lot. I tested the betas with GPU and they have more than impressive results. But like all OBI assets, they can become highly complex depending on what you want to achieve and how much of a perfectionist you are. Magicacloth is very good for achieving good results at a basic/intermediate level.
 
May 19, 2022
114
59
Yes, it has evolved a lot. I tested the betas with GPU and they have more than impressive results. But like all OBI assets, they can become highly complex depending on what you want to achieve and how much of a perfectionist you are. Magicacloth is very good for achieving good results at a basic/intermediate level.
Yes, it has evolved a lot. I tested the betas with GPU and they have more than impressive results. But like all OBI assets, they can become highly complex depending on what you want to achieve and how much of a perfectionist you are. Magicacloth is very good for achieving good results at a basic/intermediate level.
Alright I had to sort by new to get a YouTube video more recent than 3 years but you weren't
Although I didn't see any multi layering like in the magicloth vid I sent but I assume that's possible? Slightly off topic Q but how's the state of skeletal animation? I know there's some built in tools but is there a plugin you prefer or know of for in-engine animation? Im very much UE pilled but I might start dabbling in unity again for this