Skip to content

Commit

Permalink
Split but otherwise leave unchaged FineTine and MainPan nodes (#195)
Browse files Browse the repository at this point in the history
in preparation for doing #119
  • Loading branch information
baconpaul authored Feb 1, 2025
1 parent a71a409 commit 515e7bf
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 9 deletions.
17 changes: 14 additions & 3 deletions src/synth/patch.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ struct Patch : pats::PatchBase<Patch, Param>
selfNodes(scpu::make_array_bind_first_index<SelfNode, numOps>()),
matrixNodes(scpu::make_array_bind_first_index<MatrixNode, matrixSize>()),
mixerNodes(scpu::make_array_bind_first_index<MixerNode, numOps>()),
macroNodes(scpu::make_array_bind_first_index<MacroNode, numMacros>()),
fineTuneMod("Fine Tune Mod", "Fine Tune", 0), mainPanMod("Main Pan Mod", "Main Pan", 1)
macroNodes(scpu::make_array_bind_first_index<MacroNode, numMacros>()), fineTuneMod(),
mainPanMod()
{
auto pushParams = [this](auto &from) { this->pushMultipleParams(from.params()); };

Expand Down Expand Up @@ -1053,6 +1053,16 @@ struct Patch : pats::PatchBase<Patch, Param>
}
};

struct FineTuneNode : ModulationOnlyNode
{
FineTuneNode() : ModulationOnlyNode("Fine Tune Mod", "Fine Tune", 0) {}
};

struct MainPanNode : ModulationOnlyNode
{
MainPanNode() : ModulationOnlyNode("Main Pan Mod", "Main Pan", 1) {}
};

struct OutputNode : public DAHDSRMixin, public ModulationMixin, public LFOMixin
{
static constexpr uint32_t idBase{500};
Expand Down Expand Up @@ -1318,7 +1328,8 @@ struct Patch : pats::PatchBase<Patch, Param>
std::array<MacroNode, numMacros> macroNodes;
OutputNode output;

ModulationOnlyNode fineTuneMod, mainPanMod;
FineTuneNode fineTuneMod;
MainPanNode mainPanMod;

char name[256]{"Init"};

Expand Down
6 changes: 3 additions & 3 deletions src/ui/finetune-sub-panel.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ namespace baconpaul::six_sines::ui
{
struct FineTuneSubPanel : juce::Component,
HasEditor,
DAHDSRComponents<FineTuneSubPanel, Patch::ModulationOnlyNode>,
LFOComponents<FineTuneSubPanel, Patch::ModulationOnlyNode>,
ModulationComponents<FineTuneSubPanel, Patch::ModulationOnlyNode>
DAHDSRComponents<FineTuneSubPanel, Patch::FineTuneNode>,
LFOComponents<FineTuneSubPanel, Patch::FineTuneNode>,
ModulationComponents<FineTuneSubPanel, Patch::FineTuneNode>
{
FineTuneSubPanel(SixSinesEditor &e);
~FineTuneSubPanel() = default;
Expand Down
6 changes: 3 additions & 3 deletions src/ui/mainpan-sub-panel.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ namespace baconpaul::six_sines::ui
{
struct MainPanSubPanel : juce::Component,
HasEditor,
DAHDSRComponents<MainPanSubPanel, Patch::ModulationOnlyNode>,
LFOComponents<MainPanSubPanel, Patch::ModulationOnlyNode>,
ModulationComponents<MainPanSubPanel, Patch::ModulationOnlyNode>
DAHDSRComponents<MainPanSubPanel, Patch::MainPanNode>,
LFOComponents<MainPanSubPanel, Patch::MainPanNode>,
ModulationComponents<MainPanSubPanel, Patch::MainPanNode>
{
MainPanSubPanel(SixSinesEditor &e);
~MainPanSubPanel() = default;
Expand Down

0 comments on commit 515e7bf

Please sign in to comment.