MayaFlux 0.1.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches
MayaFlux::Vruta::ComplexRoutine Class Reference

Multi-domain coroutine that can handle multiple processing rates. More...

#include <Routine.hpp>

+ Inheritance diagram for MayaFlux::Vruta::ComplexRoutine:
+ Collaboration diagram for MayaFlux::Vruta::ComplexRoutine:

Public Member Functions

ProcessingToken get_processing_token () const override
 Get the processing token that determines how this routine should be scheduled.
 
bool requires_clock_sync () const override
 Check if the routine should synchronize with a clock.
 
bool get_auto_resume () const override
 Get auto_resume flag from promise.
 
void set_auto_resume (bool) override
 Set auto_resume flag in promise.
 
bool get_should_terminate () const override
 Get should_terminate flag from promise.
 
void set_should_terminate (bool) override
 Set should_terminate flag in promise.
 
bool get_sync_to_clock () const override
 Get sync_to_clock flag from promise.
 
uint64_t get_next_sample () const override
 Get next sample execution time (audio domain)
 
void set_next_sample (uint64_t) override
 Set next sample execution time (audio domain)
 
uint64_t get_next_frame () const override
 Get next frame execution time (graphics domain)
 
void set_next_frame (uint64_t) override
 Set next frame execution time (graphics domain)
 
bool is_active () const override
 Checks if the coroutine is still active.
 
bool initialize_state (uint64_t=0U) override
 Initializes the coroutine's state for execution.
 
bool try_resume (uint64_t) override
 Attempts to resume the coroutine if it's ready to execute.
 
bool restart () override
 Restarts the coroutine from the beginning.
 
uint64_t next_execution () const override
 Gets the sample position when this routine should next execute.
 
- Public Member Functions inherited from MayaFlux::Vruta::Routine
virtual ~Routine ()=default
 Destructor.
 
virtual bool try_resume_with_context (uint64_t current_value, DelayContext)
 Attempts to resume the coroutine with explicit temporal context.
 
virtual DelayContext get_delay_context () const
 Get the active delay context for this routine.
 
virtual void set_delay_context (DelayContext)
 Set the active delay context for this routine.
 
template<typename... Args>
void update_params (Args... args)
 Updates multiple named parameters in the coroutine's state.
 
template<typename T >
void set_state (const std::string &key, T value)
 Sets a named state value in the coroutine.
 
template<typename T >
T * get_state (const std::string &key)
 Gets a named state value from the coroutine.
 

Protected Member Functions

void set_state_impl (const std::string &, std::any) override
 
void * get_state_impl_raw (const std::string &) override
 
- Protected Member Functions inherited from MayaFlux::Vruta::Routine
template<typename T >
T * get_state_impl (const std::string &key)
 Implementation helper for get_state.
 
virtual void update_params_impl ()
 brief Implementation helper for update_params
 
template<typename T , typename... Args>
void update_params_impl (const std::string &key, T value, Args... args)
 Implementation helper for update_params.
 

Private Attributes

ProcessingToken m_primary_token = ProcessingToken::SAMPLE_ACCURATE
 
std::vector< ProcessingTokenm_secondary_tokens
 

Detailed Description

Multi-domain coroutine that can handle multiple processing rates.

ComplexRoutine is designed for coroutines that need to operate across multiple processing domains (audio + visual, for example). It automatically selects the fastest processing rate and manages cross-domain synchronization.

Definition at line 654 of file Routine.hpp.


The documentation for this class was generated from the following file: