Loading...
Searching...
No Matches
TimeSyncExecution.hpp
1#pragma once
2#include <Process/ExecutionComponent.hpp>
3
4#include <ossia/editor/expression/expression.hpp>
5
6#include <score_plugin_scenario_export.h>
7namespace ossia
8{
9class time_sync;
10struct time_value;
11}
12namespace Scenario
13{
14class TimeSyncModel;
15}
16
17namespace Execution
18{
19class SCORE_PLUGIN_SCENARIO_EXPORT TimeSyncComponent final : public Execution::Component
20{
21 COMMON_COMPONENT_METADATA("eca86942-002e-4af5-ad3d-cb1615e0552c")
22public:
23 static const constexpr bool is_unique = true;
25 const Scenario::TimeSyncModel& element, const Execution::Context& ctx,
26 QObject* parent);
27
28 void cleanup();
29
31 ossia::expression_ptr makeTrigger() const;
32
34 void onSetup(std::shared_ptr<ossia::time_sync> ptr, ossia::expression_ptr exp);
35
36 std::shared_ptr<ossia::time_sync> OSSIATimeSync() const;
37 const Scenario::TimeSyncModel& scoreTimeSync() const;
38
39private:
40 void updateTrigger();
41 void updateTriggerTime();
42 void on_GUITrigger();
43 std::shared_ptr<ossia::time_sync> m_ossia_node;
44 QPointer<const Scenario::TimeSyncModel> m_score_node;
45};
46}
Definition TimeSyncExecution.hpp:20
Definition TimeSyncModel.hpp:34
A component that has a reference to a specific context object.
Definition lib/score/model/Component.hpp:58
Components used for the execution of a score.
Definition ProcessComponent.cpp:12
Main plug-in of score.
Definition score-plugin-dataflow/Dataflow/PortItem.hpp:13
Definition ExecutionContext.hpp:76