Commit Graph

403 Commits

Author SHA1 Message Date
jimmy andrews
ce33cacf43 Move TConvexHull3 simplification-related settings to a separate struct, to make it easier to manage these settings (inside the convex hull code and also for other classes that call into it, like convex decomposition)
Note: These settings were all introduced post-5.3, so moving them should not require deprecation

#rb rinat.abdrashitov

[CL 27715888 by jimmy andrews in ue5-main branch]
2023-09-08 12:43:50 -04:00
xuelongmu
845f05d3aa PR #10364: Migrate to new Distance method
#jira UE-183754
#rb jimmy.andrews

[CL 27712607 by xuelongmu in ue5-main branch]
2023-09-08 11:26:29 -04:00
matija kecman
fccb4f9aff Scene sampling using a Render Capture approach
#rb jimmy.andrews
#jira UE-193152,UE-194653

[CL 27637471 by matija kecman in ue5-main branch]
2023-09-06 11:39:40 -04:00
Jimmy Andrews
7065fe745d Add support for direct construction of a simplified convex hull in GeometryCore's ConvexHull3 via:
1. A MaxHullVertices setting. If positive, the convex hull algorithm will greedily add vertices to best expand the hull, generating a simplified hull if the exact hull would exceed the specified budget.
2. SkipAtHullDistanceAbsolute/SkipAtHullDistanceAsFraction settings. If positive, the convex hull algorithm will ignore points that are closer than the threshold value, resulting in a simpler hull.

Also stop relying on the Orient3 exact predicate to find the farthest hull points (regardless of whether PointsBudget is specified) both so that the PointsBudget and SkipAtHullDistance settings can accurately compare distances from different triangles and also to fix an issue where the Orient3 magnitude was discarded when requesting a single-precision Orient3 value.

Update convex hull unit test to also test these new settings.

Also adds a small optimization the reduces the number of duplicate points considered.

#rb rinat.abdrashitov
#jira none

[CL 27604026 by Jimmy Andrews in ue5-main branch]
2023-09-05 13:49:30 -04:00
Jimmy Andrews
b2b72084ba remove unused local variable in Delaunay2.cpp
#jira none
#rb trivial

[CL 27594790 by Jimmy Andrews in ue5-main branch]
2023-09-05 09:44:22 -04:00
matija kecman
84bdab0304 Support Geometry Selection in the Tangents tool and fix some bugs
#jira UE-181650
#rb jimmy.andrews

[CL 27584315 by matija kecman in ue5-main branch]
2023-09-04 07:29:03 -04:00
frederic doll
38efdf8a4a Add missing 2d/3d features :
- ZeroValue and NoneValue in TIntVector2 (from TIntVector3)
- GridValues() in TDenseGrid3 (from TDenseGrid2)

#rb jimmy.andrews

[CL 27294375 by frederic doll in ue5-main branch]
2023-08-22 20:17:39 -04:00
george rolfe
06330436e4 [Geometry] Added profiler traces to mesh generators
#rb rinat.abdrashitov

[CL 27125582 by george rolfe in ue5-main branch]
2023-08-15 19:00:48 -04:00
semion piskarev
e5ed38cb9e DynamicMesh: Fix overlay elements not being freed and prevent changing some overlay values arbitrarily when the collapsed triangles were unset.
#rb
#jira UE-192831

[CL 27093233 by semion piskarev in ue5-main branch]
2023-08-14 19:43:18 -04:00
ryan schmidt
65908bc2d4 DynamicMesh: trivial conversion of Async/TFuture usage to new UE::Tasks
#rb tyson.brochu, jimmy.andrews
#rnx

[CL 27093045 by ryan schmidt in ue5-main branch]
2023-08-14 19:35:15 -04:00
frederic doll
4424dbfc7b Add missing feature in 2d classes based on 3d implementation :
- == and != in AxisAlignedBox2i
- default constructor in ScaleGridIndexer2

#rb jimmy.andrews

[CL 27045283 by frederic doll in ue5-main branch]
2023-08-11 16:41:38 -04:00
lonnie li
b61dc7b9df ModelingTools: Fixed gap in gutter when baking MaterialID in the Bake Textures tool.
#rb jimmy.andrews
#jira UE-191491

[CL 26813067 by lonnie li in ue5-main branch]
2023-08-03 11:48:32 -04:00
jimmy andrews
6e47422884 Add K-Means clustering to GeometryCore
Add initial PointSetFunctions to Geometry Script, including: K-Means Clustering, Flatten/Unflatten, Make Bounding Box, Transforms -> Points
Add a custom For Each-style macro to provide a more convenient interface for working with the clustering result

