|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectJavaMusic
public class JavaMusic
A class with wrapper methods for JavaMusic (specifically playNote)
Constructor Summary | |
---|---|
JavaMusic()
|
Method Summary | |
---|---|
static void |
cleanUp()
Obtains the MIDI channel to use from the default synthesizer. |
static void |
close()
Closes the default synthesizer. |
static javax.sound.midi.MidiChannel |
getChannel()
Returns the MIDI channel to use from the default synthesizer. |
static void |
main(java.lang.String[] argv)
|
static void |
open()
Obtains the MIDI channel to use from the default synthesizer. |
static void |
playNote(int note,
int duration)
Plays a note with the passed note, duration, and the default intensity (64). |
static void |
playNote(int note,
int duration,
int intensity)
Plays a note with the passed note, duration, and intensity. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JavaMusic()
Method Detail |
---|
public static void open()
public static void close()
public static void cleanUp()
public static javax.sound.midi.MidiChannel getChannel()
public static void playNote(int note, int duration, int intensity)
note
- the note (a number > 0) you want to be played.duration
- the duration you want the note to be played in milliseconds.intensity
- the intensity (a number between 0 and 127) you want the note to be played.public static void playNote(int note, int duration)
note
- the note (a number > 0) you want to be played.duration
- the duration you want the note to be played in milliseconds.public static void main(java.lang.String[] argv)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |