Commit Graph

1745 Commits (6651ae3d784d9e2eb7a7f30f36f9729c3cba9852)

Author SHA1 Message Date
amzn-phist 6651ae3d78
Fix for python load errors on Linux (#5627)
* Explicitly load libpython on Linux

Downstream loads of python modules that weren't linked to libpython would
fail to load because libraries were loaded using the RTLD_LOCAL flag.  This
adds a function that will explicitly load libpython on Linux using the
RTLD_GLOBAL flag.

Signed-off-by: amzn-phist <52085794+amzn-phist@users.noreply.github.com>

* Fix misspelled function name

Signed-off-by: amzn-phist <52085794+amzn-phist@users.noreply.github.com>

* Addressing PR feedback

- Updates naming and location of things.
- Adds load code to a Gem template.
- Updates error checking.

Signed-off-by: amzn-phist <52085794+amzn-phist@users.noreply.github.com>

* Address further feedback

Removes the api function in favor of just having modules inherit off a
PythonLoader class, that way we get RAAI behavior and lifetime management
for free.

Signed-off-by: amzn-phist <52085794+amzn-phist@users.noreply.github.com>
4 years ago
mrieggeramzn dd1d515e37
Atom/mriegger/normaloffsetbiasarealight (#4917)
* Adding directional light shadow bias
* Adding normal offset bias for projected shadows

Signed-off-by: mrieggeramzn <mriegger@amazon.com>
4 years ago
antonmic 34921d680a
Merge pull request #5656 from aws-lumberyard-dev/stab/Atom-16694
upgraded capture_displaymapper util and some cleanup
4 years ago
Jonny Gallowy 6cc98f1802 upgraded capture_displaymapper util and some cleanup
Signed-off-by: Jonny Gallowy <gallowj@amazon.com>
4 years ago
bosnichd b20a9b5f39
Some modifications required for restricted platforms: (#5624)
- Replace AZ_TRAIT_MAX_JOB_MANAGER_WORKER_THREADS with AZ_TRAIT_THREAD_NUM_JOB_MANAGER_WORKER_THREADS that allows the number of threads created by the job manager to be set directly.
- Add AZ_TRAIT_THREAD_NUM_TASK_GRAPH_WORKER_THREADS that allows the number of threads created by the task graph to be set directly.
- Add a define that forces the AsyncUploadQueue to use the primary copy queue instead of creating a secondary copy queue.

Signed-off-by: bosnichd <bosnichd@amazon.com>
4 years ago
Guthrie Adams 3d84876e87
Merge pull request #5615 from aws-lumberyard-dev/Atom/guthadam/material_editor_taking_focus_when_opening_new_document
Bug fix for material editor not taking focus when opening a new docum…
4 years ago
mrieggeramzn 5c0fe6a54f
Fix for CSM shimmering (#5607)
* Fix for CSM shimmering

Signed-off-by: mrieggeramzn <mriegger@amazon.com>

* removing debug code

Signed-off-by: mrieggeramzn <mriegger@amazon.com>
4 years ago
mrieggeramzn 533b80095b
Fix for cascade shadow map clipping out too close to the camera (#5509)
Signed-off-by: mrieggeramzn <mriegger@amazon.com>
4 years ago
Guthrie Adams d9746647e1 Bug fix for material editor not taking focus when opening a new document from the main editor or outside of the material editor
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams 4d3c977d58
Merge pull request #5585 from aws-lumberyard-dev/Atom/guthadam/cherrypick_material_relative_paths_to_stab
Cherry pick material editor saves relative paths to external references and test support to stabilization
4 years ago
galibzon b0dfe26232
The Build Time Stamp of ShaderAsset And (#5373)
* The Build Time Stamp of ShaderAsset And
ShaderVariantAsset Should Be Based On
GetTimeUTCMilliSecond()

GetTimeNowMicroseconds() is useful to measure time stamp differences.
GetTimeUTCMilliSecond() is for time stamps based on absolute clock/wall time.

* Updated DiffuseGlobalIllumination precompiled shaders

Co-authored-by: dmcdiar <dmcdiar@amazon.com>
Signed-off-by: galibzon <66021303+galibzon@users.noreply.github.com>
4 years ago
Guthrie Adams 198f225bbe Updating parent path usage has part of cherry picked from stabilization combining source data changes with relative path changes
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams 172ec938cc moved AssetSystemStub to TestUtils folder
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams 01ce02ffec Added basic unit test for relative path function
Moved asset system stub to RPI utils

Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams 7d51912a6e updated comments
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams b3f3a4245b updated image paths to use new function
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams b379c489b5 updated comment
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams ed4f7965da Created function to get relative paths to referenced files that will fall back to asset folder relative paths under certain conditions
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams f18f838da6 material editor and exporter save source materials with relative paths
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
rgba16f e4ca568433
cherry pick atom optimizations
Pull over the changes to move some expensive validation to debug builds only, and use finer grained jobs for the frame scheduler work.
4 years ago
Tommy Walton e3c3db4ba6
In Atom_Feature_Common.static, get cvar values from cvar system instead of reading directly (#5350)
Signed-off-by: Tommy Walton <waltont@amazon.com>
4 years ago
Tommy Walton f1d9e7ae28
Skybox hot reloading - fix black screen when running the editor for the first time with a clean cache (#5529)
* Add a default fallback image when a StreamingImageAsset fails to load

Signed-off-by: Tommy Walton <waltont@amazon.com>

* Don't release a missing/invalid texture reference in the skybox component. Hold on to the reference so that it can hot-reload

Signed-off-by: Tommy Walton <waltont@amazon.com>

* Don't release a missing/invalid texture reference in the ibl component. Hold on to the reference so that it can hot-reload

Signed-off-by: Tommy Walton <waltont@amazon.com>

* Use a different fallback image depending on the status of the asset. Including a setting to use a friendly image that is less obnoxious for anything that might have been missed in a release build

Signed-off-by: Tommy Walton <waltont@amazon.com>

* Adding the stubbed in fallback textures

Signed-off-by: Tommy Walton <waltont@amazon.com>

* Updated the seedlist for the RPI to include the fallback images. It only needs the default and the missing asset images, since the AP doesn't run in release builds, the asset status will always be unknown, not processing or failed to process, so if an asset is not bundled, it is just missing.

Signed-off-by: Tommy Walton <waltont@amazon.com>

* Switched to GetAssetIdByPath and removed some tabs

Signed-off-by: Tommy Walton <waltont@amazon.com>
4 years ago
rgba16f 394ba9a8bc Atom CPU threading optimization (#5481)
* Small change to make the RasterPass Scope jobs split the work more evenly over the cores

Signed-off-by: rgba16f <82187279+rgba16f@users.noreply.github.com>

* Update with PR feedback. Remove scale of EstimatedItemCount, modify the command list cost threshold instead

Signed-off-by: rgba16f <82187279+rgba16f@users.noreply.github.com>
4 years ago
rgba16f 71eedb895d Move PipelineStateCache validation of set uniqeness to only be active in debug builds (#5472)
Signed-off-by: rgba16f <82187279+rgba16f@users.noreply.github.com>
4 years ago
Tom Hulton-Harrop 2812ec2024
Fix brute force mesh intersection function (#5447)
* fix brute force mesh intersection function

Signed-off-by: Tom Hulton-Harrop <82228511+hultonha@users.noreply.github.com>

* add test for brute force ray intersection fix

Signed-off-by: Tom Hulton-Harrop <82228511+hultonha@users.noreply.github.com>

* refactor tests to remove as much duplication and provide API for future tests if required

Signed-off-by: Tom Hulton-Harrop <82228511+hultonha@users.noreply.github.com>

* small updates after review feedback

Signed-off-by: Tom Hulton-Harrop <82228511+hultonha@users.noreply.github.com>

* update following review feedback

Signed-off-by: Tom Hulton-Harrop <82228511+hultonha@users.noreply.github.com>

* fix for pointer offset

Signed-off-by: Tom Hulton-Harrop <82228511+hultonha@users.noreply.github.com>
4 years ago
hershey5045 9c57c9e64f
Fix track view bug where postfxs do not render correctly. (#5465)
* Fix track view bug where postfxs do not render correctly.

Signed-off-by: hershey5045 <43485729+hershey5045@users.noreply.github.com>

* Reduce scope and add comments.

Signed-off-by: hershey5045 <43485729+hershey5045@users.noreply.github.com>
4 years ago
antonmic 0712bc7f87
Merge pull request #5482 from aws-lumberyard-dev/Atom/antonmic/skinMeshSrgFix
Fixed issue where skin material wouldn't render if applied to a model with several submeshes and those submeshes had different material types applied to them.
4 years ago
jiaweig d5081a47db
Fix/update swapchain recreation on vsync interval changes (#5502)
Signed-off-by: jiaweig <51759646+jiaweig-amzn@users.noreply.github.com>
4 years ago
Qing Tao 21a254e9dc
Fixed a type with pass filter (#5506)
Signed-off-by: Qing Tao <55564570+VickyAtAZ@users.noreply.github.com>
4 years ago
antonmic 3fd03479de Addressed PR feedback
Signed-off-by: antonmic <56370189+antonmic@users.noreply.github.com>
4 years ago
Guthrie Adams 87c7023e3c
Merge pull request #5109 from aws-lumberyard-dev/Atom/guthadam/material_editor_loads_source_data2
Material editor creates material assets from source JSON data instead of relying on AP
4 years ago
SJ 0c546828d6
1. Add nullptr checks to prevent crashes when non-critical shaders fail to compile. (#5451)
2. Add a higher "launch_ap_timeout" for Mac because launching a newly built/downloaded AP can take a while.

Signed-off-by: amzn-sj <srikkant@amazon.com>
4 years ago
Guthrie Adams f0b4eb1712 update comment and error message
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
antonmic 1f72001cdb Added two missing MeshDataInstance to ModelDataInstance renames in error message
Signed-off-by: antonmic <56370189+antonmic@users.noreply.github.com>
4 years ago
antonmic dcbcab68d2 merging latest to resolve auto-merge conflict
Signed-off-by: antonmic <56370189+antonmic@users.noreply.github.com>
4 years ago
antonmic dadf06edda Fixed issue where skin material wouldn't render if applied to a model with several submeshes and those submeshes had different material types applied to them.
Signed-off-by: antonmic <56370189+antonmic@users.noreply.github.com>
4 years ago
santorac d6348384c3 Merge remote-tracking branch 'upstream/stabilization/2110' into Atom/santorac/FixSkinScreenshotTests 4 years ago
dmcdiarmid-ly 897fd955e2
Merge pull request #5431 from aws-lumberyard-dev/Atom/dmcdiar/ATOM-16247
ReflectionProbe exposure controls
4 years ago
jiaweig e3b1c4b7d0
Move swapchain and image recreation to the end of the frame (#5388)
Signed-off-by: jiaweig <jiaweig@amazon.com>
4 years ago
dmcdiar eb60dd404b Moved probe exposure to specular only, since it's not used by the diffuse
Signed-off-by: dmcdiar <dmcdiar@amazon.com>
4 years ago
santorac 68ceb9ed94
Merge pull request #5437 from aws-lumberyard-dev/Atom/santorac/CherrypickFixSceneSrgTime2
Cherrypick: Fixed potential render scene time precision issues
4 years ago
lumberyard-employee-dm 5fc4551ac0
[LYN-8041] Enable relocation of the Project Game Release Layout (#5380)
* Enable relocation of the Project Game Release Layout

Relocating the Project Game Release Layout to another directory on the file system failed due to the querying of the engine root failing due to the ComponentApplication::m_engineRoot not using the project path stored in the SettingsRegisry if the engine root cannot be detected

Removed the ApplicationRequestBus GetEngineRoot function.
The ComponentApplicationRequestBus has a function of the same name that returns the same path.

Removed the deprecated GetAppRoot function.
The path it returns has no defined value. It was not the engine root or the project root.
Removed unused CFileUtil and CFileUtil_impl functions that were invoking the ApplicationREquestBus GetEngineRoot function.
On the way to update the functions it was discovered that they aren't called

Added a CalculateBranchToken overload that can populate a fixed_string to avoid heap allocations

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Protect against an empty list of artifacts to remove when generating the
engine.pak

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
4 years ago
santorac c5cb90ddb7 Merge pull request #4426 from aws-lumberyard-dev/Atom/santorac/FixSceneSrgTime
Fixed potential render scene time precision issues.

The timestamp was simply converted from GetTimeAtCurrentTick to a float. Since this value is backed by QueryPerformanceCounter which is 0 at boot, you could see broken animations on the GPU when your system has been on for a long time. So I simplified the RPI's time API (removed unused code), and subtracted the application start time each frame before converting the time value to a float.

Also moved FindShaderInputConstantIndex("m_time") to be called only once, instead of every frame.

Testing:
Originally: I had a local material shader that did vertex animation and it wasn't working at all before, and now it works.
More recently, I made local changes to StandardPBR to add a simple sin wave animation. I also modified GetTimeNowMicroSecond() to artificially add 30 days to the clock. This showed choppy animation before my changes, and smooth animation after.
AtomSampleViewer passed dx12 and vulkan (other than pre-existing issues)

Signed-off-by: santorac <55155825+santorac@users.noreply.github.com>
4 years ago
dmcdiar dcb3ac4337 Set skybox exposure during ReflectionProbe bake
Signed-off-by: dmcdiar <dmcdiar@amazon.com>
4 years ago
Guthrie Adams c372761f4e Changing lua material functor script loading code to pass the correct sub ID for a compiled script asset
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams 791d11c8f9 Fix parent material loading
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams 5afd701e23 updated comments and error messages
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams c0acbe7bd4 Changed how asset creator generates the asset instance. Instead of finding or creating the asset in the asset manager, one is directly instantiated and only added to the asset manager after creation is complete. This allows for reuse of previously loaded asset ids and will replace or “reload” a pre-existing asset with the newly created one. This also sends although correct notifications.
Changed material document to load a source data are for the parent material as well.  It was also a previously loading the parent material products asset which would be out of date compared to the source data.
Changed material document to track source file dependency changes instead of product asset changes.
Fixed a bug or copy paste error in the document manager that was using the same container to track documents the modified externally and from other dependency changes.
Returning source data dependencies when creating a material asset from source.

Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
santorac 48f3bb7d7a Fixed missing initialization of ShaderCollection::Item::m_renderStatesOverlay.
This RenderStates is used to override the values in the final draw packet, if the values are valid; it's supposed to be initialized to invalid values, but it wasn't. So the depth compare function was getting set to Less instead of GreaterEqual. This wasn't a problem when using serialized assets from disk, because the deserialization uses the default constructor which did initialize m_renderStatesOverlay. No all Item constructors initialize m_renderStatesOverlay.

Signed-off-by: santorac <55155825+santorac@users.noreply.github.com>
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago
Guthrie Adams e632dc3b39 Moving material type asset PostInit call to be consistent with material asset
Signed-off-by: Guthrie Adams <guthadam@amazon.com>
4 years ago