[Alsa-user] ALSA and JavaSound

2008-11-17 Thread Lars Schnoor
Hi everyone I am using JavaSound on Linux where it as a default uses ALSA. I tried to figure out how to configure ALSA with respect to JavaSound, but couldn't find anything. I read that ALSA can, if the sound card hardware does not support it, do mixing in software. How can I configure ALSA for

Re: [Alsa-user] ALSA and JavaSound

2008-11-17 Thread Joshua Smith
For the most compatibility, I would recommend that you tell Java to use its own software headspace mixer: Mixer.Info [] mixerInfo = AudioSystem.getMixerInfo(); Mixer.Info useMixer = null; for (int i=0;imixerInfo.length;++i) if

Re: [Alsa-user] ALSA and JavaSound

2008-11-17 Thread Lars Schnoor
Hi Joshua Thank you for your reply, but I tried Javas software mixer and it gives me extremely poor performance. I am working on an voice application and the latency of Javas software mixer is just unbearable. Wouldn't starting Java with aoss cause it to use OSS instead of ALSA, is that really

Re: [Alsa-user] ALSA and JavaSound

2008-11-17 Thread Joshua Smith
The poor performance is because its a software mixer, not because it's Java. It totally sucks compared with hardware mixing, but I'd be very surprised if an ALSA software mixer gave any different performance. I have to profess ignorance about exactly what AOSS does. All I know is that

Re: [Alsa-user] ALSA and JavaSound

2008-11-17 Thread Lars Schnoor
Hi Joshua When I run my application on Windows it uses DirectSound and DirectSound does software mixing as well, but is,even with its poor performance, considerably faster than Java software mixing. So I assumed that ALSA would perform better than Java software mixing. I have to admit that I am

Re: [Alsa-user] ALSA and JavaSound

2008-11-17 Thread klondike
First of all bear in mind that by some strange reason, Sun's Java doesn't use the default card with alsa but hw:0,0, that's why you must use aoss son java uses oss and interfaces with the alsa card. Os course, that isn't much of a problem if you use openJDK Also you should bear in mind that AFAIK

Re: [Alsa-user] ALSA and JavaSound

2008-11-17 Thread Lars Schnoor
I thought I had read something about hardware mixing for the M-Audio Delta card. Would you have an example of how to activate mixing with dmix so that Java Sound accepts it? Lars Jaroslav Kysela wrote: On Mon, 17 Nov 2008, Lars Schnoor wrote: I have to admit that I am a bit surprised

Re: [Alsa-user] ALSA and JavaSound

2008-11-17 Thread Lars Schnoor
Java allows for multiple sound cards to be used. If I install multiple sound cards I can in Java Sound select which one I want to use for input and output. Java Sound on Linux does also allow for sound cards with multiple inputs and outputs. I have a M-Audio Delta 1010LT installed with 8

Re: [Alsa-user] ALSA and JavaSound

2008-11-17 Thread Joshua Smith
http://www.razorsedge.org/~mike/docs/asoundrc.html Perhaps? On Nov 17, 2008, at 5:17 PM, Lars Schnoor wrote: I thought I had read something about hardware mixing for the M-Audio Delta card. Would you have an example of how to activate mixing with dmix so that Java Sound accepts it? Lars