19#ifndef DRUMSTICK_ALSAPORT_H
20#define DRUMSTICK_ALSAPORT_H
32#if defined(DRUMSTICK_STATIC)
33#define DRUMSTICK_ALSA_EXPORT
35#if defined(drumstick_alsa_EXPORTS)
36#define DRUMSTICK_ALSA_EXPORT Q_DECL_EXPORT
38#define DRUMSTICK_ALSA_EXPORT Q_DECL_IMPORT
60 explicit PortInfo(snd_seq_port_info_t* other);
66 int getSizeOfInfo()
const;
70 QString getClientName()
const;
71 const snd_seq_addr_t* getAddr();
73 unsigned int getCapability();
74 unsigned int getType();
75 int getMidiChannels();
80 int getPortSpecified();
81 void setClient(
int client);
82 void setPort(
int port);
83 void setAddr(
const snd_seq_addr_t* addr);
84 void setName( QString
const& name );
85 void setCapability(
unsigned int capability);
86 void setType(
unsigned int type);
87 void setMidiChannels(
int channels);
88 void setMidiVoices(
int voices);
89 void setSynthVoices(
int voices);
90 void setPortSpecified(
int val);
94 bool getTimestamping();
95 bool getTimestampReal();
96 int getTimestampQueue();
97 void setTimestamping(
bool value);
98 void setTimestampReal(
bool value);
99 void setTimestampQueue(
int queueId);
103 void freeSubscribers();
104 void setClientName(QString name);
107 snd_seq_port_info_t* m_Info;
108 QString m_ClientName;
137 void unsubscribeAll();
138 void unsubscribeTo( QString
const& name );
139 void unsubscribeTo(
PortInfo* port );
140 void unsubscribeTo(
const snd_seq_addr_t* addr );
141 void unsubscribeFrom( QString
const& name );
142 void unsubscribeFrom(
PortInfo* port );
143 void unsubscribeFrom(
const snd_seq_addr_t* addr );
145 void subscribeTo(
int client,
int port );
146 void subscribeTo( QString
const& name );
147 void subscribeFrom(
PortInfo* port );
148 void subscribeFrom(
int client,
int port );
149 void subscribeFrom( QString
const& name );
150 void subscribeFromAnnounce();
151 void updateSubscribers();
156 void updateConnectionsFrom(
const PortInfoList& desired);
158 static bool containsAddress(
const snd_seq_addr_t* addr,
const PortInfoList& lst);
160 void applyPortInfo();
161 QString getPortName();
162 void setPortName( QString
const& newName);
164 unsigned int getCapability();
165 void setCapability(
unsigned int newValue);
166 unsigned int getPortType();
167 void setPortType(
unsigned int newValue);
168 int getMidiChannels();
169 void setMidiChannels(
int newValue);
171 void setMidiVoices(
int newValue);
172 int getSynthVoices();
173 void setSynthVoices(
int newValue);
174 bool getTimestamping();
175 bool getTimestampReal();
176 int getTimestampQueue();
177 void setTimestamping(
bool value);
178 void setTimestampReal(
bool value);
179 void setTimestampQueue(
int queueId);
208 void freeSubscriptions();
The QObject class is the base class of all Qt objects.
void detached(drumstick::ALSA::MidiPort *port)
Signal emitted when the port is detached from a MidiClient.
void attached(drumstick::ALSA::MidiPort *port)
Signal emitted when the port is attached to a MidiClient.
void subscribed(drumstick::ALSA::MidiPort *port, drumstick::ALSA::Subscription *subs)
Signal emitted when an internal subscription is done.
void midiClientChanged(drumstick::ALSA::MidiPort *port, drumstick::ALSA::MidiClient *seq)
Signal emitted when the MidiClient has changed.
Port information container.
QList< MidiPort * > MidiPortList
List of Ports instances.
QList< PortInfo > PortInfoList
List of port information objects.
QList< Subscription > SubscriptionsList
List of subscriptions.
QList< Subscriber > SubscribersList
List of subscribers.
Classes managing ALSA sequencer subscriptions.