Skip to main content

merge_variant_measure_streams

Function merge_variant_measure_streams 

Source
pub fn merge_variant_measure_streams(
    x: &Stream,
    y: &Stream,
    variant_name: &str,
) -> Result<Stream>
Expand description

Merges another version of a stream of measures into a copy of it: the measures of the two compared by their notes and rests as difflib compares lists, and a variant added where they differ – replacing measures, taking them out or putting new ones in: music21’s mergeVariantMeasureStreams.

Measures are found by their numbers counted from one, as music21 finds them, so a stream not numbered from one finds others than those that differ, or none.

§Errors

A measure music21 looks for by number that is not there.