ALSA project - the C library reference
Loading...
Searching...
No Matches
seq.c File Reference

Sequencer Interface. More...

Functions

const char * snd_seq_name (snd_seq_t *seq)
 get identifier of sequencer handle
 
snd_seq_type_t snd_seq_type (snd_seq_t *seq)
 get type of sequencer handle
 
int snd_seq_open (snd_seq_t **seqp, const char *name, int streams, int mode)
 Open the ALSA sequencer.
 
int snd_seq_open_lconf (snd_seq_t **seqp, const char *name, int streams, int mode, snd_config_t *lconf)
 Open the ALSA sequencer using local configuration.
 
int snd_seq_close (snd_seq_t *seq)
 Close the sequencer.
 
int snd_seq_poll_descriptors_count (snd_seq_t *seq, short events)
 Returns the number of poll descriptors.
 
int snd_seq_poll_descriptors (snd_seq_t *seq, struct pollfd *pfds, unsigned int space, short events)
 Get poll descriptors.
 
int snd_seq_poll_descriptors_revents (snd_seq_t *seq, struct pollfd *pfds, unsigned int nfds, unsigned short *revents)
 get returned events from poll descriptors
 
int snd_seq_nonblock (snd_seq_t *seq, int nonblock)
 Set nonblock mode.
 
int snd_seq_client_id (snd_seq_t *seq)
 Get the client id.
 
size_t snd_seq_get_output_buffer_size (snd_seq_t *seq)
 Return the size of output buffer.
 
size_t snd_seq_get_input_buffer_size (snd_seq_t *seq)
 Return the size of input buffer.
 
int snd_seq_set_output_buffer_size (snd_seq_t *seq, size_t size)
 Change the size of output buffer.
 
int snd_seq_set_input_buffer_size (snd_seq_t *seq, size_t size)
 Resize the input buffer.
 
size_t snd_seq_system_info_sizeof ()
 Get size of #snd_seq_system_info_t.
 
int snd_seq_system_info_malloc (snd_seq_system_info_t **ptr)
 Allocate an empty #snd_seq_system_info_t using standard malloc.
 
void snd_seq_system_info_free (snd_seq_system_info_t *obj)
 Frees a previously allocated #snd_seq_system_info_t.
 
void snd_seq_system_info_copy (snd_seq_system_info_t *dst, const snd_seq_system_info_t *src)
 Copy one #snd_seq_system_info_t to another.
 
int snd_seq_system_info_get_queues (const snd_seq_system_info_t *info)
 Get maximum number of queues.
 
int snd_seq_system_info_get_clients (const snd_seq_system_info_t *info)
 Get maximum number of clients.
 
int snd_seq_system_info_get_ports (const snd_seq_system_info_t *info)
 Get maximum number of ports.
 
int snd_seq_system_info_get_channels (const snd_seq_system_info_t *info)
 Get maximum number of channels.
 
int snd_seq_system_info_get_cur_clients (const snd_seq_system_info_t *info)
 Get the current number of clients.
 
int snd_seq_system_info_get_cur_queues (const snd_seq_system_info_t *info)
 Get the current number of queues.
 
int snd_seq_system_info (snd_seq_t *seq, snd_seq_system_info_t *info)
 obtain the sequencer system information
 
size_t snd_seq_client_info_sizeof ()
 get size of #snd_seq_client_info_t
 
int snd_seq_client_info_malloc (snd_seq_client_info_t **ptr)
 allocate an empty #snd_seq_client_info_t using standard malloc
 
void snd_seq_client_info_free (snd_seq_client_info_t *obj)
 frees a previously allocated #snd_seq_client_info_t
 
void snd_seq_client_info_copy (snd_seq_client_info_t *dst, const snd_seq_client_info_t *src)
 copy one #snd_seq_client_info_t to another
 
int snd_seq_client_info_get_client (const snd_seq_client_info_t *info)
 Get client id of a client_info container.
 
snd_seq_client_type_t snd_seq_client_info_get_type (const snd_seq_client_info_t *info)
 Get client type of a client_info container.
 
const char * snd_seq_client_info_get_name (snd_seq_client_info_t *info)
 Get the name of a client_info container.
 
int snd_seq_client_info_get_broadcast_filter (const snd_seq_client_info_t *info)
 Get the broadcast filter usage of a client_info container.
 
int snd_seq_client_info_get_error_bounce (const snd_seq_client_info_t *info)
 Get the error-bounce usage of a client_info container.
 
int snd_seq_client_info_get_card (const snd_seq_client_info_t *info)
 Get the sound card number.
 
int snd_seq_client_info_get_pid (const snd_seq_client_info_t *info)
 Get the owning PID.
 
const unsigned char * snd_seq_client_info_get_event_filter (const snd_seq_client_info_t *info)
 (DEPRECATED) Get the event filter bitmap of a client_info container
 
void snd_seq_client_info_event_filter_clear (snd_seq_client_info_t *info)
 Disable event filtering of a client_info container.
 
void snd_seq_client_info_event_filter_add (snd_seq_client_info_t *info, int event_type)
 Add an event type to the event filtering of a client_info container.
 
void snd_seq_client_info_event_filter_del (snd_seq_client_info_t *info, int event_type)
 Remove an event type from the event filtering of a client_info container.
 
int snd_seq_client_info_event_filter_check (snd_seq_client_info_t *info, int event_type)
 Check if an event type is present in the event filtering of a client_info container.
 
int snd_seq_client_info_get_num_ports (const snd_seq_client_info_t *info)
 Get the number of opened ports of a client_info container.
 
int snd_seq_client_info_get_event_lost (const snd_seq_client_info_t *info)
 Get the number of lost events of a client_info container.
 
int snd_seq_client_info_get_midi_version (const snd_seq_client_info_t *info)
 Get the MIDI protocol version number of a client_info container.
 
int snd_seq_client_info_get_ump_group_enabled (const snd_seq_client_info_t *info, int group)
 Get the UMP group filter status.
 
int snd_seq_client_info_get_ump_groupless_enabled (const snd_seq_client_info_t *info)
 Get the UMP groupless message handling status.
 
int snd_seq_client_info_get_ump_conversion (const snd_seq_client_info_t *info)
 Get the automatic conversion mode for UMP.
 
void snd_seq_client_info_set_client (snd_seq_client_info_t *info, int client)
 Set the client id of a client_info container.
 
void snd_seq_client_info_set_name (snd_seq_client_info_t *info, const char *name)
 Set the name of a client_info container.
 
void snd_seq_client_info_set_broadcast_filter (snd_seq_client_info_t *info, int val)
 Set the broadcast filter usage of a client_info container.
 
void snd_seq_client_info_set_midi_version (snd_seq_client_info_t *info, int midi_version)
 Set the MIDI protocol version of a client_info container.
 
void snd_seq_client_info_set_ump_group_enabled (snd_seq_client_info_t *info, int group, int enable)
 Set the UMP group filter status.
 
void snd_seq_client_info_set_ump_groupless_enabled (snd_seq_client_info_t *info, int enable)
 Enable/disable the UMP groupless message handling.
 
void snd_seq_client_info_set_ump_conversion (snd_seq_client_info_t *info, int enable)
 Set the automatic conversion mode for UMP.
 
void snd_seq_client_info_set_error_bounce (snd_seq_client_info_t *info, int val)
 Set the error-bounce usage of a client_info container.
 
void snd_seq_client_info_set_event_filter (snd_seq_client_info_t *info, unsigned char *filter)
 (DEPRECATED) Set the event filter bitmap of a client_info container
 
int snd_seq_get_any_client_info (snd_seq_t *seq, int client, snd_seq_client_info_t *info)
 obtain the information of the given client
 
int snd_seq_get_client_info (snd_seq_t *seq, snd_seq_client_info_t *info)
 obtain the current client information
 
int snd_seq_set_client_info (snd_seq_t *seq, snd_seq_client_info_t *info)
 set the current client information
 
int snd_seq_query_next_client (snd_seq_t *seq, snd_seq_client_info_t *info)
 query the next client
 
int snd_seq_get_ump_endpoint_info (snd_seq_t *seq, int client, void *info)
 Get UMP Endpoint information.
 
int snd_seq_get_ump_block_info (snd_seq_t *seq, int client, int blk, void *info)
 Get UMP Block information.
 
int snd_seq_set_ump_endpoint_info (snd_seq_t *seq, const void *info)
 Set UMP Endpoint information to the current client.
 
int snd_seq_set_ump_block_info (snd_seq_t *seq, int blk, const void *info)
 Set UMP Block information to the current client.
 
size_t snd_seq_port_info_sizeof ()
 get size of #snd_seq_port_info_t
 
int snd_seq_port_info_malloc (snd_seq_port_info_t **ptr)
 allocate an empty #snd_seq_port_info_t using standard malloc
 
void snd_seq_port_info_free (snd_seq_port_info_t *obj)
 frees a previously allocated #snd_seq_port_info_t
 
void snd_seq_port_info_copy (snd_seq_port_info_t *dst, const snd_seq_port_info_t *src)
 copy one #snd_seq_port_info_t to another
 
int snd_seq_port_info_get_client (const snd_seq_port_info_t *info)
 Get client id of a port_info container.
 
int snd_seq_port_info_get_port (const snd_seq_port_info_t *info)
 Get port id of a port_info container.
 
const snd_seq_addr_t * snd_seq_port_info_get_addr (const snd_seq_port_info_t *info)
 Get client/port address of a port_info container.
 
const char * snd_seq_port_info_get_name (const snd_seq_port_info_t *info)
 Get the name of a port_info container.
 
unsigned int snd_seq_port_info_get_capability (const snd_seq_port_info_t *info)
 Get the capability bits of a port_info container.
 
unsigned int snd_seq_port_info_get_type (const snd_seq_port_info_t *info)
 Get the type bits of a port_info container.
 
int snd_seq_port_info_get_read_use (const snd_seq_port_info_t *info)
 Get the number of read subscriptions of a port_info container.
 
int snd_seq_port_info_get_write_use (const snd_seq_port_info_t *info)
 Get the number of write subscriptions of a port_info container.
 
int snd_seq_port_info_get_midi_channels (const snd_seq_port_info_t *info)
 Get the midi channels of a port_info container.
 
int snd_seq_port_info_get_midi_voices (const snd_seq_port_info_t *info)
 Get the midi voices of a port_info container.
 
int snd_seq_port_info_get_synth_voices (const snd_seq_port_info_t *info)
 Get the synth voices of a port_info container.
 
int snd_seq_port_info_get_port_specified (const snd_seq_port_info_t *info)
 Get the port-specified mode of a port_info container.
 
int snd_seq_port_info_get_timestamping (const snd_seq_port_info_t *info)
 Get the time-stamping mode of the given port in a port_info container.
 
int snd_seq_port_info_get_timestamp_real (const snd_seq_port_info_t *info)
 Get whether the time-stamping of the given port is real-time mode.
 
int snd_seq_port_info_get_timestamp_queue (const snd_seq_port_info_t *info)
 Get the queue id to update timestamps.
 
int snd_seq_port_info_get_direction (const snd_seq_port_info_t *info)
 Get the direction of the port.
 
int snd_seq_port_info_get_ump_group (const snd_seq_port_info_t *info)
 Get the UMP Group assigned to the port.
 
int snd_seq_port_info_get_ump_is_midi1 (const snd_seq_port_info_t *info)
 Get the status of the optional MIDI 1.0 port in MIDI 2.0 UMP Endpoint.
 
void snd_seq_port_info_set_client (snd_seq_port_info_t *info, int client)
 Set the client id of a port_info container.
 
void snd_seq_port_info_set_port (snd_seq_port_info_t *info, int port)
 Set the port id of a port_info container.
 
void snd_seq_port_info_set_addr (snd_seq_port_info_t *info, const snd_seq_addr_t *addr)
 Set the client/port address of a port_info container.
 
void snd_seq_port_info_set_name (snd_seq_port_info_t *info, const char *name)
 Set the name of a port_info container.
 
void snd_seq_port_info_set_capability (snd_seq_port_info_t *info, unsigned int capability)
 set the capability bits of a port_info container
 
void snd_seq_port_info_set_type (snd_seq_port_info_t *info, unsigned int type)
 Get the type bits of a port_info container.
 
void snd_seq_port_info_set_midi_channels (snd_seq_port_info_t *info, int channels)
 set the midi channels of a port_info container
 
void snd_seq_port_info_set_midi_voices (snd_seq_port_info_t *info, int voices)
 set the midi voices of a port_info container
 
void snd_seq_port_info_set_synth_voices (snd_seq_port_info_t *info, int voices)
 set the synth voices of a port_info container
 
void snd_seq_port_info_set_port_specified (snd_seq_port_info_t *info, int val)
 Set the port-specified mode of a port_info container.
 
void snd_seq_port_info_set_timestamping (snd_seq_port_info_t *info, int enable)
 Set the time-stamping mode of the given port.
 
void snd_seq_port_info_set_timestamp_real (snd_seq_port_info_t *info, int enable)
 Set whether the timestime is updated in the real-time mode.
 
void snd_seq_port_info_set_timestamp_queue (snd_seq_port_info_t *info, int queue)
 Set the queue id for timestamping.
 
void snd_seq_port_info_set_direction (snd_seq_port_info_t *info, int direction)
 Set the direction of the port.
 
void snd_seq_port_info_set_ump_group (snd_seq_port_info_t *info, int ump_group)
 Set the UMP Group assigned to the port.
 
void snd_seq_port_info_set_ump_is_midi1 (snd_seq_port_info_t *info, int is_midi1)
 Set the optional MIDI 1.0 port in MIDI 2.0 UMP Endpoint.
 
int snd_seq_create_port (snd_seq_t *seq, snd_seq_port_info_t *port)
 create a sequencer port on the current client
 
int snd_seq_delete_port (snd_seq_t *seq, int port)
 delete a sequencer port on the current client
 
int snd_seq_get_any_port_info (snd_seq_t *seq, int client, int port, snd_seq_port_info_t *info)
 obtain the information of a port on an arbitrary client
 
int snd_seq_get_port_info (snd_seq_t *seq, int port, snd_seq_port_info_t *info)
 obtain the information of a port on the current client
 
int snd_seq_set_port_info (snd_seq_t *seq, int port, snd_seq_port_info_t *info)
 set the information of a port on the current client
 
int snd_seq_query_next_port (snd_seq_t *seq, snd_seq_port_info_t *info)
 query the next matching port
 
size_t snd_seq_port_subscribe_sizeof ()
 get size of #snd_seq_port_subscribe_t
 
int snd_seq_port_subscribe_malloc (snd_seq_port_subscribe_t **ptr)
 allocate an empty #snd_seq_port_subscribe_t using standard malloc
 
void snd_seq_port_subscribe_free (snd_seq_port_subscribe_t *obj)
 frees a previously allocated #snd_seq_port_subscribe_t
 
void snd_seq_port_subscribe_copy (snd_seq_port_subscribe_t *dst, const snd_seq_port_subscribe_t *src)
 copy one #snd_seq_port_subscribe_t to another
 
const snd_seq_addr_t * snd_seq_port_subscribe_get_sender (const snd_seq_port_subscribe_t *info)
 Get sender address of a port_subscribe container.
 
const snd_seq_addr_t * snd_seq_port_subscribe_get_dest (const snd_seq_port_subscribe_t *info)
 Get destination address of a port_subscribe container.
 
int snd_seq_port_subscribe_get_queue (const snd_seq_port_subscribe_t *info)
 Get the queue id of a port_subscribe container.
 
