Sound library without any default delay

Hi I want to import a sound library so i can play different sound files. I have tried to import library already but there’s a default delay i want to get rid of so i just want to know if there is another library or way to minimize the default delay

This comes from the JSyn repo here (which the Sound library is built upon):

    public JavaSoundAudioDevice() {
        String osName = System.getProperty("os.name");
        if (osName.contains("Windows")) {
            suggestedOutputLatency = 0.08;
            logger.info("JSyn: default output latency set to "
                    + ((int) (suggestedOutputLatency * 1000)) + " msec for " + osName);
        }
        deviceRecords = new ArrayList<DeviceInfo>();
        sniffAvailableMixers();
        dumpAvailableMixers();
    }

Though it could be possible by making your own Audio class and extending the Sound class of the processing sound library, you will be forfeiting a lot of the behind the scenes connections these libraries are making for you. You could always try the minim sound library instead.

1 Like