Rusthesia

Rusthesia is till now just a hack to play a midi file, created from Logic Pro/X, and display a window with falling notes down onto a piano. Thus hardcoded for example is to use track 1 and 2 as piano input.

The midi file can be transposed in half notes in realtime by using shift left/right key. Playing can be paused by space.

Audio

Synthesizer is not included. Instead midi messages will be sent via core audio. Logic Pro/X can be used for playing the midi, but has to be set up accordingly.

No idea for other operation systems, if it works or how to do.

Video

Screen output uses sdl2.

Screenshot

Here screenshot for current version: Screenshot

Preparation

The sdl2 libraries need to be installed. On macos this can be done by:

brew install sdl2 sdl2_gfx

Installation

cargo install rusthesia

Usage

For help just execute

rusthesia -h

For usage example the midi-file MarcheauxFlambeaux.mid is included. As per that website, this file is in the public domain.

First list the available tracks: ```

rusthesia MarcheauxFlambeaux.mid -l Track 0: Text: Creator: GNU LilyPond 2.8.7 Text: Generated automatically by: GNU LilyPond 2.8.7 Text: at Mon Oct 16 20:41:39 2006 Text: at Mon Oct 16 20:41:39 2006 Track name: Track 0 Track 1: Track name: upper Instrument name: accordion Track 2: Track name: lower Instrument name: accordion ```

For playing and displaying all tracks use: ```

rusthesia MarcheauxFlambeaux.mid -p 0 1 2 -s 0 1 2 ```

In order to play the lower and show only the upper, use the following command: ```

rusthesia MarcheauxFlambeaux.mid -p 1 -s 2 ```

Todo

Final Words

The application works, but still this is a quick hack. In future refactoring will be necessary.