int snd_seq_port_subscribe_get_exclusive (const snd_seq_port_subscribe_t *info)
 Get the exclusive mode of a port_subscribe container.
 
int snd_seq_port_subscribe_get_time_update (const snd_seq_port_subscribe_t *info)
 Get the time-update mode of a port_subscribe container.
 
int snd_seq_port_subscribe_get_time_real (const snd_seq_port_subscribe_t *info)
 Get the real-time update mode of a port_subscribe container.
 
void snd_seq_port_subscribe_set_sender (snd_seq_port_subscribe_t *info, const snd_seq_addr_t *addr)
 Set sender address of a port_subscribe container.
 
void snd_seq_port_subscribe_set_dest (snd_seq_port_subscribe_t *info, const snd_seq_addr_t *addr)
 Set destination address of a port_subscribe container.
 
void snd_seq_port_subscribe_set_queue (snd_seq_port_subscribe_t *info, int q)
 Set the queue id of a port_subscribe container.
 
void snd_seq_port_subscribe_set_exclusive (snd_seq_port_subscribe_t *info, int val)
 Set the exclusive mode of a port_subscribe container.
 
void snd_seq_port_subscribe_set_time_update (snd_seq_port_subscribe_t *info, int val)
 Set the time-update mode of a port_subscribe container.
 
void snd_seq_port_subscribe_set_time_real (snd_seq_port_subscribe_t *info, int val)
 Set the real-time mode of a port_subscribe container.
 
int snd_seq_get_port_subscription (snd_seq_t *seq, snd_seq_port_subscribe_t *sub)
 obtain subscription information
 
int snd_seq_subscribe_port (snd_seq_t *seq, snd_seq_port_subscribe_t *sub)
 subscribe a port connection
 
int snd_seq_unsubscribe_port (snd_seq_t *seq, snd_seq_port_subscribe_t *sub)
 unsubscribe a connection between ports
 
size_t snd_seq_query_subscribe_sizeof ()
 get size of #snd_seq_query_subscribe_t
 
int snd_seq_query_subscribe_malloc (snd_seq_query_subscribe_t **ptr)
 allocate an empty #snd_seq_query_subscribe_t using standard malloc
 
void snd_seq_query_subscribe_free (snd_seq_query_subscribe_t *obj)
 frees a previously allocated #snd_seq_query_subscribe_t
 
void snd_seq_query_subscribe_copy (snd_seq_query_subscribe_t *dst, const snd_seq_query_subscribe_t *src)
 copy one #snd_seq_query_subscribe_t to another
 
int snd_seq_query_subscribe_get_client (const snd_seq_query_subscribe_t *info)
 Get the client id of a query_subscribe container.
 
int snd_seq_query_subscribe_get_port (const snd_seq_query_subscribe_t *info)
 Get the port id of a query_subscribe container.
 
const snd_seq_addr_t * snd_seq_query_subscribe_get_root (const snd_seq_query_subscribe_t *info)
 Get the client/port address of a query_subscribe container.
 
snd_seq_query_subs_type_t snd_seq_query_subscribe_get_type (const snd_seq_query_subscribe_t *info)
 Get the query type of a query_subscribe container.
 
int snd_seq_query_subscribe_get_index (const snd_seq_query_subscribe_t *info)
 Get the index of subscriber of a query_subscribe container.
 
int snd_seq_query_subscribe_get_num_subs (const snd_seq_query_subscribe_t *info)
 Get the number of subscriptions of a query_subscribe container.
 
const snd_seq_addr_t * snd_seq_query_subscribe_get_addr (const snd_seq_query_subscribe_t *info)
 Get the address of subscriber of a query_subscribe container.
 
int snd_seq_query_subscribe_get_queue (const snd_seq_query_subscribe_t *info)
 Get the queue id of subscriber of a query_subscribe container.
 
int snd_seq_query_subscribe_get_exclusive (const snd_seq_query_subscribe_t *info)
 Get the exclusive mode of a query_subscribe container.
 
int snd_seq_query_subscribe_get_time_update (const snd_seq_query_subscribe_t *info)
 Get the time-update mode of a query_subscribe container.
 
int snd_seq_query_subscribe_get_time_real (const snd_seq_query_subscribe_t *info)
 Get the real-time update mode of a query_subscribe container.
 
void snd_seq_query_subscribe_set_client (snd_seq_query_subscribe_t *info, int client)
 Set the client id of a query_subscribe container.
 
void snd_seq_query_subscribe_set_port (snd_seq_query_subscribe_t *info, int port)
 Set the port id of a query_subscribe container.
 
void snd_seq_query_subscribe_set_root (snd_seq_query_subscribe_t *info, const snd_seq_addr_t *addr)
 Set the client/port address of a query_subscribe container.
 
void snd_seq_query_subscribe_set_type (snd_seq_query_subscribe_t *info, snd_seq_query_subs_type_t type)
 Set the query type of a query_subscribe container.
 
void snd_seq_query_subscribe_set_index (snd_seq_query_subscribe_t *info, int index)
 Set the subscriber's index to be queried.
 
int snd_seq_query_port_subscribers (snd_seq_t *seq, snd_seq_query_subscribe_t *subs)
 query port subscriber list
 
size_t snd_seq_queue_info_sizeof ()
 get size of #snd_seq_queue_info_t
 
int snd_seq_queue_info_malloc (snd_seq_queue_info_t **ptr)
 allocate an empty #snd_seq_queue_info_t using standard malloc
 
void snd_seq_queue_info_free (snd_seq_queue_info_t *obj)
 frees a previously allocated #snd_seq_queue_info_t
 
void snd_seq_queue_info_copy (snd_seq_queue_info_t *dst, const snd_seq_queue_info_t *src)
 copy one #snd_seq_queue_info_t to another
 
int snd_seq_queue_info_get_queue (const snd_seq_queue_info_t *info)
 Get the queue id of a queue_info container.
 
const char * snd_seq_queue_info_get_name (const snd_seq_queue_info_t *info)
 Get the name of a queue_info container.
 
int snd_seq_queue_info_get_owner (const snd_seq_queue_info_t *info)
 Get the owner client id of a queue_info container.
 
int snd_seq_queue_info_get_locked (const snd_seq_queue_info_t *info)
 Get the lock status of a queue_info container.
 
unsigned int snd_seq_queue_info_get_flags (const snd_seq_queue_info_t *info)
 Get the conditional bit flags of a queue_info container.
 
void snd_seq_queue_info_set_name (snd_seq_queue_info_t *info, const char *name)
 Set the name of a queue_info container.
 
void snd_seq_queue_info_set_owner (snd_seq_queue_info_t *info, int owner)
 Set the owner client id of a queue_info container.
 
void snd_seq_queue_info_set_locked (snd_seq_queue_info_t *info, int locked)
 Set the lock status of a queue_info container.
 
void snd_seq_queue_info_set_flags (snd_seq_queue_info_t *info, unsigned int flags)
 Set the conditional bit flags of a queue_info container.
 
int snd_seq_create_queue (snd_seq_t *seq, snd_seq_queue_info_t *info)
 create a queue
 
int snd_seq_alloc_named_queue (snd_seq_t *seq, const char *name)
 allocate a queue with the specified name
 
int snd_seq_alloc_queue (snd_seq_t *seq)
 allocate a queue
 
int snd_seq_free_queue (snd_seq_t *seq, int q)
 delete the specified queue
 
int snd_seq_get_queue_info (snd_seq_t *seq, int q, snd_seq_queue_info_t *info)
 obtain queue attributes
 
int snd_seq_set_queue_info (snd_seq_t *seq, int q, snd_seq_queue_info_t *info)
 change the queue attributes
 
int snd_seq_query_named_queue (snd_seq_t *seq, const char *name)
 query the matching queue with the specified name
 
int snd_seq_get_queue_usage (snd_seq_t *seq, int q)
 Get the queue usage flag to the client.
 
int snd_seq_set_queue_usage (snd_seq_t *seq, int q, int used)
 Set the queue usage flag to the client.
 
size_t snd_seq_queue_status_sizeof ()
 get size of #snd_seq_queue_status_t
 
int snd_seq_queue_status_malloc (snd_seq_queue_status_t **ptr)
 allocate an empty #snd_seq_queue_status_t using standard malloc
 
void snd_seq_queue_status_free (snd_seq_queue_status_t *obj)
 frees a previously allocated #snd_seq_queue_status_t
 
void snd_seq_queue_status_copy (snd_seq_queue_status_t *dst, const snd_seq_queue_status_t *src)
 copy one #snd_seq_queue_status_t to another
 
int snd_seq_queue_status_get_queue (const snd_seq_queue_status_t *info)
 Get the queue id of a queue_status container.
 
int snd_seq_queue_status_get_events (const snd_seq_queue_status_t *info)
 Get the number of events of a queue_status container.
 
snd_seq_tick_time_t snd_seq_queue_status_get_tick_time (const snd_seq_queue_status_t *info)
 Get the tick time of a queue_status container.
 
const snd_seq_real_time_t * snd_seq_queue_status_get_real_time (const snd_seq_queue_status_t *info)
 Get the real time of a queue_status container.
 
unsigned int snd_seq_queue_status_get_status (const snd_seq_queue_status_t *info)
 Get the running status bits of a queue_status container.
 
int snd_seq_get_queue_status (snd_seq_t *seq, int q, snd_seq_queue_status_t *status)
 obtain the running state of the queue
 
size_t snd_seq_queue_tempo_sizeof ()
 get size of #snd_seq_queue_tempo_t
 
int snd_seq_queue_tempo_malloc (snd_seq_queue_tempo_t **ptr)
 allocate an empty #snd_seq_queue_tempo_t using standard malloc
 
void snd_seq_queue_tempo_free (snd_seq_queue_tempo_t *obj)
 frees a previously allocated #snd_seq_queue_tempo_t
 
void snd_seq_queue_tempo_copy (snd_seq_queue_tempo_t *dst, const snd_seq_queue_tempo_t *src)
 copy one #snd_seq_queue_tempo_t to another
 
int snd_seq_queue_tempo_get_queue (const snd_seq_queue_tempo_t *info)
 Get the queue id of a queue_status container.
 
unsigned int snd_seq_queue_tempo_get_tempo (const snd_seq_queue_tempo_t *info)
 Get the tempo of a queue_status container.
 
int snd_seq_queue_tempo_get_ppq (const snd_seq_queue_tempo_t *info)
 Get the ppq of a queue_status container.
 
unsigned int snd_seq_queue_tempo_get_skew (const snd_seq_queue_tempo_t *info)
 Get the timer skew value of a queue_status container.
 
unsigned int snd_seq_queue_tempo_get_skew_base (const snd_seq_queue_tempo_t *info)
 Get the timer skew base value of a queue_status container.
 
unsigned int snd_seq_queue_tempo_get_tempo_base (const snd_seq_queue_tempo_t *info)
 Get the tempo base of a queue_status container.
 
void snd_seq_queue_tempo_set_tempo (snd_seq_queue_tempo_t *info, unsigned int tempo)
 Set the tempo of a queue_status container.
 
void snd_seq_queue_tempo_set_ppq (snd_seq_queue_tempo_t *info, int ppq)
 Set the ppq of a queue_status container.
 
void snd_seq_queue_tempo_set_skew (snd_seq_queue_tempo_t *info, unsigned int skew)
 Set the timer skew value of a queue_status container.
 
void snd_seq_queue_tempo_set_skew_base (snd_seq_queue_tempo_t *info, unsigned int base)
 Set the timer skew base value of a queue_status container.
 
void snd_seq_queue_tempo_set_tempo_base (snd_seq_queue_tempo_t *info, unsigned int tempo_base)
 Set the tempo base of a queue_status container.
 
int snd_seq_get_queue_tempo (snd_seq_t *seq, int q, snd_seq_queue_tempo_t *tempo)
 obtain the current tempo of the queue
 
int snd_seq_set_queue_tempo (snd_seq_t *seq, int q, snd_seq_queue_tempo_t *tempo)
 set the tempo of the queue
 
int snd_seq_has_queue_tempo_base (snd_seq_t *seq)
 inquiry the support of tempo base change
 
size_t snd_seq_queue_timer_sizeof ()
 get size of #snd_seq_queue_timer_t
 
int snd_seq_queue_timer_malloc (snd_seq_queue_timer_t **ptr)
 allocate an empty #snd_seq_queue_timer_t using standard malloc
 
void snd_seq_queue_timer_free (snd_seq_queue_timer_t *obj)
 frees a previously allocated #snd_seq_queue_timer_t
 
void snd_seq_queue_timer_copy (snd_seq_queue_timer_t *dst, const snd_seq_queue_timer_t *src)
 copy one #snd_seq_queue_timer_t to another
 
int snd_seq_queue_timer_get_queue (const snd_seq_queue_timer_t *info)
 Get the queue id of a queue_timer container.
 
snd_seq_queue_timer_type_t snd_seq_queue_timer_get_type (const snd_seq_queue_timer_t *info)
 Get the timer type of a queue_timer container.
 
const snd_timer_id_t * snd_seq_queue_timer_get_id (const snd_seq_queue_timer_t *info)
 Get the timer id of a queue_timer container.
 
unsigned int snd_seq_queue_timer_get_resolution (const snd_seq_queue_timer_t *info)
 Get the timer resolution of a queue_timer container.
 
void snd_seq_queue_timer_set_type (snd_seq_queue_timer_t *info, snd_seq_queue_timer_type_t type)
 Set the timer type of a queue_timer container.
 
void snd_seq_queue_timer_set_id (snd_seq_queue_timer_t *info, const snd_timer_id_t *id)
 Set the timer id of a queue_timer container.
 
void snd_seq_queue_timer_set_resolution (snd_seq_queue_timer_t *info, unsigned int resolution)
 Set the timer resolution of a queue_timer container.
 
int snd_seq_get_queue_timer (snd_seq_t *seq, int q, snd_seq_queue_timer_t *timer)
 obtain the queue timer information
 
int snd_seq_set_queue_timer (snd_seq_t *seq, int q, snd_seq_queue_timer_t *timer)
 set the queue timer information
 
int snd_seq_free_event (snd_seq_event_t *ev)
 (DEPRECATED) free an event
 
ssize_t snd_seq_event_length (snd_seq_event_t *ev)
 calculates the (encoded) byte-stream size of the event
 
int snd_seq_event_output (snd_seq_t *seq, snd_seq_event_t *ev)
 output an event
 
int snd_seq_event_output_buffer (snd_seq_t *seq, snd_seq_event_t *ev)
 output an event onto the lib buffer without draining buffer
 
int snd_seq_event_output_direct (snd_seq_t *seq, snd_seq_event_t *ev)
 output an event directly to the sequencer NOT through output buffer
 
int snd_seq_event_output_pending (snd_seq_t *seq)
 return the size of pending events on output buffer
 
int snd_seq_drain_output (snd_seq_t *seq)
 drain output buffer to sequencer
 
int snd_seq_extract_output (snd_seq_t *seq, snd_seq_event_t **ev_res)
 extract the first event in output buffer
 
int snd_seq_event_input (snd_seq_t *seq, snd_seq_event_t **ev)
 retrieve an event from sequencer
 
int snd_seq_event_input_pending (snd_seq_t *seq, int fetch_sequencer)
 check events in input buffer
 
int snd_seq_ump_event_output (snd_seq_t *seq, snd_seq_ump_event_t *ev)
 output a UMP event
 
int snd_seq_ump_event_output_buffer (snd_seq_t *seq, snd_seq_ump_event_t *ev)
 output an event onto the lib buffer without draining buffer
 
