Does anyone know if it is possible to get access to a bone matrix on the previous frame with python? (or any offset value for that matter)

I'm trying to figure it out but it isn't possible to sample the fcurves, as that won't include parenting and constraints (there isn't any animation curves on the bone I want to control anyway)

And it also isn't possible to jump to the previous frame with frame_set(), as I'm trying to find a solution that will work in the viewport rather than just at playback (for animators to see the result while they are animating).

I've also looked into using Animation Nodes fo this. In the older versions of the add-on there was a 'Frame offset' on the Matrix Input Node (in the advanced node settings). This feature looks like it has been removed in the latest version.

So I'm after any ideas on how to get access to the bone matrix data on the previous frame using... (A) Python or (B) the latest version of animation nodes (2.1)

  • $\begingroup$ Seems a loaded question..as I believe I: Could work it out from the data, it is what blender is doing after all. Lots of matrices etc etc .. (not going to answer it just pointing out it's possible) Could in viewport jump using frame set, store some data, then jump back, only need to do it once. Would it be that noticeable? . Animation Nodes would be using a data store in shape or form (it ticks on a scene update handler last time I used it) $\endgroup$ – batFINGER Jun 25 '18 at 9:17
  • $\begingroup$ Oh hey @batFINGER, $\endgroup$ – waylow Jun 25 '18 at 10:53
  • $\begingroup$ Is this the THE @waylow that showed me how to do this one before that one was written? $\endgroup$ – batFINGER Jun 25 '18 at 11:00
  • $\begingroup$ Yep that's me. Yeah I might be trying to bash a square peg into a round hole with the solution that I want (which might not be possible) I'd like to figure out if there is a way to access the future or past matrix positions on the fly. I'm trying to figure out how much a car needs to steer based on where it came from, If that makes sense. But maybe storing that information is the only way it can work. $\endgroup$ – waylow Jun 25 '18 at 11:29
  • $\begingroup$ Did you ever check out the car rigs of ROUBAL? He used a mesh on a curve (the cars predetermined path) with curve modifier to position and steer. Then the car moves based on only one location component (mapped via the modifier) Kicked around in my head creating the curve on the fly (like dragging a rope behind) , with last spline pointing to where the car goes next based on current speed and steering. The idea was to "drive with drivers" with velocity and steering as only properties needed to animate. Was a bit like baking from game engine, without the game being fun. $\endgroup$ – batFINGER Jun 25 '18 at 12:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.