Browse Source

Export lilypond blocks with minimum duration

master
Nils 2 years ago
parent
commit
98afe4d5ec
  1. 10
      engine/block.py

10
engine/block.py

@ -349,4 +349,12 @@ class Block(object):
such as tuplets.
Can act like a stack or simply remember stuff.
"""
return "\n % Block: " + self.name + "\n " + " ".join(item.lilypond(carryLilypondRanges) for item in self.data)
#Calculate padding from block minimum tick duration in D1024 notes. Lilypond doesn't care.
difference = self.staticExportEndMarkerDuration()
if difference:
skipstring = f" s1024*{int(difference / D1024)}"
else:
skipstring = ""
return "\n % Block: " + self.name + "\n " + " ".join(item.lilypond(carryLilypondRanges) for item in self.data) + skipstring + "\n"

Loading…
Cancel
Save