Commit Graph

43 Commits

Author SHA1 Message Date
ryan schmidt
b64039ce19 DynamicMesh: handle some failure cases in MeshBevel. These two fixes resolve many bevel failure cases, particularly those introduced by repeat bevels.
In some edge configurations two 'terminator' vertices (at the end of open bevel edge paths) are directly connected by a non-bevel edge that we will "open", and this creates a quad-shaped hole instead of a triangle-shaped hole (which was already handled). Detecting this case will arise is simpler before we change the topology, so it is done in BuildVertexSets(), stored in FBevelVertex::ConnectedBevelVertex, and used during mesh generation to call new AppendTerminatorVertexPairQuad function.

In BuildTerminatorVertex(), the search for a terminator split-edge may fail if the filtered triangle list ends up non-contiguous, preventing the vertex from being beveled (ie it is "stuck"). Code was added to both handle that case, and also try to force the list to stay contiguous.

#rb jimmy.andrews
#preflight 6319fbe3304480f8f8565048
#jira UE-160073

[CL 21908190 by ryan schmidt in ue5-main branch]
2022-09-08 20:09:26 -04:00
rinat abdrashitov
90cd97efcc Renaming AdaptiveTessellate.h/cpp to SelectiveTessellate.h/cpp
#rb trivial
#jira none
#rnx
#preflight 63069306a45b007ea2b6cedf

[CL 21564641 by rinat abdrashitov in ue5-main branch]
2022-08-25 11:02:41 -04:00
rinat abdrashitov
70cf962f41 Renaming AdaptiveTessellate to SelectiveTessellate to better reflect its actual functionality.
#rb jimmy.andrews
#jira none
#rnx
#preflight 6306859ac85b7fef22c52811

[CL 21551697 by rinat abdrashitov in ue5-main branch]
2022-08-24 16:46:15 -04:00
rinat abdrashitov
13c60db582 Only displace those vertices that belong to triangles affected by the tessellation.
#rb david.hill
#rb jimmy.andrews
#jira none
#rnx
#preflight 63053a840061f895d02bb5d4

[CL 21524058 by rinat abdrashitov in ue5-main branch]
2022-08-23 18:55:07 -04:00
Ryan Schmidt
c55dd6a6e2 DynamicMesh: fix VertexNormals mode in FOffsetMeshRegion. It was not properly handling the case where input mesh did not have VertexNormals attribute, the FMeshNormals being computed and passed to ::ApplyOffset() were never used.
GeometryScript: add ApplyMeshOffsetFaces and ApplyMeshInsetOutsetFaces
#rb none
#preflight 6303f6440061f895d0f67450

[CL 21510656 by Ryan Schmidt in ue5-main branch]
2022-08-23 12:31:21 -04:00
rinat abdrashitov
6606166965 Adding selective tessellation option to the Displace mesh tool to allow for tessellating triangles that belong to a certain material.
#rb lonnie.li
#rb ryan.schmidt
#rnx
#preflight 62fd1ce387319bacfb1457c3
#jira none

[CL 21427033 by rinat abdrashitov in ue5-main branch]
2022-08-17 12:59:12 -04:00
David Lesage
a4378546e5 Fix comment: FMeshMergeCoincidentEdges => FMergeCoincidentMeshEdges
#fyi ryan.schmidt
#preflight 62c75d608558075f425ea868

[CL 20994952 by David Lesage in ue5-main branch]
2022-07-07 18:41:12 -04:00
Nickolas Drake
55a66e16e0 Add Group Edge Welding: Add group edge welding by adding extra vertices to edge that doesn't have enough, then welding edge sequences
#rb Semion.Piskarev
#jira none
#preflight 62a8efbadb45e64426a03d12

[CL 20811431 by Nickolas Drake in ue5-main branch]
2022-06-24 12:52:47 -04:00
rinat abdrashitov
b057b05a3d Initial implementation of the adaptive tessellation operator with one pattern implemented.
Currently only supports the generation of the new geometry without interpolating attributes.
Added GeometryScript function for adaptive tessellation.

#rb jimmy.andrews
#jira none
#preflight 62a8bd591f6754ac09b21d10

[CL 20653109 by rinat abdrashitov in ue5-main branch]
2022-06-14 13:42:37 -04:00
Ryan Schmidt
c6c930536b GeometryProcessing: add FMeshResolveTJunctions, tries to fix cases where a boundary vertex lies on the interior of some other boundary edge, via edge splits, so that a Weld will work on the new set of boundary edges.
ModelingTools: Add option to Weld Tool to try to resolve T-junctions. Add feedback to report back the initial and final number of open boundary edges.
#rb jimmy.andrews
#preflight 62a260e48b67b148f2600dd8

