lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Script for note/rest refactor? (with parsing tools)


From: Pedro Pessoa
Subject: Script for note/rest refactor? (with parsing tools)
Date: Tue, 26 Feb 2019 17:24:33 -0700 (MST)

Hello list,
I'm working in a python script to generate lilypond code which generates an
almost isorhythmic stream of notes/rests.
The sustain of the notes isn't important. For better readability, I wanna
refactor these values to fit the beat's timeunit.

Where time unit = 4 :
1) des16 r16 r16 r16 -> des4
2) r8 des16 r16 r16 -> r16 des8.
3) r8 * 8 -> r4 r4

I was about to write some code to do it inside my engine (before the
lilypond is generated), but then I wondered if there wasn't some kinda of
frescobaldi snippet or python code that could do it with parsing tools. This
would be a more friendly solution to share or reuse. So, does anyone...

- have a python (or some other) script to deal with this kind problem?
- can point to some resources on the usage of python-ly?
I tried playing with it, but I'm not sure I'll get the hang of it too soon.

Thanks,
Pessoa



--
Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html



reply via email to

[Prev in Thread] Current Thread [Next in Thread]