MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ update_source_mix()

bool MayaFlux::Buffers::MixProcessor::update_source_mix ( const std::shared_ptr< AudioBuffer > &  buffer,
double  new_mix_level 
)

Updates the mix level of an existing source.

Parameters
bufferSource buffer to update
new_mix_levelNew mix level
Returns
true if source was found and updated

Definition at line 104 of file MixProcessor.cpp.

105{
106 for (auto& source : m_sources) {
107 if (source.matches_buffer(buffer)) {
108 source.mix_level = new_mix_level;
109 return true;
110 }
111 }
112 return false;
113}
std::shared_ptr< NetworkGeometryBuffer > buffer
std::vector< MixSource > m_sources
Source source()
Begin a Source chain.
Definition Plot.hpp:127

References buffer, and m_sources.