Blender Git Loki
June 8, 2015, 13:09 (GMT) |
Initial fcurve simplification code. Notes: * This is own coocking, since it seems hard to find papers on simplifying already existing bezier curves, and we do not really need the 'generic' least-square fitting of bezier in a set of points, here. * It takes advantage of specificities of FCurves (e.g. only difference that matters here is Y value at same X frame, no vertical overlapping, etc.). * It gives reasonably good results, but could most likely be enhanced quite a bit still. * Only 'hooked' to bake action operator right now (needs more work to add it to graph editor too). * Ultimately should probably be redone in C. Would keep it in Python until we have a real good cleanup behavior though, much easier to experiment in later language. |