MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ schedule_pattern() [4/4]

template<std::incrementable Index = uint64_t, typename Values, typename Callback, typename Durations = std::vector<double>>
requires Kriya::PatternValues<Values, Index> && Kriya::PatternCallback<Callback, Kriya::pattern_value_t<Values, Index>> && Kriya::PatternDurations<Durations>
void MayaFlux::schedule_pattern ( Values values,
Callback callback,
Durations durations,
std::string name = "",
Vruta::ProcessingToken token = Vruta::ProcessingToken::SAMPLE_ACCURATE )

Schedules a typed pattern spaced by durations.

Template Parameters
IndexStep index type, default uint64_t
Parameters
valuesCallable from the step index to any value, a range played once, or recurring(range)
callbackCallable that takes the generated value, or the range element by reference
durationsA list of seconds, a TimeMap, or a callable from a pass number to a range of seconds
nameName of the pattern task (optional but recommended)
tokenProcessing token to determine which scheduler rate to use (default: SAMPLE_ACCURATE)

Forwards to Kriya::pattern, which describes the forms. schedule_pattern(gen, cb, { 0.25, 0.5 }) selects this overload.

Definition at line 162 of file Chronie.hpp.

163{
164 schedule_task(name, Kriya::pattern<Index>(std::move(values), std::move(callback), std::move(durations), token));
165}
std::shared_ptr< Vruta::Routine > pattern(std::function< std::any(uint64_t)> pattern_func, std::function< void(std::any)> callback, std::function< bool(uint64_t)> ready, Vruta::ProcessingToken token)
The std::any, uint64_t form of the condition driven pattern.
Definition Pattern.cpp:5
void schedule_task(const std::string &name, Vruta::SoundRoutine &&task, bool initialize)
Schedules a new sound routine task.
Definition Chronie.cpp:103

References MayaFlux::Kriya::pattern(), MayaFlux::Vruta::SAMPLE_ACCURATE, and schedule_task().

Here is the call graph for this function: