Commit Graph

103 Commits

Author SHA1 Message Date
henrik karlsson
b5164ac775 Fixes to make modules compile with IWYU. We've added to IWYU toolchain so it compiles "orphaned" headers which does not have a owning cpp file. This identified lots of headers that couldn't be compiled by themselves (or if they were to included first)
Change consist of only forward declaration and additional includes

#preflight 63789c1de30d438849c48188
#rb none

[CL 23218412 by henrik karlsson in ue5-main branch]
2022-11-21 03:22:23 -05:00
Nickolas Drake
23a3279ab2 Construction Plane Mechanic: Add Ctrl+Middle Click behavior which moves the gizmo to the clicked position in the current plane.
A raycast is performed and its intersection with the plane determines the new gizmo position.

#jira none
#rb semion.piskarev
#preflight 6373f6750c74adb48ba69b11

[CL 23155313 by Nickolas Drake in ue5-main branch]
2022-11-16 11:38:36 -05:00
matija kecman
3741003f3b RenderCaptureBaking: Improve performance when adding/removing capture channels
- When adding a new channel: Only the newly requested channel is captured, previously all enabled channels were (re)captured
- When removing an already captured channel: We no longer recompute all remaining channels, we just wipe the one that was removed


#rnx
#rb ryan.schmidt
#preflight 6372120fbf76990b71f17750

[CL 23115901 by matija kecman in ue5-main branch]
2022-11-14 05:09:53 -05:00
matija kecman
693d9f5877 MeshModelingToolset: Fix SaveGeneratedTexture2DAsset not preserving sRGB state when overwriting an exisiting texture asset
#rnx
#rb lonnie.li, ryan.schmidt
#preflight 636a5a79f56cab38c71df202

[CL 23026982 by matija kecman in ue5-main branch]
2022-11-08 08:37:52 -05:00
matija kecman
8ff5edadd1 Fix missing header guard in RenderCaptureFunctions.h (Hoard Issue 231728)
#rb david.harvey
#rnx
#preflight 6363b3f9af536047f433dc02

[CL 22951557 by matija kecman in ue5-main branch]
2022-11-03 09:02:02 -04:00
matija kecman
b39658d261 RenderCaptureBaking: Expose render capture baking function to geometry script blueprints
#rnx
#rb ryan.schmidt
#jira none
#preflight 63639fe054471d10be59b31a

[CL 22950334 by matija kecman in ue5-main branch]
2022-11-03 07:15:45 -04:00
bryan sefcik
117472780d Fixed include paths.
#jira
#preflight 634ee62fe746026e48eb077e

[CL 22621687 by bryan sefcik in ue5-main branch]
2022-10-19 06:39:08 -04:00
semion piskarev
e1d6ffd423 MeshModelingTools: Add detail customization for selection filter in PolyEd and TriEd, make loop/ring selection imply edge selection, per discussion with ux team.
#rb Lonnie.Li
#jira none
#preflight 633c994a0e66c104f1d2889e

[CL 22338072 by semion piskarev in ue5-main branch]
2022-10-04 16:48:57 -04:00
jimmy andrews
54044d3747 work around crash in physics DDC code by splitting BakeRS and Pivot tool transactions if the object has simple collision w/ convex hulls: First make a transaction with the simple collision update, then make a transaction with the static mesh change.
Only do this for the convex hull case, because the other cases do not seem to crash and splitting the transaction is not ideal.

#jira UE-158466
#rb david.hill
#preflight 633b145def7739456517a156

[CL 22322286 by jimmy andrews in ue5-main branch]
2022-10-03 20:40:33 -04:00
ryan schmidt
4ffc24f96e Modify various interfaces in ModelingComponents and GeometryScripting to use the engine FMeshNaniteSettings instead of just a "nanite proxy percentage" parameter or custom nanite settings struct. Update affected callers and Lyra assets.
This change does break existing Blueprints that have used the now-deprecated pins/properties. There is no way to gracefully handle this as deprecating the uproperty requires that it no longer be editable in the Blueprint.

#rb jimmy.andrews
#preflight 632b846e10030508061417a9
#jira UE-151882

[CL 22145808 by ryan schmidt in ue5-main branch]
2022-09-22 17:36:58 -04:00
michael balzer
2483495b86 ModelingMode: Use actor factory when creating static mesh assets
#preflight 63213620506f1a33e08bbaf9
#rb graeme.thornton, rex.hill, david.hill

