Commit Graph

285 Commits

Author SHA1 Message Date
jordan hoffmann
5abf21121d [BugFix] Modified actors are not diff'ing correctly with one file per actor
#rb dan.oconnor
#rb francis.hurteau

[CL 24451087 by jordan hoffmann in ue5-main branch]
2023-02-28 16:07:32 -05:00
thales sabino
9df15b4889 Set the asset filter in UAssetToolsImpl::CreateAssetWithDialog
This will use the Factory supported class as a filter for assets in the Save Asset As dialog. Before this change anyone using this function would get a dialog that displayed all assets in the project.

This also makes it consistent with how Save Level As works, which only shows Levels in its dialog

#jira UE-178311
#rb lauren.barnes
#preflight 63fcbf93dd78dd50f68424b8

[CL 24423110 by thales sabino in ue5-main branch]
2023-02-27 09:48:56 -05:00
logan buchy
fe50d097d6 Performance improvement to opening Context Menu and other operations looking up AssetTypeActions
There is a host of functionality in the engine requiring looking up an AssetTypeAction object that best maps to a given class.  The metric of 'best' is the AssetTypeAction whose SupportedClass is the closest to the given class in a hierarchy.
The existing implementation searches through all AssetTypeActions (at time of writing, > 200) and queries each for their SupportedClass and then chooses the one whose SupportedClass is closest to the given class.

