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

◆ get_audio_buffer()

std::optional< std::vector< double > > MayaFlux::Nodes::Network::NodeNetwork::get_audio_buffer ( ) const
virtual

Get cached audio buffer from last process_batch()

Returns
Optional vector of samples

Returns the buffer generated by the most recent process_batch() call. All channels requesting this network's output get the same buffer.

Reimplemented in MayaFlux::Nodes::Network::ResonatorNetwork.

Definition at line 15 of file NodeNetwork.cpp.

16{
17 if (
20 && !m_last_audio_buffer.empty()) {
22 }
23 return std::nullopt;
24}
std::vector< double > m_last_audio_buffer
@ AUDIO_COMPUTE
processed each cycle but not sent to output
@ AUDIO_SINK
Aggregated audio samples sent to output.

References MayaFlux::Nodes::Network::AUDIO_COMPUTE, MayaFlux::Nodes::Network::AUDIO_SINK, m_last_audio_buffer, and m_output_mode.