A musical instrument built using the Leap Motion v2.
Download the source code of the project with git:
git clone <repo url>
cd leapMusic
Download the Leap SDK and move, copy or link the folder named LeapSDK into the project directory, the following example is of symlinking:
ln -s ~/Path/To/SDK/LeapSDK ./
Then install the PortAudio, PortMIDI, FreeGLUT and GLEW libraries.
sudo apt-get install libportaudio19-dev libportmidi-dev freeglut3-dev libglew-dev libxmu-dev libxi-dev
brew install portaudio homebrew/X11/freeglut glew
Unfortunately portmidi isn't packaged for homebrew which means you will have to download, build and install it on your own.
Now you're ready to build the project:
cd build
cmake ..
make
If you don't want to compile the project with make you can specify the type of project files CMake should generate with the -G flag. Use cmake --help
to see which generators are available.
-
An open hand with the palm facing downwards indicates idleness, nothing happens.
-
A hand turned up side down opens the context menu.
-
Absolute position of the palm of the hand. This is the position used to modify the tone and also to navigate menus. This information is trivially retrieved from the SDK.
-
Closing the hand and only pointing with the index finger plays a note.
-
Closing the fingers completely into a fist records the sound.