int snd_seq_ump_extract_output (snd_seq_t *seq, snd_seq_ump_event_t **ev_res)
 extract the first UMP event in output buffer
 
int snd_seq_ump_event_output_direct (snd_seq_t *seq, snd_seq_ump_event_t *ev)
 output a UMP event directly to the sequencer NOT through output buffer
 
int snd_seq_ump_event_input (snd_seq_t *seq, snd_seq_ump_event_t **ev)
 retrieve a UMP event from sequencer
 
int snd_seq_drop_output_buffer (snd_seq_t *seq)
 remove all events on user-space output buffer
 
int snd_seq_drop_input_buffer (snd_seq_t *seq)
 remove all events on user-space input FIFO
 
int snd_seq_drop_output (snd_seq_t *seq)
 remove all events on output buffer
 
int snd_seq_drop_input (snd_seq_t *seq)
 clear input buffer and and remove events in sequencer queue
 
size_t snd_seq_remove_events_sizeof ()
 get size of #snd_seq_remove_events_t
 
int snd_seq_remove_events_malloc (snd_seq_remove_events_t **ptr)
 allocate an empty #snd_seq_remove_events_t using standard malloc
 
void snd_seq_remove_events_free (snd_seq_remove_events_t *obj)
 frees a previously allocated #snd_seq_remove_events_t
 
void snd_seq_remove_events_copy (snd_seq_remove_events_t *dst, const snd_seq_remove_events_t *src)
 copy one #snd_seq_remove_events_t to another
 
unsigned int snd_seq_remove_events_get_condition (const snd_seq_remove_events_t *info)
 Get the removal condition bits.
 
int snd_seq_remove_events_get_queue (const snd_seq_remove_events_t *info)
 Get the queue as removal condition.
 
const snd_seq_timestamp_t * snd_seq_remove_events_get_time (const snd_seq_remove_events_t *info)
 Get the event timestamp as removal condition.
 
const snd_seq_addr_t * snd_seq_remove_events_get_dest (const snd_seq_remove_events_t *info)
 Get the event destination address as removal condition.
 
int snd_seq_remove_events_get_channel (const snd_seq_remove_events_t *info)
 Get the event channel as removal condition.
 
int snd_seq_remove_events_get_event_type (const snd_seq_remove_events_t *info)
 Get the event type as removal condition.
 
int snd_seq_remove_events_get_tag (const snd_seq_remove_events_t *info)
 Get the event tag id as removal condition.
 
void snd_seq_remove_events_set_condition (snd_seq_remove_events_t *info, unsigned int flags)
 Set the removal condition bits.
 
void snd_seq_remove_events_set_queue (snd_seq_remove_events_t *info, int queue)
 Set the queue as removal condition.
 
void snd_seq_remove_events_set_time (snd_seq_remove_events_t *info, const snd_seq_timestamp_t *time)
 Set the timestamp as removal condition.
 
void snd_seq_remove_events_set_dest (snd_seq_remove_events_t *info, const snd_seq_addr_t *addr)
 Set the destination address as removal condition.
 
void snd_seq_remove_events_set_channel (snd_seq_remove_events_t *info, int channel)
 Set the channel as removal condition.
 
void snd_seq_remove_events_set_event_type (snd_seq_remove_events_t *info, int type)
 Set the event type as removal condition.
 
void snd_seq_remove_events_set_tag (snd_seq_remove_events_t *info, int tag)
 Set the event tag as removal condition.
 
int snd_seq_remove_events (snd_seq_t *seq, snd_seq_remove_events_t *rmp)
 remove events on input/output buffers and pools
 
size_t snd_seq_client_pool_sizeof ()
 get size of #snd_seq_client_pool_t
 
int snd_seq_client_pool_malloc (snd_seq_client_pool_t **ptr)
 allocate an empty #snd_seq_client_pool_t using standard malloc
 
void snd_seq_client_pool_free (snd_seq_client_pool_t *obj)
 frees a previously allocated #snd_seq_client_pool_t
 
void snd_seq_client_pool_copy (snd_seq_client_pool_t *dst, const snd_seq_client_pool_t *src)
 copy one #snd_seq_client_pool_t to another
 
int snd_seq_client_pool_get_client (const snd_seq_client_pool_t *info)
 Get the client id of a queue_info container.
 
size_t snd_seq_client_pool_get_output_pool (const snd_seq_client_pool_t *info)
 Get the output pool size of a queue_info container.
 
size_t snd_seq_client_pool_get_input_pool (const snd_seq_client_pool_t *info)
 Get the input pool size of a queue_info container.
 
size_t snd_seq_client_pool_get_output_room (const snd_seq_client_pool_t *info)
 Get the output room size of a queue_info container.
 
size_t snd_seq_client_pool_get_output_free (const snd_seq_client_pool_t *info)
 Get the available size on output pool of a queue_info container.
 
size_t snd_seq_client_pool_get_input_free (const snd_seq_client_pool_t *info)
 Get the available size on input pool of a queue_info container.
 
void snd_seq_client_pool_set_output_pool (snd_seq_client_pool_t *info, size_t size)
 Set the output pool size of a queue_info container.
 
void snd_seq_client_pool_set_input_pool (snd_seq_client_pool_t *info, size_t size)
 Set the input pool size of a queue_info container.
 
void snd_seq_client_pool_set_output_room (snd_seq_client_pool_t *info, size_t size)
 Set the output room size of a queue_info container.
 
int snd_seq_get_client_pool (snd_seq_t *seq, snd_seq_client_pool_t *info)
 obtain the pool information of the current client
 
int snd_seq_set_client_pool (snd_seq_t *seq, snd_seq_client_pool_t *info)
 set the pool information
 
void snd_seq_set_bit (int nr, void *array)
 set a bit flag
 
void snd_seq_unset_bit (int nr, void *array)
 unset a bit flag
 
int snd_seq_change_bit (int nr, void *array)
 change a bit flag
 
int snd_seq_get_bit (int nr, void *array)
 get a bit flag state
 

Detailed Description

Sequencer Interface.

Author
Jaroslav Kysela perex.nosp@m.@per.nosp@m.ex.cz
Abramo Bagnara abram.nosp@m.o@al.nosp@m.sa-pr.nosp@m.ojec.nosp@m.t.org
Takashi Iwai tiwai.nosp@m.@sus.nosp@m.e.de
Date
2000-2001

See Sequencer interface page for more details.

Function Documentation

◆ snd_seq_alloc_named_queue()

int snd_seq_alloc_named_queue ( snd_seq_t * seq,
const char * name )

allocate a queue with the specified name

Parameters
seqsequencer handle
namethe name of the new queue
Returns
the queue id (zero or positive) on success otherwise a negative error code
See also
snd_seq_alloc_queue()

◆ snd_seq_alloc_queue()

int snd_seq_alloc_queue ( snd_seq_t * seq)

allocate a queue

Parameters
seqsequencer handle
Returns
the queue id (zero or positive) on success otherwise a negative error code
See also
snd_seq_alloc_named_queue(), snd_seq_create_queue(), snd_seq_free_queue(), snd_seq_get_queue_info()

◆ snd_seq_client_id()

int snd_seq_client_id ( snd_seq_t * seq)

Get the client id.

Parameters
seqsequencer handle
Returns
the client id

Returns the id of the specified client. If an error occurs, function returns the negative error code. A client id is necessary to inquiry or to set the client information. A user client is assigned from 128 to 191.

See also
snd_seq_open()

◆ snd_seq_client_info_copy()

void snd_seq_client_info_copy ( snd_seq_client_info_t * dst,
const snd_seq_client_info_t * src )

copy one #snd_seq_client_info_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_client_info_event_filter_add()

void snd_seq_client_info_event_filter_add ( snd_seq_client_info_t * info,
int event_type )

Add an event type to the event filtering of a client_info container.

Parameters
infoclient_info container
event_typeevent type to be added

Set the event filtering flag of this client_info and add the specified event type to the filter bitmap of this client_info container.

See also
snd_seq_get_client_info(), snd_seq_set_client_info(), snd_seq_client_info_event_filter_del(), snd_seq_client_info_event_filter_check(), snd_seq_client_info_event_filter_clear()

◆ snd_seq_client_info_event_filter_check()

int snd_seq_client_info_event_filter_check ( snd_seq_client_info_t * info,
int event_type )

Check if an event type is present in the event filtering of a client_info container.

Parameters
infoclient_info container
event_typeevent type to be checked
Returns
1 if the event type is present, 0 otherwise

Test if the event type is in the filter bitmap of this client_info container.

See also
snd_seq_get_client_info(), snd_seq_set_client_info(), snd_seq_client_info_event_filter_add(), snd_seq_client_info_event_filter_del(), snd_seq_client_info_event_filter_clear()

◆ snd_seq_client_info_event_filter_clear()

void snd_seq_client_info_event_filter_clear ( snd_seq_client_info_t * info)

Disable event filtering of a client_info container.

Parameters
infoclient_info container

Remove all event types added with snd_seq_client_info_event_filter_add and clear the event filtering flag of this client_info container.

See also
snd_seq_client_info_event_filter_add(), snd_seq_client_info_event_filter_del(), snd_seq_client_info_event_filter_check(), snd_seq_get_client_info(), snd_seq_set_client_info()

◆ snd_seq_client_info_event_filter_del()

void snd_seq_client_info_event_filter_del ( snd_seq_client_info_t * info,
int event_type )

Remove an event type from the event filtering of a client_info container.

Parameters
infoclient_info container
event_typeevent type to be removed

Removes the specified event from the filter bitmap of this client_info container. It will not clear the event filtering flag, use snd_seq_client_info_event_filter_clear instead.

See also
snd_seq_get_client_info(), snd_seq_set_client_info(), snd_seq_client_info_event_filter_add(), snd_seq_client_info_event_filter_check(), snd_seq_client_info_event_filter_clear()

◆ snd_seq_client_info_free()

void snd_seq_client_info_free ( snd_seq_client_info_t * obj)

frees a previously allocated #snd_seq_client_info_t

Parameters
objpointer to object to free

◆ snd_seq_client_info_get_broadcast_filter()

int snd_seq_client_info_get_broadcast_filter ( const snd_seq_client_info_t * info)

Get the broadcast filter usage of a client_info container.

Parameters
infoclient_info container
Returns
1 if broadcast is accepted
See also
snd_seq_get_client_info(), snd_seq_client_info_set_broadcast_filter()

◆ snd_seq_client_info_get_card()

int snd_seq_client_info_get_card ( const snd_seq_client_info_t * info)

Get the sound card number.

Parameters
infoclient_info container
Returns
card number or -1 if value is not available.

Only available for #SND_SEQ_KERNEL_CLIENT clients.

The card number can be used to query state about the hardware device providing this client, by concatenating "hw:CARD=" with the card number and using it as the name parameter to snd_ctl_open().

Note
The return value of -1 is returned for two different conditions: when the running kernel does not support this operation, and when the client does not have a hardware card attached. See snd_seq_client_info_get_pid() for a way to determine if the currently running kernel has support for this operation.
See also
snd_seq_client_info_get_pid(), snd_card_get_name(), snd_card_get_longname(), snd_ctl_open(), snd_ctl_card_info()

◆ snd_seq_client_info_get_client()

int snd_seq_client_info_get_client ( const snd_seq_client_info_t * info)

Get client id of a client_info container.

Parameters
infoclient_info container
Returns
client id
See also
snd_seq_get_client_info(), snd_seq_client_info_set_client(), snd_seq_client_id()

◆ snd_seq_client_info_get_error_bounce()

int snd_seq_client_info_get_error_bounce ( const snd_seq_client_info_t * info)

Get the error-bounce usage of a client_info container.

Parameters
infoclient_info container
Returns
1 if error-bounce is enabled
See also
snd_seq_get_client_info(), snd_seq_client_info_set_error_bounce()

◆ snd_seq_client_info_get_event_filter()

const unsigned char * snd_seq_client_info_get_event_filter ( const snd_seq_client_info_t * info)

(DEPRECATED) Get the event filter bitmap of a client_info container

Parameters
infoclient_info container
Returns
NULL if no event filter, or pointer to event filter bitmap

Use snd_seq_client_info_event_filter_check() instead.

See also
snd_seq_client_info_event_filter_add(), snd_seq_client_info_event_filter_del(), snd_seq_client_info_event_filter_check(), snd_seq_client_info_event_filter_clear(), snd_seq_get_client_info()

◆ snd_seq_client_info_get_event_lost()

int snd_seq_client_info_get_event_lost ( const snd_seq_client_info_t * info)

Get the number of lost events of a client_info container.

Parameters
infoclient_info container
Returns
number of lost events
See also
snd_seq_get_client_info()

◆ snd_seq_client_info_get_midi_version()

int snd_seq_client_info_get_midi_version ( const snd_seq_client_info_t * info)

Get the MIDI protocol version number of a client_info container.

Parameters
infoclient_info container
Returns
MIDI protocol version
See also
snd_seq_get_client_info()

◆ snd_seq_client_info_get_name()

const char * snd_seq_client_info_get_name ( snd_seq_client_info_t * info)

Get the name of a client_info container.

Parameters
infoclient_info container
Returns
name string
See also
snd_seq_get_client_info(), snd_seq_client_info_set_name()

◆ snd_seq_client_info_get_num_ports()

int snd_seq_client_info_get_num_ports ( const snd_seq_client_info_t * info)

Get the number of opened ports of a client_info container.

Parameters
infoclient_info container
Returns
number of opened ports
See also
snd_seq_get_client_info()

◆ snd_seq_client_info_get_pid()

int snd_seq_client_info_get_pid ( const snd_seq_client_info_t * info)

Get the owning PID.

Parameters
infoclient_info container
Returns
pid or -1 if value is not available.

Only available for #SND_SEQ_USER_CLIENT clients.

Note
The functionality for getting a client's PID and getting a client's card was added to the kernel at the same time, so you can use this function to determine if the running kernel supports reporting these values. If your own client has a valid PID as reported by this function, then the running kernel supports both snd_seq_client_info_get_card() and snd_seq_client_info_get_pid().
Example code for determining kernel support:
int is_get_card_or_pid_supported(snd_seq_t *seq)
{
snd_seq_client_info_t *my_client_info;
snd_seq_client_info_alloca(&my_client_info);
snd_seq_get_client_info(seq, my_client_info);
return snd_seq_client_info_get_pid(my_client_info) != -1;
}
int snd_seq_client_info_get_pid(const snd_seq_client_info_t *info)
Get the owning PID.
Definition seq.c:1683
int snd_seq_get_client_info(snd_seq_t *seq, snd_seq_client_info_t *info)
obtain the current client information
Definition seq.c:2058
See also
snd_seq_client_info_get_card()

◆ snd_seq_client_info_get_type()

snd_seq_client_type_t snd_seq_client_info_get_type ( const snd_seq_client_info_t * info)

Get client type of a client_info container.

Parameters
infoclient_info container
Returns
client type

The client type is either #SND_SEQ_KERNEL_CLIENT or #SND_SEQ_USER_CLIENT for kernel or user client respectively.

See also
snd_seq_get_client_info()

◆ snd_seq_client_info_get_ump_conversion()

int snd_seq_client_info_get_ump_conversion ( const snd_seq_client_info_t * info)

Get the automatic conversion mode for UMP.

Parameters
infoclient_info container
Returns
1 if the conversion is enabled, 0 if not
See also
snd_seq_get_client_info()

◆ snd_seq_client_info_get_ump_group_enabled()

int snd_seq_client_info_get_ump_group_enabled ( const snd_seq_client_info_t * info,
int group )

Get the UMP group filter status.

