Code Monkey home page Code Monkey logo

mplay's Introduction

mplay

Mplay is a MIDI player written in pure Python. It runs on OS X, Windows and Linux. Apart from an OpenGL wrapper (for the GUI part), there are no dependencies on other packages. Mplay has been tested with Python 2.7.5, 3.3.2 and PyOpenGL 3.0.2.

Hightlights:

  • Full functional MIDI player
  • Mixer with mute and solo options
  • Ability to change channel parameters (delay, chorus, reverb, pan)
  • Volume sliders
  • Pulldown menus for GM instrument sounds
  • MIDI VU meter
  • Show note, chord and lyrics information
  • Change key, tempo
  • Transport controls
  • Keyboard shortcuts
Key Action
a un-mute all channels
b/B toggle/solo bass
d/D toggle/solo drums
g/G toggle/solo guitar(s)
k/K toggle/solo keyboard(s)
1234567890!@#$%^ toggle channel 1-16
-/+ decrease/increase tempo
SPACE stop/resume song
> < transpose up/down
TAB select next channel
ESC quit Mplay

Tips and Tricks:

Mac OS X and Windows systems come with a builtin software synthesizer (Apple DLS SoftSynth, Microsoft GS Wavetable SW Synth). On those systems Mplay runs out of the box. For Linux, however, it might be necessary to start a TiMidity++ server:

# sudo modprobe snd_virmidi
# timidity -iAqqq &
TiMidity starting in ALSA server mode
Opening sequencer port: 128:0 128:1 128:2 128:3
# aconnect -o
client 0: 'System' [type=kernel]
    0 'Timer           '
    1 'Announce        '
client 14: 'Midi Through' [type=kernel]
    0 'Midi Through Port-0'
client 20: 'Virtual Raw MIDI 1-0' [type=kernel]
    0 'VirMIDI 1-0     '
client 21: 'Virtual Raw MIDI 1-1' [type=kernel]
    0 'VirMIDI 1-1     '
client 22: 'Virtual Raw MIDI 1-2' [type=kernel]
    0 'VirMIDI 1-2     '
client 23: 'Virtual Raw MIDI 1-3' [type=kernel]
    0 'VirMIDI 1-3     '
# aconnect 20:0 128:0

For Mac OS X you can easily build a standalone application:

virtualenv python
source python/bin/activate
pip install py2app
pip install PyOpenGL
pip install pyobjc-framework-cocoa
python setup.py py2app
dropdmg dist/mplay.app --layout-name='Mac App' --destination=`pwd`

Links:

Mplay website

Barcamp talk 2013

mplay's People

Contributors

florianrhiem avatar jheinen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

mplay's Issues

General MIDI library

Hi!

I have a player app that has a midi component. I'm using mido at the moment to do midi playback. I've used pygame's midi player too.

Will the mplay code work well as a general purpose midi player on windows?

I do not need the fancy user interface, unfortunately. I would like something that I can adjust the tempo pretty easily too which means getting at the messages.

I'm sorry if these are rookie questions to be asking you.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.