Voxel Plugin
2.0p-340
2.0p-340
  • Home
  • Getting Started
    • Installing Voxel Plugin
    • Installing Example Content
    • Migrating from 1.2
  • Knowledgebase
    • Using Graphs
      • Graph Preview
      • Buffers and Uniforms
    • Channels
    • Surfaces & Materials
      • Working with Surfaces
        • Distance Fields & Distance Checks
        • Applying Materials to a Surface
      • Material Definitions
        • Creating Materials from Scratch
        • Extending the Complex Material Sample
        • Technical Details
        • Detail Textures
    • Brushes
      • Voxelized Meshes
    • Foliage
    • Navmesh & Collision
    • Sculpt Volumes
    • Blueprints
      • Setting graph parameters
      • Querying voxel graphs
    • Graph Design
      • Why Landmass & MetaGraphs
      • Execution Flow & Query Data
      • Node Types
      • MetaGraph Macros
      • Adding Custom Nodes
    • Profiling & Debugging
      • Generation Performance
      • Memory Usage & Render Performance
      • Debugging plugin code
    • Platform Support
      • Targeting Mac & iOS
      • Targeting Android
  • Resources
    • Voxel Graph API
      • Exec Nodes
        • Edit Sculpt Surface
        • Execute
        • Merge Execs
        • Debug
          • Debug Delay
        • Set Sculpt Source Surface
        • Register To Channel
        • Generate Marching Cube Collision & Navmesh
        • Generate Marching Cube Surface
        • Create Marching Cube Preview Mesh
        • Write Volume Texture
        • Generate Point Collision
        • Render Mesh
      • Misc
        • Get Previous Output
        • Query with Gradient Step
        • Query with Position
        • Filter Buffer
        • Make Value
        • Is Valid
        • Get Collision Enabled
        • Get LOD
        • Get Point Chunk Bounds
        • Is Editor World
        • Is Game World
        • Is Hidden in Editor
        • Is Preview Scene
        • Get Position 2D
        • Get Position 3D
      • Sculpt
        • Get Sculpt Surface
      • Point
        • Make Chunked Points
        • Merge Points
        • Set Point Attribute
        • Get Point Attribute
        • Set Actor Property
        • Get Actor Property
        • Set Parent Point Attribute
        • Get Parent Point Attribute
        • Set Point Mesh
        • Get Point Mesh
        • Get Parent Point Mesh
        • Set Point Position
        • Get Point Position
        • Get Parent Point Position
        • Set Point Rotation
        • Get Point Rotation
        • Get Parent Point Rotation
        • Set Point Scale
        • Get Point Scale
        • Get Parent Point Scale
        • Set Point Normal
        • Get Point Normal
        • Get Parent Point Normal
        • Set Actor Class
        • Get Actor Class
        • Get Parent Actor Class
        • Set Point Custom Data
        • Get Point Custom Data
        • Get Parent Point Custom Data
        • Get Point Seed
        • Apply Translation
        • Apply Rotation
        • Apply Scale
        • Apply Point Storage
        • Generate Surface Points
        • Make Points
        • Get Points
        • Filter Points
        • Density Filter
        • Make Radial Point Spawner
        • Prune by Bounds
        • Prune by Distance
        • Raymarch Distance Field
        • Scatter Points
      • Material
        • Make Material
        • Make Float Detail Texture Parameter
        • Make Color Detail Texture Parameter
        • Make Material Detail Texture Parameter
        • Make Normal Detail Texture Parameter
        • Make Scalar Parameter
        • Make Vector Parameter
      • Math
        • Trig
          • Sin (Radians)
          • Sin (Degrees)
          • Cos (Radians)
          • Cos (Degrees)
          • Tan (Radians)
          • Tan (Degrees)
          • Asin (Radians)
          • Asin (Degrees)
          • Acos (Radians)
          • Acos (Degrees)
          • Atan (Radians)
          • Atan (Degrees)
          • Atan2 (Radians)
          • Atan2 (Degrees)
          • Get PI
          • Radians to Degrees
          • Degrees to Radians
        • Float
          • Bilinear Interpolation
          • Frac
          • Power
        • Boolean
          • NOT Boolean
          • NOR Boolean
          • XOR Boolean
          • AND Boolean
          • OR Boolean
          • NAND Boolean
        • Integer
          • Left Shift
          • Right Shift
          • Bitwise AND
          • Bitwise OR
          • Bitwise XOR
          • Bitwise NOT
        • Rotation
          • Make Quaternion
          • Break Quaternion
          • Make Rotation from Z
          • Combine Rotation
        • Operators
          • Equal
          • Nearly Equal
          • Not Equal
          • Less
          • Greater
          • Less Equal
          • Greater Equal
          • Ceil
          • Round
          • Floor
          • Add
          • Subtract
          • Multiply
          • Divide
          • % (Integer)
          • Min
          • Max
          • Abs
          • One Minus
          • Sign
        • Misc
          • Clamp
          • Mapped Range Value Clamped
          • Mapped Range Value Unclamped
          • Height Splitter
          • Interpolate
          • Lerp
          • Safe Lerp
          • Smooth Step
        • Seed
          • Mix Seeds
          • Make Seeds
        • Vector Operators
          • Cross Product
          • Dot Product
          • Normalize
          • Length
          • Length XY
          • Distance
          • Distance 2D
        • Conversions
          • To Double Vector (Double Linear Color)
          • To Double Vector 2D (Double Linear Color)
          • To Linear Color (Double Linear Color)
          • To Vector (Double Linear Color)
          • To Vector 2D (Double Linear Color)
          • To Double Linear Color (Double)
          • To Double Vector (Double)
          • To Double Vector 2D (Double)
          • To Float (Double)
          • To Double Linear Color (Double Vector 2D)
          • To Double Vector (Double Vector 2D)
          • To Linear Color (Double Vector 2D)
          • To Vector (Double Vector 2D)
          • To Vector 2D (Double Vector 2D)
          • To Double Linear Color (Double Vector)
          • To Double Vector 2D (Double Vector)
          • To Linear Color (Double Vector)
          • To Vector (Double Vector)
          • To Vector 2D (Double Vector)
          • To Double (Float)
          • To Linear Color (Float)
          • To Vector (Float)
          • To Vector 2D (Float)
          • To Double (Integer)
          • To Float (Integer)
          • To Int Point (Integer)
          • To Int Vector (Integer)
          • To Int Vector 4 (Integer)
          • To Seed (Integer)
          • To Double Linear Color (Int Point)
          • To Double Vector (Int Point)
          • To Double Vector 2D (Int Point)
          • To Int Vector (Int Point)
          • To Int Vector 4 (Int Point)
          • To Linear Color (Int Point)
          • To Vector (Int Point)
          • To Vector 2D (Int Point)
          • To Double Linear Color (Int Vector 4)
          • To Double Vector (Int Vector 4)
          • To Double Vector 2D (Int Vector 4)
          • To Int Point (Int Vector 4)
          • To Int Vector (Int Vector 4)
          • To Linear Color (Int Vector 4)
          • To Vector (Int Vector 4)
          • To Vector 2D (Int Vector 4)
          • To Double Linear Color (Int Vector)
          • To Double Vector (Int Vector)
          • To Double Vector 2D (Int Vector)
          • To Int Point (Int Vector)
          • To Int Vector 4 (Int Vector)
          • To Linear Color (Int Vector)
          • To Vector (Int Vector)
          • To Vector 2D (Int Vector)
          • To Double Linear Color (Linear Color)
          • To Double Vector (Linear Color)
          • To Double Vector 2D (Linear Color)
          • To Vector (Linear Color)
          • To Vector 2D (Linear Color)
          • To Integer (Seed)
          • To Double Linear Color (Vector 2D)
          • To Double Vector (Vector 2D)
          • To Double Vector 2D (Vector 2D)
          • To Linear Color (Vector 2D)
          • To Vector (Vector 2D)
          • To Double Linear Color (Vector)
          • To Double Vector (Vector)
          • To Double Vector 2D (Vector)
          • To Linear Color (Vector)
          • To Vector 2D (Vector)
        • Curve
          • Make Curve from Asset
          • Sample Curve
        • Color
          • Break Double Linear Color
          • Break Linear Color
          • Make Double Linear Color
          • Make Linear Color
        • Vector
          • Break Double Vector
          • Break Vector
          • Make Double Vector
          • Make Vector
        • Vector2D
          • Break Double Vector 2D
          • Break Vector 2D
          • Make Double Vector 2D
          • Make Vector 2D
        • Interval
          • Break Float Range
          • Break Integer Range
          • Make Float Range
          • Make Integer Range
        • Int Point
          • Break Int Point
          • Make Int Point
        • Int Vector
          • Break Int Vector
          • Make Int Vector
        • Int Vector 4
          • Break Int Vector 4
          • Make Int Vector 4
        • Transform
          • Break Transform
          • Inverse Transform Location
          • Make Transform
          • Transform Location
        • Distance
          • Smooth Max
          • Smooth Min
        • Box
          • Break Box
          • Extend Box
          • Make Box
          • Make Box from Radius
          • Make Infinite Box
          • Transform Box
      • Color
        • Distance to Color
      • Surface
        • Merge Surface
        • Get Merge Data
        • Get Surface Distance
        • Get Surface Material
        • Get Surface Attribute
        • Set Surface Material
        • Set Surface Attribute
        • Bind Attribute Detail Texture
        • Make Height Surface
        • Make Volumetric Surface
        • Make Sphere Surface
        • Make Box Surface
        • Invert Surface
        • Mask Surface
        • Inflate Surface
        • Displace Surface
        • Create Voxelized Mesh Surface
        • Blend Materials
        • Get Bounds Box
        • Get Surface Bounds
        • Make Bounds from Local Box
      • Channel Nodes
        • Query Channel
      • Noise
        • Advanced Noise 2D
        • Advanced Noise 3D
        • Perlin Noise 2D
        • Perlin Noise 3D
        • Cellular Noise 2D
        • Cellular Noise 3D
        • True Distance Cellular Noise 2D
      • Name
        • Append Names
      • Array
        • Length
        • Get
      • Gradient
        • Get Gradient
      • Chunk Spawner
        • Make Invoker Chunk Spawner
        • Make Screen Size Chunk Spawner
      • Random
        • Rand Float
        • Random Vector
        • Random Rotator
        • Random Select
        • Hash Position
        • Rand Unit Vector
        • Break Random Vector Settings
        • Make Random Vector Settings
      • Flow Control
        • Select
      • Actor
        • Get Transform
      • Network
        • Is Client
        • Is Dedicated Server
        • Is Listen Server
        • Is Server
        • Is Standalone
      • Heightmap
        • Get Heightmap Bounds
        • Make Cubemap Planet Surface
        • Sample Heightmap
      • Voxelized Mesh
        • Make Voxelized Mesh from Static Mesh
    • Glossary
    • Licensing
    • Release Notes
      • 2.0p-340 Release Notes
      • 2.0p-320 Release Notes
      • 2.0p-317 Release Notes
      • 2.0p-304 Release Notes
    • Roadmap
