GenerativeArt–MadewithUnity
Visual Effect
Graph
1
Julien Fryer
Graphics Programmer, Unity
julienf@unity3d.com
Vlad Neykov
Graphics Test Engineer, Unity
vlad@unity3d.com
Music: www.bensound.com
GenerativeArt–MadewithUnity
Overview
3
4
Next Generation Visual Effect tool for Unity
Tailored for Next-Generation platforms
(GPU/Compute)
Self contained template Assets with Event
and Parameter interface
Programmable, hybrid Stack/Node-Based
Effect behaviors
What is the Visual Effect Graph?
5
Industry trend
Scalability of effects
Artist friendly tool
Scalability of features
SRP High Definition Render Pipeline
6
CPU GPU
PARTICLE COUNT Thousands Millions
SIMULATION Simple Complex
PHYSICS Underlying Physics System
• Primitives
• Scene Representation (SDF…)
• Depth Buffer
GAMEPLAY READBACK Yes No*
* Potentially small data with latency
OTHER Can read Frame Buffers-
GPU vs CPU
Particles
GenerativeArt–MadewithUnity
Concepts
7
8
VFX Asset Authoring
● Author Behaviors
● Define Events
● Setup Parameter Interface
1
0
Asset Instance Configuration
● Edit Parameters
● Call Events
● C# Scripting
2
VFX Feature Creation/Editing
● Author New Features
● Improve Library
Layers of Editing
9
Layers of Editing
Examples
0 1 2
10
Flow
Context
Nodes
Blocks
How many particles?
What are their initial values?
How do they behave over time?
How are they rendered?
Contexts
Events, Spawner Chaining, GPU Events, Custom
Spawner Behaviors
Quad, Line, Point, Mesh, Multiple Outputs
11
GenerativeArt–MadewithUnity
Technical
Overview
12
13
FX Compilation
VFXGraph: Scriptable Objects hierarchy stored as sub assets
● Shaders (compute for simulation, vs/ps for rendering)
● Bytecode for the VFX CPU interpreter (flattened CPU part of expression graph)
● Optimized Data layout (only necessary attributes are stored)
● PropertySheet: input values and exposed parameters description
● List of VFX Systems descriptions
< Expression Graph
14
Expression Graph
High level use case
Shader Code
CPU bytecode
Constant folded
15
Compilation
2 Version of compiled data
● Edit time
○ All editable values in the graph are available for edition without recompilation
○ Additional debug and profiling data
● Runtime
○ Optimized low level graph, everything that is not exposed is constant folded
○ Constants directly inserted in shaders
GenerativeArt–MadewithUnity
Production
Pipeline
16
17
Pipeline
● VFX Toolbox (Flipbook generator)
● Point cache from meshes
● Future: Flowmap, Vector Field, Signed Distance Field, etc.
● External DCC (Houdini)
Live Demo
18
GenerativeArt–MadewithUnity
Roadmap
19
20
Down the road
● Shader Graph integration
● Subgraphs
● CPU particles
● Trails, etc.
GenerativeArt–MadewithUnity
Questions?
21
Julien Fryer
Graphics Programmer, Unity
julienf@unity3d.com
Vlad Neykov
Graphics Test Engineer, Unity
vlad@unity3d.com

Create Amazing VFX with the Visual Effect Graph