bump.

On May 20, 11:58 am, Keith Wiley <kbwi...@gmail.com> wrote:
> I think I have a basic AudioRecord app working.  I say "I think"
> because it's all in the emulator and my desktop doesn't even have a
> mic plugged in, so my ability to test is severely limited until I get
> 1.5 on my G1 for hardware/mic testing), but I'm confused about
> AudioRecord's overall structure.
>
> As far as I can tell, one must explicitly poll for new audio data by
> calling read() on a regular basis, i.e., in some sort of loop or on a
> timer or something like that.  The two AudioRecord callback routines
> do get called, but only after I call read(), and only once per call to
> read(), so what purpose do they serve?
>
> When I have done audio programming like this on other platforms (Mac),
> a callback is registered and triggered on each audio hardware device
> interrupt (each time the hardware buffer is filled).  In such a case,
> a callback actually serves a useful purpose because my app doesn't
> have to explicitly poll for new data, but I just don't get it w.r.t.
> AudioRecord.
>
> What am I missing here?  What is the scenario to which the callbacks
> are applicable?  Is it my scenario, where I am processing audio on the
> data without saving it?  Is constantly polling with read() the wrong
> approach?  If so, how do I get the callbacks to trigger repeatedly?
>
> Thanks.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to