* OSS API redirector
@ 2004-03-18 9:32 Jaroslav Kysela
2004-03-18 14:12 ` James Courtier-Dutton
0 siblings, 1 reply; 5+ messages in thread
From: Jaroslav Kysela @ 2004-03-18 9:32 UTC (permalink / raw)
To: ALSA development
Hi all,
I would like to point all developers to the OSS API redirector
which is in our alsa-oss package. It's universal piece of code which can
redirect all OSS API calls (actually mixer & PCM API only) to any shared
library.
Pros:
- no more LD_PRELOAD hacks
- any library can be used directly as endpoint
- when used more applications will work (also some which does not work
with LD_PRELOAD hack)
Drawbacks:
- still no fopen/fclose/fwrite/fread solution
- applications must be a little bit modified
Todo:
- OSS sequencer API redirector (it shouldn't be too difficult)
My original point is that we might persuade the binary only
providers (mostly games vendors) to use this small piece of code, because
there are no impacts regarding the application useability and the
maintaince overhead of this code is minimal.
The second goal is to use this redirector for all OSS applications
in Linux distributions to make the routing over ALSA library more easy.
Usage of this redirector for OSS API emulation in ALSA:
export OSS_REDIRECTOR=libalsatoss.so
And define appropriate pcm.dsp0 and pcm.mixer0 in ~/.asoundrc.
Jaroslav
-----
Jaroslav Kysela <perex@suse.cz>
Linux Kernel Sound Maintainer
ALSA Project, SuSE Labs
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: OSS API redirector
2004-03-18 9:32 OSS API redirector Jaroslav Kysela
@ 2004-03-18 14:12 ` James Courtier-Dutton
2004-03-18 21:37 ` David Lloyd
0 siblings, 1 reply; 5+ messages in thread
From: James Courtier-Dutton @ 2004-03-18 14:12 UTC (permalink / raw)
To: Jaroslav Kysela; +Cc: ALSA development
Jaroslav Kysela wrote:
> Hi all,
>
> I would like to point all developers to the OSS API redirector
> which is in our alsa-oss package. It's universal piece of code which can
> redirect all OSS API calls (actually mixer & PCM API only) to any shared
> library.
>
> Pros:
> - no more LD_PRELOAD hacks
> - any library can be used directly as endpoint
> - when used more applications will work (also some which does not work
> with LD_PRELOAD hack)
>
> Drawbacks:
> - still no fopen/fclose/fwrite/fread solution
> - applications must be a little bit modified
>
> -----
> Jaroslav Kysela <perex@suse.cz>
> Linux Kernel Sound Maintainer
> ALSA Project, SuSE Labs
>
What is the conclusion regarding fopen/fclose/fwrite/fread.
Can it be done?
Cheers
James
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: OSS API redirector
2004-03-18 14:12 ` James Courtier-Dutton
@ 2004-03-18 21:37 ` David Lloyd
2004-03-21 22:53 ` James Courtier-Dutton
0 siblings, 1 reply; 5+ messages in thread
From: David Lloyd @ 2004-03-18 21:37 UTC (permalink / raw)
To: James Courtier-Dutton; +Cc: Jaroslav Kysela, ALSA development
On Thu, 18 Mar 2004, James Courtier-Dutton wrote:
> What is the conclusion regarding fopen/fclose/fwrite/fread. Can it be
> done?
I thought that one rather pie-in-the-sky idea might be to use a kernel
module that made /dev/dsp, /dev/mixer, etc., and reflects back to a
userspace ALSA sound server via another device. This way, it doesn't
matter how the device is opened.
Might be difficult to do though, especially when you get mmap and
dma involved.
Just a thought, anyway.
- D
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: OSS API redirector
2004-03-18 21:37 ` David Lloyd
@ 2004-03-21 22:53 ` James Courtier-Dutton
2004-03-22 9:27 ` Jaroslav Kysela
0 siblings, 1 reply; 5+ messages in thread
From: James Courtier-Dutton @ 2004-03-21 22:53 UTC (permalink / raw)
To: David Lloyd; +Cc: Jaroslav Kysela, ALSA development
David Lloyd wrote:
> On Thu, 18 Mar 2004, James Courtier-Dutton wrote:
>
>
>>What is the conclusion regarding fopen/fclose/fwrite/fread. Can it be
>>done?
>
>
> I thought that one rather pie-in-the-sky idea might be to use a kernel
> module that made /dev/dsp, /dev/mixer, etc., and reflects back to a
> userspace ALSA sound server via another device. This way, it doesn't
> matter how the device is opened.
>
> Might be difficult to do though, especially when you get mmap and
> dma involved.
>
> Just a thought, anyway.
>
> - D
>
>
I thought of that, but with that you just get different problems.
E.g. dmix only works is all application wishing to play sound are run by
the same user. You would probably need some daemon to run the /dev/dsp,
and that user deamon would have to run under the same user as any native
alsa app.
Cheers
James
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: OSS API redirector
2004-03-21 22:53 ` James Courtier-Dutton
@ 2004-03-22 9:27 ` Jaroslav Kysela
0 siblings, 0 replies; 5+ messages in thread
From: Jaroslav Kysela @ 2004-03-22 9:27 UTC (permalink / raw)
To: James Courtier-Dutton; +Cc: David Lloyd, ALSA development
On Sun, 21 Mar 2004, James Courtier-Dutton wrote:
> I thought of that, but with that you just get different problems.
> E.g. dmix only works is all application wishing to play sound are run by
> the same user. You would probably need some daemon to run the /dev/dsp,
Nope. See the ipc_perm option (and we might enhance the permissions
setup in future).
Jaroslav
-----
Jaroslav Kysela <perex@suse.cz>
Linux Kernel Sound Maintainer
ALSA Project, SuSE Labs
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2004-03-22 9:33 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-03-18 9:32 OSS API redirector Jaroslav Kysela
2004-03-18 14:12 ` James Courtier-Dutton
2004-03-18 21:37 ` David Lloyd
2004-03-21 22:53 ` James Courtier-Dutton
2004-03-22 9:27 ` Jaroslav Kysela
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.