Conversation
92290e1 to
9a18de8
Compare
9adf766 to
a4678d1
Compare
a4678d1 to
4008d43
Compare
58b87fd to
83caf8d
Compare
83caf8d to
c086918
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.
This PR addresses mido#102 and adds the necessary time signature arguments to the functions in
mido.midifiles.unitsand modifiesMidiFile.__iter__to also respect time signature events in a MIDI stream/file.This PR furthermore adds a couple of other (related) things:
MidiFileto choose the timing unit to be used (ticks, seconds, beats),MidiFileto choose between relative and absolute timing when iterating over messages.Before being able to be merged, these points should be discussed/addressed:
midi_files.rst.tick2beatandbeat2tickinto the main namespace?tick2beatandbeat2tickin the API docs.MidiFile.lengthraises aValueErrorwhereasMidiFile.__iter__aTypeErrorin case of type 2 MIDI files. Which one is more appropriate?ticks_per_beattoticks_per_quarter_noteor add new variable (how to deprecate the old one)?