feat: model the percussion direction family - #361
Merged
Conversation
webern
force-pushed
the
claude/direction-types-ordering-9l60vv-c
branch
from
July 19, 2026 05:31
23b0860 to
b5dd8bd
Compare
Base automatically changed from
claude/direction-types-ordering-9l60vv-c
to
main
July 19, 2026 05:34
Fourth slice of #324: PercussionData with a TimeChoice-style PercussionDataChoice over the eleven pictogram alternatives, eleven parallel api enums mapped through new Converter EnumMaps so no value can be silently dropped, and the full 15-value MusicXML 4.0 enclosure-shape list. Wired through DirectionReader and DirectionWriter with orderedComponents fidelity. Round-trip baseline 248 -> 272 (the full synthetic percussion family). All direction-type choices are now modeled.
webern
force-pushed
the
claude/direction-types-ordering-9l60vv-d
branch
from
July 19, 2026 05:35
22584d6 to
969a10f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Human Summary
More direction types that were unmodeled.
Summary
Fourth slice of #324 (stacked on #360): the percussion pictogram family, the last unmodeled direction-type choice.
PercussionDatacarries formatting, an optional enclosure, and aPercussionDataChoice— a TimeChoice/MarkDataChoice-style variant class over the eleven pictogram alternatives (glass, metal, wood, pitched, membrane, effect, timpani, beater, stick, stick-location, other-percussion), each a small struct pairing its instrument enum with the optional SMuFL glyph override (plus tip direction / material / parentheses / dashed-circle for beater and stick).PercussionEnclosurecarries the full 15-value MusicXML 4.0 enclosure-shape list (inverted-bracket, pentagon..decagon included).DirectionReader/DirectionWriterwithorderedComponentsfidelity. Like the existing words handling, several<percussion>children of one direction-type read into separatePercussionDataitems and are written back one per direction-type; no corpus file groups them, so nothing currently loses fidelity.With this, every direction-type choice is modeled. Remaining #324 items are the metronome extras (metric modulation) and the pedal-type gaps (sostenuto/change/continue/discontinue/resume).
Testing
DirectionMarksRoundTriptests covering all eleven alternatives, enclosure, tip direction, stick attributes, and the timpani SMuFL override (108 assertions in 20 test cases across the file)References