JDK-4794104 : mixers are always present, independent of available soundcards
  • Type: Bug
  • Component: client-libs
  • Sub-Component: javax.sound
  • Affected Version: 1.4.2
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2002-12-16
  • Updated: 2003-08-02
  • Resolved: 2003-08-02
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
5.0 tigerFixed
Related Reports
Relates :  

Name: dkR10031			Date: 12/16/2002

The J2SE 1.4 Java Sound implementation reports a most mixers independently 
of how many soundcards are available. The following test was run on linux 
box without soundcards:
import javax.sound.sampled.*;

public class MyMusic{
    public static void main(String args[]){
        Mixer.Info[] mixerInfo = AudioSystem.getMixerInfo();
        for(int i=0; i<mixerInfo.length; i++){
            System.out.println("Mixer #"+i+":"+mixerInfo[i]);
----------------------------------- Logs -------------------------------
Mixer #0:Java Sound Audio Engine, version 1.0
Mixer #1:Linux,dev/dsp,multi threaded, version Unknown Version

Linux box parameters:
---------------------------------- Logs --------------------------------
Linux linux-19 2.4.18-64GB-SMP #1 SMP Wed May 29 15:37:15 UTC 2002 i686 
linux-19 /tmp/1> /sbin/lsmod
Module                  Size  Used by    Not tainted
agpgart                30080   5 (autoclean)
autofs                  9572  12 (autoclean)
ipv6                  159616  -1 (autoclean)
isa-pnp                27580   0 (unused)
joydev                  5792   0 (unused)
evdev                   4032   0 (unused)
input                   3168   0 [joydev evdev]
usb-uhci               22020   0 (unused)
usbcore                56544   1 [usb-uhci]
3c59x                  25960   1
reiserfs              165408   0 (unused)

This behavior is ambiguos - if there is NO
soundcard installed, how can the implementation 
possibly report a format? 


CONVERTED DATA BugTraq+ Release Management Values COMMIT TO FIX: tiger FIXED IN: tiger INTEGRATED IN: tiger tiger-b14

EVALUATION ###@###.### 2002-12-16 Indeed Java Sound reports mixers, even if the corresponding hardware/drivers are not installed. One could argue that the existence of a mixer (i.e. the Java Sound Engine) is not wrong, even if no soundcard is installed. After all, the Java Sound Engine is a virtual device that includes mixing engine and software synthesizer. But, it should not report supported formats when there is no way to actually open the Java Sound Engine. The same applies to specific mixers e.g. the simple input device for recording: it should not be present if there is no soundcard available. For mantis on Linux, no supported formats are reported for non-existing soundcards. Committing to Tiger.

PUBLIC COMMENTS Java Sound reports invalid mixers