speechd-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[orca-list] Pulseaudio and speech-dispatcher/gnome-speech in Ubuntu.


From: Hynek Hanke
Subject: [orca-list] Pulseaudio and speech-dispatcher/gnome-speech in Ubuntu.
Date: Wed, 16 Apr 2008 17:27:16 +0200

Hello Luke,

we have tried to analyze and test the thing and we believe
the setup that eliminates all the problems would be as described
here (a rationale follows):

1) Speech Dispatcher is setup to use PulseAudio under all circumstances.

2) General-use Speech Dispatcher (for use outside gnome-session)
is being launched from /etc/init.d/speech-dispatcher with default="yes"
under user speech_dispatcher together with its own pulse audio
daemon running under the same user (speech_dispatcher).

3) Under gnome-session, each user is supposed to run its own
instance of Speech Dispatcher. /usr/bin/speech-dispatcher is
a wrapper script that if not executed by 'speech_dispatcher' or 'root'
will check for the presence of ~/.speech-dispatcher and if it wont
find the directory, it will create the necessary structure, copy the
configuration from /etc/speech-dispatcher/, modifies the default
port number from 6560 to 6561 and sets the environment
variable SPEECHD_PORT to this value.

Rationale:
1) There will be no conflicts between (2) and (3). There can be
multiple Pulse Audio daemons running on a system under different
users and they don't prevent each other from launching and speaking.
The only thing that is not possible is to mix two simultanous streams
between these two instances of Pulse Audio. This is not a problem.
The assistive technologies working inside gnome-session will use
the user instance of Speech Dispatcher (3) and assistive technologies
outside gnome-session will use system wide Speech Dispatcher (2). Outside
gnome-session work BrlTTY, Speakup, Yasr, GDM Login etc. The user
either is in X or is not, so there is no need for mixing.

2) The wrapper script makes sure that the user is not forced to do
extensive configuration before hearing the very first piece of speech
from Speech Dispatcher after its instalation. We are now doing it
because we were forced by Pulse Audio, but it will be a general
simplification and I think a good improvement.

3) There is no chance that we would break something other
than Speech Dispatcher doing these late-time changes, since all these
changes will be made in the Speech Dispatcher package and thus only
users installing this package will be affected by possible catastrophes :)
And even for them, there is very little chance that it would actually
work worse than the current solution.

Please try to think about it and ask any questions you have. The only
work that needs to be done is to

1) Modify the Speech Dispatcher init script to launch an instance of 
PulseAudio.
2) Create the mentioned wrapper script.

Please, would you be able to do these changes or do you need
our help? We are really interested in making it work in Hardy.
When there will be a testing package, we will be very happy
to try it out and confirm there are no issues.

> Ok, things wouldn't work outside of a gnome session. However, Ubuntu's BrlTTY 
> package is not built against speech-dispatcher,
> since speech-dispatcher is in a different part of the Ubuntu archive, and the 
> packages in the archive where BrlTTY sits now,
> can not be built against packages where speech-dispatcher sits. 
Ok, this is a problem for later. But it is not really and argument, 
because users
can compile it themselves with Speech Dispatcher support in an easy way
and of course it is important whether the result will work or not. We 
have several
users using it here this way on Ubuntu and we believe that especially BrlTTY
is important.
> As stated, BrlTTY doesn't have speech-dispatcher support, and Ubuntu hardy 
> doesn't have speakup. 
Why not? What is the user supposed to do then, if something
in Gnome breaks? It is not that because Ubuntu doesn't have
a package, the users don't need it anymore.

> As for turning off pulseaudio, other applications generally auto-detect the 
> best output to use, or, if pulse doesn't work, they fall back to using Alsa.
>   
That's nice. I'll look into doing the same in Speech Dispatcher.
(That would however not solve the current problem.)

> As I think I've stated, things were done in such a way, because from reading 
> the user posts on this list and other lists, users appeared to be happy to 
> configure speech-dispatcher to suit their needs. 
>   
Ok, I understand that. I suspect however that this is more out of need than
because they would be happy with it.
> No of course they can't, but I am thinking of what is most commonly 
> used. I haven't heard of users using yasr/speechd-el on Ubuntu, and if 
> there are, and they think things could have been done better, it would 
> have been nice to hear from them to set things right. Same with 
> speakup, and for people who may have rebuilt BrlTTY.
I've heard of quite a few:) But frankly, I don't know whether they use 
Speech
Dispatcher becaus*e they like it. It just is more or less the only 
option outside
of Gnome now.
>> Put it this way. If I was to do it the way you suggest, I wouldn't be 
>> popular with my fellow developers, and it would make things even more messy. 
>> Since pulseaudio uses the sound device directly, i.e not through dmix, this 
>> would totally prevent users running pulseaudio as a user, unless they had 
>> another, unused sound card.
>>     
No, this is not correct. Luckily it is possible to run multiple PulseAudio
daemons on the same single-channel soundcard without dmix -- thats the idea.
The only thing that is not possible is to use it to mix various sound
streams comming from various users, which is -- again luckily -- not
a real problem for us.

On a related topic: We are working on improvements to the PulseAudio
output module for Speech Dispatcher which should significantly enhance
its performance. Our tests from today seem to be very encouraging.

Please let me know.

With regards,
Hynek Hanke





reply via email to

[Prev in Thread] Current Thread [Next in Thread]