LMMS
Loading...
Searching...
No Matches
juce_MPENote.h
Go to the documentation of this file.
1/*
2 ==============================================================================
3
4 This file is part of the JUCE library.
5 Copyright (c) 2022 - Raw Material Software Limited
6
7 JUCE is an open source library subject to commercial or open-source
8 licensing.
9
10 The code included in this file is provided under the terms of the ISC license
11 http://www.isc.org/downloads/software-support-policy/isc-license. Permission
12 To use, copy, modify, and/or distribute this software for any purpose with or
13 without fee is hereby granted provided that the above copyright notice and
14 this permission notice appear in all copies.
15
16 JUCE IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL WARRANTIES, WHETHER
17 EXPRESSED OR IMPLIED, INCLUDING MERCHANTABILITY AND FITNESS FOR PURPOSE, ARE
18 DISCLAIMED.
19
20 ==============================================================================
21*/
22
23namespace juce
24{
25
26//==============================================================================
40{
41 //==============================================================================
44 {
45 off = 0,
46 keyDown = 1,
49 };
50
51 //==============================================================================
72 MPENote (int midiChannel,
73 int initialNote,
74 MPEValue velocity,
75 MPEValue pitchbend,
76 MPEValue pressure,
77 MPEValue timbre,
78 KeyState keyState = MPENote::keyDown) noexcept;
79
87
89 bool isValid() const noexcept;
90
91 //==============================================================================
92 // Invariants that define the note.
93
99
104
109
110 //==============================================================================
111 // The five dimensions of continuous expressive control
112
117
129
134
139
145
153
154 //==============================================================================
165
170
171 //==============================================================================
175 double getFrequencyInHertz (double frequencyOfA = 440.0) const noexcept;
176
178 bool operator== (const MPENote& other) const noexcept;
179
181 bool operator!= (const MPENote& other) const noexcept;
182};
183
184} // namespace juce
#define noexcept
Definition DistrhoDefines.h:72
Definition juce_MPEValue.h:37
static MPEValue centreValue() noexcept
Definition juce_MPEValue.cpp:60
static MPEValue minValue() noexcept
Definition juce_MPEValue.cpp:59
#define JUCE_API
Definition juce_StandardHeader.h:152
Definition carla_juce.cpp:31
unsigned short uint16
Definition juce_MathsFunctions.h:41
unsigned char uint8
Definition juce_MathsFunctions.h:37
Definition juce_MPENote.h:40
KeyState
Definition juce_MPENote.h:44
@ keyDown
Definition juce_MPENote.h:46
@ off
Definition juce_MPENote.h:45
@ keyDownAndSustained
Definition juce_MPENote.h:48
@ sustained
Definition juce_MPENote.h:47
uint16 noteID
Definition juce_MPENote.h:98
MPEValue noteOnVelocity
Definition juce_MPENote.h:116
MPEValue timbre
Definition juce_MPENote.h:144
MPEValue pitchbend
Definition juce_MPENote.h:128
uint8 initialNote
Definition juce_MPENote.h:108
MPEValue pressure
Definition juce_MPENote.h:133
MPEValue initialTimbre
Definition juce_MPENote.h:138
double totalPitchbendInSemitones
Definition juce_MPENote.h:164
uint8 midiChannel
Definition juce_MPENote.h:103
MPEValue noteOffVelocity
Definition juce_MPENote.h:152
KeyState keyState
Definition juce_MPENote.h:169
MPENote(int midiChannel, int initialNote, MPEValue velocity, MPEValue pitchbend, MPEValue pressure, MPEValue timbre, KeyState keyState=MPENote::keyDown) noexcept
Definition juce_MPENote.cpp:38
#define const
Definition zconf.h:137