tracktion-engine 3.0-10-g034fdde4aa5
Tracktion Engine — High level data model for audio applications

« « « Anklang Documentation
Loading...
Searching...
No Matches
tracktion_MidiSysexEvent.h
Go to the documentation of this file.
1 /*
2 ,--. ,--. ,--. ,--.
3 ,-' '-.,--.--.,--,--.,---.| |,-.,-' '-.`--' ,---. ,--,--, Copyright 2024
4 '-. .-'| .--' ,-. | .--'| /'-. .-',--.| .-. || \ Tracktion Software
5 | | | | \ '-' \ `--.| \ \ | | | |' '-' '| || | Corporation
6 `---' `--' `--`--'`---'`--'`--' `---' `--' `---' `--''--' www.tracktion.com
7
8 Tracktion Engine uses a GPL/commercial licence - see LICENCE.md for details.
9*/
10
11namespace tracktion { inline namespace engine
12{
13
15{
16public:
17 static juce::ValueTree createSysexEvent (const MidiSysexEvent&, BeatPosition);
18 static juce::ValueTree createSysexEvent (const juce::MidiMessage&, BeatPosition);
19
23 ~MidiSysexEvent() noexcept {}
24
25 //==============================================================================
26 const juce::MidiMessage& getMessage() const noexcept { return message; }
27 void setMessage (const juce::MidiMessage&, juce::UndoManager*);
28
29 //==============================================================================
30 BeatPosition getBeatPosition() const noexcept { return BeatPosition::fromBeats (message.getTimeStamp()); }
31 void setBeatPosition (BeatPosition, juce::UndoManager*);
32
33 // takes into account quantising, groove templates, clip offset, etc
34 TimePosition getEditTime (const MidiClip&) const;
35 BeatPosition getEditBeats (const MidiClip&) const;
36
37 juce::ValueTree state;
38
39private:
40 //==============================================================================
41 friend class MidiList;
42 juce::MidiMessage message;
43
44 void updateMessage();
45 void updateTime();
46
47 MidiSysexEvent() = delete;
48 MidiSysexEvent (const MidiSysexEvent&) = delete;
49
51};
52
53}} // namespace tracktion { inline namespace engine
double getTimeStamp() const noexcept
#define JUCE_LEAK_DETECTOR(OwnerClass)
Represents a position in beats.
Represents a position in real-life time.