Powered by GitBook
On this page
  • 1. Graph Execution
  • 2. Query Data

Was this helpful?

  1. Knowledgebase
  2. Graph Design

Execution Flow & Query Data

The way individual graphs are executed, how they come together and what the premises and impacts behind Query Data are.

PreviousWhy Landmass & MetaGraphsNextNode Types

Last updated 1 year ago

Was this helpful?

1. Graph Execution

1.1 Calling an Execution node

Any (red) MetaNodes that exist in a graph with nothing plugged into their execution pin will be run, but only when that graph is called directly from the world. MetaNodes will not automatically run when a graph is called as a function from within another graph.

Any nodes that have an active execution pin hooked up to an Execute node in the top-level graph will be called when said top-level graph is executed.

If a graph called as function should run its MetaNodes, the execution pins can be made into an output, which can be plugged into an Execute node in the graph calling it.

Any called MetaNodes will call whatever nodes are connected to their input pins. These nodes will then call the nodes connected to their input pins, and so on until the end of the chain is reached.

1.2 Right-to-left execution

Graph execution flows right to left.

When a node is called, it will evaluate whether it has all the data it needs readily available. If the node has no connected input pins, all data is present on the node, it simply returns its requested output data.

However, if any of its input pins do have connections, those nodes need to be evaluated in order to produce the requested output. The node will therefore call the nodes that are connected to its input pins. The next node will go through the same steps, and this cycle continues until a node is reached that has no connected input pins.

While most data therefore flows left-to-right, the 'inverted' execution flow is crucial because it allows us to also send some data right-to-left. We call this Query Data.

2. Query Data

A node calling another node can send information downstream, called Query Data. A node providing Query Data will send along this piece of information whenever it calls a node. This data can therefore be read back by any downstream node. It can be also mutated by . Some downstream nodes will require specific Query Data to be present, and errors will be thrown if this is not the case. Generally, the fix for this is to add another node upstream.

For example, the Generate Surface Points node takes a bounds pin.

When using this node, you will generally want to use Get Spawnable Bounds, which will look for the SpawnableBounds Query Data. This Query Data is created and added to the downstream information flow by the Spawn Chunks node, which will switch the state of this Query Data for each chunk so that it matches said chunk's bounds. Thanks to this, every chunk's Generate Surface Points node will only generate points within that chunk's bounds.

Interesting to note is that without the , the Get Spawnable Bounds node would have no way to know anything about what the Spawn Chunks node is doing.

right-to-left execution flow
MetaNodes are the drivers of graph execution.
When generating surface points, you generally want to use Spawnable Bounds, which is provided by the chunk spawner.