summaryrefslogtreecommitdiff
path: root/src/gpu
diff options
context:
space:
mode:
Diffstat (limited to 'src/gpu')
-rw-r--r--src/gpu/gpu.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/gpu/gpu.cc b/src/gpu/gpu.cc
index f968306..fde241d 100644
--- a/src/gpu/gpu.cc
+++ b/src/gpu/gpu.cc
@@ -403,4 +403,13 @@ void gpu_shutdown() {
void gpu_simulate_until(float time, float bpm) {
g_main_sequence.simulate_until(time, 1.0f / 60.0f, bpm);
}
+
+void gpu_add_custom_effect(Effect* effect, float start_time, float end_time,
+ int priority) {
+ auto seq = std::make_shared<Sequence>();
+ seq->init(&g_main_sequence);
+ seq->add_effect(std::shared_ptr<Effect>(effect), 0.0f, end_time - start_time,
+ priority);
+ g_main_sequence.add_sequence(seq, start_time, priority);
+}
#endif