Does anyone know of Python code to both remove keyframe noise and also perform keyframe reduction somewhat like the timeline keyframe reduce function? I'm importing face capture FBX files produced by the Apple ARKit which contains multiple morphs with keyframes on every frame. Some keys have very small changes that produces a "vibration" look, or sudden changes "spikes" that I manually delete. Then I perform the keyframe reduce function on each morph not only to remove keys, but to create a nice smooth curve giving the animation a more fluid, natural look.
Another option is if anyone knows how (and if) the Cinema 4D keyframe reduce function can be called from Python.
I'm using Cinema 4D R21.
thank you for reaching out to us and welcome to the Cinema 4D development community, the Plugin Café.
Unfortunately, the "Key Reducer" and "Euler Filter" functions which can be found in Timeline Manager|Functions are not exposed in the Python or C++ SDK. Technically you can invoke most of the functions in Cinema 4D with their respective command id, in the case of "Key Reducer" you would have to invoke c4d.CallCommand(465001214). But since that functionality has a GUI and requires user inputs, this won't be very helpful in a script, as you would have then to make these inputs in the GUI and a simple script will block these.
So, your only option is to implement your own key reducing routines when you want a fully automatic workflow.
without any further questions or postings, we will consider this thread as solved by Friday the 4th, February 2022.
Thank you for your understanding,