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
RecordingQualityBar Class Reference

Quality recording bar. More...

#include <recordingqualitybar.h>

+ Inheritance diagram for RecordingQualityBar:
+ Collaboration diagram for RecordingQualityBar:

Public Member Functions

 RecordingQualityBar (QWidget *parent=nullptr)
 Default constructor. More...
 
 ~RecordingQualityBar ()
 Empty destructor. More...
 
virtual QSize minimumSizeHint () const overridefinal
 Hint for the minimal widget size. More...
 
virtual QSize sizeHint () const overridefinal
 Hint for the optimal widget size. More...
 
- Public Member Functions inherited from MessageListener
 MessageListener (bool defaultActivation=true)
 
virtual ~MessageListener ()
 
bool isMessageListenerActive () const
 
void activateMessageListener ()
 
void deactivateMessageListener ()
 

Private Member Functions

void updateValue (float v)
 Function to update the current value. More...
 
virtual void handleMessage (MessagePtr m) overridefinal
 Message handling. More...
 
void paintEvent (QPaintEvent *event) overridefinal
 Reimplemented paint function that will draw the vertical text. More...
 

Detailed Description

Quality recording bar.

In the Signal-Analyzer panel the tuner application shows a vertical progress bar which indicates the quality of the recorded key. The quality is a number between 0 and 1 which is computed heuristically by the FFTAnalyzer and can be interpreted as a measure how nicely the observed partials match with the usual inharmonicity formula.

Definition at line 41 of file recordingqualitybar.h.

Constructor & Destructor Documentation

RecordingQualityBar::RecordingQualityBar ( QWidget *  parent = nullptr)

Default constructor.

Parameters
parent: The parent widget.

Definition at line 37 of file recordingqualitybar.cpp.

+ Here is the call graph for this function:

RecordingQualityBar::~RecordingQualityBar ( )
inline

Empty destructor.

Definition at line 56 of file recordingqualitybar.h.

Member Function Documentation

void RecordingQualityBar::handleMessage ( MessagePtr  m)
finaloverrideprivatevirtual

Message handling.

Parameters
m: The message.

Implements MessageListener.

Definition at line 109 of file recordingqualitybar.cpp.

+ Here is the call graph for this function:

QSize RecordingQualityBar::minimumSizeHint ( ) const
finaloverridevirtual

Hint for the minimal widget size.

Returns
QSize hint.

The minimum size is set by the minimum space the text requires.

Definition at line 60 of file recordingqualitybar.cpp.

void RecordingQualityBar::paintEvent ( QPaintEvent *  event)
finaloverrideprivate

Reimplemented paint function that will draw the vertical text.

Parameters
event: The QPaintEvent.

Definition at line 142 of file recordingqualitybar.cpp.

QSize RecordingQualityBar::sizeHint ( ) const
finaloverridevirtual

Hint for the optimal widget size.

Returns
QSize hint.

The optimal size is the minimuimSizeHint() with a small padding.

Definition at line 66 of file recordingqualitybar.cpp.

void RecordingQualityBar::updateValue ( float  v)
private

Function to update the current value.

RecordingQualityBar::updateValue.

Parameters
v: The new value to display

Update the quality measure bar. According to the argument v in the range from 0 to 1 the bar is filled from bottom to top. The color changes continuously with the value from red over orange to green.

Parameters
v: Quality between 0 and 1

Definition at line 87 of file recordingqualitybar.cpp.


The documentation for this class was generated from the following files: