Updated this demo with more springs between the nodes, so the cloth behaves better, though at a performance cost, a lot higher CPU load. Also added a standard GL path for those without GLSL, so it should run at all cards now, but with reduced quality for those without GLSL.
A little credit goes to Kristof since I finally got around to actually read the ShaderX book I have had some time and found his nice article about cloth simulation, so I used some of the tips there for how to set up the springs.
A little credit goes to Kristof since I finally got around to actually read the ShaderX book I have had some time and found his nice article about cloth simulation, so I used some of the tips there for how to set up the springs.