GithubHelp home page GithubHelp logo

gmh5225 / werckmeister Goto Github PK

View Code? Open in Web Editor NEW

This project forked from werckme/werckmeister

0.0 0.0 0.0 12.13 MB

An open source Sheet Music MIDI Compiler

Home Page: http://werckme.github.io/

License: GNU General Public License v3.0

Shell 0.20% JavaScript 0.01% C++ 61.98% Python 0.91% C 22.83% Lua 1.52% Go 0.27% CSS 0.26% Makefile 0.34% HTML 9.95% CMake 1.33% LilyPond 0.02% Batchfile 0.01% M4 0.24% Dockerfile 0.01% Roff 0.15%

werckmeister's Introduction

Linux Build Windows Build Mac Build

An open source Sheet Music MIDI Compiler

Werckmeister compiles sheet music source code into a MIDI file.

Use Werckmeister if you want to

  • prototype a song
  • transcript sheet music
  • experiment with chord progressions or different accompaniment styles
  • compose using readable source code instead of proprietary files formats

Features

  • open source
  • fast sheet music MIDI compiler
  • sheet file MIDI player
  • vscode extension
  • accompaniment template rendering engine
  • css like conduction rules
  • Lua mods

Motivation

Why oh why does the world need another musical programming language?

It begun with the fact, that I was searching for new scorewriter tool. I was using Overture for a long time but it got outdated and did'nt run very well on my new computer. It anoyed me that I have to pay several hundred dollars just to get it to run on a new system.

That and the fact that all music I have written is "locked in" in a proprietary file format, led me to the decision that the new solution has to be open source.

Fun Fact: If I had known MuseScore during that time, maybe there would be no werckmeister today

So eventually I found LilypPond. I loved the idea behind it: writing music just with text. It addressed the problem having useless (score) files, because having no program that can read it.

Unfortunately lilypond dosen't fullfill all my needs. It is made with a focus on "music engraving", not creating music in a way I would do with a regulary scorewriter (in terms of trying things out, experimenting with ideas).

So, for me, it had following disadvantages:

  • rudimental MIDI generation
  • long rendering time
  • bloated soure code with visual engraving informations

so that was original idea:

having a tool like LilyPond, but

  • with a focus on MIDI
  • fast compile time
  • tight source code

So I searched more in this "music via source code" direction. I found great software there, such as CSound and SuperCollider. But, for my opinion, these programs are made to have a new way of creating music, less writing music in a more traditional way.

Alda comes very close to that, what I was searching for, but again, I didn't know it back then.

So finally, I decided to create werckmeister.

Somewhat later, I played around with a Yamaha keyboard and its "Auto Accompaniment" feature and I was wondering how it comes, that when I press a Cmaj7 chord the virtual band plays the correct notes to that. And that was the beginning of the "accompaniment template" system.

Syntax

Tracks and Voices

A Werckmeister piece is built of tracks and voices. A track can have an arbitray number of voices, but at least there has to be one voice. A track is embraced by brackets ([]), a voice by curled braces ({}). The shortest valid Werckmeister piece would be: [{}]

Notation

The syntax is loosely inspired by the lilypond notation syntax. A note is written by letter followed by a number for its duration. If a note has no duration, the last given duration will be used.

a simple scale with quartes and eights
a simple scale with quartes and eights

Templates

Instead of writing absolute notes, you use relative degrees. For example I4 means the first degree as a quarter note.

This template playes the Ist IIIrd Vth and the VIIth degree as quarter note. It will be played two bars. Starting with a C7 followed by a C minor 7 chord
This template playes the Ist, IIIrd, Vth and the VIIth degree as quarter note. It will be used for two bars. Starting with a C7 followed by a C minor 7 chord.

Installation

Build from sources

Dependencies

  • boost library, links against:
    • unit_test_framework
    • filesystem
    • program_options
    • locale
    • asio
  • rtmidi
  • rapidjson

Prerequisites

If your boost library is not located at a common search path (e.g. "/usr/local/lib"), make sure that the environment variable "BOOST_ROOT" is set.
(see https://cmake.org/cmake/help/v3.15/module/FindBoost.html)

Run cmake

  • make a build directory
  • cd into it

*Nix

  • run cmake ..
  • run make

Windows

  • run cmake --help
  • look for your "generator" e.g. "Visual Studio 12 2013"
  • run cmake .. -G "Visual Studio 12 2013"
  • open the generated .sln file with Visual Studio
  • Start Building

After build

there should be at least 3 executables:

  • sheetc -> a cli ".sheet"-file compiler
  • sheetp -> a cli ".sheet"-file player
  • rehearse -> runs the unit tests

Compiler

run ./sheetc asheetfile.sheet to compile a sheet file into a MIDI file.

Player

run ./sheetp asheetfile.sheet.

There are several optional arguments:

  • --watch -> on the fly change detection/recompile
  • --begin -> start position as quarter position
  • --end -> end position as quarter position
  • --loop -> play as loop
  • --list -> lists your detected MIDI devices

Architecture

Werckmeister Architecture

Other Cool Projects

werckmeister's People

Contributors

sambagodschynski avatar kant 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.