Original CL:
Commit 1 of 3 - Decoupling ISMPool from GeometryCollection
Create a copy of the GC_ISM pool files in its own Runtime/Experimental folder. This allows our non-GC assets to take advantage of the ISMPooling and custom instance data.
#rb cedric.caillaud
[CL 35979457 by trapper mcferron in ue5-main branch]
* Some of the code still relied on possibly non-persistent GetTypeHash()
* Fixed an issue with the transient Geometry Collection ISM Pool components getting a random value for their InstancingRandomSeed property.
* Improved verbose logging to ease debugging in the future
#rb Dominic.Couture, Richard.Malo, jeanfrancois.dube
[CL 35824182 by sebastien lussier in ue5-main branch]
Removes cases of log spam where we have translucent materials that disable nanite later in the pipeline when creating scene proxies.
#rb cedric.caillaud
[CL 35515823 by jeremy moore in ue5-main branch]
Issue was that duplicating an actor in Editor would duplicate the ISMs in the object hierachy. Because the ISM Pool was marked as transient the ISMs would be left leaking when the duplicated actor's custom renderer reregistered and created new ISMs.
[CL 33139028 by jeremy moore in ue5-main branch]
Fixes this previous submission...
#rb jeremy.moore
If bAllowPerInstanceRemoval was set, an instance would be removed if the transform scale is 0 and readded when transform scale is valid. The process of removing it erases its custom instance data and there is no way to restore it when the instance is readded.
This CL makes a shadow copy of the custom instance data if bAllowPerInstanceRemoval is set which allows the process of readding the instance to also restore its custom instance data.
#changelist validated
#virtualized
[CL 31241459 by trapper mcferron in ue5-main branch]
If bAllowPerInstanceRemoval was set, an instance would be removed if the transform scale is 0 and readded when transform scale is valid. The process of removing it erases its custom instance data and there is no way to restore it when the instance is readded.
This CL makes a shadow copy of the custom instance data if bAllowPerInstanceRemoval is set which allows the process of readding the instance to also restore its custom instance data.
#changelist validated
#virtualized
[CL 31239930 by trapper mcferron in ue5-main branch]
This allows the actor containing the ISM components to have full control over the root transforms of each ISM for faster or customised processing.
#rb Cedric.Caillaud, Jeremy.Moore
[CL 29419013 by benn gallagher in ue5-main branch]
The static mesh code does PSO precaching which calls Nanite::AuditMaterialsImp() which expects to find the correct override materials.
[CL 29198348 by jeremy moore in ue5-main branch]
This will not iterate over all instances to recalculate the bounds on every instance add/remove/transform update. But instead will maintain a conservative bounds that can only grow.
This is an optimization for the case where we might have very high instance counts causing the bounds calculation to become very expensive.
It's off by default, and controlled by SetUseConservativeBounds().
Even when the option is turned on for an ISM, we keep the existing behavior whenever the number of instances is below r.InstancedStaticMeshes.ConservativeBounds.Threshold
#rb Ola.Olsson,Kenzo.terelst
[CL 29034857 by jeremy moore in ue5-main branch]
The behavior is controlled by r.ISMPool.ComponentKeepAlive.
The old free list behavior is still supported and is now controlled by r.ISMPool.ComponentRecycle.
Both cvars can be safely enabled/disabled at runtime for testing.
Note that keep alive will effectively override recycling if both are enabled, since no components are released to the recycling free list.
#rb Cedric.Cauillaud
[CL 28966562 by jeremy moore in ue5-main branch]