Commit Graph

258 Commits

Author SHA1 Message Date
Jimmy Andrews
4acfad1f33 add options on geometry collection creation
- make material duplication for internal materials optional
 - ask if user wants to split the mesh by connected component

+ implement the connected component split on the mesh description as part of the conversion, so we can do it before we've thrown out the mesh topology (geometry collection is a rendering rep that can't represent mesh topology; it splits at every UV seam and sharp edge)

#preflight 62fe8062f7404b55a3010ac6

[CL 21448521 by Jimmy Andrews in ue5-main branch]
2022-08-18 15:37:22 -04:00
Ryan Schmidt
9cbe007e84 GeometryCore: add support for custom per-path-point frames and scaling to FGeneralizedCylinderGenerator
GeometryScript: add new AppendSweepPolygon function, similar to AppendSimpleSweptPolygon but takes the sweep path as a list of FTransform instead of FVector, giving the caller more control over rotation and scaling along the sweep.
#rb rinat.abdrashitov
#preflight 62fd623087319bacfb1eec6d

[CL 21445763 by Ryan Schmidt in ue5-main branch]
2022-08-18 13:46:18 -04:00
Ryan Schmidt
430d6c4107 GeometryCore: add TConstObjectSharedAccess and FSharedConstDynamicMesh3 typedef for FDynamicMesh3. This template provides a way for an "owner" of an object to share it with background threads. The owner may have a TSharedPtr or some other ownership model in which it can provide a raw pointer, the TConstObjectSharedAccess can work with either. Receivers of the TConstObjectSharedAccess use a function AccessSharedObject() to access and process the shared object. See header comments for more details
#rb david.hill
#preflight 62fbd1410f2aefc97a75c0de

[CL 21414137 by Ryan Schmidt in ue5-main branch]
2022-08-16 16:55:42 -04:00
Jimmy Andrews
c0135363a4 add a Facing2 exact predicate
#rb david.hill
#preflight 62fa8554bd746abb9963712f

[CL 21400240 by Jimmy Andrews in ue5-main branch]
2022-08-15 22:08:00 -04:00
Jimmy Andrews
f29a8e9ddc fix rotating calipers failing to find extreme point due to two points on hull being close enough that they appear equal w.r.t. the extreme direction
fixes oriented bounding box not containing the output points in GeometryFlowTests

#jira UE-160567
#rb rinat.abdrashitov
#preflight 62f2c57ebc175ec68c148e6e

[CL 21298515 by Jimmy Andrews in ue5-main branch]
2022-08-09 16:57:45 -04:00
George Rolfe
93297c81ae CurveUtil explicit type fix
#jira none
#rb Matija.Kecman
#preflight 62f079e0086f90bbc45c6c36

[CL 21283434 by George Rolfe in ue5-main branch]
2022-08-09 08:28:00 -04:00
Jimmy Andrews
c21b7d49f3 Add new oriented box fit variant that starts from the fast DiTO box and optimizes the fit iteratively
+ Add ProgressCancel to box fits
+ Change editor code to use the new fit algorithms

#rb rinat.abdrashitov
#rb david.hill
#preflight 62f15a2ba035cdf05ea4d1b7

[CL 21273458 by Jimmy Andrews in ue5-main branch]
2022-08-08 15:20:28 -04:00
David Hill
de3073fb9e GeometryCore and DynamicMesh: enable implicit type conversion warnings.
#preflight 62d9635a185da2495f443808

[CL 21201226 by David Hill in ue5-main branch]
2022-07-21 11:03:29 -04:00
David Hill
8ad44307e4 GeometryCore: Update DynamicVector so the iterator can access all the data in a very large vector. Also fix type conversion warnings.
#preflight 62d82a85110da0f944755e6d
#rb Jimmy.Andrews

[CL 21200104 by David Hill in ue5-main branch]
2022-07-21 09:32:46 -04:00
David Hill
9f5eeac1e3 Geometry: Suppress type conversion warnings in third party on clang
#preflight 62d6fdcdd54af4b9a29176a2
#rnx

[CL 21185144 by David Hill in ue5-main branch]
2022-07-20 14:04:32 -04:00
Bryan sefcik
b4a6e947d8 Ran IWYU on Public headers under Engine/Source/Runtime/...
Headers are updated to contain any missing #includes needed to compile and #includes are sorted.  Nothing is removed.

#ushell-cherrypick of 21065896 by bryan.sefcik
#preflight 62d4b1a5a6141b6adfb0c892
#jira

#ROBOMERGE-OWNER: Bryan.sefcik
#ROBOMERGE-AUTHOR: bryan.sefcik
#ROBOMERGE-SOURCE: CL 21150156 via CL 21151754 via CL 21154719
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v972-20964824)
#ROBOMERGE-CONFLICT from-shelf

[CL 21181076 by Bryan sefcik in ue5-main branch]
2022-07-20 11:31:36 -04:00
David Hill
5cd1c6b9cb GeometryCore: FitOrientedBox3 - fixing implicit conversion warning.
#preflight none

[CL 21165693 by David Hill in ue5-main branch]
2022-07-19 15:02:31 -04:00
David Hill
3feeb2386c Geometry: fix clang warning on android with 3rd party code.
#preflight none
#rnx

[CL 21165207 by David Hill in ue5-main branch]
2022-07-19 14:27:26 -04:00
David Hill
612f70bd55 GeometryCore, GeometryProcessing: Add pragmas to suppress implicit type conversion warnings when compiling third party code.
Predicates.cpp and  xaltas.cpp

#preflight 62d6cf9d1133256db6e4624a
#rb Jimmy.Andrews

