Examples of unloadAllInstruments()


Examples of com.sun.media.sound.AudioSynthesizer.unloadAllInstruments()

    public static void test(Soundbank soundbank) throws Exception {

        // Create instance of synthesizer using the testing soundbank above
        AudioSynthesizer synth = new SoftSynthesizer();
        AudioInputStream stream = synth.openStream(format, null);
        synth.unloadAllInstruments(synth.getDefaultSoundbank());
        synth.loadAllInstruments(soundbank);
        Receiver recv = synth.getReceiver();

        // Set volume to max and turn reverb off
        ShortMessage reverb_off = new ShortMessage();
View Full Code Here

Examples of com.sun.media.sound.AudioSynthesizer.unloadAllInstruments()

        SF2InstrumentRegion insregion = new SF2InstrumentRegion();
        insregion.setLayer(layer);
        ins.getRegions().add(insregion);

        // Load the test soundbank into the synthesizer
        synth.unloadAllInstruments(synth.getDefaultSoundbank());
        synth.loadAllInstruments(sf2);
       
        // Send out one midi on message
        MidiChannel ch1 = synth.getChannels()[0];
        ch1.programChange(0);
View Full Code Here

Examples of com.sun.media.sound.SoftSynthesizer.unloadAllInstruments()

    public static void test(Soundbank soundbank) throws Exception {

        // Create instance of synthesizer using the testing soundbank above
        AudioSynthesizer synth = new SoftSynthesizer();
        AudioInputStream stream = synth.openStream(format, null);
        synth.unloadAllInstruments(synth.getDefaultSoundbank());
        synth.loadAllInstruments(soundbank);
        Receiver recv = synth.getReceiver();

        // Set volume to max and turn reverb off
        ShortMessage reverb_off = new ShortMessage();
View Full Code Here

Examples of com.sun.media.sound.SoftSynthesizer.unloadAllInstruments()

        SF2InstrumentRegion insregion = new SF2InstrumentRegion();
        insregion.setLayer(layer);
        ins.getRegions().add(insregion);

        // Load the test soundbank into the synthesizer
        synth.unloadAllInstruments(synth.getDefaultSoundbank());
        synth.loadAllInstruments(sf2);
       
        // Send out one midi on message
        MidiChannel ch1 = synth.getChannels()[0];
        ch1.programChange(0);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.