Entropy Piano Tuner  1.1.3 (documentation not yet complete)
An open-source experimental software for piano tuning by entropy minimization
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Go to the documentation of this file.
1 /*****************************************************************************
2  * Copyright 2015 Haye Hinrichsen, Christoph Wick
3  *
4  * This file is part of Entropy Piano Tuner.
5  *
6  * Entropy Piano Tuner is free software: you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by the
8  * Free Software Foundation, either version 3 of the License, or (at your
9  * option) any later version.
10  *
11  * Entropy Piano Tuner is distributed in the hope that it will be useful, but
12  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13  * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14  * more details.
15  *
16  * You should have received a copy of the GNU General Public License along with
17  * Entropy Piano Tuner. If not, see http://www.gnu.org/licenses/.
18  *****************************************************************************/
20 //======================================================================
21 // Class for a single message
22 //======================================================================
24 #ifndef MESSAGE_H
25 #define MESSAGE_H
27 #include <memory>
43 class Message
44 {
45 public:
48  {
49  // Bare messages without appended data
58  // Complex messages carrying data in associated message classes:
72  };
74 public:
81  explicit Message(MessageTypes type);
84  virtual ~Message();
88  MessageTypes getType() const {return mType;}
90 private:
95 };
98 typedef std::shared_ptr<Message> MessagePtr;
100 #endif // MESSAGE_H
const MessageTypes mType
Local variable holding the message type.
Definition: message.h:94
sent by SignalAnalyzer if FFT is ready
Definition: message.h:66
std::shared_ptr< Message > MessagePtr
Global type of a shared message pointer.
Definition: message.h:98
Available message types:
Definition: message.h:47
called when the recording was cleared
Definition: message.h:50
tuning deviation curve has been updated
Definition: message.h:71
data of a key changed
Definition: message.h:62
Message that a change was made with the current project file.
Definition: message.h:68
Message(MessageTypes type)
Message constructor.
Definition: message.cpp:28
sent by KeyRecognizer if final FFT is ready
Definition: message.h:61
Message that the operation mode has changed.
Definition: message.h:65
Message that a key has been selected.
Definition: message.h:63
recording input level has changed
Definition: message.h:69
analysis of the signal started
Definition: message.h:53
stroboscope message
Definition: message.h:70
number of the key recognized during recording
Definition: message.h:67
virtual ~Message()
Virtual destructor without function, can be overwritten in derived classes.
Definition: message.cpp:36
Message that progress of any kind was made by the calculator.
Definition: message.h:59
Message that the tuning curve has been adapted.
Definition: message.h:60
MessageTypes getType() const
Get the message type of the message object.
Definition: message.h:88
final key information after recording
Definition: message.h:55
The Message class.
Definition: message.h:43
new event from MIDI keyboard received
Definition: message.h:64
recording ended
Definition: message.h:52
settings in the system options changed
Definition: message.h:56
analysis of the signal ended
Definition: message.h:54
keystroke recognized and recording started
Definition: message.h:51