Navigation
API > API/Plugins > API/Plugins/MetaHumanCharacterPalette
Used to assemble a renderable character from a MetaHuman Collection.
Can be either an asset used in the editor or a transient object generated at runtime.
| Name | UMetaHumanInstance |
| Type | class |
| Header File | /Engine/Plugins/MetaHuman/MetaHumanCharacter/Source/MetaHumanCharacterPalette/Public/MetaHumanInstance.h |
| Include Path | #include "MetaHumanInstance.h" |
Syntax
UCLASS (BlueprintType)
class UMetaHumanInstance : public UObject
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UMetaHumanInstance
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| OnInstanceUpdatedNative | FMetaHumanInstanceUpdatedNative | MetaHumanInstance.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bIsAssemblyOutputCooked | bool | True if this Instance was loaded from a cooked package and has a valid baked RuntimeAssemblyOutput. | MetaHumanInstance.h |
|
| Collection | TObjectPtr< UMetaHumanCollection > | MetaHumanInstance.h | ||
| CurrentOverriddenAssemblyParameters | FMetaHumanInstanceParameterCollection | Used by the assembly that's currently in progress | MetaHumanInstance.h |
|
| EditorAssemblyOutput | FMetaHumanProcessedAssemblyOutput | The assembly output and associated data for this Instance while it's being edited in the editor. | MetaHumanInstance.h |
|
| OverriddenCollectionInstanceParameters | FInstancedPropertyBag | OverriddenInstanceParameters for the Collection pipeline itself, so that we can detect when a key in OverriddenInstanceParameters has been reset to the empty path due to a missing asset. | MetaHumanInstance.h | |
| OverriddenInstanceParameters | TMap< FMetaHumanPaletteItemPath, FInstancedPropertyBag > | MetaHumanInstance.h | ||
| RuntimeAssemblyOutput | FMetaHumanProcessedAssemblyOutput | The assembly output and associated data for this Instance in cooked builds. | MetaHumanInstance.h |
|
| ShouldCookAsAssembled | EMetaHumanInstanceCookBehavior | Determines whether this Instance should be assembled at cook time and have its assembly output baked into the cooked package. | MetaHumanInstance.h |
|
| SlotSelections | TArray< FMetaHumanPipelineSlotSelectionData > | The selected items for slots on the Pipeline. | MetaHumanInstance.h | |
| WillCookAsAssembled | EMetaHumanInstanceCookBehavior | The effective resolved value of ShouldCookAsAssembled. | MetaHumanInstance.h |
|
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void Assemble
(
const FMetaHumanCharacterAssembled& OnAssembled, |
MetaHumanInstance.h | ||
void Assemble
(
EMetaHumanCharacterPaletteBuildQuality Quality, |
MetaHumanInstance.h | ||
void Assemble
(
EMetaHumanCharacterPaletteBuildQuality Quality, |
MetaHumanInstance.h | ||
void Assemble
(
EMetaHumanCharacterPaletteBuildQuality Quality, |
MetaHumanInstance.h | ||
void Assemble
(
const FMetaHumanCharacterAssembled& OnAssembled |
Runs the associated Character Pipeline's assembly function to populate the AssemblyOutput. | MetaHumanInstance.h |
|
void Assemble
(
const FMetaHumanCharacterAssembledNative& OnAssembledNative |
MetaHumanInstance.h |
|
|
void ClearAllOverriddenInstanceParameters() |
Functions to clear overridden Instance Parameters | MetaHumanInstance.h | |
void ClearAssemblyOutput () |
Clear the result of the last assembly. | MetaHumanInstance.h |
|
void ClearOverriddenInstanceParameters
(
const FMetaHumanPaletteItemPath& ItemPath |
MetaHumanInstance.h | ||
bool ContainsSlotSelection
(
const FMetaHumanPipelineSlotSelection& Selection |
MetaHumanInstance.h | ||
void CopyContentsFrom
(
TNotNull< const UMetaHumanInstance* > Other |
Copies the contents of the Other Instance into this Instance, discarding this Instance's existing contents and leaving it in an unassembled state. | MetaHumanInstance.h | |
| The term Instance Parameters now refers to both Assembly and Post-Assembly Parameters. | MetaHumanInstance.h | ||
const FInstancedStruct & GetAssemblyOutput () |
MetaHumanInstance.h | ||
const FInstancedStruct & GetAssemblyOutput () |
Assemble if necessary and return the assembly output | MetaHumanInstance.h |
|
| Returns the Assembly Parameters produced by the last build and their original values. | MetaHumanInstance.h | ||
FInstancedPropertyBag GetCurrentInstanceParametersForItem
(
const FMetaHumanPaletteItemPath& ItemPath |
Returns the Instance Parameters produced by the last assembly and their effective values. | MetaHumanInstance.h | |
const FInstancedStruct & GetExistingAssemblyOutput () |
GetAssemblyOutput should be used instead of this function in most cases. | MetaHumanInstance.h |
|
| Return the MetaHuman Collection that this instance will assemble from. | MetaHumanInstance.h |
|
|
| Returns the Instance Parameters stored in this instance as overrides. | MetaHumanInstance.h | ||
| Returns the Post-Assembly Parameters produced by the last assembly and their original values. | MetaHumanInstance.h | ||
const TArray< FMetaHumanPipelineSlotSelectionData > & GetSlotSelectionData() |
MetaHumanInstance.h |
|
|
bool IsAssembled() |
Returns true if the Instance is assembled and up to date | MetaHumanInstance.h |
|
void NotifyAssemblyOutputInvalidated () |
Notify users of this Instance that they should call GetAssemblyOutput again and update themselves. | MetaHumanInstance.h | |
EMetaHumanInstanceParameterOverrideResult OverrideInstanceParameters
(
const FMetaHumanPaletteItemPath& ItemPath, |
Set the overridden Instance Parameter values for a given item, or the Collection itself if an empty item path is specified. | MetaHumanInstance.h | |
void SetMetaHumanCollection
(
UMetaHumanCollection* InCollection |
Set the MetaHuman Collection that this instance will assemble from. | MetaHumanInstance.h |
|
void SetSingleSlotSelection
(
FName SlotName, |
Remove any existing selections for this slot and select only the given item. | MetaHumanInstance.h |
|
void SetSingleSlotSelection
(
const FMetaHumanPaletteItemPath& ParentItemPath, |
MetaHumanInstance.h |
|
|
TArray< FMetaHumanPinnedSlotSelection > ToPinnedSlotSelections
(
EMetaHumanUnusedSlotBehavior UnusedSlotBehavior |
Formats the slot selections and overridden instance parameters stored in this instance to be passed into a Collection build as pinned selections. | MetaHumanInstance.h | |
bool TryAddSlotSelection
(
const FMetaHumanPipelineSlotSelection& Selection |
Adds the provided slot selection if valid, e.g. won't allow duplicate selections or multiple selections for slots that don't allow it. | MetaHumanInstance.h |
|
bool TryGetAnySlotSelection
(
FName SlotName, |
Get a single item selection for this slot, if there is at least one. | MetaHumanInstance.h | |
bool TryGetAnySlotSelection
(
const FMetaHumanPaletteItemPath& ParentItemPath, |
MetaHumanInstance.h | ||
bool TryRemoveSlotSelection
(
const FMetaHumanPipelineSlotSelection& Selection |
Returns true if the selection existed and was removed, false if it didn't exist. | MetaHumanInstance.h | |
| Unpacks only the assets contained in this Instance. | MetaHumanInstance.h |
Public Virtual
Overridden from UObject
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void PostEditChangeProperty
(
FPropertyChangedEvent& PropertyChangedEvent |
MetaHumanInstance.h | ||
virtual void PostLoad() |
MetaHumanInstance.h | ||
virtual void PreSave
(
FObjectPreSaveContext ObjectSaveContext |
MetaHumanInstance.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static bool TryGetAnySlotSelection
(
TConstArrayView< FMetaHumanPipelineSlotSelectionData > SlotSelections, |
MetaHumanInstance.h | ||
static bool TryGetAnySlotSelection
(
TConstArrayView< FMetaHumanPipelineSlotSelectionData > SlotSelections, |
MetaHumanInstance.h | ||
static bool TryGetAnySlotSelection
(
TConstArrayView< FMetaHumanPipelineSlotSelection > SlotSelections, |
MetaHumanInstance.h | ||
static bool TryGetAnySlotSelection
(
TConstArrayView< FMetaHumanPipelineSlotSelection > SlotSelections, |
MetaHumanInstance.h |