Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/compositor/intern/COM_NodeGraph.h')
-rw-r--r--source/blender/compositor/intern/COM_NodeGraph.h26
1 files changed, 8 insertions, 18 deletions
diff --git a/source/blender/compositor/intern/COM_NodeGraph.h b/source/blender/compositor/intern/COM_NodeGraph.h
index 7252d546fce..990e3a30831 100644
--- a/source/blender/compositor/intern/COM_NodeGraph.h
+++ b/source/blender/compositor/intern/COM_NodeGraph.h
@@ -18,6 +18,8 @@
#pragma once
+#include "BLI_vector.hh"
+
#include <map>
#include <set>
#include <vector>
@@ -39,33 +41,21 @@ class NodeOutput;
*/
class NodeGraph {
public:
- class Link {
- private:
- NodeOutput *m_from;
- NodeInput *m_to;
-
- public:
- Link(NodeOutput *from, NodeInput *to) : m_from(from), m_to(to)
- {
- }
+ struct Link {
+ NodeOutput *from;
+ NodeInput *to;
- NodeOutput *getFromSocket() const
- {
- return m_from;
- }
- NodeInput *getToSocket() const
+ Link(NodeOutput *from, NodeInput *to) : from(from), to(to)
{
- return m_to;
}
};
typedef std::vector<Node *> Nodes;
typedef Nodes::iterator NodeIterator;
- typedef std::vector<Link> Links;
private:
Nodes m_nodes;
- Links m_links;
+ blender::Vector<Link> m_links;
public:
NodeGraph();
@@ -75,7 +65,7 @@ class NodeGraph {
{
return m_nodes;
}
- const Links &links() const
+ const blender::Vector<Link> &links() const
{
return m_links;
}