fix(vst): master-gain per-sample ramp (no zipper/click); voice-count commits once on release; minor review items
This commit is contained in:
@@ -745,8 +745,9 @@ ComponentState deserializeComponentState(const std::vector<std::uint8_t>& bytes,
|
||||
// default (unity) holds, reproducing pre-FB1 output exactly. A non-finite, negative, or
|
||||
// above-cap value (a corrupt blob) falls back to unity rather than silencing/blasting.
|
||||
if (version == kComponentStateVersion) {
|
||||
const double g = bitsToDouble(asU64(r.i64()));
|
||||
if (!r.ok) return out; // truncated inside the gain double -> empty (unity holds)
|
||||
const double g = bitsToDouble(r.u64());
|
||||
if (!r.ok) return out; // truncated inside the gain double — unity holds (out already
|
||||
// carries mode/marker/velocity/voice fields from above)
|
||||
out.masterGainLinear =
|
||||
(std::isfinite(g) && g >= 0.0 && g <= vst::masterGainMaxLinear() * (1.0 + 1e-9))
|
||||
? g
|
||||
|
||||
Reference in New Issue
Block a user