Parameters
infoclient_info container
group0-based group index
Returns
0 if the group is filtered / disabled, 1 if it's processed
See also
snd_seq_get_client_info()

◆ snd_seq_client_info_get_ump_groupless_enabled()

int snd_seq_client_info_get_ump_groupless_enabled ( const snd_seq_client_info_t * info)

Get the UMP groupless message handling status.

Parameters
infoclient_info container
Returns
1 if UMP groupless messages is processed, 0 if filtered/disabled
See also
snd_seq_get_client_info()

◆ snd_seq_client_info_malloc()

int snd_seq_client_info_malloc ( snd_seq_client_info_t ** ptr)

allocate an empty #snd_seq_client_info_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_client_info_set_broadcast_filter()

void snd_seq_client_info_set_broadcast_filter ( snd_seq_client_info_t * info,
int val )

Set the broadcast filter usage of a client_info container.

Parameters
infoclient_info container
valnon-zero if broadcast is accepted
See also
snd_seq_get_client_info(), snd_seq_client_info_get_broadcast_filter()

◆ snd_seq_client_info_set_client()

void snd_seq_client_info_set_client ( snd_seq_client_info_t * info,
int client )

Set the client id of a client_info container.

Parameters
infoclient_info container
clientclient id
See also
snd_seq_get_client_info(), snd_seq_client_info_get_client()

◆ snd_seq_client_info_set_error_bounce()

void snd_seq_client_info_set_error_bounce ( snd_seq_client_info_t * info,
int val )

Set the error-bounce usage of a client_info container.

Parameters
infoclient_info container
valnon-zero if error is bounced
See also
snd_seq_get_client_info(), snd_seq_client_info_get_error_bounce()

◆ snd_seq_client_info_set_event_filter()

void snd_seq_client_info_set_event_filter ( snd_seq_client_info_t * info,
unsigned char * filter )

(DEPRECATED) Set the event filter bitmap of a client_info container

Parameters
infoclient_info container
filterevent filter bitmap, pass NULL for no event filtering

Use snd_seq_client_info_event_filter_add instead.

See also
snd_seq_client_info_event_filter_add(), snd_seq_client_info_event_filter_del(), snd_seq_client_info_event_filter_check(), snd_seq_client_info_event_filter_clear(), snd_seq_set_client_info()

◆ snd_seq_client_info_set_midi_version()

void snd_seq_client_info_set_midi_version ( snd_seq_client_info_t * info,
int midi_version )

Set the MIDI protocol version of a client_info container.

Parameters
infoclient_info container
midi_versionMIDI protocol version to set
See also
snd_seq_get_client_info(), snd_seq_client_info_get_midi_version()

◆ snd_seq_client_info_set_name()

void snd_seq_client_info_set_name ( snd_seq_client_info_t * info,
const char * name )

Set the name of a client_info container.

Parameters
infoclient_info container
namename string
See also
snd_seq_get_client_info(), snd_seq_client_info_get_name(), snd_seq_set_client_name()

◆ snd_seq_client_info_set_ump_conversion()

void snd_seq_client_info_set_ump_conversion ( snd_seq_client_info_t * info,
int enable )

Set the automatic conversion mode for UMP.

Parameters
infoclient_info container
enable0 or 1 for disabling/enabling the conversion
See also
snd_seq_set_client_info(), snd_seq_client_info_get_ump_conversion()

◆ snd_seq_client_info_set_ump_group_enabled()

void snd_seq_client_info_set_ump_group_enabled ( snd_seq_client_info_t * info,
int group,
int enable )

Set the UMP group filter status.

Parameters
infoclient_info container
group0-based group index
enable0 to filter/disable the group, non-zero to enable
See also
snd_seq_set_client_info(), snd_seq_client_info_get_ump_group_enabled()

◆ snd_seq_client_info_set_ump_groupless_enabled()

void snd_seq_client_info_set_ump_groupless_enabled ( snd_seq_client_info_t * info,
int enable )

Enable/disable the UMP groupless message handling.

Parameters
infoclient_info container
enableenable the UMP groupless messages
See also
snd_seq_set_client_info(), snd_seq_client_info_get_ump_groupless_enabled()

◆ snd_seq_client_info_sizeof()

size_t snd_seq_client_info_sizeof ( )

get size of #snd_seq_client_info_t

Returns
size in bytes

◆ snd_seq_client_pool_copy()

void snd_seq_client_pool_copy ( snd_seq_client_pool_t * dst,
const snd_seq_client_pool_t * src )

copy one #snd_seq_client_pool_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_client_pool_free()

void snd_seq_client_pool_free ( snd_seq_client_pool_t * obj)

frees a previously allocated #snd_seq_client_pool_t

Parameters
objpointer to object to free

◆ snd_seq_client_pool_get_client()

int snd_seq_client_pool_get_client ( const snd_seq_client_pool_t * info)

Get the client id of a queue_info container.

Parameters
infoclient_pool container
Returns
client id

◆ snd_seq_client_pool_get_input_free()

size_t snd_seq_client_pool_get_input_free ( const snd_seq_client_pool_t * info)

Get the available size on input pool of a queue_info container.

Parameters
infoclient_pool container
Returns
available input size

◆ snd_seq_client_pool_get_input_pool()

size_t snd_seq_client_pool_get_input_pool ( const snd_seq_client_pool_t * info)

Get the input pool size of a queue_info container.

Parameters
infoclient_pool container
Returns
input pool size

◆ snd_seq_client_pool_get_output_free()

size_t snd_seq_client_pool_get_output_free ( const snd_seq_client_pool_t * info)

Get the available size on output pool of a queue_info container.

Parameters
infoclient_pool container
Returns
available output size

◆ snd_seq_client_pool_get_output_pool()

size_t snd_seq_client_pool_get_output_pool ( const snd_seq_client_pool_t * info)

Get the output pool size of a queue_info container.

Parameters
infoclient_pool container
Returns
output pool size

◆ snd_seq_client_pool_get_output_room()

size_t snd_seq_client_pool_get_output_room ( const snd_seq_client_pool_t * info)

Get the output room size of a queue_info container.

Parameters
infoclient_pool container
Returns
output room size

◆ snd_seq_client_pool_malloc()

int snd_seq_client_pool_malloc ( snd_seq_client_pool_t ** ptr)

allocate an empty #snd_seq_client_pool_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_client_pool_set_input_pool()

void snd_seq_client_pool_set_input_pool ( snd_seq_client_pool_t * info,
size_t size )

Set the input pool size of a queue_info container.

Parameters
infoclient_pool container
sizeinput pool size

◆ snd_seq_client_pool_set_output_pool()

void snd_seq_client_pool_set_output_pool ( snd_seq_client_pool_t * info,
size_t size )

Set the output pool size of a queue_info container.

Parameters
infoclient_pool container
sizeoutput pool size

◆ snd_seq_client_pool_set_output_room()

void snd_seq_client_pool_set_output_room ( snd_seq_client_pool_t * info,
size_t size )

Set the output room size of a queue_info container.

Parameters
infoclient_pool container
sizeoutput room size

◆ snd_seq_client_pool_sizeof()

size_t snd_seq_client_pool_sizeof ( )

get size of #snd_seq_client_pool_t

Returns
size in bytes

◆ snd_seq_close()

int snd_seq_close ( snd_seq_t * seq)

Close the sequencer.

Parameters
seqHandle returned from snd_seq_open()
Returns
0 on success otherwise a negative error code

Closes the sequencer client and releases its resources. After a client is closed, an event with #SND_SEQ_EVENT_CLIENT_EXIT is broadcast to announce port. The connection between other clients are disconnected. Call this just before exiting your program.

See also
snd_seq_close()

◆ snd_seq_create_port()

int snd_seq_create_port ( snd_seq_t * seq,
snd_seq_port_info_t * port )

create a sequencer port on the current client

Parameters
seqsequencer handle
portport information for the new port
Returns
0 on success otherwise a negative error code

Creates a sequencer port on the current client. The attributes of created port is specified in info argument.

The client field in info argument is overwritten with the current client id. The port id to be created can be specified via snd_seq_port_info_set_port_specified. You can get the created port id by reading the port pointer via snd_seq_port_info_get_port.

Each port has the capability bit-masks to specify the access capability of the port from other clients. The capability bit flags are defined as follows:

  • #SND_SEQ_PORT_CAP_READ Readable from this port
  • #SND_SEQ_PORT_CAP_WRITE Writable to this port.
  • #SND_SEQ_PORT_CAP_SYNC_READ For synchronization (not implemented)
  • #SND_SEQ_PORT_CAP_SYNC_WRITE For synchronization (not implemented)
  • #SND_SEQ_PORT_CAP_DUPLEX Read/write duplex access is supported
  • #SND_SEQ_PORT_CAP_SUBS_READ Read subscription is allowed
  • #SND_SEQ_PORT_CAP_SUBS_WRITE Write subscription is allowed
  • #SND_SEQ_PORT_CAP_NO_EXPORT Subscription management from 3rd client is disallowed

Each port has also the type bitmasks defined as follows:

  • #SND_SEQ_PORT_TYPE_SPECIFIC Hardware specific port
  • #SND_SEQ_PORT_TYPE_MIDI_GENERIC Generic MIDI device
  • #SND_SEQ_PORT_TYPE_MIDI_GM General MIDI compatible device
  • #SND_SEQ_PORT_TYPE_MIDI_GM2 General MIDI 2 compatible device
  • #SND_SEQ_PORT_TYPE_MIDI_GS GS compatible device
  • #SND_SEQ_PORT_TYPE_MIDI_XG XG compatible device
  • #SND_SEQ_PORT_TYPE_MIDI_MT32 MT-32 compatible device
  • #SND_SEQ_PORT_TYPE_HARDWARE Implemented in hardware
  • #SND_SEQ_PORT_TYPE_SOFTWARE Implemented in software
  • #SND_SEQ_PORT_TYPE_SYNTHESIZER Generates sound
  • #SND_SEQ_PORT_TYPE_PORT Connects to other device(s)
  • #SND_SEQ_PORT_TYPE_APPLICATION Application (sequencer/editor)

A port may contain specific midi channels, midi voices and synth voices. These values could be zero as default.

See also
snd_seq_delete_port(), snd_seq_get_port_info(), snd_seq_create_simple_port()

◆ snd_seq_create_queue()

int snd_seq_create_queue ( snd_seq_t * seq,
snd_seq_queue_info_t * info )

create a queue

Parameters
seqsequencer handle
infoqueue information to initialize
Returns
the queue id (zero or positive) on success otherwise a negative error code
See also
snd_seq_alloc_queue()

◆ snd_seq_delete_port()

int snd_seq_delete_port ( snd_seq_t * seq,
int port )

delete a sequencer port on the current client

Parameters
seqsequencer handle
portport to be deleted
Returns
0 on success otherwise a negative error code

Deletes the existing sequencer port on the current client.

See also
snd_seq_create_port(), snd_seq_delete_simple_port()

◆ snd_seq_drain_output()

int snd_seq_drain_output ( snd_seq_t * seq)

drain output buffer to sequencer

Parameters
seqsequencer handle
Returns
0 when all events are drained and sent to sequencer. When events still remain on the buffer, the byte size of remaining events are returned. On error a negative error code is returned.

This function drains all pending events on the output buffer. The function returns immediately after the events are sent to the queues regardless whether the events are processed or not. To get synchronization with the all event processes, use snd_seq_sync_output_queue() after calling this function.

See also
snd_seq_event_output(), snd_seq_sync_output_queue()

◆ snd_seq_drop_input()

int snd_seq_drop_input ( snd_seq_t * seq)

clear input buffer and and remove events in sequencer queue

Parameters
seqsequencer handle
See also
snd_seq_drop_input_buffer(), snd_seq_remove_events()

◆ snd_seq_drop_input_buffer()

int snd_seq_drop_input_buffer ( snd_seq_t * seq)

remove all events on user-space input FIFO

Parameters
seqsequencer handle
See also
snd_seq_drop_input()

◆ snd_seq_drop_output()

int snd_seq_drop_output ( snd_seq_t * seq)

remove all events on output buffer

Parameters
seqsequencer handle

Removes all events on both user-space output buffer and output memory pool on kernel.

See also
snd_seq_drain_output(), snd_seq_drop_output_buffer(), snd_seq_remove_events()

◆ snd_seq_drop_output_buffer()

int snd_seq_drop_output_buffer ( snd_seq_t * seq)

remove all events on user-space output buffer

Parameters
seqsequencer handle

Removes all events on user-space output buffer. Unlike snd_seq_drain_output(), this function doesn't remove events on output memory pool of sequencer.

See also
snd_seq_drop_output()

◆ snd_seq_event_input()

int snd_seq_event_input ( snd_seq_t * seq,
snd_seq_event_t ** ev )

retrieve an event from sequencer

Parameters
seqsequencer handle
evevent pointer to be stored
Returns

Obtains an input event from sequencer. The event is created via snd_seq_create_event(), and its pointer is stored on ev argument.

This function firstly receives the event byte-stream data from sequencer as much as possible at once. Then it retrieves the first event record and store the pointer on ev. By calling this function sequentially, events are extracted from the input buffer.

If there is no input from sequencer, function falls into sleep in blocking mode until an event is received, or returns -EAGAIN error in non-blocking mode. Occasionally, this function may return -ENOSPC error. This means that the input FIFO of sequencer overran, and some events are lost. Once this error is returned, the input FIFO is cleared automatically.

Function returns the byte size of remaining events on the input buffer if an event is successfully received. Application can determine from the returned value whether to call input once more or not.

See also
snd_seq_event_input_pending(), snd_seq_drop_input()

◆ snd_seq_event_input_pending()

int snd_seq_event_input_pending ( snd_seq_t * seq,
int fetch_sequencer )

check events in input buffer

Returns
the byte size of remaining input events on input buffer.

If events remain on the input buffer of user-space, function returns the total byte size of events on it. If fetch_sequencer argument is non-zero, this function checks the presence of events on sequencer FIFO When events exist, they are transferred to the input buffer, and the number of received events are returned. If fetch_sequencer argument is zero and no events remain on the input buffer, function simply returns zero.

See also
snd_seq_event_input()

◆ snd_seq_event_length()

ssize_t snd_seq_event_length ( snd_seq_event_t * ev)

calculates the (encoded) byte-stream size of the event

Parameters
evthe event
Returns
the size of decoded bytes

◆ snd_seq_event_output()

int snd_seq_event_output ( snd_seq_t * seq,
snd_seq_event_t * ev )

output an event

Parameters
seqsequencer handle
evevent to be output
Returns
the number of remaining events or a negative error code

An event is once expanded on the output buffer. The output buffer will be drained automatically if it becomes full.

If events remain unprocessed on output buffer before drained, the size of total byte data on output buffer is returned. If the output buffer is empty, this returns zero.

See also
snd_seq_event_output_direct(), snd_seq_event_output_buffer(), snd_seq_event_output_pending(), snd_seq_drain_output(), snd_seq_drop_output(), snd_seq_extract_output(), snd_seq_remove_events()

◆ snd_seq_event_output_buffer()

int snd_seq_event_output_buffer ( snd_seq_t * seq,
snd_seq_event_t * ev )

output an event onto the lib buffer without draining buffer

Parameters
seqsequencer handle
evevent to be output
Returns
the byte size of remaining events. -EAGAIN if the buffer becomes full.

This function doesn't drain buffer unlike snd_seq_event_output().

Note
For a UMP event, use snd_seq_ump_event_output_buffer() instead.
See also
snd_seq_event_output(), snd_seq_ump_event_output_buffer()

