Navigation
API > API/Plugins > API/Plugins/TextureGraph
Base class for making working with Variants easier and less repetitive.
| Name | FTG_Variant |
| Type | struct |
| Header File | /Engine/Plugins/TextureGraph/Source/TextureGraph/Public/TG_Variant.h |
| Include Path | #include "TG_Variant.h" |
Syntax
USTRUCT ()
struct FTG_Variant
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FTG_Variant
(
FLinearColor RHS |
TG_Variant.h | ||
FTG_Variant
(
FVector4f RHS |
TG_Variant.h | ||
FTG_Variant
(
float RHS |
TG_Variant.h | ||
FTG_Variant
(
const FTG_Variant& RHS |
TG_Variant.h | ||
FTG_Variant () |
TG_Variant.h | ||
FTG_Variant
(
FTG_Texture RHS |
TG_Variant.h |
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| EType | ETG_VariantType | TG_Variant.h | |
| Variant | FTG_VariantInnerData | TG_Variant.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Data | Variant | The concrete data. | TG_Variant.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FLinearColor & EditColor() |
TG_Variant.h | ||
float & EditScalar() |
The editor methods are calling ResetTypeAs(expectedType) and thus the Variant will mutate to the expected type and assigned 0 | TG_Variant.h | |
FTG_Texture & EditTexture() |
TG_Variant.h | ||
FVector4f & EditVector() |
TG_Variant.h | ||
const FLinearColor & GetColor () |
TG_Variant.h | ||
FLinearColor GetColor
(
FLinearColor Default |
TG_Variant.h | ||
const float & GetScalar() |
Getter and Editor The getter methods are valid ONLY if the type matches | TG_Variant.h | |
FTG_Texture GetTexture
(
FTG_EvaluationContext* InContext, |
TG_Variant.h | ||
const FTG_Texture & GetTexture () |
TG_Variant.h | ||
FTG_Texture & GetTexture () |
TG_Variant.h | ||
EType GetType() |
Get the Type of the Variant, Scalar by default. | TG_Variant.h | |
FVector4f GetVector
(
FVector4f Default |
TG_Variant.h | ||
const FVector4f & GetVector () |
TG_Variant.h | ||
bool IsColor () |
TG_Variant.h | ||
bool IsScalar () |
Helper predicates to narrow down the type of the variant. | TG_Variant.h | |
bool IsTexture () |
TG_Variant.h | ||
bool IsVector () |
TG_Variant.h | ||
bool ResetTypeAs
(
EType InType |
Reset the Variant to the specified type, If the type is changed, the value is reset to 0 return true if the type as mutated | TG_Variant.h | |
bool Serialize
(
FArchive& Ar |
TG_Variant.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static FName GetArgNameFromType
(
ETG_VariantType InType |
Retrieve the FName associated to a varaint type used for Arg cpoptypename. | TG_Variant.h | |
static FName GetNameFromType
(
ETG_VariantType InType |
Retrieve the FName corresponding to a variant type. | TG_Variant.h | |
static ETG_VariantType GetTypeFromName
(
const FName& InTypeName |
Retrieve the variant type value matching a FName Return Scalar if couldn't find a match | TG_Variant.h | |
| TG_Variant.h | |||
static bool IsInvalid
(
EType InType |
TG_Variant.h | ||
| Predicates. | TG_Variant.h | ||
| TG_Variant.h | |||
| TG_Variant.h | |||
| Find the common type between 2. | TG_Variant.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
operator bool() |
TG_Variant.h | ||
FTG_Variant & operator=
(
const FTG_Variant& RHS |
TG_Variant.h | ||
FTG_Variant & operator=
(
const float RHS |
TG_Variant.h | ||
FTG_Variant & operator=
(
const FVector4f RHS |
TG_Variant.h | ||
FTG_Variant & operator=
(
const FLinearColor RHS |
TG_Variant.h | ||
FTG_Variant & operator=
(
const FTG_Texture RHS |
TG_Variant.h | ||
bool operator==
(
const FTG_Variant& RHS |
TG_Variant.h |