https://github.com/matusson/ucloth
Burst-based Unity cloth simulation
https://github.com/matusson/ucloth
burst-compiler unity unity3d
Last synced: 8 months ago
JSON representation
Burst-based Unity cloth simulation
- Host: GitHub
- URL: https://github.com/matusson/ucloth
- Owner: Matusson
- License: mit
- Created: 2023-02-03T20:43:16.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2023-05-23T17:03:40.000Z (about 3 years ago)
- Last Synced: 2025-08-08T06:24:47.011Z (11 months ago)
- Topics: burst-compiler, unity, unity3d
- Language: C#
- Homepage:
- Size: 1.02 MB
- Stars: 78
- Watchers: 5
- Forks: 15
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Prototype Burst-based cloth simulation for Unity

### WARNING: This project is not production ready and no further work will be done. No PRs will be accepted. It is primarily intented to be a learning resource.
## Summary
This package implements custom cloth physics for Unity. It runs on the CPU, doing most of the simulation work on a background thread (some main thread cost still applies). It utilizes the Jobs system for partial multithreading - a single cloth object can't be split into multiple threads, but two cloth objects can be simulated at the same time on different threads.
Note that by default, this is a purely visual effect and all physics support only one-way coupling (the cloth will not affect other physics objects). You can implement custom logic that interacts with the cloth. A short introduction to the API is included in [API.md](/Documentation/API.md)
The project contains many issues that would need to be fixed if you want to use it in a production environment. A list of known ones is included in [Issues.md](/Documentation/Issues.md). I do not take responsibility for any, and I will not provide support. You are free to use this project as a starting point or a basic learning resource for your own simulation.
See [Setup.md](/Documentation/Setup.md) for information on how to set up the simulation, and [UCClothReference.md](/Documentation/UCClothReference.md) for a brief explanation of all parameters.
## Installation
This repository is a package compatible with UPM. Open the Package Manager window in Unity and click the "plus" icon. Select "Add packager from git URL" and paste the link to this repository (https://github.com/Matusson/UCloth.git). Alternatively, you can also clone the repo and add package from disk.
Designed for Unity 2021.3.
## License
This project is provided as-is under the MIT license.