◆ snd_seq_event_output_direct()

int snd_seq_event_output_direct ( snd_seq_t * seq,
snd_seq_event_t * ev )

output an event directly to the sequencer NOT through output buffer

Parameters
seqsequencer handle
evevent to be output
Returns
the byte size sent to sequencer or a negative error code

This function sends an event to the sequencer directly not through the output buffer. When the event is a variable length event, a temporary buffer is allocated inside alsa-lib and the data is copied there before actually sent.

See also
snd_seq_event_output()

◆ snd_seq_event_output_pending()

int snd_seq_event_output_pending ( snd_seq_t * seq)

return the size of pending events on output buffer

Parameters
seqsequencer handle
Returns
the byte size of total of pending events
See also
snd_seq_event_output()

◆ snd_seq_extract_output()

int snd_seq_extract_output ( snd_seq_t * seq,
snd_seq_event_t ** ev_res )

extract the first event in output buffer

Parameters
seqsequencer handle
ev_resevent pointer to be extracted
Returns
0 on success otherwise a negative error code

Extracts the first event in output buffer. If ev_res is NULL, just remove the event.

See also
snd_seq_event_output()

◆ snd_seq_free_event()

int snd_seq_free_event ( snd_seq_event_t * ev)

(DEPRECATED) free an event

In the former version, this function was used to release the event pointer which was allocated by snd_seq_event_input(). In the current version, the event record is not allocated, so you don't have to call this function any more.

◆ snd_seq_free_queue()

int snd_seq_free_queue ( snd_seq_t * seq,
int q )

delete the specified queue

Parameters
seqsequencer handle
qqueue id to delete
Returns
0 on success otherwise a negative error code
See also
snd_seq_alloc_queue()

◆ snd_seq_get_any_client_info()

int snd_seq_get_any_client_info ( snd_seq_t * seq,
int client,
snd_seq_client_info_t * info )

obtain the information of the given client

Parameters
seqsequencer handle
clientclient id
infothe pointer to be stored
Returns
0 on success otherwise a negative error code

Obtains the information of the client with a client id specified by info argument. The obtained information is written on info parameter.

See also
snd_seq_get_client_info()

◆ snd_seq_get_any_port_info()

int snd_seq_get_any_port_info ( snd_seq_t * seq,
int client,
int port,
snd_seq_port_info_t * info )

obtain the information of a port on an arbitrary client

Parameters
seqsequencer handle
clientclient id to get
portport id to get
infopointer information returns
Returns
0 on success otherwise a negative error code
See also
snd_seq_get_port_info()

◆ snd_seq_get_client_info()

int snd_seq_get_client_info ( snd_seq_t * seq,
snd_seq_client_info_t * info )

obtain the current client information

Parameters
seqsequencer handle
infothe pointer to be stored
Returns
0 on success otherwise a negative error code

Obtains the information of the current client stored on info. client and type fields are ignored.

See also
snd_seq_get_any_client_info(), snd_seq_set_client_info(), snd_seq_query_next_client()

◆ snd_seq_get_client_pool()

int snd_seq_get_client_pool ( snd_seq_t * seq,
snd_seq_client_pool_t * info )

obtain the pool information of the current client

Parameters
seqsequencer handle
infoinformation to be stored

◆ snd_seq_get_input_buffer_size()

size_t snd_seq_get_input_buffer_size ( snd_seq_t * seq)

Return the size of input buffer.

Parameters
seqsequencer handle
Returns
the size of input buffer in bytes

Obtains the size of input buffer. This buffer is used to read byte-stream of input events from sequencer.

See also
snd_seq_set_input_buffer_size()

◆ snd_seq_get_output_buffer_size()

size_t snd_seq_get_output_buffer_size ( snd_seq_t * seq)

Return the size of output buffer.

Parameters
seqsequencer handle
Returns
the size of output buffer in bytes

Obtains the size of output buffer. This buffer is used to store decoded byte-stream of output events before transferring to sequencer.

See also
snd_seq_set_output_buffer_size()

◆ snd_seq_get_port_info()

int snd_seq_get_port_info ( snd_seq_t * seq,
int port,
snd_seq_port_info_t * info )

obtain the information of a port on the current client

Parameters
seqsequencer handle
portport id to get
infopointer information returns
Returns
0 on success otherwise a negative error code
See also
snd_seq_create_port(), snd_seq_get_any_port_info(), snd_seq_set_port_info(), snd_seq_query_next_port()

◆ snd_seq_get_port_subscription()

int snd_seq_get_port_subscription ( snd_seq_t * seq,
snd_seq_port_subscribe_t * sub )

obtain subscription information

Parameters
seqsequencer handle
subpointer to return the subscription information
Returns
0 on success otherwise a negative error code
See also
snd_seq_subscribe_port(), snd_seq_query_port_subscribers()

◆ snd_seq_get_queue_info()

int snd_seq_get_queue_info ( snd_seq_t * seq,
int q,
snd_seq_queue_info_t * info )

obtain queue attributes

Parameters
seqsequencer handle
qqueue id to query
infoinformation returned
Returns
0 on success otherwise a negative error code
See also
snd_seq_alloc_queue(), snd_seq_set_queue_info(), snd_seq_query_named_queue()

◆ snd_seq_get_queue_status()

int snd_seq_get_queue_status ( snd_seq_t * seq,
int q,
snd_seq_queue_status_t * status )

obtain the running state of the queue

Parameters
seqsequencer handle
qqueue id to query
statuspointer to store the current status
Returns
0 on success otherwise a negative error code

Obtains the running state of the specified queue q.

◆ snd_seq_get_queue_tempo()

int snd_seq_get_queue_tempo ( snd_seq_t * seq,
int q,
snd_seq_queue_tempo_t * tempo )

obtain the current tempo of the queue

Parameters
seqsequencer handle
qqueue id to be queried
tempopointer to store the current tempo
Returns
0 on success otherwise a negative error code
See also
snd_seq_set_queue_tempo()

◆ snd_seq_get_queue_timer()

int snd_seq_get_queue_timer ( snd_seq_t * seq,
int q,
snd_seq_queue_timer_t * timer )

obtain the queue timer information

Parameters
seqsequencer handle
qqueue id to query
timerpointer to store the timer information
Returns
0 on success otherwise a negative error code
See also
snd_seq_set_queue_timer()

◆ snd_seq_get_queue_usage()

int snd_seq_get_queue_usage ( snd_seq_t * seq,
int q )

Get the queue usage flag to the client.

Parameters
seqsequencer handle
qqueue id
Returns
1 = client is allowed to access the queue, 0 = not allowed, otherwise a negative error code
See also
snd_seq_get_queue_info(), snd_seq_set_queue_usage()

◆ snd_seq_get_ump_block_info()

int snd_seq_get_ump_block_info ( snd_seq_t * seq,
int client,
int blk,
void * info )

Get UMP Block information.

Parameters
seqsequencer handle
clientsequencer client number to query
blkUMP block number (0-based) to query
infothe pointer to store snd_ump_block_info_t data
Returns
0 on success otherwise a negative error code

◆ snd_seq_get_ump_endpoint_info()

int snd_seq_get_ump_endpoint_info ( snd_seq_t * seq,
int client,
void * info )

Get UMP Endpoint information.

Parameters
seqsequencer handle
clientclient number to query
infothe pointer to store snd_ump_endpoint_info_t data
Returns
0 on success otherwise a negative error code

◆ snd_seq_has_queue_tempo_base()

int snd_seq_has_queue_tempo_base ( snd_seq_t * seq)

inquiry the support of tempo base change

Parameters
seqsequencer handle
Returns
1 if the client supports the tempo base change, 0 if not
See also
snd_seq_get_queue_tempo()

◆ snd_seq_name()

const char * snd_seq_name ( snd_seq_t * seq)

get identifier of sequencer handle

Parameters
seqsequencer handle
Returns
ASCII identifier of sequencer handle

Returns the ASCII identifier of the given sequencer handle. It's the same identifier specified in snd_seq_open().

See also
snd_seq_open()

◆ snd_seq_nonblock()

int snd_seq_nonblock ( snd_seq_t * seq,
int nonblock )

Set nonblock mode.

Parameters
seqsequencer handle
nonblock0 = block, 1 = nonblock mode
Returns
0 on success otherwise a negative error code

Change the blocking mode of the given client. In block mode, the client falls into sleep when it fills the output memory pool with full events. The client will be woken up after a certain amount of free space becomes available.

See also
snd_seq_open()

◆ snd_seq_open()

int snd_seq_open ( snd_seq_t ** seqp,
const char * name,
int streams,
int mode )

Open the ALSA sequencer.

Parameters
seqpPointer to a snd_seq_t pointer. This pointer must be kept and passed to most of the other sequencer functions.
nameThe sequencer's "name". This is not a name you make up for your own purposes; it has special significance to the ALSA library. Usually you need to pass "default" here.
streamsThe read/write mode of the sequencer. Can be one of three values:
  • #SND_SEQ_OPEN_OUTPUT - open the sequencer for output only
  • #SND_SEQ_OPEN_INPUT - open the sequencer for input only
  • #SND_SEQ_OPEN_DUPLEX - open the sequencer for output and input
Note
Internally, these are translated to O_WRONLY, O_RDONLY and O_RDWR respectively and used as the second argument to the C library open() call.
Parameters
modeOptional modifier. Can be either 0, or #SND_SEQ_NONBLOCK, which will make read/write operations non-blocking. This can also be set later using snd_seq_nonblock().
Returns
0 on success otherwise a negative error code

Creates a new handle and opens a connection to the kernel sequencer interface. After a client is created successfully, an event with #SND_SEQ_EVENT_CLIENT_START is broadcast to announce port.

See also
snd_seq_open_lconf(), snd_seq_close(), snd_seq_type(), snd_seq_name(), snd_seq_nonblock(), snd_seq_client_id()

◆ snd_seq_open_lconf()

int snd_seq_open_lconf ( snd_seq_t ** seqp,
const char * name,
int streams,
int mode,
snd_config_t * lconf )

Open the ALSA sequencer using local configuration.

Parameters
seqpPointer to a snd_seq_t pointer.
nameThe name to open
streamsThe read/write mode of the sequencer.
modeOptional modifier
lconfLocal configuration
Returns
0 on success otherwise a negative error code

See the snd_seq_open() function for further details. The extension is that the given configuration is used to resolve abstract name.

See also
snd_seq_open()

◆ snd_seq_poll_descriptors()

int snd_seq_poll_descriptors ( snd_seq_t * seq,
struct pollfd * pfds,
unsigned int space,
short events )

Get poll descriptors.

Parameters
seqsequencer handle
pfdsarray of poll descriptors
spacespace in the poll descriptor array
eventspolling events to be checked (POLLIN and POLLOUT)
Returns
count of filled descriptors

Get poll descriptors assigned to the sequencer handle. Since a sequencer handle can duplex streams, you need to set which direction(s) is/are polled in events argument. When POLLIN bit is specified, the incoming events to the ports are checked.

To check the returned poll-events, call snd_seq_poll_descriptors_revents() instead of reading the pollfd structs directly.

See also
snd_seq_poll_descriptors_count(), snd_seq_poll_descriptors_revents()

◆ snd_seq_poll_descriptors_count()

int snd_seq_poll_descriptors_count ( snd_seq_t * seq,
short events )

Returns the number of poll descriptors.

Parameters
seqsequencer handle
eventsthe poll events to be checked (POLLIN and POLLOUT)
Returns
the number of poll descriptors.

Get the number of poll descriptors. The polling events to be checked can be specified by the second argument. When both input and output are checked, pass POLLIN|POLLOUT

See also
snd_seq_poll_descriptors()

◆ snd_seq_poll_descriptors_revents()

int snd_seq_poll_descriptors_revents ( snd_seq_t * seq,
struct pollfd * pfds,
unsigned int nfds,
unsigned short * revents )

get returned events from poll descriptors

Parameters
seqsequencer handle
pfdsarray of poll descriptors
nfdscount of poll descriptors
reventsreturned events
Returns
zero if success, otherwise a negative error code
See also
snd_seq_poll_descriptors()

◆ snd_seq_port_info_copy()

void snd_seq_port_info_copy ( snd_seq_port_info_t * dst,
const snd_seq_port_info_t * src )

copy one #snd_seq_port_info_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_port_info_free()

void snd_seq_port_info_free ( snd_seq_port_info_t * obj)

frees a previously allocated #snd_seq_port_info_t

Parameters
objpointer to object to free

◆ snd_seq_port_info_get_addr()

const snd_seq_addr_t * snd_seq_port_info_get_addr ( const snd_seq_port_info_t * info)

Get client/port address of a port_info container.

Parameters
infoport_info container
Returns
client/port address pointer
See also
snd_seq_get_port_info(), snd_seq_port_info_set_addr()

◆ snd_seq_port_info_get_capability()

unsigned int snd_seq_port_info_get_capability ( const snd_seq_port_info_t * info)

Get the capability bits of a port_info container.

Parameters
infoport_info container
Returns
capability bits
See also
snd_seq_get_port_info(), snd_seq_port_info_set_capability()

◆ snd_seq_port_info_get_client()

int snd_seq_port_info_get_client ( const snd_seq_port_info_t * info)

Get client id of a port_info container.

Parameters
infoport_info container
Returns
client id
See also
snd_seq_get_port_info(), snd_seq_port_info_set_client()

◆ snd_seq_port_info_get_direction()

int snd_seq_port_info_get_direction ( const snd_seq_port_info_t * info)

Get the direction of the port.

Parameters
infoport_info container
Returns
the direction of the port
See also
snd_seq_get_port_info(), snd_seq_port_info_set_direction()

◆ snd_seq_port_info_get_midi_channels()

int snd_seq_port_info_get_midi_channels ( const snd_seq_port_info_t * info)

Get the midi channels of a port_info container.

Parameters
infoport_info container
Returns
number of midi channels (default 0)
See also
snd_seq_get_port_info(), snd_seq_port_info_set_midi_channels()

◆ snd_seq_port_info_get_midi_voices()

int snd_seq_port_info_get_midi_voices ( const snd_seq_port_info_t * info)

Get the midi voices of a port_info container.

Parameters
infoport_info container
Returns
number of midi voices (default 0)
See also
snd_seq_get_port_info(), snd_seq_port_info_set_midi_voices()

◆ snd_seq_port_info_get_name()

const char * snd_seq_port_info_get_name ( const snd_seq_port_info_t * info)

Get the name of a port_info container.

Parameters
infoport_info container
Returns
name string
See also
snd_seq_get_port_info(), snd_seq_port_info_set_name()

◆ snd_seq_port_info_get_port()

int snd_seq_port_info_get_port ( const snd_seq_port_info_t * info)

Get port id of a port_info container.

Parameters
infoport_info container
Returns
port id
See also
snd_seq_get_port_info(), snd_seq_port_info_set_port()

◆ snd_seq_port_info_get_port_specified()

int snd_seq_port_info_get_port_specified ( const snd_seq_port_info_t * info)

Get the port-specified mode of a port_info container.

Parameters
infoport_info container
Returns
1 if port id is specified at creation
See also
snd_seq_get_port_info(), snd_seq_port_info_set_port_specified()

◆ snd_seq_port_info_get_read_use()

int snd_seq_port_info_get_read_use ( const snd_seq_port_info_t * info)

Get the number of read subscriptions of a port_info container.

Parameters
infoport_info container
Returns
number of read subscriptions
See also
snd_seq_get_port_info()

◆ snd_seq_port_info_get_synth_voices()

