MCPcopy Create free account
hub / github.com/aethersdr/AetherSDR / testZeroSourceCompPeakUsesSliceContext

Function testZeroSourceCompPeakUsesSliceContext

tests/meter_model_test.cpp:132–148  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

130}
131
132void testZeroSourceCompPeakUsesSliceContext()
133{
134 MeterModel model;
135 model.defineMeter(slcMeter(14, 0));
136 model.defineMeter(txMeter(20, "COMPPEAK", "dB", 0));
137 model.defineMeter(slcMeter(32, 1));
138 model.defineMeter(txMeter(44, "COMPPEAK", "dB", 0));
139
140 model.setActiveTxSlice(1);
141 model.updateValues({20}, {rawDb(8.0f)});
142 report("inactive zero-source COMPPEAK meter is ignored",
143 !model.hasCompressionMeterValue() && nearlyEqual(model.compPeak(), 0.0f));
144
145 model.updateValues({44}, {rawDb(15.0f)});
146 report("zero-source COMPPEAK meter follows active slice context",
147 model.hasCompressionMeterValue() && nearlyEqual(model.compPeak(), 15.0f));
148}
149
150void testSparseSliceIdsUseManifestDerivedWaveformBase()
151{

Callers 1

mainFunction · 0.85

Calls 10

slcMeterFunction · 0.85
txMeterFunction · 0.85
rawDbFunction · 0.85
defineMeterMethod · 0.80
setActiveTxSliceMethod · 0.80
updateValuesMethod · 0.80
compPeakMethod · 0.80
reportFunction · 0.70
nearlyEqualFunction · 0.70

Tested by

no test coverage detected