gp-import: fixed wrong alterations with capo

This commit is contained in:
Alexander Pavlov 2022-12-20 14:27:00 +01:00
parent d2ef9946b8
commit 40daa57fba

View file

@ -2173,7 +2173,7 @@ void GPConverter::setTpc(Note* note, int accidental)
{ 11, 19 },
};
if (accidental == GPNote::invalidAccidental) {
if (note->staff()->capo({ 0, 1 }) != 0 || accidental == GPNote::invalidAccidental) {
note->setTpcFromPitch();
} else {
int tone = (note->pitch() - accidental + 12) % 12;