Skip to content

Commit

Permalink
Merge pull request #917 from oxygen-dioxide/plugin-note-overlap
Browse files Browse the repository at this point in the history
Fix OpenUtau freezing when using classic plugins if there are overlapping notes
  • Loading branch information
stakira authored Nov 14, 2023
2 parents 34fafe4 + 8383854 commit 01f1728
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions OpenUtau.Core/Classic/Ust.cs
Original file line number Diff line number Diff line change
Expand Up @@ -341,9 +341,12 @@ public static List<UNote> WritePlugin(UProject project, UVoicePart part, UNote f
var note = first;
while (note != last.Next) {
if (note.position < position) {
//Ignore current note if it is overlapped with previous note
note = note.Next;
continue;
}
if (note.position > position) {
//Insert R note if there is space between two notes
writer.WriteLine($"[#{sequence.Count:D4}]");
var spacer = UNote.Create();
spacer.position = position;
Expand Down

0 comments on commit 01f1728

Please sign in to comment.