23 std::vector<ExecutionCommand> commands;
30 : context{other.context}
31 , commands(std::move(other.commands))
37 commands = std::move(other.commands);
43 if(commands.capacity() > 0)
45 OSSIA_ENSURE_CURRENT_THREAD_KIND(ossia::thread_type::Ui);
49 void reserve(std::size_t sz)
noexcept { commands.reserve(sz); }
50 bool empty()
const noexcept {
return commands.empty(); }
52 void push_back(T&& t)
noexcept
54 commands.emplace_back(std::move(t));
59 OSSIA_ENSURE_CURRENT_THREAD_KIND(ossia::thread_type::Ui);
61 [t = std::move(*
this)]()
mutable { t.run_all_in_exec(); });
69 OSSIA_ENSURE_CURRENT_THREAD_KIND(ossia::thread_type::Ui);
70 for(
auto& cmd : commands)
74 void run_all_in_exec()
76 OSSIA_ENSURE_CURRENT_THREAD_KIND(ossia::thread_type::Audio);
77 for(
auto& cmd : commands)
Definition ExecutionContext.hpp:196
ExecutionCommandQueue & executionQueue
Definition ExecutionContext.hpp:242