Commit Graph

256 Commits (6766d10d1be624e65f6e60a5ca8771c1b34da478)

Author SHA1 Message Date
Qing Tao 85222130d4
LYN-4007 Editor crashes when entering the Game Mode with two Box Shape entities with Game View enabled (#974)
The crash was caused by using gpu query across command lists.
5 years ago
Doug McDiarmid 1d3322f881 Merge branch 'main' into Atom/dmcdiar/ATOM-15517 5 years ago
Chris Santora 755d1b7abc Merge remote-tracking branch 'upstream/main' into Atom/santorac/MaterialTypeCleanup 5 years ago
Chris Santora 7e023c3676 ATOM-15133 "Clean Up EnhancedPBR"
Updated material type files for StandardPBR, EnhancedPBR, and Skin to align with each other as much as possible.
There were minor cases like some property settings were different, properties in different order, comments, and formatting.
There were major cases as well, like EnhancedPBR using clunky built in functors where lua functors would be better, property visibility state wasn't right, properties were missing, etc.

I also added a new HasShaderWithTag function for lua functors. This is used in StandardPBR_ShaderEnable.lua to allow this script to be used for both StandardPBR and EnhancedPBR (EnhancedPBR doesn't have the low end pipeline shaders).
5 years ago
Doug McDiarmid 17e9c17f31 Added Occlusion Culling Planes and RPI Culling support for Masked Occlusion Culling 5 years ago
Nicholas Van Sickle d1863c6c5b
Restore Editor viewport icon rendering (#879)
This introduces an EditorViewportIconDisplayInterface that will eventually be used to outright remove CIconManager, it provides a simple interface for loading 2D image assets and rendering them on-screen. It also introduces AtomBridge::PerViewportDynamicDraw for getting a dynamic draw instance on a per-viewport basis
5 years ago
galibzon 0678dec64e
[ATOM-15618] Shader Build Pipeline: Add UnitTest To Validate Shader C… (#918)
* [ATOM-15618] Shader Build Pipeline: Add UnitTest To Validate Shader Compiler
Argument Processing Introduced With The New Supervariant System

- Added new test suite in
  Gems/Atom/Asset/Shader/Code/Tests/SupervariantCmdArgumentTests.cpp

- Refactored and improved the previously existing classes:
  GlobalBuildOptions, PreprocessorOptions and ShaderCompilerArguments
  to work well with the new ShaderSourceData::SupervariantInfo.

- Moved command line argument processing function out of
ShaderCompilerArguments and into its own utility namespace in
Atom/RHI.Edit/Utils.h

Signed-off-by: garrieta <garrieta@amazon.com>
5 years ago
jiaweig 50085d0487
Merge pull request #823 from aws-lumberyard-dev/Atom/jiaweig/ATOM-15125_UV_Tangent
ATOM-15125 Support Reorder of Tangent Streams
5 years ago
jiaweig f64bd999e0 Move UvStreamTangentBitmask to new files. 5 years ago
antonmic 6388277cd1 Fixed ImGui Pass as well as how exposure pass enables itself 5 years ago
jiaweig 13893e77f3 merge main 5 years ago
Chris Santora bffc72794b ATOM-15597 Accessing Material Instance Panel Crashes Editor
There were two issues fixed here. First, I broke the material inspector with my changes at 53188a12da which added support for hiding entire property groups. I'm not sure how this happened because I definitely tested the MaterialComponent's material inspector. Perhaps there was a bad merge or something otherwise got clobbered after testing and before committing. Anyway, this issue was I accidentally delete the code that prepared the list of material properties for functor processing.

The second issue was the MaterialFunctor class needs to return null when metadata can't be found; it was proceeding to dereference an end iterator.

Testing:
Successfully opened the material inspector through the MaterialComponent. Was able to change property flags in the inspector and see other properties change visibility as expected.
5 years ago
jiaweig c3794ca96c Addressed review comments. 5 years ago
Chris Santora 8799d1ab54 Merge branch 'main' into Atom/santorac/NewLayeringWorkflow 5 years ago
galibzon 256df54575
[ATOM-15276] Shader Build Pipeline: Add Shader Supervariant System (#749)
* [ATOM-15276] Shader Build Pipeline: Add Shader Supervariant System.

Added ShaderAssetBuilder2 & ShaderVariantAssetBuilder2.

Added ShaderAsset2, ShaderVariantAsset2.

Eventually they will be the only builders. AzslBuilder &
SrgLayoutBuilder will be removed.
ShaderResourceGroupAsset will be removed. ShaderAssetBuilder &
ShaderVariantAssetBuilder will be replaced.

Signed-off-by: garrieta <garrieta@amazon.com>
5 years ago
Chris Santora f3099aa7d5 Merge remote-tracking branch 'origin/main' into Atom/santorac/NewLayeringWorkflow 5 years ago
pruiksma 5802c4e1dc Merge branch 'main' into pruiksma/ATOM-15561 5 years ago
Tommy Walton ded39be57e
Merging WrinkleMask support from 1.0 to main (#680)
Added a loop to the skin shader that will sample from wrinkle masks, multiply them by a weight, combine them, and use them instead of vertex colors for wrinkle map blending

Added an array of masks, an array of weights, and a wrinkle mask count to the DefaultObjectSrg. -Will create a follow up task to handle this a better way.

Removed motion vector (for now) from skin.materialtype since we're not using them, and removed depthtransparent since skin doesn't support transparency

Added an interface to the MeshFeatureProcessor to get the object srg

Wrapped srg->Compile in if(srg->IsQueuedForCompile()) to prevent compiling twice --This doesn't stop a race condition if both happen at the same time, but that is at least far less likely. It will need a better solution later.

Added a function to the MorphTargetExporter that will check to see if a texture that matches the blend shape name exists in a particular folder, and adds a reference to that image to the MorphTargetMetaAsset --Only supports .tif, and doesn't automatically re-process the .fbx if the folder is updated. These can be improved in later iterations

Added a null check in MaterialTypeSourceData.cpp to fix a crash I ran into

Added a for loop in two places to look for the first submesh that has a morph target, instead of just using the first to check if a lod has morph targets or not. --I have a better fix for this, but it involves more areas of the code, so I'm saving that for another change.

Modified AtomActorInstance to look for any morph targets that have a wrinkle mask reference

Then each frame, for any morph targets with non-zero weights that also have wrinkle masks, it updates the mask array, weights, and count on the object srg.
5 years ago
jiaweig 775b7d048b Add support for tangent stream pairing with the first UV from the model. 5 years ago
antonmic a4e1b40e88 Merge branch 'main' into Atom/antonmic/lowEnd 5 years ago
pruiksma dff3efbfca [ATOM-15561] Adding AZ_Error for unhandled pass binding failure case. 5 years ago
antonmic 242a10dd10 addressed PR feedback 5 years ago
Nicholas Van Sickle 46c0c35c26
Merge pull request #734 from aws-lumberyard-dev/nvsickle/DebugInfoDisplay
Restore debug rendering to the viewport
5 years ago
Vicky 1c575763c7
ATOM-4661 Improvement with pass templates registration from data (#735)
* ATOM-4661 Improvement with pass templates registration from data
- Update PassLibrary so it can load pass templates from more than one files and report duplicate pass templates.
- Added load templates events to pass system so the handlers from any gems can load their own pass templates.
- Added PassSystemInterface::OnReadyLoadTemplatesEvent::Handler in FeatureCommon gem's CommonSystemeComponet to load the PassTemplates.azasset in featureCommon gem.
- Misc: moved BindlessPrototypeSrg.asli from RPI to ASV project; fixed an assert issue when exit ASV
5 years ago
nvsickle cc986f563a Merge remote-tracking branch 'upstream/main' into nvsickle/DebugInfoDisplay 5 years ago
Chris Santora 1684c338b2 More minor cleanup in MaterialFunctor.cpp 5 years ago
moudgils da8f5849aa Merge branch 'main' into Atom/moudgils/FixTextureArray 5 years ago
Chris Santora 70c8ef99ef Updates in response to code review, from gadams3.
Cleaned up code around MaterialFunctor's QueryMaterialPropertyMetadata and QueryMaterialPropertyGroupMetadata.
Removed unnecessary "groupHeader->setObjectName(...)"
Simplified code in MaterialInspector::OnDocumentPropertyGroupVisibilityChanged.
5 years ago
Chris Santora 37a1b77d50 Merge branch 'main' into Atom/santorac/NewLayeringWorkflow 5 years ago
Chris Santora 53188a12da Made StandardMultilayerPBR hide a layer's property groups when that layer is disabled.
ATOM-14688 Disable Individual Layers

- Added new SetMaterialPropertyGroupVisibility functions to the material functors.
- Updated the MaterialFunctor::EditorContext to include parameters for handling material property group metadata.
- Updated the material inspector(s) to apply the property group visiblity changes from the material functor, to hide or show the property groups.
- Moved some code from MaterialPropertyDescriptor.h/cpp to a new MaterialDynamicMetadata.h/cpp, since these aren't really related to the MaterialPropertyDescriptor code. It's more for material functors to use.
- Also fixed the casing for the "GetMaterialPropertyValue_Image" lua function, since I was already in this code (ATOM-14793 "Fix Inconsistent Casing For LuaMaterialFunctorRuntimeContext")

Tested in MaterialEditor and in in the main Editor's MaterialComponent property override inspector.
5 years ago
nvsickle 559798251d Merge remote-tracking branch 'upstream/main' into nvsickle/DebugInfoDisplay 5 years ago
Tom Hulton-Harrop f9fb61cc5d
Fix issue with viewport interaction ordering and viewport matrix changed handler (#695)
* fix for ctrl+mouse-wheel to cycle transform modes in the viewport

* ensure correct callback function is invoked

* remove redundant check in CameraInput
5 years ago
dmcdiarmid-ly a0cb4714c0
Merge pull request #659 from aws-lumberyard-dev/Atom/dmcdiar/ATOM-15511
[ATOM-15511] Change AtomSampleViewer BindlessPrototype sample to use an unbounded array
5 years ago
Tom Hulton-Harrop b5e5a3bfee
More camera fixes for the new CameraInput system (#667)
* use new ViewportContext interface to set camera transform on load

* WIP fixes for camera viewport handler callbacks

* disable synchonization with old camera when new camera system is enabled

* further updates to camera-input

* ensure event is signalled when camera transform is set

* updates to ModernViewportCameraController

* fix for right click menu appearing with camera

* updates following review feedback

* convert std:: usage to AZStd::
5 years ago
antonmic 8e4d0d73dc Good working state, but material always emmits low end draw item 5 years ago
Vicky 01b2798fe1
Integrate from 1.0 to main: LYN-3436 AutomatedTesting.GameLauncher crashes at launch if assets are not all processed (#612)
* Atom/qingtao/lyn 3436 (#558)

* LYN-3436 AutomatedTesting.GameLauncher crashes at launch if assets are not all processed

Change RPISystem so that the application would exit if the RPI system couldn't load critical assets.
Added code to avoid the GetLayout crash when layout for each platforms were not ready.
Added LoadCriticalAsset function to force compile and load critical assets.
Added default value to viewport size for ViewportContext.

* Change RPISystem asset initialization order so it returns earlier when those critical assets are not ready
5 years ago
nvsickle 64d53d1fab Fix View::GetCameraTransform 5 years ago
nvsickle dca2294b36 Move GetCameraTransform into RPI::View. 5 years ago
moudgils 521a486ee4 Fixes to ios build 5 years ago
dmcdiar 1e860e7c82 Change BindlessPrototype to use an unbounded array 5 years ago
sourjon cd0628f513
Merge pull request #565 from aws-lumberyard-dev/Prefab/PhysX/ColliderFixes
Prefab/physx/collider fixes - Addresses collider crashes on starting in game mode
5 years ago
jonbeer 3751493862 Fixing ATOM RPI issue with new serialization changes 5 years ago
Chris Santora a940f12183 Merge branch 'main' into Atom/santorac/ShaderCollectionItemFixMain-LYN-2905 5 years ago
Vicky 1681e97a0c
ATOM-15369 LYN-3352 Expose sorting paramers to DynamicDrawContext's draw functions (#451) (#463)
* ATOM-15369 Expose sorting paramers to DynamicDrawContext's draw functions
 LYN-3352 LyShine: First element in Hierarchy does not properly draw in UI Editor

Add function to DynamicDrawContext to support set sort key for followed draw calls.
Use different sort key for background draw and top layer draw in UI canvas.
5 years ago
AMZN-koppersr 5e4094b258
Revamped AzFramework::Scene (#332)
Updated AzFramework::Scene to allow it to serve as the one-stop location for localized singletons. Localized singletons in this case are instance that can only occur once in an environment but multiple times within an application. As an example, this allows settings up a single camera per viewport for instance.

Highlights of changes:

Replaced the original ebuses with interfaces and events for easy of use and performance.
Removed the Entity Context specific code and moved that to new locations within the Entity Context itself.
Allowed basic inheritance. If a subsystem isn't found in a scene the parent can optionally be searched.
Scenes can enter a zombie state and avoid immediately being deleted. This is needed for situations where subsystems can't be destroyed until async calls have been completed.
5 years ago
Mike Balfour 18c2069b64
Merge pull request #359 from aws-lumberyard-dev/mbalfour/misc-viewport-fixes
ViewportContext - fix ebus connections
5 years ago
Vicky e4509dbe68
Merge pull request #322 from aws-lumberyard-dev/Atom/qingtao/ATOM-6088
ATOM-6088 Unified approach to send draws to a single viewport

    Created a template class TagRegistery which implements the previous DrawListTagRegistry. The template is used for both DrawListTagRegistry and DrawFilterTagRegistry
    Added DrawFilterTag to DrawItemKeyPair
    Added DrawFilterMask support in DrawPacket and DrawPacketBuilder
    Added CreateDynamicContext for render pipeline which allows draw to selected render pipeline.
    Updated RasterPass's BuildCommandListInternal function to filter draw items for its owner RenderPipeline.
5 years ago
qingtao 60db6b55d0 Address feedback of PR for ATOM-6088.
* Rename DrawItemKeyPair to DrawItemProperties.
* Switch back to use Ptr<DrawListTagRegistry> instead of DrawListTagRegistry
* Updated some comment.
5 years ago
mbalfour 251929d071 Two misc bugfixes:
1) RayTracing will sometimes crash by dereferencing a null ptr.  This guards against it.
2) ViewportContext was missing some BusConnect / BusDisconnect calls.
5 years ago
qingtao 12f528d744 ATOM-6088 Unified approach to send draws to a single viewport
- Created a template class TagRegistery which implements the previous DrawListTagRegistry. The template is used for both DrawListTagRegistry and DrawFilterTagRegistry
- Added DrawFilterTag to DrawItemKeyPair
- Added DrawFilterMask support in DrawPacket and DrawPacketBuilder
- Added CreateDynamicContext for render pipeline which allows draw to selected render pipeline.
- Updated RasterPass's BuildCommandListInternal function to filter draw items for its owner RenderPipeline.
- Updated RHI unit tests.
5 years ago
Chris Santora 9db65478ee LYN-2905 Script Canvas: Saving a graph that contains an Item Variable crashes the Editor
Set the reflection name for ShaderCollection::Item to "ShaderCollectionItem" so it doesn't show up as just "Item" in Script Canvas. Note that this change was made in main only, not in the 1.0 branch, to de-risk the beta branch.

Testing:
Ran the repro steps for the bug, and ran the ShaderManagementConsole's GenerateShaderVariantListForMaterials.py script successfully.
5 years ago
Chris Santora 6b3abe3c56 Cherrypick from 1.0 branch of...
6c2a243cdc3dbe8cf5cb2ec9063585255607f8e5

LYN-2905 Script Canvas: Saving a graph that contains an Item Variable crashes the Editor

Added a check for m_shaderAsset.IsReady() before trying to use the asset data. Also added a check before calling BlockUntilLoadComplete() to prevent reporting an error message unnecessarily.
5 years ago
Aaron Ruiz Mora 45fbc86d2d
Fix cloth with MeshOptimization ON
- Reexport cloth assets with AssImp ON. These was necessary because AssImp collects a different name for the color streams than FbxSDK and therefore they needed to be reassigned in the cloth rule.
- Adding '_optimized' string to a global variable and using StringFunc RChop to remove it for a string.
5 years ago
Chris Burel 61fe298319
Merge pull request #197 from aws-lumberyard-dev/filesEndInNewlines
Add newlines to the end of all files
5 years ago
Nicholas Van Sickle 3eaa749191
Merge pull request #277 from aws-lumberyard-dev/nvsickle/MoreMainFixes
Cherry-pick several 1.0 viewport fixes to main
5 years ago
Chris Burel 28170ffe41 Add newlines to the end of all files 5 years ago
Benjamin Jillich 0fa00a117c
[ATOM-14477] Add clone function to model and/or model asset (#135)
* Added clone methods for the buffer, model lod and model assets.
* Cloning works via the creators.
* Mesh handle/instance now knows about the model asset it originated from as well as the cloned model asset that we need for instancing until instancing works without the dependencies to the asset ids.
* MeshComponentRequestBus returns the original asset id and the model asset. If you need access to the clone, go by the model.
* Cloth component mesh now gettings its model asset from the model as it needs to work on the clone.
* Moved the requires cloning function from the mesh loader in the mesh feature processor to the mesh component controller.
* As we need the model asset to be loaded before we can check if it requires cloning or not, we couldn't pass in a bool from the controller but had to use a callback.
* Using asset hint instead of asset id for the model lod asset creator error.
* Storing a map of source buffer asset ids and the actual cloned buffer assets rather than just their ids.
* Using the buffer assets from the new map directly and removed the search process in the mesh loop where the asset views are created.
* Fixed the vegetation mocks.
* Using the actor's mesh asset when emitting the on model ready event for the mesh component notification bus.
* Mesh components notifications connection policy changed to adapt to cloned model asset.
* Handling empty meshes in model lod asset creator.
* Removed the requires cloning callback from the mesh feature processor and made it a parameter to the acquire mesh function
* Fixing mocks and unit tests
5 years ago
nvsickle 12468fd81a Fix spacing from merge 5 years ago
nvsickle f835372c0f Fix capitalization... 5 years ago
nvsickle 228fa7ff6b Fix search and replace fail 5 years ago
nvsickle e6cfe36a03 Fix typo 5 years ago
nvsickle 9e6244dc99 Fix game mode camera components not working in-Editor
Ensures RPI::View updates always make it back to the ViewportContext, even if you talk directly to the View
5 years ago
rgba16f ca1a684c95
Merge pull request #266 from aws-lumberyard-dev/FixGameLauncherConsole
Fix GameLauncher Imgui DebugConsole so that it renders
5 years ago
rgba16f 0bf7c29506 Fix GameLauncher Imgui DebugConsole so that it renders 5 years ago
greerdv 62a3b7635b Merge branch 'main' into non-uniform-scale-mesh 5 years ago
greerdv 496891b4c0 feedback from PR 5 years ago
Tommy Walton b95865b2d8
Simple Motion component doesn't animate actors (#179)
Buffers that have InputAssembly bind flags but also have ShaderRead flags should create buffer views
5 years ago
nvsickle ba5e0170a2 Fix ImGui rendering in-Editor
-Ensure ViewportContext rendertick notifications always fire
-Use viewport size to determine ImGui resolution, ensure OnViewportSizeChanged is always up-to-date for the default viewport context
5 years ago
greerdv fd8b42c45e Merge branch 'main' into non-uniform-scale-mesh 5 years ago
qingtao c9153b0353 ATOM-15272 Running game with Actor spams asserts in the log resulting in low framerate
The condition was setup wrongly when introducing DynamicInputAssembly.
5 years ago
greerdv e497b7ac33 Merge branch 'main' into non-uniform-scale-mesh 5 years ago
dmcdiar 46b9f1934d Removed commented line 5 years ago
dmcdiar 456bcb3bf9 Updated the EnvironmentCubeMapPipeline to match recent changes to the MainPipeline.
Set the multisample state on the EnvironmentCubeMapPipeline render settings.
5 years ago
Vicky 9195abe5c6
Merge pull request #102 from aws-lumberyard-dev/Atom/qingtao/ATOM-15252
ATOM-15252 [Atom 0.8.5] Track View capture crashes when scene contains certain postfx
5 years ago
hershey5045 8378f52ba6
Fix bug in ShaderVariantAssetBuilder. Add cvar in MeshDrawPacket class. (#61)
Fix bug in ShaderVariantAssetBuilder. Add a console variable to force root shader variant usage.
5 years ago
qingtao 0aae99c491 Merge branch 'main' into Atom/qingtao/ATOM-15252 to first the blast test issue in AR. 5 years ago
qingtao 8e34d784e6 ATOM-15252 [Atom 0.8.5] Track View capture crashes when scene contains certain postfx
The crash was because the "BlendColorGradingLutImageAttachmentId" attachment got imported to attachment database twice.
This fix avoids import this attachment twice. It also avoid crash but only report a warning if an imported attachment wasn't used in any scope.
Enable both RHI and RPI validation (no visiable performance impact observed.
5 years ago
moudgils ca86068d83 Minor update 5 years ago
moudgils d0435b4489 Minor update 5 years ago
moudgils 05359187c4 Test update 5 years ago
moudgils 89a935cd29 Minor update 5 years ago
moudgils 3c631e4a85 Merge branch 'main' into Atom/moudgils/BumpResourcePoolbuilder 5 years ago
Vicky 8743155b73
Merge pull request #76 from aws-lumberyard-dev/Atom/qingtao/ATOM-13791
ATOM-13791 Editor: ImGui profiling tools doesn't work correctly due to disabled RenderPipelines
LYN-2908 Pressing Home button crashes the Editor
5 years ago
moudgils abf26eede1 Bump REsourcePoolBuilder as the bufferBindFlags were updated 5 years ago
dmcdiar 20c1454e4b Added the ShaderRead buffer bind flag to the static and dynamic input assembly pools, and one creation of a static input assembly buffer. 5 years ago
greerdv 4c582a2b0a Merge branch 'main' into non-uniform-scale-mesh 5 years ago
greerdv d8169e08fb merging from main 5 years ago
qingtao fa7f61cf0d ATOM-13791 Editor: ImGui profiling tools doesn't work correctly due to disabled RenderPipelines
- Added pause/resume button to ImGui Profiler to pause/resume profiling
- Added showing pass execution timeline
- Change TimestampResult to include both begin tick and duration tick. Update some function names of TimestampResult.
- Update some functions names in Pass.
- Stop showing accumulated time for ParentPass.
- Fixed a crash issue with ImGuiManager which doesn't have default font.
5 years ago
moudgils 3d3f43b0b9
Merge pull request #36 from aws-lumberyard-dev/Atom/moudgils/MacRuntimeFixes
Atom/moudgils/mac runtime fixes
5 years ago
AMZN-mnaumov c97dae47b7
Merge pull request #22 from aws-lumberyard-dev/Atom/mnaumov/ATOM-14904_2
[ATOM-14904] Fixing ShaderVariantAsyncLoader shutdown not releasing it's assets
5 years ago
moudgils 6f67aabd67 Minor cleanup 5 years ago
greerdv 2fb2813b48 updating atom mesh component to support non-uniform scale component 5 years ago
moudgils 9aec30a608 Merge branch 'main' into Atom/moudgils/MacRuntimeFixes 5 years ago
moudgils 68d58f48ae Merge branch 'main' into Atom/moudgils/MacRuntimeFixes 5 years ago
alexpete 8469c9ca0a Integrating github/staging through commit 5f214be 5 years ago
moudgils 16ba08c917 Mac compile fixes, Fix imgui rendering, Introduce a new RHI::BufferBindFlag, Fix a crash in AsyncStreaming, Fix shader build errors 5 years ago
Alex Peterson 921eb742d4
Merge branch 'main' into github/staging 5 years ago
AMZN-mnaumov 1a7bf94917
Merge branch 'main' into Atom/mnaumov/ATOM-14904_2 5 years ago
mnaumov f188e1c9a7 Fixing ShaderVariantAsyncLoader shutdown not releasing it's assets 5 years ago
nvsickle 1dabb39b98 Migrate fixes from CodeCommit branch 5 years ago
alexpete c5b955d281 Integrating github/staging through commit b0dd7ed 5 years ago
alexpete 1044dc3da1 Integrating github/staging through commit ab87ed9 5 years ago
alexpete c2cbd430fe Integrating up through commit 90f050496 5 years ago
alexpete 36c4e827bd Integrating latest from github/staging
Integrating up through commit 5e1bdae
5 years ago
alexpete 75dc720198 Integrating latest 47acbe8 5 years ago
alexpete a10351f38d Initial commit 5 years ago