-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
generatePatternSeqs features #21
base: master
Are you sure you want to change the base?
generatePatternSeqs features #21
Conversation
[60, 1.0, 75/127.0], | ||
[\rest, 1.0, 0.0], | ||
[60, 1.0, 100/127.0] | ||
]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3-tuple when velocity flag is set.
[60, 1.0], | ||
[\rest, 1.0], | ||
[60, 1.0] | ||
]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the default / previous behavior.
[60, 1.0], | ||
[\rest, 1.0], | ||
[60, 1.0] | ||
]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Default / previous behavior.
[60, 1.0], | ||
[\rest, 1.0], | ||
[60, 1.0] | ||
]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pads the start of the pattern with a rest, because the first note is a beat in.
[\rest, 1.0], | ||
[60, 1.0], | ||
[\rest, 1.0] | ||
]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pads the end of the pattern with a rest, because the last note ends at 3.0
and the argument is 4.0
Hello,
This introduces 2 features to the
generatePatternSeqs
method, as well as unit tests & MIDI files demonstrating the features.Consider this MIDI file:
This would create a pattern like:
Now consider this MIDI file:
Without this PR,
generatePatternSeqs
will generate the same pattern. But I want to put a rest in there, useful when loading loops in the MIDI sequence.By the same token, if the notes in the MIDI file do not go until the end of the file, I'd like to define the length of the loop and to insert a rest.
Unit tests and fixtures (example MIDI files) included. To run the tests:
The post window should show: