Vital
Loading...
Searching...
No Matches
reverb_section.h
Go to the documentation of this file.
1#pragma once
2
3#include "JuceHeader.h"
5#include "synth_section.h"
6
7class SynthButton;
8
18public:
20 static constexpr float kFeedbackFilterBuffer = 0.4f;
21
27 ReverbSection(String name, const vital::output_map& mono_modulations);
28
31
36 void paintBackground(Graphics& g) override;
37
42 void paintBackgroundShadow(Graphics& g) override { if (isActive()) paintTabShadow(g); }
43
47 void resized() override;
48
53 void setActive(bool active) override;
54
59 void sliderValueChanged(Slider* slider) override;
60
64 void lowBandSelected() override;
65
69 void midBandSelected() override { }
70
74 void highBandSelected() override;
75
76private:
77 std::unique_ptr<SynthButton> on_;
78 std::unique_ptr<EqualizerResponse> feedback_eq_response_;
79 std::unique_ptr<TabSelector> selected_eq_band_;
80 std::unique_ptr<SynthSlider> decay_time_;
81 std::unique_ptr<SynthSlider> low_pre_cutoff_;
82 std::unique_ptr<SynthSlider> high_pre_cutoff_;
83 std::unique_ptr<SynthSlider> low_cutoff_;
84 std::unique_ptr<SynthSlider> low_gain_;
85 std::unique_ptr<SynthSlider> high_cutoff_;
86 std::unique_ptr<SynthSlider> high_gain_;
87 std::unique_ptr<SynthSlider> chorus_amount_;
88 std::unique_ptr<SynthSlider> chorus_frequency_;
89 std::unique_ptr<SynthSlider> size_;
90 std::unique_ptr<SynthSlider> delay_;
91 std::unique_ptr<SynthSlider> dry_wet_;
92
93 JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(ReverbSection)
94};
Interface for objects that want to be notified when a band is selected.
Definition equalizer_response.h:36
A UI section for controlling and visualizing reverb parameters.
Definition reverb_section.h:17
void sliderValueChanged(Slider *slider) override
Called when a slider's value changes.
Definition reverb_section.cpp:172
~ReverbSection()
Destructor.
Definition reverb_section.cpp:89
void resized() override
Called when the component is resized. Arranges the sliders, buttons, and EQ visualization.
Definition reverb_section.cpp:109
void highBandSelected() override
Called when the high EQ band is selected in the EqualizerResponse.
Definition reverb_section.cpp:162
void midBandSelected() override
Called when the mid band is selected in the EqualizerResponse (unused in this section).
Definition reverb_section.h:69
static constexpr float kFeedbackFilterBuffer
Used to scale the feedback filter EQ buffer.
Definition reverb_section.h:20
void setActive(bool active) override
Sets the active state of this section.
Definition reverb_section.cpp:146
void paintBackgroundShadow(Graphics &g) override
Paints a background shadow if active.
Definition reverb_section.h:42
void lowBandSelected() override
Called when the low EQ band is selected in the EqualizerResponse.
Definition reverb_section.cpp:152
void paintBackground(Graphics &g) override
Paints the reverb section background, labels, and any custom UI elements.
Definition reverb_section.cpp:91
ReverbSection(String name, const vital::output_map &mono_modulations)
Constructs a ReverbSection.
Definition reverb_section.cpp:9
A specialized OpenGlToggleButton with additional functionality for the Vital synth.
Definition synth_button.h:450
Base class for all synthesizer sections, providing UI layout, painting, and interaction logic.
Definition synth_section.h:193
bool isActive() const
Checks if the section is currently active.
Definition synth_section.h:683
virtual void paintTabShadow(Graphics &g)
Paints a tab-like shadow effect around the component.
Definition synth_section.cpp:188
std::map< std::string, Output * > output_map
Maps parameter names to Output pointers, representing output signals from various modules.
Definition synth_types.h:229