maelzel.scoring: General purpose music notation¶
maelzel.scoring Package¶
scoring¶
The scoring package provides functionality for representing a musical score and rendering to pdf or an image via multiple backends (lilypond, MuseScore)
scoring.core¶
See also
maelzel.scoring.core
The scoring.core provides the basic building blocks to define an abstract
score. For scoring purposes the most basic element is the
maelzel.scoring.notation.Notation
. A Notation can be used to represent
a Note, a Chord or a Rest. Notations can be grouped together in a
maelzel.scoring.core.Part
and multiple Parts form an
maelzel.scoring.core.UnquantizedScore
Quantized / Unquantized¶
See also
In all these cases durations are abstract and measured in quarter notes. The generated UnquantizedPart/UnquantizedScore do not have any measures or scorestructure and are not quantized to musically meaningful durations.
For quantization purposes a ScoreStruct
is needed, where
the structure of the score is defined (time signatures, tempi, metadata). In order
to fine-tune the quantization a QuantizationProfile
can
be defined, or the default preset can be used. Such a QuantizationProfile
allows to
determine the complexity of the resulting rhythms, kinds of tuplets allowed, when to use
grace-notes, etc.
Rendering¶
See also
Only when an Arrangement has been quantized to a QuantizedScore
it is possible to render this as pdf. The rendering process is done by first converting
the quantized intermediate representation to some of the supported backend formats:
lilypond or musicxml (rendered via MuseScore). Then the rendering backend is called
to generate either a pdf
or a png
. It is also possible to export the rendered score
as musicxml
or even as midi
.
Note
The external programs used for rendering (lilypond or MuseScore) need to be installed and present in the path. It is possible to customize the binary called when rendering in the general maelzel configuration. See Configuration
Functions¶
|
|
|
True if these Notations can be merged based on duration and start/end |
|
Return a list of Notations filled with rests |
|
Utility function to create a chord Notation |
|
Create an id to group notations together |
|
Utility function to create a note Notation |
|
Shortcut function to create a rest notation. |
|
Merge two compatible notations to one. |
|
Merge the given notations into one, if possible |
|
Returns True if n0 and n1 can be merged |
|
Convert notations to their corresponding |
|
Pack a list of possibly simultaneous notations into tracks |
|
Remove overlap between notations. |
|
Fills all offsets, in place |
|
Split the given notations between the given offsets |
|
Tie these notations inplace |
Classes¶
|
Class representing the notated duration of a note |
|
This represents a notation (a rest, a note or a chord) |
|
An UnquantizedPart is a list of unquantized non-simultaneous |
|
An UnquantizedScore is a list of UnquantizedParts |