Node graph editor framework focused on data processing using Unity UIElements, GraphView and C# 4.7
This node based solution provides a great C# API allowing you to implement conditional graphs, dependencies graphs, processing graphs and more.
Based on Unity's GraphView technology, NodeGraphProcessor is also very fast and works well with large graphs.
Simple and powerful C# node API to create new nodes and custom views.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using GraphProcessor;
using System.Linq;
[System.Serializable, NodeMenuItem("Operations/Sub")] // Add the node in the node creation context menu
public class SubNode : BaseNode
{
[Input(name = "A")]
public float inputA;
[Input(name = "B")]
public float inputB;
[Output(name = "Out")]
public float output;
public override string name => "Sub";
// Called when the graph is process, process inputs and assign the result in output.
protected override void Process()
{
output = inputA - inputB;
}
}
This project requires at least Unity 2020.2 with a scripting runtime version of 4.x in player settings.
The current Unity version used for the project is 2020.2.0f1, if you want to install NodeGraphProcessor in an older unity project, you can install it via Open UPM (minimum version: Unity 2019.3).
There are two ways to install this asset: you can use the Unity package manager or move the entire repo inside your Assets folder. To install using the package manager:
Assets/NodeGraphProcessor
The package is available on the openupm registry. It's recommended to install it via openupm-cli.
openupm add com.alelievr.node-graph-processor
Alternatively, you can use the git address feature in the package manager on the branch #upm, it only contains the package but it may be out of sync compared to master.
Note that you'll not have access to the examples provided in this repo because the package only include the core of NodeGraphProcessor.
More details are available in the Changelog
API doc is available here: alelievr.github.io/NodeGraphProcessor
The user manual is hosted using Github Wiki.
For more details consult our Github Project page.
Want to be in the made with list? Send a message to the issue #14
Just add this bit of code in your Node script to make it renamable in the UI.
public override bool isRenamable => true;
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。