ContentImportSettings
ContentImportSettings
#Overview
name: ContentImportSettings
The value of this variable can be defined or overridden in .ini config files. 1
.ini config file referencing this setting variable.
It is referenced in 6
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of ContentImportSettings is to manage and configure import settings for content in Unreal Engine 5. This variable is part of the Interchange system, which handles importing various types of assets into the engine.
ContentImportSettings is primarily used by the Interchange subsystem within Unreal Engine 5. It is specifically related to the Engine module of the Interchange system, as evidenced by its location in the InterchangeProjectSettings class.
The value of this variable is set in the UInterchangeProjectSettings class, which inherits from UDeveloperSettings. This means it can be configured through the project settings interface in the Unreal Editor.
ContentImportSettings interacts with several other variables and functions:
- It’s used in conjunction with SceneImportSettings to differentiate between content and scene imports.
- It contains a DefaultPipelineStackOverride map, which is used to determine the default pipeline stack for different asset types.
- It includes a ShowImportDialogOverride map, which controls whether to show import dialogs for specific asset types.
Developers should be aware of the following when using this variable:
- It affects the behavior of content imports across the entire project.
- Changes to this variable can impact the default pipeline stacks used for different asset types.
- It can control whether import dialogs are shown for specific asset types.
Best practices when using this variable include:
- Carefully consider the implications of changing default pipeline stacks or import dialog behaviors.
- Use the GetImportSettings and GetMutableImportSettings functions to access and modify these settings, rather than directly accessing the variable.
- When making changes, use the SaveConfig method to ensure the changes are persisted.
- Be aware of the different asset types (EInterchangeTranslatorAssetType) when configuring overrides.
- Consider the needs of your project and team when configuring these settings to streamline the import process.
#Setting Variables
#References In INI files
Location: <Workspace>/Engine/Config/BaseEngine.ini:3499, section: [/Script/InterchangeEngine.InterchangeProjectSettings]
- INI Section:
/Script/InterchangeEngine.InterchangeProjectSettings
- Raw value:
(DefaultPipelineStackOverride=((Materials, "Materials"),(Textures, "Textures")),ShowImportDialogOverride=((Textures, (bShowImportDialog=False))),PipelineStacks=(("Assets", (Pipelines=("/Interchange/Pipelines/DefaultAssetsPipeline.DefaultAssetsPipeline"),PerTranslatorPipelines=((Translator="/Script/InterchangeImport.InterchangeMaterialXTranslator",Pipelines=("/Interchange/Pipelines/DefaultAssetsPipeline.DefaultAssetsPipeline","/Interchange/Pipelines/DefaultMaterialXPipeline.DefaultMaterialXPipeline")),(Translator="/Script/InterchangeImport.InterchangeGLTFTranslator",Pipelines=("/Interchange/Pipelines/DefaultGLTFAssetsPipeline.DefaultGLTFAssetsPipeline","/Interchange/Pipelines/DefaultGLTFPipeline.DefaultGLTFPipeline"))))),("Materials", (Pipelines=("/Interchange/Pipelines/DefaultMaterialPipeline.DefaultMaterialPipeline"),PerTranslatorPipelines=((Translator="/Script/InterchangeImport.InterchangeMaterialXTranslator",Pipelines=("/Interchange/Pipelines/DefaultMaterialPipeline.DefaultMaterialPipeline","/Interchange/Pipelines/DefaultMaterialXPipeline.DefaultMaterialXPipeline"))))),("Textures", (Pipelines=("/Interchange/Pipelines/DefaultTexturePipeline.DefaultTexturePipeline")))),DefaultPipelineStack="Assets",ImportDialogClass="/Script/InterchangeEditorPipelines.InterchangePipelineConfigurationGeneric",bShowImportDialog=True)
- Is Array:
False
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Runtime/Interchange/Engine/Private/InterchangeProjectSettings.cpp:12
Scope (from outer to inner):
file
function const FInterchangeImportSettings& FInterchangeProjectSettingsUtils::GetImportSettings
Source code excerpt:
else
{
return InterchangeProjectSettings.ContentImportSettings;
}
}
FInterchangeImportSettings& FInterchangeProjectSettingsUtils::GetMutableImportSettings(UInterchangeProjectSettings& InterchangeProjectSettings, const bool bIsSceneImport)
{
if (bIsSceneImport)
#Loc: <Workspace>/Engine/Source/Runtime/Interchange/Engine/Private/InterchangeProjectSettings.cpp:24
Scope (from outer to inner):
file
function FInterchangeImportSettings& FInterchangeProjectSettingsUtils::GetMutableImportSettings
Source code excerpt:
else
{
return InterchangeProjectSettings.ContentImportSettings;
}
}
const FInterchangeImportSettings& FInterchangeProjectSettingsUtils::GetDefaultImportSettings(const bool bIsSceneImport)
{
return GetImportSettings(*GetDefault<UInterchangeProjectSettings>(), bIsSceneImport);
#Loc: <Workspace>/Engine/Source/Runtime/Interchange/Engine/Private/InterchangeProjectSettings.cpp:52
Scope (from outer to inner):
file
function FName FInterchangeProjectSettingsUtils::GetDefaultPipelineStackName
Source code excerpt:
EInterchangeTranslatorAssetType SupportedAssetTypes = Translator->GetSupportedAssetTypes();
const FInterchangeContentImportSettings& ContentImportSettings = GetDefault<UInterchangeProjectSettings>()->ContentImportSettings;
for (TMap<EInterchangeTranslatorAssetType, FName>::TConstIterator StackOverridesIt = ContentImportSettings.DefaultPipelineStackOverride.CreateConstIterator(); StackOverridesIt; ++StackOverridesIt)
{
if ((SupportedAssetTypes ^ StackOverridesIt->Key) < StackOverridesIt->Key)
{
DefaultPipelineStack = StackOverridesIt->Value;
break;
}
#Loc: <Workspace>/Engine/Source/Runtime/Interchange/Engine/Private/InterchangeProjectSettings.cpp:87
Scope (from outer to inner):
file
function void FInterchangeProjectSettingsUtils::SetDefaultPipelineStackName
Source code excerpt:
EInterchangeTranslatorAssetType SupportedAssetTypes = Translator->GetSupportedAssetTypes();
FInterchangeContentImportSettings& ContentImportSettings = GetMutableDefault<UInterchangeProjectSettings>()->ContentImportSettings;
for (TMap<EInterchangeTranslatorAssetType, FName>::TIterator StackOverridesIt = ContentImportSettings.DefaultPipelineStackOverride.CreateIterator(); StackOverridesIt; ++StackOverridesIt)
{
if ((SupportedAssetTypes ^ StackOverridesIt->Key) < StackOverridesIt->Key)
{
//Update the override stack name and save the config
StackOverridesIt->Value = StackName;
GetMutableDefault<UInterchangeProjectSettings>()->SaveConfig();
#Loc: <Workspace>/Engine/Source/Runtime/Interchange/Engine/Private/InterchangeProjectSettings.cpp:124
Scope (from outer to inner):
file
function bool FInterchangeProjectSettingsUtils::ShouldShowPipelineStacksConfigurationDialog
Source code excerpt:
bool bFoundOverride = false;
bool bShowFromOverrideStack = false;
const FInterchangeContentImportSettings& ContentImportSettings = GetDefault<UInterchangeProjectSettings>()->ContentImportSettings;
for (const TPair<EInterchangeTranslatorAssetType, FInterchangeDialogOverride>& ShowImportDialog : ContentImportSettings.ShowImportDialogOverride)
{
if ((ShowImportDialog.Key == EInterchangeTranslatorAssetType::None && SupportedAssetTypes == EInterchangeTranslatorAssetType::None)
|| (static_cast<uint8>(ShowImportDialog.Key & SupportedAssetTypes) > 0))
{
//Look if there is a per translator override
const FInterchangeDialogOverride& InterchangeDialogOverride = ShowImportDialog.Value;
#Loc: <Workspace>/Engine/Source/Runtime/Interchange/Engine/Public/InterchangeProjectSettings.h:109
Scope (from outer to inner):
file
class class UInterchangeProjectSettings : public UDeveloperSettings
Source code excerpt:
*/
UPROPERTY(EditAnywhere, config, Category = "ImportContent")
FInterchangeContentImportSettings ContentImportSettings;
/**
* Settings used when importing into a level.
*/
UPROPERTY(EditAnywhere, config, Category = "ImportIntoLevel")
FInterchangeImportSettings SceneImportSettings;