[CL 21164760 by David Hill in ue5-main branch]
2022-07-19 13:53:50 -04:00
David Hill
bd6eef7ea1 Geometry Core, Geometry Processing. Fix implicit cast warnings encountered during clang build.
GeometryCore: StairGenerator.cpp, SweepGenerator.{h,.cpp}, UVPacking.cpp, ParallelTransformReduce.h, CurvewUtil.h, SweepingMeshSDF.h FastWinding.h

GeometryProcessing:  Remesher.cpp, AdaptiveTessellate.cpp, UniformTessellate.cpp, GeometrySelectionUtil.cpp, MeshSimpleApproximation.cpp

#rb Lonnie.Li
#preflight 62d5bfa347779a730a46bc55

[CL 21161422 by David Hill in ue5-main branch]
2022-07-19 09:31:09 -04:00
Ryan Schmidt
f3812c4df5 GeometryCore: add FSegmentTree3, an AABBTree for 3D line segments. Supports finding Nearest Segment to 3D point, and FindNearestVisibleSegmentHitByRay() which raycasts into a set of boxes based on a "visibility" metric, similar to FGeometrySet3::FindNearestCurveToRay().
Modify FGeometrySet3::FindNearestCurveToRay to use a single visibility metric, instead of branches. The previous code was dependent on the order in which segments were processed, and for the purposes of 3D UI hit testing, did not seem to do any better than the current code.

Add basic tests for FSegmentTree3 queries.

#rb rinat.abdrashitov
#preflight 62d5db7547779a730a49033b

[CL 21156801 by Ryan Schmidt in ue5-main branch]
2022-07-18 21:55:20 -04:00
Jimmy Andrews
5214f714b5 Add a new FitOrientedBox3 algorithm
+ fixes to the similar Gte algorithm and to FitOrientedBox2
+ Add a Contain(Array) for TAxisAlignedBox3
+ Add option to save triangle adjacencies on computed 3D convex hull (since we already compute them)
+ Fix plane returned for degenerate convex hull result when Dimension=2
+ Let FitOrientedBox2 functions take a custom best-fit function, so that they can be used in the inner loop of FitOrientedBox3 when searching for the best-fit surface area

#rb david.hill
#preflight 62d56a783c3df32390b32263

[CL 21149570 by Jimmy Andrews in ue5-main branch]
2022-07-18 12:17:27 -04:00
matija kecman
f4900ae7a1 Render Capture Baking: Use depth capture to eliminate occlusion artefacts which can appear when baking non-convex shapes and look like weird sihouettes/blotches in the base color channel
Also removed artefacts that became visible after the ones fixible with a depth test were resolved. These were related to linearly interpolating data on the photosets, this was fixed since the baking framework is where texture filtering should take place

#rnx
#rb lonnie.li, ryan.schmidt
#jira none
#preflight 62d473b0dc4397d384a06bc8

[CL 21148985 by matija kecman in ue5-main branch]
2022-07-18 11:21:15 -04:00
Jimmy Andrews
bfe1c9e793 CIS fix: type mismatch between local functions in FitOrientedBox2.cpp
#preflight 62cefa3e127551eb254189bd

[CL 21074964 by Jimmy Andrews in ue5-main branch]
2022-07-13 13:35:58 -04:00
Jimmy Andrews
e24ae4281b Add functions to fit an oriented box2 to points, a simple polygon, or a convex hull
Add function to find a 2d convex hull of a simple polygon (faster than finding a convex hull of a point set)

#rb david.hill
#rb rinat.abdrashitov
#preflight 62cdb9a83c539c05f8145798

[CL 21070929 by Jimmy Andrews in ue5-main branch]
2022-07-13 10:39:04 -04:00
David Hill
3b8bc90d7e GeometryCore : fixing implicit conversion warnings, ParallelTransformReduce
#preflight 62cec5dd7822772758d449ed
#rb Tyson.Brochu

[CL 21070648 by David Hill in ue5-main branch]
2022-07-13 10:11:09 -04:00
Ryan Schmidt
715e1d357f GeometryCore:
Add FDynamicMesh3::EnableMatchingAttributes(), to expose AttributeSet::EnableMatchingAttributes() at the Mesh level
Add FDynamicMesh3::GetTriEdgeIDFromEdgeID(), helper to simplify construction of FMeshTriEdgeID identifiers
Add FRotator conversions for TQuaternion
Add TTransformSRT3::GetRotator()
Add UE::Geometry::Lerp variant for TFrame3
#rb rinat.abdrashitov
#preflight 62cc4a23f22e9d4fdf5da0f2

[CL 21047483 by Ryan Schmidt in ue5-main branch]
2022-07-11 17:10:51 -04:00
David Hill
769f6e10fd GeometryCore: DynamicVertex Attributes. fixing type promotion warnings.
#preflight 62c84de1e060ecd065bc8918
#rb Jimmy.Andrews

[CL 21011298 by David Hill in ue5-main branch]
2022-07-08 14:28:51 -04:00
Jimmy Andrews
f351c84a57 Add OrientedBox2 to BoxTypes.h + some test coverage
Add a TransformByTranspose to Matrix3, so we can efficiently inverse-transform when we know we have a rotation matrix

#rb david.hill
#preflight 62c7626b1c165b9e7bcf37f2

[CL 20996042 by Jimmy Andrews in ue5-main branch]
2022-07-07 19:52:15 -04:00
George Rolfe
30e1fad69d FProfileSweepGenerator per-point Scale
#jira none
#rb simion.piskarev
#rb jimmy.andrews
#preflight 62c4c49d3c5171c817cd868f

[CL 20953049 by George Rolfe in ue5-main branch]
2022-07-05 19:42:52 -04:00