Commit Graph

289 Commits (f47e71da36e29f097509a1c5dd9555ffdbc34bfb)

Author SHA1 Message Date
Chris Galvan d7574777a8 Resolved merge conflicts
Signed-off-by: Chris Galvan <chgalvan@amazon.com>
5 years ago
Mike Balfour d34d088191
Miscellaneous prefab/converter bugfixes to support TrackView (#1701)
This has a small bundle of bugfixes and improvements all based around improving prefab TrackView support:

* JsonMerger - improved the error message when patch remove operations fail to make the specific failure more obvious
Instance - swapped the order of destroying entities vs clearing the lookup tables so that lookups still produce valid results during destruction. (This could happen while creating undo caches)
* InstanceEntityIdMapper - in the case where an id isn't found, it now returns an invalid id instead of an "attempted-valid" one that still generally turned out to be not-valid
* PrefabUndo - downgraded a potential crash to an error message if for some reason the patch contains changes to an entity that doesn't currently have an alias. (This case can be caused occasionally by other bugs and error conditions)
* EditorSequenceComponent - downgraded a potential crash to an assert for the times when it tries to remove components, fails, but thinks it succeeded. (This case can currently be caused by using Maestro with Prefabs enabled)
* EditorSequenceAgentComponent - added an undo cache refresh whenever the component deletes itself, so that deleting itself during an EditorSequenceComponent destruction chain of events leaves the undo cache in the correct state.
* SliceConverter - fixed the conversion of entity references in top-level slice instance entities that refer down to nested slice entities. There was a chicken-and-egg problem in terms of which entities need to be created first to make the references and the prefab patching & serialization happy. This was worked around by creating placeholder top-level entities, then the nested slice entities, then replacing the top-level entities with the fully-realized ones.

Specific changes:
* Added more informative error message.

Signed-off-by: mbalfour <mbalfour@amazon.com>
(cherry picked from commit 672608a6c833c07295996cd9b3449825222b74d0)

* Changed the error condition to produce a "valid" invalid id instead of a deterministic but not-valid id

Signed-off-by: mbalfour <mbalfour@amazon.com>
(cherry picked from commit 3673950c949de8e067b32ddafaffd07e648a13d8)

* Guard against invalid reference assert/crash

Signed-off-by: mbalfour <mbalfour@amazon.com>
(cherry picked from commit 268d4ef3447f268a1372d07e028b9e67bac5c64e)

* Downgrade an invalid reference crash to an assert

Signed-off-by: mbalfour <mbalfour@amazon.com>
(cherry picked from commit 38c9303770845f4e863273dd6fb8fc7e83380425)

* Improved logic for handling entity references across nested slices.

Signed-off-by: mbalfour <mbalfour@amazon.com>
(cherry picked from commit 7e89a016d95fb72cb5f119e1e3768daa60e6bfb4)

* Changed order of entities.clear() call so that instance lookups are still valid during entity destruction.

Signed-off-by: mbalfour <mbalfour@amazon.com>

* Add undo cache notification when removing Maestro components.

Signed-off-by: mbalfour <mbalfour@amazon.com>
5 years ago
Steve Pham b4a2edec6a
Final update copyright headers to reference license files at the repo root (#1693)
* Final update copyright headers to reference license files at the repo root

Signed-off-by: spham <spham@amazon.com>

* Fix copyright validator unit tests to support the stale O3DE header scenario

Signed-off-by: spham <spham@amazon.com>
5 years ago
Esteban Papp 9f0bbf3b74
SPEC-7531 Change Code/CryEngine to Code/Legacy (#1634)
* git mv Code\CryEngine Code\Legacy
* redirecting CMakeLists.txt
* fixing uic warning
* Some more CryEngine mentions
* validation scripts

Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
5 years ago
Gene Walters 4e14c0069b Merge branch 'upstream/stabilization/2106' into genewalt/gitflow_210628 5 years ago
sharmajs-amzn deadf448c9
Fix for module file path (#1598) 5 years ago
amzn-mgwynn ce955715a8
Merge pull request #1543 from aws-lumberyard-dev/native-ui-changes
More specific component error messaging and modes for native UI to prevent blocking dialog in some applications
5 years ago
mgwynn 6721485946 Added parameter names to virtual function definitions for intellisense 5 years ago
Terry Michaels 21ebff5709
Updated help search and all docs.o3de.org links to o3de.org (#1594) 5 years ago
mgwynn a9ef02d29a Renaming nativeUI mode setting for all platforms 5 years ago
mgwynn 692c993bdb Incorporating review comments. Adding nativeUI setting for launchers. 5 years ago
Benjamin Jillich bf0816fb69
[LYN-4574] [LYN-4603] [LYN-4669] Saving motions and actors to json-based .assetinfo files in the Animation Editor fails (#1509)
* Fixes saving motions from within the Animation Editor
* Fixes saving actors from within the Animation Editor
* The motion event chunk of the .motion file format now also stores the event data as json (rather than XML) reducing motion file sizes (Example: 60KB motion went down to 49KB, containing only 4 motion events from 2 tracks).
* Fully backward compatible
* New motion meta data rule stores the event data directly rather than command strings or objects. This is the way that aligns with the Json paradigm and as side-effect bypasses the optionals that we use for the commands which fixes the issue.

* [LYN-4574] Adding new motion event meta data rule that stores the event data directly rather than via commands to align with the Json paradigm
* [LYN-4574] Preparing motion, event table and event track for Json serialization
* [LYN-4574] New chunk to store motion event data in Json format (fully backward compatible to XML)
* [LYN-4669] Json: Empty AZStd::vector<AZStd::shared_ptr<T>> serializes into 1x element with nullptr as data
* [LYN-4603] EMotion FX: Cannot save actors with physics or simulated object setup in Json format
5 years ago
Esteban Papp 1a5a8bd0ea
LYN-4657 OSX: Building AutomatedTesting project fails 5 years ago
mgwynn fb3940fa31 More specific component error messaging and modes for native UI to prevent blocking dialog in some applications 5 years ago
Terry Michaels 1e457928f5
Update help URLs and remove unneeded links (#1520) 5 years ago
Steve Pham 70042fcdcd
O3DE Copyright Updates for Linux Foundation (#1504) 5 years ago
John ef0f4130b7 Fix for White Box mesh disappearing 5 years ago
AMZN-koppersr c78fa200ef Addressed PR feedback. 5 years ago
AMZN-koppersr 1ac4ec656d Merge branch 'stabilization/2106' into Streamer/ConfigUpdates 5 years ago
mbalfour df648db62e Merge branch 'stabilization/2106' into mbalfour/gitflow_210622
# Conflicts:
#	Code/Framework/AzQtComponents/AzQtComponents/Components/Style.cpp
#	Code/Framework/AzToolsFramework/AzToolsFramework/Viewport/ViewportMessages.h
#	Gems/AWSCore/Code/Source/Editor/UI/AWSCoreEditorMenu.cpp
5 years ago
Benjamin Jillich 7d5a7b47ac
[LYN-3717] When pulling in an actor FBX, two entities are spawned & [ATOM-15258] Clicking and Dragging fbx file into viewport produces 2 entities (#1392)
* [LYN-3717] When pulling in an actor FBX, two entities are spawned & [ATOM-15258] Clicking and Dragging fbx file into viewport produces 2 entities
* Added another operation to the CanSpawnEntityForProduct that checks the other products and can veto the creation process.
* The model product will not create an entity in case there is already an actor exported, which prevents the issue reported by two different teams/users.
5 years ago
Esteban Papp bfd266db8f
LYN-4659 OSX: Prebuilt Editor and Asset Processor fail to launch (#1446)
* LYN-4657 OSX: Building AutomatedTesting project fails

* forgot this file

* fixing lrelease patching in mac/windows

* reverting change and disabling warning, the intention of the test is to compare to unitialized values

* Fix for dxc

* no need to disable the warning, just remove the const

* missing dependency to EditorCommon
5 years ago
AMZN-koppersr 6161b9771e Typo fixed in AZ::IO::Streamer. 5 years ago
AMZN-koppersr ee39b28dac Updates to AZ::IO::Streamer configurations
- On Windows the game now has file read sharing enabled for debug and profile builds. On Windows 10 the performance impact is neglectable, so it's been turned on to remove the need for the "cl_streamerDevMode" command line option.
- The drive that handles the virtual file system has been added to the game by default for debug and profile builds. Previously this required using "cl_streamerDevMode" which can now be omitted. A previous update already made it so that the drive would only be added if /Amazon/AzCore/Bootstrap/remote_filesystem was set to 1, but the configuration wasn't updated to reflect this.
- Removed some comments to keep the setreg files clean. The non-specialized versions of the same setreg files still have the comments.
- Removed the "DevMode" configuration (used by cl_streamerDevMode) from the game except for debug and profile. This configuration contained development tools which are not needed for release builds.
5 years ago
AMZN-koppersr 2f83fd0967 Added 2 benchmarks for StorageDriveWin
Two benchmarks were added in order to compare performance with and without file read sharing enabled on Windows. Note that the benchmark results do fluctuate. Micro-benchmarks are not ideal when profiling something like the streaming file system due to the number of threads and OS layers involved, but still provides some insights. Also note that the CPU counter is not useful in this benchmark because the main thread spends most of its time asleep while waiting for the read to complete, which is recorded as (near) zero time by the benchmark tool.
This change also reduces the log spam the tests could produce.
5 years ago
nvsickle e55580af57 Merge remote-tracking branch 'upstream/stabilization/2106' into nvsickle/MergeStabilizationJun18 5 years ago
Esteban Papp c02345fd71
LYN-4657 OSX: Building AutomatedTesting project fails (#1436)
* LYN-4657 OSX: Building AutomatedTesting project fails

* forgot this file
5 years ago
Chris Burel 6d0ef1cf57
Avoid reading from a destroyed variable (#1347)
This code iterates over the items in a vector, and if one case is met,
it mutates that same vector. This invalidates the object, as the place
where that object used to be has been moved.
5 years ago
lumberyard-employee-dm 7dabe8b6e9
Updated Several Engine Gem's CMakeLists.txt to add themselves as required Gems (#1262)
* Fixed organization of the AssetProcessor SourceAssetBrowser

Assets within the Engine Root were grouped under a '/' entry.
That has been fixed to use the relative path within the engine root for
those assets
Assets outside of the Engine Root, but on the same drive were using
absolute paths before. Now there are child entries that navigate up the
directory hierarchy to those asset locations

* Added ly_enable_gems call to Atom gems targets that are required

The DefaultLevel.prefab contains several Atom components, that require
the Atom RHI, RPI, Common_Feature, ShaderBuilder and AtomLyIntegration CommonFeatures
gems to be enabled in order to successfully process in the
AssetProcessor.

* Added ly_enable_gems call to make the Camera gem required in Tools,
Builders and Clients.

This is needed as the DefaultLevel.prefab contains an Editor Camera
Component

* Adding the ly_enable_gem call to make the Maestro gem required

CrySystem currently requires Maestro to be enabled in order to
initialize

* Added ly_enable_gems call to the SceneProcessing gem to make it required

The SceneCore and SceneData libraries that are part of the core engine
Code folder requires the SceneProcessing gem to be enabled in order to
invoke the InitializeDynamicModule hooks in DllMain.cpp in order to
initialize those libraries.

* Fixed bad argument in comment for Prefab CMakeLists.txt

* Fixed Assert in Asset Builders due to the Atom RPI Builder

The Atom RPI Builder was enabling the Asset Catalog for the ScriptAsset a second time

The Atom Feature Common EditorSystemCommonComponent.cpp which also loads
in the AssetBuilder is enabling the Asset Catalog for the ScriptAsset

Added BehaviorContext reflection to the OutputDeviceTransformType enum
to fix the BehaviorContext errors about reflecting a method that returns
such an enum

* Added TypeId output to the JsonDeserializer report message about missing
ClassData

Previously the report callback would indicate that the target type was
missing Serialization class data, but didn't indicate the TypeId of the
target type

* Added support to the ly_enable_gems function to be able to support
0 gems being enabled.

Updated the Install step for CMake to propagate any ly_enable_gems
within a CMakeLists.txt for a target into the generated CMakeLists.txt
that is made for each installed IMPORTED target

* Adding newline to the end of the Camera Gem CMakeLists.txt

* Fixing target TYPE parameter for actual Gem Modules to use the GEM_MODULE tag instead of MODULE

* Reverting change to the DESTINATION directory for the installed CMakeLists.txt to use the relative path to the installed directory

* Adding the Atom_Bootstrap gem as a required gem

The Client and GameLaunchers required the Atom_Bootstrap gem in order to create the NativeWindow
Added Atom_Feature_Common client module as a runtime dependency of the AtomLyIntegration CommonsFeature client module

* Fixed register.py --all-projects-path and --all-gems-path arguments to
NOT register projects or gems that are within a template folder
Fixed reading of old pre-1.0 o3de_manifest.json files where the
"engines" key was a json array

* Changed how the relative target source directory is calculated when that source directroy resides outside of the engine root.
The final dirname component is used with a unique SHA256 has to form a <dirname>-<8 char SHA256> folder for installing files into

* Adding newline to the end of Atom_Bootstrap CMakeLists.txt

* Moving ly_enable_gems variants for Tools and Builders inside of PAL_TRAIT_BUILD_HOST_TOOLS block

* Adding a comment to AWSCore.ResourceMappingTool target to indicate that it is not a GEM_MODULE.
Furthermore it cannot be loaded with the Gem system because the library is in a different directory the executable
5 years ago
AMZN-koppersr 6b08ab6e03 Merge branch 'stabilization/2106' into JsonSerialization/ArrayDefaultsFix 5 years ago
AMZN-koppersr 1b1a5a28f4 Using zero-initializer for defaults in the Json Serializer instead of explicit values 5 years ago
AMZN-koppersr c482c17c9e Fixed an issue with the new Json Serializer Conformity tests and Atom's materials 5 years ago
AMZN-koppersr ddc60041d3 Addressing PR feedback 5 years ago
AMZN-koppersr c360e29fbf Fixed compile errors from Clang. 5 years ago
John 15bf2d20ed Merge branch 'development' into TIF/Runtime 5 years ago
Tom Hulton-Harrop d9b1ccd323
Add align grid button to Viewport UI (#1311)
* first pass of adding grid snapping button

* update to request current grid size

* show/hide snapping option based on selection

* small tidy-up changes

* small updates following review feedback

* added some unit tests for snapping functionality and some small tidy-up/refactoring

* small refactor to ensure snap to grid ui only appears with snapping enabled

* add missing include to resolve build error

* fixes for build

* add & to make compiler happy
5 years ago
AMZN-koppersr 98ff91d854 Removed unused test structure. 5 years ago
AMZN-koppersr 8af45d28be Additional unit tests for the Json Serialization
To cover the recent changes to the return code from containers and the initialization fixes additional unit tests were added. Almost all new tests are part of the conformity test suite so that they test any custom json serializers outside of AzCore that might need to be updated due to the fixes.
5 years ago
AMZN-koppersr 780dd0df9f Container fixes for the Json Serialization
These changes fix the following:
- Containers treat new values as new objects and make sure they're initialized.
- Fixed sized containers behave slightly different and will initialize all values when a new fixed sized container is created.
- Loading any values to a container will now return PartialDefaults instead of defaults used as adding any value to a container no longer makes the container a default as the default is always an empty container.
- The previous doesn't apply to fixed sized containers as those containers are always considered to have the exact number of values they can hold.
5 years ago
AMZN-koppersr f00fa26e12 Separated initializing new and all objects in the Json Serialization
Introduced OperationFlags::InitializeNewInstance to the Json Serialization which allows custom json serializers to indicate that they need to set defaults only to new instances. Objects created to fill in a pointer are considered new objects and serializer can use the new ContinuationFlags::LoadAsNewInstance to also inform that the load is happening on a new object. Serializer that use the InitializeNewInstance flag know that a new object is begin initialized if they're called with an explicit default object.
5 years ago
AMZN-koppersr fcd989c295 Removed unit tests from bool, int and double Json Serialization
A future commit will include a generic test conformity test suite to replace these.
5 years ago
AMZN-koppersr 08abc497f3 Fixed initialization of math types for Json Serialization
Several math types in AzCore deliberately don't initialize through a constructor. This set of changes make sure that they still get properly initialized in the Json Serialization instead having random values.
5 years ago
AMZN-koppersr bc5fc9a191 Added missing reflection to NameJsonSerializerTests 5 years ago
AMZN-koppersr 716e99a8a7 Reverted string change because it cause incorrect string sizes. 5 years ago
AMZN-koppersr a98355e000 Fix PODs not initializing in Json Serialization
When pointers are used new instances are created for pod types, which will have random values at that point. The Json Serialization did not set a value for these if they were explicitly set to defaults. This change adds initialization for explicit defaults in the bool, integer and double serializer plus unit tests to verify.
5 years ago
AMZN-koppersr 6f50207b06 Updated the unit tests for the Json Serialization array fix 5 years ago
Yuriy Toporovskyy 3c46a72672 Bug fix: handle the case where a container has only default elements 5 years ago
chcurran 9f7f6e84a4 Merge branch 'stabilization/2106' of https://github.com/aws-lumberyard/o3de into carlito/stabilization/2106 5 years ago
Mike Balfour ab3aa904f0
Fixed misc slice conversion bugs
* Fixed crash caused by nesting the same slice twice
If the same slice is nested at multiple levels in the same slice hierarchy, the second conversion would reregister the prefab and crash.  Now that case is detected and the slice isn't reconverted.

* Fixed json array patches where multiple elements are removed.
The patches now generate removals from back to front, instead of front to back, so that the indices remain valid as each patch is applied.
5 years ago
mnaumov 9ca0e731f4 Merge remote-tracking branch 'upstream/stabilization/2106' into mnaumov/StabilizationJun15
# Conflicts:
#	Code/CryEngine/CrySystem/LevelSystem/LevelSystem.cpp
5 years ago