First efforts to combine the data generated by my boids simulator with my auto-walking algorithm were fraught with difficulty. 'Noisy' fcurves had loads of jitter on them due to some of the fuzzy approximation methods used by the boids sim to keep the simulations fast. Added to this as I was doing much of the calculations for the boids rotations using matrices or quaternions rather than Eulers, rotations would often flip from +/- 360 to 0 and back again. I wrote a quick 'filter and smooth' script which effectively corrects Euler flips and blurs the data generated by the sim to allow the walking algorithm to produce more regular leg movement.
Here's the first crash test dummy... not particularly exciting but at least it works now! Running is yet to be implemented and the walking algorithm falls apart if the distance the boid has to move in any given frame step is too large. Writing sub-frame steps would easily correct this however and would probably be faster than any more intelligent algorithms.
Stay tuned for more demos and hopefully in the near future some source code for you to disect.
Showing posts with label procedural walk. Show all posts
Showing posts with label procedural walk. Show all posts
Friday, 7 January 2011
Success at Last
Labels:
auto walker,
blender,
blender 2.5,
boids,
procedural walk,
python,
walking
Thursday, 6 January 2011
Leg Sequencing for the Auto-Walker
I've successfully implemented leg sequencing for the auto-walker I'm working on for the 'tube' project. Its not a 'strict' method like many other auto-walkers use. The legs can drift in and out of sequence if the bug turns a corner or so on, but the algorithm will then speed up or slow down each leg to reach the desired leg sequence order.
Hopefully by the end of the week I'll have stable enough source to release it!
Labels:
auto walker,
blender,
blender 2.5,
boids,
procedural walk,
python
Wednesday, 5 January 2011
Progress on the auto-walker
I spent most of yesterday just hitting dead ends. My code became far too complex and it was almost impossible to find bugs. I went for a full re-factor of the walking algorithm and now I'm getting much smoother motion. It takes a few frames of pre-roll to get the legs in order - notice some jittering in the first second or so as legs are hurriedly placed to stabilise the bug. By stabilisation I mean that if all the legs on one side of the bug (or in any given 'leg group' set by the user) become lifted then the algorithm will hurriedly place the leg which has been airborne the longest to keep the bug upright. Still no body motion, but I've made a preliminary start on leg sequencing.
Labels:
auto walker,
blender,
blender 2.5,
code,
procedural walk,
python,
walk cycle
Subscribe to:
Posts (Atom)