drumstick 2.9.0
C++ MIDI libraries using Qt objects, idioms, and style.
|
Queue management. More...
#include <alsaqueue.h>
Public Member Functions | |
MidiQueue (MidiClient *seq, QObject *parent=nullptr) | |
Constructor. More... | |
MidiQueue (MidiClient *seq, const QueueInfo &info, QObject *parent=nullptr) | |
Constructor. More... | |
MidiQueue (MidiClient *seq, const QString name, QObject *parent=nullptr) | |
Constructor. More... | |
MidiQueue (MidiClient *seq, const int queue_id, QObject *parent=nullptr) | |
Constructor. More... | |
virtual | ~MidiQueue () |
Destructor. | |
void | start () |
Start the queue. More... | |
void | stop () |
Stop the queue. More... | |
void | continueRunning () |
Start the queue without resetting the last position. More... | |
void | clear () |
Clear the queue, dropping any scheduled events. | |
void | setTickPosition (snd_seq_tick_time_t pos) |
Sets the queue position in musical time (ticks). More... | |
void | setRealTimePosition (snd_seq_real_time_t *pos) |
Sets the queue position in real time (clock) units: seconds and nanoseconds. More... | |
QueueInfo & | getInfo () |
Gets a QueueInfo object reference. More... | |
QueueStatus & | getStatus () |
Gets a QueueStatus object reference. More... | |
QueueTempo & | getTempo () |
Gets a QueueTempo object reference. More... | |
QueueTimer & | getTimer () |
Gets a QueueTimer object reference. More... | |
int | getUsage () |
Gets the queue usage flag. More... | |
void | setInfo (const QueueInfo &value) |
Applies a QueueInfo object to the queue. More... | |
void | setTempo (const QueueTempo &value) |
Applies a QueueTempo object to the queue. More... | |
void | setTimer (const QueueTimer &value) |
Applies q QueueTimer object to the queue. More... | |
void | setUsage (int used) |
Sets the queue usage flag. More... | |
Queue management.
This class represents an ALSA sequencer queue object.
Definition at line 200 of file alsaqueue.h.
|
explicit |
Constructor.
seq | An existing MidiClient instance |
parent | An optional parent object |
Definition at line 703 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_ERROR, and MidiClient::getHandle().
MidiQueue | ( | MidiClient * | seq, |
const QueueInfo & | info, | ||
QObject * | parent = nullptr |
||
) |
Constructor.
seq | An existing MidiClient instance |
info | A QueueInfo object reference |
parent | An optional parent object |
Definition at line 717 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_ERROR, and MidiClient::getHandle().
MidiQueue | ( | MidiClient * | seq, |
const QString | name, | ||
QObject * | parent = nullptr |
||
) |
Constructor.
seq | An existing MidiClient instance |
name | The name for the new queue |
parent | An optional parent object |
Definition at line 732 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_ERROR, and MidiClient::getHandle().
MidiQueue | ( | MidiClient * | seq, |
const int | queue_id, | ||
QObject * | parent = nullptr |
||
) |
Constructor.
Note: this constructor doesn't allocate a new queue, it uses an existing one.
seq | An existing MidiClient instance |
queue_id | An existing queue numeric identifier |
parent | An optional parent object |
Definition at line 748 of file alsaqueue.cpp.
void continueRunning | ( | ) |
Start the queue without resetting the last position.
This method should start running the queue from the last position set.
Definition at line 886 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
Referenced by SequencerOutputThread::run().
QueueInfo & getInfo | ( | ) |
Gets a QueueInfo object reference.
Definition at line 771 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
QueueStatus & getStatus | ( | ) |
Gets a QueueStatus object reference.
Definition at line 781 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
QueueTempo & getTempo | ( | ) |
Gets a QueueTempo object reference.
Definition at line 791 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
QueueTimer & getTimer | ( | ) |
Gets a QueueTimer object reference.
Definition at line 801 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
int getUsage | ( | ) |
Gets the queue usage flag.
Definition at line 842 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
void setInfo | ( | const QueueInfo & | value | ) |
Applies a QueueInfo object to the queue.
value | A QueueInfo object reference |
Definition at line 811 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
void setRealTimePosition | ( | snd_seq_real_time_t * | pos | ) |
Sets the queue position in real time (clock) units: seconds and nanoseconds.
pos | Real time (clock) position in seconds/nanoseconds. |
Definition at line 917 of file alsaqueue.cpp.
References SequencerEvent::getHandle(), and MidiClient::outputDirect().
void setTempo | ( | const QueueTempo & | value | ) |
Applies a QueueTempo object to the queue.
value | A QueueTempo object reference |
Definition at line 821 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
void setTickPosition | ( | snd_seq_tick_time_t | pos | ) |
Sets the queue position in musical time (ticks).
pos | Musical time in ticks. |
Definition at line 905 of file alsaqueue.cpp.
References SequencerEvent::getHandle(), and MidiClient::outputDirect().
Referenced by SequencerOutputThread::run().
void setTimer | ( | const QueueTimer & | value | ) |
Applies q QueueTimer object to the queue.
value | A QueueTimer object reference |
Definition at line 831 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
void setUsage | ( | int | used | ) |
Sets the queue usage flag.
used | 1 = client is allowed to access the queue, 0 = not allowed. |
Definition at line 852 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
void start | ( | ) |
Start the queue.
This method should start running the queue from the initial position.
Definition at line 862 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
Referenced by SequencerOutputThread::run().
void stop | ( | ) |
Stop the queue.
This method should stop running the queue.
Definition at line 873 of file alsaqueue.cpp.
References DRUMSTICK_ALSA_CHECK_WARNING, and MidiClient::getHandle().
Referenced by SequencerOutputThread::run().