Sandbox Logo

Alternative Curves + Editor

This is a replacement to the stock Curve structure, with improved performance and an expanded editor including features such as automatic tangents, pre/post-infinity controls, snapping, undo/redo, and more.

More performant?
At the time of publishing, the stock Curve asset uses O(n log n) time complexity to find and access keyframes because of the internal workings of ImmutableList. We use a single binary search and constant time array lookups, resulting in us instead running in O(log n) time.

Profiling shows AltCurve evaluation running at least 85% faster than the stock Curve evaluations in the worst case, only improving as more keyframes are added.

Shortcuts:
Navigation and View:
F: Focus view
Middle-Mouse: Create keyframe at location
Left-Mouse (Hold): Box select
Delete: Remove selected keyframes
Ctrl+A: Select all
Ctrl+Z: Undo
Ctrl+Y: Redo
Scroll: Zoom
Scroll (Shift): Zoom Vertical
Scroll (Ctrl): Zoom Horizontal

Snapping and Axis Locking:
Z: Toggle time snapping
X: Toggle value snapping
Alt (Hold): Disable snap
Shift (Hold): Lock keyframe movement axis

Keyframe Manipulation:
1: Cubic interpolation - Auto tangents
2: Cubic interpolation - Mirrored tangents
3: Cubic interpolation - Split tangents
4: Linear interpolation
5: Stepped/Constant interpolation
6: Flatten tangents

Source: github.com/jimbomcb/sbox-altcurves

Alternative Curves

An alternative Curve structure featuring better performance and editor features like undo, snapping, and automatic interpolation

Created
9/11/2024
Updated
9/18/2024
In Collections
Referenced By
Dependencies
Reviews
🥇 x 1