int snd_seq_port_info_get_synth_voices ( const snd_seq_port_info_t * info)

Get the synth voices of a port_info container.

Parameters
infoport_info container
Returns
number of synth voices (default 0)
See also
snd_seq_get_port_info(), snd_seq_port_info_set_synth_voices()

◆ snd_seq_port_info_get_timestamp_queue()

int snd_seq_port_info_get_timestamp_queue ( const snd_seq_port_info_t * info)

Get the queue id to update timestamps.

Parameters
infoport_info container
Returns
the queue id to get the timestamps
See also
snd_seq_get_port_info(), snd_seq_port_info_set_timestamp_queue()

◆ snd_seq_port_info_get_timestamp_real()

int snd_seq_port_info_get_timestamp_real ( const snd_seq_port_info_t * info)

Get whether the time-stamping of the given port is real-time mode.

Parameters
infoport_info container
Returns
1 if the time-stamping is in the real-time mode
See also
snd_seq_get_port_info(), snd_seq_port_info_set_timestamp_real()

◆ snd_seq_port_info_get_timestamping()

int snd_seq_port_info_get_timestamping ( const snd_seq_port_info_t * info)

Get the time-stamping mode of the given port in a port_info container.

Parameters
infoport_info container
Returns
1 if the port updates timestamps of incoming events
See also
snd_seq_get_port_info(), snd_seq_port_info_set_timestamping()

◆ snd_seq_port_info_get_type()

unsigned int snd_seq_port_info_get_type ( const snd_seq_port_info_t * info)

Get the type bits of a port_info container.

Parameters
infoport_info container
Returns
port type bits
See also
snd_seq_get_port_info(), snd_seq_port_info_set_type()

◆ snd_seq_port_info_get_ump_group()

int snd_seq_port_info_get_ump_group ( const snd_seq_port_info_t * info)

Get the UMP Group assigned to the port.

Parameters
infoport_info container
Returns
0 for no conversion, or the (1-based) UMP Group number assigned to the port
See also
snd_seq_get_port_info(), snd_seq_port_info_set_ump_group()

◆ snd_seq_port_info_get_ump_is_midi1()

int snd_seq_port_info_get_ump_is_midi1 ( const snd_seq_port_info_t * info)

Get the status of the optional MIDI 1.0 port in MIDI 2.0 UMP Endpoint.

Parameters
infoport_info container
Returns
1 if it's an optional MIDI 1.0 port in MIDI 2.0 UMP Endpoint
See also
snd_seq_get_port_info(), snd_seq_port_info_set_ump_is_midi1()

◆ snd_seq_port_info_get_write_use()

int snd_seq_port_info_get_write_use ( const snd_seq_port_info_t * info)

Get the number of write subscriptions of a port_info container.

Parameters
infoport_info container
Returns
number of write subscriptions
See also
snd_seq_get_port_info()

◆ snd_seq_port_info_malloc()

int snd_seq_port_info_malloc ( snd_seq_port_info_t ** ptr)

allocate an empty #snd_seq_port_info_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_port_info_set_addr()

void snd_seq_port_info_set_addr ( snd_seq_port_info_t * info,
const snd_seq_addr_t * addr )

Set the client/port address of a port_info container.

Parameters
infoport_info container
addrclient/port address
See also
snd_seq_get_port_info(), snd_seq_port_info_get_addr()

◆ snd_seq_port_info_set_capability()

void snd_seq_port_info_set_capability ( snd_seq_port_info_t * info,
unsigned int capability )

set the capability bits of a port_info container

Parameters
infoport_info container
capabilitycapability bits
See also
snd_seq_get_port_info(), snd_seq_port_info_get_capability()

◆ snd_seq_port_info_set_client()

void snd_seq_port_info_set_client ( snd_seq_port_info_t * info,
int client )

Set the client id of a port_info container.

Parameters
infoport_info container
clientclient id
See also
snd_seq_get_port_info(), snd_seq_port_info_get_client()

◆ snd_seq_port_info_set_direction()

void snd_seq_port_info_set_direction ( snd_seq_port_info_t * info,
int direction )

Set the direction of the port.

Parameters
infoport_info container
directionthe port direction
See also
snd_seq_get_port_info(), snd_seq_port_info_get_direction()

◆ snd_seq_port_info_set_midi_channels()

void snd_seq_port_info_set_midi_channels ( snd_seq_port_info_t * info,
int channels )

set the midi channels of a port_info container

Parameters
infoport_info container
channelsmidi channels (default 0)
See also
snd_seq_get_port_info(), snd_seq_port_info_get_midi_channels()

◆ snd_seq_port_info_set_midi_voices()

void snd_seq_port_info_set_midi_voices ( snd_seq_port_info_t * info,
int voices )

set the midi voices of a port_info container

Parameters
infoport_info container
voicesmidi voices (default 0)
See also
snd_seq_get_port_info(), snd_seq_port_info_get_midi_voices()

◆ snd_seq_port_info_set_name()

void snd_seq_port_info_set_name ( snd_seq_port_info_t * info,
const char * name )

Set the name of a port_info container.

Parameters
infoport_info container
namename string
See also
snd_seq_get_port_info(), snd_seq_port_info_get_name()

◆ snd_seq_port_info_set_port()

void snd_seq_port_info_set_port ( snd_seq_port_info_t * info,
int port )

Set the port id of a port_info container.

Parameters
infoport_info container
portport id
See also
snd_seq_get_port_info(), snd_seq_port_info_get_port()

◆ snd_seq_port_info_set_port_specified()

void snd_seq_port_info_set_port_specified ( snd_seq_port_info_t * info,
int val )

Set the port-specified mode of a port_info container.

Parameters
infoport_info container
valnon-zero if specifying the port id at creation
See also
snd_seq_get_port_info(), snd_seq_port_info_get_port_specified()

◆ snd_seq_port_info_set_synth_voices()

void snd_seq_port_info_set_synth_voices ( snd_seq_port_info_t * info,
int voices )

set the synth voices of a port_info container

Parameters
infoport_info container
voicessynth voices (default 0)
See also
snd_seq_get_port_info(), snd_seq_port_info_get_synth_voice()

◆ snd_seq_port_info_set_timestamp_queue()

void snd_seq_port_info_set_timestamp_queue ( snd_seq_port_info_t * info,
int queue )

Set the queue id for timestamping.

Parameters
infoport_info container
queuethe queue id to get timestamps
See also
snd_seq_get_port_info(), snd_seq_port_info_get_timestamp_queue()

◆ snd_seq_port_info_set_timestamp_real()

void snd_seq_port_info_set_timestamp_real ( snd_seq_port_info_t * info,
int enable )

Set whether the timestime is updated in the real-time mode.

Parameters
infoport_info container
enablenon-zero if updating the timestamps in real-time mode
See also
snd_seq_get_port_info(), snd_seq_port_info_get_timestamp_real()

◆ snd_seq_port_info_set_timestamping()

void snd_seq_port_info_set_timestamping ( snd_seq_port_info_t * info,
int enable )

Set the time-stamping mode of the given port.

Parameters
infoport_info container
enablenon-zero if updating the timestamps of incoming events
See also
snd_seq_get_port_info(), snd_seq_port_info_get_timestamping()

◆ snd_seq_port_info_set_type()

void snd_seq_port_info_set_type ( snd_seq_port_info_t * info,
unsigned int type )

Get the type bits of a port_info container.

Parameters
infoport_info container
typeport type bits
See also
snd_seq_get_port_info(), snd_seq_port_info_get_type()

◆ snd_seq_port_info_set_ump_group()

void snd_seq_port_info_set_ump_group ( snd_seq_port_info_t * info,
int ump_group )

Set the UMP Group assigned to the port.

Parameters
infoport_info container
ump_group0 for no conversion, or the (1-based) UMP Group number
See also
snd_seq_get_port_info(), snd_seq_port_info_get_ump_group()

◆ snd_seq_port_info_set_ump_is_midi1()

void snd_seq_port_info_set_ump_is_midi1 ( snd_seq_port_info_t * info,
int is_midi1 )

Set the optional MIDI 1.0 port in MIDI 2.0 UMP Endpoint.

Parameters
infoport_info container
is_midi1non-zero for MIDI 1.0 port in MIDI 2.0 EP
See also
snd_seq_get_port_info(), snd_seq_port_info_get_ump_is_midi1()

◆ snd_seq_port_info_sizeof()

size_t snd_seq_port_info_sizeof ( )

get size of #snd_seq_port_info_t

Returns
size in bytes

◆ snd_seq_port_subscribe_copy()

void snd_seq_port_subscribe_copy ( snd_seq_port_subscribe_t * dst,
const snd_seq_port_subscribe_t * src )

copy one #snd_seq_port_subscribe_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_port_subscribe_free()

void snd_seq_port_subscribe_free ( snd_seq_port_subscribe_t * obj)

frees a previously allocated #snd_seq_port_subscribe_t

Parameters
objpointer to object to free

◆ snd_seq_port_subscribe_get_dest()

const snd_seq_addr_t * snd_seq_port_subscribe_get_dest ( const snd_seq_port_subscribe_t * info)

Get destination address of a port_subscribe container.

Parameters
infoport_subscribe container
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_set_dest()

◆ snd_seq_port_subscribe_get_exclusive()

int snd_seq_port_subscribe_get_exclusive ( const snd_seq_port_subscribe_t * info)

Get the exclusive mode of a port_subscribe container.

Parameters
infoport_subscribe container
Returns
1 if exclusive mode
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_set_exclusive()

◆ snd_seq_port_subscribe_get_queue()

int snd_seq_port_subscribe_get_queue ( const snd_seq_port_subscribe_t * info)

Get the queue id of a port_subscribe container.

Parameters
infoport_subscribe container
Returns
queue id
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_set_queue()

◆ snd_seq_port_subscribe_get_sender()

const snd_seq_addr_t * snd_seq_port_subscribe_get_sender ( const snd_seq_port_subscribe_t * info)

Get sender address of a port_subscribe container.

Parameters
infoport_subscribe container
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_set_sender()

◆ snd_seq_port_subscribe_get_time_real()

int snd_seq_port_subscribe_get_time_real ( const snd_seq_port_subscribe_t * info)

Get the real-time update mode of a port_subscribe container.

Parameters
infoport_subscribe container
Returns
1 if real-time update mode
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_set_time_real()

◆ snd_seq_port_subscribe_get_time_update()

int snd_seq_port_subscribe_get_time_update ( const snd_seq_port_subscribe_t * info)

Get the time-update mode of a port_subscribe container.

Parameters
infoport_subscribe container
Returns
1 if update timestamp
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_set_time_update()

◆ snd_seq_port_subscribe_malloc()

int snd_seq_port_subscribe_malloc ( snd_seq_port_subscribe_t ** ptr)

allocate an empty #snd_seq_port_subscribe_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_port_subscribe_set_dest()

void snd_seq_port_subscribe_set_dest ( snd_seq_port_subscribe_t * info,
const snd_seq_addr_t * addr )

Set destination address of a port_subscribe container.

Parameters
infoport_subscribe container
addrdestination address
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_get_dest()

◆ snd_seq_port_subscribe_set_exclusive()

void snd_seq_port_subscribe_set_exclusive ( snd_seq_port_subscribe_t * info,
int val )

Set the exclusive mode of a port_subscribe container.

Parameters
infoport_subscribe container
valnon-zero to enable
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_get_exclusive()

◆ snd_seq_port_subscribe_set_queue()

void snd_seq_port_subscribe_set_queue ( snd_seq_port_subscribe_t * info,
int q )

Set the queue id of a port_subscribe container.

Parameters
infoport_subscribe container
qqueue id
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_get_queue()

◆ snd_seq_port_subscribe_set_sender()

void snd_seq_port_subscribe_set_sender ( snd_seq_port_subscribe_t * info,
const snd_seq_addr_t * addr )

Set sender address of a port_subscribe container.

Parameters
infoport_subscribe container
addrsender address
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_get_sender()

◆ snd_seq_port_subscribe_set_time_real()

void snd_seq_port_subscribe_set_time_real ( snd_seq_port_subscribe_t * info,
int val )

Set the real-time mode of a port_subscribe container.

Parameters
infoport_subscribe container
valnon-zero to enable
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_get_time_real()

◆ snd_seq_port_subscribe_set_time_update()

void snd_seq_port_subscribe_set_time_update ( snd_seq_port_subscribe_t * info,
int val )

Set the time-update mode of a port_subscribe container.

Parameters
infoport_subscribe container
valnon-zero to enable
See also
snd_seq_subscribe_port(), snd_seq_port_subscribe_get_time_update()

◆ snd_seq_port_subscribe_sizeof()

size_t snd_seq_port_subscribe_sizeof ( )

get size of #snd_seq_port_subscribe_t

Returns
size in bytes

◆ snd_seq_query_named_queue()

int snd_seq_query_named_queue ( snd_seq_t * seq,
const char * name )

query the matching queue with the specified name

Parameters
seqsequencer handle
namethe name string to query
Returns
the queue id if found or negative error code

Searches the matching queue with the specified name string.

See also
snd_seq_get_queue_info()

◆ snd_seq_query_next_client()

int snd_seq_query_next_client ( snd_seq_t * seq,
snd_seq_client_info_t * info )

query the next client

Parameters
seqsequencer handle
infoquery pattern and result

Queries the next client. The search begins at the client with an id one greater than client field in info. If a client is found, its attributes are stored in info, and zero is returned. Otherwise returns a negative error code.

See also
snd_seq_get_any_client_info()

◆ snd_seq_query_next_port()

int snd_seq_query_next_port ( snd_seq_t * seq,
snd_seq_port_info_t * info )

query the next matching port

Parameters
seqsequencer handle
infoquery pattern and result

Queries the next matching port on the client specified in info argument. The search begins at the next port specified in port field of info argument. For finding the first port at a certain client, give -1.

If a matching port is found, its attributes are stored on info and function returns zero. Otherwise, a negative error code is returned.

See also
snd_seq_get_port_info()

◆ snd_seq_query_port_subscribers()

int snd_seq_query_port_subscribers ( snd_seq_t * seq,
snd_seq_query_subscribe_t * subs )

query port subscriber list

Parameters
seqsequencer handle
subssubscription to query
Returns
0 on success otherwise a negative error code

Queries the subscribers accessing to a port. The query information is specified in subs argument.

At least, the client id, the port id, the index number and the query type must be set to perform a proper query. As the query type, #SND_SEQ_QUERY_SUBS_READ or #SND_SEQ_QUERY_SUBS_WRITE can be specified to check whether the readers or the writers to the port. To query the first subscription, set 0 to the index number. To list up all the subscriptions, call this function with the index numbers from 0 until this returns a negative value.

See also
snd_seq_get_port_subscription()

◆ snd_seq_query_subscribe_copy()

void snd_seq_query_subscribe_copy ( snd_seq_query_subscribe_t * dst,
const snd_seq_query_subscribe_t * src )

copy one #snd_seq_query_subscribe_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_query_subscribe_free()

void snd_seq_query_subscribe_free ( snd_seq_query_subscribe_t * obj)

frees a previously allocated #snd_seq_query_subscribe_t

Parameters
objpointer to object to free

◆ snd_seq_query_subscribe_get_addr()

const snd_seq_addr_t * snd_seq_query_subscribe_get_addr ( const snd_seq_query_subscribe_t * info)

Get the address of subscriber of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
subscriber's address pointer
See also
snd_seq_query_port_subscribers()

◆ snd_seq_query_subscribe_get_client()

int snd_seq_query_subscribe_get_client ( const snd_seq_query_subscribe_t * info)

