Thanks very much Clemens.
I saw this function in the API, but from from the name and signature, snd_seq_ev_set_queue_pos_tick(ev,q,ttime), I thought it was a method for a single event rather for the whole queue. Could you explain what the ev argument is for and what I need to put in it; and also why its called snd_seq_ev_set_queue_pos_tick rather than snd_seq_queue_set_pos_tick ?
(I can see in the API docs this text, which I think tells what I need to put in ev, but I don't understand why this is needed, why's it not just snd_seq_queue_set_pos_tick(q,ttime) ? I saw this function in the API, but from from the name and signature, snd_seq_ev_set_queue_pos_tick(ev,q,ttime), I thought it was a method for a single event rather for the whole queue. Could you explain what the ev argument is for and what I need to put in it; and also why its called snd_seq_ev_set_queue_pos_tick rather than snd_seq_queue_set_pos_tick ?
((ev)->type = SND_SEQ_EVENT_SETPOS_TICK,\
(ev)->data.queue.queue = (q),\
(ev)->data.queue.param.time.tick = (ttime))
)
thanks
charles
On Mon, Apr 4, 2016 at 9:12 AM, Clemens Ladisch <cladisch@xxxxxxxxxxxxxx> wrote:
Charles Fox wrote:
> The midiarp.c demo in the tutorial shows how to read the tick state,
> and how to get and set the tempo. So I was expecting to find
> a function called something like snd_seq_queue_set_tick , but there
> doesn't seem to be one in the API.
To set a queue's timer's position, send a message SND_SEQ_EVENT_SETPOS_TICK
and/or SND_SEQ_EVENT_SETPOS_TIME to the global timer port.
There are macros snd_seq_ev_set_queue_pos_tick() and
snd_seq_ev_set_queue_pos_real() to help you construct such messages.
Regards,
Clemens
------------------------------------------------------------------------------
_______________________________________________ Alsa-user mailing list Alsa-user@xxxxxxxxxxxxxxxxxxxxx https://lists.sourceforge.net/lists/listinfo/alsa-user