nodes can now be connected through the node editor

This commit is contained in:
itsmattkc
2019-04-13 02:40:58 +10:00
parent 6b67727bd8
commit 8cd96eae64
24 changed files with 480 additions and 85 deletions
+1 -1
View File
@@ -7,7 +7,7 @@ BoolInput::BoolInput(Node* parent, const QString& id, const QString& name, bool
connect(bool_field, SIGNAL(Toggled(bool)), this, SIGNAL(Toggled(bool)));
AddField(bool_field);
AddNodeInput(olive::nodes::kBoolean);
AddAcceptedNodeInput(olive::nodes::kBoolean);
}
bool BoolInput::GetBoolAt(double timecode)
+1 -1
View File
@@ -5,7 +5,7 @@ ColorInput::ColorInput(Node* parent, const QString& id, const QString& name, boo
{
AddField(new ColorField(this));
AddNodeInput(olive::nodes::kColor);
AddAcceptedNodeInput(olive::nodes::kColor);
}
QColor ColorInput::GetColorAt(double timecode)
+1 -1
View File
@@ -7,7 +7,7 @@ ComboInput::ComboInput(Node* parent, const QString& id, const QString& name, boo
connect(combo_field, SIGNAL(DataChanged(const QVariant&)), this, SIGNAL(DataChanged(const QVariant&)));
AddField(combo_field);
AddNodeInput(olive::nodes::kCombo);
AddAcceptedNodeInput(olive::nodes::kCombo);
}
void ComboInput::AddItem(const QString &text, const QVariant &data)
+1 -1
View File
@@ -5,7 +5,7 @@ FileInput::FileInput(Node* parent, const QString& id, const QString& name, bool
{
AddField(new FileField(this));
AddNodeInput(olive::nodes::kFile);
AddAcceptedNodeInput(olive::nodes::kFile);
}
QString FileInput::GetFileAt(double timecode)
+1 -1
View File
@@ -5,7 +5,7 @@ FontInput::FontInput(Node* parent, const QString& id, const QString& name, bool
{
AddField(new FontField(this));
AddNodeInput(olive::nodes::kFont);
AddAcceptedNodeInput(olive::nodes::kFont);
}
QString FontInput::GetFontAt(double timecode)
+1 -1
View File
@@ -5,7 +5,7 @@ StringInput::StringInput(Node* parent, const QString& id, const QString& name, b
{
AddField(new StringField(this, rich_text));
AddNodeInput(olive::nodes::kString);
AddAcceptedNodeInput(olive::nodes::kString);
}
QString StringInput::GetStringAt(double timecode)
+4 -4
View File
@@ -15,15 +15,15 @@ VecInput::VecInput(Node* parent, const QString& id, const QString& name, int val
AddField(new DoubleField(this));
}
AddNodeInput(olive::nodes::kFloat);
AddAcceptedNodeInput(olive::nodes::kFloat);
if (values > 1) {
AddNodeInput(olive::nodes::kVec2);
AddAcceptedNodeInput(olive::nodes::kVec2);
}
if (values > 2) {
AddNodeInput(olive::nodes::kVec3);
AddAcceptedNodeInput(olive::nodes::kVec3);
}
if (values > 3) {
AddNodeInput(olive::nodes::kVec4);
AddAcceptedNodeInput(olive::nodes::kVec4);
}
}