diff --git a/OpenUtau.Core/Format/MidiWriter.cs b/OpenUtau.Core/Format/MidiWriter.cs index e7461e607..44a3c94d8 100644 --- a/OpenUtau.Core/Format/MidiWriter.cs +++ b/OpenUtau.Core/Format/MidiWriter.cs @@ -263,6 +263,10 @@ static public void Save(string filePath, UProject project) { using (var objectsManager = new TimedObjectsManager(trackChunk.Events)) { var events = objectsManager.Objects; foreach (UNote note in voicePart.notes) { + //Ignore notes whose pitch is out of midi range + if(note.tone < 0 || note.tone > 127){ + continue; + } string lyric = note.lyric; if (lyric == "+") { lyric = "-";