[CL 22020648 by michael balzer in ue5-main branch]
2022-09-14 20:14:40 -04:00
tyson brochu
9efcc70606 ModelingComponents/Selection:
- create a new MeshTopologySelector base class. The existing GroupTopologySelector class now inherits from it, as does a new BoundarySelector class
- likewise, create a new MeshTopologySelectionMehchanic base class and have (existing) PolygonSelectionMechanic and (new) BoundarySelectionMechanic inherit from it
- the new Boundary classes use FMeshBoundary loops to define selectable loops rather than FGroupTopology

HoleFillTool:
- change to using BoundarySelectionMechanic instead of GroupTopologySelector

Misc:
- allow FMeshBoundaryLoops to fail untangling a loop with bowties but still continue processing other loops


#jira UE-144821
#rb jimmy.andrews
#preflight 63222176e93a80888cb7d3df

[CL 22013854 by tyson brochu in ue5-main branch]
2022-09-14 15:25:19 -04:00
tyson brochu
ec28b3bb51 Lattice tool: hide gizmo if only constrained vertices are selected
#jira UE-133082
#rb rinat.abdrashitov
#preflight 631f9432e07c4dc0b12df4bb

[CL 21984706 by tyson brochu in ue5-main branch]
2022-09-13 12:11:52 -04:00
jimmy andrews
713456a6f0 LWC fixes for polyedit and polypath tools: Keep preview meshes centered near the origin, with translation on the transform rather than baked, because rendering stores the mesh vertices in floating point
#jira UE-158024
#jira UE-158002
#rb tyson.brochu
#preflight 631a4804ec45fbf3d741b365

[CL 21916252 by jimmy andrews in ue5-main branch]
2022-09-09 01:37:45 -04:00
Ryan Schmidt
e579178cda ModelingComponents: refactor conversion code from ExtractCollisionGeometryTool into static functions ConvertSimpleCollisionToMeshes() and ConvertComplexCollisionToMeshes()
GeometryScript: add CopyCollisionMeshesFromObject function, extracts meshed collision shapes or complex collision from various object types as a UDynamicMesh
#rb none
#preflight 62ffc256c85b7fef22f671cc

[CL 21460263 by Ryan Schmidt in ue5-main branch]
2022-08-19 13:20:33 -04:00
semion piskarev
3cc8f15db4 MeshModelingTools: Various CubeGrid improvements.
- Made the tool Accept/Cancel.
- Added the ability to set block size at current power.
- Added ability to initialize the grid from a given actor, initialized to current target.
- Added the option for the grid sizes to follow the default editor grid (1, 5, 10, 50, 100, etc).
- Allowed global mode for gizmo manipulation, to allow editor grid snapping to work.
- Removed the non-useful selection plane tolerance setting

#rb Jimmy.Andrews
#jira UE-153345, UE-152029
#preflight 62f163f9185da2495f83831e

[CL 21274412 by semion piskarev in ue5-main branch]
2022-08-08 16:01:14 -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
Ryan Schmidt
dc5b1dcca4 add file that was missed in CL 21117964
#rb none
#preflight skip

[CL 21119976 by Ryan Schmidt in ue5-main branch]
2022-07-15 20:04:27 -04:00
Ryan Schmidt
986547914e Move GeometrySelection.h and GeometrySelectionUtil.h to GeometryProcessing plugin. Move types in GeometrySelection.h into UE::Geometry:: namespace. Fix up usage sites.
#rb none
#preflight 62d1c7222e3e5993c351a126

[CL 21117964 by Ryan Schmidt in ue5-main branch]
2022-07-15 17:53:52 -04:00
Ryan Schmidt
6032c02f0e ModelingMode: add Delete command for current Mesh Selection
ToolsFramework:
add UInteractiveCommand and UInteractiveCommandArguments types, base classes for 'interactive commands' which are intended to be used for atomic actions, ie stateless, no user interaction, etc
ModelingComponents:
add UGeometrySelectionEditCommand/Arguments, this is a UInteractiveCommand that uses a FGeometrySelection as an argument
add UGeometrySelectionManager::CanExecuteSelectionCommand() and ExecuteSelectionCommand()

MeshModelingTools:
add UDeleteGeometrySelectionCommand, deletes selected mesh geometry by converting input selection to list of triangles

ModelingToolsEditorMode:
add Delete command to ModelingMode and UI. ModelingToolsEditorMode currently is keeping active command set alive via new UModelingToolsEditorMode::ModelingModeCommands member.