[CL 20585253 by Ryan Schmidt in ue5-main branch]
2022-06-09 17:40:10 -04:00
David Hill
c7fdcbcbe8 Geometry: Intrinsic Triangulation and Geodesics. Fixed bugs related to the special case when an intrinsic triangle has only two distinct verts (as happens when an intrinsic triangle wraps the tip of a cone). Also added mesh reset methods and allowing the intrinsic mesh to optionally own a copy of the surface mesh it uses.
#preflight 6287de806c7692ac8cccee95
#rb Tyson.Brochu

[CL 20348622 by David Hill in ue5-main branch]
2022-05-24 11:10:33 -04:00
David Hill
92e5b04fa9 Remove extraneous debug code.
#preflight 62866a9615019f647746ed23
#jira none
#rnx

[CL 20284806 by David Hill in ue5-main branch]
2022-05-19 14:55:44 -04:00
David Hill
294f8cca41 Geometry Processing: Implement intrinsic mesh triangle and edge split using normal coordinates
#preflight 62851449614041edb7874304
#rb jimmy.andrews

[CL 20280431 by David Hill in ue5-main branch]
2022-05-19 10:43:03 -04:00
semion piskarev
51b6474352 MeshModelingTools: Make offset and inset work in pathological bowtie-related cases. Fix DisconnectTriangles in cases of bowties.
#rb Jimmy.Andrews, Rinat.Abdrashitov
#jira UE-150128, UE-150574
#preflight 6283abd4730e8423d125ff9a

[CL 20242223 by semion piskarev in ue5-main branch]
2022-05-17 10:13:11 -04:00
Jimmy Andrews
4993c96dfd Fix fracture messing up normals for some meshes by making the mesh boolean's simplifier preserve vertex normals
#jira UE-151297
#rb rinat.abdrashitov
#preflight 627d25564a05ef0394cc0592

[CL 20165579 by Jimmy Andrews in ue5-main branch]
2022-05-12 12:09:00 -04:00
Jimmy Andrews
8566e1a762 add convex decomposition options to Msh2Coll tool and geometryscript collision functions
#rb rinat.abdrashitov
#preflight 624751ec292f228e09196984

[CL 19594527 by Jimmy Andrews in ue5-main branch]
2022-04-01 16:04:37 -04:00
rinat abdrashitov
6149eb4a59 Added a flag to optionally recompute normal overlay or per-vertex normals after displacement in PNTriangles.
Disabled quadratically varying normal computation for 5.0.

#rb david.hill
#rb semion.piskarev
#rnx
#jira none
#preflight 61f899cb114ec25fe0c8e0f2

#ROBOMERGE-AUTHOR: rinat.abdrashitov
#ROBOMERGE-SOURCE: CL 18811717 in //UE5/Release-5.0/... via CL 18811737 via CL 18822719
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v908-18788545)

[CL 18823656 by rinat abdrashitov in ue5-main branch]
2022-02-02 05:56:24 -05:00
ryan schmidt
6ad26b69f0 rename UE::Geometry::TTransform3 to TTransformSRT3, update references
#rb none
#rnx
#jira UE-139757
#preflight 61f572d9e52a8a4a910990f1

#ROBOMERGE-AUTHOR: ryan.schmidt
#ROBOMERGE-SOURCE: CL 18784197 in //UE5/Release-5.0/... via CL 18784203 via CL 18784222
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18784226 by ryan schmidt in ue5-main branch]
2022-01-29 14:37:53 -05:00
rinat abdrashitov
b2354c8152 Fixed a misspelling of the word tessellation in the code and filenames (previously tesselation - missing an "l"). Only affected the files that import PNTriangles.h and UnifromTesselation.h (renamed to UnifromTessellation.h).
#rb jimmy.andrews
#rnx
#jira none
#preflight 61f41d586b5aea38e5bc87f7

#ROBOMERGE-AUTHOR: rinat.abdrashitov
#ROBOMERGE-SOURCE: CL 18775574 in //UE5/Release-5.0/... via CL 18775583 via CL 18775838
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18775879 by rinat abdrashitov in ue5-main branch]
2022-01-28 14:07:23 -05:00
rinat abdrashitov
90509f1b0d Fixed a compilation error in CL18443426 caused by missing files.
#rnx
#jira none

#ROBOMERGE-AUTHOR: rinat.abdrashitov
#ROBOMERGE-SOURCE: CL 18443776 in //UE5/Release-5.0/... via CL 18445115
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v897-18405271)

[CL 18445279 by rinat abdrashitov in ue5-release-engine-test branch]
2021-12-13 13:36:23 -05:00
rinat abdrashitov
4110be33f5 UniformTesselate.h/cpp
Added a new operator to subtriangulate a mesh. Its meant to take the input mesh and quickly generate final number of new vertices and triangles and interpoloate existing attributes to them.
This is would be used to replace the current recursive subdivision (using edge splits) in the DispalceMeshTool and PNTriangles operator.

DynamicMeshOverlay.h/cpp
Refactored the implementation of GetElementAtVertex from the child class TDynamicMeshVectorOverlay to the parent TDynamicMeshOverlay. The child now calls the parent.
Added a new method GetElementIDAtVertex and use it inside GetElementAtVertex since it replaces most of the logic.

OperationsTests.cpp/ExpectedRectangle.obj
Added unit tests for the UniformTesselate operator.

#rb jimmy.andrews
#rnx
#jira none
#preflight 619c0aa4fa0b360c40779025

#ROBOMERGE-AUTHOR: rinat.abdrashitov
#ROBOMERGE-SOURCE: CL 18284521 in //UE5/Release-5.0/... via CL 18284544
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)
#ROBOMERGE[STARSHIP]: UE5-Main

[CL 18284556 by rinat abdrashitov in ue5-release-engine-test branch]
2021-11-24 11:09:23 -05:00
ryan schmidt
0e961a1e23 ModelingTools: add Edge Bevel operation in PolyEdit Tool. New UPolyEditBevelEdgeActivity, and operations to initialize it in PolyEdit. This bevel operation currently uses an explicit bevel-distance rather than a live viewport interaction, and as a result required adding a separate 'apply' button inside the PolyEditTool panel (via new UEditMeshPolygonsToolAcceptCancelAction). The UX here is terrible but it's not clear we can do better in 5.0 timeframe.
GeometryProcessing: add support for beveling the border ring(s) of a triangle or polygroup-face selection. Improve polygroup assignment around bevel loops, previously the entire loop received a single polygroup which is not what the user expects in polygroup-modeling. Now a new polygroup is assigned for each unique group-edge-pair. Terminator vertices now also generate a new polygroup if there are 2 or more adjacent groups, previously behavior (assigning to arbitrary nbr) was not useful during polygroup-edting.

#rb rinat.abdrashitov
#rnx
#jira none
#preflight 6193ddccb32bbfdc50d9ed07

#ROBOMERGE-AUTHOR: ryan.schmidt
#ROBOMERGE-SOURCE: CL 18208908 in //UE5/Release-5.0/... via CL 18209386
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)
#ROBOMERGE[STARSHIP]: UE5-Main

[CL 18209422 by ryan schmidt in ue5-release-engine-test branch]
2021-11-16 13:24:21 -05:00
david hill
0e72ee8961 Dynamic Mesh, Intrinsic Mesh - add a more efficient normal-coordinate based method for tracing a small number of intrinsic mesh edges.
#preflight 618c30c2857f725e2961a5af
#rb jimmy.andrews

#ROBOMERGE-AUTHOR: david.hill
#ROBOMERGE-SOURCE: CL 18152341 in //UE5/Release-5.0/... via CL 18152405
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v889-18060218)
#ROBOMERGE[STARSHIP]: UE5-Main

[CL 18152455 by david hill in ue5-release-engine-test branch]
2021-11-11 11:47:23 -05:00
david hill
9e0ccd3133 Geometry tools: Fix GeodesicPath compile error
#rb none

#ROBOMERGE-AUTHOR: david.hill
#ROBOMERGE-SOURCE: CL 18136061 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v889-18060218)

[CL 18136142 by david hill in ue5-release-engine-test branch]
2021-11-10 15:04:25 -05:00
david hill
6e12be9318 Dynamic Mesh, Intrinsic Mesh - more robust calculation of intrinsic edges.
-  add integer-based normal coordinates for correspondence with the surface mesh and unify code that helps track the relationship between meshes.
-  rename FIntrinsicEdgeFlipMesh  FSimpleIntrinsicEdgeFlipMesh.
-  new FIntrinsicEdgeFlipMesh that uses the interger-based normal coordinates to track location of intrinsic edges relative to the surface mesh.

#preflight 618aa6de235a78d30e416b21
#rb jimmy.andrews

#ROBOMERGE-AUTHOR: david.hill
#ROBOMERGE-SOURCE: CL 18135001 in //UE5/Release-5.0/... via CL 18135020
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v889-18060218)
#ROBOMERGE[STARSHIP]: UE5-Main

[CL 18135032 by david hill in ue5-release-engine-test branch]
2021-11-10 14:22:10 -05:00