Zrythm v2.0.0-DEV
a highly automated and intuitive digital audio workstation
Loading...
Searching...
No Matches
transport_controller.h
1// SPDX-FileCopyrightText: © 2026 Alexandros Theodotou <alex@zrythm.org>
2// SPDX-License-Identifier: LicenseRef-ZrythmLicense
3
4#pragma once
5
6#include "controllers/recording_mode.h"
7
8#include <QObject>
9#include <QtQmlIntegration/qqmlintegration.h>
10
11namespace zrythm::dsp
12{
13class Transport;
14class SnapGrid;
15}
16
17namespace zrythm::controllers
18{
19
25class TransportController : public QObject
26{
27 Q_OBJECT
28 QML_ELEMENT
29 QML_UNCREATABLE ("")
30 QML_EXTENDED_NAMESPACE (zrythm::controllers::recording)
31
32public:
33 explicit TransportController (
34 dsp::Transport &transport,
35 dsp::SnapGrid &snap_grid,
36 QObject * parent = nullptr);
37
41 Q_INVOKABLE void moveBackward () [[clang::blocking]];
42
46 Q_INVOKABLE void moveForward () [[clang::blocking]];
47
48private:
49 dsp::Transport &transport_;
50 dsp::SnapGrid &snap_grid_;
51};
52
53} // namespace zrythm::controllers
Q_INVOKABLE void moveForward()
Moves the playhead forward to the next snap point.
Q_INVOKABLE void moveBackward()
Moves the playhead backward to the previous snap point.
Snap/grid information.
Definition snap_grid.h:23
The Transport class represents the transport controls and state for an audio engine.
Definition transport.h:45