#rb semion.piskarev, ryan.schmidt, david.hill

[CL 26785428 by jimmy andrews in ue5-main branch]
2023-08-02 15:56:15 -04:00
david hill
c53a0fb1d8 Mesh Modeling Tools, For the "normal aware" simplification method in the modeling mode simplification tool. Makes an internal computation more robust for the specific case when triangles being collapsed are on a plane that intersects the origin.
Specifically the computations of attribute gradients now uses a local coordinate system defined in terms of the triangle faces.

#rb jimmy.andrews

[CL 26771504 by david hill in ue5-main branch]
2023-08-02 10:24:10 -04:00
jimmy andrews
389b3473ff Refine ConvexHull3's simplification algorithm to remove vertices that looked like corners vertices only due to face groups that were deleted
#rb david.hill

[CL 26740088 by jimmy andrews in ue5-main branch]
2023-08-01 11:23:57 -04:00
jimmy andrews
b8887e57ed Add a new polygon-based simplification method to ConvexHull3, and a tolerance for the initial hull build, to support use cases where we do not need an exact hull and can prioritize using fewer plane + avoiding near-degenerate planes in the output. This simplification is especially effective for cases where a large number of near-coplanar faces would exist in the exact-hull output.
#rb rinat.abdrashitov

[CL 26683043 by jimmy andrews in ue5-main branch]
2023-07-28 15:02:49 -04:00
benoit gadreau
bc524589f4 Skin Binding: fixed pos to grid/cell center indexation
+ removed occupancy grid computation when useless (this is only used for debug purposes and slows down the binding calculation)

#jira UE-187013
#jira UE-180559
#rb halfdan.ingvarsson

[CL 26506572 by benoit gadreau in ue5-main branch]
2023-07-21 04:56:52 -04:00
jimmy andrews
02a0a370eb add variant of mesh projection hull that keeps 3d hull on one side of the projection
#rb rinat.abdrashitov

[CL 26469457 by jimmy andrews in ue5-main branch]
2023-07-19 16:20:22 -04:00
frederic doll
db5d482dd2 SparseGrid2:
- create TSparseGrid2 from TSparseGrid3
- implement missing methods in FAxisAlignedBox2i
- add basic auto test

#rb jimmy.andrews

[CL 26357668 by frederic doll in ue5-main branch]
2023-06-30 18:03:33 -04:00
jimmy andrews
874bb70ad5 Add option to drive adding more negative space samples when the current samples don't cover the space identified by Voxel Search (and are farther apart than the target Sample Spacing), to make the negative space coverage algorithm better able to protect space in challenging cases where a smaller fixed number of samples would fail.
#rb rinat.abdrashitov

[CL 26314665 by jimmy andrews in ue5-main branch]
2023-06-29 11:28:58 -04:00
jimmy andrews
e1ff718256 Fix crash when spline mesh tool has a spline with too few points, and generally make polygon triangulation not crash when passed an input with too few points
#rb rinat.abdrashitov

[CL 26295671 by jimmy andrews in ue5-main branch]
2023-06-28 15:30:03 -04:00
jimmy andrews
ee45f975f2 add a 'per bone' negative space compute option to the merge hulls dataflow node, which can more reasonably target negative space for small leaf bones
#rb rinat.abdrashitov

[CL 26251571 by jimmy andrews in ue5-main branch]
2023-06-26 22:35:03 -04:00
rinat abdrashitov
b0e1560231 -GeometryScript: When creating a new SkeletaMesh asset, provide an option to use the bone attributes of the dynamic mesh to set the reference skeleton of the skeletal mesh.
-Added a convenience function for getting an array of bone names from a reference skeleton.
-Added MeshBones.h/cpp that contain utility functions to deal with dynamic mesh bone attributes

#rb halfdan.ingvarsson

[CL 26233377 by rinat abdrashitov in ue5-main branch]
2023-06-26 10:17:13 -04:00
jimmy andrews
f70dd3a744 Add a convex decomposition sphere covering mode that uses vox-solidify/difference/offset operations to better place the negative space sphere sampling
[CL 26154533 by jimmy andrews in ue5-main branch]
2023-06-21 13:34:37 -04:00
henrik karlsson
5db685f97d [Engine]
* Moved dllexport from type to methods/staticvar in all Engine runtime code. This improves compile times, memory and performance in dll builds

[CL 26082269 by henrik karlsson in ue5-main branch]
2023-06-17 18:13:06 -04:00