-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Some refactoring in package `mpmToolbox.gui.syncPlayer`. - The SyncPlayer's MIDI output can now be streamed to any other MIDI port available on the host system. Thus, users are no longer limited to the internal Gervill synthesizer and the soundbank loaded into it.
- Loading branch information
1 parent
2b5b9c4
commit a57a761
Showing
8 changed files
with
179 additions
and
113 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
package mpmToolbox.gui.syncPlayer; | ||
|
||
import com.alee.api.annotations.NotNull; | ||
import meico.audio.Audio; | ||
import meico.supplementary.KeyValue; | ||
|
||
/** | ||
* This class represents an item in the audio chooser combobox of the SyncPlayer. | ||
* @author Axel Berndt | ||
*/ | ||
class AudioChooserItem extends KeyValue<String, Audio> { | ||
/** | ||
* This constructor creates a audio chooser item (String, Audio) pair out of a non-null audio object. | ||
* @param audio | ||
*/ | ||
public AudioChooserItem(@NotNull Audio audio) { | ||
super(audio.getFile().getName(), audio); | ||
} | ||
|
||
/** | ||
* This constructor creates a audio chooser item with the specified name key but null audio object. | ||
* Basically, this is used to communicate to the SyncPlayer not to play audio. | ||
* The string is typically something like "No audio recording". | ||
* @param string | ||
*/ | ||
public AudioChooserItem(String string) { | ||
super(string, null); | ||
} | ||
|
||
/** | ||
* All combobox items require this method. The overwrite here makes sure that the string being returned | ||
* is the audio file's name instead of some Java Object ID. | ||
* @return | ||
*/ | ||
@Override | ||
public String toString() { | ||
return this.getKey(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
package mpmToolbox.gui.syncPlayer; | ||
|
||
import com.alee.api.annotations.NotNull; | ||
import meico.mpm.elements.Performance; | ||
import meico.supplementary.KeyValue; | ||
|
||
/** | ||
* This class represents an item in the performance chooser combobox of the SyncPlayer. | ||
* @author Axel Berndt | ||
*/ | ||
class PerformanceChooserItem extends KeyValue<String, Performance> { | ||
/** | ||
* This constructor creates a performance chooser item (String, Performance) pair out of a non-null performance. | ||
* @param performance | ||
*/ | ||
public PerformanceChooserItem(@NotNull Performance performance) { | ||
super(performance.getName(), performance); | ||
} | ||
|
||
/** | ||
* This constructor creates a performance chooser item with the specified name key but null performance. | ||
* Basically, this is used to communicate to the SyncPlayer not to play a performance rendering. | ||
* The string is typically something like "No performance rendering". | ||
* @param string | ||
*/ | ||
public PerformanceChooserItem(String string) { | ||
super(string, null); | ||
} | ||
|
||
/** | ||
* All combobox items require this method. The overwrite here makes sure that the string being returned | ||
* is the performance's name instead of some Java Object ID. | ||
* @return | ||
*/ | ||
@Override | ||
public String toString() { | ||
return this.getKey(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
package mpmToolbox.gui.syncPlayer; | ||
|
||
import com.alee.api.annotations.NotNull; | ||
import meico.supplementary.KeyValue; | ||
|
||
import java.io.File; | ||
|
||
/** | ||
* This class represents an item in the soundfont chooser combobox of the SyncPlayer. | ||
* @author Axel Berndt | ||
*/ | ||
class SoundfontChooserItem extends KeyValue<String, File> { | ||
/** | ||
* This constructor creates a soundfont chooser item (String, File) pair out of a non-null file. | ||
* @param soundfont | ||
*/ | ||
public SoundfontChooserItem(@NotNull File soundfont) { | ||
super(soundfont.getName(), soundfont); | ||
} | ||
|
||
/** | ||
* This constructor creates a soundfont chooser item with the specified name key but null soundfont. | ||
* Basically, this is used to communicate to the SyncPlayer to use the default soundfont. | ||
* @param string | ||
*/ | ||
public SoundfontChooserItem(String string) { | ||
super(string, null); | ||
} | ||
|
||
/** | ||
* All combobox items require this method. The overwrite here makes sure that the string being returned | ||
* is the file name instead of some Java Object ID. | ||
* @return | ||
*/ | ||
@Override | ||
public String toString() { | ||
return this.getKey(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters