# ammarw/ue5_graphcapture architecture

> Architecture diagram of the GitHub repository ammarw/ue5_graphcapture, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ammarw/ue5_graphcapture
- Repository: https://github.com/ammarw/ue5_graphcapture

## Overview

UE5_GraphCapture is an Unreal Engine editor plugin for capturing graph-editor screenshots and exporting graph structure as JSON. The main workflows begin with toolbar/menu commands: screenshot capture inspects graph-editor widgets and saves images, while JSON export presents configurable options before reading graph data and writing an export. The README documents support for Blueprint, Material, Behavior Tree, and AI graphs; sampled exporter code also handles Niagara custom HLSL. Screenshot internals and export wiring are visible in excerpts, but unsampled implementation details are not inferred.

Main entry points: [`Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp`](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp) (Plugin module), [`Source/UE5_GraphCapture/Private/UE5_GraphCaptureJsonExporter.cpp`](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureJsonExporter.cpp) (Graph JSON exporter), [`Source/UE5_GraphCapture/Private/UE5_GraphCaptureCommands.cpp`](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureCommands.cpp) (Editor commands), [`Source/UE5_GraphCapture/Private/UE5_GraphCaptureOptionsDialog.cpp`](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureOptionsDialog.cpp) (Export options dialog)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_editor["Editor integration"]
  node_workspace["Graph workspace"]
  node_commands["Editor commands"]
  node_module["Plugin module"]
  node_graph_widget["Graph editor widget"]
  node_notifications["Editor notifications"]
end

subgraph group_capture["Screenshot capture"]
  node_screenshot["Screenshot capture"]
  node_image_writer["Image writing"]
  node_image_files["Screenshot files"]
end

subgraph group_export["JSON export"]
  node_dialog["Export options dialog"]
  node_exporter["Graph JSON exporter"]
  node_graph_data["Graph structure"]
  node_json_file["GraphExport.json"]
end

node_user(("Editor user"))
node_saved_dir[("Project Saved folder")]

node_user -->|"activates"| node_commands
node_commands -->|"dispatches"| node_module
node_module -->|"finds graph editors"| node_workspace
node_module -->|"starts capture"| node_screenshot
node_screenshot -->|"captures widget"| node_graph_widget
node_screenshot -->|"submits image"| node_image_writer
node_image_writer -->|"writes PNG"| node_image_files
node_image_files -->|"saved under"| node_saved_dir
node_module -->|"reports outcome"| node_notifications
node_module -->|"opens options"| node_dialog
node_dialog -->|"confirms options"| node_module
node_module -->|"invokes export"| node_exporter
node_exporter -->|"reads current graph"| node_graph_widget
node_graph_widget -->|"provides graph"| node_graph_data
node_exporter -->|"serializes and writes"| node_json_file
node_json_file -->|"saved under"| node_saved_dir
node_exporter -->|"reports export result"| node_notifications

click node_commands "https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureCommands.cpp"
click node_module "https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp"
click node_screenshot "https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp"
click node_image_writer "https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp"
click node_dialog "https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureOptionsDialog.cpp"
click node_exporter "https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureJsonExporter.cpp"
click node_notifications "https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_workspace,node_commands,node_module,node_graph_widget,node_notifications,node_user toneBlue
class node_screenshot,node_image_writer,node_image_files,node_saved_dir toneAmber
class node_dialog,node_exporter,node_graph_data,node_json_file toneMint
```

## Components

### Editor integration

- **Graph workspace**
- [Editor commands](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureCommands.cpp): `Source/UE5_GraphCapture/Private/UE5_GraphCaptureCommands.cpp`
- [Plugin module](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp): `Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp`
- **Graph editor widget**
- [Editor notifications](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp): `Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp`

### Screenshot capture

- [Screenshot capture](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp): `Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp`
- [Image writing](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp): `Source/UE5_GraphCapture/Private/UE5_GraphCapture.cpp`
- **Screenshot files**

### JSON export

- [Export options dialog](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureOptionsDialog.cpp): `Source/UE5_GraphCapture/Private/UE5_GraphCaptureOptionsDialog.cpp`
- [Graph JSON exporter](https://github.com/ammarw/ue5_graphcapture/blob/main/Source/UE5_GraphCapture/Private/UE5_GraphCaptureJsonExporter.cpp): `Source/UE5_GraphCapture/Private/UE5_GraphCaptureJsonExporter.cpp`
- **Graph structure**
- **GraphExport.json**

### Other components

- **Editor user**
- **Project Saved folder**

## Connections

- Editor user → Editor commands: activates
- Editor commands → Plugin module: dispatches
- Plugin module → Graph workspace: finds graph editors
- Plugin module → Screenshot capture: starts capture
- Screenshot capture → Graph editor widget: captures widget
- Screenshot capture → Image writing: submits image
- Image writing → Screenshot files: writes PNG
- Screenshot files → Project Saved folder: saved under
- Plugin module → Editor notifications: reports outcome
- Plugin module → Export options dialog: opens options
- Export options dialog → Plugin module: confirms options
- Plugin module → Graph JSON exporter: invokes export
- Graph JSON exporter → Graph editor widget: reads current graph
- Graph editor widget → Graph structure: provides graph
- Graph JSON exporter → GraphExport.json: serializes and writes
- GraphExport.json → Project Saved folder: saved under
- Graph JSON exporter → Editor notifications: reports export result
