diff options
author | Loek Le Blansch <loek@pipeframe.xyz> | 2024-06-12 20:40:29 +0200 |
---|---|---|
committer | Loek Le Blansch <loek@pipeframe.xyz> | 2024-06-12 20:40:29 +0200 |
commit | 068a4971084bd1e415c6523c3b5eb5a48de520ca (patch) | |
tree | dfadac49c27f22dc0ada6dcfa464be99afb1827b /NodeInput.cpp | |
parent | 9270528a26cfd9f19d79519a61712c9d2f426106 (diff) |
fix NodeInput stuff
Diffstat (limited to 'NodeInput.cpp')
-rw-r--r-- | NodeInput.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/NodeInput.cpp b/NodeInput.cpp index 2fae505..6ee0db4 100644 --- a/NodeInput.cpp +++ b/NodeInput.cpp @@ -1,25 +1,25 @@ #include "NodeInput.h" #include "prut.h" - -NodeInput NodeInput::instance(NodeInput::type); NodeInputLow NodeInputLow::instance(NodeInputLow::type); NodeInputHigh NodeInputHigh::instance(NodeInputHigh::type); -NodeInput::NodeInput(const NodeInput * prototype) : Node() { } - -NodeInput * NodeInput::clone() const { - return new NodeInput(this); +NodeInput::NodeInput() { + this->max_inputs = -1; + this->max_inputs = 0; } -SignalLevel NodeInput::level() { - prutprint("BaseInput"); - return UNDEFINED; +NodeInputLow * NodeInputLow::clone() const { + return new NodeInputLow(this); } SignalLevel NodeInputLow::level() { prutprint("LOW"); return LOW; } + +NodeInputHigh * NodeInputHigh::clone() const { + return new NodeInputHigh(this); +} SignalLevel NodeInputHigh::level() { prutprint("HIGH"); return HIGH; |