Files
UnrealEngineUWP/Engine/Plugins/Runtime/Metasound/Source/MetasoundFrontend/Private/MetasoundArrayNodes.cpp
Rob Gay 4b1e992925 Move FString/FText VertexName identifers to FNames. Convention is as follows:
- FGuid IDs are used to identify unique verticies within an entire graph (currently may be duplicated if graph is duplicated).
- FNames are used to be readible vertex identifiers that are only unique within a node's API.
- FText is only for ***OPTIONAL*** DisplayNames that can be provided as a more descriptive, readible descriptor of a given vertex (But are not necessarily unique). Currently disabled until loc tool on FText property in MetaSoundDetailsCustomization is properly displayed.
#rb phil.popp
#jira UE-123982
#preflight 613f6ff892b32b00016cf188

[CL 17494445 by Rob Gay in ue5-main branch]
2021-09-13 14:13:39 -04:00

105 lines
2.2 KiB
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#include "MetasoundArrayNodes.h"
#define LOCTEXT_NAMESPACE "MetasoundFrontend"
namespace Metasound
{
namespace MetasoundArrayNodesPrivate
{
FNodeClassMetadata CreateArrayNodeClassMetadata(const FName& InDataTypeName, const FName& InOperatorName, const FText& InDisplayName, const FText& InDescription, const FVertexInterface& InDefaultInterface)
{
FNodeClassMetadata Metadata
{
FNodeClassName{FName("Array"), InOperatorName, InDataTypeName},
1, // Major Version
0, // Minor Version
InDisplayName,
InDescription,
PluginAuthor,
PluginNodeMissingPrompt,
InDefaultInterface,
{ LOCTEXT("ArrayCategory", "Array") },
{ LOCTEXT("MetasoundArrayKeyword", "Array") },
FNodeDisplayStyle{}
};
return Metadata;
}
}
namespace ArrayNodeVertexNames
{
/* Input Vertx Names */
const FVertexName& GetInputArrayName()
{
static const FVertexName Name = TEXT("Array");
return Name;
}
const FVertexName& GetInputLeftArrayName()
{
static const FVertexName Name = TEXT("Left Array");
return Name;
}
const FVertexName& GetInputRightArrayName()
{
static const FVertexName Name = TEXT("Right Array");
return Name;
}
const FVertexName& GetInputTriggerName()
{
static const FVertexName Name = TEXT("Trigger");
return Name;
}
const FVertexName& GetInputIndexName()
{
static const FVertexName Name = TEXT("Index");
return Name;
}
const FVertexName& GetInputStartIndexName()
{
static const FVertexName Name = TEXT("Start Index");
return Name;
}
const FVertexName& GetInputEndIndexName()
{
static const FVertexName Name = TEXT("End Index");
return Name;
}
const FVertexName& GetInputValueName()
{
static const FVertexName Name = TEXT("Value");
return Name;
}
/* Output Vertex Names */
const FVertexName& GetOutputNumName()
{
static const FVertexName Name = TEXT("Num");
return Name;
}
const FVertexName& GetOutputValueName()
{
static const FVertexName Name = TEXT("Element");
return Name;
}
const FVertexName& GetOutputArrayName()
{
static const FVertexName Name = TEXT("Array");
return Name;
}
}
}
#undef LOCTEXT_NAMESPACE