DryWetMIDI 8.0.0
Major playback improvements
Now it’s possible to change playback’s data on the fly (#78)! It was a big challenge to implement this functionality (do you even use red-black trees?). But now you can add, remove and change objects without needing to recreate an instance of the Playback or even stop it. You’ll find the detailed guide on how to use the feature in the Dynamic changes article of the library docs.
Also a bunch of bugs related to the Playback were fixed:
- currently playing note is not interrupted when
PlaybackEndreached; MoveToTimehas no effect if it’s executed just before the firstStartmethod call;IsRunningcan return invalid value due to race conditions whenLoopproperty is set totrue;Startand thenStopcalls in the middle of a note can cause unexpected behavior whenInterruptNotesOnStopandTrackNotesare set totrue.
Data tracking is now on by default. So in case of jumps in time you’ll get correctly applied program, pitch and control values. TrackNotes is now true by default too. Of course you can turn the feature off via corresponding properties if you want.
Several new things were added:
Playback: addedSendNoteOffEventsForNonActiveNotesandSendNoteOnEventsForActiveNotesproperties;PlaybackSettings: addedCalculateTempoMapproperty;NotesPlaybackStartedandNotesPlaybackFinishedevents args: added original notes (seeNotesEventArgs.OriginalNotes).
Please note that there are some breaking changes:
Playmethod has been removed. It causes confusion and does nothing but just callingStartand thenSpinWait.SpinUntil(() => !IsRunning). You can do these actions by yourself if you for some reason want the blocking playback.PlaybackHinthas been removed fromPlaybackSettings. There was no noticeable performance gain in using this feature. You can just disable data tracking if you want.- Snapping has been reworked. First of all, there is no
Snappingproperty within thePlaybackanymore. Snapping functionality was moved just right into thePlayback.Snapping.IsEnabledis replaced withIsSnappingEnabled.SnapToNotesStartsandSnapToNotesEndsmethods are replaced with the much more flexibleSnapToEventsone.
New features and improvements
- Split
CsvSerializerSettingsintoCsvSerializationSettingsfor serialization methods andCsvDeserializationSettingsfor deserialization ones. - Time, length and note formats can be resolved automatically on CSV deserialization (which is the default behavior now).
- Added
UnknownRecordPolicyproperty toCsvDeserializationSettings. - Introduced
CsvExceptionwhich replacesFormatExceptioninCsvSerializer. - Added
BytesArrayDelimiterproperty toCsvSerializationSettingsandCsvDeserializationSettings. - Added
RemoveDuplicatedControlChangeEventsproperty toSanitizingSettings. - Replaced
RemoveOrphanedNoteOnEventsproperty ofSanitizingSettingswithOrphanedNoteOnEventsPolicywhich provides more ways to handle orphaned Note On events.
Small changes and bug fixes
- Implemented piano roll multi-cell custom actions.
- Print line and symbol indices in piano roll errors.
- Handle empty collections in
ManageTempoMapmethods of theTempoMapManagingUtilities(#321). - Optimized
MidiFileUtilities.GetDurationmethods. - Fixed: MIDI devices session is not closed on domain unload or process exit (#318).
- Fixed: Bytes array values with whitespaces causes CSV deserialization failed.