[pulseaudio-discuss] porting pulse audio to Android

2010-07-22 Thread priyanka sharma
I am working towards modying the android audio the stack so that it allows
multiple outputs, e.g. routing media player audio to a headset while playing
radio and nav instructions on the speakers.
We are working towards using Pulse Audio for to achieve this.
I need some help in understanding the amount of effort required to port
Pulse Audio to Android. Any help in this regard would be of great use to us.

best regards
Priyanka Sharma
___
pulseaudio-discuss mailing list
pulseaudio-discuss@mail.0pointer.de
https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss


Re: [pulseaudio-discuss] porting pulse audio to Android

2010-07-22 Thread Colin Guthrie
'Twas brillig, and priyanka sharma at 22/07/10 12:18 did gyre and gimble:
 I need some help in understanding the amount of effort required to port
 Pulse Audio to Android. Any help in this regard would be of great use to us.

As far as the compilation etc. it shouldn't be too hard, but from what I
understand the current reason PA is not on Android is purely from a
licensing perspective. I believe the only GPL'ish code that is permitted
as part of the official android stack is the kernel itself.

I believe even libasound is tricky (I think the original rationale was
to avoid confusion for 3rd party developers as to what code they had to
release into the open and what bits they can keep private - the clear
line of kernel patches need to be open, userspace does not).

But I presume license issues are not a concern for you in this context.

I guess then the problems would be with how android apps interact with
audio? I'm not sure how they actually do their output or input? I
believe there is a separate lib on andoird for this (I don't know the
details but others on this list do so can maybe advise better) but
perhaps it can be adapted to work with PA rather than plain alsa?

Hopefully someone can chip in with more details of how hard the porting
would be from a wider picture perspective.

Col

-- 

Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mandriva Linux Contributor [http://www.mandriva.com/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]
___
pulseaudio-discuss mailing list
pulseaudio-discuss@mail.0pointer.de
https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss


Re: [pulseaudio-discuss] porting pulse audio to Android

2010-07-22 Thread Mark Brown
On Thu, Jul 22, 2010 at 12:33:01PM +0100, Colin Guthrie wrote:
 'Twas brillig, and priyanka sharma at 22/07/10 12:18 did gyre and gimble:

  I need some help in understanding the amount of effort required to port
  Pulse Audio to Android. Any help in this regard would be of great use to us.

 As far as the compilation etc. it shouldn't be too hard, but from what I
 understand the current reason PA is not on Android is purely from a
 licensing perspective. I believe the only GPL'ish code that is permitted
 as part of the official android stack is the kernel itself.

Just to clarify, there's no problem with handset vendors including GPLed
code if they want to (barring any licensing conflcits with other
software on the device) - the concerns purely surround what is included
by default as part of the Android platform release.

 I guess then the problems would be with how android apps interact with
 audio? I'm not sure how they actually do their output or input? I
 believe there is a separate lib on andoird for this (I don't know the
 details but others on this list do so can maybe advise better) but
 perhaps it can be adapted to work with PA rather than plain alsa?

The high level architecture is this:

http://source.android.com/porting/audio.html

You'd end up tweaking an off the shelf ALSA libaudio to bounce via
Pulse, possibly bypassing the ALSA abstractions and talking directly to
Pulse for the data injection as well as using Pulse to configure any
soft routing it does.

 Hopefully someone can chip in with more details of how hard the porting
 would be from a wider picture perspective.

Should be fairly straightforward to get it working.
___
pulseaudio-discuss mailing list
pulseaudio-discuss@mail.0pointer.de
https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss


Re: [pulseaudio-discuss] Assert error in pulsecore/resampler.c:trivial_resample

2010-07-22 Thread Maarten Bosmans
2010/7/20 Tanu Kaskinen ta...@iki.fi:
 On Fri, 2010-07-16 at 23:22 +0200, Maarten Bosmans wrote:
 Hi,

 PulseAudio from git master crashes when I play a sound to a combined
 sink of two 96000 Hz sinks. It does not happen if the slave sinks are
 set to 48kHz. Playing directly two one of the slaves also works.

 [snip]

 Now, is it somehow possible that the rate difference is actually that
 huge? I don't think so, unless there's a bug in module-combine.

 Could you check with gdb what are the values of r-i_ss.rate and
 r-o_ss.rate when the crash happens?

No, that's not it, they're both the same, 96000. (Attached is a
snippet of gdb output, in which the structure r is printed)

The source file (input stream for combined sink) is 44100 Hz, the
slave sinks are at 96000 Hz.
I tried specifying the samplerate for the combined sink. The lower the
rate of the combined sink, the smaller the chance of the crash
happening. For a rate  4 it seems to never crash. For about
42000-43000 it sometimes crashes, mostly after more than 30 seconds of
audio. For 44000-45000 it usually crashes after 1-2 seconds and for
higher samplerates it crashes every time after just a fraction of a
second.

What I further noticed is that the resampler for the stream from the
combined sinks to the slave alsa sinks is always PA_RESAMPLER_TRIVIAL.
Is that correct, even for a stream from, say, 41000 to 96000? I would
think that for such a case something like PA_RESAMPLER_SPEEX_FLOAT
would be necessary.

 --
 Tanu Kaskinen


Thanks for thinking along in debugging this,

Maarten


gdb.log
Description: Binary data
___
pulseaudio-discuss mailing list
pulseaudio-discuss@mail.0pointer.de
https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss


[pulseaudio-discuss] pulseaudio debug mode

2010-07-22 Thread Chris
What is the best way to start PA for debugging and still have all the
usual clients running?

-- 
Chris
KeyID 0xE372A7DA98E6705C



signature.asc
Description: This is a digitally signed message part
___
pulseaudio-discuss mailing list
pulseaudio-discuss@mail.0pointer.de
https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss