Bake window: derive it from the rate the voice actually reads at, so a dialled Rate or downward Pitch no longer truncates the file
This commit is contained in:
@@ -50,6 +50,8 @@ InstrumentParams dialed() {
|
||||
p.play.pitchEnv.peakSemitones = -7.0;
|
||||
p.play.pitchEnv.shape.attackSeconds = 0.05;
|
||||
p.play.pitchVelocityCurve = VelocityCurve::linear();
|
||||
p.play.playRate = 0.5;
|
||||
p.play.pitchOffsetSemitones = -7.5;
|
||||
p.play.filter.enabled = true;
|
||||
p.play.filter.modAmount = -0.8;
|
||||
p.play.filter.velAmount = 0.6;
|
||||
@@ -139,6 +141,15 @@ int main() {
|
||||
CHECK(after.play.pitchEnv.peakSemitones == 0.0);
|
||||
CHECK(after.play.pitchEnv.shape.attackSeconds == freshPlay.pitchEnv.shape.attackSeconds);
|
||||
|
||||
// --- RESET: Rate and the baseline Pitch offset -----------------------------------
|
||||
// Both are processing the bake already printed, so the whitelist leaves them at their
|
||||
// defaults — the safe direction. A second bake of the result at a still-dialled rate would
|
||||
// otherwise re-stretch what the first one baked in.
|
||||
CHECK(after.play.playRate == 1.0);
|
||||
CHECK(after.play.pitchOffsetSemitones == 0.0);
|
||||
CHECK(after.play.playRate == freshPlay.playRate);
|
||||
CHECK(after.play.pitchOffsetSemitones == freshPlay.pitchOffsetSemitones);
|
||||
|
||||
// --- RESET: the filter, including its velocity/key-tracking mod -----------------
|
||||
CHECK(!after.play.filter.enabled);
|
||||
CHECK(after.play.filter.modAmount == 0.0);
|
||||
|
||||
Reference in New Issue
Block a user