comparison src/Analyser.h @ 184:ea15fa75ae6f

Ctrl+Return now switches the alternate pitch candidates on and off; Ctrl+Up/Down selects among them
author Chris Cannam
date Sun, 23 Feb 2014 17:59:23 +0000
parents e33f9d052503
children 800e65412473
comparison
equal deleted inserted replaced
183:bdee9e6f135b 184:ea15fa75ae6f
89 * success or a user-readable error string on failure. 89 * success or a user-readable error string on failure.
90 */ 90 */
91 QString reAnalyseSelection(Selection sel); 91 QString reAnalyseSelection(Selection sel);
92 92
93 /** 93 /**
94 * Return true if the analysed pitch candidates are currently
95 * visible (by default they are hidden after construction until
96 * the user requests them). Note that the shown/hidden state is
97 * independent of whether any pitch candidates actually exist --
98 * it's possible they might be shown but not have been created yet
99 * because creation (through reAnalyseSelection) is asynchronous.
100 */
101 bool arePitchCandidatesShown() const;
102
103 /**
104 * Show or hide the analysed pitch candidate layers. As in
105 * arePitchCandidatesShown, this is independent of whether the
106 * candidate layers actually exist. Call reAnalyseSelection to
107 * schedule creation of those layers.
108 */
109 void showPitchCandidates(bool shown);
110
111 /**
94 * If a re-analysis has been activated, switch the selected area 112 * If a re-analysis has been activated, switch the selected area
95 * of the main pitch track to a different candidate from the 113 * of the main pitch track to a different candidate from the
96 * analysis results. 114 * analysis results.
97 */ 115 */
98 void switchPitchCandidate(Selection sel, bool up); 116 void switchPitchCandidate(Selection sel, bool up);
99 117
100 /** 118 /**
101 * Remove the pitch estimates from the selected area of the main 119 * Delete the pitch estimates from the selected area of the main
102 * pitch track. 120 * pitch track.
103 */ 121 */
104 void clearPitches(Selection sel); 122 void deletePitches(Selection sel);
105 123
106 /** 124 /**
107 * Move the main pitch track and any active analysis candidate 125 * Move the main pitch track and any active analysis candidate
108 * tracks up or down an octave in the selected area. 126 * tracks up or down an octave in the selected area.
109 */ 127 */
140 mutable std::map<Component, Layer *> m_layers; 158 mutable std::map<Component, Layer *> m_layers;
141 159
142 Selection m_reAnalysingSelection; 160 Selection m_reAnalysingSelection;
143 std::vector<Layer *> m_reAnalysisCandidates; 161 std::vector<Layer *> m_reAnalysisCandidates;
144 int m_currentCandidate; 162 int m_currentCandidate;
163 bool m_candidatesVisible;
145 164
146 QString addVisualisations(); 165 QString addVisualisations();
147 QString addWaveform(); 166 QString addWaveform();
148 QString addAnalyses(); 167 QString addAnalyses();
149 168