Maestro Conceptual Views
Two Main Modes for Playing Music
- In Green on the schema: play music from a MIDI file with full interaction with your application (MidiFilePlayer, MPTKWriter, MidiExternalPlay, MidiInReader MidiListPlayer, MidiSpatializer).
- In Orange on the schema: create and play your music at run-time in your application (MidiStreamPlayer, MidiKeyboard, MPTKChordBuilder, MPTKChordLib, MPTKRangeLib). Typically, music is created in your Update() method.
Simplified view:
Detailed view:
These two modes Green and Orange can be combined in any way around the central MPTKEvent class, which describes a MIDI event.
Maestro Unity Prefabs & Classes
Three Prefabs are available with the Free version
- MidiFilePlayer:
- Play music from a MIDI file, fully controlling the speed, position, quantization, channel, instrument, effect, and loop. Navigate to a specific position as needed.
- It is not necessary to write a C# script for playing music playback.
- The easier and quick way to add music to your app.
- Obviously you don’t need to be a musician, there is a lot of MIDI files available on internet, often for free.
- The Integrated Maestro MIDI Editor is also capable of creating your MIDI sequences [Pro].
- Play music from a MIDI file, fully controlling the speed, position, quantization, channel, instrument, effect, and loop. Navigate to a specific position as needed.
- MidiStreamPlayer:
- Generate and perform music through your algorithm.
- Play music by creating MIDI event (note-on, preset change, control change, …) in relation with your Unity action (see MPTKEvent class).
- From your Unity Update() method or on Unity event.
- Generative music is at your fingertips.
- Generate and perform music through your algorithm.
- MidiFileLoader:
- Load a MIDI file for analysis or processing by accessing to all the MIDI events: note, tempo, text, instrument, … No player onboarded.
Four Prefabs are available with the Pro version
- MidiListPlayer:
- Play music from a list of MIDI files.
- Overlap between MIDI
- Play part of a midi.
- Loop …
- Play music from a list of MIDI files.
- MidiExternalPlay:
- Play a MIDI directly with an URL from the Web or anywhere from the device (desktop or mobile).
- MidiInReader:
- Read MIDI events from a MIDI keyboard.
- Play directly, or do all that you want with the MIDI events (see MPTKEvent class).
- MidiSpatializer:
- Play music from a MIDI files with the spatializer ready for a 3D environment where each instruments can be localized in space.
There is surely a prefab for your need! All you have to do is to add one of this prefab to your scene.
Main Maestro Classes
Quick overview of the main classes:
- MPTKEvent class
- It’s a central class for all others Maestro prefabs and classes!
- Create MIDI events or interact with the attribute of a MIDI message.
- Play and stop a note.
- Modify in real time default internal synthesizer generators values.
- Change instrument (preset, patch, …).
- Change controllers values.
- Access for the parameters of each voice.
- It’s a central class for all others Maestro prefabs and classes!
- MPTKWriter class [Pro]
- Generate and export MIDI files programmatically.
- Play directly as an external MIDI or directly with MPTK.
- Insert/append MIDI to a MIDI at run-time
- The MIDI Editor functionality is encapsulated build with this class.
- MidiKeyboard class [Pro]
- Connect external MIDI keyboard
- By script:
- List device
- Open / Close the selected device
- Read or write MIDI event to the device