| 292 | } |
| 293 | |
| 294 | void ProcessorChain::updateNoLock() { |
| 295 | traceScope(); |
| 296 | int latency = 0; |
| 297 | bool supportsDouble = true; |
| 298 | m_extraChannels = 0; |
| 299 | m_sidechainDisabled = false; |
| 300 | for (auto& proc : m_processors) { |
| 301 | if (nullptr != proc) { |
| 302 | latency += proc->getLatencySamples(); |
| 303 | if (!proc->supportsDoublePrecisionProcessing()) { |
| 304 | supportsDouble = false; |
| 305 | } |
| 306 | m_extraChannels = jmax(m_extraChannels, proc->getExtraInChannels(), proc->getExtraOutChannels()); |
| 307 | m_sidechainDisabled = m_hasSidechain && (m_sidechainDisabled || proc->getNeedsDisabledSidechain()); |
| 308 | } |
| 309 | } |
| 310 | if (latency != getLatencySamples()) { |
| 311 | logln("updating latency samples to " << latency); |
| 312 | setLatencySamples(latency); |
| 313 | } |
| 314 | m_supportsDoublePrecision = supportsDouble; |
| 315 | auto it = m_processors.rbegin(); |
| 316 | while (it != m_processors.rend() && (*it)->isSuspended()) { |
| 317 | it++; |
| 318 | } |
| 319 | if (it != m_processors.rend()) { |
| 320 | m_tailSecs = (*it)->getTailLengthSeconds(); |
| 321 | } else { |
| 322 | m_tailSecs = 0.0; |
| 323 | } |
| 324 | } |
| 325 | |
| 326 | std::shared_ptr<Processor> ProcessorChain::getProcessor(int index) { |
| 327 | traceScope(); |
nothing calls this directly
no test coverage detected