Changeset View
Changeset View
Standalone View
Standalone View
source/blender/nodes/NOD_node_tree_ref.hh
| Show First 20 Lines • Show All 119 Lines • ▼ Show 20 Lines | public: | ||||
| StringRefNull identifier() const; | StringRefNull identifier() const; | ||||
| bNodeSocketType *typeinfo() const; | bNodeSocketType *typeinfo() const; | ||||
| bNodeSocket *bsocket() const; | bNodeSocket *bsocket() const; | ||||
| bNode *bnode() const; | bNode *bnode() const; | ||||
| bNodeTree *btree() const; | bNodeTree *btree() const; | ||||
| bool is_available() const; | bool is_available() const; | ||||
| bool is_undefined() const; | |||||
| void *default_value() const; | void *default_value() const; | ||||
| template<typename T> T *default_value() const; | template<typename T> T *default_value() const; | ||||
| }; | }; | ||||
| class InputSocketRef final : public SocketRef { | class InputSocketRef final : public SocketRef { | ||||
| public: | public: | ||||
| friend NodeTreeRef; | friend NodeTreeRef; | ||||
| ▲ Show 20 Lines • Show All 56 Lines • ▼ Show 20 Lines | public: | ||||
| int id() const; | int id() const; | ||||
| bool is_reroute_node() const; | bool is_reroute_node() const; | ||||
| bool is_group_node() const; | bool is_group_node() const; | ||||
| bool is_group_input_node() const; | bool is_group_input_node() const; | ||||
| bool is_group_output_node() const; | bool is_group_output_node() const; | ||||
| bool is_muted() const; | bool is_muted() const; | ||||
| bool is_frame() const; | bool is_frame() const; | ||||
| bool is_undefined() const; | |||||
| void *storage() const; | void *storage() const; | ||||
| template<typename T> T *storage() const; | template<typename T> T *storage() const; | ||||
| }; | }; | ||||
| class LinkRef : NonCopyable, NonMovable { | class LinkRef : NonCopyable, NonMovable { | ||||
| private: | private: | ||||
| OutputSocketRef *from_; | OutputSocketRef *from_; | ||||
| ▲ Show 20 Lines • Show All 47 Lines • ▼ Show 20 Lines | public: | ||||
| Span<const SocketRef *> sockets() const; | Span<const SocketRef *> sockets() const; | ||||
| Span<const InputSocketRef *> input_sockets() const; | Span<const InputSocketRef *> input_sockets() const; | ||||
| Span<const OutputSocketRef *> output_sockets() const; | Span<const OutputSocketRef *> output_sockets() const; | ||||
| Span<const LinkRef *> links() const; | Span<const LinkRef *> links() const; | ||||
| bool has_link_cycles() const; | bool has_link_cycles() const; | ||||
| bool has_undefined_nodes_or_sockets() const; | |||||
| bNodeTree *btree() const; | bNodeTree *btree() const; | ||||
| StringRefNull name() const; | StringRefNull name() const; | ||||
| std::string to_dot() const; | std::string to_dot() const; | ||||
| private: | private: | ||||
| /* Utility functions used during construction. */ | /* Utility functions used during construction. */ | ||||
| ▲ Show 20 Lines • Show All 141 Lines • ▼ Show 20 Lines | inline bNodeTree *SocketRef::btree() const | ||||
| return node_->btree(); | return node_->btree(); | ||||
| } | } | ||||
| inline bool SocketRef::is_available() const | inline bool SocketRef::is_available() const | ||||
| { | { | ||||
| return (bsocket_->flag & SOCK_UNAVAIL) == 0; | return (bsocket_->flag & SOCK_UNAVAIL) == 0; | ||||
| } | } | ||||
| inline bool SocketRef::is_undefined() const | |||||
| { | |||||
| return bsocket_->typeinfo == &NodeSocketTypeUndefined; | |||||
| } | |||||
| inline void *SocketRef::default_value() const | inline void *SocketRef::default_value() const | ||||
| { | { | ||||
| return bsocket_->default_value; | return bsocket_->default_value; | ||||
| } | } | ||||
| template<typename T> inline T *SocketRef::default_value() const | template<typename T> inline T *SocketRef::default_value() const | ||||
| { | { | ||||
| return (T *)bsocket_->default_value; | return (T *)bsocket_->default_value; | ||||
| ▲ Show 20 Lines • Show All 121 Lines • ▼ Show 20 Lines | inline bool NodeRef::is_group_output_node() const | ||||
| return bnode_->type == NODE_GROUP_OUTPUT; | return bnode_->type == NODE_GROUP_OUTPUT; | ||||
| } | } | ||||
| inline bool NodeRef::is_frame() const | inline bool NodeRef::is_frame() const | ||||
| { | { | ||||
| return bnode_->type == NODE_FRAME; | return bnode_->type == NODE_FRAME; | ||||
| } | } | ||||
| inline bool NodeRef::is_undefined() const | |||||
| { | |||||
| return bnode_->typeinfo == &NodeTypeUndefined; | |||||
| } | |||||
| inline bool NodeRef::is_muted() const | inline bool NodeRef::is_muted() const | ||||
| { | { | ||||
| return (bnode_->flag & NODE_MUTED) != 0; | return (bnode_->flag & NODE_MUTED) != 0; | ||||
| } | } | ||||
| inline void *NodeRef::storage() const | inline void *NodeRef::storage() const | ||||
| { | { | ||||
| return bnode_->storage; | return bnode_->storage; | ||||
| ▲ Show 20 Lines • Show All 101 Lines • Show Last 20 Lines | |||||