Time value for LengthConverter.ConvertFrom #194
Answered
by
melanchall
Jenix-Park
asked this question in
Q&A
-
Let's say I have absolute time data of both note-on and note-off events in microseconds.
|
Beta Was this translation helpful? Give feedback.
Answered by
melanchall
Jun 1, 2022
Replies: 1 comment 1 reply
-
Your code is good, but it can be simplified: var note = new Note((SevenBitNumber)noteNumber)
.SetTime(new MetricTimeSpan(noteOnTime), tempoMap)
.SetLength(new MetricTimeSpan(noteOffTime - noteOnTime), tempoMap); |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
Jenix-Park
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Your code is good, but it can be simplified: