generateHanonThirds function
- HanonThirdsExercise ex,
- int tone
O tom tone (0 a 11) do nº 52: a escala em terças duas vezes e o compasso
final.
Implementation
HanonPiece generateHanonThirds(HanonThirdsExercise ex, int tone) {
final t = hanonThirdsTones[tone];
return HanonPiece(
sections: [
HanonSection(
hanonByBeat(_hand(t, right: true), _hand(t, right: false)),
times: 2,
),
HanonSection(_closing(t)),
],
time: ex.time,
key: t.key,
octaveShifts: [
for (final s in t.shifts)
PatternOctaveShift(
from: s.first ~/ 8,
to: s.last ~/ 8,
startAfter: s.first % 8 == 0 ? null : (s.first % 8) * _sixteenth,
endAfter: s.last % 8 == 7 ? null : (s.last % 8 + 1) * _sixteenth,
),
],
);
}