How cuernatra/emi-node-editor works
AO Emi is a C++ visual programming editor: users assemble node graphs, compile them to EMI-Script, and inspect behavior in a demo preview. The README documents the graph model, node registry, compiler, editor, and preview; the sampled preview code also shows graph-driven evaluation and drawing. The embedded EMI-Script parser and VM are included as runtime layers. Some connections are documented or visible only in the source index, so unsampled behavior is not expanded into unsupported call paths.
Main entry points: mainEditor.cpp Main Editor · nodeRenderer.cpp Node Renderer · VM.cpp Script VM · graphCompiler.cpp Graph Compiler
Components 21
Graph Editing
- App Loop
src/app/app.cpp - Editor Layout
src/app/editorLayout.cpp - Main Editor
src/editor/mainEditor.cpp - Graph State
src/editor/graph/graphState.h - Graph Canvas
src/editor/graph/graphEditor.cpp - Graph Serializer
src/editor/graph/graphSerializer.cpp - Node Renderer
src/editor/renderer/nodeRenderer.cpp - Field Widgets
src/editor/renderer/fieldWidgetRenderer.cpp - Pin Renderer
src/editor/renderer/pinRenderer.h
Graph Compilation
- Node Registry
src/core/registry/nodeRegistry.cpp - Node Definitions
src/core/registry/nodes/flowNodes.cpp - Graph Compiler
src/core/compiler/graphCompiler.cpp
Preview Runtime
- Graph Preview
src/editor/panels/graphPreviewPanel.cpp - Graph Executor
src/editor/graph/graphExecutor.cpp
EMI-Script Runtime
- EMI API
EMI-Script/include/EMI/EMI.h - Script Parser
EMI-Script/src/Parser/Parser.cpp - Script AST
EMI-Script/src/Parser/AST.h - Script VM
EMI-Script/src/VM.cpp - Script Functions
EMI-Script/src/Function.h - Script Namespaces
EMI-Script/src/Namespace.h
Other components
- Editor User
Connections 21
- Editor User → App Loop: uses
README.md - App Loop → Editor Layout: updates and renders
- Editor Layout → Main Editor: composes
- Main Editor → Graph State: uses
src/editor/mainEditor.cpp - Main Editor → Graph Canvas: uses
src/editor/mainEditor.cpp - Main Editor → Graph Serializer: uses
src/editor/mainEditor.cpp - Main Editor → Graph Executor: uses
src/editor/mainEditor.cpp - Node Renderer → Field Widgets: uses
src/editor/renderer/nodeRenderer.cpp - Node Renderer → Pin Renderer: uses
src/editor/renderer/nodeRenderer.cpp - Node Renderer → Node Registry: looks up nodes
src/editor/renderer/nodeRenderer.cpp - Node Definitions → Node Registry: registers nodes
src/core/registry/nodes/flowNodes.cpp - Graph Compiler → Node Registry: looks up nodes
src/core/compiler/graphCompiler.cpp - Graph State → Graph Compiler: provides graph
- Graph Compiler → EMI API: produces EMI-Script
README.md - Main Editor → Graph Preview: opens preview
- Graph Preview → Graph State: evaluates graph
src/editor/panels/graphPreviewPanel.cpp - EMI API → Script Parser: compiles scripts
- Script Parser → Script AST: builds AST
EMI-Script/src/Parser/Parser.cpp - Script VM → Script Parser: dispatches parsing
EMI-Script/src/VM.cpp - Script VM → Script Functions: uses functions
EMI-Script/src/VM.cpp - Script VM → Script Namespaces: uses namespaces
EMI-Script/src/VM.cpp