Hi, Im having trouble baking the pose locations of this armature into IPO’s
Is it even possible- the file below has an armature with bones constrained to empties, Id like to remove the empties bit keep the same animation in the pose bones IPOs
Unfortunately you can’t bake constraints that use objects outside the Armature (Empties) for Targets; in that case there’s no Action on your Armature to bake. (I assume you wrote DefaultAction with Python?).
Anyhow, I deleted your armature and used JB Perins Empties2Armature on the empties (had to change ‘Hips’ to '_Hips) and it wrote baked actions to all bones so you better scour his script.
%<
Hopefully Cambo can combine the best of his script and JB Perins’.
I used both scripts on a 1,000 frame mocap.
Cambo’s script imports it in ~6seconds, albeit with the problems he mentions, while JB’s script works but took ~30 minutes to complete !
JB’s also seemed to generate a ton of more data, making the timeline, action window and NLA editor “scrubbers” all but unuseable on my machine. The difference appears to be in the IPO window where it looks like the JB script has written all the keyframes, while Cambo’s script has written the curves without the keyframes.
Mike
Baked Actions do have keyframes on every frame.
The empties to armatures script was not 100% accurate, When I tried it some bones were noticible out by a few deg. so IMHO Its not an option to copy that.
I’m not suggesting you use that code, but see how he writes the Action Ipos from the empties. That’s why I asked about how you got DefaultAction; was that written in Python (in the file I downloaded) or did you hit the Bake button before uploading it? Because it wrote every bone to the default position for every frame. You know better than me but I was thinking that if you see how he wrote the action you could then use your own math.
%<
Some progress,
Rather then messing about with BVH, I thaught Id make a bake action script that worked like Blenders BAKE should.
http://blenderartists.org/forum/showthread.php?t=72839
This works except in cases where the bone if offset from its parent
but its a long way ahead from what I had before.
At the moment it dosent actually make an action but thats trivial. most improtant thing is to get the correct keyframes.