From a0278a8893d9a784153479e861930d31122f22fa Mon Sep 17 00:00:00 2001 From: Yinan Zhou Date: Wed, 27 Nov 2024 20:37:56 -0500 Subject: [PATCH] fix: change default octave to c4 when adjusting pitch refs: https://github.com/DDMAL/Neon/issues/1246 --- src/editortoolkit_neume.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/editortoolkit_neume.cpp b/src/editortoolkit_neume.cpp index 08e110a978e..b29dfd18f8b 100644 --- a/src/editortoolkit_neume.cpp +++ b/src/editortoolkit_neume.cpp @@ -4252,11 +4252,10 @@ bool EditorToolkitNeume::AdjustPitchFromPosition(Object *obj, Clef *clef) LogError("Clef %s does not have valid shape. Shape is %s", clef->GetID().c_str(), clef->GetShape()); return false; } - pi->SetOct(3); - // The default octave = 3, but the actual octave is calculated by + // The default octave = 4, but the actual octave is calculated by // taking into account the displacement of the clef - int octave = 3; + int octave = 4; if (clef->GetDis() && clef->GetDisPlace()) { octave += (clef->GetDisPlace() == STAFFREL_basic_above ? 1 : -1) * (clef->GetDis() / 7); } @@ -4323,9 +4322,9 @@ bool EditorToolkitNeume::AdjustPitchFromPosition(Object *obj, Clef *clef) assert(pi); pi->SetPname(pname); - // The default octave = 3, but the actual octave is calculated by + // The default octave = 4, but the actual octave is calculated by // taking into account the displacement of the clef - int octave = 3; + int octave = 4; if (clef->GetDis() && clef->GetDisPlace()) { octave += (clef->GetDisPlace() == STAFFREL_basic_above ? 1 : -1) * (clef->GetDis() / 7); }