Navigation
API > API/Runtime > API/Runtime/Engine
FStaticMeshComponentBulkReregisterContext - More efficiently handles bulk reregistering of static mesh components, by removing and adding scene and physics debug render data in bulk render commands, rather than one at a time. A significant fraction of the cost of reregistering components is the synchronization cost of issuing commands to the render thread. Bulk render commands means you only pay this cost once, rather than per component, potentially providing up to a 4x speedup.
When a context is active, the bBulkReregister flag is set on the primitive component. This disables calls to SendRenderDebugPhysics, AddPrimitive, RemovePrimitive, and ReleasePrimitive, where they would otherwise occur during re-registration, with the assumption that the constructor and destructor of the context handles those tasks. To allow the optimization to be applied to re-created components, "AddSimpleConstructionScript" can be called to register simple construction scripts, so any components they create get added to the context as well. It's not a problem if re-reated components are missed by the context, they'll just lose performance by going through the slower individual component code path.
| Name | EBulkReregister |
| Type | enum |
| Header File | /Engine/Source/Runtime/Engine/Public/StaticMeshResources.h |
| Include Path | #include "StaticMeshResources.h" |
Syntax
enum EBulkReregister
{
Component,
RenderState,
}
Values
| Name | Remarks |
|---|---|
| Component | |
| RenderState |