Hi,
I'm trying to simulate a tree my first idea was to use spring/mass system to create soft body of the plant, problem with that approach was how to connect branches together without 1000's of springs
Secound attempt was to build system from rigid bodies , costraints + springs to give elsticity to joints... at the moment I've finished my litle construction,but it becomes unstable when frame rate drops to 40 fps and I haven't yet implemented springs into it...
any sugestions how to simulate complex plant like tree with 4 levels and 100 branches ?
thx
Physics of Plant
-
- Posts: 15
- Joined: Tue Jul 26, 2005 10:11 am
Re: Physics of Plant
Hi,Janusz wrote:Hi,
I'm trying to simulate a tree my first idea was to use spring/mass system to create soft body of the plant, problem with that approach was how to connect branches together without 1000's of springs
Secound attempt was to build system from rigid bodies , costraints + springs to give elsticity to joints... at the moment I've finished my litle construction,but it becomes unstable when frame rate drops to 40 fps and I haven't yet implemented springs into it...
any sugestions how to simulate complex plant like tree with 4 levels and 100 branches ?
thx
Depend on the quality you want to achieve, stiff springs mean stiff equations and you better try implicit integration.
1000 springs are easily handled by an implicit solver even using time steps on the order of 1/50.
You can use rotational springs instead of simple linear springs for your constraints.
BTW: You say that no springs are included in your simulator, so what you mean by 'it becomes unstable when frame rate drops to 40 fps'?
Regards,
Carlo Lanzotti
-
- Posts: 2
- Joined: Tue Oct 18, 2005 3:54 pm
- Location: Warsaw Poland
Hi,
I've made a small mistake writing point to point constraint connecting branches and it caused constraints to oscillate ... at the moment whole simulation is stable even at 5 fps. I still didn't manage to implement rotational constraint blocking twists at the joint.
I will try to research information on implicit integration any suggestion where to start ?
thanks Janusz Klaptocz
I've made a small mistake writing point to point constraint connecting branches and it caused constraints to oscillate ... at the moment whole simulation is stable even at 5 fps. I still didn't manage to implement rotational constraint blocking twists at the joint.
I will try to research information on implicit integration any suggestion where to start ?
thanks Janusz Klaptocz
-
- Posts: 15
- Joined: Tue Jul 26, 2005 10:11 am
Hi Janusz,Janusz wrote:Hi,
I've made a small mistake writing point to point constraint connecting branches and it caused constraints to oscillate ... at the moment whole simulation is stable even at 5 fps. I still didn't manage to implement rotational constraint blocking twists at the joint.
I will try to research information on implicit integration any suggestion where to start ?
thanks Janusz Klaptocz
I recommend you read the course paper written by David Baraff:
http://www.cs.cmu.edu/~baraff/sigcourse/notese.pdf
Feel free to ask on the subject if you need in depth explanations.
Best Regards,
Carlo Lanzotti
-
- Posts: 52
- Joined: Sat Oct 08, 2005 1:16 am
- Location: Itinerant
I would definitely go with a verlet-based integrator coupled with a simple relaxation solver using distance constraints... i.e. jakobsen style physics.
http://www.teknikus.dk/tj/gdc2001.htm
stable and fast, but not that accurate, but a truly accurate model of a tree isn't going to be anywhere near fast enough for real-time.
There was a talk at Game Developer Conference on extending the relaxation solver to handle orientation constraints, but I can't remember it's name. It used interpolations of quaternions.
- Michael Alexander Ewert
http://www.teknikus.dk/tj/gdc2001.htm
stable and fast, but not that accurate, but a truly accurate model of a tree isn't going to be anywhere near fast enough for real-time.
There was a talk at Game Developer Conference on extending the relaxation solver to handle orientation constraints, but I can't remember it's name. It used interpolations of quaternions.
- Michael Alexander Ewert