From cb92abd03fce026bb6182d3d71386c35917712a4 Mon Sep 17 00:00:00 2001 From: Massimo Callegari Date: Tue, 8 Oct 2024 19:43:50 +0200 Subject: [PATCH] engine: fix flashing fade out (fix #1624) Fix also: https://www.qlcplus.org/forum/viewtopic.php?t=17774 --- debian/changelog | 1 + engine/src/genericfader.cpp | 10 +++++----- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/debian/changelog b/debian/changelog index 21b91282ca..8ade849967 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,5 +1,6 @@ qlcplus (4.13.2) stable; urgency=low + * engine: fix flashing fade out * engine: add stopOnExit, waitFunctionStart and waitFunctionStop commands to Script - see documentation (thanks to ldebs) * UI/Show Manager: show step notes on the timeline (thanks to anarchid) * Web Access: fix grand master stopping running functions diff --git a/engine/src/genericfader.cpp b/engine/src/genericfader.cpp index f1f5cece85..c21eccfe8e 100644 --- a/engine/src/genericfader.cpp +++ b/engine/src/genericfader.cpp @@ -340,16 +340,16 @@ void GenericFader::setFadeOut(bool enable, uint fadeTime) { FadeChannel& fc(it.next().value()); - // non-intensity channels (eg LTP) should fade - // to the current universe value - if ((fc.flags() & FadeChannel::Intensity) == 0) - fc.addFlag(FadeChannel::SetTarget); - fc.setStart(fc.current()); + // all channels should fade to the current universe value + fc.addFlag(FadeChannel::SetTarget); fc.setTarget(0); fc.setElapsed(0); fc.setReady(false); fc.setFadeTime(fc.canFade() ? fadeTime : 0); + // if flashing, remove the flag and treat + // it like a regular fade out to target + fc.removeFlag(FadeChannel::Flashing); } }