Navigation
API > API/Plugins > API/Plugins/MetaHumanDefaultEditorPipeline > API/Plugins/MetaHumanDefaultEditorPipeline/UMetaHumanDefaultEditorPipelineB-
Description
Bakes materials to textures with the provided settings.
If bCreateInstancesOfBakedMaterials is true, the materials specified in FMetaHumanMaterialBakingOptions to be used with the baked textures will be instanced first, so that the original materials aren't modified. This setting should be used when the FMetaHumanMaterialBakingOptions come from an asset on disk.
If bCreateInstancesOfBakedMaterials is false, the baked materials will be modified and used directly. This can be used when FMetaHumanMaterialBakingOptions has been generated procedurally and set up with baked materials for this purpose.
| Name | TryBakeMaterials |
| Type | function |
| Header File | /Engine/Plugins/MetaHuman/MetaHumanCharacter/Source/MetaHumanDefaultEditorPipeline/Public/MetaHumanDefaultEditorPipelineBase.h |
| Include Path | #include "MetaHumanDefaultEditorPipelineBase.h" |
| Source | /Engine/Plugins/MetaHuman/MetaHumanCharacter/Source/MetaHumanDefaultEditorPipeline/Private/MetaHumanDefaultEditorPipelineBase.cpp |
bool TryBakeMaterials
(
const FString & BaseOutputFolder,
const FMetaHumanMaterialBakingOptions & InMaterialBakingOptions,
TArray < FSkeletalMaterial > & InOutSkelMeshMaterials,
const TMap < FName , TObjectPtr < UMaterialInterface > > & RemovedMaterialSlots,
const TArray < int32 > & MaterialChangesPerLOD,
TNotNull< UObject * > GeneratedAssetOuter,
FMetaHumanCharacterGeneratedAssets & InOutGeneratedAssets,
TArray < TObjectPtr < UTexture > > & OutGeneratedTextures,
bool bCreateInstancesOfBakedMaterials
) const