Closed firthm01 closed 11 months ago
Regardless, the affected item should have it's change flag set by the input plugin, and so this should acted upon by the monitoring plugins - to check.
EDIT: The change flag is set and is received by the monitoring plugins as expected.
The problem is that the SceneGainsCalculator expects only one use of an input channel. When metadata for an AudioObject is received, the matrix (direct_ vector) for those input channels are updated. If another AudioObject also uses those input channels and sends metadata, the matrix is then updated to represent that AudioObject, overwriting the previous values.
This section of code runs once for every piece of AudioObject metadata received;
https://github.com/ebu/ear-production-suite/blob/9a5c788421e242a47364567258b1b3b304f12cfe/ear-production-suite-plugins/lib/src/scene_gains_calculator.cpp#L123-L129
You can see how it would overwrite whatever was previously stored in direct_[inputChannel]
if inputChannel
is reused between AudioObjects.
Gains should be a summation of calculations for all AudioObjects using that input channel - perhaps we need to do per-object calculations and then sum whenever the direct or diffuse matrices are requested by the audio processing backend.
Original Title: Monitoring issue when a DS layout is changed
E.g,
EDIT: This reasoning is not entirely correct - see later comments
This is because routing changes are currently only detected if the routing parameter changes (i.e, starting channel). A change of layout is not detected as a routing change, even though it should be. See this bit of code;https://github.com/ebu/ear-production-suite/blob/9a5c788421e242a47364567258b1b3b304f12cfe/ear-production-suite-plugins/lib/src/scene_store.cpp#L90-L94 ~~This triggersflagOverlaps
which adds all of the items to theitemsChangedSinceLastSend
vector, making sure the monitoring plugins update their state for all items (we kept it simple here rather than trying to figure out exactly which items are affected). Opening the Scene plugin triggersflagOverlaps
via another code route which is why we hear the correction only when the Scene plugin is opened.~~