Get the client id of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
client id
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_set_client()

◆ snd_seq_query_subscribe_get_exclusive()

int snd_seq_query_subscribe_get_exclusive ( const snd_seq_query_subscribe_t * info)

Get the exclusive mode of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
1 if exclusive mode
See also
snd_seq_query_port_subscribers()

◆ snd_seq_query_subscribe_get_index()

int snd_seq_query_subscribe_get_index ( const snd_seq_query_subscribe_t * info)

Get the index of subscriber of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
subscriber's index
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_set_index()

◆ snd_seq_query_subscribe_get_num_subs()

int snd_seq_query_subscribe_get_num_subs ( const snd_seq_query_subscribe_t * info)

Get the number of subscriptions of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
number of subscriptions
See also
snd_seq_query_port_subscribers()

◆ snd_seq_query_subscribe_get_port()

int snd_seq_query_subscribe_get_port ( const snd_seq_query_subscribe_t * info)

Get the port id of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
port id
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_set_port()

◆ snd_seq_query_subscribe_get_queue()

int snd_seq_query_subscribe_get_queue ( const snd_seq_query_subscribe_t * info)

Get the queue id of subscriber of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
subscriber's queue id
See also
snd_seq_query_port_subscribers()

◆ snd_seq_query_subscribe_get_root()

const snd_seq_addr_t * snd_seq_query_subscribe_get_root ( const snd_seq_query_subscribe_t * info)

Get the client/port address of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
client/port address pointer
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_set_root()

◆ snd_seq_query_subscribe_get_time_real()

int snd_seq_query_subscribe_get_time_real ( const snd_seq_query_subscribe_t * info)

Get the real-time update mode of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
1 if real-time update mode
See also
snd_seq_query_port_subscribers()

◆ snd_seq_query_subscribe_get_time_update()

int snd_seq_query_subscribe_get_time_update ( const snd_seq_query_subscribe_t * info)

Get the time-update mode of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
1 if update timestamp
See also
snd_seq_query_port_subscribers()

◆ snd_seq_query_subscribe_get_type()

snd_seq_query_subs_type_t snd_seq_query_subscribe_get_type ( const snd_seq_query_subscribe_t * info)

Get the query type of a query_subscribe container.

Parameters
infoquery_subscribe container
Returns
query type
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_set_type()

◆ snd_seq_query_subscribe_malloc()

int snd_seq_query_subscribe_malloc ( snd_seq_query_subscribe_t ** ptr)

allocate an empty #snd_seq_query_subscribe_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_query_subscribe_set_client()

void snd_seq_query_subscribe_set_client ( snd_seq_query_subscribe_t * info,
int client )

Set the client id of a query_subscribe container.

Parameters
infoquery_subscribe container
clientclient id
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_get_client()

◆ snd_seq_query_subscribe_set_index()

void snd_seq_query_subscribe_set_index ( snd_seq_query_subscribe_t * info,
int index )

Set the subscriber's index to be queried.

Parameters
infoquery_subscribe container
indexindex to be queried
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_get_index()

◆ snd_seq_query_subscribe_set_port()

void snd_seq_query_subscribe_set_port ( snd_seq_query_subscribe_t * info,
int port )

Set the port id of a query_subscribe container.

Parameters
infoquery_subscribe container
portport id
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_get_port()

◆ snd_seq_query_subscribe_set_root()

void snd_seq_query_subscribe_set_root ( snd_seq_query_subscribe_t * info,
const snd_seq_addr_t * addr )

Set the client/port address of a query_subscribe container.

Parameters
infoquery_subscribe container
addrclient/port address pointer
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_get_root()

◆ snd_seq_query_subscribe_set_type()

void snd_seq_query_subscribe_set_type ( snd_seq_query_subscribe_t * info,
snd_seq_query_subs_type_t type )

Set the query type of a query_subscribe container.

Parameters
infoquery_subscribe container
typequery type
See also
snd_seq_query_port_subscribers(), snd_seq_query_subscribe_get_type()

◆ snd_seq_query_subscribe_sizeof()

size_t snd_seq_query_subscribe_sizeof ( )

get size of #snd_seq_query_subscribe_t

Returns
size in bytes

◆ snd_seq_queue_info_copy()

void snd_seq_queue_info_copy ( snd_seq_queue_info_t * dst,
const snd_seq_queue_info_t * src )

copy one #snd_seq_queue_info_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_queue_info_free()

void snd_seq_queue_info_free ( snd_seq_queue_info_t * obj)

frees a previously allocated #snd_seq_queue_info_t

Parameters
objpointer to object to free

◆ snd_seq_queue_info_get_flags()

unsigned int snd_seq_queue_info_get_flags ( const snd_seq_queue_info_t * info)

Get the conditional bit flags of a queue_info container.

Parameters
infoqueue_info container
Returns
conditional bit flags
See also
snd_seq_get_queue_info(), snd_seq_queue_info_set_flags()

◆ snd_seq_queue_info_get_locked()

int snd_seq_queue_info_get_locked ( const snd_seq_queue_info_t * info)

Get the lock status of a queue_info container.

Parameters
infoqueue_info container
Returns
lock status — non-zero = locked
See also
snd_seq_get_queue_info(), snd_seq_queue_info_set_locked()

◆ snd_seq_queue_info_get_name()

const char * snd_seq_queue_info_get_name ( const snd_seq_queue_info_t * info)

Get the name of a queue_info container.

Parameters
infoqueue_info container
Returns
name string
See also
snd_seq_get_queue_info(), snd_seq_queue_info_set_name()

◆ snd_seq_queue_info_get_owner()

int snd_seq_queue_info_get_owner ( const snd_seq_queue_info_t * info)

Get the owner client id of a queue_info container.

Parameters
infoqueue_info container
Returns
owner client id
See also
snd_seq_get_queue_info(), snd_seq_queue_info_set_owner()

◆ snd_seq_queue_info_get_queue()

int snd_seq_queue_info_get_queue ( const snd_seq_queue_info_t * info)

Get the queue id of a queue_info container.

Parameters
infoqueue_info container
Returns
queue id
See also
snd_seq_get_queue_info(), snd_seq_queue_info_set_queue()

◆ snd_seq_queue_info_malloc()

int snd_seq_queue_info_malloc ( snd_seq_queue_info_t ** ptr)

allocate an empty #snd_seq_queue_info_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_queue_info_set_flags()

void snd_seq_queue_info_set_flags ( snd_seq_queue_info_t * info,
unsigned int flags )

Set the conditional bit flags of a queue_info container.

Parameters
infoqueue_info container
flagsconditional bit flags
See also
snd_seq_get_queue_info(), snd_seq_queue_info_get_flags()

◆ snd_seq_queue_info_set_locked()

void snd_seq_queue_info_set_locked ( snd_seq_queue_info_t * info,
int locked )

Set the lock status of a queue_info container.

Parameters
infoqueue_info container
lockedlock status
See also
snd_seq_get_queue_info(), snd_seq_queue_info_get_locked()

◆ snd_seq_queue_info_set_name()

void snd_seq_queue_info_set_name ( snd_seq_queue_info_t * info,
const char * name )

Set the name of a queue_info container.

Parameters
infoqueue_info container
namename string
See also
snd_seq_get_queue_info(), snd_seq_queue_info_get_name()

◆ snd_seq_queue_info_set_owner()

void snd_seq_queue_info_set_owner ( snd_seq_queue_info_t * info,
int owner )

Set the owner client id of a queue_info container.

Parameters
infoqueue_info container
ownerclient id
See also
snd_seq_get_queue_info(), snd_seq_queue_info_get_owner()

◆ snd_seq_queue_info_sizeof()

size_t snd_seq_queue_info_sizeof ( )

get size of #snd_seq_queue_info_t

Returns
size in bytes

◆ snd_seq_queue_status_copy()

void snd_seq_queue_status_copy ( snd_seq_queue_status_t * dst,
const snd_seq_queue_status_t * src )

copy one #snd_seq_queue_status_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_queue_status_free()

void snd_seq_queue_status_free ( snd_seq_queue_status_t * obj)

frees a previously allocated #snd_seq_queue_status_t

Parameters
objpointer to object to free

◆ snd_seq_queue_status_get_events()

int snd_seq_queue_status_get_events ( const snd_seq_queue_status_t * info)

Get the number of events of a queue_status container.

Parameters
infoqueue_status container
Returns
number of events
See also
snd_seq_get_queue_status()

◆ snd_seq_queue_status_get_queue()

int snd_seq_queue_status_get_queue ( const snd_seq_queue_status_t * info)

Get the queue id of a queue_status container.

Parameters
infoqueue_status container
Returns
queue id
See also
snd_seq_get_queue_status()

◆ snd_seq_queue_status_get_real_time()

const snd_seq_real_time_t * snd_seq_queue_status_get_real_time ( const snd_seq_queue_status_t * info)

Get the real time of a queue_status container.

Parameters
infoqueue_status container
See also
snd_seq_get_queue_status()

◆ snd_seq_queue_status_get_status()

unsigned int snd_seq_queue_status_get_status ( const snd_seq_queue_status_t * info)

Get the running status bits of a queue_status container.

Parameters
infoqueue_status container
Returns
running status bits
See also
snd_seq_get_queue_status()

◆ snd_seq_queue_status_get_tick_time()

snd_seq_tick_time_t snd_seq_queue_status_get_tick_time ( const snd_seq_queue_status_t * info)

Get the tick time of a queue_status container.

Parameters
infoqueue_status container
Returns
tick time
See also
snd_seq_get_queue_status()

◆ snd_seq_queue_status_malloc()

int snd_seq_queue_status_malloc ( snd_seq_queue_status_t ** ptr)

allocate an empty #snd_seq_queue_status_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_queue_status_sizeof()

size_t snd_seq_queue_status_sizeof ( )

get size of #snd_seq_queue_status_t

Returns
size in bytes

◆ snd_seq_queue_tempo_copy()

void snd_seq_queue_tempo_copy ( snd_seq_queue_tempo_t * dst,
const snd_seq_queue_tempo_t * src )

copy one #snd_seq_queue_tempo_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_queue_tempo_free()

void snd_seq_queue_tempo_free ( snd_seq_queue_tempo_t * obj)

frees a previously allocated #snd_seq_queue_tempo_t

Parameters
objpointer to object to free

◆ snd_seq_queue_tempo_get_ppq()

int snd_seq_queue_tempo_get_ppq ( const snd_seq_queue_tempo_t * info)

Get the ppq of a queue_status container.

Parameters
infoqueue_status container
Returns
ppq value
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_get_queue()

int snd_seq_queue_tempo_get_queue ( const snd_seq_queue_tempo_t * info)

Get the queue id of a queue_status container.

Parameters
infoqueue_status container
Returns
queue id
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_get_skew()

unsigned int snd_seq_queue_tempo_get_skew ( const snd_seq_queue_tempo_t * info)

Get the timer skew value of a queue_status container.

Parameters
infoqueue_status container
Returns
timer skew value
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_get_skew_base()

unsigned int snd_seq_queue_tempo_get_skew_base ( const snd_seq_queue_tempo_t * info)

Get the timer skew base value of a queue_status container.

Parameters
infoqueue_status container
Returns
timer skew base value
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_get_tempo()

unsigned int snd_seq_queue_tempo_get_tempo ( const snd_seq_queue_tempo_t * info)

Get the tempo of a queue_status container.

Parameters
infoqueue_status container
Returns
tempo value
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_get_tempo_base()

unsigned int snd_seq_queue_tempo_get_tempo_base ( const snd_seq_queue_tempo_t * info)

Get the tempo base of a queue_status container.

Parameters
infoqueue_status container
Returns
tempo base time in nsec unit
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_malloc()

int snd_seq_queue_tempo_malloc ( snd_seq_queue_tempo_t ** ptr)

allocate an empty #snd_seq_queue_tempo_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_queue_tempo_set_ppq()

void snd_seq_queue_tempo_set_ppq ( snd_seq_queue_tempo_t * info,
int ppq )

Set the ppq of a queue_status container.

Parameters
infoqueue_status container
ppqppq value
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_set_skew()

void snd_seq_queue_tempo_set_skew ( snd_seq_queue_tempo_t * info,
unsigned int skew )

Set the timer skew value of a queue_status container.

Parameters
infoqueue_status container
skewtimer skew value

The skew of timer is calculated as skew / base. For example, to play with double speed, pass base * 2 as the skew value.

See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_set_skew_base()

void snd_seq_queue_tempo_set_skew_base ( snd_seq_queue_tempo_t * info,
unsigned int base )

Set the timer skew base value of a queue_status container.

Parameters
infoqueue_status container
basetimer skew base value
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_set_tempo()

void snd_seq_queue_tempo_set_tempo ( snd_seq_queue_tempo_t * info,
unsigned int tempo )

Set the tempo of a queue_status container.

Parameters
infoqueue_status container
tempotempo value
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_set_tempo_base()

void snd_seq_queue_tempo_set_tempo_base ( snd_seq_queue_tempo_t * info,
unsigned int tempo_base )

Set the tempo base of a queue_status container.

Parameters
infoqueue_status container
tempo_basetempo base time in nsec unit
See also
snd_seq_get_queue_tempo()

◆ snd_seq_queue_tempo_sizeof()

size_t snd_seq_queue_tempo_sizeof ( )

get size of #snd_seq_queue_tempo_t

Returns
size in bytes

◆ snd_seq_queue_timer_copy()

void snd_seq_queue_timer_copy ( snd_seq_queue_timer_t * dst,
const snd_seq_queue_timer_t * src )

copy one #snd_seq_queue_timer_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_queue_timer_free()

void snd_seq_queue_timer_free ( snd_seq_queue_timer_t * obj)

frees a previously allocated #snd_seq_queue_timer_t

Parameters
objpointer to object to free

◆ snd_seq_queue_timer_get_id()

const snd_timer_id_t * snd_seq_queue_timer_get_id ( const snd_seq_queue_timer_t * info)

Get the timer id of a queue_timer container.

Parameters
infoqueue_timer container
Returns
timer id pointer
See also
snd_seq_get_queue_timer()

◆ snd_seq_queue_timer_get_queue()

int snd_seq_queue_timer_get_queue ( const snd_seq_queue_timer_t * info)

Get the queue id of a queue_timer container.

Parameters
infoqueue_timer container
Returns
queue id
See also
snd_seq_get_queue_timer()

◆ snd_seq_queue_timer_get_resolution()

unsigned int snd_seq_queue_timer_get_resolution ( const snd_seq_queue_timer_t * info)

Get the timer resolution of a queue_timer container.

Parameters
infoqueue_timer container
Returns
timer resolution
See also
snd_seq_get_queue_timer()

◆ snd_seq_queue_timer_get_type()

snd_seq_queue_timer_type_t snd_seq_queue_timer_get_type ( const snd_seq_queue_timer_t * info)

Get the timer type of a queue_timer container.

Parameters
infoqueue_timer container
Returns
timer type
See also
snd_seq_get_queue_timer()

◆ snd_seq_queue_timer_malloc()

int snd_seq_queue_timer_malloc ( snd_seq_queue_timer_t ** ptr)

allocate an empty #snd_seq_queue_timer_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_queue_timer_set_id()

void snd_seq_queue_timer_set_id ( snd_seq_queue_timer_t * info,
const snd_timer_id_t * id )

Set the timer id of a queue_timer container.

Parameters
infoqueue_timer container
idtimer id pointer
See also
snd_seq_get_queue_timer()

◆ snd_seq_queue_timer_set_resolution()

void snd_seq_queue_timer_set_resolution ( snd_seq_queue_timer_t * info,
unsigned int resolution )

