summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-04-26 23:51:38 +0000
committerDavid Robillard <d@drobilla.net>2012-04-26 23:51:38 +0000
commit623aca05bf5c5d4491a26969c29e16d8ce38b790 (patch)
treef66e11ddc6b8bbed189fd01d9485b324862cf776 /src
parent4e3a82b0de3646e74e40695d2537bb5071682318 (diff)
downloadingen-623aca05bf5c5d4491a26969c29e16d8ce38b790.tar.gz
ingen-623aca05bf5c5d4491a26969c29e16d8ce38b790.tar.bz2
ingen-623aca05bf5c5d4491a26969c29e16d8ce38b790.zip
Don't send peak values if they're equal to the last sent value.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4280 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src')
-rw-r--r--src/server/PortImpl.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/PortImpl.cpp b/src/server/PortImpl.cpp
index c4d186d7..7dcbf060 100644
--- a/src/server/PortImpl.cpp
+++ b/src/server/PortImpl.cpp
@@ -225,7 +225,7 @@ PortImpl::broadcast_value(Context& context, bool force)
break;
case PortType::AUDIO:
val = forge.make(((AudioBuffer*)buffer(0).get())->peak(context));
- {
+ if (force || val != _last_broadcasted_value) {
const Notification note = Notification::make(
Notification::PORT_ACTIVITY, context.start(), this, val);
context.event_sink().write(sizeof(note), &note);