Java with alsa instead of pulseaudio


#1

I am trying to get working java based music server (Airsonic) with alsa local aoutput. Unfortunately I can’t figure it out. Some help will be highly appreciated.

Thanks!


#2

#3

Okay, i have figured it out, but now i have problem with all file formats (aiff, alac, wma, wav …) which are different from FLAC. No sound!
Only plughw ( Hardware device with all software conversions) is available/detected from java btw

output for aiff for example is:
Exception in thread “com.github.biconou.AudioPlayer.JavaPlayer.Tplayer” java.lang.RuntimeException: javax.sound.sampled.UnsupportedAudioFileException
at com.github.biconou.AudioPlayer.JavaPlayer.lambda$play$4(JavaPlayer.java:309)
at java.lang.Thread.run(Thread.java:748)
Caused by: javax.sound.sampled.UnsupportedAudioFileException
at com.github.biconou.AudioPlayer.JavaPlayer.getAudioInputStream(JavaPlayer.java:194)
at com.github.biconou.AudioPlayer.JavaPlayer.getCurrentStreamFromPlayList(JavaPlayer.java:453)
at com.github.biconou.AudioPlayer.JavaPlayer.lambda$play$4(JavaPlayer.java:307)