Loading...
Searching...
No Matches
oscr::Executor< Node > Class Template Referencefinal
Inheritance diagram for oscr::Executor< Node >:
Execution::ProcessComponent_T< ProcessModel< Node >, ossia::node_process > oscr::dynamic_ports_component_data< Node > Process::GenericProcessComponent_T< ProcessComponentBase_T, Process_T >

Public Member Functions

UuidKey< score::Componentkey () const noexcept final override
 
bool key_match (UuidKey< score::Component > other) const noexcept final override
 
 Executor (ProcessModel< Node > &element, const ::Execution::Context &ctx, QObject *p)
 
void setup_cpu (ProcessModel< Node > &element, const ::Execution::Context &ctx, QObject *p)
 
void setup_gpu (ProcessModel< Node > &element, const ::Execution::Context &ctx, QObject *p)
 
void recompute_ports ()
 
void connect_controls (ProcessModel< Node > &element, const ::Execution::Context &ctx, std::shared_ptr< safe_node< Node > > &ptr)
 
void setup_soundfile_task_pool (ProcessModel< Node > &element, const ::Execution::Context &ctx, std::shared_ptr< safe_node< Node > > &ptr)
 
void connect_dynamic_items (ProcessModel< Node > &element, Node &eff)
 
void connect_message_bus (ProcessModel< Node > &element, const ::Execution::Context &ctx, Node &eff)
 
void connect_worker (const ::Execution::Context &ctx, avnd::effect_container< Node > &eff)
 
void update_controls (std::shared_ptr< safe_node< Node > > &ptr)
 
void cleanup () override
 
- Public Member Functions inherited from Execution::ProcessComponent_T< ProcessModel< Node >, ossia::node_process >
ossia::node_process & OSSIAProcess () const
 
- Public Member Functions inherited from Process::GenericProcessComponent_T< ProcessComponentBase_T, Process_T >
Process_T & process () const
 

Static Public Member Functions

static Q_DECL_RELAXED_CONSTEXPR UuidKey< score::Componentstatic_key () noexcept
 

Additional Inherited Members

- Public Types inherited from Process::GenericProcessComponent_T< ProcessComponentBase_T, Process_T >
using model_type = Process_T
 

Member Function Documentation

◆ recompute_ports()

template<typename Node >
void oscr::Executor< Node >::recompute_ports ( )
inline

The model's ports changed (a dynamic port group was resized): rebuild the exec node's port list to match, without replacing the node.

Everything that allocates happens here, in the main thread; the exec thread only swaps the new port vectors in. Order of the transaction:

  1. disconnect the edges of the cables of this process,
  2. unregister the old exec ports from the execution state,
  3. swap the new ports into the node (previous ones go back to be freed in the main thread),
  4. register the new exec ports, with their addresses,
  5. reconnect the cables against the new ports. Then the UI -> exec connection is made for the control inlets that appeared.

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