mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2026-09-13 18:19:33 +00:00
Fixed the issues #3280
This commit is contained in:
@@ -72,6 +72,8 @@ class AudioSpectrumView : public View {
|
|||||||
|
|
||||||
class FrequencyScale : public Widget {
|
class FrequencyScale : public Widget {
|
||||||
public:
|
public:
|
||||||
|
/* Receives a frequency offset in Hz for key/touch selection. With live
|
||||||
|
* tuning enabled, encoder events instead pass the raw encoder delta. */
|
||||||
std::function<void(int32_t offset)> on_select{};
|
std::function<void(int32_t offset)> on_select{};
|
||||||
|
|
||||||
void on_show() override;
|
void on_show() override;
|
||||||
|
|||||||
@@ -51,6 +51,12 @@ bool FilteredSpectrumCollector::feed(
|
|||||||
sampling_rate_ = channel.sampling_rate / capture_decimation_;
|
sampling_rate_ = channel.sampling_rate / capture_decimation_;
|
||||||
capture_ready_ = true;
|
capture_ready_ = true;
|
||||||
EventDispatcher::events_flag(EVT_MASK_SPECTRUM);
|
EventDispatcher::events_flag(EVT_MASK_SPECTRUM);
|
||||||
|
if (is_streaming()) {
|
||||||
|
capture_ready_ = true;
|
||||||
|
EventDispatcher::events_flag(EVT_MASK_SPECTRUM);
|
||||||
|
} else {
|
||||||
|
capture_ready_ = false;
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@@ -51,6 +51,7 @@ class SpectrumCollector {
|
|||||||
const int32_t filter_transition);
|
const int32_t filter_transition);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
bool is_streaming() const { return streaming; }
|
||||||
void set_filter(
|
void set_filter(
|
||||||
const int32_t filter_low_frequency,
|
const int32_t filter_low_frequency,
|
||||||
const int32_t filter_high_frequency,
|
const int32_t filter_high_frequency,
|
||||||
|
|||||||
Reference in New Issue
Block a user