From 1e06fcb34d222ef2017d4adf888568184dd63ab9 Mon Sep 17 00:00:00 2001 From: Michael Andreen Date: Thu, 3 Apr 2003 10:06:12 +0000 Subject: [PATCH] initial commit --- MooGUI.java | 25 +++++++++++ MooMenu.java | 25 +++++++++++ MooNote.java | 84 +++++++++++++++++++++++++++++++++++ MooNoteElement.java | 25 +++++++++++ MooSequence.java | 68 ++++++++++++++++++++++++++++ MooStatus.java | 25 +++++++++++ MooToolbar.java | 25 +++++++++++ MooTrack.java | 106 ++++++++++++++++++++++++++++++++++++++++++++ MooTrackTitle.java | 25 +++++++++++ MooTrackView.java | 25 +++++++++++ MooView.java | 25 +++++++++++ MooViewCounter.java | 25 +++++++++++ Moosique.java | 101 +++++++++++++++++++++++++++++++++++++++++ 13 files changed, 584 insertions(+) create mode 100644 MooGUI.java create mode 100644 MooMenu.java create mode 100644 MooNote.java create mode 100644 MooNoteElement.java create mode 100644 MooSequence.java create mode 100644 MooStatus.java create mode 100644 MooToolbar.java create mode 100644 MooTrack.java create mode 100644 MooTrackTitle.java create mode 100644 MooTrackView.java create mode 100644 MooView.java create mode 100644 MooViewCounter.java create mode 100644 Moosique.java diff --git a/MooGUI.java b/MooGUI.java new file mode 100644 index 0000000..22ccb53 --- /dev/null +++ b/MooGUI.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * Moosique's graphical user interface. + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooGUI { + + /** + * Creates the GUI. + */ + public MooGUI () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/MooMenu.java b/MooMenu.java new file mode 100644 index 0000000..2d5c20a --- /dev/null +++ b/MooMenu.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooMenu { + + /** + * Creates the menus. + */ + public MooMenu () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/MooNote.java b/MooNote.java new file mode 100644 index 0000000..edd8159 --- /dev/null +++ b/MooNote.java @@ -0,0 +1,84 @@ +import javax.sound.midi.*; + +/** + * Functional representation of a MIDI note, which contains two MIDI events, note on and note off. + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooNote { + + private MidiEvent noteOn, noteOff; + + /** + * Creates a MooNote of the given pitch, velocity and length in the current track. + */ + public MooNote (int pitch, int velocity, int length) { + + } + + /** + * Sets the pitch of the current note. + + @param pitch the pitch of the note (0-127) + */ + public void setPitch(int pitch) { + + } + + /** + * Sets the velocity of the current note. + + @param vel the velocity of the note (0-127) + */ + public void setVelocity(int vel) { + + } + + /** + * Sets the length of the current note (or rather moves the note off event). + + @param n the length of the note in ticks (100 per beat) + */ + public void setLength(int ticks) { + + } + + /** + * Returns the note on event of the current note. + * @return the note on MidiEvent + */ + public MidiEvent getNoteOnEvent() { + + } + + /** + * Returns the note off event of the current note. + * @return the note off MidiEvent + */ + public MidiEvent getNoteOffEvent() { + + } + + /** + * Returns the pitch of the current note. + * @return the pitch of the note + */ + public int getPitch() { + + } + + /** + * Returns the velocity of the current note. + * @return the velocity of the note + */ + public int getVelocity() { + + } + + /** + * Returns the length of the current note. + * @return the length of the note + */ + public int getLength() { + + } +} diff --git a/MooNoteElement.java b/MooNoteElement.java new file mode 100644 index 0000000..60f153a --- /dev/null +++ b/MooNoteElement.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * Graphical representation of a MIDI note. + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooNoteElement { + + /** + * Creates a new note element. + */ + public MooNoteElement () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/MooSequence.java b/MooSequence.java new file mode 100644 index 0000000..a92ca10 --- /dev/null +++ b/MooSequence.java @@ -0,0 +1,68 @@ +import javax.sound.midi.*; + +/** + * Functional representation of a MIDI sequence. + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooSequence { + + private Collection tracks; + + /** + * Creates a MooSequence with three tracks. + */ + public MooSequence () { + + } + + /** + * Returns a pointer to the specified track. + * @param track the number of the track (0-31) + * @return the specified track + */ + public MooTrack getTrack(int track) { + + } + + /** + * Returns the number of tracks in the current sequence. + * @return the number of the tracks + */ + public int getNumberOfTracks() { + + } + + /** + * Creates a new track after the specified track. + * @param track the number of the track (0-31) + */ + public void addTrack(int track) { + + } + + /** + * Deletes the specified track. + * @param track the number of the track (0-31) + */ + public void deleteTrack(int track) { + + } + + /** + * Returns the Java Sequence object of the current sequence. + * @return a Sequence + */ + public Sequence getSequence() { + + } + + /** + * Resets the solo and mute settings of all tracks. + */ + public void activateTracks() { + + } +} diff --git a/MooStatus.java b/MooStatus.java new file mode 100644 index 0000000..101dd72 --- /dev/null +++ b/MooStatus.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooStatus { + + /** + * Creates the status bar. + */ + public MooStatus () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/MooToolbar.java b/MooToolbar.java new file mode 100644 index 0000000..887fd8e --- /dev/null +++ b/MooToolbar.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class Moo { + + /** + * Creates the toolbar. + */ + public MooToolbar () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/MooTrack.java b/MooTrack.java new file mode 100644 index 0000000..f9d51f3 --- /dev/null +++ b/MooTrack.java @@ -0,0 +1,106 @@ +import javax.sound.midi.*; + +/** + * Functional representation of a MIDI track. + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooTrack { + + private Collection notes; + private int channel; + private int instrument; + private boolean solo; + private boolean mute; + + + /** + * Creates an empty MooTrack. + */ + public MooTrack () { + + } + + /** + * Sets the MIDI channel of the current track. + * @param chan the number of the MIDI channel (1-16) + */ + public void setChannel(int chan) { + + } + + /** + * Sets the MIDI instrument of the current track. + * @param instr the number of the MIDI instrument (0-127) + */ + public void setInstrument(int instr) { + + } + + /** + * Returns the number of notes in the current track. + * @return the number of notes + */ + public void getNumberOfNotes() { + + } + + /** + * Adds the given note to the current track. + * @param note the MooNote to add + */ + public void addNote(MooNote note) { + + } + + /** + * Deletes the given note to the current track. + * @param note the MooNote to delete + */ + public void deleteNote(MooNote note) { + + } + + /** + * Returns the note of the given index. + * @param note the index of the note + */ + public MooNote getNote(int note) { + + } + + /** + * Makes the current track solo. + * @param set if the track should be solo + */ + public void solo(boolean set) { + + } + + /** + * Mutes the current track. + * @param set if the track should be muted + */ + public void mute(boolean set) { + + } + + /** + * Checks if the current track is solo. + * @return if the track is solo + */ + + public boolean isSolo() { + + } + + /** + * Checks if the current track is muted. + * @return if the track is muted + */ + public boolean isMute() { + + } +} diff --git a/MooTrackTitle.java b/MooTrackTitle.java new file mode 100644 index 0000000..3090852 --- /dev/null +++ b/MooTrackTitle.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * The title bar for each track with track name, channel, instrument etc. + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooTrackTitle { + + /** + * Creates the title bar. + */ + public MooTrackTitle () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/MooTrackView.java b/MooTrackView.java new file mode 100644 index 0000000..83ef2f5 --- /dev/null +++ b/MooTrackView.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooTrackView { + + /** + * Creates + */ + public MooTrackView () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/MooView.java b/MooView.java new file mode 100644 index 0000000..c5cc49d --- /dev/null +++ b/MooView.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooView { + + /** + * Creates + */ + public MooView () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/MooViewCounter.java b/MooViewCounter.java new file mode 100644 index 0000000..45a9280 --- /dev/null +++ b/MooViewCounter.java @@ -0,0 +1,25 @@ +import javax.swing.*; + +/** + * + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class MooViewCounter { + + /** + * Creates + */ + public MooViewCounter () { + + } + + /** + * + */ + public void () { + + } +} diff --git a/Moosique.java b/Moosique.java new file mode 100644 index 0000000..720d0c8 --- /dev/null +++ b/Moosique.java @@ -0,0 +1,101 @@ +import javax.sound.midi.*; +import java.io.*; + +/** + * Moosique - The trackers approach to MIDI + * + * Main class that handles initiation, IO and sound FX. + * + * @author Andersson, Andreen, Lanneskog, Pehrson + * @version 1 + */ + +public class Moosique { + + private static MooGUI gui; + private static MooSequence seq; + private static String filename; + + /** + * Runs the application. + */ + public static void main (String[] args) { + + } + + /** + * Returns a pointer to the current sequence. + * @return the current sequence + */ + public static MooSequence getSequence() { + + } + + /** + * Starts playback of the current sequence. + */ + public static void play() { + + } + + /** + * Pauses playback of the current sequence. + */ + public static void pause() { + + } + + /** + * Stops playback of the current sequence. + */ + public static void stop() { + + } + + /** + * Rewinds the current sequence the given number of measures. + * @param measures the number of measures to rewind + */ + public static void rewind(int measures) { + + } + + /** + * Fast forwards the current sequence the given number of measures. + * @param measures the number of measures to fast forward + */ + public static void forward(int measures) { + + } + + /** + * Loads the MooSequence in the given file. + * @param filename the filename to use + */ + public static void load(String filename) throws IOException { + + } + + /** + * Saves the current sequence to the given filename + * @param filename the filename to use + */ + public static void saveAs(String filename) throws IOException { + + } + + /** + * Saves the current sequence to the previously given filename. + */ + public static void save() throws IOException { + + } + + /** + * Exports the current sequence to a standard MIDI file. + * @param filename the filename to use + */ + public static void exportMIDI(String filename) throws IOException { + + } +} -- 2.39.2