Set the timer resolution of a queue_timer container.

Parameters
infoqueue_timer container
resolutiontimer resolution
See also
snd_seq_get_queue_timer()

◆ snd_seq_queue_timer_set_type()

void snd_seq_queue_timer_set_type ( snd_seq_queue_timer_t * info,
snd_seq_queue_timer_type_t type )

Set the timer type of a queue_timer container.

Parameters
infoqueue_timer container
typetimer type
See also
snd_seq_get_queue_timer()

◆ snd_seq_queue_timer_sizeof()

size_t snd_seq_queue_timer_sizeof ( )

get size of #snd_seq_queue_timer_t

Returns
size in bytes

◆ snd_seq_remove_events()

int snd_seq_remove_events ( snd_seq_t * seq,
snd_seq_remove_events_t * rmp )

remove events on input/output buffers and pools

Parameters
seqsequencer handle
rmpremove event container

Removes matching events with the given condition from input/output buffers and pools. The removal condition is specified in rmp argument.

See also
snd_seq_event_output(), snd_seq_drop_output(), snd_seq_reset_pool_output()

◆ snd_seq_remove_events_copy()

void snd_seq_remove_events_copy ( snd_seq_remove_events_t * dst,
const snd_seq_remove_events_t * src )

copy one #snd_seq_remove_events_t to another

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_remove_events_free()

void snd_seq_remove_events_free ( snd_seq_remove_events_t * obj)

frees a previously allocated #snd_seq_remove_events_t

Parameters
objpointer to object to free

◆ snd_seq_remove_events_get_channel()

int snd_seq_remove_events_get_channel ( const snd_seq_remove_events_t * info)

Get the event channel as removal condition.

Parameters
inforemove_events container
Returns
channel number
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_get_condition()

unsigned int snd_seq_remove_events_get_condition ( const snd_seq_remove_events_t * info)

Get the removal condition bits.

Parameters
inforemove_events container
Returns
removal condition bits
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_get_dest()

const snd_seq_addr_t * snd_seq_remove_events_get_dest ( const snd_seq_remove_events_t * info)

Get the event destination address as removal condition.

Parameters
inforemove_events container
Returns
destination address
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_get_event_type()

int snd_seq_remove_events_get_event_type ( const snd_seq_remove_events_t * info)

Get the event type as removal condition.

Parameters
inforemove_events container
Returns
event type
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_get_queue()

int snd_seq_remove_events_get_queue ( const snd_seq_remove_events_t * info)

Get the queue as removal condition.

Parameters
inforemove_events container
Returns
queue id
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_get_tag()

int snd_seq_remove_events_get_tag ( const snd_seq_remove_events_t * info)

Get the event tag id as removal condition.

Parameters
inforemove_events container
Returns
tag id
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_get_time()

const snd_seq_timestamp_t * snd_seq_remove_events_get_time ( const snd_seq_remove_events_t * info)

Get the event timestamp as removal condition.

Parameters
inforemove_events container
Returns
time stamp
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_malloc()

int snd_seq_remove_events_malloc ( snd_seq_remove_events_t ** ptr)

allocate an empty #snd_seq_remove_events_t using standard malloc

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_remove_events_set_channel()

void snd_seq_remove_events_set_channel ( snd_seq_remove_events_t * info,
int channel )

Set the channel as removal condition.

Parameters
inforemove_events container
channelchannel number
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_set_condition()

void snd_seq_remove_events_set_condition ( snd_seq_remove_events_t * info,
unsigned int flags )

Set the removal condition bits.

Parameters
inforemove_events container
flagsremoval condition bits
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_set_dest()

void snd_seq_remove_events_set_dest ( snd_seq_remove_events_t * info,
const snd_seq_addr_t * addr )

Set the destination address as removal condition.

Parameters
inforemove_events container
addrdestination address
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_set_event_type()

void snd_seq_remove_events_set_event_type ( snd_seq_remove_events_t * info,
int type )

Set the event type as removal condition.

Parameters
inforemove_events container
typeevent type
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_set_queue()

void snd_seq_remove_events_set_queue ( snd_seq_remove_events_t * info,
int queue )

Set the queue as removal condition.

Parameters
inforemove_events container
queuequeue id
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_set_tag()

void snd_seq_remove_events_set_tag ( snd_seq_remove_events_t * info,
int tag )

Set the event tag as removal condition.

Parameters
inforemove_events container
tagtag id
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_set_time()

void snd_seq_remove_events_set_time ( snd_seq_remove_events_t * info,
const snd_seq_timestamp_t * time )

Set the timestamp as removal condition.

Parameters
inforemove_events container
timetimestamp pointer
See also
snd_seq_remove_events()

◆ snd_seq_remove_events_sizeof()

size_t snd_seq_remove_events_sizeof ( )

get size of #snd_seq_remove_events_t

Returns
size in bytes

◆ snd_seq_set_client_info()

int snd_seq_set_client_info ( snd_seq_t * seq,
snd_seq_client_info_t * info )

set the current client information

Parameters
seqsequencer handle
infothe client info data to set
Returns
0 on success otherwise a negative error code

Obtains the information of the current client stored on info. client and type fields are ignored.

See also
snd_seq_get_client_info()

◆ snd_seq_set_client_pool()

int snd_seq_set_client_pool ( snd_seq_t * seq,
snd_seq_client_pool_t * info )

set the pool information

Parameters
seqsequencer handle
infoinformation to update

Sets the pool information of the current client. The client field in info is replaced automatically with the current id.

◆ snd_seq_set_input_buffer_size()

int snd_seq_set_input_buffer_size ( snd_seq_t * seq,
size_t size )

Resize the input buffer.

Parameters
seqsequencer handle
sizethe size of input buffer to be changed in bytes
Returns
0 on success otherwise a negative error code

Changes the size of input buffer.

See also
snd_seq_get_input_buffer_size()

◆ snd_seq_set_output_buffer_size()

int snd_seq_set_output_buffer_size ( snd_seq_t * seq,
size_t size )

Change the size of output buffer.

Parameters
seqsequencer handle
sizethe size of output buffer to be changed in bytes
Returns
0 on success otherwise a negative error code

Changes the size of output buffer.

See also
snd_seq_get_output_buffer_size()

◆ snd_seq_set_port_info()

int snd_seq_set_port_info ( snd_seq_t * seq,
int port,
snd_seq_port_info_t * info )

set the information of a port on the current client

Parameters
seqsequencer handle
portport to be set
infoport information to be set
Returns
0 on success otherwise a negative error code
See also
snd_seq_set_port_info()

◆ snd_seq_set_queue_info()

int snd_seq_set_queue_info ( snd_seq_t * seq,
int q,
snd_seq_queue_info_t * info )

change the queue attributes

Parameters
seqsequencer handle
qqueue id to change
infoinformation changed
Returns
0 on success otherwise a negative error code
See also
snd_seq_get_queue_info()

◆ snd_seq_set_queue_tempo()

int snd_seq_set_queue_tempo ( snd_seq_t * seq,
int q,
snd_seq_queue_tempo_t * tempo )

set the tempo of the queue

Parameters
seqsequencer handle
qqueue id to change the tempo
tempotempo information
Returns
0 on success otherwise a negative error code
See also
snd_seq_get_queue_tempo()

◆ snd_seq_set_queue_timer()

int snd_seq_set_queue_timer ( snd_seq_t * seq,
int q,
snd_seq_queue_timer_t * timer )

set the queue timer information

Parameters
seqsequencer handle
qqueue id to change the timer
timertimer information
Returns
0 on success otherwise a negative error code
See also
snd_seq_get_queue_timer()

◆ snd_seq_set_queue_usage()

int snd_seq_set_queue_usage ( snd_seq_t * seq,
int q,
int used )

Set the queue usage flag to the client.

Parameters
seqsequencer handle
qqueue id
usednon-zero if the client is allowed
Returns
0 on success otherwise a negative error code
See also
snd_seq_get_queue_info(), snd_seq_set_queue_usage()

◆ snd_seq_set_ump_block_info()

int snd_seq_set_ump_block_info ( snd_seq_t * seq,
int blk,
const void * info )

Set UMP Block information to the current client.

Parameters
seqsequencer handle
blkUMP block number (0-based) to send
infothe pointer to send snd_ump_block_info_t data
Returns
0 on success otherwise a negative error code

◆ snd_seq_set_ump_endpoint_info()

int snd_seq_set_ump_endpoint_info ( snd_seq_t * seq,
const void * info )

Set UMP Endpoint information to the current client.

Parameters
seqsequencer handle
infothe pointer to send snd_ump_endpoint_info_t data
Returns
0 on success otherwise a negative error code

◆ snd_seq_subscribe_port()

int snd_seq_subscribe_port ( snd_seq_t * seq,
snd_seq_port_subscribe_t * sub )

subscribe a port connection

Parameters
seqsequencer handle
subsubscription information
Returns
0 on success otherwise a negative error code

Subscribes a connection between two ports. The subscription information is stored in sub argument.

See also
snd_seq_get_port_subscription(), snd_seq_unsubscribe_port(), snd_seq_connect_from(), snd_seq_connect_to()

◆ snd_seq_system_info()

int snd_seq_system_info ( snd_seq_t * seq,
snd_seq_system_info_t * info )

obtain the sequencer system information

Parameters
seqsequencer handle
infothe pointer to be stored
Returns
0 on success otherwise a negative error code

Stores the global system information of ALSA sequencer system. The returned data contains the maximum available numbers of queues, clients, ports and channels.

◆ snd_seq_system_info_copy()

void snd_seq_system_info_copy ( snd_seq_system_info_t * dst,
const snd_seq_system_info_t * src )

Copy one #snd_seq_system_info_t to another.

Parameters
dstpointer to destination
srcpointer to source

◆ snd_seq_system_info_free()

void snd_seq_system_info_free ( snd_seq_system_info_t * obj)

Frees a previously allocated #snd_seq_system_info_t.

Parameters
objpointer to object to free

◆ snd_seq_system_info_get_channels()

int snd_seq_system_info_get_channels ( const snd_seq_system_info_t * info)

Get maximum number of channels.

Parameters
info#snd_seq_system_info_t container
Returns
maximum number of channels
See also
snd_seq_system_info()

◆ snd_seq_system_info_get_clients()

int snd_seq_system_info_get_clients ( const snd_seq_system_info_t * info)

Get maximum number of clients.

Parameters
info#snd_seq_system_info_t container
Returns
maximum number of clients
See also
snd_seq_system_info()

◆ snd_seq_system_info_get_cur_clients()

int snd_seq_system_info_get_cur_clients ( const snd_seq_system_info_t * info)

Get the current number of clients.

Parameters
info#snd_seq_system_info_t container
Returns
current number of clients
See also
snd_seq_system_info()

◆ snd_seq_system_info_get_cur_queues()

int snd_seq_system_info_get_cur_queues ( const snd_seq_system_info_t * info)

Get the current number of queues.

Parameters
info#snd_seq_system_info_t container
Returns
current number of queues
See also
snd_seq_system_info()

◆ snd_seq_system_info_get_ports()

int snd_seq_system_info_get_ports ( const snd_seq_system_info_t * info)

Get maximum number of ports.

Parameters
info#snd_seq_system_info_t container
Returns
maximum number of ports
See also
snd_seq_system_info()

◆ snd_seq_system_info_get_queues()

int snd_seq_system_info_get_queues ( const snd_seq_system_info_t * info)

Get maximum number of queues.

Parameters
info#snd_seq_system_info_t container
Returns
maximum number of queues
See also
snd_seq_system_info()

◆ snd_seq_system_info_malloc()

int snd_seq_system_info_malloc ( snd_seq_system_info_t ** ptr)

Allocate an empty #snd_seq_system_info_t using standard malloc.

Parameters
ptrreturned pointer
Returns
0 on success otherwise negative error code

◆ snd_seq_system_info_sizeof()

size_t snd_seq_system_info_sizeof ( )

Get size of #snd_seq_system_info_t.

Returns
size in bytes

◆ snd_seq_type()

snd_seq_type_t snd_seq_type ( snd_seq_t * seq)

get type of sequencer handle

Parameters
seqsequencer handle
Returns
type of sequencer handle

Returns the type #snd_seq_type_t of the given sequencer handle.

See also
snd_seq_open()

◆ snd_seq_ump_event_input()

int snd_seq_ump_event_input ( snd_seq_t * seq,
snd_seq_ump_event_t ** ev )

retrieve a UMP event from sequencer

Parameters
seqsequencer handle
evUMP event pointer to be stored

Like snd_seq_event_input(), this reads out the input event, but in snd_seq_ump_event_t type instead of snd_seq_event_t type.

Calling this function is allowed only when the client is set to SND_SEQ_CLIENT_UMP_MIDI_1_0 or SND_SEQ_CLIENT_UMP_MIDI_2_0.

For other input operations, the same function like snd_seq_event_input_pending() or snd_seq_drop_input() can be still used.

See also
snd_seq_event_input()

◆ snd_seq_ump_event_output()

int snd_seq_ump_event_output ( snd_seq_t * seq,
snd_seq_ump_event_t * ev )

output a UMP event

Parameters
seqsequencer handle
evUMP event to be output
Returns
the number of remaining events or a negative error code

Just like snd_seq_event_output(), it puts an event onto the buffer, draining the buffer automatically when needed, but the event is snd_seq_ump_event_t type instead snd_seq_event_t.

Calling this function is allowed only when the client is set to SND_SEQ_CLIENT_UMP_MIDI_1_0 or SND_SEQ_CLIENT_UMP_MIDI_2_0.

The flushing and clearing of the buffer is done via the same functions, snd_seq_event_drain_output() and snd_seq_drop_output().

See also
snd_seq_event_output()

◆ snd_seq_ump_event_output_buffer()

int snd_seq_ump_event_output_buffer ( snd_seq_t * seq,
snd_seq_ump_event_t * ev )

output an event onto the lib buffer without draining buffer

Parameters
seqsequencer handle
evUMP event to be output
Returns
the byte size of remaining events. -EAGAIN if the buffer becomes full.

This is a UMP event version of snd_seq_event_output_buffer().

See also
snd_seq_event_output_buffer(), snd_seq_ump_event_output()

◆ snd_seq_ump_event_output_direct()

int snd_seq_ump_event_output_direct ( snd_seq_t * seq,
snd_seq_ump_event_t * ev )

output a UMP event directly to the sequencer NOT through output buffer

Parameters
seqsequencer handle
evUMP event to be output
Returns
the byte size sent to sequencer or a negative error code

This is a UMP event version of snd_seq_event_output_direct().

See also
snd_seq_event_output_direct()

◆ snd_seq_ump_extract_output()

int snd_seq_ump_extract_output ( snd_seq_t * seq,
snd_seq_ump_event_t ** ev_res )

extract the first UMP event in output buffer

Parameters
seqsequencer handle
ev_resUMP event pointer to be extracted
Returns
0 on success otherwise a negative error code

This is a UMP event version of snd_seq_extract_output().

See also
snd_seq_extract_output(), snd_seq_ump_event_output()

◆ snd_seq_unsubscribe_port()

int snd_seq_unsubscribe_port ( snd_seq_t * seq,
snd_seq_port_subscribe_t * sub )

unsubscribe a connection between ports

Parameters
seqsequencer handle
subsubscription information to disconnect
Returns
0 on success otherwise a negative error code

Unsubscribes a connection between two ports, described in sender and dest fields in sub argument.

See also
snd_seq_subscribe_port(), snd_seq_disconnect_from(), snd_seq_disconnect_to()