#rb none
#preflight 62d195b9a66919b6701d89a8

[CL 21113757 by Ryan Schmidt in ue5-main branch]
2022-07-15 13:49:13 -04:00
Ryan Schmidt
9c4efbe435 ModelingComponents: Add UE::Geometry::GetCurrentGeometrySelectionForTarget() util function to query current UGeometrySelectionManager for active Selection. Modify UE::Geometry::GetCurrentToolInputSelection() to return converted selection from UGeometrySelectionManager instead of using the now-disabled UPersistentMeshSelectionManager. Deprecate UPersistentMeshSelectionManager and related functions/classes.
#rb none
#preflight 62c60a31892b4d4f308ca646

[CL 20983305 by Ryan Schmidt in ue5-main branch]
2022-07-07 09:44:46 -04:00
Ryan Schmidt
6c6315d4e5 ModelingMode: add support for new element-level geometry selection system for DynamicMeshComponents
New UModelingSelectionInteraction provides click-to-select and gizmo interactions for current set of mesh objects that support selection, by manipulating the active UGeometrySelectionManager.

ModelingMode now creates a UGeometrySelectionManager and UModelingSelectionInteraction on mode startup, if 'persistent selections' are enabled in the project settings. This replaces the previous persistent selection system/manager, which is no longer created/registered.
UModelingToolsEditorMode::ShouldDrawWidget() and ::ComputeBoundingBoxForViewportFocus() updated to support active Selection.

Functions ::OnToolsContextRender(), ::OnToolPostBuild(), ::GetGeometrySelectionChangesAllowed(), ::TestForEditorGizmoHit(), ::UpdateSelectionManagerOnEditorSelectionChange() added to support selection system.

FModelingToolsEditorModeToolkit will add buttons for selection control if Persistent Selections are enabled. Dynamic updates to Palette based on active selection are initiated by EdMode. Currently the selection-actions palette is empty.

#rb none
#preflight 62c5f20c3c5171c81715f5f4

[CL 20973334 by Ryan Schmidt in ue5-main branch]
2022-07-06 16:54:57 -04:00
David Hill
4c6d43fe88 MeshModelingToolSet - DynamicMeshSelector. Make sure the correct version of shutdown is called. Fixes a static analysis warning
#jira UE-158215
#preflight 62c4e80f2f31b87c6cc5f9f8
#rb Jimmy.Andrews

[CL 20955739 by David Hill in ue5-main branch]
2022-07-05 21:51:47 -04:00
Ryan Schmidt
96bcffd475 ModelingComponents: add new geometric-element Selection system
GeometrySelection.h/cpp: FGeometrySelection, FGeometrySelectionEditor, representation and manipulation of a generic element-level selection, stored as a set of uint64. Editor makes changes to Selection while tracking deltas.
GeometrySelectionUtil.h/cpp: utility and helper functions for editing/processing a mesh+selection
GeometrySelector.h: FGeometryIdentifier type used to identify target objects with element-level selection support. IGeometrySelector interface that defines API for element selection for a type of target object. Factory type for spawing instances. IGeometrySelectionTransformer interface that defines API for element-level transformation
GeometrySelectionManager.h/cpp: UGeometrySelectionManager that maintains set of 'active targets' with associated Selector, Selection, and SelectionEditor, and provides high-level API for creating and querying element selections, 3D transforms of selections, selection undo/redo, and (currently) limited debug rendering
GeometrySelectionChanges.h/cpp: FChange types for element selection changes
DynamicMeshSelector.h/cpp: implementation of IGeometrySelector for UDynamicMesh/Component

#rb jimmy.andrews
#preflight 62bdb9cbb024a2608c38b72d

[CL 20896967 by Ryan Schmidt in ue5-main branch]
2022-06-30 12:09:44 -04:00
Ryan Schmidt
636abcceee SceneSnappingManager: add ::PauseSceneGeometryUpdates() and ::UnPauseSceneGeometryUpdates(), these temporarily disable/re-enable geometry updates (eg BVH rebuilds) on DynamicMeshComponents, for use in live-edit situations where we can't defer mesh updates (because render geometry needs to update) but don't want a per-frame BVH build
#rb none
#preflight 62ab7bb82804d6adf7f72f97

[CL 20692560 by Ryan Schmidt in ue5-main branch]
2022-06-16 15:25:58 -04:00