EditorUsesSpeed
EditorUsesSpeed
#Overview
name: EditorUsesSpeed
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 5
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of EditorUsesSpeed is to control the texture encoding speed specifically for the editor environment in Unreal Engine 5. This setting variable is part of the texture encoding system, which is responsible for compressing and optimizing textures used in the game or project.
EditorUsesSpeed is primarily used within the Engine module, specifically in the texture encoding subsystem. It is referenced in the TextureEncodingSettings files, indicating its importance in managing texture encoding behavior in the editor.
The value of this variable is set in the UTextureEncodingProjectSettings class, which is a subclass of UDeveloperSettings. This suggests that it can be configured through the project settings in the Unreal Editor.
EditorUsesSpeed interacts with other variables such as CookUsesSpeed and EncodeSpeed. While EditorUsesSpeed determines the encoding speed for the editor, CookUsesSpeed is used for the cooking process. The EncodeSpeed variable is resolved based on whether the engine is running in editor mode or cooking mode.
Developers should be aware that changing this variable can affect the performance and quality of texture encoding in the editor. A faster encoding speed might result in quicker texture processing but potentially lower quality, while a slower speed could provide better quality at the cost of longer processing times.
Best practices when using this variable include:
- Consider the balance between encoding speed and quality based on your project’s needs.
- Be consistent with the encoding speed settings between editor and cook to ensure similar results in both environments.
- Test different encoding speeds to find the optimal balance for your specific project.
- Be aware that changing this setting may require a restart of the editor to take effect, as indicated by the “ConfigRestartRequired” meta tag.
- Monitor the impact on editor performance and texture quality when adjusting this setting.
#Setting Variables
#References In INI files
Location: <Workspace>/Engine/Config/BaseEngine.ini:3463, section: [/Script/Engine.TextureEncodingProjectSettings]
- INI Section:
/Script/Engine.TextureEncodingProjectSettings
- Raw value:
FinalIfAvailable
- Is Array:
False
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/TextureEncodingSettings.cpp:21
Scope (from outer to inner):
file
function UTextureEncodingProjectSettings::UTextureEncodingProjectSettings
Source code excerpt:
FastUniversalTiling(ETextureUniversalTiling::Disabled),
CookUsesSpeed(ETextureEncodeSpeed::Final),
EditorUsesSpeed(ETextureEncodeSpeed::FinalIfAvailable)
{
}
UTextureEncodingUserSettings::UTextureEncodingUserSettings(const FObjectInitializer& ObjectInitializer)
: Super(ObjectInitializer),
ForceEncodeSpeed(ETextureEncodeSpeedOverride::Disabled)
#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/TextureEncodingSettings.cpp:85
Scope (from outer to inner):
file
function static void ConstructResolvedSettings
Source code excerpt:
OutResolvedSettings->Project.FastUniversalTiling = ProjectSettings->FastUniversalTiling;
OutResolvedSettings->Project.CookUsesSpeed = ProjectSettings->CookUsesSpeed;
OutResolvedSettings->Project.EditorUsesSpeed = ProjectSettings->EditorUsesSpeed;
// Determine what encode speed to use
{
const UEnum* EncodeSpeedEnum = StaticEnum<ETextureEncodeSpeed>();
// Overridden by command line?
#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/TextureEncodingSettings.cpp:121
Scope (from outer to inner):
file
function static void ConstructResolvedSettings
Source code excerpt:
{
// Interactive editor
OutResolvedSettings->EncodeSpeed = OutResolvedSettings->Project.EditorUsesSpeed;
UE_LOG(LogTextureEncodingSettings, Display, TEXT("Texture Encode Speed: %s (editor)."), *EncodeSpeedEnum->GetNameStringByValue((int64)OutResolvedSettings->EncodeSpeed));
}
else
{
OutResolvedSettings->EncodeSpeed = OutResolvedSettings->Project.CookUsesSpeed;
UE_LOG(LogTextureEncodingSettings, Display, TEXT("Texture Encode Speed: %s (cook)."), *EncodeSpeedEnum->GetNameStringByValue((int64)OutResolvedSettings->EncodeSpeed));
#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/TextureEncodingSettingsPrivate.h:119
Scope (from outer to inner):
file
class class UTextureEncodingProjectSettings : public UDeveloperSettings
Source code excerpt:
// Which encode speed everything else uses.
UPROPERTY(config, EditAnywhere, Category = EncodeSpeeds, meta = (ConfigRestartRequired = true))
ETextureEncodeSpeed EditorUsesSpeed;
};
UCLASS(config = EditorPerProjectUserSettings, defaultconfig, meta = (DisplayName = "Texture Encoding"), MinimalAPI)
class UTextureEncodingUserSettings : public UDeveloperSettings
{
//
#Loc: <Workspace>/Engine/Source/Runtime/Engine/Public/TextureEncodingSettings.h:68
Scope: file
Source code excerpt:
ETextureUniversalTiling FastUniversalTiling;
ETextureEncodeSpeed CookUsesSpeed;
ETextureEncodeSpeed EditorUsesSpeed;
} Project;
// The resolved EncodeSpeed to use for this instance, taking in to account overrides.
ETextureEncodeSpeed EncodeSpeed;
static ENGINE_API FResolvedTextureEncodingSettings const& Get();