IGraphController

An [IGraphController](API\Plugins\MetasoundFrontend\IGraphController) provides methods for querying and manipulating a Metasound graph.

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

References

Module

MetasoundFrontend

Header

/Engine/Plugins/Runtime/Metasound/Source/MetasoundFrontend/Public/MetasoundFrontendController.h

Include

#include "MetasoundFrontendController.h"

Syntax

class IGraphController :
    public TSharedFromThis< IGraphController >,
    public Metasound::Frontend::IDocumentAccessor

Remarks

An IGraphController provides methods for querying and manipulating a Metasound graph.

Constructors

Name Description

Public function

IGraphController()

Destructors

Name Description

Public function Virtual

~IGraphController()

Functions

Name Description

Public function

FNodeHandle

 

AddDuplicateNode

(
    const INodeController& InNodeContr...
)

Add a new node to this graph by duplicating the supplied node.

Public function

FNodeHandle

 

AddInputVertex

(
    const FVertexName& InName,
    const FName InTypeName,
    const FText& InToolTip,
    const FMetasoundFrontendLiteral...
)

Public function

FNodeHandle

 

AddInputVertex

(
    const FMetasoundFrontendClassInput ...
)

Add a new input node using the input description.

Public function

FNodeHandle

 

AddNode

(
    const FMetasoundFrontendClassMetada...,
    FGuid InNodeGuid
)

Add a new node to this graph.

Public function

FNodeHandle

 

AddNode

(
    const FNodeRegistryKey& InKey,
    FGuid InNodeGuid
)

Add a new node to this graph from the node registry.

Public function

FNodeHandle

 

AddOutputVertex

(
    const FMetasoundFrontendClassOutput...
)

Add a new output node using the output description.

Public function

FNodeHandle

 

AddOutputVertex

(
    const FVertexName& InName,
    const FName InTypeName,
    const FText& InToolTip
)

Public function

FVariableHan...

 

AddVariable

(
    const FName& InDataTypeName
)

Adds a new variable to the graph

Public function

FNodeHandle

 

AddVariableAccessorNode

(
    const FGuid& InVariableID
)

Creates and returns a variable accessor node.

Public function

FNodeHandle

 

AddVariableDeferredAccessorNode

(
    const FGuid& InVariableID
)

Creates and returns a variable deferred accessor node.

Public function Const

TUniquePtr< ...

 

BuildOperator

(
    const FOperatorSettings& InSetting...,
    const FMetasoundEnvironment& InEnv...,
    TArray< IOperatorBuilder::FBuildErr...
)

Creates a runtime operator for the given graph.

Public function

void

 

ClearGraph()

Clears the graph, its associated interface, and synchronizes removed dependencies with the owning graph.

Public function

bool

 

ClearLiteralForInput

(
    const FVertexName& InInputName,
    FGuid InVertexID
)

Clear the current literal for a given input.

Public function Const

bool

 

ContainsInputVertex

(
    const FVertexName& InName,
    const FName& InTypeName
)

Returns true if an input vertex with the given Name exists.

Public function Const

bool

 

ContainsInputVertexWithName

(
    const FVertexName& InName
)

Returns true if an input vertex with the given Name exists.

Public function Const

bool

 

ContainsOutputVertex

(
    const FVertexName& InName,
    const FName& InTypeName
)

Returns true if an output vertex with the given Name exists.

Public function Const

bool

 

ContainsOutputVertexWithName

(
    const FVertexName& InName
)

Returns true if an output vertex with the given Name exists.

Public function

FNodeHandle

 

CreateEmptySubgraph

(
    const FMetasoundFrontendClassMetada...
)

Creates and inserts a new subgraph into this graph using the given metadata.

Public function Const

FConstClassI...

 

FindClassInputWithName

(
    const FVertexName& InName
)

Public function Const

FConstClassO...

 

FindClassOutputWithName

(
    const FVertexName& InName
)

Public function

FNodeHandle

 

FindOrAddVariableMutatorNode

(
    const FGuid& InVariableID
)

Returns the variable mutator node. If none exist, one is created.

Public function Const

FConstVariab...

 

FindVariable

(
    const FGuid& InVariableID
)

Finds a variable by ID.

Public function

FVariableHan...

 

FindVariable

(
    const FGuid& InVariableID
)

Finds a variable by ID.

Public function Const

FConstVariab...

 

FindVariableContainingNode

(
    const FGuid& InNodeID
)

Finds a variable inspecting the nodes associated with the variable.

Public function

FVariableHan...

 

FindVariableContainingNode

(
    const FGuid& InNodeID
)

Finds a variable inspecting the nodes associated with the variable.

Public function Const

FGuid

 

GetClassID()

Returns the ClassID associated with this graph.

Public function Const

TArray< FCon...

 

GetConstInputNodes()

Returns all input nodes in the graph.

Public function Const

TArray< FCon...

 

GetConstNodes()

Returns all nodes in the graph.

Public function Const

TArray< FCon...

 

GetConstOutputNodes()

Returns all output nodes in the graph.

Public function Const

FMetasoundFr...

 

GetDefaultInput

(
    const FGuid& InVertexID
)

Public function Const

FText

 

GetDisplayName()

