Exclude from the mesh generation all mesh sections that are using materials for which the material domain isn't "Surface" (ex: decals)
Those will still be rendered properly in the material baking phase.
Prevent black patches in places where decals aren't resting on surfaces
#rb ryan.schmidt
#ROBOMERGE-SOURCE: CL 16733154
#ROBOMERGE-BOT: (v835-16672529)
[CL 16733173 by sebastien lussier in ue5-main branch]
- FMeshSceneAdapter updates
- if bThickenThinMeshes is enabled, then all instance meshes are converted to DynamicMesh and decomposed to find non-closed regions. Those regions are uniqued into separate meshes. The remaining closed geometry is separated out and kept as instanced.
- various utility functions added to support above
- previous code to explicitly 'thicken' open meshes into solids is removed. Instead unsigned distance is used to determine inside/outside and generate a 1/0 winding number
- instances are now sorted into an octree to speed up winding number evaluations
- If all meshes are closed (or effectively closed via above, ie will return integer winding number) then winding number query can early-out as soon as it finds a non-zero value
- Add hard-normals options in IGeometryProcessing_ApproximateActors (not exposed in MergeActors tool options yet)
- Added hard-normal callucation to ApproximateActorsImpl, and additional profiling
- Allow specification of actual ECollisionTraceFlag options in CreateStaticMeshUtil, instead of just a boolean
- Add FSparseDynamicOctree3::ContainmentQueryCancellable() variant that can early-exit
#rb none
#rnx
#jira none
#preflight 60a686274c320300018d3841
#ROBOMERGE-SOURCE: CL 16410125 in //UE5/Private-Frosty/...
#ROBOMERGE-BOT: STARSHIP (Private-Frosty -> Main) (v804-16311228)
[CL 16412542 by ryan schmidt in ue5-main branch]
- Add FImageAdapter, wraps TImageBuilder of different types and provides a consistent interface, so that other code doesn't need specializations for each image type
- FMeshSceneAdapter now supports the ability to detect and thicken "thin" meshes, by flattening the instances into unique mesh copies (generally necessary due to scaling). Can also now return statistics about the mesh scene, return a full flattened mesh (for debugging), and automatically generate a "closing mesh" that can help to cap off the base of mesh assemblies when trying to generate a solid/etc.
ModelingComponents:
- FWorldRenderCapture now writes via FImageAdapter instead of an Image4f
- FSceneCapturePhotoSet now stores less data for photo sets. BaseColor/Emissive/WorldNormal are 3f, Roughness/Specular/Metallic are 1f
- IApproximateActors and implementation now support optional base-capping, occluded mesh removal, geometric-tolerance simplification, thin mesh auth-thickening. Now creates MICs based on an input Material, instead of new Material. Added ability to emit a flattened debug mesh, and print debug info.
MergeActors:
- Expose above improvements to IApproximateActors
#rb none
#rnx
#jira none
#preflight 609ef005f6c6e3000144c5e2
[CL 16338550 by Ryan Schmidt in ue5-main branch]
ModelingComponents: add FMeshSceneAdapter, generates "flattened" mesh representation for a set of Actors, with support for instancing to avoid duplication, and creates minimal set of AABBTree/FWNTrees for the unique meshes. Does not make copies of any mesh data, uses MeshAdapter to allow queries directly on MeshDescriptions.
#rb none
#rnx
#jira none
[CL 16148184 by Ryan Schmidt in ue5-main branch]