2#include <ossia/dataflow/dataflow_fwd.hpp>
3#include <ossia/dataflow/graph_edge.hpp>
4#include <ossia/dataflow/transport.hpp>
5#include <ossia/detail/audio_spin_mutex.hpp>
6#include <ossia/detail/logger_fwd.hpp>
10#include <smallfun.hpp>
22class OSSIA_EXPORT graph_interface
26 virtual ~graph_interface();
27 virtual void add_node(ossia::node_ptr) = 0;
28 virtual void remove_node(
const ossia::node_ptr&) = 0;
29 virtual void connect(ossia::edge_ptr) = 0;
30 virtual void disconnect(
const ossia::edge_ptr&) = 0;
31 virtual void disconnect(ossia::graph_edge*) = 0;
32 virtual void mark_dirty() = 0;
34 virtual void state(execution_state& e) = 0;
36 virtual void clear() = 0;
38 virtual void print(std::ostream&) = 0;
40 [[nodiscard]]
virtual tcb::span<ossia::graph_node* const> get_nodes() const noexcept
43 std::shared_ptr<edge_pool> pool;
45 ossia::edge_ptr allocate_edge(
46 connection c, outlet_ptr pout, inlet_ptr pin, node_ptr pout_node,
50struct graph_setup_options
74 int parallel_threads = 8;
75 std::shared_ptr<ossia::logger_type> log{};
76 std::shared_ptr<bench_map> bench{};
79struct tick_setup_options
99std::shared_ptr<ossia::graph_interface> make_graph(
const graph_setup_options&);
spdlog::logger & logger() noexcept
Where the errors will be logged. Default is stderr.
Definition context.cpp:118
ossia::value_with_unit merge(const value_with_unit &vu, const ossia::value &val, ossia::destination_index idx)
merge Merge a computed value in a unit-aware value
Definition dataspace_visitors.cpp:311
std::ostream & print(std::ostream &out, const state_element &e)
print Print a state_element
Definition state_element.cpp:23