bullet physics branch - baking keyframes

when baking physics animations, i’m finding that it will randomly add or subtract full revolutions to baked keyframes, meaning that any attempt to time remap keyframes creates animation havok. i can go through and delete the erroneous keyframes, however when there are on the order of 100 objects, this becomes impractical.

anyone have any tips to avoid this or know of any secret functions for deleting “bad” keyframes?

In the graph editor you can select multiple keyframes at once and then delete them, I think.

thanks for that suggestion! although with a lot of moving pieces it still becomes incredibly time consuming as you can’t really work with multiple pieces selected or the graph editor becomes unintelligible.


anyway, i started to write myself a python script to correct the added revolutions, but soon discovered:

a) i actually just recoded something already in blender, called the “discontinuity filter” which attempts to do the same thing, but still runs into problems because,

b) sometimes the jumps in fcurve values aren’t simply added revolutions, but weird re-mixings of x,y,z channels that are presumably to avoid gimbal lock.

so in the end, it seems like there is currently no easy fix for re-timing baked physics after the fact. so instead the route i’m taking animating the simulation speed in the scene settings, to get sort of the desired result. still miss being able to fine tune in the graph editor, though!