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
+26
View File
@@ -0,0 +1,26 @@
#ifndef NODEEDGEUI_H
#define NODEEDGEUI_H
#include <QGraphicsPathItem>
#include "nodeui.h"
class NodeEdgeUI : public QGraphicsPathItem {
public:
NodeEdgeUI(NodeEdge* edge);
static QPainterPath GetEdgePath(const QPointF& start_pos, const QPointF& end_pos);
void adjust();
NodeEdge* edge();
private:
NodeEdge* edge_;
NodeUI* output_node_;
int output_index_;
NodeUI* input_node_;
int input_index_;
};
#endif // NODEEDGEUI_H