Re: [LAD] Deciphering jack-smf-utils -- Jack MIDI stuff

From: M Donalies <ingeniousnebbish@email-addr-hidden>
Date: Mon Feb 18 2013 - 16:35:08 EET

On Monday 18 February 2013 08:33:16 Paul Davis wrote:
> On Mon, Feb 18, 2013 at 8:35 AM, M Donalies <ingeniousnebbish@email-addr-hiddenwrote:
> > On Sunday 17 February 2013 08:21:51 Paul Coccoli wrote:
> > > On Sat, Feb 16, 2013 at 10:33 PM, M Donalies <ingeniousnebbish@email-addr-hidden>
> >
> > wrote:
> > > > process_callback() calls process_midi_output(), wherein we find:
> > > > port_buffer = jack_port_get_buffer(output_port, nframes);
> > > >
> > > > Why the nframes parameter? Is there a separate buffer area for each
> > > > frame?
> > >
> > > There's a separate buffer for each port.
> >
> > Yes, and that's the output_port arg, but what's with nframes? Why isn't
> > the function simply: jack_port_get_buffer(output_port) ?
>
> because the client may not want to get all the data at once.
>
> ardour, for example, breaks up the process() cycle internally to deal with
> "global" scheduled events. so it may ask for the first N frames, then
> another M, then another P frames until everything is done.

Oh, I see. process_callback() is called once every N frames, where N depends
upon user settings for latency, etc. I was mistakenly reading it as a callback
each frame.

-- 
7:8
_______________________________________________
Linux-audio-dev mailing list
Linux-audio-dev@email-addr-hidden
http://lists.linuxaudio.org/listinfo/linux-audio-dev
Received on Mon Feb 18 16:15:03 2013

This archive was generated by hypermail 2.1.8 : Mon Feb 18 2013 - 16:15:04 EET