jsbean / ArithmeticTools

Basic arithmetic types and operations
MIT License
3 stars 0 forks source link

Implement Interpolation #94

Open jsbean opened 7 years ago

jsbean commented 7 years ago

Extract from Rhythm, and implement generically. See: dn-m/Rhythm/issues:40.

jsbean commented 7 years ago

Just spit-ballin' here:

In order to make this process generic, for more types than just Tempo over MetricalDuration, we could do the following?:

jsbean commented 7 years ago

Or, perhaps the InterpolationProtocol could be much lighter:

protocol InterpolationProtocol {
    let start: YType
    let end: YType
    let length: XType
    func y(for x: XType) -> YType
}