Return the display name of the graph.

Public function Const

const FMetas...

 

GetGraphMetadata()

Return the metadata for the current graph.

Public function Const

const FMetas...

 

GetGraphStyle()

Returns graph style.

Public function Const

const FText ...

 

GetInputDescription

(
    const FVertexName& InName
)

Get the description for the input with the given name.

Public function

TArray< FNod...

 

GetInputNodes()

Returns all input nodes in the graph.

Public function Const

FConstNodeHa...

 

GetInputNodeWithName

(
    const FVertexName& InName
)

Returns a handle to an existing input node for the given graph input name.

Public function

FNodeHandle

 

GetInputNodeWithName

(
    const FVertexName& InName
)

Returns a handle to an existing input node for the given graph input name.

Public function Const

TArray< FVer...

 

GetInputVertexNames()

Public function Static

FGraphHandle

 

GetInvalidHandle()

Public function

TArray< FNod...

 

GetNodes()

Returns all nodes in the graph.

Public function

FNodeHandle

 

GetNodeWithID

(
    FGuid InNodeID
)

Returns a node by NodeID. If the node does not exist, an invalid handle is returned.

Public function Const

FConstNodeHa...

 

GetNodeWithID

(
    FGuid InNodeID
)

Returns a node by NodeID. If the node does not exist, an invalid handle is returned.

Public function Const

const FText ...

 

GetOutputDescription

(
    const FVertexName& InName
)

Get the description for the output with the given name.

Public function

TArray< FNod...

 

GetOutputNodes()

Returns all output nodes in the graph.

Public function Const

FConstNodeHa...

 

GetOutputNodeWithName

(
    const FVertexName& InName
)

Returns a handle to an existing output node for the given graph output name.

Public function

FNodeHandle

 

GetOutputNodeWithName

(
    const FVertexName& InName
)

Returns a handle to an existing output node for the given graph output name.

Public function Const

TArray< FVer...

 

GetOutputVertexNames()

Public function Const

FConstDocume...

 

GetOwningDocument()

Returns a handle to the document owning this graph.

Public function

FDocumentHan...

 

GetOwningDocument()

Returns a handle to the document owning this graph.

Public function Const

ELiteralType

 

GetPreferredLiteralTypeForInputVertex

(
    const FVertexName& InInputName
)

Returns the preferred literal argument type for a given input.

Public function

UClass *

 

GetSupportedClassForInputVertex

(
    const FVertexName& InInputName
)

Return the UObject class corresponding an input.

Public function Const

TArray< FCon...

 

GetVariables()

Returns an array of all variables associated with the graph.

Public function

TArray< FVar...

 

GetVariables()

Returns an array of all variables associated with the graph.

Public function Const

FGuid

 

GetVertexIDForInputVertex

(
    const FVertexName& InInputName
)

Public function Const

FGuid

 

GetVertexIDForOutputVertex

(
    const FVertexName& InOutputName
)

Public function Const

bool

 

IsValid()

Returns true if the controller is in a valid state.

Public function Const

void

 

IterateConstNodes

(
    TFunctionRef< void...,
    EMetasoundFrontendClassType InClass...
)

Iterate over all nodes with the given function.

Public function

void

 

IterateNodes

(
    TFunctionRef< void)> In...,
    EMetasoundFrontendClassType InClass...
)

Iterate over all input nodes with the given function.

Public function

bool

 

RemoveInputVertex

(
    const FVertexName& InputName
)

Remove the input with the given name. Returns true if successfully removed, false otherwise.

Public function

bool

 

RemoveNode

(
    INodeController& InNode
)

Remove the node corresponding to this node handle.

Public function

bool

 

RemoveOutputVertex

(
    const FVertexName& OutputName
)

Remove the output with the given name. Returns true if successfully removed, false otherwise.

Public function

bool

 

RemoveVariable

(
    const FGuid& InVariableID
)

Removes the variable with the given ID.

Public function

bool

 

SetDefaultInput

(
    const FGuid& InVertexID,
    const FMetasoundFrontendLiteral& I...
)

Public function

bool

 

SetDefaultInputToDefaultLiteralOfType

(
    const FGuid& InVertexID
)

Set the default value for the graph input.

Public function

void

 

SetGraphMetadata

(
    const FMetasoundFrontendClassMetada...
)

Sets the metadata for the current graph.

Public function

void

 

SetGraphStyle

(
    const FMetasoundFrontendGraphStyle ...
)

Sets graph style.

Public function

void

 

SetInputDescription

(
    const FVertexName& InName,
    const FText& InDescription
)

Set the description for the input with the given name.

Public function

void

 

SetInputDisplayName

(
    const FVertexName& InName,
    const FText& InDisplayName
)

Set the display name for the input with the given name.

Public function

void

 

SetOutputDescription

(
    const FVertexName& InName,
    const FText& InDescription
)

Set the description for the output with the given name.

Public function

void

 

SetOutputDisplayName

(
    const FVertexName& InName,
    const FText& InDisplayName
)

Set the display name for the output with the given name.

Public function

void

 

UpdateInterfaceChangeID()

Updates the ChangeID for the class interface, which signals AutoUpdate to attempt to patch class references at runtime even if the graph class has not been versioned.