2 #include <halp/audio.hpp>
3 #include <halp/callback.hpp>
4 #include <halp/controls.hpp>
5 #include <halp/meta.hpp>
9 namespace ClassicalBeat
13 halp_meta(name,
"Beat Metronome")
14 halp_meta(c_name,
"ImpulseMetronome")
15 halp_meta(category,
"Control/Generators")
16 halp_meta(author,
"ossia score")
17 halp_meta(manual_url,
"https://ossia.io/score-docs/processes/control-utilities.html#impulse-metronome")
18 halp_meta(description,
"A simple metronome - outputs a bang on the current tick")
19 halp_meta(uuid,
"1c185139-04f9-492f-8b4a-000dd4428990")
23 halp::timed_callback<
"out"> out;
26 using tick = halp::tick_musical;
27 void operator()(
const halp::tick_musical& tk)
29 using namespace ossia;
30 if(tk.start_position_in_quarters < tk.end_position_in_quarters)
32 const auto f = [&](int64_t start_sample) { outputs.out(start_sample); };
Definition: ClassicalBeat.hpp:12