|
MayaFlux 0.3.0
Digital-First Multimedia Processing Framework
|
| void MayaFlux::Kriya::TemporalActivation::activate_network | ( | const std::shared_ptr< Nodes::Network::NodeNetwork > & | network, |
| double | duration_seconds, | ||
| Nodes::ProcessingToken | token = Nodes::ProcessingToken::AUDIO_RATE, |
||
| const std::vector< uint32_t > & | channels = {} |
||
| ) |
Activates a node network for a specified duration.
| network | The node network to activate |
| token | The processing token associated with the network |
| duration_seconds | The duration to keep the network active (in seconds) |
| channels | Optional list of output channels to connect the network to (default is all channels) |
This method activates the specified node network by connecting it to the output channels or graphics sync, and starts a timer for the specified duration. When the timer expires, the network is automatically disconnected from the output channels, effectively deactivating it.
If another node, network, or buffer is already active, it will be cancelled before activating the new one.
Definition at line 108 of file Timers.cpp.
References MayaFlux::Nodes::NodeGraphManager::add_network(), cancel(), cleanup_current_operation(), m_active_type, m_channels, m_current_network, m_node_graph_manager, m_node_token, m_timer, NETWORK, and MayaFlux::Kriya::Timer::schedule().
Here is the call graph for this function: