resonance 1.0.1
Loading...
Searching...
No Matches
pitcher.h
Go to the documentation of this file.
1#pragma once
2
3#include "app/msgsink.h"
4#include "app/msgsource.h"
5#include "app/ticktask.h"
6#include "sch/tickclock.h"
7
34class Pitcher : public MsgSink, public MsgSource, public TickTask {
35public:
44 explicit Pitcher(Sch::TickClock *pClock) : TickTask(pClock, Sch::Tick(kBarPeriod).mTick, 0) {
45 }
46
54 virtual ~Pitcher() {
55 }
56
58 static constexpr int kBarPeriod = 1920;
59};
Receiver of engine messages.
Definition msgsink.h:37
Sender of engine messages, which stores the list of sinks that receive them.
Definition msgsource.h:26
static constexpr int kBarPeriod
The TickTask period, one bar of 1920 ticks.
Definition pitcher.h:58
Pitcher(Sch::TickClock *pClock)
Construct the three bases, the TickTask one to run every bar.
Definition pitcher.h:44
virtual ~Pitcher()
Inline.
Definition pitcher.h:54
Pausable view of scheduler time, together with the tempo that maps it to a song position.
Definition tickclock.h:40
TickTask(Sch::TickClock *pClock, int nPeriod, int bAligned)
virtual int Tick(int nElapsedTicks)=0
Run the task.
Scheduling of timed commands.
Definition activefilter.h:9