On 2009/11/02 13:57, kernel error <k3rn3l.3r...@gmail.com> wrote:
> Technically, SNDNEED = SNDBUF/(channels*(bits/8)), i assume that mean the
> number of instructions to execute ? but I'm really not sure, I take
> xmms-plugin as an example and I confess I don't understood completly
> his working.

If you copy'n'paste code from another module, you have to write that
in a comment.  And, please do not submit code you do not understand
(yet).

It looks like the code tries to fill the buffer completely, even if an
input frame is smaller than the buffer.  MPD can handle partial
buffers fine, in fact, MPD does not even regulate the buffer size -
submit any non-empty decoded buffer to decoder_data(), as much as you
have at any given time.

I guess the whole loop can be eliminated, replaced with a single
ayemu_vtx_getframe() / ayemu_set_regs() / ayemu_gen_sound() call.

Oh, and please check your variable types.  e.g. don't use signed
integers for counting stuff (bytes, frames, ...).

Max

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Musicpd-dev-team mailing list
Musicpd-dev-team@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/musicpd-dev-team

Reply via email to