3#include <ossia/detail/config.hpp>
5#include <ossia/dataflow/token_request.hpp>
26#if defined(OSSIA_SCENARIO_DATAFLOW)
27 std::shared_ptr<ossia::graph_node> node;
45 virtual void state(
const ossia::token_request&) = 0;
77 virtual void resume();
90 [[nodiscard]]
bool unmuted()
const;
102 [[nodiscard]]
bool enabled()
const;
107 void set_loops(
bool b);
123 virtual void mute_impl(
bool);
130 bool m_loops =
false;
131 bool m_unmuted =
true;
132 bool m_enabled =
true;
136class looping_process :
public time_process
139 using time_process::time_process;
140 void state(
const ossia::token_request& tok)
override
144 if(this->m_start_offset == 0_tv)
145 static_cast<T*
>(
this)->state_impl(tok);
147 static_cast<T*
>(
this)->state_impl(tok.add_offset(this->m_start_offset));
152 this->m_start_offset, this->m_loop_duration,
153 [
this](
const token_request& tr) {
static_cast<T*
>(
this)->state_impl(tr); },
154 [
this](
const time_value& t) {
static_cast<T*
>(
this)->transport_impl(t); });
159enum class sync_status
The time_process class.
Definition time_process.hpp:24
virtual void state(const ossia::token_request &)=0
get a #StateElement from the process depending on its parent #time_interval date
virtual ~time_process()
destructor
The time_value class.
Definition ossia/editor/scenario/time_value.hpp:30