Project

roborabb

0.0
No commit activity in last 3 years
No release in over 3 years
Algorithmically generate practice drum scores
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Development

>= 0
~> 2.0
 Project Readme

Roborabb

Generates drumming practice charts in lilypond notation.

example score

Example

Install the gem:

gem install roborabb

Then use it:

require 'roborabb'

rock_1 = Roborabb.construct(
  title:          "Rock",
  subdivisions:   8,
  unit:           8,
  time_signature: "4/4",
  notes: {
    hihat: ->(env) { true },
    kick:  ->(env) { (env.subdivision + 0) % 4 == 0 },
    snare: ->(env) { (env.subdivision + 2) % 4 == 0 },
  }
)

puts Roborabb::Lilypond.new(rock_1, bars: 16).to_lilypond

The resulting file is immediately compilable with lilypond:

sudo apt install lilypond # ubuntu lilypond install

ruby examples/rock.rb > rock.ly && lilypond rock.ly # Generates rock.pdf

See examples directory for more.

Compatibility

Only tested on ruby 1.9.3. Requires 1.9, since it uses new style hashes.

Developing

git clone git://github.com/xaviershay/roborabb.git
bundle           # Install development dependencies
bundle exec rake # Runs the specs

Any big new features require an acceptance test, bug fixes should only require unit tests. Follow the conventions already present.

Status

New, but complete.