Skip to content

Commit

Permalink
No need to flagOverlaps anymore
Browse files Browse the repository at this point in the history
flagOverlaps was used to ensure all overlapping (or previously overlapping) objects had their gains recalculated. This is not necessary anymore as each object has it's gain matrix calculated separately and so is unaffected by routing changes of other objects. They are only summed when the entire matrix is requested in order to perform the audio processing.
  • Loading branch information
firthm01 committed Nov 1, 2023
1 parent 03b799b commit 572a892
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 17 deletions.
1 change: 0 additions & 1 deletion ear-production-suite-plugins/lib/include/scene_store.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ class SceneStore : public MetadataListener {
void addGroup(proto::ProgrammeElement const& element);
void addToggle(proto::ProgrammeElement const& element);
void sendUpdate();
void flagOverlaps();
};
}

Expand Down
16 changes: 0 additions & 16 deletions ear-production-suite-plugins/lib/src/scene_store.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,6 @@ void SceneStore::dataReset(const ear::plugin::proto::ProgrammeStore &programmes,
}
}
}

flagOverlaps();
}

void ear::plugin::SceneStore::programmeSelected(const ear::plugin::ProgrammeObjects &objects) {
Expand All @@ -46,7 +44,6 @@ void ear::plugin::SceneStore::programmeSelected(const ear::plugin::ProgrammeObje
for(auto const& object : objects) {
addMonitoringItem(object.inputMetadata);
}
flagOverlaps();
}

void ear::plugin::SceneStore::itemsAddedToProgramme(ear::plugin::ProgrammeStatus status,
Expand All @@ -55,7 +52,6 @@ void ear::plugin::SceneStore::itemsAddedToProgramme(ear::plugin::ProgrammeStatus
for (auto const &object: objects) {
addMonitoringItem(object.inputMetadata);
}
flagOverlaps();
}
}

Expand All @@ -78,7 +74,6 @@ void ear::plugin::SceneStore::itemRemovedFromProgramme(ear::plugin::ProgrammeSta
item != monitoringItems->end()) {
monitoringItems->erase(item);
itemsChangedSinceLastSend.insert(id);
flagOverlaps();
}
}
}
Expand All @@ -89,9 +84,6 @@ bool SceneStore::updateMonitoringItem(proto::InputItemMetadata const& inputItem)
item != monitoringItems->end()) {
auto routingChanged = item->routing() != inputItem.routing();
setMonitoringItemFrom(*item, inputItem);
if(routingChanged) {
flagOverlaps();
}
return true;
} else {
return false;
Expand All @@ -103,7 +95,6 @@ void ear::plugin::SceneStore::programmeItemUpdated(ear::plugin::ProgrammeStatus
if(status.isSelected) {
if(!updateMonitoringItem(object.inputMetadata)) {
addMonitoringItem(object.inputMetadata);
flagOverlaps();
}
}
}
Expand Down Expand Up @@ -247,10 +238,3 @@ void SceneStore::exporting(bool isExporting) {
}
}

void SceneStore::flagOverlaps() {
// Keep it simple - for any routing/monitoring mix changes
// Set changed on all items
for(auto& item : store_.all_available_items()) {
itemsChangedSinceLastSend.insert(item.connection_id());
}
}

0 comments on commit 572a892

Please sign in to comment.