{"id":19848756,"url":"https://github.com/etcwilde/cloth","last_synced_at":"2026-05-14T17:02:45.616Z","repository":{"id":80177772,"uuid":"51115580","full_name":"etcwilde/Cloth","owner":"etcwilde","description":"Cloth Simulation","archived":false,"fork":false,"pushed_at":"2016-03-04T17:59:31.000Z","size":150,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-28T23:03:42.598Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/etcwilde.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-02-05T00:22:26.000Z","updated_at":"2016-02-17T21:12:56.000Z","dependencies_parsed_at":null,"dependency_job_id":"4617e0c8-6297-4f4a-8077-a9997f05df10","html_url":"https://github.com/etcwilde/Cloth","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/etcwilde/Cloth","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etcwilde%2FCloth","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etcwilde%2FCloth/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etcwilde%2FCloth/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etcwilde%2FCloth/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/etcwilde","download_url":"https://codeload.github.com/etcwilde/Cloth/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/etcwilde%2FCloth/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33034788,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-13T13:14:54.681Z","status":"online","status_checked_at":"2026-05-14T02:00:06.663Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-12T13:18:15.781Z","updated_at":"2026-05-14T17:02:45.599Z","avatar_url":"https://github.com/etcwilde.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cloth\n\n![Cloth](docs/cloth.png)\n\nEvan Wilde 2016\n\nThis is a simple 12-spring spring-mass cloth simulation. It includes a cloth, a\nuser-camera, a quaternion camera, and a spline camera. The user-camera is a full\narcball implementation, allowing rotations on any axis.\n\n## Usage Instructions\n\n### General:\n\n- c: Rotate through camera modes\n- f: Toggles the fan\n- SPACE: Toggles the simulation\n\n### User Camera:\n\n- CTRL + Middle Mouse Click: Smooth Dolly\n- Scroll Wheel: Incremental Dolly\n- SHIFT + Middle Mouse Click: Track\n- Middle Mouse Click: Rotate View\n\n### Quaternion Camera:\n\nThe quaternion camera has no user inputs.\n\nNote: This one is meant to just sit there and spin. It is pretty funny looking,\nthough it is not my fault if you get sick, consider yourself warned.\n\n### Spline Camera:\n\nThe spline camera has no user inputs\n\n## Further Explanation\n\nEach inner mass is connected by 12 springs to the other masses. These springs can be\nbroken down into three sets of four springs. The first set of springs controls the\nstretching of the cloth. The second set of springs controls the shearing of the\ncloth. The third set of springs controls the bending of the cloth.\n\n![Springs](docs/springs.png)\n\nThe stretch springs connect each mass to the mass directly above, below, right and\nleft of the mass. The shear springs connect the mass to the masses diagonal to the\nmass. The bend springs connect each mass to the mass two above, two below, and two\nto the right and left of the mass.\n\nThe springs currently use a basic Euler integrator, which can misbehave in rather\ndramatic ways if the spring constants and masses are not set to \"nice\" values.\n\n## Future Work\n\nThis probably won't happen, but is probably a good thing to have.\n\n- Add self-collision detection and handling to the cloth.\n- Replace the wireframe with a triangulated mesh\n- Replace the Euler integrator with something better behaved\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fetcwilde%2Fcloth","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fetcwilde%2Fcloth","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fetcwilde%2Fcloth/lists"}