Giter VIP home page Giter VIP logo

pianoputer's Introduction

Pianoputer

This library lets you to play your computer keyboard like a piano. Here is a video of it in action on a French azerty keyboard.

Play!

Pianoputer only works in python3 so make sure you are using python3

pip install pianoputer
pianoputer

After a few seconds, the below image will appear in a window, indicating that the program is ready. The cyan key is the key that the sample wav file is assigned to. By default this is c4, the piano middle C at 261.6 hz All white and black keys are transposed up and down from the anchor cyan key.

qwerty keyboard layout, c4 is cyan

Changing the sound file

You can provide your own sound file with

pianoputer --wav my_sound_file.wav

For example:

pianoputer -w audio_files/bowl_c6.wav

All white and black keys are transposed up and down from the anchor cyan key.

Changing the keyboard layout

Note that the default keyboard configuration (stored in file keyboards/qwerty_piano.txt) is for the most commonly used QWERTY keyboards. You can change the configuration so that it matches your keyboard, for instance using the alternative keyboards/azerty_typewriter.txt:

pianoputer -k keyboards/azerty_typewriter.txt

azerty typewriter These .txt files simply contain a sequence of key names and are easy to edit. For convenience this repository also provides a make_kb_file.py program:

python make_kb_file.py

This will let you press the keys in the order that you want, and create a new keyboard configuration file, by default my_keyboard.kb (just follow the instructions). You can then use the custom keyboard file with the --keyboard argument

Local Installation

python3 -m venv venv
source venv/bin/activate
# if you want to edit the program and have pianoputer use your edits
pip install -e .
# to install pianoputer separately in your virtual environment
pip install .
pianoputer

Attributions

Changelog

https://github.com/Zulko/pianoputer/tree/master/CHANGELOG.md

pianoputer's People

Contributors

spacether avatar zulko avatar yoyoberenguer avatar adriankhl avatar xpika avatar schneiderfelipe avatar jtyr avatar jo-m avatar

Watchers

James Cloos avatar

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.