The improvement here exploits that UClass is the type information of UObjects, and UObjects don't support multiple-inheritance (ie. only one SuperClass).  Therefore we can walk the class hierarchy from the given Class up to find
the best AssetTypeAction.  This changes the linear search (with # of AssetTypeActions) to a nominal sub-linear search (with depth of inheritance).

To be able to do that, a new map was added that associates a registered AssetTypeAction's SupportedClass with the AssetTypeAction's index in it's array.  This lets us do a constant time lookup at the cost of a bit of memory.

There is further room for improvement with the usage of UFactory's public member functions such as `GetDisplayName`, `GetMenuCategories` and similar which still necessitates this query.  Opportunity exists in the NewAssetContextMenu and in the API of IAssetTools::GetNewAssetFactories
to generate a more performance oriented data structure.  There is also some opportunity to improve the construction of a FSoftClassPath from a UClass which can be fairly expensive. These all feed into the performance issue but ultimately this is the smallest change that provides the largest improvements at the lowest risk.

Testing:
Using debugger stepped through startup/shutdown of the editor.
Artificially added duplicate registrations to check codepaths for adding AssetTypeActions that with same supported class
Added unregisters to check codepaths for unregister.  Need to be careful with editor as AssetTool module is removed very early on outside of the usual lifetime of modules in EngineLoop::Exit so most AssetTypeActions do not actually get deregistered.

#jira UE-175345
#rb ronald.koppers
#preflight 63ed3f277e76998e9a66a676

[CL 24253312 by logan buchy in ue5-main branch]
2023-02-16 04:12:20 -05:00
alexis matte
a20c1131ce Change asset tools import extension support to FNamePermissionList instead of FString. This allow to control the permissions like all the other permission.
#rb jeanluc.corenthin
#preflight 63e24fad07207b2570b72285

[CL 24049361 by alexis matte in ue5-main branch]
2023-02-07 10:49:14 -05:00
jordan hoffmann
bdc51e576e [BugFix] Static Analysis warnings
#rb dan.oconnor
#lockdown julien.marchand
#preflight 63db064f4965eb8c33de5daf

[CL 23972790 by jordan hoffmann in ue5-main branch]
2023-02-02 13:26:22 -05:00
shirley man
34519468d3 #preflight 63db295b39234ef628432297
#rb trivial
Fixed spelling typo in log message.

[CL 23964736 by shirley man in ue5-main branch]
2023-02-02 01:25:57 -05:00
jordan hoffmann
31b04b24ba [Feature/Bugfix] Support for diffing against nullptr (treated as an empty or nonexistent file)
#rb dan.oconnor
#preflight 63d83f963656ea96dc2a0a4c

#jira UE-173747
"Crash occurs when scrolling down through files in Review Changelist window upon loading of asset"
  - certain widget blueprints were crashing the review tool because we were working around the inability to diff against nullptr by constructing temprorary empty objects. This approach circumvents that problem entirely

#jira UE-173231
"Changelist Review tool allows diffing against previous revision for Deletion changes"
  - while this jira suggests that the ability to diff deletion changes is a bug, it was actually an intended feature. The real bug was that it would crash or fail to work in many cases. This has been fixed by either asset diffing against nullptr or text diffing against an empty file (depending on circumstance)

#jira UE-174610
"Reviewing Changelist with Deletion Changes results in LogLinker warnings & LoadErrors"
 - deletion changes were trying to load the new revision of files but obviously it doesn't exist because it's a deletion. Fixed by only loading the previous revision


note: since the review tool is going to be "Production Ready"  in 5.2, these changes are neccesary for stability

[CL 23924072 by jordan hoffmann in ue5-main branch]
2023-01-31 01:28:46 -05:00
alexis matte
b93fee971d Create a system to control which extension importer should support.
#rb jeanluc.corenthin
#rnx
#preflight 63d7eb4cba4fadeef006c7d7

[CL 23923306 by alexis matte in ue5-main branch]
2023-01-31 01:12:25 -05:00
johan duparc
83548e6f86 Fix typo in asset tools category
[CL 23845882 by johan duparc in ue5-main branch]
2023-01-25 06:01:10 -05:00
Alexis Matte
c780cd0119 Interchange: Integrate interchange with the AssetImportTask workflow, by allowing user to specify an override pipeline stack in the AssetImportTask::Options parameter.
Also implement a pipeline asset name option so user can specify a name when they import only one asset.

#jira UE-173881
#rb jeanluc.corenthin
#rnx
#preflight 63cfe55f6730a500ffb0815e

[CL 23829783 by Alexis Matte in ue5-main branch]
2023-01-24 09:17:49 -05:00
nick darnell
1d16e1bb1c AssetDefinition - Fixing AssetDefintions for native classes not existing.
#jira UE-165574

[CL 23824481 by nick darnell in ue5-main branch]
2023-01-23 18:48:51 -05:00
nick darnell
e6dc94a38f AssetDefinition - Fixing filter categories to include everything that hasn't yet been converted to a Asset Definition.
AssetDefintiion - Converted more blueprint / Animation blueprint stuff over to be an asset definition.

#jira UE-165574

[CL 23804692 by nick darnell in ue5-main branch]
2023-01-21 21:00:48 -05:00
nick darnell
58645cbc15 Editor Performance - Fixing a long standing issue with asset thumbnails, they've been loading the assets for a pretty long time now, because of the thumbnail editing mode. Note that thumbnail editing mode was not needed to be enabled and yet the asset would still load. This was a cause for a lot of hitches in the Content Browser.
AssetDefinition - Working on the asset definitions for blueprints/class types, iterating on the Merge API.  Bringing over more of the blueprint features into its asset definition, unregistered the Blueprint AssetType Actions.

Asset Filters - We now support categories per filter, this enables a single asset definition to correctly specify multiple filters.  For example, blueprints actually supply 4 filters, one for blueprints, but also blueprint interfaces, macros and function libraries.

[CL 23791489 by nick darnell in ue5-main branch]
2023-01-20 11:49:23 -05:00
dj schilens
6548d72e8c Advanced Copy - Optional callback when copy is complete, and expose to blueprints
* Adds a new delegate for when AdvancedCopy is complete (since Advanced Copy is async and can't return the results directly)
* Adds a new blueprint callable overload for AdvancedCopy in the AssetTools interface that optionally takes this callback

[REVIEW] [at]matt.peters [at]brooke.hubert

[CL 23781823 by dj schilens in ue5-main branch]
2023-01-19 17:12:52 -05:00
nick darnell
7c56e6c4d1 AssetDefinition - Upgrading several skeletal and animation assets to be asset definitions. Had to upgrade a few utilities that were causing the assets to still load.
#jira UE-165574

[CL 23781708 by nick darnell in ue5-main branch]
2023-01-19 17:09:58 -05:00
julien stjean
4661e3773e Fixed an issue where the metadata of the package wouldn't be migrated for some assets.
#jira UE-172915
#preflight 63c585e9a06ab115eacb2961
#lockdown aurel.cordonnier

[CL 23747902 by julien stjean in ue5-main branch]
2023-01-17 18:37:25 -05:00
nick darnell
3486296e42 AssetDefinition - When proxying to the old category system, if the advanced top level category doesn't exist, make sure to create it. Fixes FX/Niagara stuff not appearing in the top level menu.
[CL 23732858 by nick darnell in ue5-main branch]
2023-01-16 17:04:58 -05:00
nick darnell
ae774ca1eb AssetDefinition - Upgrading the Data/Curve tables to use the new AssetDefinition.
AssetDefinition - Changing how getting the SourceFiles works a bit, wanted it to be easier to just get the real data and not have to wrap it myself, and also to not need to needlessly put it into a container if it's not needed.

#jira UE-165574

[CL 23686064 by nick darnell in ue5-main branch]
2023-01-13 16:11:10 -05:00
Alexis Matte
3ae90e5430 If we import only one main asset (static mesh, skeletal mesh or anim sequence), we should select it in the content browser when the import is done.
#jira UE-165275
#rb jeanluc.corenthin
#preflight 63c1a40970575f89004e2b2e

[CL 23682334 by Alexis Matte in ue5-main branch]
2023-01-13 13:49:45 -05:00
nick darnell
3e81121a50 AssetDefinition - "UV Editor" plugin's option no longer hides if it won't work (determining it requires loading the assets), so it's just going to determine that when you fire it and fire a notification if it wont work.
AssetDefinition - Skeleton
AssetDefinition - SkeletonMesh
AssetDefinition - StringTable

#jira UE-165574

[CL 23658411 by nick darnell in ue5-main branch]
2023-01-11 20:52:36 -05:00
julien stjean
547e401ec2 Added the auto save flag to the package migration to avoid some asset from generating stuff on save.
#rb none

[CL 23635342 by julien stjean in ue5-main branch]
2023-01-10 18:11:49 -05:00
dj schilens
f346caac06 Compile AR filter only once when getting Advanced Copy sources/dependencies
- Using Advanced Copy on assets with lots of dependencies spent most of the time just compiling the AR filter
- I kept the original IAssetRegistry::UseFilterToExcludeAssets() (using an FARFilter) as it is blueprint callable

[REVIEW] [at]*matt.peters [at]jay.nakai [at]brooke.hubert

[CL 23631854 by dj schilens in ue5-main branch]
2023-01-10 15:25:00 -05:00
julien stjean
8b4de387d0 The migration can now change the writing permissions temporally to save the migrated assets.
The migration also now report in its callback the dependencies that where not exported because of the new filtering of the assets that can be migrated.
Fixed some other issues like a crash and a bad event broadcast.

#preflight 63bc235c763c6c10641898bb
#rb JeanLuc.Corenthin

[CL 23617167 by julien stjean in ue5-main branch]
2023-01-09 13:51:05 -05:00
nick darnell
32457bcb13 AssetDefinition - Converted Fonts/FontFaces, SlateBrush, SlateWidgetStyle, and Lightweight instance.
#jira UE-165574

[CL 23592534 by nick darnell in ue5-main branch]
2023-01-05 16:11:54 -05:00
nick darnell
f8bd93f6b1 AssetDefinition - Converting the Haptic AssetTypeActions to AssetDefinitions.
The copying localization ID is now an option stated as such instead of a right click showing the ID you click.  In order to show the ID the asset has to be loaded, so instead it's now a copy operation that then loads the asset before copying the ID.

Fixing a regression that stopped showing export options for unloaded assets.  The code was using FastGetAsset, which won't load the asset if unloaded.  The new code just looks at the package flags from the FAssetData, no need to attempt to load the asset.

#jira UE-165574
#jira UE-173203

[CL 23588044 by nick darnell in ue5-main branch]
2023-01-05 10:47:04 -05:00