![]() |
The Java Developers Almanac 1.4Order this book from Amazon. |
e718. Determining the File Format of a Midi Audio Filetry { // From file MidiFileFormat fformat = MidiSystem.getMidiFileFormat(new File("midifile")); // From URL fformat = MidiSystem.getMidiFileFormat(new URL("http://hostname/midifile")); // Get file format switch (fformat.getType()) { case 0: // mid break; case 1: // rmf break; } } catch (MalformedURLException e) { } catch (IOException e) { } catch (InvalidMidiDataException e) { // File format is not supported. }
e720. Determining the Position of a Midi Sequencer e721. Setting the Volume of Playing Midi Audio
© 2002 Addison-Wesley. |