modeling.EnablePolyModel
modeling.EnablePolyModel
#Overview
name: modeling.EnablePolyModel
This variable is created as a Console Variable (cvar).
- type:
Var
- help:
Enable prototype PolyEdit tab
It is referenced in 3
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of modeling.EnablePolyModel is to enable or disable the prototype PolyEdit tab in the Modeling Tools Editor Mode. This setting variable is primarily used for the modeling system within Unreal Engine 5.
The Unreal Engine subsystem that relies on this setting variable is the ModelingToolsEditorMode plugin, specifically within the ModelingToolsEditorModeToolkit component.
The value of this variable is set as a console variable using TAutoConsoleVariable. It is initialized with a default value of 0, which means the PolyEdit tab is disabled by default.
This variable interacts with an associated variable named CVarEnablePolyModeling. They share the same value and purpose.
Developers must be aware that this variable controls the visibility and availability of experimental, prototype features in the Modeling Tools. Enabling this variable (by setting it to a value greater than 0) will expose potentially unstable or incomplete functionality.
Best practices when using this variable include:
- Only enable it in development or testing environments, not in production builds.
- Be prepared for potential instability or incomplete features when enabled.
- Use it to test and provide feedback on new modeling tools features.
- Disable it when working on stable, production-ready content.
Regarding the associated variable CVarEnablePolyModeling:
The purpose of CVarEnablePolyModeling is identical to modeling.EnablePolyModel. It’s used to control the availability of the prototype PolyEdit tab in the Modeling Tools Editor Mode.
This variable is used within the same ModelingToolsEditorMode plugin, specifically in the GetToolPaletteNames function of the FModelingToolsEditorModeToolkit class.
The value of CVarEnablePolyModeling is set through the console variable system, initialized with a default value of 0.
CVarEnablePolyModeling directly interacts with the modeling.EnablePolyModel variable, as they share the same value and purpose.
Developers should be aware that this variable is checked at runtime to determine whether to add the PolyEdit tab to the tool palette.
Best practices for using CVarEnablePolyModeling are the same as those for modeling.EnablePolyModel, as they serve the same purpose and have the same implications for the modeling toolset.
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Plugins/Editor/ModelingToolsEditorMode/Source/ModelingToolsEditorMode/Private/ModelingToolsEditorModeToolkit.cpp:76
Scope: file
Source code excerpt:
TEXT("Enable unsupported Experimental prototype Modeling Tools"));
static TAutoConsoleVariable<int32> CVarEnablePolyModeling(
TEXT("modeling.EnablePolyModel"),
0,
TEXT("Enable prototype PolyEdit tab"));
static TAutoConsoleVariable<int32> CVarEnableToolPresets(
TEXT("modeling.EnablePresets"),
1,
TEXT("Enable tool preset features and UX"));
#Associated Variable and Callsites
This variable is associated with another variable named CVarEnablePolyModeling
. They share the same value. See the following C++ source code.
#Loc: <Workspace>/Engine/Plugins/Editor/ModelingToolsEditorMode/Source/ModelingToolsEditorMode/Private/ModelingToolsEditorModeToolkit.cpp:75
Scope: file
Source code excerpt:
0,
TEXT("Enable unsupported Experimental prototype Modeling Tools"));
static TAutoConsoleVariable<int32> CVarEnablePolyModeling(
TEXT("modeling.EnablePolyModel"),
0,
TEXT("Enable prototype PolyEdit tab"));
static TAutoConsoleVariable<int32> CVarEnableToolPresets(
TEXT("modeling.EnablePresets"),
1,
#Loc: <Workspace>/Engine/Plugins/Editor/ModelingToolsEditorMode/Source/ModelingToolsEditorMode/Private/ModelingToolsEditorModeToolkit.cpp:1740
Scope (from outer to inner):
file
function void FModelingToolsEditorModeToolkit::GetToolPaletteNames
Source code excerpt:
}
bool bEnablePolyModel = (CVarEnablePolyModeling.GetValueOnGameThread() > 0);
if (bEnablePolyModel)
{
PaletteNames.Add(PolyEditTabName);
ExistingNames.Add(PolyEditTabName);
}