clockblocks.utilities.set_beat_length_targets
- clockblocks.utilities.set_beat_length_targets(beat_length_targets: Sequence[float], whens: Sequence[ResolvableMoment], curve_shapes: Sequence[float] = None, truncate: bool = True, align_to: ResolvableMoment | Sequence[ResolvableMoment | None] = None) None[source]
Set several beat-length targets at once, building a multi-segment tempo curve on the current clock. Forwards to
set_beat_length_targets(); acts on the currently active clock. Raises NoActiveClockError if there is no active clock.- Parameters:
beat_length_targets – the beat length to arrive at for each segment, in seconds per beat.
whens – the arrival moment for each target (same length as
beat_length_targets).curve_shapes – optional per-segment curve shapes (same length), or
Nonefor all-linear.truncate – if
True, discard any tempo curve already scheduled past the current beat first.align_to – optional; align whole runs of segments to a phase/coordinate. See
set_beat_length_targets().