简体   繁体   中英

Java/Linux: sound output on wrong card

I have a java application that replays some PCM sound on my linux box. Unfortunately it uses the wrong soundcard.

I could direct xine by using the .asoundrc to the correct soundcard - but how can I tell the JVM which sound output to use by default?

Do you know how to list the "Mixers" that are available/visible? This JavaTutorial covers this topic.

http://docs.oracle.com/javase/tutorial/sound/accessing.html

If it is listed, you can have the Java application be written to select it. I don't know how to set a JVM sound card default though. That is probably more of an OS issue, is my guess. I'm thinking there is some spot in Linux that is being consulted by the JVM.

I hope this is at least somewhat helpful. Good luck!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM