diff --git a/.gitignore b/.gitignore index 9012ec7576..2820d1e1c1 100644 --- a/.gitignore +++ b/.gitignore @@ -2,18 +2,14 @@ .vs/ .vscode/ __pycache__ -AssetProcessorTemp/** [Bb]uild/ [Oo]ut/** CMakeUserPresets.json [Cc]ache/ /[Ii]nstall/ -Editor/EditorEventLog.xml -Editor/EditorLayout.xml **/*egg-info/** **/*egg-link **/[Rr]estricted -UserSettings.xml [Uu]ser/ FrameCapture/** .DS_Store @@ -22,9 +18,6 @@ client*.cfg server*.cfg .mayaSwatches/ _savebackup/ -#Output folder for test results when running Automated Tests -TestResults/** *.swatches /imgui.ini -/scripts/project_manager/logs/ -/AutomatedTesting/Gem/PythonTests/scripting/TestResults + diff --git a/AutomatedTesting/CMakeLists.txt b/AutomatedTesting/CMakeLists.txt index 1c5382ba4b..9621c0accb 100644 --- a/AutomatedTesting/CMakeLists.txt +++ b/AutomatedTesting/CMakeLists.txt @@ -27,5 +27,4 @@ else() set_property(GLOBAL APPEND PROPERTY LY_PROJECTS_TARGET_NAME ${project_target_name}) - add_subdirectory(Gem) endif() \ No newline at end of file diff --git a/AutomatedTesting/Gem/CMakeLists.txt b/AutomatedTesting/Gem/CMakeLists.txt index 7a411544ec..e3d8a4087a 100644 --- a/AutomatedTesting/Gem/CMakeLists.txt +++ b/AutomatedTesting/Gem/CMakeLists.txt @@ -6,6 +6,9 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) -add_subdirectory(PythonTests) -add_subdirectory(PythonCoverage) +add_subdirectory(PythonTests) \ No newline at end of file diff --git a/AutomatedTesting/Gem/Code/CMakeLists.txt b/AutomatedTesting/Gem/Code/CMakeLists.txt index 8808507765..1a88d6e69a 100644 --- a/AutomatedTesting/Gem/Code/CMakeLists.txt +++ b/AutomatedTesting/Gem/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME AutomatedTesting ${PAL_TRAIT_MONOLITHIC_DRIVEN_MODULE_TYPE} diff --git a/AutomatedTesting/Gem/Code/Source/AutoGen/NetworkTestPlayerComponent.AutoComponent.xml b/AutomatedTesting/Gem/Code/Source/AutoGen/NetworkTestPlayerComponent.AutoComponent.xml index 46d6191835..251d2b25af 100644 --- a/AutomatedTesting/Gem/Code/Source/AutoGen/NetworkTestPlayerComponent.AutoComponent.xml +++ b/AutomatedTesting/Gem/Code/Source/AutoGen/NetworkTestPlayerComponent.AutoComponent.xml @@ -19,8 +19,8 @@ - - + + @@ -29,10 +29,10 @@ - + - - + + diff --git a/AutomatedTesting/Gem/PythonCoverage/CMakeLists.txt b/AutomatedTesting/Gem/PythonCoverage/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/AutomatedTesting/Gem/PythonCoverage/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonCoverage/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/AutomatedTesting/Gem/PythonCoverage/Code/CMakeLists.txt b/AutomatedTesting/Gem/PythonCoverage/Code/CMakeLists.txt index a865ccc49f..ea6db88c1c 100644 --- a/AutomatedTesting/Gem/PythonCoverage/Code/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonCoverage/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${o3de_gem_restricted_path} ${o3de_gem_path} ${o3de_gem_name}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) if(PAL_TRAIT_PYTHONCOVERAGE_SUPPORTED) diff --git a/AutomatedTesting/Gem/PythonCoverage/gem.json b/AutomatedTesting/Gem/PythonCoverage/gem.json index b99ce0daad..681696d78e 100644 --- a/AutomatedTesting/Gem/PythonCoverage/gem.json +++ b/AutomatedTesting/Gem/PythonCoverage/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "A tool for generating gem coverage for Python tests.", "canonical_tags": [ @@ -13,5 +14,8 @@ "PythonCoverage" ], "icon_path": "preview.png", - "requirements": "" + "requirements": "", + "documentation_url": "", + "dependencies": [ + ] } diff --git a/AutomatedTesting/Gem/PythonTests/AWS/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/AWS/CMakeLists.txt index 2a5e1d7cab..c8629bbe8b 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonTests/AWS/CMakeLists.txt @@ -13,7 +13,8 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS) # Only enable AWS automated tests on Windows - if(NOT "${PAL_PLATFORM_NAME}" STREQUAL "Windows") + set(SUPPORTED_PLATFORMS "Windows" "Linux") + if (NOT "${PAL_PLATFORM_NAME}" IN_LIST SUPPORTED_PLATFORMS) return() endif() @@ -21,9 +22,8 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS) NAME AutomatedTesting::AWSTests TEST_SUITE awsi TEST_SERIAL - PATH ${CMAKE_CURRENT_LIST_DIR}/${PAL_PLATFORM_NAME}/ + PATH ${CMAKE_CURRENT_LIST_DIR}/ RUNTIME_DEPENDENCIES - Legacy::Editor AZ::AssetProcessor AutomatedTesting.GameLauncher AutomatedTesting.Assets diff --git a/AutomatedTesting/Gem/PythonTests/AWS/README.md b/AutomatedTesting/Gem/PythonTests/AWS/README.md index 0d046cbe4c..a25f39d9c2 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/README.md +++ b/AutomatedTesting/Gem/PythonTests/AWS/README.md @@ -2,30 +2,61 @@ ## Prerequisites 1. Build the O3DE Editor and AutomatedTesting.GameLauncher in Profile. -2. AWS CLI is installed and configured following [Configuration and Credential File Settings](https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html). -3. [AWS Cloud Development Kit (CDK)](https://docs.aws.amazon.com/cdk/latest/guide/getting_started.html#getting_started_install) is installed. +2. Install the latest version of NodeJs. +3. AWS CLI is installed and configured following [Configuration and Credential File Settings](https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html). +4. [AWS Cloud Development Kit (CDK)](https://docs.aws.amazon.com/cdk/latest/guide/getting_started.html#getting_started_install) is installed. ## Deploy CDK Applications 1. Go to the AWS IAM console and create an IAM role called o3de-automation-tests which adds your own account as as a trusted entity and uses the "AdministratorAccess" permissions policy. -2. Copy {engine_root}\scripts\build\Platform\Windows\deploy_cdk_applications.cmd to your engine root folder. -3. Open a new Command Prompt window at the engine root and set the following environment variables: -``` - Set O3DE_AWS_PROJECT_NAME=AWSAUTO - Set O3DE_AWS_DEPLOY_REGION=us-east-1 - Set O3DE_AWS_DEPLOY_ACCOUNT={your_aws_account_id} - Set ASSUME_ROLE_ARN=arn:aws:iam::{your_aws_account_id}:role/o3de-automation-tests - Set COMMIT_ID=HEAD -``` -4. In the same Command Prompt window, Deploy the CDK applications for AWS gems by running deploy_cdk_applications.cmd. +2. Copy the following deployment script to your engine root folder: + * Windows (Command Prompt) + ``` + {engine_root}\scripts\build\Platform\Windows\deploy_cdk_applications.cmd + ``` + * Linux + ``` + {engine_root}/scripts/build/Platform/Linux/deploy_cdk_applications.sh + ``` +3. Open a new CLI window at the engine root and set the following environment variables: + * Windows + ``` + Set O3DE_AWS_PROJECT_NAME=AWSAUTO + Set O3DE_AWS_DEPLOY_REGION=us-east-1 + Set ASSUME_ROLE_ARN=arn:aws:iam::{your_aws_account_id}:role/o3de-automation-tests + Set COMMIT_ID=HEAD + ``` + * Linux + ``` + export O3DE_AWS_PROJECT_NAME=AWSAUTO + export O3DE_AWS_DEPLOY_REGION=us-east-1 + export ASSUME_ROLE_ARN=arn:aws:iam::{your_aws_account_id}:role/o3de-automation-tests + export COMMIT_ID=HEAD + ``` +4. In the same CLI window, Deploy the CDK applications for AWS gems by running deploy_cdk_applications.cmd. ## Run Automation Tests ### CLI -In the same Command Prompt window, run the following CLI command: -python\python.cmd -m pytest {path_to_the_test_file} --build-directory {directory_to_the_profile_build} +1. In the same CLI window, run the following CLI command: + * Windows + ``` + python\python.cmd -m pytest {path_to_the_test_file} --build-directory {directory_to_the_profile_build} + ``` + * Linux + ``` + python/python.sh -m pytest {path_to_the_test_file} --build-directory {directory_to_the_profile_build} + ``` ### Pycharm You can also run any specific automation test directly from Pycharm by providing the "--build-directory" argument in the Run Configuration. ## Destroy CDK Applications -1. Copy {engine_root}\scripts\build\Platform\Windows\destroy_cdk_applications.cmd to your engine root folder. -2. In the same Command Prompt window, destroy the CDK applications for AWS gems by running destroy_cdk_applications.cmd. \ No newline at end of file +1. Copy the following destruction script to your engine root folder: + * Windows + ``` + {engine_root}\scripts\build\Platform\Windows\destroy_cdk_applications.cmd + ``` + * Linux + ``` + {engine_root}/scripts/build/Platform/Linux/destroy_cdk_applications.sh + ``` +2. In the same CLI window, destroy the CDK applications for AWS gems by running destroy_cdk_applications.cmd. diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/__init__.py b/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/__init__.py deleted file mode 100644 index 50cbb262dd..0000000000 --- a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/__init__.py +++ /dev/null @@ -1,6 +0,0 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/core/__init__.py b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/__init__.py similarity index 100% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/core/__init__.py rename to AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/__init__.py diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_automation_test.py b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_automation_test.py similarity index 96% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_automation_test.py rename to AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_automation_test.py index 6f3113d771..77d71df370 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_automation_test.py +++ b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_automation_test.py @@ -1,289 +1,289 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" - -import logging -import os -import pytest -import typing -from datetime import datetime - -import ly_test_tools.log.log_monitor - -from AWS.common import constants -from AWS.common.resource_mappings import AWS_RESOURCE_MAPPINGS_ACCOUNT_ID_KEY -from .aws_metrics_custom_thread import AWSMetricsThread - -# fixture imports -from assetpipeline.ap_fixtures.asset_processor_fixture import asset_processor -from .aws_metrics_utils import aws_metrics_utils - -AWS_METRICS_FEATURE_NAME = 'AWSMetrics' - -logger = logging.getLogger(__name__) - - -def setup(launcher: pytest.fixture, - asset_processor: pytest.fixture) -> pytest.fixture: - """ - Set up the resource mapping configuration and start the log monitor. - :param launcher: Client launcher for running the test level. - :param asset_processor: asset_processor fixture. - :return log monitor object. - """ - asset_processor.start() - asset_processor.wait_for_idle() - - file_to_monitor = os.path.join(launcher.workspace.paths.project_log(), constants.GAME_LOG_NAME) - - # Initialize the log monitor. - log_monitor = ly_test_tools.log.log_monitor.LogMonitor(launcher=launcher, log_file_path=file_to_monitor) - - return log_monitor - - -def monitor_metrics_submission(log_monitor: pytest.fixture) -> None: - """ - Monitor the messages and notifications for submitting metrics. - :param log_monitor: Log monitor to check the log messages. - """ - expected_lines = [ - '(Script) - Submitted metrics without buffer.', - '(Script) - Submitted metrics with buffer.', - '(Script) - Flushed the buffered metrics.', - '(Script) - Metrics is sent successfully.' - ] - - unexpected_lines = [ - '(Script) - Failed to submit metrics without buffer.', - '(Script) - Failed to submit metrics with buffer.', - '(Script) - Failed to send metrics.' - ] - - result = log_monitor.monitor_log_for_lines( - expected_lines=expected_lines, - unexpected_lines=unexpected_lines, - halt_on_unexpected=True) - - # Assert the log monitor detected expected lines and did not detect any unexpected lines. - assert result, ( - f'Log monitoring failed. Used expected_lines values: {expected_lines} & ' - f'unexpected_lines values: {unexpected_lines}') - - -def query_metrics_from_s3(aws_metrics_utils: pytest.fixture, resource_mappings: pytest.fixture) -> None: - """ - Verify that the metrics events are delivered to the S3 bucket and can be queried. - :param aws_metrics_utils: aws_metrics_utils fixture. - :param resource_mappings: resource_mappings fixture. - """ - aws_metrics_utils.verify_s3_delivery( - resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsBucketName') - ) - logger.info('Metrics are sent to S3.') - - aws_metrics_utils.run_glue_crawler( - resource_mappings.get_resource_name_id('AWSMetrics.EventsCrawlerName')) - - # Remove the events_json table if exists so that the sample query can create a table with the same name. - aws_metrics_utils.delete_table(resource_mappings.get_resource_name_id('AWSMetrics.EventDatabaseName'), 'events_json') - aws_metrics_utils.run_named_queries(resource_mappings.get_resource_name_id('AWSMetrics.AthenaWorkGroupName')) - logger.info('Query metrics from S3 successfully.') - - -def verify_operational_metrics(aws_metrics_utils: pytest.fixture, - resource_mappings: pytest.fixture, start_time: datetime) -> None: - """ - Verify that operational health metrics are delivered to CloudWatch. - :param aws_metrics_utils: aws_metrics_utils fixture. - :param resource_mappings: resource_mappings fixture. - :param start_time: Time when the game launcher starts. - """ - aws_metrics_utils.verify_cloud_watch_delivery( - 'AWS/Lambda', - 'Invocations', - [{'Name': 'FunctionName', - 'Value': resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsProcessingLambdaName')}], - start_time) - logger.info('AnalyticsProcessingLambda metrics are sent to CloudWatch.') - - aws_metrics_utils.verify_cloud_watch_delivery( - 'AWS/Lambda', - 'Invocations', - [{'Name': 'FunctionName', - 'Value': resource_mappings.get_resource_name_id('AWSMetrics.EventProcessingLambdaName')}], - start_time) - logger.info('EventsProcessingLambda metrics are sent to CloudWatch.') - - -def update_kinesis_analytics_application_status(aws_metrics_utils: pytest.fixture, - resource_mappings: pytest.fixture, start_application: bool) -> None: - """ - Update the Kinesis analytics application to start or stop it. - :param aws_metrics_utils: aws_metrics_utils fixture. - :param resource_mappings: resource_mappings fixture. - :param start_application: whether to start or stop the application. - """ - if start_application: - aws_metrics_utils.start_kinesis_data_analytics_application( - resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsApplicationName')) - else: - aws_metrics_utils.stop_kinesis_data_analytics_application( - resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsApplicationName')) - -@pytest.mark.SUITE_awsi -@pytest.mark.usefixtures('automatic_process_killer') -@pytest.mark.usefixtures('aws_credentials') -@pytest.mark.usefixtures('resource_mappings') -@pytest.mark.parametrize('assume_role_arn', [constants.ASSUME_ROLE_ARN]) -@pytest.mark.parametrize('feature_name', [AWS_METRICS_FEATURE_NAME]) -@pytest.mark.parametrize('profile_name', ['AWSAutomationTest']) -@pytest.mark.parametrize('project', ['AutomatedTesting']) -@pytest.mark.parametrize('region_name', [constants.AWS_REGION]) -@pytest.mark.parametrize('resource_mappings_filename', [constants.AWS_RESOURCE_MAPPING_FILE_NAME]) -@pytest.mark.parametrize('session_name', [constants.SESSION_NAME]) -@pytest.mark.parametrize('stacks', [[f'{constants.AWS_PROJECT_NAME}-{AWS_METRICS_FEATURE_NAME}-{constants.AWS_REGION}']]) -class TestAWSMetricsWindows(object): - """ - Test class to verify the real-time and batch analytics for metrics. - """ - @pytest.mark.parametrize('level', ['AWS/Metrics']) - def test_realtime_and_batch_analytics(self, - level: str, - launcher: pytest.fixture, - asset_processor: pytest.fixture, - workspace: pytest.fixture, - aws_utils: pytest.fixture, - resource_mappings: pytest.fixture, - aws_metrics_utils: pytest.fixture): - """ - Verify that the metrics events are sent to CloudWatch and S3 for analytics. - """ - # Start Kinesis analytics application on a separate thread to avoid blocking the test. - kinesis_analytics_application_thread = AWSMetricsThread(target=update_kinesis_analytics_application_status, - args=(aws_metrics_utils, resource_mappings, True)) - kinesis_analytics_application_thread.start() - - log_monitor = setup(launcher, asset_processor) - - # Kinesis analytics application needs to be in the running state before we start the game launcher. - kinesis_analytics_application_thread.join() - launcher.args = ['+LoadLevel', level] - launcher.args.extend(['-rhi=null']) - start_time = datetime.utcnow() - with launcher.start(launch_ap=False): - monitor_metrics_submission(log_monitor) - - # Verify that real-time analytics metrics are delivered to CloudWatch. - aws_metrics_utils.verify_cloud_watch_delivery( - AWS_METRICS_FEATURE_NAME, - 'TotalLogins', - [], - start_time) - logger.info('Real-time metrics are sent to CloudWatch.') - - # Run time-consuming operations on separate threads to avoid blocking the test. - operational_threads = list() - operational_threads.append( - AWSMetricsThread(target=query_metrics_from_s3, - args=(aws_metrics_utils, resource_mappings))) - operational_threads.append( - AWSMetricsThread(target=verify_operational_metrics, - args=(aws_metrics_utils, resource_mappings, start_time))) - operational_threads.append( - AWSMetricsThread(target=update_kinesis_analytics_application_status, - args=(aws_metrics_utils, resource_mappings, False))) - for thread in operational_threads: - thread.start() - for thread in operational_threads: - thread.join() - - @pytest.mark.parametrize('level', ['AWS/Metrics']) - def test_realtime_and_batch_analytics_no_global_accountid(self, - level: str, - launcher: pytest.fixture, - asset_processor: pytest.fixture, - workspace: pytest.fixture, - aws_utils: pytest.fixture, - resource_mappings: pytest.fixture, - aws_metrics_utils: pytest.fixture): - """ - Verify that the metrics events are sent to CloudWatch and S3 for analytics. - """ - # Remove top-level account ID from resource mappings - resource_mappings.clear_select_keys([AWS_RESOURCE_MAPPINGS_ACCOUNT_ID_KEY]) - # Start Kinesis analytics application on a separate thread to avoid blocking the test. - kinesis_analytics_application_thread = AWSMetricsThread(target=update_kinesis_analytics_application_status, - args=(aws_metrics_utils, resource_mappings, True)) - kinesis_analytics_application_thread.start() - - log_monitor = setup(launcher, asset_processor) - - # Kinesis analytics application needs to be in the running state before we start the game launcher. - kinesis_analytics_application_thread.join() - launcher.args = ['+LoadLevel', level] - launcher.args.extend(['-rhi=null']) - start_time = datetime.utcnow() - with launcher.start(launch_ap=False): - monitor_metrics_submission(log_monitor) - - # Verify that real-time analytics metrics are delivered to CloudWatch. - aws_metrics_utils.verify_cloud_watch_delivery( - AWS_METRICS_FEATURE_NAME, - 'TotalLogins', - [], - start_time) - logger.info('Real-time metrics are sent to CloudWatch.') - - # Run time-consuming operations on separate threads to avoid blocking the test. - operational_threads = list() - operational_threads.append( - AWSMetricsThread(target=query_metrics_from_s3, - args=(aws_metrics_utils, resource_mappings))) - operational_threads.append( - AWSMetricsThread(target=verify_operational_metrics, - args=(aws_metrics_utils, resource_mappings, start_time))) - operational_threads.append( - AWSMetricsThread(target=update_kinesis_analytics_application_status, - args=(aws_metrics_utils, resource_mappings, False))) - for thread in operational_threads: - thread.start() - for thread in operational_threads: - thread.join() - - @pytest.mark.parametrize('level', ['AWS/Metrics']) - def test_unauthorized_user_request_rejected(self, - level: str, - launcher: pytest.fixture, - asset_processor: pytest.fixture, - workspace: pytest.fixture): - """ - Verify that unauthorized users cannot send metrics events to the AWS backed backend. - """ - log_monitor = setup(launcher, asset_processor) - - # Set invalid AWS credentials. - launcher.args = ['+LoadLevel', level, '+cl_awsAccessKey', 'AKIAIOSFODNN7EXAMPLE', - '+cl_awsSecretKey', 'wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY'] - launcher.args.extend(['-rhi=null']) - - with launcher.start(launch_ap=False): - result = log_monitor.monitor_log_for_lines( - expected_lines=['(Script) - Failed to send metrics.'], - unexpected_lines=['(Script) - Metrics is sent successfully.'], - halt_on_unexpected=True) - assert result, 'Metrics events are sent successfully by unauthorized user' - logger.info('Unauthorized user is rejected to send metrics.') - - def test_clean_up_s3_bucket(self, - aws_utils: pytest.fixture, - resource_mappings: pytest.fixture, - aws_metrics_utils: pytest.fixture): - """ - Clear the analytics bucket objects so that the S3 bucket can be destroyed during tear down. - """ - aws_metrics_utils.empty_bucket( - resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsBucketName')) +""" +Copyright (c) Contributors to the Open 3D Engine Project. +For complete copyright and license terms please see the LICENSE at the root of this distribution. + +SPDX-License-Identifier: Apache-2.0 OR MIT +""" + +import logging +import os +import pytest +import typing +from datetime import datetime + +import ly_test_tools.log.log_monitor + +from AWS.common import constants +from AWS.common.resource_mappings import AWS_RESOURCE_MAPPINGS_ACCOUNT_ID_KEY +from .aws_metrics_custom_thread import AWSMetricsThread + +# fixture imports +from assetpipeline.ap_fixtures.asset_processor_fixture import asset_processor +from .aws_metrics_utils import aws_metrics_utils + +AWS_METRICS_FEATURE_NAME = 'AWSMetrics' + +logger = logging.getLogger(__name__) + + +def setup(launcher: pytest.fixture, + asset_processor: pytest.fixture) -> pytest.fixture: + """ + Set up the resource mapping configuration and start the log monitor. + :param launcher: Client launcher for running the test level. + :param asset_processor: asset_processor fixture. + :return log monitor object. + """ + asset_processor.start() + asset_processor.wait_for_idle() + + file_to_monitor = os.path.join(launcher.workspace.paths.project_log(), constants.GAME_LOG_NAME) + + # Initialize the log monitor. + log_monitor = ly_test_tools.log.log_monitor.LogMonitor(launcher=launcher, log_file_path=file_to_monitor) + + return log_monitor + + +def monitor_metrics_submission(log_monitor: pytest.fixture) -> None: + """ + Monitor the messages and notifications for submitting metrics. + :param log_monitor: Log monitor to check the log messages. + """ + expected_lines = [ + '(Script) - Submitted metrics without buffer.', + '(Script) - Submitted metrics with buffer.', + '(Script) - Flushed the buffered metrics.', + '(Script) - Metrics is sent successfully.' + ] + + unexpected_lines = [ + '(Script) - Failed to submit metrics without buffer.', + '(Script) - Failed to submit metrics with buffer.', + '(Script) - Failed to send metrics.' + ] + + result = log_monitor.monitor_log_for_lines( + expected_lines=expected_lines, + unexpected_lines=unexpected_lines, + halt_on_unexpected=True) + + # Assert the log monitor detected expected lines and did not detect any unexpected lines. + assert result, ( + f'Log monitoring failed. Used expected_lines values: {expected_lines} & ' + f'unexpected_lines values: {unexpected_lines}') + + +def query_metrics_from_s3(aws_metrics_utils: pytest.fixture, resource_mappings: pytest.fixture) -> None: + """ + Verify that the metrics events are delivered to the S3 bucket and can be queried. + :param aws_metrics_utils: aws_metrics_utils fixture. + :param resource_mappings: resource_mappings fixture. + """ + aws_metrics_utils.verify_s3_delivery( + resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsBucketName') + ) + logger.info('Metrics are sent to S3.') + + aws_metrics_utils.run_glue_crawler( + resource_mappings.get_resource_name_id('AWSMetrics.EventsCrawlerName')) + + # Remove the events_json table if exists so that the sample query can create a table with the same name. + aws_metrics_utils.delete_table(resource_mappings.get_resource_name_id('AWSMetrics.EventDatabaseName'), 'events_json') + aws_metrics_utils.run_named_queries(resource_mappings.get_resource_name_id('AWSMetrics.AthenaWorkGroupName')) + logger.info('Query metrics from S3 successfully.') + + +def verify_operational_metrics(aws_metrics_utils: pytest.fixture, + resource_mappings: pytest.fixture, start_time: datetime) -> None: + """ + Verify that operational health metrics are delivered to CloudWatch. + :param aws_metrics_utils: aws_metrics_utils fixture. + :param resource_mappings: resource_mappings fixture. + :param start_time: Time when the game launcher starts. + """ + aws_metrics_utils.verify_cloud_watch_delivery( + 'AWS/Lambda', + 'Invocations', + [{'Name': 'FunctionName', + 'Value': resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsProcessingLambdaName')}], + start_time) + logger.info('AnalyticsProcessingLambda metrics are sent to CloudWatch.') + + aws_metrics_utils.verify_cloud_watch_delivery( + 'AWS/Lambda', + 'Invocations', + [{'Name': 'FunctionName', + 'Value': resource_mappings.get_resource_name_id('AWSMetrics.EventProcessingLambdaName')}], + start_time) + logger.info('EventsProcessingLambda metrics are sent to CloudWatch.') + + +def update_kinesis_analytics_application_status(aws_metrics_utils: pytest.fixture, + resource_mappings: pytest.fixture, start_application: bool) -> None: + """ + Update the Kinesis analytics application to start or stop it. + :param aws_metrics_utils: aws_metrics_utils fixture. + :param resource_mappings: resource_mappings fixture. + :param start_application: whether to start or stop the application. + """ + if start_application: + aws_metrics_utils.start_kinesis_data_analytics_application( + resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsApplicationName')) + else: + aws_metrics_utils.stop_kinesis_data_analytics_application( + resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsApplicationName')) + +@pytest.mark.SUITE_awsi +@pytest.mark.usefixtures('automatic_process_killer') +@pytest.mark.usefixtures('aws_credentials') +@pytest.mark.usefixtures('resource_mappings') +@pytest.mark.parametrize('assume_role_arn', [constants.ASSUME_ROLE_ARN]) +@pytest.mark.parametrize('feature_name', [AWS_METRICS_FEATURE_NAME]) +@pytest.mark.parametrize('profile_name', ['AWSAutomationTest']) +@pytest.mark.parametrize('project', ['AutomatedTesting']) +@pytest.mark.parametrize('region_name', [constants.AWS_REGION]) +@pytest.mark.parametrize('resource_mappings_filename', [constants.AWS_RESOURCE_MAPPING_FILE_NAME]) +@pytest.mark.parametrize('session_name', [constants.SESSION_NAME]) +@pytest.mark.parametrize('stacks', [[f'{constants.AWS_PROJECT_NAME}-{AWS_METRICS_FEATURE_NAME}-{constants.AWS_REGION}']]) +class TestAWSMetricsWindows(object): + """ + Test class to verify the real-time and batch analytics for metrics. + """ + @pytest.mark.parametrize('level', ['levels/aws/metrics/metrics.spawnable']) + def test_realtime_and_batch_analytics(self, + level: str, + launcher: pytest.fixture, + asset_processor: pytest.fixture, + workspace: pytest.fixture, + aws_utils: pytest.fixture, + resource_mappings: pytest.fixture, + aws_metrics_utils: pytest.fixture): + """ + Verify that the metrics events are sent to CloudWatch and S3 for analytics. + """ + # Start Kinesis analytics application on a separate thread to avoid blocking the test. + kinesis_analytics_application_thread = AWSMetricsThread(target=update_kinesis_analytics_application_status, + args=(aws_metrics_utils, resource_mappings, True)) + kinesis_analytics_application_thread.start() + + log_monitor = setup(launcher, asset_processor) + + # Kinesis analytics application needs to be in the running state before we start the game launcher. + kinesis_analytics_application_thread.join() + launcher.args = ['+LoadLevel', level] + launcher.args.extend(['-rhi=null']) + start_time = datetime.utcnow() + with launcher.start(launch_ap=False): + monitor_metrics_submission(log_monitor) + + # Verify that real-time analytics metrics are delivered to CloudWatch. + aws_metrics_utils.verify_cloud_watch_delivery( + AWS_METRICS_FEATURE_NAME, + 'TotalLogins', + [], + start_time) + logger.info('Real-time metrics are sent to CloudWatch.') + + # Run time-consuming operations on separate threads to avoid blocking the test. + operational_threads = list() + operational_threads.append( + AWSMetricsThread(target=query_metrics_from_s3, + args=(aws_metrics_utils, resource_mappings))) + operational_threads.append( + AWSMetricsThread(target=verify_operational_metrics, + args=(aws_metrics_utils, resource_mappings, start_time))) + operational_threads.append( + AWSMetricsThread(target=update_kinesis_analytics_application_status, + args=(aws_metrics_utils, resource_mappings, False))) + for thread in operational_threads: + thread.start() + for thread in operational_threads: + thread.join() + + @pytest.mark.parametrize('level', ['levels/aws/metrics/metrics.spawnable']) + def test_realtime_and_batch_analytics_no_global_accountid(self, + level: str, + launcher: pytest.fixture, + asset_processor: pytest.fixture, + workspace: pytest.fixture, + aws_utils: pytest.fixture, + resource_mappings: pytest.fixture, + aws_metrics_utils: pytest.fixture): + """ + Verify that the metrics events are sent to CloudWatch and S3 for analytics. + """ + # Remove top-level account ID from resource mappings + resource_mappings.clear_select_keys([AWS_RESOURCE_MAPPINGS_ACCOUNT_ID_KEY]) + # Start Kinesis analytics application on a separate thread to avoid blocking the test. + kinesis_analytics_application_thread = AWSMetricsThread(target=update_kinesis_analytics_application_status, + args=(aws_metrics_utils, resource_mappings, True)) + kinesis_analytics_application_thread.start() + + log_monitor = setup(launcher, asset_processor) + + # Kinesis analytics application needs to be in the running state before we start the game launcher. + kinesis_analytics_application_thread.join() + launcher.args = ['+LoadLevel', level] + launcher.args.extend(['-rhi=null']) + start_time = datetime.utcnow() + with launcher.start(launch_ap=False): + monitor_metrics_submission(log_monitor) + + # Verify that real-time analytics metrics are delivered to CloudWatch. + aws_metrics_utils.verify_cloud_watch_delivery( + AWS_METRICS_FEATURE_NAME, + 'TotalLogins', + [], + start_time) + logger.info('Real-time metrics are sent to CloudWatch.') + + # Run time-consuming operations on separate threads to avoid blocking the test. + operational_threads = list() + operational_threads.append( + AWSMetricsThread(target=query_metrics_from_s3, + args=(aws_metrics_utils, resource_mappings))) + operational_threads.append( + AWSMetricsThread(target=verify_operational_metrics, + args=(aws_metrics_utils, resource_mappings, start_time))) + operational_threads.append( + AWSMetricsThread(target=update_kinesis_analytics_application_status, + args=(aws_metrics_utils, resource_mappings, False))) + for thread in operational_threads: + thread.start() + for thread in operational_threads: + thread.join() + + @pytest.mark.parametrize('level', ['levels/aws/metrics/metrics.spawnable']) + def test_unauthorized_user_request_rejected(self, + level: str, + launcher: pytest.fixture, + asset_processor: pytest.fixture, + workspace: pytest.fixture): + """ + Verify that unauthorized users cannot send metrics events to the AWS backed backend. + """ + log_monitor = setup(launcher, asset_processor) + + # Set invalid AWS credentials. + launcher.args = ['+LoadLevel', level, '+cl_awsAccessKey', 'AKIAIOSFODNN7EXAMPLE', + '+cl_awsSecretKey', 'wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY'] + launcher.args.extend(['-rhi=null']) + + with launcher.start(launch_ap=False): + result = log_monitor.monitor_log_for_lines( + expected_lines=['(Script) - Failed to send metrics.'], + unexpected_lines=['(Script) - Metrics is sent successfully.'], + halt_on_unexpected=True) + assert result, 'Metrics events are sent successfully by unauthorized user' + logger.info('Unauthorized user is rejected to send metrics.') + + def test_clean_up_s3_bucket(self, + aws_utils: pytest.fixture, + resource_mappings: pytest.fixture, + aws_metrics_utils: pytest.fixture): + """ + Clear the analytics bucket objects so that the S3 bucket can be destroyed during tear down. + """ + aws_metrics_utils.empty_bucket( + resource_mappings.get_resource_name_id('AWSMetrics.AnalyticsBucketName')) diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_custom_thread.py b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_custom_thread.py similarity index 96% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_custom_thread.py rename to AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_custom_thread.py index 1bba9c3e39..99f9072c4b 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_custom_thread.py +++ b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_custom_thread.py @@ -1,29 +1,29 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" - -from threading import Thread - - -class AWSMetricsThread(Thread): - """ - Custom thread for raising assertion errors on the main thread. - """ - def __init__(self, **kwargs): - super().__init__(**kwargs) - self._error = None - - def run(self) -> None: - try: - super().run() - except AssertionError as e: - self._error = e - - def join(self, **kwargs) -> None: - super().join(**kwargs) - - if self._error: - raise AssertionError(self._error) +""" +Copyright (c) Contributors to the Open 3D Engine Project. +For complete copyright and license terms please see the LICENSE at the root of this distribution. + +SPDX-License-Identifier: Apache-2.0 OR MIT +""" + +from threading import Thread + + +class AWSMetricsThread(Thread): + """ + Custom thread for raising assertion errors on the main thread. + """ + def __init__(self, **kwargs): + super().__init__(**kwargs) + self._error = None + + def run(self) -> None: + try: + super().run() + except AssertionError as e: + self._error = e + + def join(self, **kwargs) -> None: + super().join(**kwargs) + + if self._error: + raise AssertionError(self._error) diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_utils.py b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_utils.py similarity index 97% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_utils.py rename to AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_utils.py index e7eb486d02..64ee224f4e 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_utils.py +++ b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_utils.py @@ -1,239 +1,239 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" - -import logging -import pathlib -import pytest -import typing - -from datetime import datetime -from botocore.exceptions import WaiterError - -from .aws_metrics_waiters import KinesisAnalyticsApplicationUpdatedWaiter, \ - CloudWatchMetricsDeliveredWaiter, DataLakeMetricsDeliveredWaiter, GlueCrawlerReadyWaiter - -logging.getLogger('boto').setLevel(logging.CRITICAL) - -# Expected directory and file extension for the S3 objects. -EXPECTED_S3_DIRECTORY = 'firehose_events/' -EXPECTED_S3_OBJECT_EXTENSION = '.parquet' - - -class AWSMetricsUtils: - """ - Provide utils functions for the AWSMetrics gem to interact with the deployed resources. - """ - - def __init__(self, aws_utils: pytest.fixture): - self._aws_util = aws_utils - - def start_kinesis_data_analytics_application(self, application_name: str) -> None: - """ - Start the Kenisis Data Analytics application for real-time analytics. - :param application_name: Name of the Kenisis Data Analytics application. - """ - input_id = self.get_kinesis_analytics_application_input_id(application_name) - assert input_id, 'invalid Kinesis Data Analytics application input.' - - client = self._aws_util.client('kinesisanalytics') - try: - client.start_application( - ApplicationName=application_name, - InputConfigurations=[ - { - 'Id': input_id, - 'InputStartingPositionConfiguration': { - 'InputStartingPosition': 'NOW' - } - }, - ] - ) - except client.exceptions.ResourceInUseException: - # The application has been started. - return - - try: - KinesisAnalyticsApplicationUpdatedWaiter(client, 'RUNNING').wait(application_name=application_name) - except WaiterError as e: - assert False, f'Failed to start the Kinesis Data Analytics application: {str(e)}.' - - def get_kinesis_analytics_application_input_id(self, application_name: str) -> str: - """ - Get the input ID for the Kenisis Data Analytics application. - :param application_name: Name of the Kenisis Data Analytics application. - :return: Input ID for the Kenisis Data Analytics application. - """ - client = self._aws_util.client('kinesisanalytics') - response = client.describe_application( - ApplicationName=application_name - ) - if not response: - return '' - input_descriptions = response.get('ApplicationDetail', {}).get('InputDescriptions', []) - if len(input_descriptions) != 1: - return '' - - return input_descriptions[0].get('InputId', '') - - def stop_kinesis_data_analytics_application(self, application_name: str) -> None: - """ - Stop the Kenisis Data Analytics application. - :param application_name: Name of the Kenisis Data Analytics application. - """ - client = self._aws_util.client('kinesisanalytics') - client.stop_application( - ApplicationName=application_name - ) - - try: - KinesisAnalyticsApplicationUpdatedWaiter(client, 'READY').wait(application_name=application_name) - except WaiterError as e: - assert False, f'Failed to stop the Kinesis Data Analytics application: {str(e)}.' - - def verify_cloud_watch_delivery(self, namespace: str, metrics_name: str, - dimensions: typing.List[dict], start_time: datetime) -> None: - """ - Verify that the expected metrics is delivered to CloudWatch. - :param namespace: Namespace of the metrics. - :param metrics_name: Name of the metrics. - :param dimensions: Dimensions of the metrics. - :param start_time: Start time for generating the metrics. - """ - client = self._aws_util.client('cloudwatch') - - try: - CloudWatchMetricsDeliveredWaiter(client).wait( - namespace=namespace, - metrics_name=metrics_name, - dimensions=dimensions, - start_time=start_time - ) - except WaiterError as e: - assert False, f'Failed to deliver metrics to CloudWatch: {str(e)}.' - - def verify_s3_delivery(self, analytics_bucket_name: str) -> None: - """ - Verify that metrics are delivered to S3 for batch analytics successfully. - :param analytics_bucket_name: Name of the deployed S3 bucket. - """ - client = self._aws_util.client('s3') - bucket_name = analytics_bucket_name - - try: - DataLakeMetricsDeliveredWaiter(client).wait(bucket_name=bucket_name, prefix=EXPECTED_S3_DIRECTORY) - except WaiterError as e: - assert False, f'Failed to find the S3 directory for storing metrics data: {str(e)}.' - - # Check whether the data is converted to the expected data format. - response = client.list_objects_v2( - Bucket=bucket_name, - Prefix=EXPECTED_S3_DIRECTORY - ) - assert response.get('KeyCount', 0) != 0, f'Failed to deliver metrics to the S3 bucket {bucket_name}.' - - s3_objects = response.get('Contents', []) - for s3_object in s3_objects: - key = s3_object.get('Key', '') - assert pathlib.Path(key).suffix == EXPECTED_S3_OBJECT_EXTENSION, \ - f'Invalid data format is found in the S3 bucket {bucket_name}' - - def run_glue_crawler(self, crawler_name: str) -> None: - """ - Run the Glue crawler and wait for it to finish. - :param crawler_name: Name of the Glue crawler - """ - client = self._aws_util.client('glue') - try: - client.start_crawler( - Name=crawler_name - ) - except client.exceptions.CrawlerRunningException: - # The crawler has already been started. - return - - try: - GlueCrawlerReadyWaiter(client).wait(crawler_name=crawler_name) - except WaiterError as e: - assert False, f'Failed to run the Glue crawler: {str(e)}.' - - def run_named_queries(self, work_group: str) -> None: - """ - Run the named queries under the specific Athena work group. - :param work_group: Name of the Athena work group. - """ - client = self._aws_util.client('athena') - # List all the named queries. - response = client.list_named_queries( - WorkGroup=work_group - ) - named_query_ids = response.get('NamedQueryIds', []) - - # Run each of the queries. - for named_query_id in named_query_ids: - get_named_query_response = client.get_named_query( - NamedQueryId=named_query_id - ) - named_query = get_named_query_response.get('NamedQuery', {}) - - start_query_execution_response = client.start_query_execution( - QueryString=named_query.get('QueryString', ''), - QueryExecutionContext={ - 'Database': named_query.get('Database', '') - }, - WorkGroup=work_group - ) - - # Wait for the query to finish. - state = 'RUNNING' - while state == 'QUEUED' or state == 'RUNNING': - get_query_execution_response = client.get_query_execution( - QueryExecutionId=start_query_execution_response.get('QueryExecutionId', '') - ) - - state = get_query_execution_response.get('QueryExecution', {}).get('Status', {}).get('State', '') - - assert state == 'SUCCEEDED', f'Failed to run the named query {named_query.get("Name", {})}' - - def empty_bucket(self, bucket_name: str) -> None: - """ - Empty the S3 bucket following: - https://boto3.amazonaws.com/v1/documentation/api/latest/guide/migrations3.html - - :param bucket_name: Name of the S3 bucket. - """ - s3 = self._aws_util.resource('s3') - bucket = s3.Bucket(bucket_name) - - for key in bucket.objects.all(): - key.delete() - - def delete_table(self, database_name: str, table_name: str) -> None: - """ - Delete an existing Glue table. - - :param database_name: Name of the Glue database. - :param table_name: Name of the table to delete. - """ - client = self._aws_util.client('glue') - client.delete_table( - DatabaseName=database_name, - Name=table_name - ) - - -@pytest.fixture(scope='function') -def aws_metrics_utils( - request: pytest.fixture, - aws_utils: pytest.fixture): - """ - Fixture for the AWS metrics util functions. - :param request: _pytest.fixtures.SubRequest class that handles getting - a pytest fixture from a pytest function/fixture. - :param aws_utils: aws_utils fixture. - """ - aws_utils_obj = AWSMetricsUtils(aws_utils) - return aws_utils_obj +""" +Copyright (c) Contributors to the Open 3D Engine Project. +For complete copyright and license terms please see the LICENSE at the root of this distribution. + +SPDX-License-Identifier: Apache-2.0 OR MIT +""" + +import logging +import pathlib +import pytest +import typing + +from datetime import datetime +from botocore.exceptions import WaiterError + +from .aws_metrics_waiters import KinesisAnalyticsApplicationUpdatedWaiter, \ + CloudWatchMetricsDeliveredWaiter, DataLakeMetricsDeliveredWaiter, GlueCrawlerReadyWaiter + +logging.getLogger('boto').setLevel(logging.CRITICAL) + +# Expected directory and file extension for the S3 objects. +EXPECTED_S3_DIRECTORY = 'firehose_events/' +EXPECTED_S3_OBJECT_EXTENSION = '.parquet' + + +class AWSMetricsUtils: + """ + Provide utils functions for the AWSMetrics gem to interact with the deployed resources. + """ + + def __init__(self, aws_utils: pytest.fixture): + self._aws_util = aws_utils + + def start_kinesis_data_analytics_application(self, application_name: str) -> None: + """ + Start the Kenisis Data Analytics application for real-time analytics. + :param application_name: Name of the Kenisis Data Analytics application. + """ + input_id = self.get_kinesis_analytics_application_input_id(application_name) + assert input_id, 'invalid Kinesis Data Analytics application input.' + + client = self._aws_util.client('kinesisanalytics') + try: + client.start_application( + ApplicationName=application_name, + InputConfigurations=[ + { + 'Id': input_id, + 'InputStartingPositionConfiguration': { + 'InputStartingPosition': 'NOW' + } + }, + ] + ) + except client.exceptions.ResourceInUseException: + # The application has been started. + return + + try: + KinesisAnalyticsApplicationUpdatedWaiter(client, 'RUNNING').wait(application_name=application_name) + except WaiterError as e: + assert False, f'Failed to start the Kinesis Data Analytics application: {str(e)}.' + + def get_kinesis_analytics_application_input_id(self, application_name: str) -> str: + """ + Get the input ID for the Kenisis Data Analytics application. + :param application_name: Name of the Kenisis Data Analytics application. + :return: Input ID for the Kenisis Data Analytics application. + """ + client = self._aws_util.client('kinesisanalytics') + response = client.describe_application( + ApplicationName=application_name + ) + if not response: + return '' + input_descriptions = response.get('ApplicationDetail', {}).get('InputDescriptions', []) + if len(input_descriptions) != 1: + return '' + + return input_descriptions[0].get('InputId', '') + + def stop_kinesis_data_analytics_application(self, application_name: str) -> None: + """ + Stop the Kenisis Data Analytics application. + :param application_name: Name of the Kenisis Data Analytics application. + """ + client = self._aws_util.client('kinesisanalytics') + client.stop_application( + ApplicationName=application_name + ) + + try: + KinesisAnalyticsApplicationUpdatedWaiter(client, 'READY').wait(application_name=application_name) + except WaiterError as e: + assert False, f'Failed to stop the Kinesis Data Analytics application: {str(e)}.' + + def verify_cloud_watch_delivery(self, namespace: str, metrics_name: str, + dimensions: typing.List[dict], start_time: datetime) -> None: + """ + Verify that the expected metrics is delivered to CloudWatch. + :param namespace: Namespace of the metrics. + :param metrics_name: Name of the metrics. + :param dimensions: Dimensions of the metrics. + :param start_time: Start time for generating the metrics. + """ + client = self._aws_util.client('cloudwatch') + + try: + CloudWatchMetricsDeliveredWaiter(client).wait( + namespace=namespace, + metrics_name=metrics_name, + dimensions=dimensions, + start_time=start_time + ) + except WaiterError as e: + assert False, f'Failed to deliver metrics to CloudWatch: {str(e)}.' + + def verify_s3_delivery(self, analytics_bucket_name: str) -> None: + """ + Verify that metrics are delivered to S3 for batch analytics successfully. + :param analytics_bucket_name: Name of the deployed S3 bucket. + """ + client = self._aws_util.client('s3') + bucket_name = analytics_bucket_name + + try: + DataLakeMetricsDeliveredWaiter(client).wait(bucket_name=bucket_name, prefix=EXPECTED_S3_DIRECTORY) + except WaiterError as e: + assert False, f'Failed to find the S3 directory for storing metrics data: {str(e)}.' + + # Check whether the data is converted to the expected data format. + response = client.list_objects_v2( + Bucket=bucket_name, + Prefix=EXPECTED_S3_DIRECTORY + ) + assert response.get('KeyCount', 0) != 0, f'Failed to deliver metrics to the S3 bucket {bucket_name}.' + + s3_objects = response.get('Contents', []) + for s3_object in s3_objects: + key = s3_object.get('Key', '') + assert pathlib.Path(key).suffix == EXPECTED_S3_OBJECT_EXTENSION, \ + f'Invalid data format is found in the S3 bucket {bucket_name}' + + def run_glue_crawler(self, crawler_name: str) -> None: + """ + Run the Glue crawler and wait for it to finish. + :param crawler_name: Name of the Glue crawler + """ + client = self._aws_util.client('glue') + try: + client.start_crawler( + Name=crawler_name + ) + except client.exceptions.CrawlerRunningException: + # The crawler has already been started. + return + + try: + GlueCrawlerReadyWaiter(client).wait(crawler_name=crawler_name) + except WaiterError as e: + assert False, f'Failed to run the Glue crawler: {str(e)}.' + + def run_named_queries(self, work_group: str) -> None: + """ + Run the named queries under the specific Athena work group. + :param work_group: Name of the Athena work group. + """ + client = self._aws_util.client('athena') + # List all the named queries. + response = client.list_named_queries( + WorkGroup=work_group + ) + named_query_ids = response.get('NamedQueryIds', []) + + # Run each of the queries. + for named_query_id in named_query_ids: + get_named_query_response = client.get_named_query( + NamedQueryId=named_query_id + ) + named_query = get_named_query_response.get('NamedQuery', {}) + + start_query_execution_response = client.start_query_execution( + QueryString=named_query.get('QueryString', ''), + QueryExecutionContext={ + 'Database': named_query.get('Database', '') + }, + WorkGroup=work_group + ) + + # Wait for the query to finish. + state = 'RUNNING' + while state == 'QUEUED' or state == 'RUNNING': + get_query_execution_response = client.get_query_execution( + QueryExecutionId=start_query_execution_response.get('QueryExecutionId', '') + ) + + state = get_query_execution_response.get('QueryExecution', {}).get('Status', {}).get('State', '') + + assert state == 'SUCCEEDED', f'Failed to run the named query {named_query.get("Name", {})}' + + def empty_bucket(self, bucket_name: str) -> None: + """ + Empty the S3 bucket following: + https://boto3.amazonaws.com/v1/documentation/api/latest/guide/migrations3.html + + :param bucket_name: Name of the S3 bucket. + """ + s3 = self._aws_util.resource('s3') + bucket = s3.Bucket(bucket_name) + + for key in bucket.objects.all(): + key.delete() + + def delete_table(self, database_name: str, table_name: str) -> None: + """ + Delete an existing Glue table. + + :param database_name: Name of the Glue database. + :param table_name: Name of the table to delete. + """ + client = self._aws_util.client('glue') + client.delete_table( + DatabaseName=database_name, + Name=table_name + ) + + +@pytest.fixture(scope='function') +def aws_metrics_utils( + request: pytest.fixture, + aws_utils: pytest.fixture): + """ + Fixture for the AWS metrics util functions. + :param request: _pytest.fixtures.SubRequest class that handles getting + a pytest fixture from a pytest function/fixture. + :param aws_utils: aws_utils fixture. + """ + aws_utils_obj = AWSMetricsUtils(aws_utils) + return aws_utils_obj diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_waiters.py b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_waiters.py similarity index 96% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_waiters.py rename to AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_waiters.py index 46070a3a64..7b09557c79 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/Windows/aws_metrics/aws_metrics_waiters.py +++ b/AutomatedTesting/Gem/PythonTests/AWS/aws_metrics/aws_metrics_waiters.py @@ -1,139 +1,139 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" - -import botocore.client -import logging - -from datetime import timedelta -from AWS.common.custom_waiter import CustomWaiter, WaitState - -logging.getLogger('boto').setLevel(logging.CRITICAL) - - -class KinesisAnalyticsApplicationUpdatedWaiter(CustomWaiter): - """ - Subclass of the base custom waiter class. - Wait for the Kinesis analytics application being updated to a specific status. - """ - def __init__(self, client: botocore.client, status: str): - """ - Initialize the waiter. - - :param client: Boto3 client to use. - :param status: Expected status. - """ - super().__init__( - 'KinesisAnalyticsApplicationUpdated', - 'DescribeApplication', - 'ApplicationDetail.ApplicationStatus', - {status: WaitState.SUCCESS}, - client) - - def wait(self, application_name: str): - """ - Wait for the expected status. - - :param application_name: Name of the Kinesis analytics application. - """ - self._wait(ApplicationName=application_name) - - -class GlueCrawlerReadyWaiter(CustomWaiter): - """ - Subclass of the base custom waiter class. - Wait for the Glue crawler to finish its processing. Return when the crawler is in the "Stopping" status - to avoid wasting too much time in the automation tests on its shutdown process. - """ - def __init__(self, client: botocore.client): - """ - Initialize the waiter. - - :param client: Boto3 client to use. - """ - super().__init__( - 'GlueCrawlerReady', - 'GetCrawler', - 'Crawler.State', - {'STOPPING': WaitState.SUCCESS}, - client) - - def wait(self, crawler_name): - """ - Wait for the expected status. - - :param crawler_name: Name of the Glue crawler. - """ - self._wait(Name=crawler_name) - - -class DataLakeMetricsDeliveredWaiter(CustomWaiter): - """ - Subclass of the base custom waiter class. - Wait for the expected directory being created in the S3 bucket. - """ - def __init__(self, client: botocore.client): - """ - Initialize the waiter. - - :param client: Boto3 client to use. - """ - super().__init__( - 'DataLakeMetricsDelivered', - 'ListObjectsV2', - 'KeyCount > `0`', - {True: WaitState.SUCCESS}, - client) - - def wait(self, bucket_name, prefix): - """ - Wait for the expected directory being created. - - :param bucket_name: Name of the S3 bucket. - :param prefix: Name of the expected directory prefix. - """ - self._wait(Bucket=bucket_name, Prefix=prefix) - - -class CloudWatchMetricsDeliveredWaiter(CustomWaiter): - """ - Subclass of the base custom waiter class. - Wait for the expected metrics being delivered to CloudWatch. - """ - def __init__(self, client: botocore.client): - """ - Initialize the waiter. - - :param client: Boto3 client to use. - """ - super().__init__( - 'CloudWatchMetricsDelivered', - 'GetMetricStatistics', - 'length(Datapoints) > `0`', - {True: WaitState.SUCCESS}, - client) - - def wait(self, namespace, metrics_name, dimensions, start_time): - """ - Wait for the expected metrics being delivered. - - :param namespace: Namespace of the metrics. - :param metrics_name: Name of the metrics. - :param dimensions: Dimensions of the metrics. - :param start_time: Start time for generating the metrics. - """ - self._wait( - Namespace=namespace, - MetricName=metrics_name, - Dimensions=dimensions, - StartTime=start_time, - EndTime=start_time + timedelta(0, self.timeout), - Period=60, - Statistics=[ - 'SampleCount' - ], - Unit='Count' - ) +""" +Copyright (c) Contributors to the Open 3D Engine Project. +For complete copyright and license terms please see the LICENSE at the root of this distribution. + +SPDX-License-Identifier: Apache-2.0 OR MIT +""" + +import botocore.client +import logging + +from datetime import timedelta +from AWS.common.custom_waiter import CustomWaiter, WaitState + +logging.getLogger('boto').setLevel(logging.CRITICAL) + + +class KinesisAnalyticsApplicationUpdatedWaiter(CustomWaiter): + """ + Subclass of the base custom waiter class. + Wait for the Kinesis analytics application being updated to a specific status. + """ + def __init__(self, client: botocore.client, status: str): + """ + Initialize the waiter. + + :param client: Boto3 client to use. + :param status: Expected status. + """ + super().__init__( + 'KinesisAnalyticsApplicationUpdated', + 'DescribeApplication', + 'ApplicationDetail.ApplicationStatus', + {status: WaitState.SUCCESS}, + client) + + def wait(self, application_name: str): + """ + Wait for the expected status. + + :param application_name: Name of the Kinesis analytics application. + """ + self._wait(ApplicationName=application_name) + + +class GlueCrawlerReadyWaiter(CustomWaiter): + """ + Subclass of the base custom waiter class. + Wait for the Glue crawler to finish its processing. Return when the crawler is in the "Stopping" status + to avoid wasting too much time in the automation tests on its shutdown process. + """ + def __init__(self, client: botocore.client): + """ + Initialize the waiter. + + :param client: Boto3 client to use. + """ + super().__init__( + 'GlueCrawlerReady', + 'GetCrawler', + 'Crawler.State', + {'STOPPING': WaitState.SUCCESS}, + client) + + def wait(self, crawler_name): + """ + Wait for the expected status. + + :param crawler_name: Name of the Glue crawler. + """ + self._wait(Name=crawler_name) + + +class DataLakeMetricsDeliveredWaiter(CustomWaiter): + """ + Subclass of the base custom waiter class. + Wait for the expected directory being created in the S3 bucket. + """ + def __init__(self, client: botocore.client): + """ + Initialize the waiter. + + :param client: Boto3 client to use. + """ + super().__init__( + 'DataLakeMetricsDelivered', + 'ListObjectsV2', + 'KeyCount > `0`', + {True: WaitState.SUCCESS}, + client) + + def wait(self, bucket_name, prefix): + """ + Wait for the expected directory being created. + + :param bucket_name: Name of the S3 bucket. + :param prefix: Name of the expected directory prefix. + """ + self._wait(Bucket=bucket_name, Prefix=prefix) + + +class CloudWatchMetricsDeliveredWaiter(CustomWaiter): + """ + Subclass of the base custom waiter class. + Wait for the expected metrics being delivered to CloudWatch. + """ + def __init__(self, client: botocore.client): + """ + Initialize the waiter. + + :param client: Boto3 client to use. + """ + super().__init__( + 'CloudWatchMetricsDelivered', + 'GetMetricStatistics', + 'length(Datapoints) > `0`', + {True: WaitState.SUCCESS}, + client) + + def wait(self, namespace, metrics_name, dimensions, start_time): + """ + Wait for the expected metrics being delivered. + + :param namespace: Namespace of the metrics. + :param metrics_name: Name of the metrics. + :param dimensions: Dimensions of the metrics. + :param start_time: Start time for generating the metrics. + """ + self._wait( + Namespace=namespace, + MetricName=metrics_name, + Dimensions=dimensions, + StartTime=start_time, + EndTime=start_time + timedelta(0, self.timeout), + Period=60, + Statistics=[ + 'SampleCount' + ], + Unit='Count' + ) diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/__init__.py b/AutomatedTesting/Gem/PythonTests/AWS/client_auth/__init__.py similarity index 100% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/__init__.py rename to AutomatedTesting/Gem/PythonTests/AWS/client_auth/__init__.py diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/client_auth/aws_client_auth_automation_test.py b/AutomatedTesting/Gem/PythonTests/AWS/client_auth/aws_client_auth_automation_test.py similarity index 94% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/client_auth/aws_client_auth_automation_test.py rename to AutomatedTesting/Gem/PythonTests/AWS/client_auth/aws_client_auth_automation_test.py index 077a068a18..b185a155ed 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/Windows/client_auth/aws_client_auth_automation_test.py +++ b/AutomatedTesting/Gem/PythonTests/AWS/client_auth/aws_client_auth_automation_test.py @@ -40,7 +40,7 @@ class TestAWSClientAuthWindows(object): Test class to verify AWS Client Auth gem features on Windows. """ - @pytest.mark.parametrize('level', ['AWS/ClientAuth']) + @pytest.mark.parametrize('level', ['levels/aws/clientauth/clientauth.spawnable']) def test_anonymous_credentials(self, level: str, launcher: pytest.fixture, @@ -72,7 +72,7 @@ class TestAWSClientAuthWindows(object): ) assert result, 'Anonymous credentials fetched successfully.' - @pytest.mark.parametrize('level', ['AWS/ClientAuth']) + @pytest.mark.parametrize('level', ['levels/aws/clientauth/clientauth.spawnable']) def test_anonymous_credentials_no_global_accountid(self, level: str, launcher: pytest.fixture, @@ -140,7 +140,7 @@ class TestAWSClientAuthWindows(object): except cognito_idp.exceptions.UserNotFoundException: pass - launcher.args = ['+LoadLevel', 'AWS/ClientAuthPasswordSignUp'] + launcher.args = ['+LoadLevel', 'levels/aws/clientauthpasswordsignup/clientauthpasswordsignup.spawnable'] launcher.args.extend(['-rhi=null']) with launcher.start(launch_ap=False): @@ -158,7 +158,7 @@ class TestAWSClientAuthWindows(object): Username='test1' ) - launcher.args = ['+LoadLevel', 'AWS/ClientAuthPasswordSignIn'] + launcher.args = ['+LoadLevel', 'levels/aws/clientauthpasswordsignin/clientauthpasswordsignin.spawnable'] launcher.args.extend(['-rhi=null']) with launcher.start(launch_ap=False): diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/client_auth/__init__.py b/AutomatedTesting/Gem/PythonTests/AWS/core/__init__.py similarity index 99% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/client_auth/__init__.py rename to AutomatedTesting/Gem/PythonTests/AWS/core/__init__.py index bbcbcf1807..f5193b300e 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/Windows/client_auth/__init__.py +++ b/AutomatedTesting/Gem/PythonTests/AWS/core/__init__.py @@ -4,4 +4,3 @@ For complete copyright and license terms please see the LICENSE at the root of t SPDX-License-Identifier: Apache-2.0 OR MIT """ - diff --git a/AutomatedTesting/Gem/PythonTests/AWS/Windows/core/test_aws_resource_interaction.py b/AutomatedTesting/Gem/PythonTests/AWS/core/test_aws_resource_interaction.py similarity index 99% rename from AutomatedTesting/Gem/PythonTests/AWS/Windows/core/test_aws_resource_interaction.py rename to AutomatedTesting/Gem/PythonTests/AWS/core/test_aws_resource_interaction.py index 59c517fd1c..367f02cac3 100644 --- a/AutomatedTesting/Gem/PythonTests/AWS/Windows/core/test_aws_resource_interaction.py +++ b/AutomatedTesting/Gem/PythonTests/AWS/core/test_aws_resource_interaction.py @@ -84,7 +84,7 @@ def write_test_data_to_dynamodb_table(resource_mappings: pytest.fixture, aws_uti @pytest.mark.parametrize('session_name', [constants.SESSION_NAME]) @pytest.mark.usefixtures('workspace') @pytest.mark.parametrize('project', ['AutomatedTesting']) -@pytest.mark.parametrize('level', ['AWS/Core']) +@pytest.mark.parametrize('level', ['levels/aws/core/core.spawnable']) @pytest.mark.usefixtures('resource_mappings') @pytest.mark.parametrize('resource_mappings_filename', [constants.AWS_RESOURCE_MAPPING_FILE_NAME]) @pytest.mark.parametrize('stacks', [[f'{constants.AWS_PROJECT_NAME}-{AWS_CORE_FEATURE_NAME}', diff --git a/AutomatedTesting/Gem/PythonTests/Atom/TestSuite_Main.py b/AutomatedTesting/Gem/PythonTests/Atom/TestSuite_Main.py index d79e144ae0..7051b9983c 100644 --- a/AutomatedTesting/Gem/PythonTests/Atom/TestSuite_Main.py +++ b/AutomatedTesting/Gem/PythonTests/Atom/TestSuite_Main.py @@ -4,10 +4,18 @@ For complete copyright and license terms please see the LICENSE at the root of t SPDX-License-Identifier: Apache-2.0 OR MIT """ +import logging +import os import pytest +import ly_test_tools.environment.file_system as file_system +import editor_python_test_tools.hydra_test_utils as hydra + from ly_test_tools.o3de.editor_test import EditorSharedTest, EditorTestSuite +logger = logging.getLogger(__name__) +TEST_DIRECTORY = os.path.join(os.path.dirname(__file__), "tests") + @pytest.mark.parametrize("project", ["AutomatedTesting"]) @pytest.mark.parametrize("launcher_platform", ['windows_editor']) @@ -39,10 +47,6 @@ class TestAutomation(EditorTestSuite): class AtomEditorComponents_DirectionalLightAdded(EditorSharedTest): from Atom.tests import hydra_AtomEditorComponents_DirectionalLightAdded as test_module - @pytest.mark.test_case_id("C36525660") - class AtomEditorComponents_DisplayMapperAdded(EditorSharedTest): - from Atom.tests import hydra_AtomEditorComponents_DisplayMapperAdded as test_module - @pytest.mark.test_case_id("C36525661") class AtomEditorComponents_EntityReferenceAdded(EditorSharedTest): from Atom.tests import hydra_AtomEditorComponents_EntityReferenceAdded as test_module @@ -118,3 +122,73 @@ class TestAutomation(EditorTestSuite): class ShaderAssetBuilder_RecompilesShaderAsChainOfDependenciesChanges(EditorSharedTest): from Atom.tests import hydra_ShaderAssetBuilder_RecompilesShaderAsChainOfDependenciesChanges as test_module + + +@pytest.mark.parametrize("project", ["AutomatedTesting"]) +@pytest.mark.parametrize("launcher_platform", ['windows_generic']) +class TestMaterialEditorBasicTests(object): + @pytest.fixture(autouse=True) + def setup_teardown(self, request, workspace, project): + def delete_files(): + file_system.delete( + [ + os.path.join(workspace.paths.project(), "Materials", "test_material.material"), + os.path.join(workspace.paths.project(), "Materials", "test_material_1.material"), + os.path.join(workspace.paths.project(), "Materials", "test_material_2.material"), + ], + True, + True, + ) + # Cleanup our newly created materials + delete_files() + + def teardown(): + # Cleanup our newly created materials + delete_files() + + request.addfinalizer(teardown) + + @pytest.mark.parametrize("exe_file_name", ["MaterialEditor"]) + @pytest.mark.test_case_id("C34448113") # Creating a New Asset. + @pytest.mark.test_case_id("C34448114") # Opening an Existing Asset. + @pytest.mark.test_case_id("C34448115") # Closing Selected Material. + @pytest.mark.test_case_id("C34448116") # Closing All Materials. + @pytest.mark.test_case_id("C34448117") # Closing all but Selected Material. + @pytest.mark.test_case_id("C34448118") # Saving Material. + @pytest.mark.test_case_id("C34448119") # Saving as a New Material. + @pytest.mark.test_case_id("C34448120") # Saving as a Child Material. + @pytest.mark.test_case_id("C34448121") # Saving all Open Materials. + def test_MaterialEditorBasicTests( + self, request, workspace, project, launcher_platform, generic_launcher, exe_file_name): + + expected_lines = [ + "Material opened: True", + "Test asset doesn't exist initially: True", + "New asset created: True", + "New Material opened: True", + "Material closed: True", + "All documents closed: True", + "Close All Except Selected worked as expected: True", + "Actual Document saved with changes: True", + "Document saved as copy is saved with changes: True", + "Document saved as child is saved with changes: True", + "Save All worked as expected: True", + ] + unexpected_lines = [ + "Traceback (most recent call last):" + ] + + hydra.launch_and_validate_results( + request, + TEST_DIRECTORY, + generic_launcher, + "hydra_AtomMaterialEditor_BasicTests.py", + run_python="--runpython", + timeout=43, + expected_lines=expected_lines, + unexpected_lines=unexpected_lines, + halt_on_unexpected=True, + null_renderer=True, + log_file_name="MaterialEditor.log", + enable_prefab_system=False, + ) diff --git a/AutomatedTesting/Gem/PythonTests/Atom/TestSuite_Sandbox.py b/AutomatedTesting/Gem/PythonTests/Atom/TestSuite_Sandbox.py index f0bb6e72ca..c9182070f6 100644 --- a/AutomatedTesting/Gem/PythonTests/Atom/TestSuite_Sandbox.py +++ b/AutomatedTesting/Gem/PythonTests/Atom/TestSuite_Sandbox.py @@ -19,13 +19,6 @@ logger = logging.getLogger(__name__) TEST_DIRECTORY = os.path.join(os.path.dirname(__file__), "tests") -class TestAtomEditorComponentsSandbox(object): - - # It requires at least one test - def test_Dummy(self, request, editor, level, workspace, project, launcher_platform): - pass - - @pytest.mark.parametrize("project", ["AutomatedTesting"]) @pytest.mark.parametrize("launcher_platform", ['windows_editor']) @pytest.mark.parametrize("level", ["auto_test"]) @@ -90,87 +83,23 @@ class TestAtomEditorComponentsMain(object): ) -@pytest.mark.parametrize("project", ["AutomatedTesting"]) -@pytest.mark.parametrize("launcher_platform", ['windows_generic']) -@pytest.mark.system -class TestMaterialEditorBasicTests(object): - @pytest.fixture(autouse=True) - def setup_teardown(self, request, workspace, project): - def delete_files(): - file_system.delete( - [ - os.path.join(workspace.paths.project(), "Materials", "test_material.material"), - os.path.join(workspace.paths.project(), "Materials", "test_material_1.material"), - os.path.join(workspace.paths.project(), "Materials", "test_material_2.material"), - ], - True, - True, - ) - # Cleanup our newly created materials - delete_files() - - def teardown(): - # Cleanup our newly created materials - delete_files() - - request.addfinalizer(teardown) - - @pytest.mark.parametrize("exe_file_name", ["MaterialEditor"]) - @pytest.mark.test_case_id("C34448113") # Creating a New Asset. - @pytest.mark.test_case_id("C34448114") # Opening an Existing Asset. - @pytest.mark.test_case_id("C34448115") # Closing Selected Material. - @pytest.mark.test_case_id("C34448116") # Closing All Materials. - @pytest.mark.test_case_id("C34448117") # Closing all but Selected Material. - @pytest.mark.test_case_id("C34448118") # Saving Material. - @pytest.mark.test_case_id("C34448119") # Saving as a New Material. - @pytest.mark.test_case_id("C34448120") # Saving as a Child Material. - @pytest.mark.test_case_id("C34448121") # Saving all Open Materials. - def test_MaterialEditorBasicTests( - self, request, workspace, project, launcher_platform, generic_launcher, exe_file_name): - - expected_lines = [ - "Material opened: True", - "Test asset doesn't exist initially: True", - "New asset created: True", - "New Material opened: True", - "Material closed: True", - "All documents closed: True", - "Close All Except Selected worked as expected: True", - "Actual Document saved with changes: True", - "Document saved as copy is saved with changes: True", - "Document saved as child is saved with changes: True", - "Save All worked as expected: True", - ] - unexpected_lines = [ - "Traceback (most recent call last):" - ] - - hydra.launch_and_validate_results( - request, - TEST_DIRECTORY, - generic_launcher, - "hydra_AtomMaterialEditor_BasicTests.py", - run_python="--runpython", - timeout=120, - expected_lines=expected_lines, - unexpected_lines=unexpected_lines, - halt_on_unexpected=True, - null_renderer=True, - log_file_name="MaterialEditor.log", - enable_prefab_system=False, - ) - - @pytest.mark.parametrize("project", ["AutomatedTesting"]) @pytest.mark.parametrize("launcher_platform", ['windows_editor']) class TestAutomation(EditorTestSuite): enable_prefab_system = False + #this test is intermittently timing out without ever having executed. sandboxing while we investigate cause. + @pytest.mark.test_case_id("C36525660") + class AtomEditorComponents_DisplayMapperAdded(EditorSharedTest): + from Atom.tests import hydra_AtomEditorComponents_DisplayMapperAdded as test_module + + # this test causes editor to crash when using slices. once automation transitions to prefabs it should pass @pytest.mark.test_case_id("C36529666") class AtomEditorComponentsLevel_DiffuseGlobalIlluminationAdded(EditorSharedTest): from Atom.tests import hydra_AtomEditorComponentsLevel_DiffuseGlobalIlluminationAdded as test_module + # this test causes editor to crash when using slices. once automation transitions to prefabs it should pass @pytest.mark.test_case_id("C36525660") class AtomEditorComponentsLevel_DisplayMapperAdded(EditorSharedTest): from Atom.tests import hydra_AtomEditorComponentsLevel_DisplayMapperAdded as test_module diff --git a/AutomatedTesting/Gem/PythonTests/Atom/atom_utils/material_editor_utils.py b/AutomatedTesting/Gem/PythonTests/Atom/atom_utils/material_editor_utils.py index b21c74de19..f7ff970541 100644 --- a/AutomatedTesting/Gem/PythonTests/Atom/atom_utils/material_editor_utils.py +++ b/AutomatedTesting/Gem/PythonTests/Atom/atom_utils/material_editor_utils.py @@ -162,6 +162,13 @@ def select_model_config(configname): azlmbr.materialeditor.MaterialViewportRequestBus(azlmbr.bus.Broadcast, "SelectModelPresetByName", configname) +def destroy_main_window(): + """ + Closes the Material Editor window + """ + azlmbr.atomtools.AtomToolsMainWindowFactoryRequestBus(azlmbr.bus.Broadcast, "DestroyMainWindow") + + def wait_for_condition(function, timeout_in_seconds=1.0): # type: (function, float) -> bool """ diff --git a/AutomatedTesting/Gem/PythonTests/Atom/tests/hydra_AtomMaterialEditor_BasicTests.py b/AutomatedTesting/Gem/PythonTests/Atom/tests/hydra_AtomMaterialEditor_BasicTests.py index 9f8f6c44b2..baad02318d 100644 --- a/AutomatedTesting/Gem/PythonTests/Atom/tests/hydra_AtomMaterialEditor_BasicTests.py +++ b/AutomatedTesting/Gem/PythonTests/Atom/tests/hydra_AtomMaterialEditor_BasicTests.py @@ -186,6 +186,11 @@ def run(): material_editor.set_property(document2_id, property2_name, initial_color) material_editor.save_all() material_editor.close_all_documents() + material_editor.wait_for_condition(lambda: + (not material_editor.is_open(document1_id)) and + (not material_editor.is_open(document2_id)) and + (not material_editor.is_open(document3_id)), 2.0) + material_editor.destroy_main_window() if __name__ == "__main__": diff --git a/AutomatedTesting/Gem/PythonTests/Blast/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/Blast/CMakeLists.txt index aea2562e0b..64effb5b4c 100644 --- a/AutomatedTesting/Gem/PythonTests/Blast/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonTests/Blast/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # for PAL_TRAIT_BLAST Traits diff --git a/AutomatedTesting/Gem/PythonTests/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/CMakeLists.txt index 800f347359..26c03e78c2 100644 --- a/AutomatedTesting/Gem/PythonTests/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonTests/CMakeLists.txt @@ -10,7 +10,7 @@ # Automated Tests ################################################################################ -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_dir}/PAL_traits_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/editor_entity_utils.py b/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/editor_entity_utils.py index 72530325e0..c3398406ab 100644 --- a/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/editor_entity_utils.py +++ b/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/editor_entity_utils.py @@ -8,7 +8,8 @@ SPDX-License-Identifier: Apache-2.0 OR MIT # Built-in Imports from __future__ import annotations from typing import List, Tuple, Union - +from enum import Enum +import warnings # Open 3D Engine Imports import azlmbr @@ -21,14 +22,25 @@ import azlmbr.legacy.general as general from editor_python_test_tools.utils import Report +class EditorEntityType(Enum): + GAME = azlmbr.entity.EntityType().Game + LEVEL = azlmbr.entity.EntityType().Level + + class EditorComponent: """ EditorComponent class used to set and get the component property value using path EditorComponent object is returned from either of EditorEntity.add_component() or Entity.add_components() or EditorEntity.get_components_of_type() which also assigns self.id and self.type_id to the EditorComponent object. + self.type_id is the UUID for the component type as provided by an ebus call. """ + def __init__(self, type_id: uuid): + self.type_id = type_id + self.id = None + self.property_tree_editor = None + def get_component_name(self) -> str: """ Used to get name of component @@ -38,9 +50,9 @@ class EditorComponent: assert len(type_names) != 0, "Component object does not have type id" return type_names[0] - def get_property_tree(self): + def get_property_tree(self, force_get: bool = False): """ - Used to get the property tree object of component that has following functions associated with it: + Used to get and cache the property tree editor of component that has following functions associated with it: 1. prop_tree.is_container(path) 2. prop_tree.get_container_count(path) 3. prop_tree.reset_container(path) @@ -48,17 +60,161 @@ class EditorComponent: 5. prop_tree.remove_container_item(path, key) 6. prop_tree.update_container_item(path, key, value) 7. prop_tree.get_container_item(path, key) - :return: Property tree object of a component + :param force_get: Force a fresh property tree editor rather than the cached self.property_tree_editor + :return: Property tree editor of the component """ + if (not force_get) and (self.property_tree_editor is not None): + return self.property_tree_editor + build_prop_tree_outcome = editor.EditorComponentAPIBus( bus.Broadcast, "BuildComponentPropertyTreeEditor", self.id ) assert ( build_prop_tree_outcome.IsSuccess() - ), f"Failure: Could not build property tree of component: '{self.get_component_name()}'" + ), f"Failure: Could not build property tree editor of component: '{self.get_component_name()}'" prop_tree = build_prop_tree_outcome.GetValue() Report.info(prop_tree.build_paths_list()) - return prop_tree + self.property_tree_editor = prop_tree + return self.property_tree_editor + + def is_property_container(self, component_property_path: str) -> bool: + """ + Used to determine if a component property is a container. + Containers are a collection of same typed values that can expand/shrink to contain more or less. + There are two types of containers; indexed and associative. + Indexed containers use integer key and are something like a linked list + Associative containers utilize keys of the same type which could be any supported type. + :param component_property_path: String of component property. (e.g. 'Settings|Visible') + :return: Boolean True if the property is a container False if it is not. + """ + if self.property_tree_editor is None: + self.get_property_tree() + result = self.property_tree_editor.is_container(component_property_path) + if not result: + Report.info(f"{self.get_component_name()}: '{component_property_path}' is not a container") + return result + + def get_container_count(self, component_property_path: str) -> int: + """ + Used to get the count of items in the container. + :param component_property_path: String of component property. (e.g. 'Settings|Visible') + :return: Count of items in the container as unsigned integer + """ + assert ( + self.is_property_container(component_property_path) + ), f"Failure: '{component_property_path}' is not a property container" + container_count_outcome = self.property_tree_editor.get_container_count(component_property_path) + assert ( + container_count_outcome.IsSuccess() + ), f"Failure: get_container_count did not return success for '{component_property_path}'" + return container_count_outcome.GetValue() + + def reset_container(self, component_property_path: str): + """ + Used to reset a container to empty + :param component_property_path: String of component property. (e.g. 'Settings|Visible') + :return: None + """ + assert ( + self.is_property_container(component_property_path) + ), f"Failure: '{component_property_path}' is not a property container" + reset_outcome = self.property_tree_editor.reset_container(component_property_path) + assert ( + reset_outcome.IsSuccess() + ), f"Failure: could not reset_container on '{component_property_path}'" + + def append_container_item(self, component_property_path: str, value: any): + """ + Used to append a value to an indexed container item without providing an index key. + Append will fail on an associative container + :param component_property_path: String of component property. (e.g. 'Settings|Visible') + :param value: Value to be set + :return: None + """ + assert ( + self.is_property_container(component_property_path) + ), f"Failure: '{component_property_path}' is not a property container" + append_outcome = self.property_tree_editor.append_container_item(component_property_path, value) + assert ( + append_outcome.IsSuccess() + ), f"Failure: could not append_container_item to '{component_property_path}'" + + def add_container_item(self, component_property_path: str, key: any, value: any): + """ + Used to add a container item at a specified key. + There are two types of containers; indexed and associative. + Indexed containers use integer key. + Associative containers utilize keys of the same type which could be any supported type. + :param component_property_path: String of component property. (e.g. 'Settings|Visible') + :param key: Zero index integer key or any supported type for associative container + :param value: Value to be set + :return: None + """ + assert ( + self.is_property_container(component_property_path) + ), f"Failure: '{component_property_path}' is not a property container" + add_outcome = self.property_tree_editor.add_container_item(component_property_path, key, value) + assert ( + add_outcome.IsSuccess() + ), f"Failure: could not add_container_item '{key}' to '{component_property_path}'" + + def get_container_item(self, component_property_path: str, key: any) -> any: + """ + Used to retrieve a container item value at the specified key. + There are two types of containers; indexed and associative. + Indexed containers use integer key. + Associative containers utilize keys of the same type which could be any supported type. + :param component_property_path: String of component property. (e.g. 'Settings|Visible') + :param key: Zero index integer key or any supported type for associative container + :return: Value stored at the key specified + """ + assert ( + self.is_property_container(component_property_path) + ), f"Failure: '{component_property_path}' is not a property container" + get_outcome = self.property_tree_editor.get_container_item(component_property_path, key) + assert ( + get_outcome.IsSuccess() + ), ( + f"Failure: could not get a value for {self.get_component_name()}: '{component_property_path}' [{key}]. " + f"Error returned by get_container_item: {get_outcome.GetError()}") + return get_outcome.GetValue() + + def remove_container_item(self, component_property_path: str, key: any): + """ + Used to remove a container item value at the specified key. + There are two types of containers; indexed and associative. + Indexed containers use integer key. + Associative containers utilize keys of the same type which could be any supported type. + :param component_property_path: String of component property. (e.g. 'Settings|Visible') + :param key: Zero index integer key or any supported type for associative container + :return: None + """ + assert ( + self.is_property_container(component_property_path) + ), f"Failure: '{component_property_path}' is not a property container" + remove_outcome = self.property_tree_editor.remove_container_item(component_property_path, key) + assert ( + remove_outcome.IsSuccess() + ), f"Failure: could not remove_container_item '{key}' from '{component_property_path}'" + + def update_container_item(self, component_property_path: str, key: any, value: any): + """ + Used to update a container item at a specified key. + There are two types of containers; indexed and associative. + Indexed containers use integer key. + Associative containers utilize keys of the same type which could be any supported type. + :param component_property_path: String of component property. (e.g. 'Settings|Visible') + :param key: Zero index integer key or any supported type for associative container + :param value: Value to be set + :return: None + """ + assert ( + self.is_property_container(component_property_path) + ), f"Failure: '{component_property_path}' is not a property container" + update_outcome = self.property_tree_editor.update_container_item(component_property_path, key, value) + assert ( + update_outcome.IsSuccess() + ), f"Failure: could not update '{key}' in '{component_property_path}'" def get_component_property_value(self, component_property_path: str): """ @@ -94,23 +250,36 @@ class EditorComponent: """ return editor.EditorComponentAPIBus(bus.Broadcast, "IsComponentEnabled", self.id) + def set_enabled(self, new_state: bool): + """ + Used to set the component enabled state + :param new_state: Boolean enabled True, disabled False + :return: None + """ + if new_state: + editor.EditorComponentAPIBus(bus.Broadcast, "EnableComponents", [self.id]) + else: + editor.EditorComponentAPIBus(bus.Broadcast, "DisableComponents", [self.id]) + def disable_component(self): """ Used to disable the component using its id value. + Deprecation warning! Use set_enabled(False) instead as this method is in deprecation :return: None """ + warnings.warn("disable_component is deprecated, use set_enabled(False) instead.", DeprecationWarning) editor.EditorComponentAPIBus(bus.Broadcast, "DisableComponents", [self.id]) @staticmethod - def get_type_ids(component_names: list) -> list: + def get_type_ids(component_names: list, entity_type: EditorEntityType = EditorEntityType.GAME) -> list: """ Used to get type ids of given components list - :param: component_names: List of components to get type ids - :return: List of type ids of given components. + :param component_names: List of components to get type ids + :param entity_type: Entity_Type enum value Entity_Type.GAME is the default + :return: List of type ids of given components. Type id is a UUID as provided by the ebus call """ type_ids = editor.EditorComponentAPIBus( - bus.Broadcast, "FindComponentTypeIdsByEntityType", component_names, azlmbr.entity.EntityType().Game - ) + bus.Broadcast, "FindComponentTypeIdsByEntityType", component_names, entity_type.value) return type_ids @@ -131,7 +300,7 @@ class EditorEntity: """ Entity class is used to create and interact with Editor Entities. Example: To create Editor Entity, Use the code: - test_entity = Entity.create_editor_entity("TestEntity") + test_entity = EditorEntity.create_editor_entity("TestEntity") # This creates a python object with 'test_entity' linked to entity name "TestEntity" in Editor. # To add component, use: test_entity.add_component() @@ -276,10 +445,9 @@ class EditorEntity: :return: List of newly added components to the entity """ components = [] - type_ids = EditorComponent.get_type_ids(component_names) + type_ids = EditorComponent.get_type_ids(component_names, EditorEntityType.GAME) for type_id in type_ids: - new_comp = EditorComponent() - new_comp.type_id = type_id + new_comp = EditorComponent(type_id) add_component_outcome = editor.EditorComponentAPIBus( bus.Broadcast, "AddComponentsOfType", self.id, [type_id] ) @@ -291,6 +459,27 @@ class EditorEntity: self.components.append(new_comp) return components + def remove_component(self, component_name: str) -> None: + """ + Used to remove a component from Entity + :param component_name: String of component name to remove + :return: None + """ + self.remove_components([component_name]) + + def remove_components(self, component_names: list): + """ + Used to remove a list of components from Entity + :param component_names: List of component names to remove + :return: None + """ + type_ids = EditorComponent.get_type_ids(component_names, EditorEntityType.GAME) + for type_id in type_ids: + remove_outcome = editor.EditorComponentAPIBus(bus.Broadcast, "RemoveComponents", self.id, [type_id]) + assert ( + remove_outcome.IsSuccess() + ), f"Failure: could not remove component from '{self.get_name()}'" + def get_components_of_type(self, component_names: list) -> List[EditorComponent]: """ Used to get components of type component_name that already exists on Entity @@ -298,10 +487,9 @@ class EditorEntity: :return: List of Entity Component objects of given component name """ component_list = [] - type_ids = EditorComponent.get_type_ids(component_names) + type_ids = EditorComponent.get_type_ids(component_names, EditorEntityType.GAME) for type_id in type_ids: - component = EditorComponent() - component.type_id = type_id + component = EditorComponent(type_id) get_component_of_type_outcome = editor.EditorComponentAPIBus( bus.Broadcast, "GetComponentOfType", self.id, type_id ) @@ -319,7 +507,7 @@ class EditorEntity: :param component_name: Name of component to check for :return: True, if entity has specified component. Else, False """ - type_ids = EditorComponent.get_type_ids([component_name]) + type_ids = EditorComponent.get_type_ids([component_name], EditorEntityType.GAME) return editor.EditorComponentAPIBus(bus.Broadcast, "HasComponentOfType", self.id, type_ids[0]) def get_start_status(self) -> int: @@ -359,6 +547,21 @@ class EditorEntity: set_status = self.get_start_status() assert set_status == status_to_set, f"Failed to set start status of {desired_start_status} to {self.get_name}" + def is_locked(self) -> bool: + """ + Used to get the locked status of the entity + :return: Boolean True if locked False if not locked + """ + return editor.EditorEntityInfoRequestBus(bus.Event, "IsLocked", self.id) + + def set_lock_state(self, is_locked: bool) -> None: + """ + Sets the lock state on the object to locked or not locked. + :param is_locked: True for locking, False to unlock. + :return: None + """ + editor.EditorEntityAPIBus(bus.Event, "SetLockState", self.id, is_locked) + def delete(self) -> None: """ Used to delete the Entity. @@ -488,18 +691,6 @@ class EditorLevelEntity: EditorLevelComponentAPIBus requests. """ - @staticmethod - def get_type_ids(component_names: list) -> list: - """ - Used to get type ids of given components list for EntityType Level - :param: component_names: List of components to get type ids - :return: List of type ids of given components. - """ - type_ids = editor.EditorComponentAPIBus( - bus.Broadcast, "FindComponentTypeIdsByEntityType", component_names, azlmbr.entity.EntityType().Level - ) - return type_ids - @staticmethod def add_component(component_name: str) -> EditorComponent: """ @@ -518,10 +709,9 @@ class EditorLevelEntity: :return: List of newly added components to the level """ components = [] - type_ids = EditorLevelEntity.get_type_ids(component_names) + type_ids = EditorComponent.get_type_ids(component_names, EditorEntityType.LEVEL) for type_id in type_ids: - new_comp = EditorComponent() - new_comp.type_id = type_id + new_comp = EditorComponent(type_id) add_component_outcome = editor.EditorLevelComponentAPIBus( bus.Broadcast, "AddComponentsOfType", [type_id] ) @@ -540,10 +730,9 @@ class EditorLevelEntity: :return: List of Level Component objects of given component name """ component_list = [] - type_ids = EditorLevelEntity.get_type_ids(component_names) + type_ids = EditorComponent.get_type_ids(component_names, EditorEntityType.LEVEL) for type_id in type_ids: - component = EditorComponent() - component.type_id = type_id + component = EditorComponent(type_id) get_component_of_type_outcome = editor.EditorLevelComponentAPIBus( bus.Broadcast, "GetComponentOfType", type_id ) @@ -562,7 +751,7 @@ class EditorLevelEntity: :param component_name: Name of component to check for :return: True, if level has specified component. Else, False """ - type_ids = EditorLevelEntity.get_type_ids([component_name]) + type_ids = EditorComponent.get_type_ids([component_name], EditorEntityType.LEVEL) return editor.EditorLevelComponentAPIBus(bus.Broadcast, "HasComponentOfType", type_ids[0]) @staticmethod @@ -572,5 +761,5 @@ class EditorLevelEntity: :param component_name: Name of component to check for :return: integer count of occurences of level component attached to level or zero if none are present """ - type_ids = EditorLevelEntity.get_type_ids([component_name]) + type_ids = EditorComponent.get_type_ids([component_name], EditorEntityType.LEVEL) return editor.EditorLevelComponentAPIBus(bus.Broadcast, "CountComponentsOfType", type_ids[0]) diff --git a/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/hydra_editor_utils.py b/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/hydra_editor_utils.py index 5e3828ad02..36fc6003f7 100644 --- a/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/hydra_editor_utils.py +++ b/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/hydra_editor_utils.py @@ -5,15 +5,22 @@ For complete copyright and license terms please see the LICENSE at the root of t SPDX-License-Identifier: Apache-2.0 OR MIT """ +from typing import List +from math import isclose +import collections.abc + import azlmbr.bus as bus import azlmbr.editor as editor import azlmbr.entity as entity import azlmbr.legacy.general as general import azlmbr.object -from typing import List -from math import isclose -import collections.abc +from editor_python_test_tools.utils import TestHelper as helper + + +def open_base_level(): + helper.init_idle() + helper.open_level("Prefab", "Base") def find_entity_by_name(entity_name): diff --git a/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/utils.py b/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/utils.py index 7b526033dd..35a50b6090 100644 --- a/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/utils.py +++ b/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/utils.py @@ -101,30 +101,56 @@ class TestHelper: Report.critical_result(msgtuple_success_fail, general.is_in_game_mode()) @staticmethod - def multiplayer_enter_game_mode(msgtuple_success_fail: Tuple[str, str], sv_default_player_spawn_asset: str) -> None: + def find_line(window, line, print_infos): """ - :param msgtuple_success_fail: The tuple with the expected/unexpected messages for entering game mode. - :param sv_default_player_spawn_asset: The path to the network player prefab that will be automatically spawned upon entering gamemode. The engine default is "prefabs/player.network.spawnable" + Looks for an expected line in a list of tracer log lines + :param window: The log's window name. For example, logs printed via script-canvas use the "Script" window. + :param line: The log message to search for. + :param print_infos: A list of PrintInfos collected by Tracer to search. Example options: your_tracer.warnings, your_tracer.errors, your_tracer.asserts, or your_tracer.prints - :return: None + :return: True if the line is found, otherwise false. """ + for printInfo in print_infos: + if printInfo.window == window.strip() and printInfo.message.strip() == line: + return True + return False - # looks for an expected line in a list of tracers lines - # lines: the tracer list of lines to search. options are section_tracer.warnings, section_tracer.errors, section_tracer.asserts, section_tracer.prints - # return: true if the line is found, otherwise false - def find_expected_line(expected_line, lines): - found_lines = [printInfo.message.strip() for printInfo in lines] - return expected_line in found_lines + @staticmethod + def succeed_if_log_line_found(window, line, print_infos, time_out): + """ + Looks for a line in a list of tracer log lines and reports success if found. + :param window: The log's window name. For example, logs printed via script-canvas use the "Script" window. + :param line: The log message we're hoping to find. + :param print_infos: A list of PrintInfos collected by Tracer to search. Example options: your_tracer.warnings, your_tracer.errors, your_tracer.asserts, or your_tracer.prints + :param time_out: The total amount of time to wait before giving up looking for the expected line. - def wait_for_critical_expected_line(expected_line, lines, time_out): - TestHelper.wait_for_condition(lambda : find_expected_line(expected_line, lines), time_out) - Report.critical_result(("Found expected line: " + expected_line, "Failed to find expected line: " + expected_line), find_expected_line(expected_line, lines)) + :return: No return value, but if the message is found, a successful critical result is reported; otherwise failure. + """ + TestHelper.wait_for_condition(lambda : TestHelper.find_line(window, line, print_infos), time_out) + Report.critical_result(("Found expected line: " + line, "Failed to find expected line: " + line), TestHelper.find_line(window, line, print_infos)) - def wait_for_critical_unexpected_line(unexpected_line, lines, time_out): - TestHelper.wait_for_condition(lambda : find_expected_line(unexpected_line, lines), time_out) - Report.critical_result(("Unexpected line not found: " + unexpected_line, "Unexpected line found: " + unexpected_line), not find_expected_line(unexpected_line, lines)) + @staticmethod + def fail_if_log_line_found(window, line, print_infos, time_out): + """ + Reports a failure if a log line in a list of tracer log lines is found. + :param window: The log's window name. For example, logs printed via script-canvas use the "Script" window. + :param line: The log message we're hoping to not find. + :param print_infos: A list of PrintInfos collected by Tracer to search. Example options: your_tracer.warnings, your_tracer.errors, your_tracer.asserts, or your_tracer.prints + :param time_out: The total amount of time to wait before giving up looking for the unexpected line. If time runs out and we don't see the unexpected line then report a success. + :return: No return value, but if the line is found, a failed critical result is reported; otherwise success. + """ + TestHelper.wait_for_condition(lambda : TestHelper.find_line(window, line, print_infos), time_out) + Report.critical_result(("Unexpected line not found: " + line, "Unexpected line found: " + line), not TestHelper.find_line(window, line, print_infos)) + @staticmethod + def multiplayer_enter_game_mode(msgtuple_success_fail: Tuple[str, str], sv_default_player_spawn_asset: str) -> None: + """ + :param msgtuple_success_fail: The tuple with the expected/unexpected messages for entering game mode. + :param sv_default_player_spawn_asset: The path to the network player prefab that will be automatically spawned upon entering gamemode. The engine default is "prefabs/player.network.spawnable" + + :return: None + """ Report.info("Entering game mode") if sv_default_player_spawn_asset : general.set_cvar("sv_defaultPlayerSpawnAsset", sv_default_player_spawn_asset) @@ -135,20 +161,20 @@ class TestHelper: multiplayer.PythonEditorFuncs_enter_game_mode() # make sure the server launcher binary exists - wait_for_critical_unexpected_line("LaunchEditorServer failed! The ServerLauncher binary is missing!", section_tracer.errors, 0.5) + TestHelper.fail_if_log_line_found("MultiplayerEditor", "LaunchEditorServer failed! The ServerLauncher binary is missing!", section_tracer.errors, 0.5) # make sure the server launcher is running waiter.wait_for(lambda: process_utils.process_exists("AutomatedTesting.ServerLauncher", ignore_extensions=True), timeout=5.0, exc=AssertionError("AutomatedTesting.ServerLauncher has NOT launched!"), interval=1.0) - wait_for_critical_expected_line("MultiplayerEditorConnection: Editor-server activation has found and connected to the editor.", section_tracer.prints, 15.0) + TestHelper.succeed_if_log_line_found("EditorServer", "MultiplayerEditorConnection: Editor-server activation has found and connected to the editor.", section_tracer.prints, 15.0) - wait_for_critical_expected_line("Editor is sending the editor-server the level data packet.", section_tracer.prints, 5.0) + TestHelper.succeed_if_log_line_found("MultiplayerEditor", "Editor is sending the editor-server the level data packet.", section_tracer.prints, 5.0) - wait_for_critical_expected_line("Logger: Editor Server completed receiving the editor's level assets, responding to Editor...", section_tracer.prints, 5.0) + TestHelper.succeed_if_log_line_found("EditorServer", "Logger: Editor Server completed receiving the editor's level assets, responding to Editor...", section_tracer.prints, 5.0) - wait_for_critical_expected_line("Editor-server ready. Editor has successfully connected to the editor-server's network simulation.", section_tracer.prints, 5.0) + TestHelper.succeed_if_log_line_found("MultiplayerEditorConnection", "Editor-server ready. Editor has successfully connected to the editor-server's network simulation.", section_tracer.prints, 5.0) - wait_for_critical_unexpected_line(f"MultiplayerSystemComponent: SpawnDefaultPlayerPrefab failed. Missing sv_defaultPlayerSpawnAsset at path '{sv_default_player_spawn_asset.lower()}'.", section_tracer.prints, 0.5) + TestHelper.fail_if_log_line_found("EditorServer", f"MultiplayerSystemComponent: SpawnDefaultPlayerPrefab failed. Missing sv_defaultPlayerSpawnAsset at path '{sv_default_player_spawn_asset.lower()}'.", section_tracer.prints, 0.5) TestHelper.wait_for_condition(lambda : multiplayer.PythonEditorFuncs_is_in_game_mode(), 5.0) Report.critical_result(msgtuple_success_fail, multiplayer.PythonEditorFuncs_is_in_game_mode()) diff --git a/AutomatedTesting/Gem/PythonTests/Multiplayer/TestSuite_Sandbox.py b/AutomatedTesting/Gem/PythonTests/Multiplayer/TestSuite_Sandbox.py index 8f50d4d36d..8c5f33993d 100644 --- a/AutomatedTesting/Gem/PythonTests/Multiplayer/TestSuite_Sandbox.py +++ b/AutomatedTesting/Gem/PythonTests/Multiplayer/TestSuite_Sandbox.py @@ -32,3 +32,6 @@ class TestAutomation(TestAutomationBase): from .tests import Multiplayer_AutoComponent_NetworkInput as test_module self._run_prefab_test(request, workspace, editor, test_module) + def test_Multiplayer_AutoComponent_RPC(self, request, workspace, editor, launcher_platform): + from .tests import Multiplayer_AutoComponent_RPC as test_module + self._run_prefab_test(request, workspace, editor, test_module) diff --git a/AutomatedTesting/Gem/PythonTests/Multiplayer/tests/Multiplayer_AutoComponent_RPC.py b/AutomatedTesting/Gem/PythonTests/Multiplayer/tests/Multiplayer_AutoComponent_RPC.py new file mode 100644 index 0000000000..827826cbcc --- /dev/null +++ b/AutomatedTesting/Gem/PythonTests/Multiplayer/tests/Multiplayer_AutoComponent_RPC.py @@ -0,0 +1,83 @@ +""" +Copyright (c) Contributors to the Open 3D Engine Project. +For complete copyright and license terms please see the LICENSE at the root of this distribution. + +SPDX-License-Identifier: Apache-2.0 OR MIT +""" + + +# Test Case Title : Check that the four network RPCs can be sent and received + + +# fmt: off +class TestSuccessFailTuples(): + enter_game_mode = ("Entered game mode", "Failed to enter game mode") + exit_game_mode = ("Exited game mode", "Couldn't exit game mode") + find_network_player = ("Found network player", "Couldn't find network player") +# fmt: on + + +def Multiplayer_AutoComponent_RPC(): + r""" + Summary: + Runs a test to make sure that RPCs can be sent and received via script canvas + + Level Description: + - Dynamic + 1. Although the level is nearly empty, when the server and editor connect the server will spawn and replicate the player network prefab. + a. The player network prefab has a NetworkTestPlayerComponent.AutoComponent and a script canvas attached which sends and receives various RPCs. + Print logs occur upon sending and receiving the RPCs; we are testing to make sure the expected events and values are received. + - Static + 1. NetLevelEntity. This is a networked entity which has a script attached. Used for cross-entity communication. The net-player prefab will send this level entity Server->Authority RPCs + + + Expected Outcome: + We should see editor logs stating that RPCs have been sent and received. + However, if the script receives unexpected values for the Process event we will see print logs for bad data as well. + + :return: + """ + import azlmbr.legacy.general as general + from editor_python_test_tools.utils import Report + from editor_python_test_tools.utils import Tracer + + from editor_python_test_tools.utils import TestHelper as helper + from ly_remote_console.remote_console_commands import RemoteConsole as RemoteConsole + + level_name = "AutoComponent_RPC" + player_prefab_name = "Player" + player_prefab_path = f"levels/multiplayer/{level_name}/{player_prefab_name}.network.spawnable" + + helper.init_idle() + + # 1) Open Level + helper.open_level("Multiplayer", level_name) + + with Tracer() as section_tracer: + # 2) Enter game mode + helper.multiplayer_enter_game_mode(TestSuccessFailTuples.enter_game_mode, player_prefab_path.lower()) + + # 3) Make sure the network player was spawned + player_id = general.find_game_entity(player_prefab_name) + Report.critical_result(TestSuccessFailTuples.find_network_player, player_id.IsValid()) + + # 4) Check the editor logs for expected and unexpected log output + PLAYERID_RPC_WAIT_TIME_SECONDS = 1.0 # The player id is sent from the server as soon as the player script is spawned. 1 second should be more than enough time to send/receive that RPC. + helper.succeed_if_log_line_found('EditorServer', 'Script: AutoComponent_RPC: Sending client PlayerNumber 1', section_tracer.prints, PLAYERID_RPC_WAIT_TIME_SECONDS) + helper.succeed_if_log_line_found('Script', "AutoComponent_RPC: I'm Player #1", section_tracer.prints, PLAYERID_RPC_WAIT_TIME_SECONDS) + + # Uncomment once editor game-play mode supports level entities with net-binding + #PLAYFX_RPC_WAIT_TIME_SECONDS = 1.1 # The server will send an RPC to play an fx on the client every second. + #helper.succeed_if_log_line_found('EditorServer', "Script: AutoComponent_RPC_NetLevelEntity Activated on entity: NetLevelEntity", section_tracer.prints, PLAYFX_RPC_WAIT_TIME_SECONDS) + #helper.succeed_if_log_line_found('EditorServer', "Script: AutoComponent_RPC_NetLevelEntity: Authority sending RPC to play some fx.", section_tracer.prints, PLAYFX_RPC_WAIT_TIME_SECONDS) + #helper.succeed_if_log_line_found('Script', "AutoComponent_RPC_NetLevelEntity: I'm a client playing some superficial fx.", section_tracer.prints, PLAYFX_RPC_WAIT_TIME_SECONDS) + + + # Exit game mode + helper.exit_game_mode(TestSuccessFailTuples.exit_game_mode) + + + +if __name__ == "__main__": + from editor_python_test_tools.utils import Report + Report.start_test(Multiplayer_AutoComponent_RPC) diff --git a/AutomatedTesting/Gem/PythonTests/Physics/tests/collider/Collider_SameCollisionGroupSameCustomLayerCollide.py b/AutomatedTesting/Gem/PythonTests/Physics/tests/collider/Collider_SameCollisionGroupSameCustomLayerCollide.py index 2e40c0b557..8e8fccd725 100644 --- a/AutomatedTesting/Gem/PythonTests/Physics/tests/collider/Collider_SameCollisionGroupSameCustomLayerCollide.py +++ b/AutomatedTesting/Gem/PythonTests/Physics/tests/collider/Collider_SameCollisionGroupSameCustomLayerCollide.py @@ -127,7 +127,7 @@ def Collider_SameCollisionGroupSameCustomLayerCollide(): # Main Script # 1) Load the level helper.init_idle() - helper.open_level("physics", "Collider_SameCollisionGroupSameCustomLayerCollide") + helper.open_level("Physics", "Collider_SameCollisionGroupSameCustomLayerCollide") # 2) Enter Game Mode helper.enter_game_mode(Tests.enter_game_mode) diff --git a/AutomatedTesting/Gem/PythonTests/Physics/tests/force_region/ForceRegion_MultipleForcesInSameComponentCombineForces.py b/AutomatedTesting/Gem/PythonTests/Physics/tests/force_region/ForceRegion_MultipleForcesInSameComponentCombineForces.py index 7307f3a2fb..e5f6e236cf 100644 --- a/AutomatedTesting/Gem/PythonTests/Physics/tests/force_region/ForceRegion_MultipleForcesInSameComponentCombineForces.py +++ b/AutomatedTesting/Gem/PythonTests/Physics/tests/force_region/ForceRegion_MultipleForcesInSameComponentCombineForces.py @@ -162,7 +162,7 @@ def ForceRegion_MultipleForcesInSameComponentCombineForces(): helper.init_idle() # 1) Load Level - helper.open_level("physics", "ForceRegion_MultipleForcesInSameComponentCombineForces") + helper.open_level("Physics", "ForceRegion_MultipleForcesInSameComponentCombineForces") # 2) Enter Game Mode helper.enter_game_mode(Tests.enter_game_mode) diff --git a/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_DefaultLibraryUpdatedAcrossLevels_after.py b/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_DefaultLibraryUpdatedAcrossLevels_after.py index 1f8cfae498..41ccc8f2dd 100644 --- a/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_DefaultLibraryUpdatedAcrossLevels_after.py +++ b/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_DefaultLibraryUpdatedAcrossLevels_after.py @@ -229,8 +229,8 @@ def Material_DefaultLibraryUpdatedAcrossLevels_after(): for test in test_list: # 1) Open the correct level is open helper.open_level( - "physics", - f"Material_DefaultLibraryUpdatedAcrossLevels\\{test.level}" + "Physics", + os.path.join("Material_DefaultLibraryUpdatedAcrossLevels", str(test.level)) ) # 2) Enter Game Mode diff --git a/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_DefaultLibraryUpdatedAcrossLevels_before.py b/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_DefaultLibraryUpdatedAcrossLevels_before.py index 15db5808e2..d86a016be1 100644 --- a/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_DefaultLibraryUpdatedAcrossLevels_before.py +++ b/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_DefaultLibraryUpdatedAcrossLevels_before.py @@ -189,7 +189,7 @@ def Material_DefaultLibraryUpdatedAcrossLevels_before(): # 1) Open the correct level is open helper.open_level( "Physics", - f"Material_DefaultLibraryUpdatedAcrossLevels\\{test.level}" + os.path.join("Material_DefaultLibraryUpdatedAcrossLevels", str(test.level)) ) # 2) Enter Game Mode diff --git a/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_LibraryUpdatedAcrossLevels.py b/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_LibraryUpdatedAcrossLevels.py index 0b647361f6..6eebfe60bc 100644 --- a/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_LibraryUpdatedAcrossLevels.py +++ b/AutomatedTesting/Gem/PythonTests/Physics/tests/material/Material_LibraryUpdatedAcrossLevels.py @@ -252,10 +252,8 @@ def Material_LibraryUpdatedAcrossLevels(): for test in test_list: # 1) Open the correct level for the test helper.open_level( - "physics", - "Material_LibraryUpdatedAcrossLevels\\Material_LibraryUpdatedAcrossLevels_{}".format( - test.level_index - ), + "Physics", + os.path.join("Material_LibraryUpdatedAcrossLevels", str(test.level_index)) ) # 2) Open Game Mode diff --git a/AutomatedTesting/Gem/PythonTests/Physics/tests/script_canvas/ScriptCanvas_SpawnEntityWithPhysComponents.py b/AutomatedTesting/Gem/PythonTests/Physics/tests/script_canvas/ScriptCanvas_SpawnEntityWithPhysComponents.py index 5862b7586b..e6e29063d6 100644 --- a/AutomatedTesting/Gem/PythonTests/Physics/tests/script_canvas/ScriptCanvas_SpawnEntityWithPhysComponents.py +++ b/AutomatedTesting/Gem/PythonTests/Physics/tests/script_canvas/ScriptCanvas_SpawnEntityWithPhysComponents.py @@ -106,7 +106,7 @@ def ScriptCanvas_SpawnEntityWithPhysComponents(): # Main Script helper.init_idle() # 1) Open Level - helper.open_level("physics", "ScriptCanvas_SpawnEntityWithPhysComponents") + helper.open_level("Physics", "ScriptCanvas_SpawnEntityWithPhysComponents") # 2) Enter Game Mode helper.enter_game_mode(Tests.enter_game_mode) diff --git a/AutomatedTesting/Gem/PythonTests/PythonAssetBuilder/AssetBuilder_test.py b/AutomatedTesting/Gem/PythonTests/PythonAssetBuilder/AssetBuilder_test.py index 45e633a979..cb2c445246 100644 --- a/AutomatedTesting/Gem/PythonTests/PythonAssetBuilder/AssetBuilder_test.py +++ b/AutomatedTesting/Gem/PythonTests/PythonAssetBuilder/AssetBuilder_test.py @@ -12,12 +12,36 @@ import sys import os import pytest import logging +import sqlite3 pytest.importorskip('ly_test_tools') import ly_test_tools.environment.file_system as file_system import ly_test_tools.log.log_monitor import ly_test_tools.environment.waiter as waiter +def detect_product(sql_connection, platform, target): + cur = sql_connection.cursor() + product_target = f'{platform}/{target}' + print(f'Detecting {product_target} in assetdb.sqlite') + hits = 0 + for row in cur.execute(f'select ProductID from Products where ProductName is "{product_target}"'): + hits = hits + 1 + assert hits == 1 + + +def find_products(cache_folder, platform): + con = sqlite3.connect(os.path.join(cache_folder, 'assetdb.sqlite')) + detect_product(con, platform, 'gem/pythontests/pythonassetbuilder/test_asset.mock_asset') + detect_product(con, platform, 'gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_z_positive_1.azmodel') + detect_product(con, platform, 'gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_z_negative_1.azmodel') + detect_product(con, platform, 'gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_y_positive_1.azmodel') + detect_product(con, platform, 'gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_y_negative_1.azmodel') + detect_product(con, platform, 'gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_x_positive_1.azmodel') + detect_product(con, platform, 'gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_x_negative_1.azmodel') + detect_product(con, platform, 'gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_center_1.azmodel') + con.close() + + @pytest.mark.SUITE_periodic @pytest.mark.parametrize('launcher_platform', ['windows_editor']) @pytest.mark.parametrize('project', ['AutomatedTesting']) @@ -25,16 +49,7 @@ import ly_test_tools.environment.waiter as waiter class TestPythonAssetProcessing(object): def test_DetectPythonCreatedAsset(self, request, editor, level, launcher_platform): unexpected_lines = [] - expected_lines = [ - 'Mock asset exists', - 'AssetId found for asset (gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_z_positive_1.azmodel) found', - 'AssetId found for asset (gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_z_negative_1.azmodel) found', - 'AssetId found for asset (gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_y_positive_1.azmodel) found', - 'AssetId found for asset (gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_y_negative_1.azmodel) found', - 'AssetId found for asset (gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_x_positive_1.azmodel) found', - 'AssetId found for asset (gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_x_negative_1.azmodel) found', - 'AssetId found for asset (gem/pythontests/pythonassetbuilder/geom_group_fbx_cube_100cm_center_1.azmodel) found' - ] + expected_lines = [] timeout = 180 halt_on_unexpected = False test_directory = os.path.join(os.path.dirname(__file__)) @@ -50,3 +65,9 @@ class TestPythonAssetProcessing(object): exc=("Log file '{}' was never opened by another process.".format(editorlog_file)), interval=1) log_monitor.monitor_log_for_lines(expected_lines, unexpected_lines, halt_on_unexpected, timeout) + + cache_folder = editor.workspace.paths.cache() + platform = editor.workspace.asset_processor_platform + if platform == 'windows': + platform = 'pc' + find_products(cache_folder, platform) diff --git a/AutomatedTesting/Gem/PythonTests/WhiteBox/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/WhiteBox/CMakeLists.txt index 733e8edf29..d4554ee84b 100644 --- a/AutomatedTesting/Gem/PythonTests/WhiteBox/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonTests/WhiteBox/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # for PAL_TRAIT_WHITEBOX Traits diff --git a/AutomatedTesting/Gem/PythonTests/assetpipeline/ap_fixtures/clear_moveoutput_fixture.py b/AutomatedTesting/Gem/PythonTests/assetpipeline/ap_fixtures/clear_moveoutput_fixture.py index 30ecac9a65..4b23f52006 100755 --- a/AutomatedTesting/Gem/PythonTests/assetpipeline/ap_fixtures/clear_moveoutput_fixture.py +++ b/AutomatedTesting/Gem/PythonTests/assetpipeline/ap_fixtures/clear_moveoutput_fixture.py @@ -3,8 +3,6 @@ Copyright (c) Contributors to the Open 3D Engine Project. For complete copyright and license terms please see the LICENSE at the root of this distribution. SPDX-License-Identifier: Apache-2.0 OR MIT - -Fixture for clearing out 'MoveOutput' folders from \dev and \dev\PROJECT """ # Import builtin libraries diff --git a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/CMakeLists.txt index e37a5ed99b..5839093473 100644 --- a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/CMakeLists.txt @@ -93,15 +93,19 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS) ) ly_add_pytest( - NAME AssetPipelineTests.AssetBundler - PATH ${CMAKE_CURRENT_LIST_DIR}/asset_bundler_batch_tests.py + NAME AssetPipelineTests.AssetBuilder + PATH ${CMAKE_CURRENT_LIST_DIR}/asset_builder_tests.py EXCLUDE_TEST_RUN_TARGET_FROM_IDE TEST_SERIAL TEST_SUITE periodic RUNTIME_DEPENDENCIES AZ::AssetProcessor - AZ::AssetBundlerBatch ) + + set(SUPPORTED_PLATFORMS "Windows" "Mac") + if (NOT "${PAL_PLATFORM_NAME}" IN_LIST SUPPORTED_PLATFORMS) + return() + endif() ly_add_pytest( NAME AssetPipelineTests.BundleMode @@ -117,16 +121,16 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS) ) ly_add_pytest( - NAME AssetPipelineTests.AssetBuilder - PATH ${CMAKE_CURRENT_LIST_DIR}/asset_builder_tests.py + NAME AssetPipelineTests.AssetBundler + PATH ${CMAKE_CURRENT_LIST_DIR}/asset_bundler_batch_tests.py EXCLUDE_TEST_RUN_TARGET_FROM_IDE TEST_SERIAL TEST_SUITE periodic RUNTIME_DEPENDENCIES AZ::AssetProcessor + AZ::AssetBundlerBatch ) - ly_add_pytest( NAME AssetPipelineTests.MissingDependency PATH ${CMAKE_CURRENT_LIST_DIR}/missing_dependency_tests.py @@ -136,5 +140,5 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS) RUNTIME_DEPENDENCIES AZ::AssetProcessorBatch ) - + endif() diff --git a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/asset_bundler_batch_tests.py b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/asset_bundler_batch_tests.py index f5e5642573..f64427f6df 100755 --- a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/asset_bundler_batch_tests.py +++ b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/asset_bundler_batch_tests.py @@ -108,7 +108,7 @@ class TestsAssetBundlerBatch_WindowsAndMac(object): """ helper = bundler_batch_helper seed_list = os.path.join(workspace.paths.engine_root(), "Assets", "Engine", "SeedAssetList.seed") # Engine seed list - asset = r"levels\testdependencieslevel\level.pak" + asset = r"levels\testdependencieslevel\testdependencieslevel.spawnable" # Create Asset list helper.call_assetLists( @@ -191,7 +191,7 @@ class TestsAssetBundlerBatch_WindowsAndMac(object): """ helper = bundler_batch_helper seed_list = os.path.join(workspace.paths.engine_root(), "Assets", "Engine", "SeedAssetList.seed") # Engine seed list - asset = r"levels\testdependencieslevel\level.pak" + asset = r"levels\testdependencieslevel\testdependencieslevel.spawnable" # Useful bundle locations / names (2 for comparing contents) # fmt:off @@ -924,7 +924,7 @@ class TestsAssetBundlerBatch_WindowsAndMac(object): # Create a seed file helper.call_seeds( seedListFile=helper["seed_list_file"], - addSeed=r"levels\testdependencieslevel\level.pak", + addSeed=r"levels\testdependencieslevel\testdependencieslevel.spawnable", platform="pc", ) @@ -947,9 +947,9 @@ class TestsAssetBundlerBatch_WindowsAndMac(object): # Specifying platform but not "add" or "remove" should fail result, _ = helper.call_assetLists( assetListFile=helper["asset_info_file_request"], + allowOverwrites="", seedListFile=helper["seed_list_file"], platform="pc", - allowOverwrites="", ) assert result, "Overwriting with override threw an error" @@ -982,7 +982,7 @@ class TestsAssetBundlerBatch_WindowsAndMac(object): request.addfinalizer(lambda: fs.delete([bundle_result_path], True, False)) bundles_folder = os.path.join(workspace.paths.project(), "Bundles") - level_pak = r"levels\testdependencieslevel\level.pak" + level_pak = r"levels\testdependencieslevel\testdependencieslevel.spawnable" bundle_request_path = os.path.join(bundles_folder, "bundle.pak") bundle_result_path = os.path.join(bundles_folder, helper.platform_file_name("bundle.pak", workspace.asset_processor_platform)) diff --git a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/asset_relocator_tests.py b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/asset_relocator_tests.py index 744720323e..42c83c7c25 100755 --- a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/asset_relocator_tests.py +++ b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/asset_relocator_tests.py @@ -169,17 +169,17 @@ class TestsAssetRelocator_WindowsAndMac(object): @pytest.mark.test_case_id("C21968388") @pytest.mark.assetpipeline - def test_WindowsMacPlatforms_MoveCorruptedSliceFile_MoveSuccess(self, request, workspace, ap_setup_fixture, + def test_WindowsMacPlatforms_MoveCorruptedPrefabFile_MoveSuccess(self, request, workspace, ap_setup_fixture, asset_processor): """ Asset with UUID/AssetId reference in non-standard format is successfully scanned and relocated to the MoveOutput folder. - This test uses a pre-corrupted .slice file. + This test uses a pre-corrupted .prefab file. Test Steps: - 1. Create temporary testing environment with a corrupted slice - 2. Attempt to move the corrupted slice - 3. Verify that corrupted slice was moved successfully + 1. Create temporary testing environment with a corrupted prefab + 2. Attempt to move the corrupted prefab + 3. Verify that corrupted prefab was moved successfully """ env = ap_setup_fixture @@ -187,7 +187,7 @@ class TestsAssetRelocator_WindowsAndMac(object): asset_folder = "C21968388" source_dir, _ = asset_processor.prepare_test_environment(env["tests_dir"], asset_folder) - filename = "DependencyScannerAsset.slice" + filename = "DependencyScannerAsset.prefab" file_path = os.path.join(source_dir, filename) dst_rel_path = os.path.join("MoveOutput", filename) dst_full_path = os.path.join(source_dir, dst_rel_path) diff --git a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/assets/C21968388/DependencyScannerAsset.prefab b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/assets/C21968388/DependencyScannerAsset.prefab new file mode 100644 index 0000000000..1ba25b4463 --- /dev/null +++ b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/assets/C21968388/DependencyScannerAsset.prefab @@ -0,0 +1,908 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "DependencyScannerAsset", + "Components": { + "Component_[10182366347512475253]": { + "$type": "EditorPrefabComponent", + "Id": 10182366347512475253 + }, + "Component_[12917798267488243668]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12917798267488243668 + }, + "Component_[3261249813163778338]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3261249813163778338 + }, + "Component_[3837204912784440039]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 3837204912784440039 + }, + "Component_[4272963378099646759]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 4272963378099646759, + "Parent Entity": "" + }, + "Component_[4848458548047175816]": { + "$type": "EditorVisibilityComponent", + "Id": 4848458548047175816 + }, + "Component_[5787060997243919943]": { + "$type": "EditorInspectorComponent", + "Id": 5787060997243919943 + }, + "Component_[7804170251266531779]": { + "$type": "EditorLockComponent", + "Id": 7804170251266531779 + }, + "Component_[7874177159288365422]": { + "$type": "EditorEntitySortComponent", + "Id": 7874177159288365422 + }, + "Component_[8018146290632383969]": { + "$type": "EditorEntityIconComponent", + "Id": 8018146290632383969 + }, + "Component_[8452360690590857075]": { + "$type": "SelectionComponent", + "Id": 8452360690590857075 + } + } + }, + "Entities": { + "Entity_[274004659287]": { + "Id": "Entity_[274004659287]", + "Name": "DependencyScannerAsset", + "Components": { + "Component_[10849460799799271301]": { + "$type": "EditorPendingCompositionComponent", + "Id": 10849460799799271301 + }, + "Component_[11098142762746045658]": { + "$type": "SelectionComponent", + "Id": 11098142762746045658 + }, + "Component_[11154538629717040387]": { + "$type": "EditorEntitySortComponent", + "Id": 11154538629717040387, + "Child Entity Order": [ + "Entity_[305822185575]", + "Entity_[278299626583]", + "Entity_[282594593879]", + "Entity_[286889561175]", + "Entity_[291184528471]" + ] + }, + "Component_[1365196255752273753]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1365196255752273753 + }, + "Component_[280906579560376421]": { + "$type": "EditorLockComponent", + "Id": 280906579560376421 + }, + "Component_[4629965429001113748]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4629965429001113748 + }, + "Component_[4876910656129741263]": { + "$type": "EditorEntityIconComponent", + "Id": 4876910656129741263 + }, + "Component_[5763306492614623496]": { + "$type": "EditorInspectorComponent", + "Id": 5763306492614623496, + "ComponentOrderEntryArray": [ + { + "ComponentId": 7514977506847036117 + } + ] + }, + "Component_[7327709568605458460]": { + "$type": "EditorVisibilityComponent", + "Id": 7327709568605458460 + }, + "Component_[7514977506847036117]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7514977506847036117, + "Parent Entity": "ContainerEntity" + } + } + }, + "Entity_[278299626583]": { + "Id": "Entity_[278299626583]", + "Name": "AssetIDMatch", + "Components": { + "Component_[10285740519857855186]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10285740519857855186 + }, + "Component_[11273731016303624898]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11273731016303624898, + "Parent Entity": "Entity_[274004659287]" + }, + "Component_[1136790983026972010]": { + "$type": "EditorVisibilityComponent", + "Id": 1136790983026972010 + }, + "Component_[12777313618328131055]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12777313618328131055 + }, + "Component_[13256044902558773795]": { + "$type": "EditorLockComponent", + "Id": 13256044902558773795 + }, + "Component_[15834551022302435776]": { + "$type": "EditorInspectorComponent", + "Id": 15834551022302435776, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11273731016303624898 + }, + { + "ComponentId": 9671522714018290727, + "SortIndex": 1 + } + ] + }, + "Component_[16345420368214930095]": { + "$type": "SelectionComponent", + "Id": 16345420368214930095 + }, + "Component_[5309075942188429052]": { + "$type": "EditorEntitySortComponent", + "Id": 5309075942188429052 + }, + "Component_[8639731896786645938]": { + "$type": "EditorEntityIconComponent", + "Id": 8639731896786645938 + }, + "Component_[9844585173698551415]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9844585173698551415 + } + } + }, + "Entity_[282594593879]": { + "Id": "Entity_[282594593879]", + "Name": "UUIDMatch", + "Components": { + "Component_[10379494986254888760]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10379494986254888760 + }, + "Component_[10932830014545295552]": { + "$type": "SelectionComponent", + "Id": 10932830014545295552 + }, + "Component_[16077882919902242532]": { + "$type": "EditorEntitySortComponent", + "Id": 16077882919902242532 + }, + "Component_[2150375322459274584]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2150375322459274584 + }, + "Component_[2645455411436465820]": { + "$type": "EditorEntityIconComponent", + "Id": 2645455411436465820 + }, + "Component_[5422214869037468733]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5422214869037468733 + }, + "Component_[7238126895911071330]": { + "$type": "EditorInspectorComponent", + "Id": 7238126895911071330, + "ComponentOrderEntryArray": [ + { + "ComponentId": 8407607000804893064 + }, + { + "ComponentId": 12952323341649885242, + "SortIndex": 1 + } + ] + }, + "Component_[7981670269715131988]": { + "$type": "EditorVisibilityComponent", + "Id": 7981670269715131988 + }, + "Component_[8407607000804893064]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 8407607000804893064, + "Parent Entity": "Entity_[274004659287]" + }, + "Component_[8567641786004090803]": { + "$type": "EditorLockComponent", + "Id": 8567641786004090803 + } + } + }, + "Entity_[286889561175]": { + "Id": "Entity_[286889561175]", + "Name": "RelativeProductMatch", + "Components": { + "Component_[10180645282669228972]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10180645282669228972, + "Parent Entity": "Entity_[274004659287]" + }, + "Component_[10200807690182688147]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10200807690182688147 + }, + "Component_[11014661873645081316]": { + "$type": "EditorInspectorComponent", + "Id": 11014661873645081316, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10180645282669228972 + }, + { + "ComponentId": 12869852248016369650, + "SortIndex": 1 + } + ] + }, + "Component_[12869852248016369650]": { + "$type": "{77CDE991-EC1A-B7C1-B112-7456ABAC81A1} EditorSpawnerComponent", + "Id": 12869852248016369650, + "Slice": { + "assetId": { + "guid": "{29F14025-3BD2-5CA9-A9DE-B8B349268C2F}", + "subId": 2 + }, + "assetHint": "slices/bullet.dynamicslice" + } + }, + "Component_[15136448544716183259]": { + "$type": "EditorOnlyEntityComponent", + "Id": 15136448544716183259 + }, + "Component_[15966001894874626764]": { + "$type": "SelectionComponent", + "Id": 15966001894874626764 + }, + "Component_[16167982631516160155]": { + "$type": "EditorEntityIconComponent", + "Id": 16167982631516160155 + }, + "Component_[16672905198052847867]": { + "$type": "EditorEntitySortComponent", + "Id": 16672905198052847867 + }, + "Component_[4506946122562404190]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4506946122562404190 + }, + "Component_[6836304267269231429]": { + "$type": "EditorLockComponent", + "Id": 6836304267269231429 + }, + "Component_[8756593519140349183]": { + "$type": "EditorVisibilityComponent", + "Id": 8756593519140349183 + } + } + }, + "Entity_[291184528471]": { + "Id": "Entity_[291184528471]", + "Name": "RelativeSourceMatch", + "Components": { + "Component_[11694027325905361034]": { + "$type": "EditorEntitySortComponent", + "Id": 11694027325905361034 + }, + "Component_[13891029613307790064]": { + "$type": "EditorEntityIconComponent", + "Id": 13891029613307790064 + }, + "Component_[15933511034411930900]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15933511034411930900, + "Parent Entity": "Entity_[274004659287]" + }, + "Component_[17540827492846961803]": { + "$type": "EditorLockComponent", + "Id": 17540827492846961803 + }, + "Component_[2850297705939373458]": { + "$type": "SelectionComponent", + "Id": 2850297705939373458 + }, + "Component_[4809103331004345812]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4809103331004345812 + }, + "Component_[5654779331777839943]": { + "$type": "EditorInspectorComponent", + "Id": 5654779331777839943, + "ComponentOrderEntryArray": [ + { + "ComponentId": 15933511034411930900 + }, + { + "ComponentId": 10284025539900054207, + "SortIndex": 1 + } + ] + }, + "Component_[6097019179005900386]": { + "$type": "EditorVisibilityComponent", + "Id": 6097019179005900386 + }, + "Component_[7748387730313625157]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 7748387730313625157 + }, + "Component_[9822265453841229082]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9822265453841229082 + } + } + }, + "Entity_[297232250983]": { + "Id": "Entity_[297232250983]", + "Name": "1151F14D38A65579888ABE3139882E68:[0]", + "Components": { + "Component_[11936148741777754959]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 11936148741777754959 + }, + "Component_[12610073699988743015]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 12610073699988743015, + "Parent Entity": "Entity_[305822185575]" + }, + "Component_[1603205169722765279]": { + "$type": "EditorLockComponent", + "Id": 1603205169722765279 + }, + "Component_[17691206348057560715]": { + "$type": "EditorPendingCompositionComponent", + "Id": 17691206348057560715 + }, + "Component_[2711821203680330048]": { + "$type": "SelectionComponent", + "Id": 2711821203680330048 + }, + "Component_[3887480309311474860]": { + "$type": "EditorVisibilityComponent", + "Id": 3887480309311474860 + }, + "Component_[5853968883842282450]": { + "$type": "EditorEntityIconComponent", + "Id": 5853968883842282450 + }, + "Component_[7679080692843343453]": { + "$type": "EditorCommentComponent", + "Id": 7679080692843343453, + "Configuration": "Asset ID that matches an existing dependency of this asset (am_grass1.mtl)" + }, + "Component_[8024752235278898687]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8024752235278898687 + }, + "Component_[8373296084678231042]": { + "$type": "EditorEntitySortComponent", + "Id": 8373296084678231042 + }, + "Component_[9782967158965587831]": { + "$type": "EditorInspectorComponent", + "Id": 9782967158965587831, + "ComponentOrderEntryArray": [ + { + "ComponentId": 12610073699988743015 + }, + { + "ComponentId": 7679080692843343453, + "SortIndex": 1 + } + ] + } + } + }, + "Entity_[301527218279]": { + "Id": "Entity_[301527218279]", + "Name": "Slices/bullet.dynamicslice", + "Components": { + "Component_[15613078542630153866]": { + "$type": "EditorInspectorComponent", + "Id": 15613078542630153866, + "ComponentOrderEntryArray": [ + { + "ComponentId": 2483032678718995164 + }, + { + "ComponentId": 9734604379060902193, + "SortIndex": 1 + } + ] + }, + "Component_[16098942854900817264]": { + "$type": "SelectionComponent", + "Id": 16098942854900817264 + }, + "Component_[16720139961856477500]": { + "$type": "EditorEntitySortComponent", + "Id": 16720139961856477500 + }, + "Component_[2483032678718995164]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 2483032678718995164, + "Parent Entity": "Entity_[305822185575]" + }, + "Component_[2502984783426127018]": { + "$type": "EditorLockComponent", + "Id": 2502984783426127018 + }, + "Component_[46714013890147210]": { + "$type": "EditorOnlyEntityComponent", + "Id": 46714013890147210 + }, + "Component_[4907474530744780429]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4907474530744780429 + }, + "Component_[5420332829198300813]": { + "$type": "EditorPendingCompositionComponent", + "Id": 5420332829198300813 + }, + "Component_[7683578164681693579]": { + "$type": "EditorEntityIconComponent", + "Id": 7683578164681693579 + }, + "Component_[8312115250363172310]": { + "$type": "EditorVisibilityComponent", + "Id": 8312115250363172310 + }, + "Component_[9734604379060902193]": { + "$type": "EditorCommentComponent", + "Id": 9734604379060902193, + "Configuration": "Relative product path that matches an existing dependency of this asset" + } + } + }, + "Entity_[305822185575]": { + "Id": "Entity_[305822185575]", + "Name": "AssetReferences", + "Components": { + "Component_[13422135993444528172]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13422135993444528172 + }, + "Component_[13988015667379021413]": { + "$type": "EditorLockComponent", + "Id": 13988015667379021413 + }, + "Component_[14885956487876614434]": { + "$type": "EditorVisibilityComponent", + "Id": 14885956487876614434 + }, + "Component_[15550715415947731915]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15550715415947731915 + }, + "Component_[2576266145980379805]": { + "$type": "EditorInspectorComponent", + "Id": 2576266145980379805, + "ComponentOrderEntryArray": [ + { + "ComponentId": 3176911836967955668 + }, + { + "ComponentId": 836721549453007197, + "SortIndex": 1 + } + ] + }, + "Component_[3176911836967955668]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3176911836967955668, + "Parent Entity": "Entity_[274004659287]" + }, + "Component_[5613459137294642234]": { + "$type": "SelectionComponent", + "Id": 5613459137294642234 + }, + "Component_[6400873582148097152]": { + "$type": "EditorEntityIconComponent", + "Id": 6400873582148097152 + }, + "Component_[684670817803453913]": { + "$type": "EditorEntitySortComponent", + "Id": 684670817803453913, + "Child Entity Order": [ + "Entity_[323002054759]", + "Entity_[327297022055]", + "Entity_[301527218279]", + "Entity_[318707087463]", + "Entity_[297232250983]", + "Entity_[314412120167]", + "Entity_[331591989351]", + "Entity_[310117152871]" + ] + }, + "Component_[8118206464926826097]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118206464926826097 + }, + "Component_[836721549453007197]": { + "$type": "EditorCommentComponent", + "Id": 836721549453007197, + "Configuration": "Entity names are used to trigger the missing dependency scanner. Comments are stripped from dynamic slices." + } + } + }, + "Entity_[310117152871]": { + "Id": "Entity_[310117152871]", + "Name": "Materials/FakeMaterial.mtl", + "Components": { + "Component_[10593857511582714674]": { + "$type": "EditorInspectorComponent", + "Id": 10593857511582714674, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11797216659359478300 + }, + { + "ComponentId": 13816702107134233983, + "SortIndex": 1 + } + ] + }, + "Component_[11797216659359478300]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11797216659359478300, + "Parent Entity": "Entity_[305822185575]" + }, + "Component_[13816702107134233983]": { + "$type": "EditorCommentComponent", + "Id": 13816702107134233983, + "Configuration": "Invalid path that does not match an existing dependency of this asset" + }, + "Component_[14868583012186337705]": { + "$type": "EditorOnlyEntityComponent", + "Id": 14868583012186337705 + }, + "Component_[14965348027145283648]": { + "$type": "EditorEntitySortComponent", + "Id": 14965348027145283648 + }, + "Component_[15075774238648121688]": { + "$type": "EditorEntityIconComponent", + "Id": 15075774238648121688 + }, + "Component_[16157883709857447266]": { + "$type": "EditorLockComponent", + "Id": 16157883709857447266 + }, + "Component_[17712080510249108208]": { + "$type": "EditorVisibilityComponent", + "Id": 17712080510249108208 + }, + "Component_[2247408514677946398]": { + "$type": "SelectionComponent", + "Id": 2247408514677946398 + }, + "Component_[5565369976544134481]": { + "$type": "EditorPendingCompositionComponent", + "Id": 5565369976544134481 + }, + "Component_[6044814215558788086]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 6044814215558788086 + } + } + }, + "Entity_[314412120167]": { + "Id": "Entity_[314412120167]", + "Name": "88888888-4444-4444-4444-CCCCCCCCCCCC", + "Components": { + "Component_[10072177500579430176]": { + "$type": "EditorLockComponent", + "Id": 10072177500579430176 + }, + "Component_[10853215476279564671]": { + "$type": "EditorCommentComponent", + "Id": 10853215476279564671, + "Configuration": "UUID that does not exist" + }, + "Component_[13413154971272749631]": { + "$type": "SelectionComponent", + "Id": 13413154971272749631 + }, + "Component_[15316173756367163440]": { + "$type": "EditorInspectorComponent", + "Id": 15316173756367163440, + "ComponentOrderEntryArray": [ + { + "ComponentId": 3266728630359207653 + }, + { + "ComponentId": 10853215476279564671, + "SortIndex": 1 + } + ] + }, + "Component_[15809307959802829291]": { + "$type": "EditorEntitySortComponent", + "Id": 15809307959802829291 + }, + "Component_[17649652752752487081]": { + "$type": "EditorEntityIconComponent", + "Id": 17649652752752487081 + }, + "Component_[2130036493438440377]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2130036493438440377 + }, + "Component_[3266728630359207653]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3266728630359207653, + "Parent Entity": "Entity_[305822185575]" + }, + "Component_[5892125564582966187]": { + "$type": "EditorVisibilityComponent", + "Id": 5892125564582966187 + }, + "Component_[597602776660257245]": { + "$type": "EditorOnlyEntityComponent", + "Id": 597602776660257245 + }, + "Component_[8238652007701465495]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8238652007701465495 + } + } + }, + "Entity_[318707087463]": { + "Id": "Entity_[318707087463]", + "Name": "BBA1A5494C73578894BF0692CDA5FC33", + "Components": { + "Component_[10222455787643359341]": { + "$type": "EditorPendingCompositionComponent", + "Id": 10222455787643359341 + }, + "Component_[11487845392038268864]": { + "$type": "SelectionComponent", + "Id": 11487845392038268864 + }, + "Component_[12135534290310046764]": { + "$type": "EditorVisibilityComponent", + "Id": 12135534290310046764 + }, + "Component_[14412623226519978498]": { + "$type": "EditorOnlyEntityComponent", + "Id": 14412623226519978498 + }, + "Component_[14516371382857751872]": { + "$type": "EditorEntityIconComponent", + "Id": 14516371382857751872 + }, + "Component_[16011611743122468576]": { + "$type": "EditorInspectorComponent", + "Id": 16011611743122468576, + "ComponentOrderEntryArray": [ + { + "ComponentId": 4157328932578509254 + }, + { + "ComponentId": 8524796860605854850, + "SortIndex": 1 + } + ] + }, + "Component_[3813931698067937301]": { + "$type": "EditorEntitySortComponent", + "Id": 3813931698067937301 + }, + "Component_[4157328932578509254]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 4157328932578509254, + "Parent Entity": "Entity_[305822185575]" + }, + "Component_[8524796860605854850]": { + "$type": "EditorCommentComponent", + "Id": 8524796860605854850, + "Configuration": "UUID that matches an existing dependency of this asset (lumbertank_body.cgf)" + }, + "Component_[8660819596448699427]": { + "$type": "EditorLockComponent", + "Id": 8660819596448699427 + }, + "Component_[8768262795169819026]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8768262795169819026 + } + } + }, + "Entity_[323002054759]": { + "Id": "Entity_[323002054759]", + "Name": "Materials/am_rockground.mtl", + "Components": { + "Component_[13459503224133892836]": { + "$type": "EditorEntityIconComponent", + "Id": 13459503224133892836 + }, + "Component_[1346698328271204385]": { + "$type": "EditorVisibilityComponent", + "Id": 1346698328271204385 + }, + "Component_[13662830241397426219]": { + "$type": "SelectionComponent", + "Id": 13662830241397426219 + }, + "Component_[14169735046939083706]": { + "$type": "EditorInspectorComponent", + "Id": 14169735046939083706, + "ComponentOrderEntryArray": [ + { + "ComponentId": 833157791612452820 + }, + { + "ComponentId": 3573928838741352115, + "SortIndex": 1 + } + ] + }, + "Component_[16049700338512950477]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16049700338512950477 + }, + "Component_[16191253524853449302]": { + "$type": "EditorOnlyEntityComponent", + "Id": 16191253524853449302 + }, + "Component_[1737139665005484521]": { + "$type": "EditorPendingCompositionComponent", + "Id": 1737139665005484521 + }, + "Component_[17562284119637289685]": { + "$type": "EditorEntitySortComponent", + "Id": 17562284119637289685 + }, + "Component_[3573928838741352115]": { + "$type": "EditorCommentComponent", + "Id": 3573928838741352115, + "Configuration": "Relative source path that matches an existing dependency of this asset" + }, + "Component_[485401015869338526]": { + "$type": "EditorLockComponent", + "Id": 485401015869338526 + }, + "Component_[833157791612452820]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 833157791612452820, + "Parent Entity": "Entity_[305822185575]" + } + } + }, + "Entity_[327297022055]": { + "Id": "Entity_[327297022055]", + "Name": "Config/Game.xml", + "Components": { + "Component_[11848260632907964142]": { + "$type": "EditorInspectorComponent", + "Id": 11848260632907964142, + "ComponentOrderEntryArray": [ + { + "ComponentId": 497869813123895830 + }, + { + "ComponentId": 5248857300320701553, + "SortIndex": 1 + } + ] + }, + "Component_[12842864953492512672]": { + "$type": "EditorEntitySortComponent", + "Id": 12842864953492512672 + }, + "Component_[16656501539883791157]": { + "$type": "EditorLockComponent", + "Id": 16656501539883791157 + }, + "Component_[17365661125603122123]": { + "$type": "EditorEntityIconComponent", + "Id": 17365661125603122123 + }, + "Component_[2967487135389707052]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 2967487135389707052 + }, + "Component_[3356294263684362888]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3356294263684362888 + }, + "Component_[497869813123895830]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 497869813123895830, + "Parent Entity": "Entity_[305822185575]" + }, + "Component_[5248857300320701553]": { + "$type": "EditorCommentComponent", + "Id": 5248857300320701553, + "Configuration": "Valid path that does not match an existing dependency of this asset. Should report as a missing dependency" + }, + "Component_[746309483212393367]": { + "$type": "SelectionComponent", + "Id": 746309483212393367 + }, + "Component_[8319831469290771470]": { + "$type": "EditorPendingCompositionComponent", + "Id": 8319831469290771470 + }, + "Component_[9369067377618608622]": { + "$type": "EditorVisibilityComponent", + "Id": 9369067377618608622 + } + } + }, + "Entity_[331591989351]": { + "Id": "Entity_[331591989351]", + "Name": "1151F14D38A65579888ABE3139882E68:[333]", + "Components": { + "Component_[104857639379046106]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 104857639379046106, + "Parent Entity": "Entity_[305822185575]" + }, + "Component_[1061601983221247493]": { + "$type": "EditorLockComponent", + "Id": 1061601983221247493 + }, + "Component_[11028443253330664986]": { + "$type": "EditorVisibilityComponent", + "Id": 11028443253330664986 + }, + "Component_[13806275118632081006]": { + "$type": "EditorEntitySortComponent", + "Id": 13806275118632081006 + }, + "Component_[13922573109551604801]": { + "$type": "EditorEntityIconComponent", + "Id": 13922573109551604801 + }, + "Component_[17027032709917108335]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 17027032709917108335 + }, + "Component_[17030988165269698825]": { + "$type": "EditorOnlyEntityComponent", + "Id": 17030988165269698825 + }, + "Component_[2294579021665535860]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2294579021665535860 + }, + "Component_[5863078697041048226]": { + "$type": "EditorInspectorComponent", + "Id": 5863078697041048226, + "ComponentOrderEntryArray": [ + { + "ComponentId": 104857639379046106 + }, + { + "ComponentId": 9466290982672370664, + "SortIndex": 1 + } + ] + }, + "Component_[7608263859116142496]": { + "$type": "SelectionComponent", + "Id": 7608263859116142496 + }, + "Component_[9466290982672370664]": { + "$type": "EditorCommentComponent", + "Id": 9466290982672370664, + "Configuration": "Asset ID that does not exist (am_grass1.mtl UUID, no matching product ID)" + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/bundle_mode_tests.py b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/bundle_mode_tests.py index af92bb1773..b2252567b6 100644 --- a/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/bundle_mode_tests.py +++ b/AutomatedTesting/Gem/PythonTests/assetpipeline/asset_processor_tests/bundle_mode_tests.py @@ -23,12 +23,11 @@ from ..ap_fixtures.timeout_option_fixture import timeout_option_fixture as timeo @pytest.mark.SUITE_periodic @pytest.mark.parametrize('launcher_platform', ['windows_editor']) @pytest.mark.parametrize('project', ['AutomatedTesting']) -@pytest.mark.parametrize('level', ['auto_test']) +@pytest.mark.parametrize('level', ['TestDependenciesLevel']) class TestBundleMode(object): def test_bundle_mode_with_levels_mounts_bundles_correctly(self, request, editor, level, launcher_platform, asset_processor, workspace, bundler_batch_helper): - level_pak = os.path.join("levels", level, "level.pak") - + level_pak = os.path.join("levels", level, "TestDependenciesLevel.spawnable") bundles_folder = os.path.join(workspace.paths.project(), "Bundles") bundle_request_path = os.path.join(bundles_folder, "bundle.pak") bundle_result_path = os.path.join(bundles_folder, diff --git a/AutomatedTesting/Gem/PythonTests/assetpipeline/fbx_tests/assets/TwoSceneFiles_OneWithPythonOneWithout_PythonOnlyRunsOnFirstScene/python_builder.py b/AutomatedTesting/Gem/PythonTests/assetpipeline/fbx_tests/assets/TwoSceneFiles_OneWithPythonOneWithout_PythonOnlyRunsOnFirstScene/python_builder.py index 7ad5894a86..a9759e3d33 100644 --- a/AutomatedTesting/Gem/PythonTests/assetpipeline/fbx_tests/assets/TwoSceneFiles_OneWithPythonOneWithout_PythonOnlyRunsOnFirstScene/python_builder.py +++ b/AutomatedTesting/Gem/PythonTests/assetpipeline/fbx_tests/assets/TwoSceneFiles_OneWithPythonOneWithout_PythonOnlyRunsOnFirstScene/python_builder.py @@ -23,7 +23,7 @@ def output_test_data(scene): # Just write something to the file, but the filename is the main information # used for the test. f.write(f"scene.sourceFilename: {scene.sourceFilename}\n") - return True + return '' mySceneJobHandler = None diff --git a/AutomatedTesting/Gem/PythonTests/automatedtesting_shared/base.py b/AutomatedTesting/Gem/PythonTests/automatedtesting_shared/base.py index 0441f8a1dc..4db959b23e 100755 --- a/AutomatedTesting/Gem/PythonTests/automatedtesting_shared/base.py +++ b/AutomatedTesting/Gem/PythonTests/automatedtesting_shared/base.py @@ -182,7 +182,7 @@ class TestAutomationBase: @staticmethod def _kill_ly_processes(include_asset_processor=True): LY_PROCESSES = [ - 'Editor', 'Profiler', 'RemoteConsole', 'AutomatedTesting.ServerLauncher' + 'Editor', 'Profiler', 'RemoteConsole', 'AutomatedTesting.ServerLauncher', 'o3de' ] AP_PROCESSES = [ 'AssetProcessor', 'AssetProcessorBatch', 'AssetBuilder', 'CrySCompileServer', diff --git a/AutomatedTesting/Gem/PythonTests/editor/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/editor/CMakeLists.txt index 1fc71da972..b3f0d2da8e 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonTests/editor/CMakeLists.txt @@ -9,10 +9,10 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS AND PAL_TRAIT_FOUNDATION_TEST_SUPPORTED) ly_add_pytest( - NAME AutomatedTesting::EditorTests_Main_Optimized + NAME AutomatedTesting::EditorTests_Main TEST_SUITE main TEST_SERIAL - PATH ${CMAKE_CURRENT_LIST_DIR}/TestSuite_Main_Optimized.py + PATH ${CMAKE_CURRENT_LIST_DIR}/TestSuite_Main.py PYTEST_MARKS "not REQUIRES_gpu" RUNTIME_DEPENDENCIES Legacy::Editor @@ -27,7 +27,7 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS AND PAL_TRAIT_ TEST_SUITE main TEST_SERIAL TEST_REQUIRES gpu - PATH ${CMAKE_CURRENT_LIST_DIR}/TestSuite_Main_Optimized.py + PATH ${CMAKE_CURRENT_LIST_DIR}/TestSuite_Main.py PYTEST_MARKS "REQUIRES_gpu" RUNTIME_DEPENDENCIES Legacy::Editor @@ -37,17 +37,4 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS AND PAL_TRAIT_ Editor ) - ly_add_pytest( - NAME AutomatedTesting::EditorTests_Sandbox_Optimized - TEST_SUITE sandbox - TEST_SERIAL - PATH ${CMAKE_CURRENT_LIST_DIR}/TestSuite_Sandbox_Optimized.py - RUNTIME_DEPENDENCIES - Legacy::Editor - AZ::AssetProcessor - AutomatedTesting.Assets - COMPONENT - Editor - ) - endif() diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetBrowser_SearchFiltering.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetBrowser_SearchFiltering.py index 7366faafdc..4265dd6fc9 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetBrowser_SearchFiltering.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetBrowser_SearchFiltering.py @@ -59,8 +59,8 @@ def AssetBrowser_SearchFiltering(): import azlmbr.legacy.general as general + import editor_python_test_tools.hydra_editor_utils as hydra from editor_python_test_tools.utils import Report - from editor_python_test_tools.utils import TestHelper as helper def verify_files_appeared(model, allowed_asset_extensions, parent_index=QtCore.QModelIndex()): indexes = [parent_index] @@ -80,8 +80,7 @@ def AssetBrowser_SearchFiltering(): return True # 1) Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # 2) Open Asset Browser (if not opened already) editor_window = pyside_utils.get_editor_main_window() @@ -98,7 +97,13 @@ def AssetBrowser_SearchFiltering(): # 3) Type the name of an asset in the search bar and make sure it is filtered to and selectable asset_browser = editor_window.findChild(QtWidgets.QDockWidget, "Asset Browser") search_bar = asset_browser.findChild(QtWidgets.QLineEdit, "textSearch") - search_bar.setText("cedar.fbx") + + # Add a small pause when typing in the search bar in order to check that the entries are updated properly + search_bar.setText("Cedar.f") + general.idle_wait(0.5) + search_bar.setText("Cedar.fbx") + general.idle_wait(0.5) + asset_browser_tree = asset_browser.findChild(QtWidgets.QTreeView, "m_assetBrowserTreeViewWidget") asset_browser_table = asset_browser.findChild(QtWidgets.QTreeView, "m_assetBrowserTableViewWidget") found = await pyside_utils.wait_for_condition(lambda: pyside_utils.find_child_by_pattern(asset_browser_table, "cedar.fbx"), 5.0) diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetBrowser_TreeNavigation.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetBrowser_TreeNavigation.py index ecc77778cc..52072205b5 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetBrowser_TreeNavigation.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetBrowser_TreeNavigation.py @@ -53,6 +53,7 @@ def AssetBrowser_TreeNavigation(): import azlmbr.legacy.general as general import editor_python_test_tools.pyside_utils as pyside_utils + import editor_python_test_tools.hydra_editor_utils as hydra from editor_python_test_tools.utils import Report from editor_python_test_tools.utils import TestHelper as helper @@ -69,8 +70,7 @@ def AssetBrowser_TreeNavigation(): file_path = ("AutomatedTesting", "Assets", "ImageGradients", "image_grad_test_gsi.png") # 1) Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # 2) Open Asset Browser (if not opened already) editor_window = pyside_utils.get_editor_main_window() diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetPicker_UI_UX.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetPicker_UI_UX.py index 59a78c9e5d..047d6edf41 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetPicker_UI_UX.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/AssetPicker_UI_UX.py @@ -215,8 +215,7 @@ def AssetPicker_UI_UX(): QtTest.QTest.keyClick(tree, Qt.Key_Enter, Qt.NoModifier) # 1) Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # 2) Create entity and add Mesh component entity_position = math.Vector3(125.0, 136.0, 32.0) diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD.py index 39cacf9af5..48b7d2b176 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD.py @@ -56,19 +56,17 @@ def BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD(): 06. delete parent entity """ + import editor_python_test_tools.hydra_editor_utils as hydra from editor_python_test_tools.utils import Report from editor_python_test_tools.editor_entity_utils import EditorEntity import azlmbr.bus as bus import azlmbr.editor as editor import azlmbr.entity as entity - import azlmbr.legacy.general as general import azlmbr.object # 01. load an existing level - test_level = 'Simple' - general.open_level_no_prompt(test_level) - Report.result(Tests.load_level, general.get_current_level_name() == test_level) + hydra.open_base_level() # 02. create parent entity and set name # Delete any exiting entity and Create a new Entity at the root level diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/BasicEditorWorkflows_LevelEntityComponentCRUD.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/BasicEditorWorkflows_LevelEntityComponentCRUD.py index 9c5880ab1e..f13b924e30 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/BasicEditorWorkflows_LevelEntityComponentCRUD.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/BasicEditorWorkflows_LevelEntityComponentCRUD.py @@ -31,7 +31,7 @@ class Tests: "Component removed from entity successfully", "Failed to remove component from entity" ) - level_saved_and_exported = ( + saved_and_exported = ( "Level saved and exported successfully", "Failed to save/export level" ) @@ -52,8 +52,7 @@ def BasicEditorWorkflows_LevelEntityComponentCRUD(): - A new entity can be created - Entity hierarchy can be adjusted - Components can be added/removed/updated - - Level can be saved - - Level can be exported + - Level can be saved/exported Note: - This test file must be called from the O3DE Editor command terminal @@ -70,7 +69,7 @@ def BasicEditorWorkflows_LevelEntityComponentCRUD(): import azlmbr.editor as editor import azlmbr.entity as entity import azlmbr.math as math - import azlmbr.paths + import azlmbr.paths as paths import editor_python_test_tools.hydra_editor_utils as hydra from editor_python_test_tools.utils import Report @@ -84,7 +83,7 @@ def BasicEditorWorkflows_LevelEntityComponentCRUD(): return None # 1) Create a new level - level = "tmp_level" + lvl_name = "tmp_level" editor_window = pyside_utils.get_editor_main_window() new_level_action = pyside_utils.get_action_for_menu_path(editor_window, "File", "New Level") pyside_utils.trigger_action_async(new_level_action) @@ -95,23 +94,24 @@ def BasicEditorWorkflows_LevelEntityComponentCRUD(): Report.info("New Level dialog opened") grp_box = new_level_dlg.findChild(QtWidgets.QGroupBox, "STATIC_GROUP1") level_name = grp_box.findChild(QtWidgets.QLineEdit, "LEVEL") - level_name.setText(level) + level_name.setText(lvl_name) button_box = new_level_dlg.findChild(QtWidgets.QDialogButtonBox, "buttonBox") button_box.button(QtWidgets.QDialogButtonBox.Ok).click() # Verify new level was created successfully level_create_success = await pyside_utils.wait_for_condition(lambda: editor.EditorToolsApplicationRequestBus( - bus.Broadcast, "GetCurrentLevelName") == level, 5.0) + bus.Broadcast, "GetCurrentLevelName") == lvl_name, 5.0) Report.critical_result(Tests.level_created, level_create_success) # 2) Delete existing entities, and create and manipulate new entities via Entity Inspector search_filter = azlmbr.entity.SearchFilter() all_entities = entity.SearchBus(azlmbr.bus.Broadcast, "SearchEntities", search_filter) editor.ToolsApplicationRequestBus(bus.Broadcast, "DeleteEntities", all_entities) - entity_outliner_widget = editor_window.findChild(QtWidgets.QWidget, "OutlinerWidgetUI") + entity_outliner_widget = editor_window.findChild(QtWidgets.QWidget, "EntityOutlinerWidgetUI") outliner_object_list = entity_outliner_widget.findChild(QtWidgets.QWidget, "m_objectList_Contents") outliner_tree = outliner_object_list.findChild(QtWidgets.QWidget, "m_objectTree") - await pyside_utils.trigger_context_menu_entry(outliner_tree, "Create entity") + outliner_viewport = outliner_tree.findChild(QtWidgets.QWidget, "qt_scrollarea_viewport") + await pyside_utils.trigger_context_menu_entry(outliner_viewport, "Create entity") # Find the new entity parent_entity_id = find_entity_by_name("Entity1") @@ -153,14 +153,10 @@ def BasicEditorWorkflows_LevelEntityComponentCRUD(): save_level_action = pyside_utils.get_action_for_menu_path(editor_window, "File", "Save") pyside_utils.trigger_action_async(save_level_action) - # 5) Export the level - export_action = pyside_utils.get_action_for_menu_path(editor_window, "Game", "Export to Engine") - pyside_utils.trigger_action_async(export_action) - level_pak_file = os.path.join( - "AutomatedTesting", "Levels", level, "level.pak" - ) - export_success = await pyside_utils.wait_for_condition(lambda: os.path.exists(level_pak_file), 5.0) - Report.result(Tests.level_saved_and_exported, export_success) + # 5) Verify the save/export of the level + level_prefab_path = os.path.join(paths.products, "levels", lvl_name, f"{lvl_name}.spawnable") + success = await pyside_utils.wait_for_condition(lambda: os.path.exists(level_prefab_path), 5.0) + Report.result(Tests.saved_and_exported, success) run_test() diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/ComponentCRUD_Add_Delete_Components.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/ComponentCRUD_Add_Delete_Components.py index 779f1ef953..6772450405 100755 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/ComponentCRUD_Add_Delete_Components.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/ComponentCRUD_Add_Delete_Components.py @@ -63,7 +63,7 @@ def ComponentCRUD_Add_Delete_Components(): :return: None """ - from PySide2 import QtWidgets, QtTest, QtCore + from PySide2 import QtWidgets, QtTest from PySide2.QtCore import Qt import azlmbr.legacy.general as general @@ -74,7 +74,6 @@ def ComponentCRUD_Add_Delete_Components(): import editor_python_test_tools.hydra_editor_utils as hydra from editor_python_test_tools.utils import Report - from editor_python_test_tools.utils import TestHelper as helper async def add_component(component_name): pyside_utils.click_button_async(add_comp_btn) @@ -88,8 +87,7 @@ def ComponentCRUD_Add_Delete_Components(): QtTest.QTest.keyClick(tree, Qt.Key_Enter, Qt.NoModifier) # 1) Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # 2) Create entity entity_position = math.Vector3(125.0, 136.0, 32.0) diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Docking_BasicDockedTools.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Docking_BasicDockedTools.py index 6683fc952a..a5a94f06a5 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Docking_BasicDockedTools.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Docking_BasicDockedTools.py @@ -62,12 +62,11 @@ def Docking_BasicDockedTools(): import azlmbr.editor as editor import azlmbr.entity as entity + import editor_python_test_tools.hydra_editor_utils as hydra from editor_python_test_tools.utils import Report - from editor_python_test_tools.utils import TestHelper as helper # Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # Make sure the Entity Outliner, Entity Inspector and Console tools are open general.open_pane("Entity Outliner (PREVIEW)") @@ -80,7 +79,7 @@ def Docking_BasicDockedTools(): editor.EditorEntityAPIBus(bus.Event, 'SetName', entity_id, entity_original_name) editor_window = pyside_utils.get_editor_main_window() - entity_outliner = editor_window.findChild(QtWidgets.QDockWidget, "Entity Outliner (PREVIEW)") + entity_outliner = editor_window.findChild(QtWidgets.QDockWidget, "Entity Outliner") # 1) Open the tools and dock them together in a floating tabbed widget. # We drag/drop it over the viewport since it doesn't allow docking, so this will undock it @@ -88,15 +87,15 @@ def Docking_BasicDockedTools(): pyside_utils.drag_and_drop(entity_outliner, render_overlay) # We need to grab a new reference to the Entity Outliner QDockWidget because when it gets moved - # to the floating window, its parent changes so the wrapped intance we had becomes invalid - entity_outliner = editor_window.findChild(QtWidgets.QDockWidget, "Entity Outliner (PREVIEW)") + # to the floating window, its parent changes so the wrapped instance we had becomes invalid + entity_outliner = editor_window.findChild(QtWidgets.QDockWidget, "Entity Outliner") # Dock the Entity Inspector tabbed with the floating Entity Outliner entity_inspector = editor_window.findChild(QtWidgets.QDockWidget, "Entity Inspector") pyside_utils.drag_and_drop(entity_inspector, entity_outliner) # We need to grab a new reference to the Entity Inspector QDockWidget because when it gets moved - # to the floating window, its parent changes so the wrapped intance we had becomes invalid + # to the floating window, its parent changes so the wrapped instance we had becomes invalid entity_inspector = editor_window.findChild(QtWidgets.QDockWidget, "Entity Inspector") # Dock the Console tabbed with the floating Entity Inspector @@ -106,7 +105,7 @@ def Docking_BasicDockedTools(): # Check to ensure all the tools are parented to the same QStackedWidget def check_all_panes_tabbed(): entity_inspector = editor_window.findChild(QtWidgets.QDockWidget, "Entity Inspector") - entity_outliner = editor_window.findChild(QtWidgets.QDockWidget, "Entity Outliner (PREVIEW)") + entity_outliner = editor_window.findChild(QtWidgets.QDockWidget, "Entity Outliner") console = editor_window.findChild(QtWidgets.QDockWidget, "Console") entity_inspector_parent = entity_inspector.parentWidget() entity_outliner_parent = entity_outliner.parentWidget() @@ -122,7 +121,7 @@ def Docking_BasicDockedTools(): # 2.1,2) Select an Entity in the Entity Outliner. entity_inspector = editor_window.findChild(QtWidgets.QDockWidget, "Entity Inspector") - entity_outliner = editor_window.findChild(QtWidgets.QDockWidget, "Entity Outliner (PREVIEW)") + entity_outliner = editor_window.findChild(QtWidgets.QDockWidget, "Entity Outliner") console = editor_window.findChild(QtWidgets.QDockWidget, "Console") object_tree = entity_outliner.findChild(QtWidgets.QTreeView, "m_objectTree") test_entity_index = pyside_utils.find_child_by_pattern(object_tree, entity_original_name) diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/EntityOutliner_EntityOrdering.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/EntityOutliner_EntityOrdering.py index 5fa8130302..fab7984df9 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/EntityOutliner_EntityOrdering.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/EntityOutliner_EntityOrdering.py @@ -30,11 +30,13 @@ def EntityOutliner_EntityOrdering(): 5) Add another new entity, ensure the rest of the order is unchanged """ - import editor_python_test_tools.pyside_utils as pyside_utils + from PySide2 import QtCore + import azlmbr.legacy.general as general + + import editor_python_test_tools.hydra_editor_utils as hydra + import editor_python_test_tools.pyside_utils as pyside_utils from editor_python_test_tools.utils import Report - from editor_python_test_tools.utils import TestHelper as helper - from PySide2 import QtCore, QtWidgets, QtGui, QtTest # Grab the Editor, Entity Outliner, and Outliner Model editor_window = pyside_utils.get_editor_main_window() @@ -110,8 +112,7 @@ def EntityOutliner_EntityOrdering(): expected_order = [] # 1) Open the empty Prefab Base level - helper.init_idle() - helper.open_level("Prefab", "Base") + hydra.open_base_level() # 2) Add 5 entities to the outliner ENTITIES_TO_ADD = 5 diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/InputBindings_Add_Remove_Input_Events.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/InputBindings_Add_Remove_Input_Events.py index f4769dab4d..07c89ff110 100755 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/InputBindings_Add_Remove_Input_Events.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/InputBindings_Add_Remove_Input_Events.py @@ -69,8 +69,8 @@ def InputBindings_Add_Remove_Input_Events(): import azlmbr.legacy.general as general + import editor_python_test_tools.hydra_editor_utils as hydra from editor_python_test_tools.utils import Report - from editor_python_test_tools.utils import TestHelper as helper def open_asset_editor(): general.open_pane("Asset Editor") @@ -81,8 +81,7 @@ def InputBindings_Add_Remove_Input_Events(): return not general.is_pane_visible("Asset Editor") # 1) Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # 2) Open Asset Editor Report.result(Tests.asset_editor_opened, open_asset_editor()) diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_EditMenuOptions.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_EditMenuOptions.py index bd213be293..ce85cf223f 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_EditMenuOptions.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_EditMenuOptions.py @@ -26,9 +26,9 @@ def Menus_EditMenuOptions_Work(): :return: None """ + import editor_python_test_tools.hydra_editor_utils as hydra import editor_python_test_tools.pyside_utils as pyside_utils from editor_python_test_tools.utils import Report - from editor_python_test_tools.utils import TestHelper as helper edit_menu_options = [ ("Undo",), @@ -52,19 +52,20 @@ def Menus_EditMenuOptions_Work(): ("Editor Settings", "Global Preferences"), ("Editor Settings", "Editor Settings Manager"), ("Editor Settings", "Keyboard Customization", "Customize Keyboard"), - ("Editor Settings", "Keyboard Customization", "Export Keyboard Settings"), - ("Editor Settings", "Keyboard Customization", "Import Keyboard Settings"), + # The following menu options are temporarily disabled due to https://github.com/o3de/o3de/issues/6746 + #("Editor Settings", "Keyboard Customization", "Export Keyboard Settings"), + #("Editor Settings", "Keyboard Customization", "Import Keyboard Settings"), ] # 1) Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # 2) Interact with Edit Menu options editor_window = pyside_utils.get_editor_main_window() for option in edit_menu_options: try: action = pyside_utils.get_action_for_menu_path(editor_window, "Edit", *option) + Report.info(f"Triggering {action.iconText()}") action.trigger() action_triggered = True except Exception as e: diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_FileMenuOptions.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_FileMenuOptions.py index a3e7611b5e..4fcdc371e7 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_FileMenuOptions.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_FileMenuOptions.py @@ -26,35 +26,34 @@ def Menus_FileMenuOptions_Work(): :return: None """ + import editor_python_test_tools.hydra_editor_utils as hydra import editor_python_test_tools.pyside_utils as pyside_utils from editor_python_test_tools.utils import Report - from editor_python_test_tools.utils import TestHelper as helper file_menu_options = [ ("New Level",), - ("Open Level",), - ("Import",), + #("Open Level",), Temporarily disabled due to https://github.com/o3de/o3de/issues/6605 + #("Import",), Temporarily disabled due to https://github.com/o3de/o3de/issues/6746 ("Save",), - ("Save As",), + #("Save As",), Temporarily disabled due to https://github.com/o3de/o3de/issues/6605 ("Save Level Statistics",), ("Edit Project Settings",), - ("Edit Platform Settings",), + #("Edit Platform Settings",), Temporarily disabled due to https://github.com/o3de/o3de/issues/6604 ("New Project",), ("Open Project",), ("Show Log File",), - ("Resave All Slices",), ("Exit",), ] # 1) Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # 2) Interact with File Menu options editor_window = pyside_utils.get_editor_main_window() for option in file_menu_options: try: action = pyside_utils.get_action_for_menu_path(editor_window, "File", *option) + Report.info(f"Triggering {action.iconText()}") action.trigger() action_triggered = True except Exception as e: diff --git a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_ViewMenuOptions.py b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_ViewMenuOptions.py index deff2855a0..bb9ff15082 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_ViewMenuOptions.py +++ b/AutomatedTesting/Gem/PythonTests/editor/EditorScripts/Menus_ViewMenuOptions.py @@ -26,13 +26,15 @@ def Menus_ViewMenuOptions_Work(): :return: None """ + import editor_python_test_tools.hydra_editor_utils as hydra import editor_python_test_tools.pyside_utils as pyside_utils from editor_python_test_tools.utils import Report - from editor_python_test_tools.utils import TestHelper as helper view_menu_options = [ ("Center on Selection",), ("Show Quick Access Bar",), + ("Layouts", "Component Entity Layout",), + ("Layouts", "Save Layout",), ("Viewport", "Configure Layout"), ("Viewport", "Go to Position"), ("Viewport", "Center on Selection"), @@ -45,14 +47,14 @@ def Menus_ViewMenuOptions_Work(): ] # 1) Open an existing simple level - helper.init_idle() - helper.open_level("Physics", "Base") + hydra.open_base_level() # 2) Interact with View Menu options editor_window = pyside_utils.get_editor_main_window() for option in view_menu_options: try: action = pyside_utils.get_action_for_menu_path(editor_window, "View", *option) + Report.info(f"Triggering {action.iconText()}") action.trigger() action_triggered = True except Exception as e: diff --git a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Main.py b/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Main.py index c9e91687e0..3805ef15dd 100644 --- a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Main.py +++ b/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Main.py @@ -7,48 +7,77 @@ SPDX-License-Identifier: Apache-2.0 OR MIT import os import pytest -import sys import ly_test_tools.environment.file_system as file_system +from ly_test_tools.o3de.editor_test import EditorSingleTest, EditorSharedTest, EditorParallelTest, EditorTestSuite -sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../automatedtesting_shared') -from base import TestAutomationBase +@pytest.mark.SUITE_main +@pytest.mark.parametrize("launcher_platform", ['windows_editor']) +@pytest.mark.parametrize("project", ["AutomatedTesting"]) +class TestAutomationNoAutoTestMode(EditorTestSuite): + + # Disable -autotest_mode and -BatchMode. Tests cannot run in -BatchMode due to UI interactions, and these tests + # interact with modal dialogs + global_extra_cmdline_args = [] + + class test_AssetPicker_UI_UX(EditorSharedTest): + from .EditorScripts import AssetPicker_UI_UX as test_module -@pytest.fixture -def remove_test_level(request, workspace, project): - file_system.delete([os.path.join(workspace.paths.engine_root(), project, "Levels", "tmp_level")], True, True) + class test_BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD(EditorSharedTest): + from .EditorScripts import BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD as test_module - def teardown(): - file_system.delete([os.path.join(workspace.paths.engine_root(), project, "Levels", "tmp_level")], True, True) + class test_BasicEditorWorkflows_LevelEntityComponentCRUD(EditorSingleTest): + # Custom teardown to remove level created during test + def teardown(self, request, workspace, editor, editor_test_results, launcher_platform): + file_system.delete([os.path.join(workspace.paths.engine_root(), "AutomatedTesting", "Levels", "tmp_level")], + True, True) + from .EditorScripts import BasicEditorWorkflows_LevelEntityComponentCRUD as test_module + + @pytest.mark.REQUIRES_gpu + class test_BasicEditorWorkflows_GPU_LevelEntityComponentCRUD(EditorSingleTest): + # Disable null renderer + use_null_renderer = False + + # Custom teardown to remove level created during test + def teardown(self, request, workspace, editor, editor_test_results, launcher_platform): + file_system.delete([os.path.join(workspace.paths.engine_root(), "AutomatedTesting", "Levels", "tmp_level")], + True, True) + from .EditorScripts import BasicEditorWorkflows_LevelEntityComponentCRUD as test_module - request.addfinalizer(teardown) + class test_InputBindings_Add_Remove_Input_Events(EditorSharedTest): + from .EditorScripts import InputBindings_Add_Remove_Input_Events as test_module @pytest.mark.SUITE_main @pytest.mark.parametrize("launcher_platform", ['windows_editor']) @pytest.mark.parametrize("project", ["AutomatedTesting"]) -class TestAutomation(TestAutomationBase): +class TestAutomationAutoTestMode(EditorTestSuite): - def test_BasicEditorWorkflows_LevelEntityComponentCRUD(self, request, workspace, editor, launcher_platform, - remove_test_level): - from .EditorScripts import BasicEditorWorkflows_LevelEntityComponentCRUD as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, autotest_mode=False, enable_prefab_system=False) + # Enable only -autotest_mode for these tests. Tests cannot run in -BatchMode due to UI interactions + global_extra_cmdline_args = ["-autotest_mode"] - @pytest.mark.REQUIRES_gpu - def test_BasicEditorWorkflows_GPU_LevelEntityComponentCRUD(self, request, workspace, editor, launcher_platform, - remove_test_level): - from .EditorScripts import BasicEditorWorkflows_LevelEntityComponentCRUD as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, autotest_mode=False, - use_null_renderer=False, enable_prefab_system=False) + class test_AssetBrowser_SearchFiltering(EditorSharedTest): + from .EditorScripts import AssetBrowser_SearchFiltering as test_module + + class test_AssetBrowser_TreeNavigation(EditorSharedTest): + from .EditorScripts import AssetBrowser_TreeNavigation as test_module + + class test_ComponentCRUD_Add_Delete_Components(EditorSharedTest): + from .EditorScripts import ComponentCRUD_Add_Delete_Components as test_module - def test_EntityOutlienr_EntityOrdering(self, request, workspace, editor, launcher_platform): + @pytest.mark.skip("Passes locally/fails on Jenkins. https://github.com/o3de/o3de/issues/6747") + class test_Docking_BasicDockedTools(EditorSharedTest): + from .EditorScripts import Docking_BasicDockedTools as test_module + + class test_EntityOutliner_EntityOrdering(EditorSharedTest): from .EditorScripts import EntityOutliner_EntityOrdering as test_module - self._run_test( - request, - workspace, - editor, - test_module, - batch_mode=False, - autotest_mode=True, - ) + + class test_Menus_EditMenuOptions_Work(EditorSharedTest): + from .EditorScripts import Menus_EditMenuOptions as test_module + + class test_Menus_FileMenuOptions_Work(EditorSharedTest): + from .EditorScripts import Menus_FileMenuOptions as test_module + + class test_Menus_ViewMenuOptions_Work(EditorSharedTest): + from .EditorScripts import Menus_ViewMenuOptions as test_module diff --git a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Main_Optimized.py b/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Main_Optimized.py deleted file mode 100644 index d87fd8625b..0000000000 --- a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Main_Optimized.py +++ /dev/null @@ -1,79 +0,0 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" - -import os -import pytest - -import ly_test_tools.environment.file_system as file_system -from ly_test_tools.o3de.editor_test import EditorSingleTest, EditorSharedTest, EditorParallelTest, EditorTestSuite - - -@pytest.mark.xfail(reason="Optimized tests are experimental, we will enable xfail and monitor them temporarily.") -@pytest.mark.SUITE_main -@pytest.mark.parametrize("launcher_platform", ['windows_editor']) -@pytest.mark.parametrize("project", ["AutomatedTesting"]) -class TestAutomationNoAutoTestMode(EditorTestSuite): - - # Disable -autotest_mode and -BatchMode. Tests cannot run in -BatchMode due to UI interactions, and these tests - # interact with modal dialogs - global_extra_cmdline_args = [] - - enable_prefab_system = False - - class test_BasicEditorWorkflows_LevelEntityComponentCRUD(EditorSingleTest): - # Custom teardown to remove slice asset created during test - def teardown(self, request, workspace, editor, editor_test_results, launcher_platform): - file_system.delete([os.path.join(workspace.paths.engine_root(), "AutomatedTesting", "Levels", "tmp_level")], - True, True) - from .EditorScripts import BasicEditorWorkflows_LevelEntityComponentCRUD as test_module - - @pytest.mark.REQUIRES_gpu - class test_BasicEditorWorkflows_GPU_LevelEntityComponentCRUD(EditorSingleTest): - # Disable null renderer - use_null_renderer = False - - # Custom teardown to remove slice asset created during test - def teardown(self, request, workspace, editor, editor_test_results, launcher_platform): - file_system.delete([os.path.join(workspace.paths.engine_root(), "AutomatedTesting", "Levels", "tmp_level")], - True, True) - from .EditorScripts import BasicEditorWorkflows_LevelEntityComponentCRUD as test_module - - class test_InputBindings_Add_Remove_Input_Events(EditorSharedTest): - from .EditorScripts import InputBindings_Add_Remove_Input_Events as test_module - - class test_AssetPicker_UI_UX(EditorSharedTest): - from .EditorScripts import AssetPicker_UI_UX as test_module - - -@pytest.mark.SUITE_main -@pytest.mark.parametrize("launcher_platform", ['windows_editor']) -@pytest.mark.parametrize("project", ["AutomatedTesting"]) -class TestAutomationAutoTestMode(EditorTestSuite): - - # Enable only -autotest_mode for these tests. Tests cannot run in -BatchMode due to UI interactions - global_extra_cmdline_args = ["-autotest_mode"] - - enable_prefab_system = False - - class test_AssetBrowser_TreeNavigation(EditorSharedTest): - from .EditorScripts import AssetBrowser_TreeNavigation as test_module - - class test_AssetBrowser_SearchFiltering(EditorSharedTest): - from .EditorScripts import AssetBrowser_SearchFiltering as test_module - - class test_ComponentCRUD_Add_Delete_Components(EditorSharedTest): - from .EditorScripts import ComponentCRUD_Add_Delete_Components as test_module - - class test_Menus_ViewMenuOptions_Work(EditorSharedTest): - from .EditorScripts import Menus_ViewMenuOptions as test_module - - @pytest.mark.skip(reason="Times out due to dialogs failing to dismiss: LYN-4208") - class test_Menus_FileMenuOptions_Work(EditorSharedTest): - from .EditorScripts import Menus_FileMenuOptions as test_module - - class test_BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD(EditorSharedTest): - from .EditorScripts import BasicEditorWorkflows_ExistingLevel_EntityComponentCRUD as test_module diff --git a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Periodic.py b/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Periodic.py deleted file mode 100644 index 1bd1d7f987..0000000000 --- a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Periodic.py +++ /dev/null @@ -1,60 +0,0 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" - -import os -import pytest -import sys - -import ly_test_tools.environment.file_system as file_system - -sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../automatedtesting_shared') -from base import TestAutomationBase - - -@pytest.fixture -def remove_test_level(request, workspace, project): - file_system.delete([os.path.join(workspace.paths.engine_root(), project, "Levels", "tmp_level")], True, True) - - def teardown(): - file_system.delete([os.path.join(workspace.paths.engine_root(), project, "Levels", "tmp_level")], True, True) - - request.addfinalizer(teardown) - - -@pytest.mark.SUITE_periodic -@pytest.mark.parametrize("launcher_platform", ['windows_editor']) -@pytest.mark.parametrize("project", ["AutomatedTesting"]) -class TestAutomation(TestAutomationBase): - - def test_AssetBrowser_TreeNavigation(self, request, workspace, editor, launcher_platform): - from .EditorScripts import AssetBrowser_TreeNavigation as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, enable_prefab_system=False) - - def test_AssetBrowser_SearchFiltering(self, request, workspace, editor, launcher_platform): - from .EditorScripts import AssetBrowser_SearchFiltering as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, enable_prefab_system=False) - - def test_AssetPicker_UI_UX(self, request, workspace, editor, launcher_platform): - from .EditorScripts import AssetPicker_UI_UX as test_module - self._run_test(request, workspace, editor, test_module, autotest_mode=False, batch_mode=False, enable_prefab_system=False) - - def test_ComponentCRUD_Add_Delete_Components(self, request, workspace, editor, launcher_platform): - from .EditorScripts import ComponentCRUD_Add_Delete_Components as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, enable_prefab_system=False) - - def test_InputBindings_Add_Remove_Input_Events(self, request, workspace, editor, launcher_platform): - from .EditorScripts import InputBindings_Add_Remove_Input_Events as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, autotest_mode=False, enable_prefab_system=False) - - def test_Menus_ViewMenuOptions_Work(self, request, workspace, editor, launcher_platform): - from .EditorScripts import Menus_ViewMenuOptions as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, enable_prefab_system=False) - - @pytest.mark.skip(reason="Times out due to dialogs failing to dismiss: LYN-4208") - def test_Menus_FileMenuOptions_Work(self, request, workspace, editor, launcher_platform): - from .EditorScripts import Menus_FileMenuOptions as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, enable_prefab_system=False) diff --git a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Sandbox.py b/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Sandbox.py deleted file mode 100644 index 8a56a2dbfd..0000000000 --- a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Sandbox.py +++ /dev/null @@ -1,27 +0,0 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" - -import os -import pytest -import sys - -sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../automatedtesting_shared') -from base import TestAutomationBase - - -@pytest.mark.SUITE_sandbox -@pytest.mark.parametrize("launcher_platform", ['windows_editor']) -@pytest.mark.parametrize("project", ["AutomatedTesting"]) -class TestAutomation(TestAutomationBase): - - def test_Menus_EditMenuOptions_Work(self, request, workspace, editor, launcher_platform): - from .EditorScripts import Menus_EditMenuOptions as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, enable_prefab_system=False) - - def test_Docking_BasicDockedTools(self, request, workspace, editor, launcher_platform): - from .EditorScripts import Docking_BasicDockedTools as test_module - self._run_test(request, workspace, editor, test_module, batch_mode=False, enable_prefab_system=False) diff --git a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Sandbox_Optimized.py b/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Sandbox_Optimized.py deleted file mode 100644 index ce0d5e43e9..0000000000 --- a/AutomatedTesting/Gem/PythonTests/editor/TestSuite_Sandbox_Optimized.py +++ /dev/null @@ -1,28 +0,0 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT -""" - -import os -import pytest - -from ly_test_tools.o3de.editor_test import EditorSingleTest, EditorSharedTest, EditorParallelTest, EditorTestSuite - - -@pytest.mark.SUITE_sandbox -@pytest.mark.parametrize("launcher_platform", ['windows_editor']) -@pytest.mark.parametrize("project", ["AutomatedTesting"]) -class TestAutomationAutoTestMode(EditorTestSuite): - - # Enable only -autotest_mode for these tests. Tests cannot run in -BatchMode due to UI interactions - global_extra_cmdline_args = ["-autotest_mode"] - - enable_prefab_system = False - - class test_Docking_BasicDockedTools(EditorSharedTest): - from .EditorScripts import Docking_BasicDockedTools as test_module - - class test_Menus_EditMenuOptions_Work(EditorSharedTest): - from .EditorScripts import Menus_EditMenuOptions as test_module diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_Embedded_E2E.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_Embedded_E2E.py index 86035bfbae..b4650c782e 100755 --- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_Embedded_E2E.py +++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_Embedded_E2E.py @@ -110,7 +110,8 @@ def DynamicSliceInstanceSpawner_Embedded_E2E(): general.save_level() general.export_to_engine() pak_path = os.path.join(paths.products, "levels", lvl_name, "level.pak") - Report.result(Tests.saved_and_exported, os.path.exists(pak_path)) + success = helper.wait_for_condition(lambda: os.path.exists(pak_path), 10.0) + Report.result(Tests.saved_and_exported, success) if __name__ == "__main__": diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_External_E2E.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_External_E2E.py index 2353095849..a5e7e90ce2 100755 --- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_External_E2E.py +++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_External_E2E.py @@ -132,7 +132,8 @@ def DynamicSliceInstanceSpawner_External_E2E(): general.save_level() general.export_to_engine() pak_path = os.path.join(paths.products, "levels", lvl_name, "level.pak") - Report.result(Tests.saved_and_exported, os.path.exists(pak_path)) + success = helper.wait_for_condition(lambda: os.path.exists(pak_path), 10.0) + Report.result(Tests.saved_and_exported, success) if __name__ == "__main__": diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/LayerBlender_E2E_Editor.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/LayerBlender_E2E_Editor.py index f2c7faae8a..6b5a80ee8e 100755 --- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/LayerBlender_E2E_Editor.py +++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/LayerBlender_E2E_Editor.py @@ -156,7 +156,8 @@ def LayerBlender_E2E_Editor(): general.save_level() general.export_to_engine() pak_path = os.path.join(paths.products, "levels", lvl_name, "level.pak") - Report.result(Tests.saved_and_exported, os.path.exists(pak_path)) + success = helper.wait_for_condition(lambda: os.path.exists(pak_path), 10.0) + Report.result(Tests.saved_and_exported, success) if __name__ == "__main__": diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/SpawnerSlices_SliceCreationAndVisibilityToggleWorks.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/SpawnerSlices_SliceCreationAndVisibilityToggleWorks.py index c36d1b5bc9..fc55080cec 100644 --- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/SpawnerSlices_SliceCreationAndVisibilityToggleWorks.py +++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/SpawnerSlices_SliceCreationAndVisibilityToggleWorks.py @@ -73,7 +73,7 @@ def SpawnerSlices_SliceCreationAndVisibilityToggleWorks(): slice.SliceRequestBus(bus.Broadcast, "CreateNewSlice", veg_1.id, slice_path) # 2.3) Verify if the slice has been created successfully - spawner_slice_success = helper.wait_for_condition(lambda: path_is_valid_asset(slice_path), 5.0) + spawner_slice_success = helper.wait_for_condition(lambda: path_is_valid_asset(slice_path), 10.0) Report.result(Tests.spawner_slice_created, spawner_slice_success) # 3) C2627904: Hiding a slice containing the component clears any visuals from the Viewport diff --git a/AutomatedTesting/Gem/PythonTests/smoke/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/smoke/CMakeLists.txt index 3fc4f3db0e..69d411536f 100644 --- a/AutomatedTesting/Gem/PythonTests/smoke/CMakeLists.txt +++ b/AutomatedTesting/Gem/PythonTests/smoke/CMakeLists.txt @@ -31,35 +31,6 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS) Smoke ) - ly_add_pytest( - NAME AutomatedTesting::LoadLevelGPU - TEST_SUITE smoke - TEST_SERIAL - TEST_REQUIRES gpu - PATH ${CMAKE_CURRENT_LIST_DIR}/test_RemoteConsole_GPULoadLevel_Works.py - TIMEOUT 100 - RUNTIME_DEPENDENCIES - AZ::AssetProcessor - AZ::PythonBindingsExample - AutomatedTesting.GameLauncher - AutomatedTesting.Assets - COMPONENT - Smoke - ) - - ly_add_pytest( - NAME AutomatedTesting::EditorTestWithGPU - TEST_REQUIRES gpu - PATH ${CMAKE_CURRENT_LIST_DIR}/test_Editor_NewExistingLevels_Works.py - TIMEOUT 100 - RUNTIME_DEPENDENCIES - AZ::AssetProcessor - AZ::PythonBindingsExample - Legacy::Editor - AutomatedTesting.GameLauncher - AutomatedTesting.Assets - ) - ly_add_pytest( NAME AutomatedTesting::GameLauncherWithGPU TEST_SUITE sandbox diff --git a/AutomatedTesting/Gem/PythonTests/smoke/Editor_NewExistingLevels_Works.py b/AutomatedTesting/Gem/PythonTests/smoke/Editor_NewExistingLevels_Works.py deleted file mode 100644 index 71956488fc..0000000000 --- a/AutomatedTesting/Gem/PythonTests/smoke/Editor_NewExistingLevels_Works.py +++ /dev/null @@ -1,143 +0,0 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT - - -Test Case Title: Create Test for UI apps- Editor -""" - - -class Tests(): - level_created = ("Level created", "Failed to create level") - entity_found = ("New Entity created in level", "Failed to create New Entity in level") - mesh_added = ("Mesh Component added", "Failed to add Mesh Component") - enter_game_mode = ("Game Mode successfully entered", "Failed to enter in Game Mode") - exit_game_mode = ("Game Mode successfully exited", "Failed to exit in Game Mode") - level_opened = ("Level opened successfully", "Failed to open level") - level_exported = ("Level exported successfully", "Failed to export level") - mesh_removed = ("Mesh Component removed", "Failed to remove Mesh Component") - entity_deleted = ("Entity deleted", "Failed to delete Entity") - level_edits_present = ("Level edits persist after saving", "Failed to save level edits after saving") - - -def Editor_NewExistingLevels_Works(): - """ - Summary: Perform the below operations on Editor - - 1) Launch & Close editor - 2) Create new level - 3) Saving and loading levels - 4) Level edits persist after saving - 5) Export Level - 6) Can switch to play mode (ctrl+g) and exit that - 7) Run editor python bindings test - 8) Create an Entity - 9) Delete an Entity - 10) Add a component to an Entity - - Expected Behavior: - All operations succeed and do not cause a crash - - Test Steps: - 1) Launch editor and Create a new level - 2) Create a new entity - 3) Add Mesh component - 4) Verify enter/exit game mode - 5) Save, Load and Export level - 6) Remove Mesh component - 7) Delete entity - 8) Open an existing level - 9) Create a new entity in an existing level - 10) Save, Load and Export an existing level and close editor - - Note: - - This test file must be called from the O3DE Editor command terminal - - Any passed and failed tests are written to the Editor.log file. - Parsing the file or running a log_monitor are required to observe the test results. - - :return: None - """ - - import os - import editor_python_test_tools.hydra_editor_utils as hydra - from editor_python_test_tools.utils import TestHelper as helper - from editor_python_test_tools.utils import Report - import azlmbr.bus as bus - import azlmbr.editor as editor - import azlmbr.legacy.general as general - import azlmbr.math as math - - # 1) Launch editor and Create a new level - helper.init_idle() - test_level_name = "temp_level" - general.create_level_no_prompt(test_level_name, 128, 1, 128, False) - helper.wait_for_condition(lambda: general.get_current_level_name() == test_level_name, 2.0) - Report.result(Tests.level_created, general.get_current_level_name() == test_level_name) - - # 2) Create a new entity - entity_position = math.Vector3(200.0, 200.0, 38.0) - new_entity = hydra.Entity("Entity1") - new_entity.create_entity(entity_position, []) - test_entity = hydra.find_entity_by_name("Entity1") - Report.result(Tests.entity_found, test_entity.IsValid()) - - # 3) Add Mesh component - new_entity.add_component("Mesh") - Report.result(Tests.mesh_added, hydra.has_components(new_entity.id, ["Mesh"])) - - # 4) Verify enter/exit game mode - helper.enter_game_mode(Tests.enter_game_mode) - helper.exit_game_mode(Tests.exit_game_mode) - - # 5) Save, Load and Export level - # Save Level - general.save_level() - # Open Level - general.open_level(test_level_name) - Report.result(Tests.level_opened, general.get_current_level_name() == test_level_name) - # Export Level - general.export_to_engine() - level_pak_file = os.path.join("AutomatedTesting", "Levels", test_level_name, "level.pak") - Report.result(Tests.level_exported, os.path.exists(level_pak_file)) - - # 6) Remove Mesh component - new_entity.remove_component("Mesh") - Report.result(Tests.mesh_removed, not hydra.has_components(new_entity.id, ["Mesh"])) - - # 7) Delete entity - editor.ToolsApplicationRequestBus(bus.Broadcast, "DeleteEntityById", new_entity.id) - test_entity = hydra.find_entity_by_name("Entity1") - Report.result(Tests.entity_deleted, len(test_entity) == 0) - - # 8) Open an existing level - general.open_level(test_level_name) - Report.result(Tests.level_opened, general.get_current_level_name() == test_level_name) - - # 9) Create a new entity in an existing level - entity_position = math.Vector3(200.0, 200.0, 38.0) - new_entity_2 = hydra.Entity("Entity2") - new_entity_2.create_entity(entity_position, []) - test_entity = hydra.find_entity_by_name("Entity2") - Report.result(Tests.entity_found, test_entity.IsValid()) - - # 10) Save, Load and Export an existing level - # Save Level - general.save_level() - # Open Level - general.open_level(test_level_name) - Report.result(Tests.level_opened, general.get_current_level_name() == test_level_name) - entity_id = hydra.find_entity_by_name(new_entity_2.name) - Report.result(Tests.level_edits_present, entity_id == new_entity_2.id) - # Export Level - general.export_to_engine() - level_pak_file = os.path.join("AutomatedTesting", "Levels", test_level_name, "level.pak") - Report.result(Tests.level_exported, os.path.exists(level_pak_file)) - - -if __name__ == "__main__": - - from editor_python_test_tools.utils import Report - - Report.start_test(Editor_NewExistingLevels_Works) diff --git a/AutomatedTesting/Gem/PythonTests/smoke/test_Editor_NewExistingLevels_Works.py b/AutomatedTesting/Gem/PythonTests/smoke/test_Editor_NewExistingLevels_Works.py deleted file mode 100644 index 5caf7744c4..0000000000 --- a/AutomatedTesting/Gem/PythonTests/smoke/test_Editor_NewExistingLevels_Works.py +++ /dev/null @@ -1,34 +0,0 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT - - -Test should run in both gpu and non gpu -""" - -import pytest -import os -from automatedtesting_shared.base import TestAutomationBase - -import ly_test_tools -import ly_test_tools.environment.file_system as file_system - - -@pytest.mark.SUITE_smoke -@pytest.mark.skipif(not ly_test_tools.WINDOWS, reason="Only succeeds on windows https://github.com/o3de/o3de/issues/5539") -@pytest.mark.parametrize("launcher_platform", ["windows_editor"]) -@pytest.mark.parametrize("project", ["AutomatedTesting"]) -@pytest.mark.parametrize("level", ["temp_level"]) -class TestAutomation(TestAutomationBase): - def test_Editor_NewExistingLevels_Works(self, request, workspace, editor, level, project, launcher_platform): - def teardown(): - file_system.delete([os.path.join(workspace.paths.engine_root(), project, "Levels", level)], True, True) - - request.addfinalizer(teardown) - file_system.delete([os.path.join(workspace.paths.engine_root(), project, "Levels", level)], True, True) - - from . import Editor_NewExistingLevels_Works as test_module - - self._run_test(request, workspace, editor, test_module, enable_prefab_system=False) diff --git a/AutomatedTesting/Gem/PythonTests/smoke/test_RemoteConsole_GPULoadLevel_Works.py b/AutomatedTesting/Gem/PythonTests/smoke/test_RemoteConsole_GPULoadLevel_Works.py deleted file mode 100644 index 7debcab938..0000000000 --- a/AutomatedTesting/Gem/PythonTests/smoke/test_RemoteConsole_GPULoadLevel_Works.py +++ /dev/null @@ -1,43 +0,0 @@ -""" -Copyright (c) Contributors to the Open 3D Engine Project. -For complete copyright and license terms please see the LICENSE at the root of this distribution. - -SPDX-License-Identifier: Apache-2.0 OR MIT - - -UI Apps: AutomatedTesting.GameLauncher -Launch AutomatedTesting.GameLauncher with Simple level -Test should run in both gpu and non gpu -""" - -import pytest -import psutil - -import ly_test_tools.environment.waiter as waiter -import editor_python_test_tools.hydra_test_utils as editor_test_utils -from ly_remote_console.remote_console_commands import RemoteConsole as RemoteConsole -from ly_remote_console.remote_console_commands import ( - send_command_and_expect_response as send_command_and_expect_response, -) - - -@pytest.mark.parametrize("launcher_platform", ["windows"]) -@pytest.mark.parametrize("project", ["AutomatedTesting"]) -@pytest.mark.parametrize("level", ["Simple"]) -class TestRemoteConsoleLoadLevelWorks(object): - @pytest.fixture - def remote_console_instance(self, request): - console = RemoteConsole() - - def teardown(): - if console.connected: - console.stop() - - request.addfinalizer(teardown) - - return console - - def test_RemoteConsole_LoadLevel_Works(self, launcher, level, remote_console_instance, launcher_platform): - expected_lines = ['Level system is loading "Simple"'] - - editor_test_utils.launch_and_validate_results_launcher(launcher, level, remote_console_instance, expected_lines, null_renderer=False) diff --git a/AutomatedTesting/Gem/Sponza/gem.json b/AutomatedTesting/Gem/Sponza/gem.json index 68749cd5f4..f36b22a805 100644 --- a/AutomatedTesting/Gem/Sponza/gem.json +++ b/AutomatedTesting/Gem/Sponza/gem.json @@ -4,14 +4,19 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "A standard test scene for Global Illumination (forked from crytek sponza scene)", "canonical_tags": [ - "Gem" + "Gem", + "Asset" ], "user_tags": [ - "Assets" + "Sponza" ], + "icon_path": "preview.png", "requirements": "", - "dependencies": [] + "documentation_url": "", + "dependencies": [ + ] } diff --git a/AutomatedTesting/Gem/gem.json b/AutomatedTesting/Gem/gem.json index df197df09d..90a0c8cb01 100644 --- a/AutomatedTesting/Gem/gem.json +++ b/AutomatedTesting/Gem/gem.json @@ -3,13 +3,21 @@ "display_name": "AutomatedTesting", "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", - "origin": "Amazon Web Services, Inc.", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "Project Gem for customizing the AutomatedTesting project functionality.", "canonical_tags": [ "Gem" ], - "user_tags": [], + "user_tags": [ + "AutomatedTesting" + ], "icon_path": "preview.png", - "requirements": "" + "requirements": "", + "documentation_url": "", + "dependencies": [], + "external_subdirectories": [ + "PythonCoverage" + ] } diff --git a/AutomatedTesting/Levels/AWS/ClientAuth/ClientAuth.ly b/AutomatedTesting/Levels/AWS/ClientAuth/ClientAuth.ly deleted file mode 100644 index b4a2d6cb3a..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuth/ClientAuth.ly +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:19f2c4454bb395cdc0a36d1e45e6a384bbd23037af1a2fb93e088ecfa0f10e5b -size 9343 diff --git a/AutomatedTesting/Levels/AWS/ClientAuth/ClientAuth.prefab b/AutomatedTesting/Levels/AWS/ClientAuth/ClientAuth.prefab new file mode 100644 index 0000000000..8f2fb61c71 --- /dev/null +++ b/AutomatedTesting/Levels/AWS/ClientAuth/ClientAuth.prefab @@ -0,0 +1,620 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]", + "Entity_[2670735447885]", + "Entity_[2670735447885]" + ] + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 6861302815203973165 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1172344194419]": { + "Id": "Entity_[1172344194419]", + "Name": "Shader Ball", + "Components": { + "Component_[10789351944715265527]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10789351944715265527 + }, + "Component_[12037033284781049225]": { + "$type": "EditorEntitySortComponent", + "Id": 12037033284781049225 + }, + "Component_[13759153306105970079]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13759153306105970079 + }, + "Component_[14135560884830586279]": { + "$type": "EditorInspectorComponent", + "Id": 14135560884830586279 + }, + "Component_[16247165675903986673]": { + "$type": "EditorVisibilityComponent", + "Id": 16247165675903986673 + }, + "Component_[18082433625958885247]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18082433625958885247 + }, + "Component_[6472623349872972660]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6472623349872972660, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Rotate": [ + 0.0, + 0.10000000149011612, + 180.0 + ] + } + }, + "Component_[6495255223970673916]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 6495255223970673916, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{FD340C30-755C-5911-92A3-19A3F7A77931}", + "subId": 281415304 + }, + "assetHint": "objects/shaderball/shaderball_default_1m.azmodel" + } + } + } + }, + "Component_[8056625192494070973]": { + "$type": "SelectionComponent", + "Id": 8056625192494070973 + }, + "Component_[8550141614185782969]": { + "$type": "EditorEntityIconComponent", + "Id": 8550141614185782969 + }, + "Component_[9439770997198325425]": { + "$type": "EditorLockComponent", + "Id": 9439770997198325425 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1172344194419]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11231930600558681245]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 11231930600558681245, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + }, + "Entity_[2670735447885]": { + "Id": "Entity_[2670735447885]", + "Name": "AnonymousAuthorization", + "Components": { + "Component_[11400228652398928245]": { + "$type": "EditorOnlyEntityComponent", + "Id": 11400228652398928245 + }, + "Component_[15542812360906781451]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15542812360906781451, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 0.0, + 0.10000038146972656, + 4.005923748016357 + ] + } + }, + "Component_[16858205397479531670]": { + "$type": "EditorLockComponent", + "Id": 16858205397479531670 + }, + "Component_[1921474395300693283]": { + "$type": "EditorScriptCanvasComponent", + "Id": 1921474395300693283, + "m_name": "ConitoAnonymousAuthorization.scriptcanvas", + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "id": "{C0B0CEBA-064E-580F-AD81-CFE8CE0D61B1}" + } + }, + "sourceHandle": { + "id": "{C0B0CEBA-064E-580F-AD81-CFE8CE0D61B1}" + } + }, + "Component_[2312432053711106201]": { + "$type": "EditorEntityIconComponent", + "Id": 2312432053711106201 + }, + "Component_[4066858233846929269]": { + "$type": "EditorEntitySortComponent", + "Id": 4066858233846929269 + }, + "Component_[6542133807409587028]": { + "$type": "EditorPendingCompositionComponent", + "Id": 6542133807409587028 + }, + "Component_[7002965736546436267]": { + "$type": "SelectionComponent", + "Id": 7002965736546436267 + }, + "Component_[7455250879152263787]": { + "$type": "EditorVisibilityComponent", + "Id": 7455250879152263787 + }, + "Component_[8081535907930415421]": { + "$type": "EditorInspectorComponent", + "Id": 8081535907930415421 + }, + "Component_[9630473919092479415]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 9630473919092479415 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/AWS/ClientAuth/filelist.xml b/AutomatedTesting/Levels/AWS/ClientAuth/filelist.xml deleted file mode 100644 index 6b5b5a8727..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuth/filelist.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/AutomatedTesting/Levels/AWS/ClientAuth/level.pak b/AutomatedTesting/Levels/AWS/ClientAuth/level.pak deleted file mode 100644 index bd791070e9..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuth/level.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8a674e05824e5ceec13a0487b318923568710bc8269e5be84adad59c495a7ceb -size 3610 diff --git a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/ClientAuthPasswordSignIn.ly b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/ClientAuthPasswordSignIn.ly deleted file mode 100644 index 40d9ad619c..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/ClientAuthPasswordSignIn.ly +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a1c0b621525b8e88c3775ea4c60c2197d1e1b060ace9bad9d6efcb0532817e44 -size 9356 diff --git a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/ClientAuthPasswordSignIn.prefab b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/ClientAuthPasswordSignIn.prefab new file mode 100644 index 0000000000..46c01bbb0f --- /dev/null +++ b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/ClientAuthPasswordSignIn.prefab @@ -0,0 +1,620 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]", + "Entity_[3263440934733]", + "Entity_[3263440934733]" + ] + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 6861302815203973165 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1172344194419]": { + "Id": "Entity_[1172344194419]", + "Name": "Shader Ball", + "Components": { + "Component_[10789351944715265527]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10789351944715265527 + }, + "Component_[12037033284781049225]": { + "$type": "EditorEntitySortComponent", + "Id": 12037033284781049225 + }, + "Component_[13759153306105970079]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13759153306105970079 + }, + "Component_[14135560884830586279]": { + "$type": "EditorInspectorComponent", + "Id": 14135560884830586279 + }, + "Component_[16247165675903986673]": { + "$type": "EditorVisibilityComponent", + "Id": 16247165675903986673 + }, + "Component_[18082433625958885247]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18082433625958885247 + }, + "Component_[6472623349872972660]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6472623349872972660, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Rotate": [ + 0.0, + 0.10000000149011612, + 180.0 + ] + } + }, + "Component_[6495255223970673916]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 6495255223970673916, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{FD340C30-755C-5911-92A3-19A3F7A77931}", + "subId": 281415304 + }, + "assetHint": "objects/shaderball/shaderball_default_1m.azmodel" + } + } + } + }, + "Component_[8056625192494070973]": { + "$type": "SelectionComponent", + "Id": 8056625192494070973 + }, + "Component_[8550141614185782969]": { + "$type": "EditorEntityIconComponent", + "Id": 8550141614185782969 + }, + "Component_[9439770997198325425]": { + "$type": "EditorLockComponent", + "Id": 9439770997198325425 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1172344194419]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11231930600558681245]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 11231930600558681245, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + }, + "Entity_[3263440934733]": { + "Id": "Entity_[3263440934733]", + "Name": "Auth", + "Components": { + "Component_[10677660472305013611]": { + "$type": "EditorPendingCompositionComponent", + "Id": 10677660472305013611 + }, + "Component_[12020966173483420539]": { + "$type": "EditorInspectorComponent", + "Id": 12020966173483420539 + }, + "Component_[1395011275436594572]": { + "$type": "EditorLockComponent", + "Id": 1395011275436594572 + }, + "Component_[14204408480276164321]": { + "$type": "EditorScriptCanvasComponent", + "Id": 14204408480276164321, + "m_name": "PasswordSignIn.scriptcanvas", + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "id": "{DA0FCA2B-66E4-575B-802E-BA93F35690C1}" + } + }, + "sourceHandle": { + "id": "{DA0FCA2B-66E4-575B-802E-BA93F35690C1}" + } + }, + "Component_[15510129631063791276]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15510129631063791276 + }, + "Component_[2829815269827202953]": { + "$type": "EditorEntitySortComponent", + "Id": 2829815269827202953 + }, + "Component_[4152540778425032559]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 4152540778425032559, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 0.0, + 0.10000038146972656, + 4.005923748016357 + ] + } + }, + "Component_[4562090268412258507]": { + "$type": "EditorEntityIconComponent", + "Id": 4562090268412258507 + }, + "Component_[4826060551136971267]": { + "$type": "SelectionComponent", + "Id": 4826060551136971267 + }, + "Component_[8974703175361704047]": { + "$type": "EditorVisibilityComponent", + "Id": 8974703175361704047 + }, + "Component_[9513341577149946975]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9513341577149946975 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/filelist.xml b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/filelist.xml deleted file mode 100644 index ce3f3f3407..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/filelist.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/level.pak b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/level.pak deleted file mode 100644 index 1af55520b6..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignIn/level.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:f318a1787069385de291660f79e350cea2ca2c3ef3b5e0576686066bd9c49395 -size 3667 diff --git a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/ClientAuthPasswordSignUp.ly b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/ClientAuthPasswordSignUp.ly deleted file mode 100644 index b3f66ff34a..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/ClientAuthPasswordSignUp.ly +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:afc5d665128738e6bea09e78a16ee38acc923a8ecefff90d987858ce72c395fa -size 9360 diff --git a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/ClientAuthPasswordSignUp.prefab b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/ClientAuthPasswordSignUp.prefab new file mode 100644 index 0000000000..3d85ec02a5 --- /dev/null +++ b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/ClientAuthPasswordSignUp.prefab @@ -0,0 +1,620 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]", + "Entity_[3851851454285]", + "Entity_[3851851454285]" + ] + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 6861302815203973165 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1172344194419]": { + "Id": "Entity_[1172344194419]", + "Name": "Shader Ball", + "Components": { + "Component_[10789351944715265527]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10789351944715265527 + }, + "Component_[12037033284781049225]": { + "$type": "EditorEntitySortComponent", + "Id": 12037033284781049225 + }, + "Component_[13759153306105970079]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13759153306105970079 + }, + "Component_[14135560884830586279]": { + "$type": "EditorInspectorComponent", + "Id": 14135560884830586279 + }, + "Component_[16247165675903986673]": { + "$type": "EditorVisibilityComponent", + "Id": 16247165675903986673 + }, + "Component_[18082433625958885247]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18082433625958885247 + }, + "Component_[6472623349872972660]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6472623349872972660, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Rotate": [ + 0.0, + 0.10000000149011612, + 180.0 + ] + } + }, + "Component_[6495255223970673916]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 6495255223970673916, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{FD340C30-755C-5911-92A3-19A3F7A77931}", + "subId": 281415304 + }, + "assetHint": "objects/shaderball/shaderball_default_1m.azmodel" + } + } + } + }, + "Component_[8056625192494070973]": { + "$type": "SelectionComponent", + "Id": 8056625192494070973 + }, + "Component_[8550141614185782969]": { + "$type": "EditorEntityIconComponent", + "Id": 8550141614185782969 + }, + "Component_[9439770997198325425]": { + "$type": "EditorLockComponent", + "Id": 9439770997198325425 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1172344194419]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11231930600558681245]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 11231930600558681245, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + }, + "Entity_[3851851454285]": { + "Id": "Entity_[3851851454285]", + "Name": "Auth", + "Components": { + "Component_[10199578265902796701]": { + "$type": "EditorScriptCanvasComponent", + "Id": 10199578265902796701, + "m_name": "PasswordSignUp.scriptcanvas", + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "id": "{367CEE66-3A7D-549E-BD69-C63612B3F12D}" + } + }, + "sourceHandle": { + "id": "{367CEE66-3A7D-549E-BD69-C63612B3F12D}" + } + }, + "Component_[10665743855533689275]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10665743855533689275 + }, + "Component_[15982638153420818774]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15982638153420818774, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 0.0, + 0.10000038146972656, + 4.005923748016357 + ] + } + }, + "Component_[17743308263820862394]": { + "$type": "EditorOnlyEntityComponent", + "Id": 17743308263820862394 + }, + "Component_[18074634570765223479]": { + "$type": "SelectionComponent", + "Id": 18074634570765223479 + }, + "Component_[3471158028107369345]": { + "$type": "EditorEntityIconComponent", + "Id": 3471158028107369345 + }, + "Component_[376079292001997684]": { + "$type": "EditorInspectorComponent", + "Id": 376079292001997684 + }, + "Component_[4387781728620577034]": { + "$type": "EditorLockComponent", + "Id": 4387781728620577034 + }, + "Component_[8591645353763910598]": { + "$type": "EditorEntitySortComponent", + "Id": 8591645353763910598 + }, + "Component_[9373910525775599099]": { + "$type": "EditorVisibilityComponent", + "Id": 9373910525775599099 + }, + "Component_[9394316863271268125]": { + "$type": "EditorPendingCompositionComponent", + "Id": 9394316863271268125 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/filelist.xml b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/filelist.xml deleted file mode 100644 index 6565342dd4..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/filelist.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/level.pak b/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/level.pak deleted file mode 100644 index 781de219f7..0000000000 --- a/AutomatedTesting/Levels/AWS/ClientAuthPasswordSignUp/level.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:87882b64688a77815d93c6973929fa21b89dc6c13d4866c710124ce2cd0f411e -size 3652 diff --git a/AutomatedTesting/Levels/AWS/Core/Core.ly b/AutomatedTesting/Levels/AWS/Core/Core.ly deleted file mode 100644 index 8b01ee7abe..0000000000 --- a/AutomatedTesting/Levels/AWS/Core/Core.ly +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:5242a9b598bc329ef2af2b114092e4e50c7c398cdde4605a0717b0b3ce66d797 -size 10030 diff --git a/AutomatedTesting/Levels/AWS/Core/Core.prefab b/AutomatedTesting/Levels/AWS/Core/Core.prefab new file mode 100644 index 0000000000..3d2749849b --- /dev/null +++ b/AutomatedTesting/Levels/AWS/Core/Core.prefab @@ -0,0 +1,758 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]", + "Entity_[1386540226381]", + "Entity_[1390835193677]", + "Entity_[1395130160973]", + "Entity_[1395130160973]" + ] + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 6861302815203973165 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1172344194419]": { + "Id": "Entity_[1172344194419]", + "Name": "Shader Ball", + "Components": { + "Component_[10789351944715265527]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10789351944715265527 + }, + "Component_[12037033284781049225]": { + "$type": "EditorEntitySortComponent", + "Id": 12037033284781049225 + }, + "Component_[13759153306105970079]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13759153306105970079 + }, + "Component_[14135560884830586279]": { + "$type": "EditorInspectorComponent", + "Id": 14135560884830586279 + }, + "Component_[16247165675903986673]": { + "$type": "EditorVisibilityComponent", + "Id": 16247165675903986673 + }, + "Component_[18082433625958885247]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18082433625958885247 + }, + "Component_[6472623349872972660]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6472623349872972660, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Rotate": [ + 0.0, + 0.10000000149011612, + 180.0 + ] + } + }, + "Component_[6495255223970673916]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 6495255223970673916, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{FD340C30-755C-5911-92A3-19A3F7A77931}", + "subId": 281415304 + }, + "assetHint": "objects/shaderball/shaderball_default_1m.azmodel" + } + } + } + }, + "Component_[8056625192494070973]": { + "$type": "SelectionComponent", + "Id": 8056625192494070973 + }, + "Component_[8550141614185782969]": { + "$type": "EditorEntityIconComponent", + "Id": 8550141614185782969 + }, + "Component_[9439770997198325425]": { + "$type": "EditorLockComponent", + "Id": 9439770997198325425 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1172344194419]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11231930600558681245]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 11231930600558681245, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + }, + "Entity_[1386540226381]": { + "Id": "Entity_[1386540226381]", + "Name": "s3", + "Components": { + "Component_[11158492000035348927]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 11158492000035348927 + }, + "Component_[13101294672800983417]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13101294672800983417 + }, + "Component_[13312594438559441372]": { + "$type": "EditorEntitySortComponent", + "Id": 13312594438559441372 + }, + "Component_[14532086496432860950]": { + "$type": "EditorVisibilityComponent", + "Id": 14532086496432860950 + }, + "Component_[15284288439796123368]": { + "$type": "EditorOnlyEntityComponent", + "Id": 15284288439796123368 + }, + "Component_[17553238493971510581]": { + "$type": "EditorScriptCanvasComponent", + "Id": 17553238493971510581, + "m_name": "s3demo.scriptcanvas", + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "id": "{D72821C5-1C31-5AE5-891D-30371C49B9E0}" + } + }, + "sourceHandle": { + "id": "{D72821C5-1C31-5AE5-891D-30371C49B9E0}" + } + }, + "Component_[17621265899133139471]": { + "$type": "EditorLockComponent", + "Id": 17621265899133139471 + }, + "Component_[2763569637558196086]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 2763569637558196086, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 0.0, + 0.10000038146972656, + 4.005923748016357 + ] + } + }, + "Component_[3946146016045577093]": { + "$type": "SelectionComponent", + "Id": 3946146016045577093 + }, + "Component_[4521094551057628689]": { + "$type": "EditorInspectorComponent", + "Id": 4521094551057628689 + }, + "Component_[5378520857609165944]": { + "$type": "EditorEntityIconComponent", + "Id": 5378520857609165944 + } + } + }, + "Entity_[1390835193677]": { + "Id": "Entity_[1390835193677]", + "Name": "dynamodb", + "Components": { + "Component_[13579073750136791325]": { + "$type": "EditorVisibilityComponent", + "Id": 13579073750136791325 + }, + "Component_[14581079376974874313]": { + "$type": "EditorEntitySortComponent", + "Id": 14581079376974874313 + }, + "Component_[15354545119837386836]": { + "$type": "SelectionComponent", + "Id": 15354545119837386836 + }, + "Component_[15913971829919706180]": { + "$type": "EditorEntityIconComponent", + "Id": 15913971829919706180 + }, + "Component_[17308449372189366987]": { + "$type": "EditorPendingCompositionComponent", + "Id": 17308449372189366987 + }, + "Component_[17741852956994822371]": { + "$type": "EditorOnlyEntityComponent", + "Id": 17741852956994822371 + }, + "Component_[4363122368868820254]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4363122368868820254 + }, + "Component_[4890242568951925088]": { + "$type": "EditorScriptCanvasComponent", + "Id": 4890242568951925088, + "m_name": "dynamodbdemo.scriptcanvas", + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "id": "{004B97C6-75F3-5B95-ADA4-EBF751EEF697}" + } + }, + "sourceHandle": { + "id": "{004B97C6-75F3-5B95-ADA4-EBF751EEF697}" + } + }, + "Component_[7140725680315799866]": { + "$type": "EditorLockComponent", + "Id": 7140725680315799866 + }, + "Component_[8431133659360426398]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 8431133659360426398, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 0.0, + 0.10000038146972656, + 4.005923748016357 + ] + } + }, + "Component_[9486500593077263666]": { + "$type": "EditorInspectorComponent", + "Id": 9486500593077263666 + } + } + }, + "Entity_[1395130160973]": { + "Id": "Entity_[1395130160973]", + "Name": "lambda", + "Components": { + "Component_[14224781635611846065]": { + "$type": "SelectionComponent", + "Id": 14224781635611846065 + }, + "Component_[14532864313352417822]": { + "$type": "EditorInspectorComponent", + "Id": 14532864313352417822 + }, + "Component_[14621438229914413040]": { + "$type": "EditorEntitySortComponent", + "Id": 14621438229914413040 + }, + "Component_[15642112885025274607]": { + "$type": "EditorLockComponent", + "Id": 15642112885025274607 + }, + "Component_[16340039184260739086]": { + "$type": "EditorVisibilityComponent", + "Id": 16340039184260739086 + }, + "Component_[17170806711467412600]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17170806711467412600, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 0.0, + 0.10000038146972656, + 4.005923748016357 + ] + } + }, + "Component_[18080677632538463069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18080677632538463069 + }, + "Component_[2663457305102263144]": { + "$type": "EditorEntityIconComponent", + "Id": 2663457305102263144 + }, + "Component_[4954526281430171003]": { + "$type": "EditorOnlyEntityComponent", + "Id": 4954526281430171003 + }, + "Component_[6251151424244415885]": { + "$type": "EditorScriptCanvasComponent", + "Id": 6251151424244415885, + "m_name": "lambdademo.scriptcanvas", + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "id": "{3DCA213D-534E-5C86-9308-2F7675A08029}" + } + }, + "sourceHandle": { + "id": "{3DCA213D-534E-5C86-9308-2F7675A08029}" + } + }, + "Component_[6526999075003995619]": { + "$type": "EditorPendingCompositionComponent", + "Id": 6526999075003995619 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/AWS/Core/filelist.xml b/AutomatedTesting/Levels/AWS/Core/filelist.xml deleted file mode 100644 index 9d1fcd2e83..0000000000 --- a/AutomatedTesting/Levels/AWS/Core/filelist.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/AutomatedTesting/Levels/AWS/Core/level.pak b/AutomatedTesting/Levels/AWS/Core/level.pak deleted file mode 100644 index 01b79da84e..0000000000 --- a/AutomatedTesting/Levels/AWS/Core/level.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:4ba2f409fc974c72b8ee8b660d200ed1d013ee8408419b0e91d6d487e71e4997 -size 3774 diff --git a/AutomatedTesting/Levels/AWS/Metrics/Metrics.ly b/AutomatedTesting/Levels/AWS/Metrics/Metrics.ly deleted file mode 100644 index 12998e89be..0000000000 --- a/AutomatedTesting/Levels/AWS/Metrics/Metrics.ly +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:023992998ab5a1d64b38dacd1d5e1a9dc930ff704289c0656ed6eaba6951d660 -size 9066 diff --git a/AutomatedTesting/Levels/AWS/Metrics/Metrics.prefab b/AutomatedTesting/Levels/AWS/Metrics/Metrics.prefab new file mode 100644 index 0000000000..7f4144d734 --- /dev/null +++ b/AutomatedTesting/Levels/AWS/Metrics/Metrics.prefab @@ -0,0 +1,627 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]", + "Entity_[2086619895629]", + "Entity_[2086619895629]" + ] + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 6861302815203973165 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1172344194419]": { + "Id": "Entity_[1172344194419]", + "Name": "Shader Ball", + "Components": { + "Component_[10789351944715265527]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10789351944715265527 + }, + "Component_[12037033284781049225]": { + "$type": "EditorEntitySortComponent", + "Id": 12037033284781049225 + }, + "Component_[13759153306105970079]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13759153306105970079 + }, + "Component_[14135560884830586279]": { + "$type": "EditorInspectorComponent", + "Id": 14135560884830586279 + }, + "Component_[16247165675903986673]": { + "$type": "EditorVisibilityComponent", + "Id": 16247165675903986673 + }, + "Component_[18082433625958885247]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18082433625958885247 + }, + "Component_[6472623349872972660]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6472623349872972660, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Rotate": [ + 0.0, + 0.10000000149011612, + 180.0 + ] + } + }, + "Component_[6495255223970673916]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 6495255223970673916, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{FD340C30-755C-5911-92A3-19A3F7A77931}", + "subId": 281415304 + }, + "assetHint": "objects/shaderball/shaderball_default_1m.azmodel" + } + } + } + }, + "Component_[8056625192494070973]": { + "$type": "SelectionComponent", + "Id": 8056625192494070973 + }, + "Component_[8550141614185782969]": { + "$type": "EditorEntityIconComponent", + "Id": 8550141614185782969 + }, + "Component_[9439770997198325425]": { + "$type": "EditorLockComponent", + "Id": 9439770997198325425 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1172344194419]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11231930600558681245]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 11231930600558681245, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + }, + "Entity_[2086619895629]": { + "Id": "Entity_[2086619895629]", + "Name": "metrics", + "Components": { + "Component_[10664937239001700943]": { + "$type": "SelectionComponent", + "Id": 10664937239001700943 + }, + "Component_[12411100785613400502]": { + "$type": "EditorVisibilityComponent", + "Id": 12411100785613400502 + }, + "Component_[13461617945403887462]": { + "$type": "EditorEntityIconComponent", + "Id": 13461617945403887462 + }, + "Component_[1398528805938487915]": { + "$type": "EditorInspectorComponent", + "Id": 1398528805938487915 + }, + "Component_[15586634767575159325]": { + "$type": "EditorEntitySortComponent", + "Id": 15586634767575159325 + }, + "Component_[1737734807882912852]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1737734807882912852 + }, + "Component_[2398400563175352537]": { + "$type": "EditorOnlyEntityComponent", + "Id": 2398400563175352537 + }, + "Component_[3845542252660517302]": { + "$type": "EditorPendingCompositionComponent", + "Id": 3845542252660517302 + }, + "Component_[3873433240186817282]": { + "$type": "EditorLockComponent", + "Id": 3873433240186817282 + }, + "Component_[4474288881478318615]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 4474288881478318615, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 0.0, + 0.10000038146972656, + 4.005923748016357 + ] + } + }, + "Component_[5865591669658426602]": { + "$type": "ScriptEditorComponent", + "Id": 5865591669658426602, + "ScriptComponent": { + "Script": { + "assetId": { + "guid": "{50D66834-9277-5469-892E-DAD087FF4C0E}", + "subId": 1 + }, + "loadBehavior": "QueueLoad", + "assetHint": "levels/aws/metrics/script/metrics.luac" + } + }, + "ScriptAsset": { + "assetId": { + "guid": "{50D66834-9277-5469-892E-DAD087FF4C0E}", + "subId": 1 + }, + "assetHint": "levels/aws/metrics/script/metrics.luac" + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/AWS/Metrics/filelist.xml b/AutomatedTesting/Levels/AWS/Metrics/filelist.xml deleted file mode 100644 index 3539102346..0000000000 --- a/AutomatedTesting/Levels/AWS/Metrics/filelist.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/AutomatedTesting/Levels/AWS/Metrics/level.pak b/AutomatedTesting/Levels/AWS/Metrics/level.pak deleted file mode 100644 index fd1f5ac6ad..0000000000 --- a/AutomatedTesting/Levels/AWS/Metrics/level.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:e7c0c07b13bb64db344b94d5712e1e802e607a9dee506768b34481f4a76d8505 -size 3593 diff --git a/AutomatedTesting/Levels/PbrMaterialChart/PbrMaterialChart.prefab b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/PbrMaterialChart.prefab similarity index 97% rename from AutomatedTesting/Levels/PbrMaterialChart/PbrMaterialChart.prefab rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/PbrMaterialChart.prefab index faa93597de..2c0ee5cb1a 100644 --- a/AutomatedTesting/Levels/PbrMaterialChart/PbrMaterialChart.prefab +++ b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/PbrMaterialChart.prefab @@ -1474,9 +1474,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{1FD47684-2E9E-5525-BBCA-251795F9033C}" + "guid": "{12B5A321-3D64-5DF6-9E15-D8F447229EC1}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r00.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r00.azmaterial" } } } @@ -1569,9 +1569,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{B5660D78-818E-5273-AF3D-EC8189E2E6CB}" + "guid": "{EB8B9C49-D6F4-5098-AC97-543381E2554A}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r01.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r01.azmaterial" } } } @@ -1824,9 +1824,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{512443BD-9511-5F13-A84A-3ED5DB9E9B5A}" + "guid": "{CAA9CAFC-8A48-5406-BE26-448E5AA1A5B0}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r02.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r02.azmaterial" } } } @@ -1926,9 +1926,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{E28A5CC5-4B8B-5B90-877A-3D92C75DC75A}" + "guid": "{2F338C0B-EF86-5AC4-AEE6-28A26BB9E97E}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r03.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r03.azmaterial" } } } @@ -2028,9 +2028,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{1495BCCF-3F96-5D0B-8176-228DB22CEC82}" + "guid": "{9BF4E656-0D4F-5746-A256-32740742712B}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r04.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r04.azmaterial" } } } @@ -2130,9 +2130,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{40494612-0ABF-55B5-9C56-E968763FCFDE}" + "guid": "{850398D7-386A-56C6-AEB2-95E4F64368B1}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r05.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r05.azmaterial" } } } @@ -2232,9 +2232,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{76CF9D4A-009F-5494-83AB-6E3D4D1B4A36}" + "guid": "{74784C2A-A713-5C6A-8B3D-B66CAE3DD055}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r06.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r06.azmaterial" } } } @@ -2334,9 +2334,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{8431B792-E6CC-51DD-B82E-F3E4A12FCB4A}" + "guid": "{4F9F91F7-7E22-5A14-856D-194CC258E70D}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r07.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r07.azmaterial" } } } @@ -2436,9 +2436,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{4B1F29FF-7971-5524-AA1B-0DC2392A33C4}" + "guid": "{842AE870-802B-5934-997F-0965F960ECB9}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r08.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r08.azmaterial" } } } @@ -2538,9 +2538,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{785BE6DE-C0EB-5B47-9438-4F9ECFC34A96}" + "guid": "{0184CF10-E675-5C33-B1B9-009C383AB463}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r09.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r09.azmaterial" } } } @@ -2640,9 +2640,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{C40DE9AE-6756-57E7-B3B4-FB0542B5CD0F}" + "guid": "{6DDA0761-C165-58CC-B45E-03C29F0CF598}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m00_r10.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m00_r10.azmaterial" } } } @@ -2896,9 +2896,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{251C4C29-4ECD-5763-AF4F-20675EAC048B}" + "guid": "{101AB53A-3B3E-5ACF-841C-65DB2BFBF305}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r04.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r04.azmaterial" } } } @@ -2998,9 +2998,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{02D082C4-5032-57CC-A081-BC4D8518BCF0}" + "guid": "{B82B96D6-7511-5E22-A36E-FFF682B3236B}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r05.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r05.azmaterial" } } } @@ -3100,9 +3100,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{FA9D8842-95B2-5371-8352-CBEEEAABE676}" + "guid": "{DBED5292-3E17-5038-9974-80A8BB1F79E8}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r06.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r06.azmaterial" } } } @@ -3202,9 +3202,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{522A9626-FF4C-561A-A44A-64B68F7274D2}" + "guid": "{25F07733-365C-5826-AEE3-E92FBE807555}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r07.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r07.azmaterial" } } } @@ -3304,9 +3304,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{06DDFD66-D7F5-5D55-8972-6D61276E88F6}" + "guid": "{C9A7B916-CF71-5A34-B9B9-54FE8CB058DC}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r00.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r00.azmaterial" } } } @@ -3399,9 +3399,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{060EF1B7-1029-5227-B03B-1415C74E9D65}" + "guid": "{85C8DFC5-358D-579D-B922-14FA1B401571}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r08.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r08.azmaterial" } } } @@ -3501,9 +3501,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{7B7BC6F8-150A-518F-816E-2F7DBE786461}" + "guid": "{51924281-7A06-5654-B783-A4F5759063ED}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r01.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r01.azmaterial" } } } @@ -3603,9 +3603,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{270881B6-21E9-509D-A6CD-1046674FB0BE}" + "guid": "{7877F64E-26E3-558C-B6D9-B609ED6E43BF}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r09.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r09.azmaterial" } } } @@ -3705,9 +3705,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{C0538953-C56E-5C1A-BBE2-E6BE04764C20}" + "guid": "{6CC3C6B9-EE05-5A77-A12D-7085D93D89DB}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r02.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r02.azmaterial" } } } @@ -3874,9 +3874,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{5EA26E09-E3D6-5181-8E7A-F2E98A24247C}" + "guid": "{E6E15876-EEF3-555D-BD80-1B9D5A7ECC7D}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r10.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r10.azmaterial" } } } @@ -3976,9 +3976,9 @@ "{}": { "MaterialAsset": { "assetId": { - "guid": "{E1A5D708-7A49-5CCA-81C3-4CB337C47703}" + "guid": "{83179EEC-BAC7-5D39-9788-37D33E9584B1}" }, - "assetHint": "levels/pbrmaterialchart/materials/basic_m10_r03.azmaterial" + "assetHint": "levels/graphics/pbrmaterialchart/materials/basic_m10_r03.azmaterial" } } } diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r00.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r00.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r00.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r00.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r01.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r01.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r01.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r01.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r02.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r02.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r02.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r02.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r03.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r03.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r03.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r03.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r04.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r04.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r04.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r04.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r05.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r05.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r05.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r05.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r06.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r06.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r06.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r06.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r07.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r07.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r07.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r07.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r08.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r08.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r08.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r08.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r09.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r09.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r09.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r09.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r10.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r10.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m00_r10.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m00_r10.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r00.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r00.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r00.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r00.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r01.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r01.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r01.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r01.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r02.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r02.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r02.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r02.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r03.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r03.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r03.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r03.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r04.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r04.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r04.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r04.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r05.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r05.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r05.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r05.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r06.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r06.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r06.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r06.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r07.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r07.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r07.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r07.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r08.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r08.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r08.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r08.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r09.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r09.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r09.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r09.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r10.material b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r10.material similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/materials/basic_m10_r10.material rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/materials/basic_m10_r10.material diff --git a/AutomatedTesting/Levels/PbrMaterialChart/tags.txt b/AutomatedTesting/Levels/Graphics/PbrMaterialChart/tags.txt similarity index 100% rename from AutomatedTesting/Levels/PbrMaterialChart/tags.txt rename to AutomatedTesting/Levels/Graphics/PbrMaterialChart/tags.txt diff --git a/AutomatedTesting/Levels/Graphics/ShadowTest/ShadowTest.prefab b/AutomatedTesting/Levels/Graphics/ShadowTest/ShadowTest.prefab new file mode 100644 index 0000000000..86d16328e9 --- /dev/null +++ b/AutomatedTesting/Levels/Graphics/ShadowTest/ShadowTest.prefab @@ -0,0 +1,566 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "ShadowTest", + "Components": { + "Component_[10182366347512475253]": { + "$type": "EditorPrefabComponent", + "Id": 10182366347512475253 + }, + "Component_[12917798267488243668]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12917798267488243668 + }, + "Component_[3261249813163778338]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3261249813163778338 + }, + "Component_[3837204912784440039]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 3837204912784440039 + }, + "Component_[4272963378099646759]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 4272963378099646759, + "Parent Entity": "" + }, + "Component_[4848458548047175816]": { + "$type": "EditorVisibilityComponent", + "Id": 4848458548047175816 + }, + "Component_[5787060997243919943]": { + "$type": "EditorInspectorComponent", + "Id": 5787060997243919943 + }, + "Component_[7804170251266531779]": { + "$type": "EditorLockComponent", + "Id": 7804170251266531779 + }, + "Component_[7874177159288365422]": { + "$type": "EditorEntitySortComponent", + "Id": 7874177159288365422 + }, + "Component_[8018146290632383969]": { + "$type": "EditorEntityIconComponent", + "Id": 8018146290632383969 + }, + "Component_[8452360690590857075]": { + "$type": "SelectionComponent", + "Id": 8452360690590857075 + } + } + }, + "Entities": { + "Entity_[232650527119]": { + "Id": "Entity_[232650527119]", + "Name": "DirectionalLight", + "Components": { + "Component_[10660156197505313227]": { + "$type": "EditorLockComponent", + "Id": 10660156197505313227 + }, + "Component_[14184823757717157844]": { + "$type": "EditorInspectorComponent", + "Id": 14184823757717157844, + "ComponentOrderEntryArray": [ + { + "ComponentId": 9854879901259791898 + }, + { + "ComponentId": 3968519938187714949, + "SortIndex": 1 + } + ] + }, + "Component_[1495573908681275492]": { + "$type": "EditorEntitySortComponent", + "Id": 1495573908681275492 + }, + "Component_[15580233403487968826]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15580233403487968826 + }, + "Component_[3968519938187714949]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 3968519938187714949, + "Controller": { + "Configuration": { + "Intensity": 0.0, + "CameraEntityId": "", + "ShadowmapSize": "Size2048" + } + } + }, + "Component_[4961040003466069196]": { + "$type": "EditorEntityIconComponent", + "Id": 4961040003466069196 + }, + "Component_[7824884165323036147]": { + "$type": "EditorVisibilityComponent", + "Id": 7824884165323036147 + }, + "Component_[8741866916946672319]": { + "$type": "EditorPendingCompositionComponent", + "Id": 8741866916946672319 + }, + "Component_[9288966876314965560]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9288966876314965560 + }, + "Component_[9313163355156975968]": { + "$type": "SelectionComponent", + "Id": 9313163355156975968 + }, + "Component_[9854879901259791898]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 9854879901259791898, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 2.0 + ], + "Rotate": [ + -32.05662536621094, + -26.103206634521484, + 47.54806137084961 + ] + } + } + } + }, + "Entity_[260824893221]": { + "Id": "Entity_[260824893221]", + "Name": "SpotLight", + "Components": { + "Component_[16098295228434057928]": { + "$type": "EditorDiskShapeComponent", + "Id": 16098295228434057928, + "ShapeColor": [ + 1.0, + 1.0, + 1.0, + 1.0 + ], + "DiskShape": { + "Configuration": { + "Radius": 0.0 + } + } + }, + "Component_[16175995808158769171]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16175995808158769171, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 0.6417449712753296, + 1.3211734294891357, + 3.022759199142456 + ], + "Rotate": [ + 243.31329345703125, + 0.0, + 0.0 + ] + } + }, + "Component_[17136787899581093377]": { + "$type": "EditorEntitySortComponent", + "Id": 17136787899581093377 + }, + "Component_[17938027566627202610]": { + "$type": "EditorPendingCompositionComponent", + "Id": 17938027566627202610 + }, + "Component_[190081405128299223]": { + "$type": "SelectionComponent", + "Id": 190081405128299223 + }, + "Component_[2181418147135573579]": { + "$type": "EditorEntityIconComponent", + "Id": 2181418147135573579 + }, + "Component_[2564149706319215342]": { + "$type": "EditorOnlyEntityComponent", + "Id": 2564149706319215342 + }, + "Component_[3716169383940064541]": { + "$type": "EditorInspectorComponent", + "Id": 3716169383940064541, + "ComponentOrderEntryArray": [ + { + "ComponentId": 16175995808158769171 + }, + { + "ComponentId": 16665800442781289114, + "SortIndex": 1 + } + ] + }, + "Component_[4143676462074671972]": { + "$type": "AZ::Render::EditorAreaLightComponent", + "Id": 4143676462074671972, + "Controller": { + "Configuration": { + "LightType": 2, + "AttenuationRadius": 31.62277603149414, + "EnableShutters": true, + "InnerShutterAngleDegrees": 22.5, + "OuterShutterAngleDegrees": 27.5, + "Enable Shadow": true, + "Shadowmap Max Size": "Size2048", + "Filtering Sample Count": 32 + } + } + }, + "Component_[6706371214647538019]": { + "$type": "EditorVisibilityComponent", + "Id": 6706371214647538019 + }, + "Component_[7493944209625718550]": { + "$type": "EditorLockComponent", + "Id": 7493944209625718550 + }, + "Component_[7614113482082939165]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 7614113482082939165 + } + } + }, + "Entity_[269117486973]": { + "Id": "Entity_[269117486973]", + "Name": "Floor", + "Components": { + "Component_[10562678944594915756]": { + "$type": "EditorEntitySortComponent", + "Id": 10562678944594915756 + }, + "Component_[1175452962278157526]": { + "$type": "EditorEntityIconComponent", + "Id": 1175452962278157526 + }, + "Component_[13598353801231166887]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13598353801231166887 + }, + "Component_[13735087293504923475]": { + "$type": "SelectionComponent", + "Id": 13735087293504923475 + }, + "Component_[13888244442459268363]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 13888244442459268363, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E65E9ED3-3E38-5ABA-9E22-95E34DA4C3AE}", + "subId": 280178048 + }, + "assetHint": "objects/plane.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[1525720357937234014]": { + "$type": "EditorMaterialComponent", + "Id": 1525720357937234014, + "materialSlotsByLodEnabled": true + }, + "Component_[16568998871680422442]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16568998871680422442 + }, + "Component_[2147751093058990131]": { + "$type": "EditorInspectorComponent", + "Id": 2147751093058990131, + "ComponentOrderEntryArray": [ + { + "ComponentId": 3266761149114817871 + }, + { + "ComponentId": 13888244442459268363, + "SortIndex": 1 + }, + { + "ComponentId": 1525720357937234014, + "SortIndex": 2 + } + ] + }, + "Component_[3266761149114817871]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3266761149114817871, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Scale": [ + 100.0, + 100.0, + 100.0 + ], + "UniformScale": 100.0 + } + }, + "Component_[4625895382416898670]": { + "$type": "EditorVisibilityComponent", + "Id": 4625895382416898670 + }, + "Component_[4856699190357614535]": { + "$type": "EditorLockComponent", + "Id": 4856699190357614535 + }, + "Component_[6466465153982575739]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6466465153982575739 + } + } + }, + "Entity_[282757803856]": { + "Id": "Entity_[282757803856]", + "Name": "Cube", + "Components": { + "Component_[11189870094752260272]": { + "$type": "EditorEntitySortComponent", + "Id": 11189870094752260272 + }, + "Component_[11909086967677513257]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 11909086967677513257, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{593006BE-FE73-5A4B-A0A6-06C02EFFE458}", + "subId": 285127096 + }, + "loadBehavior": "PreLoad", + "assetHint": "objects/cube.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[1443341568598731610]": { + "$type": "EditorVisibilityComponent", + "Id": 1443341568598731610 + }, + "Component_[18339772707807258951]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18339772707807258951, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 0.6083869934082031, + 3.137901782989502, + 0.5876787900924683 + ] + } + }, + "Component_[2447207272572065708]": { + "$type": "EditorEntityIconComponent", + "Id": 2447207272572065708 + }, + "Component_[3281906807632213471]": { + "$type": "SelectionComponent", + "Id": 3281906807632213471 + }, + "Component_[3412442673858204671]": { + "$type": "EditorPendingCompositionComponent", + "Id": 3412442673858204671 + }, + "Component_[5382641380294287889]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5382641380294287889 + }, + "Component_[7221534636342494619]": { + "$type": "EditorInspectorComponent", + "Id": 7221534636342494619, + "ComponentOrderEntryArray": [ + { + "ComponentId": 18339772707807258951 + }, + { + "ComponentId": 11909086967677513257, + "SortIndex": 1 + } + ] + }, + "Component_[7701217952253676487]": { + "$type": "EditorLockComponent", + "Id": 7701217952253676487 + }, + "Component_[7758436981023123121]": { + "$type": "EditorOnlyEntityComponent", + "Id": 7758436981023123121 + } + } + }, + "Entity_[372196702077]": { + "Id": "Entity_[372196702077]", + "Name": "Bunny", + "Components": { + "Component_[11345914745205508221]": { + "$type": "EditorEntityIconComponent", + "Id": 11345914745205508221 + }, + "Component_[11507863983962969790]": { + "$type": "EditorMaterialComponent", + "Id": 11507863983962969790, + "materialSlotsByLodEnabled": true + }, + "Component_[1342998773562921470]": { + "$type": "EditorPendingCompositionComponent", + "Id": 1342998773562921470 + }, + "Component_[14975835087235718844]": { + "$type": "EditorInspectorComponent", + "Id": 14975835087235718844, + "ComponentOrderEntryArray": [ + { + "ComponentId": 5012565883129470759 + }, + { + "ComponentId": 7975043234993822905, + "SortIndex": 1 + }, + { + "ComponentId": 11507863983962969790, + "SortIndex": 2 + } + ] + }, + "Component_[16460806723667032929]": { + "$type": "EditorOnlyEntityComponent", + "Id": 16460806723667032929 + }, + "Component_[18225690044585951363]": { + "$type": "EditorLockComponent", + "Id": 18225690044585951363 + }, + "Component_[18314752491697618927]": { + "$type": "EditorEntitySortComponent", + "Id": 18314752491697618927 + }, + "Component_[2431610550789583502]": { + "$type": "EditorVisibilityComponent", + "Id": 2431610550789583502 + }, + "Component_[5012565883129470759]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 5012565883129470759, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 0.20401419699192047 + ] + } + }, + "Component_[7975043234993822905]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 7975043234993822905, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0C6BBB76-4EC2-583A-B8C6-1A4C4FD1FE9D}", + "subId": 283109893 + }, + "assetHint": "objects/bunny.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[8510666363380501112]": { + "$type": "SelectionComponent", + "Id": 8510666363380501112 + }, + "Component_[9639060480533776634]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 9639060480533776634 + } + } + }, + "Entity_[670308843764]": { + "Id": "Entity_[670308843764]", + "Name": "Camera1", + "Components": { + "Component_[12951260100632682169]": { + "$type": "GenericComponentWrapper", + "Id": 12951260100632682169, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[14180723329646459524]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14180723329646459524 + }, + "Component_[14996469885773917977]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 14996469885773917977, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 4.563776969909668, + 0.7667046785354614, + 3.000542640686035 + ], + "Rotate": [ + -9.740042686462402, + -20.20942497253418, + 63.57760238647461 + ] + } + }, + "Component_[17638492356673689530]": { + "$type": "EditorInspectorComponent", + "Id": 17638492356673689530 + }, + "Component_[2421853983468750254]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 2421853983468750254, + "Controller": { + "Configuration": { + "Field of View": 90.00020599365234, + "EditorEntityId": 666013876468 + } + } + }, + "Component_[2572028619185965684]": { + "$type": "EditorEntityIconComponent", + "Id": 2572028619185965684 + }, + "Component_[2782900516907042776]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 2782900516907042776 + }, + "Component_[2849166119438883669]": { + "$type": "EditorVisibilityComponent", + "Id": 2849166119438883669 + }, + "Component_[4618311795498613781]": { + "$type": "EditorOnlyEntityComponent", + "Id": 4618311795498613781 + }, + "Component_[5402004894214413002]": { + "$type": "EditorEntitySortComponent", + "Id": 5402004894214413002 + }, + "Component_[6111028576371006514]": { + "$type": "SelectionComponent", + "Id": 6111028576371006514 + }, + "Component_[8203141294643544464]": { + "$type": "EditorLockComponent", + "Id": 8203141294643544464 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/tags.txt b/AutomatedTesting/Levels/Graphics/ShadowTest/tags.txt similarity index 100% rename from AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/tags.txt rename to AutomatedTesting/Levels/Graphics/ShadowTest/tags.txt diff --git a/AutomatedTesting/Levels/Sponza/Sponza.prefab b/AutomatedTesting/Levels/Graphics/Sponza/Sponza.prefab similarity index 100% rename from AutomatedTesting/Levels/Sponza/Sponza.prefab rename to AutomatedTesting/Levels/Graphics/Sponza/Sponza.prefab diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/tags.txt b/AutomatedTesting/Levels/Graphics/Sponza/tags.txt similarity index 100% rename from AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/tags.txt rename to AutomatedTesting/Levels/Graphics/Sponza/tags.txt diff --git a/AutomatedTesting/Levels/Graphics/hermanubis/hermanubis.prefab b/AutomatedTesting/Levels/Graphics/hermanubis/hermanubis.prefab new file mode 100644 index 0000000000..2234b02cfe --- /dev/null +++ b/AutomatedTesting/Levels/Graphics/hermanubis/hermanubis.prefab @@ -0,0 +1,705 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "Hermanubis", + "Components": { + "Component_[10182366347512475253]": { + "$type": "EditorPrefabComponent", + "Id": 10182366347512475253 + }, + "Component_[12917798267488243668]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12917798267488243668 + }, + "Component_[3261249813163778338]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3261249813163778338 + }, + "Component_[3837204912784440039]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 3837204912784440039 + }, + "Component_[4272963378099646759]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 4272963378099646759, + "Parent Entity": "" + }, + "Component_[4848458548047175816]": { + "$type": "EditorVisibilityComponent", + "Id": 4848458548047175816 + }, + "Component_[5787060997243919943]": { + "$type": "EditorInspectorComponent", + "Id": 5787060997243919943 + }, + "Component_[7804170251266531779]": { + "$type": "EditorLockComponent", + "Id": 7804170251266531779 + }, + "Component_[7874177159288365422]": { + "$type": "EditorEntitySortComponent", + "Id": 7874177159288365422 + }, + "Component_[8018146290632383969]": { + "$type": "EditorEntityIconComponent", + "Id": 8018146290632383969 + }, + "Component_[8452360690590857075]": { + "$type": "SelectionComponent", + "Id": 8452360690590857075 + } + } + }, + "Entities": { + "Entity_[250006174949]": { + "Id": "Entity_[250006174949]", + "Name": "WorldOrigin", + "Components": { + "Component_[13379444112629774116]": { + "$type": "EditorEntityIconComponent", + "Id": 13379444112629774116 + }, + "Component_[13797113876161133062]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 13797113876161133062, + "Parent Entity": "ContainerEntity" + }, + "Component_[16382506042739704306]": { + "$type": "EditorInspectorComponent", + "Id": 16382506042739704306, + "ComponentOrderEntryArray": [ + { + "ComponentId": 13797113876161133062 + }, + { + "ComponentId": 8816319458242680670, + "SortIndex": 1 + } + ] + }, + "Component_[2147729086581105478]": { + "$type": "EditorOnlyEntityComponent", + "Id": 2147729086581105478 + }, + "Component_[2433100672102773575]": { + "$type": "SelectionComponent", + "Id": 2433100672102773575 + }, + "Component_[4832829387489613630]": { + "$type": "EditorVisibilityComponent", + "Id": 4832829387489613630 + }, + "Component_[5585931842723227683]": { + "$type": "EditorEntitySortComponent", + "Id": 5585931842723227683, + "Child Entity Order": [ + "Entity_[254301142245]" + ] + }, + "Component_[7088004383223117498]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 7088004383223117498 + }, + "Component_[7856264459806503732]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7856264459806503732 + }, + "Component_[8816319458242680670]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 8816319458242680670 + }, + "Component_[930042309700959235]": { + "$type": "EditorLockComponent", + "Id": 930042309700959235 + } + } + }, + "Entity_[254301142245]": { + "Id": "Entity_[254301142245]", + "Name": "GlobalSkylight", + "Components": { + "Component_[10076500561520682485]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10076500561520682485, + "Parent Entity": "Entity_[250006174949]" + }, + "Component_[12626877995248630950]": { + "$type": "EditorInspectorComponent", + "Id": 12626877995248630950, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10076500561520682485 + }, + { + "ComponentId": 8158442301445120126, + "SortIndex": 1 + }, + { + "ComponentId": 7260006984216245935, + "SortIndex": 2 + } + ] + }, + "Component_[13040837632921717329]": { + "$type": "SelectionComponent", + "Id": 13040837632921717329 + }, + "Component_[1390505494369101864]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1390505494369101864 + }, + "Component_[6733278858932131836]": { + "$type": "EditorVisibilityComponent", + "Id": 6733278858932131836 + }, + "Component_[7260006984216245935]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 7260006984216245935, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3B78EA69-7CF0-56A7-A49A-110B88412666}", + "subId": 3000 + }, + "assetHint": "lightingpresets/greenwich_park_02_4k_iblskyboxcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3B78EA69-7CF0-56A7-A49A-110B88412666}", + "subId": 2000 + }, + "assetHint": "lightingpresets/greenwich_park_02_4k_iblskyboxcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[7944006745008331817]": { + "$type": "EditorEntitySortComponent", + "Id": 7944006745008331817 + }, + "Component_[8158442301445120126]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 8158442301445120126, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{3B78EA69-7CF0-56A7-A49A-110B88412666}", + "subId": 1000 + }, + "assetHint": "lightingpresets/greenwich_park_02_4k_iblskyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[8255370213772594097]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8255370213772594097 + }, + "Component_[8551180373364097938]": { + "$type": "EditorLockComponent", + "Id": 8551180373364097938 + }, + "Component_[8852330656608249928]": { + "$type": "EditorPendingCompositionComponent", + "Id": 8852330656608249928 + }, + "Component_[8913694496991926693]": { + "$type": "EditorEntityIconComponent", + "Id": 8913694496991926693 + } + } + }, + "Entity_[258596109541]": { + "Id": "Entity_[258596109541]", + "Name": "Hermanubis_stone", + "Components": { + "Component_[1026780512255775175]": { + "$type": "EditorEntityIconComponent", + "Id": 1026780512255775175 + }, + "Component_[10882452951986489612]": { + "$type": "SelectionComponent", + "Id": 10882452951986489612 + }, + "Component_[12454042755417175050]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 12454042755417175050, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{1F650917-AA74-5107-9C49-648C957B33DA}", + "subId": 275904906 + }, + "assetHint": "materialeditor/viewportmodels/hermanubis.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[13691807045809495479]": { + "$type": "EditorMaterialComponent", + "Id": 13691807045809495479, + "Controller": { + "Configuration": { + "materials": { + "{}": { + "MaterialAsset": { + "assetId": { + "guid": "{FF6412B6-F86E-54C8-835C-04F08190D81B}" + }, + "assetHint": "objects/hermanubis/hermanubis_stone.azmaterial" + } + } + } + } + }, + "materialSlotsByLodEnabled": true + }, + "Component_[14490373655742304057]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14490373655742304057 + }, + "Component_[15248132570755287431]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15248132570755287431 + }, + "Component_[16950375358457415777]": { + "$type": "EditorVisibilityComponent", + "Id": 16950375358457415777 + }, + "Component_[17852268252813268496]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17852268252813268496, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 1.1189539432525635, + 0.0, + 0.0 + ] + } + }, + "Component_[3867610358542973898]": { + "$type": "EditorEntitySortComponent", + "Id": 3867610358542973898 + }, + "Component_[7717372065847089412]": { + "$type": "EditorOnlyEntityComponent", + "Id": 7717372065847089412 + }, + "Component_[7783943040473764331]": { + "$type": "EditorInspectorComponent", + "Id": 7783943040473764331, + "ComponentOrderEntryArray": [ + { + "ComponentId": 17852268252813268496 + }, + { + "ComponentId": 12454042755417175050, + "SortIndex": 1 + }, + { + "ComponentId": 13691807045809495479, + "SortIndex": 2 + } + ] + }, + "Component_[833407121913837256]": { + "$type": "EditorLockComponent", + "Id": 833407121913837256 + } + } + }, + "Entity_[262891076837]": { + "Id": "Entity_[262891076837]", + "Name": "Hermanubis_brass", + "Components": { + "Component_[1026780512255775175]": { + "$type": "EditorEntityIconComponent", + "Id": 1026780512255775175 + }, + "Component_[10882452951986489612]": { + "$type": "SelectionComponent", + "Id": 10882452951986489612 + }, + "Component_[12454042755417175050]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 12454042755417175050, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{1F650917-AA74-5107-9C49-648C957B33DA}", + "subId": 275904906 + }, + "assetHint": "materialeditor/viewportmodels/hermanubis.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[13691807045809495479]": { + "$type": "EditorMaterialComponent", + "Id": 13691807045809495479, + "Controller": { + "Configuration": { + "materials": { + "{}": { + "MaterialAsset": { + "assetId": { + "guid": "{B3AC2305-1DE6-54AA-AAD5-5E77C75E5BB5}" + }, + "assetHint": "objects/hermanubis/hermanubis_brass.azmaterial" + } + } + } + } + }, + "materialSlotsByLodEnabled": true + }, + "Component_[14490373655742304057]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14490373655742304057 + }, + "Component_[15248132570755287431]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15248132570755287431 + }, + "Component_[16950375358457415777]": { + "$type": "EditorVisibilityComponent", + "Id": 16950375358457415777 + }, + "Component_[17852268252813268496]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17852268252813268496, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -1.4824472665786743, + -0.034557100385427475, + 0.0 + ] + } + }, + "Component_[3867610358542973898]": { + "$type": "EditorEntitySortComponent", + "Id": 3867610358542973898 + }, + "Component_[7717372065847089412]": { + "$type": "EditorOnlyEntityComponent", + "Id": 7717372065847089412 + }, + "Component_[7783943040473764331]": { + "$type": "EditorInspectorComponent", + "Id": 7783943040473764331, + "ComponentOrderEntryArray": [ + { + "ComponentId": 17852268252813268496 + }, + { + "ComponentId": 12454042755417175050, + "SortIndex": 1 + }, + { + "ComponentId": 13691807045809495479, + "SortIndex": 2 + } + ] + }, + "Component_[833407121913837256]": { + "$type": "EditorLockComponent", + "Id": 833407121913837256 + } + } + }, + "Entity_[267186044133]": { + "Id": "Entity_[267186044133]", + "Name": "SphereLight", + "Components": { + "Component_[10922228943444131599]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10922228943444131599 + }, + "Component_[11625534306113165068]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11625534306113165068, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 0.2636711895465851, + 2.2845842838287354, + 0.22468790411949158 + ] + } + }, + "Component_[12372418243816154216]": { + "$type": "EditorSphereShapeComponent", + "Id": 12372418243816154216, + "ShapeColor": [ + 0.3289234936237335, + 0.7307698130607605, + 0.14859239757061005, + 1.0 + ] + }, + "Component_[12579170654872581897]": { + "$type": "EditorLockComponent", + "Id": 12579170654872581897 + }, + "Component_[12844637542561882557]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12844637542561882557 + }, + "Component_[13087890528096920855]": { + "$type": "EditorInspectorComponent", + "Id": 13087890528096920855, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11625534306113165068 + }, + { + "ComponentId": 13427905514841050195, + "SortIndex": 1 + }, + { + "ComponentId": 12372418243816154216, + "SortIndex": 2 + } + ] + }, + "Component_[13427905514841050195]": { + "$type": "AZ::Render::EditorAreaLightComponent", + "Id": 13427905514841050195, + "Controller": { + "Configuration": { + "LightType": 1, + "Color": [ + 0.3289234936237335, + 0.7307698130607605, + 0.14859239757061005 + ], + "IntensityMode": 1, + "Intensity": 676.7677001953125, + "AttenuationRadius": 226.51287841796875 + } + } + }, + "Component_[15364092815744365073]": { + "$type": "SelectionComponent", + "Id": 15364092815744365073 + }, + "Component_[2481373975540551564]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2481373975540551564 + }, + "Component_[4101167782224846352]": { + "$type": "EditorEntityIconComponent", + "Id": 4101167782224846352 + }, + "Component_[8664715119660216219]": { + "$type": "EditorEntitySortComponent", + "Id": 8664715119660216219 + }, + "Component_[8952093761729701957]": { + "$type": "EditorVisibilityComponent", + "Id": 8952093761729701957, + "VisibilityFlag": false + } + } + }, + "Entity_[275775978725]": { + "Id": "Entity_[275775978725]", + "Name": "TubeLight", + "Components": { + "Component_[10922228943444131599]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10922228943444131599, + "DisabledComponents": [ + { + "$type": "EditorSphereShapeComponent", + "Id": 12372418243816154216, + "ShapeColor": [ + 0.3289234936237335, + 0.7307698130607605, + 0.14859239757061005, + 1.0 + ] + } + ] + }, + "Component_[11625534306113165068]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11625534306113165068, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -4.275930881500244, + 0.5104026794433594, + 2.3807857036590576 + ], + "Rotate": [ + 270.0043029785156, + 0.16617189347743988, + 268.51611328125 + ] + } + }, + "Component_[12579170654872581897]": { + "$type": "EditorLockComponent", + "Id": 12579170654872581897 + }, + "Component_[12844637542561882557]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12844637542561882557 + }, + "Component_[13087890528096920855]": { + "$type": "EditorInspectorComponent", + "Id": 13087890528096920855, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11625534306113165068 + }, + { + "ComponentId": 13427905514841050195, + "SortIndex": 1 + }, + { + "ComponentId": 12372418243816154216, + "SortIndex": 2 + }, + { + "ComponentId": 2193911499802409037, + "SortIndex": 3 + } + ] + }, + "Component_[13427905514841050195]": { + "$type": "AZ::Render::EditorAreaLightComponent", + "Id": 13427905514841050195, + "Controller": { + "Configuration": { + "LightType": 3, + "Color": [ + 0.8521705865859985, + 0.7865872979164124, + 0.6079347133636475 + ], + "IntensityMode": 1, + "Intensity": 10000.0, + "AttenuationRadius": 21608.193359375 + } + } + }, + "Component_[15364092815744365073]": { + "$type": "SelectionComponent", + "Id": 15364092815744365073 + }, + "Component_[2193911499802409037]": { + "$type": "EditorCapsuleShapeComponent", + "Id": 2193911499802409037, + "ShapeColor": [ + 0.8521705865859985, + 0.7865872979164124, + 0.6079347133636475, + 1.0 + ], + "CapsuleShape": { + "Configuration": { + "Height": 5.0, + "Radius": 0.10000000149011612 + } + } + }, + "Component_[2481373975540551564]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2481373975540551564 + }, + "Component_[4101167782224846352]": { + "$type": "EditorEntityIconComponent", + "Id": 4101167782224846352 + }, + "Component_[8664715119660216219]": { + "$type": "EditorEntitySortComponent", + "Id": 8664715119660216219 + }, + "Component_[8952093761729701957]": { + "$type": "EditorVisibilityComponent", + "Id": 8952093761729701957, + "VisibilityFlag": false + } + } + }, + "Entity_[482743502241]": { + "Id": "Entity_[482743502241]", + "Name": "Camera1", + "Components": { + "Component_[10672707967016183310]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10672707967016183310 + }, + "Component_[13520081755303040361]": { + "$type": "EditorLockComponent", + "Id": 13520081755303040361 + }, + "Component_[13650522584195762912]": { + "$type": "SelectionComponent", + "Id": 13650522584195762912 + }, + "Component_[14204465933176839167]": { + "$type": "EditorOnlyEntityComponent", + "Id": 14204465933176839167 + }, + "Component_[14509697511269710983]": { + "$type": "EditorEntitySortComponent", + "Id": 14509697511269710983 + }, + "Component_[271930369355383880]": { + "$type": "EditorEntityIconComponent", + "Id": 271930369355383880 + }, + "Component_[5015186380056948439]": { + "$type": "EditorInspectorComponent", + "Id": 5015186380056948439 + }, + "Component_[6297637832938894772]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6297637832938894772, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -0.0018702250672504306, + 2.9982283115386963, + 3.0017592906951904 + ], + "Rotate": [ + 20.080352783203125, + -0.020488755777478218, + 179.92381286621094 + ] + } + }, + "Component_[6611378759823339947]": { + "$type": "EditorPendingCompositionComponent", + "Id": 6611378759823339947 + }, + "Component_[8475839846509409509]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 8475839846509409509, + "Controller": { + "Configuration": { + "Field of View": 90.00020599365234, + "EditorEntityId": 478448534945 + } + } + }, + "Component_[9659542522325095386]": { + "$type": "EditorVisibilityComponent", + "Id": 9659542522325095386 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Sponza/tags.txt b/AutomatedTesting/Levels/Graphics/hermanubis/tags.txt similarity index 100% rename from AutomatedTesting/Levels/Sponza/tags.txt rename to AutomatedTesting/Levels/Graphics/hermanubis/tags.txt diff --git a/AutomatedTesting/Levels/Graphics/hermanubis_high/hermanubis_high.prefab b/AutomatedTesting/Levels/Graphics/hermanubis_high/hermanubis_high.prefab new file mode 100644 index 0000000000..3378a0c144 --- /dev/null +++ b/AutomatedTesting/Levels/Graphics/hermanubis_high/hermanubis_high.prefab @@ -0,0 +1,943 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "hermanubis_high", + "Components": { + "Component_[10182366347512475253]": { + "$type": "EditorPrefabComponent", + "Id": 10182366347512475253 + }, + "Component_[12917798267488243668]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12917798267488243668 + }, + "Component_[3261249813163778338]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3261249813163778338 + }, + "Component_[3837204912784440039]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 3837204912784440039 + }, + "Component_[4272963378099646759]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 4272963378099646759, + "Parent Entity": "" + }, + "Component_[4848458548047175816]": { + "$type": "EditorVisibilityComponent", + "Id": 4848458548047175816 + }, + "Component_[5787060997243919943]": { + "$type": "EditorInspectorComponent", + "Id": 5787060997243919943 + }, + "Component_[7804170251266531779]": { + "$type": "EditorLockComponent", + "Id": 7804170251266531779 + }, + "Component_[7874177159288365422]": { + "$type": "EditorEntitySortComponent", + "Id": 7874177159288365422, + "Child Entity Order": [ + "Entity_[243647107259]", + "Entity_[247179151093]", + "Entity_[262891076837]", + "Entity_[242884183797]", + "Entity_[258596109541]", + "Entity_[267186044133]", + "Entity_[275775978725]", + "Entity_[250006174949]" + ] + }, + "Component_[8018146290632383969]": { + "$type": "EditorEntityIconComponent", + "Id": 8018146290632383969 + }, + "Component_[8452360690590857075]": { + "$type": "SelectionComponent", + "Id": 8452360690590857075 + } + } + }, + "Entities": { + "Entity_[242884183797]": { + "Id": "Entity_[242884183797]", + "Name": "Hermanubis_stone", + "Components": { + "Component_[1026780512255775175]": { + "$type": "EditorEntityIconComponent", + "Id": 1026780512255775175 + }, + "Component_[10882452951986489612]": { + "$type": "SelectionComponent", + "Id": 10882452951986489612 + }, + "Component_[12454042755417175050]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 12454042755417175050, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{35A45F31-F1C1-5076-8B51-FF599E2EEBAA}", + "subId": 274433667 + }, + "assetHint": "objects/hermanubis/hermanubis_high.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[13691807045809495479]": { + "$type": "EditorMaterialComponent", + "Id": 13691807045809495479, + "Controller": { + "Configuration": { + "materials": { + "{}": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + } + }, + "materialSlotsByLodEnabled": true + }, + "Component_[14490373655742304057]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14490373655742304057 + }, + "Component_[15248132570755287431]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15248132570755287431 + }, + "Component_[16950375358457415777]": { + "$type": "EditorVisibilityComponent", + "Id": 16950375358457415777 + }, + "Component_[17852268252813268496]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17852268252813268496, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 3.810185432434082, + 0.0, + 0.0 + ] + } + }, + "Component_[3867610358542973898]": { + "$type": "EditorEntitySortComponent", + "Id": 3867610358542973898 + }, + "Component_[7717372065847089412]": { + "$type": "EditorOnlyEntityComponent", + "Id": 7717372065847089412 + }, + "Component_[7783943040473764331]": { + "$type": "EditorInspectorComponent", + "Id": 7783943040473764331, + "ComponentOrderEntryArray": [ + { + "ComponentId": 17852268252813268496 + }, + { + "ComponentId": 12454042755417175050, + "SortIndex": 1 + }, + { + "ComponentId": 13691807045809495479, + "SortIndex": 2 + } + ] + }, + "Component_[833407121913837256]": { + "$type": "EditorLockComponent", + "Id": 833407121913837256 + } + } + }, + "Entity_[243647107259]": { + "Id": "Entity_[243647107259]", + "Name": "Camera1", + "Components": { + "Component_[11276153162797125616]": { + "$type": "GenericComponentWrapper", + "Id": 11276153162797125616, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[11484120648160206262]": { + "$type": "EditorLockComponent", + "Id": 11484120648160206262 + }, + "Component_[14251459960897306807]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 14251459960897306807, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -0.10533800721168518, + -4.001697063446045, + 3.061025619506836 + ], + "Rotate": [ + -19.998117446899414, + 0.01881762035191059, + -0.051706261932849884 + ], + "Scale": [ + 0.9999998807907104, + 1.0, + 1.0 + ] + } + }, + "Component_[149351061984148634]": { + "$type": "EditorOnlyEntityComponent", + "Id": 149351061984148634 + }, + "Component_[15121925351155689107]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 15121925351155689107, + "Controller": { + "Configuration": { + "EditorEntityId": 243647107259 + } + } + }, + "Component_[15327903729148812780]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15327903729148812780 + }, + "Component_[17667820301809320373]": { + "$type": "EditorEntityIconComponent", + "Id": 17667820301809320373 + }, + "Component_[17708351813187009272]": { + "$type": "EditorVisibilityComponent", + "Id": 17708351813187009272 + }, + "Component_[17941668830905411554]": { + "$type": "SelectionComponent", + "Id": 17941668830905411554 + }, + "Component_[48451466091772435]": { + "$type": "EditorEntitySortComponent", + "Id": 48451466091772435 + }, + "Component_[6163614082436403601]": { + "$type": "EditorInspectorComponent", + "Id": 6163614082436403601, + "ComponentOrderEntryArray": [ + { + "ComponentId": 14251459960897306807 + }, + { + "ComponentId": 15121925351155689107, + "SortIndex": 1 + }, + { + "ComponentId": 11935019334576395684, + "SortIndex": 2 + } + ] + }, + "Component_[8660334631968180943]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8660334631968180943 + } + } + }, + "Entity_[247179151093]": { + "Id": "Entity_[247179151093]", + "Name": "Hermanubis_brass", + "Components": { + "Component_[1026780512255775175]": { + "$type": "EditorEntityIconComponent", + "Id": 1026780512255775175 + }, + "Component_[10882452951986489612]": { + "$type": "SelectionComponent", + "Id": 10882452951986489612 + }, + "Component_[12454042755417175050]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 12454042755417175050, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{35A45F31-F1C1-5076-8B51-FF599E2EEBAA}", + "subId": 274433667 + }, + "assetHint": "objects/hermanubis/hermanubis_high.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[13691807045809495479]": { + "$type": "EditorMaterialComponent", + "Id": 13691807045809495479, + "Controller": { + "Configuration": { + "materials": { + "{}": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + } + }, + "materialSlotsByLodEnabled": true + }, + "Component_[14490373655742304057]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14490373655742304057 + }, + "Component_[15248132570755287431]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15248132570755287431 + }, + "Component_[16950375358457415777]": { + "$type": "EditorVisibilityComponent", + "Id": 16950375358457415777 + }, + "Component_[17852268252813268496]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17852268252813268496, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -4.019397258758545, + -0.034557100385427475, + 0.0 + ] + } + }, + "Component_[3867610358542973898]": { + "$type": "EditorEntitySortComponent", + "Id": 3867610358542973898 + }, + "Component_[7717372065847089412]": { + "$type": "EditorOnlyEntityComponent", + "Id": 7717372065847089412 + }, + "Component_[7783943040473764331]": { + "$type": "EditorInspectorComponent", + "Id": 7783943040473764331, + "ComponentOrderEntryArray": [ + { + "ComponentId": 17852268252813268496 + }, + { + "ComponentId": 12454042755417175050, + "SortIndex": 1 + }, + { + "ComponentId": 13691807045809495479, + "SortIndex": 2 + } + ] + }, + "Component_[833407121913837256]": { + "$type": "EditorLockComponent", + "Id": 833407121913837256 + } + } + }, + "Entity_[250006174949]": { + "Id": "Entity_[250006174949]", + "Name": "WorldOrigin", + "Components": { + "Component_[13379444112629774116]": { + "$type": "EditorEntityIconComponent", + "Id": 13379444112629774116 + }, + "Component_[13797113876161133062]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 13797113876161133062, + "Parent Entity": "ContainerEntity" + }, + "Component_[16382506042739704306]": { + "$type": "EditorInspectorComponent", + "Id": 16382506042739704306, + "ComponentOrderEntryArray": [ + { + "ComponentId": 13797113876161133062 + }, + { + "ComponentId": 8816319458242680670, + "SortIndex": 1 + } + ] + }, + "Component_[2147729086581105478]": { + "$type": "EditorOnlyEntityComponent", + "Id": 2147729086581105478 + }, + "Component_[2433100672102773575]": { + "$type": "SelectionComponent", + "Id": 2433100672102773575 + }, + "Component_[4832829387489613630]": { + "$type": "EditorVisibilityComponent", + "Id": 4832829387489613630 + }, + "Component_[5585931842723227683]": { + "$type": "EditorEntitySortComponent", + "Id": 5585931842723227683, + "Child Entity Order": [ + "Entity_[254301142245]" + ] + }, + "Component_[7088004383223117498]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 7088004383223117498 + }, + "Component_[7856264459806503732]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7856264459806503732 + }, + "Component_[8816319458242680670]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 8816319458242680670 + }, + "Component_[930042309700959235]": { + "$type": "EditorLockComponent", + "Id": 930042309700959235 + } + } + }, + "Entity_[254301142245]": { + "Id": "Entity_[254301142245]", + "Name": "GlobalSkylight", + "Components": { + "Component_[10076500561520682485]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10076500561520682485, + "Parent Entity": "Entity_[250006174949]" + }, + "Component_[12626877995248630950]": { + "$type": "EditorInspectorComponent", + "Id": 12626877995248630950, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10076500561520682485 + }, + { + "ComponentId": 8158442301445120126, + "SortIndex": 1 + }, + { + "ComponentId": 7260006984216245935, + "SortIndex": 2 + } + ] + }, + "Component_[13040837632921717329]": { + "$type": "SelectionComponent", + "Id": 13040837632921717329 + }, + "Component_[1390505494369101864]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1390505494369101864 + }, + "Component_[6733278858932131836]": { + "$type": "EditorVisibilityComponent", + "Id": 6733278858932131836 + }, + "Component_[7260006984216245935]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 7260006984216245935, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3B78EA69-7CF0-56A7-A49A-110B88412666}", + "subId": 3000 + }, + "assetHint": "lightingpresets/greenwich_park_02_4k_iblskyboxcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3B78EA69-7CF0-56A7-A49A-110B88412666}", + "subId": 2000 + }, + "assetHint": "lightingpresets/greenwich_park_02_4k_iblskyboxcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[7944006745008331817]": { + "$type": "EditorEntitySortComponent", + "Id": 7944006745008331817 + }, + "Component_[8158442301445120126]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 8158442301445120126, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{3B78EA69-7CF0-56A7-A49A-110B88412666}", + "subId": 1000 + }, + "assetHint": "lightingpresets/greenwich_park_02_4k_iblskyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[8255370213772594097]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8255370213772594097 + }, + "Component_[8551180373364097938]": { + "$type": "EditorLockComponent", + "Id": 8551180373364097938 + }, + "Component_[8852330656608249928]": { + "$type": "EditorPendingCompositionComponent", + "Id": 8852330656608249928 + }, + "Component_[8913694496991926693]": { + "$type": "EditorEntityIconComponent", + "Id": 8913694496991926693 + } + } + }, + "Entity_[258596109541]": { + "Id": "Entity_[258596109541]", + "Name": "Hermanubis_stone", + "Components": { + "Component_[1026780512255775175]": { + "$type": "EditorEntityIconComponent", + "Id": 1026780512255775175 + }, + "Component_[10882452951986489612]": { + "$type": "SelectionComponent", + "Id": 10882452951986489612 + }, + "Component_[12454042755417175050]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 12454042755417175050, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{35A45F31-F1C1-5076-8B51-FF599E2EEBAA}", + "subId": 274433667 + }, + "assetHint": "objects/hermanubis/hermanubis_high.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[13691807045809495479]": { + "$type": "EditorMaterialComponent", + "Id": 13691807045809495479, + "Controller": { + "Configuration": { + "materials": { + "{}": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + } + }, + "materialSlotsByLodEnabled": true + }, + "Component_[14490373655742304057]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14490373655742304057 + }, + "Component_[15248132570755287431]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15248132570755287431 + }, + "Component_[16950375358457415777]": { + "$type": "EditorVisibilityComponent", + "Id": 16950375358457415777 + }, + "Component_[17852268252813268496]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17852268252813268496, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 1.1189539432525635, + 0.0, + 0.0 + ] + } + }, + "Component_[3867610358542973898]": { + "$type": "EditorEntitySortComponent", + "Id": 3867610358542973898 + }, + "Component_[7717372065847089412]": { + "$type": "EditorOnlyEntityComponent", + "Id": 7717372065847089412 + }, + "Component_[7783943040473764331]": { + "$type": "EditorInspectorComponent", + "Id": 7783943040473764331, + "ComponentOrderEntryArray": [ + { + "ComponentId": 17852268252813268496 + }, + { + "ComponentId": 12454042755417175050, + "SortIndex": 1 + }, + { + "ComponentId": 13691807045809495479, + "SortIndex": 2 + } + ] + }, + "Component_[833407121913837256]": { + "$type": "EditorLockComponent", + "Id": 833407121913837256 + } + } + }, + "Entity_[262891076837]": { + "Id": "Entity_[262891076837]", + "Name": "Hermanubis_brass", + "Components": { + "Component_[1026780512255775175]": { + "$type": "EditorEntityIconComponent", + "Id": 1026780512255775175 + }, + "Component_[10882452951986489612]": { + "$type": "SelectionComponent", + "Id": 10882452951986489612 + }, + "Component_[12454042755417175050]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 12454042755417175050, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{35A45F31-F1C1-5076-8B51-FF599E2EEBAA}", + "subId": 274433667 + }, + "assetHint": "objects/hermanubis/hermanubis_high.azmodel" + }, + "LodOverride": 255 + } + } + }, + "Component_[13691807045809495479]": { + "$type": "EditorMaterialComponent", + "Id": 13691807045809495479, + "Controller": { + "Configuration": { + "materials": { + "{}": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + } + }, + "materialSlotsByLodEnabled": true + }, + "Component_[14490373655742304057]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14490373655742304057 + }, + "Component_[15248132570755287431]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15248132570755287431 + }, + "Component_[16950375358457415777]": { + "$type": "EditorVisibilityComponent", + "Id": 16950375358457415777 + }, + "Component_[17852268252813268496]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17852268252813268496, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -1.4824472665786743, + -0.034557100385427475, + 0.0 + ] + } + }, + "Component_[3867610358542973898]": { + "$type": "EditorEntitySortComponent", + "Id": 3867610358542973898 + }, + "Component_[7717372065847089412]": { + "$type": "EditorOnlyEntityComponent", + "Id": 7717372065847089412 + }, + "Component_[7783943040473764331]": { + "$type": "EditorInspectorComponent", + "Id": 7783943040473764331, + "ComponentOrderEntryArray": [ + { + "ComponentId": 17852268252813268496 + }, + { + "ComponentId": 12454042755417175050, + "SortIndex": 1 + }, + { + "ComponentId": 13691807045809495479, + "SortIndex": 2 + } + ] + }, + "Component_[833407121913837256]": { + "$type": "EditorLockComponent", + "Id": 833407121913837256 + } + } + }, + "Entity_[267186044133]": { + "Id": "Entity_[267186044133]", + "Name": "SphereLight", + "Components": { + "Component_[10922228943444131599]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10922228943444131599 + }, + "Component_[11625534306113165068]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11625534306113165068, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 0.2636711895465851, + 2.2845842838287354, + 0.22468790411949158 + ] + } + }, + "Component_[12372418243816154216]": { + "$type": "EditorSphereShapeComponent", + "Id": 12372418243816154216, + "ShapeColor": [ + 0.3289234936237335, + 0.7307698130607605, + 0.14859239757061005, + 1.0 + ] + }, + "Component_[12579170654872581897]": { + "$type": "EditorLockComponent", + "Id": 12579170654872581897 + }, + "Component_[12844637542561882557]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12844637542561882557 + }, + "Component_[13087890528096920855]": { + "$type": "EditorInspectorComponent", + "Id": 13087890528096920855, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11625534306113165068 + }, + { + "ComponentId": 13427905514841050195, + "SortIndex": 1 + }, + { + "ComponentId": 12372418243816154216, + "SortIndex": 2 + } + ] + }, + "Component_[13427905514841050195]": { + "$type": "AZ::Render::EditorAreaLightComponent", + "Id": 13427905514841050195, + "Controller": { + "Configuration": { + "LightType": 1, + "Color": [ + 0.3289234936237335, + 0.7307698130607605, + 0.14859239757061005 + ], + "IntensityMode": 1, + "Intensity": 676.7677001953125, + "AttenuationRadius": 226.51287841796875 + } + } + }, + "Component_[15364092815744365073]": { + "$type": "SelectionComponent", + "Id": 15364092815744365073 + }, + "Component_[2481373975540551564]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2481373975540551564 + }, + "Component_[4101167782224846352]": { + "$type": "EditorEntityIconComponent", + "Id": 4101167782224846352 + }, + "Component_[8664715119660216219]": { + "$type": "EditorEntitySortComponent", + "Id": 8664715119660216219 + }, + "Component_[8952093761729701957]": { + "$type": "EditorVisibilityComponent", + "Id": 8952093761729701957, + "VisibilityFlag": false + } + } + }, + "Entity_[275775978725]": { + "Id": "Entity_[275775978725]", + "Name": "TubeLight", + "Components": { + "Component_[10922228943444131599]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10922228943444131599, + "DisabledComponents": [ + { + "$type": "EditorSphereShapeComponent", + "Id": 12372418243816154216, + "ShapeColor": [ + 0.3289234936237335, + 0.7307698130607605, + 0.14859239757061005, + 1.0 + ] + } + ] + }, + "Component_[11625534306113165068]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11625534306113165068, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -4.275930881500244, + 0.5104026794433594, + 2.3807857036590576 + ], + "Rotate": [ + 270.0043029785156, + 0.16617189347743988, + 268.51611328125 + ] + } + }, + "Component_[12579170654872581897]": { + "$type": "EditorLockComponent", + "Id": 12579170654872581897 + }, + "Component_[12844637542561882557]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12844637542561882557 + }, + "Component_[13087890528096920855]": { + "$type": "EditorInspectorComponent", + "Id": 13087890528096920855, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11625534306113165068 + }, + { + "ComponentId": 13427905514841050195, + "SortIndex": 1 + }, + { + "ComponentId": 12372418243816154216, + "SortIndex": 2 + }, + { + "ComponentId": 2193911499802409037, + "SortIndex": 3 + } + ] + }, + "Component_[13427905514841050195]": { + "$type": "AZ::Render::EditorAreaLightComponent", + "Id": 13427905514841050195, + "Controller": { + "Configuration": { + "LightType": 3, + "Color": [ + 0.8521705865859985, + 0.7865872979164124, + 0.6079347133636475 + ], + "IntensityMode": 1, + "Intensity": 10000.0, + "AttenuationRadius": 21608.193359375 + } + } + }, + "Component_[15364092815744365073]": { + "$type": "SelectionComponent", + "Id": 15364092815744365073 + }, + "Component_[2193911499802409037]": { + "$type": "EditorCapsuleShapeComponent", + "Id": 2193911499802409037, + "ShapeColor": [ + 0.8521705865859985, + 0.7865872979164124, + 0.6079347133636475, + 1.0 + ], + "CapsuleShape": { + "Configuration": { + "Height": 5.0, + "Radius": 0.10000000149011612 + } + } + }, + "Component_[2481373975540551564]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2481373975540551564 + }, + "Component_[4101167782224846352]": { + "$type": "EditorEntityIconComponent", + "Id": 4101167782224846352 + }, + "Component_[8664715119660216219]": { + "$type": "EditorEntitySortComponent", + "Id": 8664715119660216219 + }, + "Component_[8952093761729701957]": { + "$type": "EditorVisibilityComponent", + "Id": 8952093761729701957, + "VisibilityFlag": false + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/macbeth_shaderballs/tags.txt b/AutomatedTesting/Levels/Graphics/hermanubis_high/tags.txt similarity index 100% rename from AutomatedTesting/Levels/macbeth_shaderballs/tags.txt rename to AutomatedTesting/Levels/Graphics/hermanubis_high/tags.txt diff --git a/AutomatedTesting/Levels/macbeth_shaderballs/macbeth_shaderballs.prefab b/AutomatedTesting/Levels/Graphics/macbeth_shaderballs/macbeth_shaderballs.prefab similarity index 100% rename from AutomatedTesting/Levels/macbeth_shaderballs/macbeth_shaderballs.prefab rename to AutomatedTesting/Levels/Graphics/macbeth_shaderballs/macbeth_shaderballs.prefab diff --git a/AutomatedTesting/Levels/Graphics/macbeth_shaderballs/tags.txt b/AutomatedTesting/Levels/Graphics/macbeth_shaderballs/tags.txt new file mode 100644 index 0000000000..0d6c1880e7 --- /dev/null +++ b/AutomatedTesting/Levels/Graphics/macbeth_shaderballs/tags.txt @@ -0,0 +1,12 @@ +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 diff --git a/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC.prefab b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC.prefab new file mode 100644 index 0000000000..758cb4fca8 --- /dev/null +++ b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC.prefab @@ -0,0 +1,747 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]", + "Entity_[12685882829720]", + "Entity_[31145534614197]" + ] + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 11050384689878106598 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1172344194419]": { + "Id": "Entity_[1172344194419]", + "Name": "Shader Ball", + "Components": { + "Component_[10789351944715265527]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10789351944715265527 + }, + "Component_[12037033284781049225]": { + "$type": "EditorEntitySortComponent", + "Id": 12037033284781049225 + }, + "Component_[13759153306105970079]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13759153306105970079 + }, + "Component_[14135560884830586279]": { + "$type": "EditorInspectorComponent", + "Id": 14135560884830586279 + }, + "Component_[16247165675903986673]": { + "$type": "EditorVisibilityComponent", + "Id": 16247165675903986673 + }, + "Component_[18082433625958885247]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18082433625958885247 + }, + "Component_[6472623349872972660]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6472623349872972660, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Rotate": [ + 0.0, + 0.10000000149011612, + 180.0 + ] + } + }, + "Component_[6495255223970673916]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 6495255223970673916, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{FD340C30-755C-5911-92A3-19A3F7A77931}", + "subId": 281415304 + }, + "assetHint": "objects/shaderball/shaderball_default_1m.azmodel" + } + } + } + }, + "Component_[8056625192494070973]": { + "$type": "SelectionComponent", + "Id": 8056625192494070973 + }, + "Component_[8550141614185782969]": { + "$type": "EditorEntityIconComponent", + "Id": 8550141614185782969 + }, + "Component_[9439770997198325425]": { + "$type": "EditorLockComponent", + "Id": 9439770997198325425 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1172344194419]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11231930600558681245]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 11231930600558681245, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + }, + "Entity_[12685882829720]": { + "Id": "Entity_[12685882829720]", + "Name": "GlobalGameData", + "Components": { + "Component_[11240656689650225106]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 11240656689650225106 + }, + "Component_[13863201640354873385]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13863201640354873385 + }, + "Component_[14671754037021562789]": { + "$type": "EditorInspectorComponent", + "Id": 14671754037021562789 + }, + "Component_[14750978061505735417]": { + "$type": "EditorScriptCanvasComponent", + "Id": 14750978061505735417, + "m_name": "GlobalGameData", + "m_assetHolder": { + "m_asset": { + "assetId": { + "guid": "{B16589A0-EA01-56BC-8141-91A3967FB95F}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/globalgamedata.scriptcanvas" + } + }, + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "assetId": { + "guid": "{B16589A0-EA01-56BC-8141-91A3967FB95F}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/globalgamedata.scriptcanvas" + } + } + }, + "Component_[16436925042043744033]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16436925042043744033, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 0.0, + 0.10000038146972656, + 4.005393981933594 + ] + } + }, + "Component_[16974524495698916088]": { + "$type": "EditorOnlyEntityComponent", + "Id": 16974524495698916088 + }, + "Component_[2753700837834389204]": { + "$type": "EditorLockComponent", + "Id": 2753700837834389204 + }, + "Component_[3766473509503096065]": { + "$type": "SelectionComponent", + "Id": 3766473509503096065 + }, + "Component_[4025955184206569130]": { + "$type": "EditorEntitySortComponent", + "Id": 4025955184206569130 + }, + "Component_[7909743395732791573]": { + "$type": "EditorVisibilityComponent", + "Id": 7909743395732791573 + }, + "Component_[9550161640684119498]": { + "$type": "EditorEntityIconComponent", + "Id": 9550161640684119498 + } + } + }, + "Entity_[31145534614197]": { + "Id": "Entity_[31145534614197]", + "Name": "NetLevelEntity", + "Components": { + "Component_[12132849363414901338]": { + "$type": "EditorEntityIconComponent", + "Id": 12132849363414901338 + }, + "Component_[12302672911455629152]": { + "$type": "SelectionComponent", + "Id": 12302672911455629152 + }, + "Component_[14169903623243423134]": { + "$type": "EditorVisibilityComponent", + "Id": 14169903623243423134 + }, + "Component_[14607413934411389854]": { + "$type": "EditorInspectorComponent", + "Id": 14607413934411389854 + }, + "Component_[15396284312416541768]": { + "$type": "GenericComponentWrapper", + "Id": 15396284312416541768, + "m_template": { + "$type": "Multiplayer::LocalPredictionPlayerInputComponent" + } + }, + "Component_[15494977028055234270]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15494977028055234270 + }, + "Component_[16325088972532345964]": { + "$type": "EditorLockComponent", + "Id": 16325088972532345964 + }, + "Component_[1986030426392465743]": { + "$type": "EditorEntitySortComponent", + "Id": 1986030426392465743 + }, + "Component_[4591476848838823508]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 4591476848838823508, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{80FA8BAF-4A5B-5937-9679-2E592E841A3A}", + "subId": 275306041 + }, + "assetHint": "assets/physics/collider_pxmeshautoassigned/spherebot/r0-b_body.azmodel" + } + } + } + }, + "Component_[7256163899440301540]": { + "$type": "EditorScriptCanvasComponent", + "Id": 7256163899440301540, + "m_name": "AutoComponent_RPC_NetLevelEntity", + "m_assetHolder": { + "m_asset": { + "assetId": { + "guid": "{1D517006-AC01-5ECA-AE66-0E007871F0CD}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/autocomponent_rpc_netlevelentity.scriptcanvas" + } + }, + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "assetId": { + "guid": "{1D517006-AC01-5ECA-AE66-0E007871F0CD}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/autocomponent_rpc_netlevelentity.scriptcanvas" + } + } + }, + "Component_[731336627222243355]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 731336627222243355, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 2.561863899230957, + -1.038161277770996, + 0.1487259864807129 + ] + } + }, + "Component_[8012379125499217348]": { + "$type": "EditorPendingCompositionComponent", + "Id": 8012379125499217348 + }, + "Component_[8122568562140740597]": { + "$type": "GenericComponentWrapper", + "Id": 8122568562140740597, + "m_template": { + "$type": "Multiplayer::NetworkTransformComponent" + } + }, + "Component_[8805228647591404845]": { + "$type": "GenericComponentWrapper", + "Id": 8805228647591404845, + "m_template": { + "$type": "NetBindComponent" + } + }, + "Component_[9816897251206708579]": { + "$type": "GenericComponentWrapper", + "Id": 9816897251206708579, + "m_template": { + "$type": "AutomatedTesting::NetworkTestPlayerComponent" + } + }, + "Component_[9880860858035405475]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9880860858035405475 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC.scriptcanvas b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC.scriptcanvas new file mode 100644 index 0000000000..c1c77b14fe --- /dev/null +++ b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC.scriptcanvas @@ -0,0 +1,5019 @@ +{ + "Type": "JsonSerialization", + "Version": 1, + "ClassName": "ScriptCanvasData", + "ClassData": { + "m_scriptCanvas": { + "Id": { + "id": 2816238339133127497 + }, + "Name": "AutoComponent_RPC", + "Components": { + "Component_[6790521910463264404]": { + "$type": "EditorGraphVariableManagerComponent", + "Id": 6790521910463264404, + "m_variableData": { + "m_nameVariableMap": [ + { + "Key": { + "m_id": "{71675BCB-6546-4B79-9D5E-912982945852}" + }, + "Value": { + "Datum": { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 0.0 + }, + "VariableId": { + "m_id": "{71675BCB-6546-4B79-9D5E-912982945852}" + }, + "VariableName": "PlayerNumber" + } + } + ] + } + }, + "Component_[9755768666831861951]": { + "$type": "{4D755CA9-AB92-462C-B24F-0B3376F19967} Graph", + "Id": 9755768666831861951, + "m_graphData": { + "m_nodes": [ + { + "Id": { + "id": 8706984967056 + }, + "Name": "SC-EventNode(AuthorityToAutonomous_PlayerNumber Notify Event)", + "Components": { + "Component_[10688723972761024546]": { + "$type": "AzEventHandler", + "Id": 10688723972761024546, + "Slots": [ + { + "id": { + "m_id": "{46E6B649-CAA4-4318-960D-5E4854E21BB2}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + }, + { + "$type": "ConnectionLimitContract", + "limit": 1 + }, + { + "$type": "RestrictedNodeContract", + "m_nodeId": { + "id": 8719869868944 + } + } + ], + "slotName": "Connect", + "toolTip": "Connect the AZ Event to this AZ Event Handler.", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{221AFED2-BD9E-4CFF-8EC7-75ABA019134D}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Disconnect", + "toolTip": "Disconnect current AZ Event from this AZ Event Handler.", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{D139A8D2-F57B-4EBF-B7F8-1D65C2D97C25}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "On Connected", + "toolTip": "Signaled when a connection has taken place.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{3F47A140-182E-4B32-AE14-467555A6640A}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "On Disconnected", + "toolTip": "Signaled when this event handler is disconnected.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{586BE222-2DEA-4E08-968F-07CA4EB96C54}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "OnEvent", + "toolTip": "Triggered when the AZ Event invokes Signal() function.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + }, + "IsLatent": true + }, + { + "id": { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "player_number", + "DisplayDataType": { + "m_type": 3 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{8C7E88EA-8FEE-45D0-9A2E-78BC4A18F508}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + }, + { + "$type": "ConnectionLimitContract", + "limit": 1 + }, + { + "$type": "RestrictedNodeContract", + "m_nodeId": { + "id": 8719869868944 + } + } + ], + "slotName": "AuthorityToAutonomous_PlayerNumber Notify Event", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 4, + "m_azType": "{DB613438-34F0-5B2E-A413-77424F4254CD}" + }, + "isNullPointer": true, + "label": "AuthorityToAutonomous_PlayerNumber Notify Event" + } + ], + "m_azEventEntry": { + "m_eventName": "AuthorityToAutonomous_PlayerNumber Notify Event", + "m_parameterSlotIds": [ + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + } + ], + "m_parameterNames": [ + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + }, + { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + } + ], + "m_eventSlotId": { + "m_id": "{8C7E88EA-8FEE-45D0-9A2E-78BC4A18F508}" + } + } + } + } + }, + { + "Id": { + "id": 8724164836240 + }, + "Name": "SC-Node(IsNetEntityRoleAuthority)", + "Components": { + "Component_[11076422520044215441]": { + "$type": "{E42861BD-1956-45AE-8DD7-CCFC1E3E5ACF} Method", + "Id": 11076422520044215441, + "Slots": [ + { + "id": { + "m_id": "{4EAB8D16-C0B4-44E1-885D-8E6754CD1A55}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "EntityId: 0", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{B6C4BE5E-CDE4-4EC7-98D0-A019CD80041C}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{1071F455-D5A0-4C7A-AF91-648A0F197885}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{BA87B4ED-9A52-4A0D-8920-CD0ED4E839EA}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Is Role Authority", + "DisplayDataType": { + "m_type": 0 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 2 + }, + "DataType": 1 + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 1 + }, + "isNullPointer": false, + "$type": "EntityId", + "value": { + "id": 2901262558 + }, + "label": "Entity Id" + } + ], + "methodType": 2, + "methodName": "IsNetEntityRoleAuthority", + "className": "NetBindComponent", + "resultSlotIDs": [ + {} + ], + "inputSlots": [ + { + "m_id": "{4EAB8D16-C0B4-44E1-885D-8E6754CD1A55}" + } + ], + "prettyClassName": "NetBindComponent" + } + } + }, + { + "Id": { + "id": 8737049738128 + }, + "Name": "SC-Node(Print)", + "Components": { + "Component_[15185116749844245504]": { + "$type": "Print", + "Id": 15185116749844245504, + "Slots": [ + { + "id": { + "m_id": "{F3ED8C08-D751-492A-A39A-7B7734727A5A}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "toolTip": "Input signal", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{D4FA5CCA-34FB-412B-826E-BC7050E684A6}" + }, + "DynamicTypeOverride": 3, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Value", + "toolTip": "Value which replaces instances of {Value} in the resulting string.", + "DisplayDataType": { + "m_type": 3 + }, + "DisplayGroup": { + "Value": 1015031923 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1, + "IsReference": true, + "VariableReference": { + "m_id": "{71675BCB-6546-4B79-9D5E-912982945852}" + } + }, + { + "id": { + "m_id": "{5A4FB037-120E-4BF8-A170-D827E5DC161B}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 0.0, + "label": "Value" + } + ], + "m_format": "AutoComponent_RPC: Sending client PlayerNumber {Value}\n", + "m_numericPrecision": 0, + "m_arrayBindingMap": [ + { + "Key": 1, + "Value": { + "m_id": "{D4FA5CCA-34FB-412B-826E-BC7050E684A6}" + } + } + ], + "m_unresolvedString": [ + "AutoComponent_RPC: Sending client PlayerNumber ", + {}, + "\n" + ], + "m_formatSlotMap": { + "Value": { + "m_id": "{D4FA5CCA-34FB-412B-826E-BC7050E684A6}" + } + } + } + } + }, + { + "Id": { + "id": 8719869868944 + }, + "Name": "SC-Node(GetAuthorityToAutonomous_PlayerNumberEventByEntityId)", + "Components": { + "Component_[1841271567102345236]": { + "$type": "{E42861BD-1956-45AE-8DD7-CCFC1E3E5ACF} Method", + "Id": 1841271567102345236, + "Slots": [ + { + "id": { + "m_id": "{B556F66D-84DB-4118-8AFE-B3D88D6D75CA}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "EntityId: 0", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{211BD78B-E01E-44F8-B44E-2FD988047BE9}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{1A6BCB27-F99F-4B6B-89CC-F2BE2A698331}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{7262E6CD-BADF-4DD0-8FCE-3A02C3F31CC8}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Event", + "DisplayDataType": { + "m_type": 4, + "m_azType": "{DB613438-34F0-5B2E-A413-77424F4254CD}" + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 2 + }, + "DataType": 1 + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 1 + }, + "isNullPointer": false, + "$type": "EntityId", + "value": { + "id": 2901262558 + }, + "label": "EntityId: 0" + } + ], + "methodType": 2, + "methodName": "GetAuthorityToAutonomous_PlayerNumberEventByEntityId", + "className": "NetworkTestPlayerComponent", + "resultSlotIDs": [ + {} + ], + "inputSlots": [ + { + "m_id": "{B556F66D-84DB-4118-8AFE-B3D88D6D75CA}" + } + ], + "prettyClassName": "NetworkTestPlayerComponent" + } + } + }, + { + "Id": { + "id": 8711279934352 + }, + "Name": "SendScriptEvent", + "Components": { + "Component_[5751772243856660980]": { + "$type": "SendScriptEvent", + "Id": 5751772243856660980, + "Slots": [ + { + "id": { + "m_id": "{2FF1A0A1-59C6-4DCF-AE1D-296BD5964D4E}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "toolTip": "Fires the specified ScriptEvent when signaled", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{F2955681-A901-432D-99A3-53818F46CDE7}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "toolTip": "Trigged after the ScriptEvent has been signaled and returns", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "m_version": 1, + "m_scriptEventAssetId": { + "guid": "{FE1B1992-8220-5DD3-A60A-AEC85EB91C54}" + }, + "m_asset": { + "assetId": { + "guid": "{FE1B1992-8220-5DD3-A60A-AEC85EB91C54}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/globalgamedata.scriptevents" + }, + "m_busId": { + "Value": 1375178404 + }, + "m_eventId": { + "Value": 2930121176 + } + } + } + }, + { + "Id": { + "id": 8749934640016 + }, + "Name": "SendScriptEvent", + "Components": { + "Component_[6456267108920901297]": { + "$type": "SendScriptEvent", + "Id": 6456267108920901297, + "Slots": [ + { + "id": { + "m_id": "{23DBACD8-7784-4E18-A51C-258B25DF4C19}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "toolTip": "Fires the specified ScriptEvent when signaled", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{19C850D7-7F1E-4D41-AFD9-5A4FA03D54F0}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "toolTip": "Trigged after the ScriptEvent has been signaled and returns", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{B6CA4982-245A-45F1-8AA6-3295F49DC071}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Number", + "DisplayDataType": { + "m_type": 3 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 2 + }, + "DataType": 1, + "IsReference": true, + "VariableReference": { + "m_id": "{71675BCB-6546-4B79-9D5E-912982945852}" + } + } + ], + "m_version": 1, + "m_eventSlotMapping": { + "{C7E99974-D1C0-4108-B731-120AF000060C}": { + "m_id": "{B6CA4982-245A-45F1-8AA6-3295F49DC071}" + } + }, + "m_scriptEventAssetId": { + "guid": "{FE1B1992-8220-5DD3-A60A-AEC85EB91C54}" + }, + "m_asset": { + "assetId": { + "guid": "{FE1B1992-8220-5DD3-A60A-AEC85EB91C54}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/globalgamedata.scriptevents" + }, + "m_busId": { + "Value": 1375178404 + }, + "m_eventId": { + "Value": 242067946 + } + } + } + }, + { + "Id": { + "id": 8732754770832 + }, + "Name": "SC-Node(Print)", + "Components": { + "Component_[6838720237293185886]": { + "$type": "Print", + "Id": 6838720237293185886, + "Slots": [ + { + "id": { + "m_id": "{D206E5BC-3746-4A18-80C7-DBD335FD05FE}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "toolTip": "Input signal", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{BA146872-FBFF-4662-A569-8F1B4C8774AC}" + }, + "DynamicTypeOverride": 3, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Value", + "toolTip": "Value which replaces instances of {Value} in the resulting string.", + "DisplayDataType": { + "m_type": 3 + }, + "DisplayGroup": { + "Value": 1015031923 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{A4555039-973F-43F6-BC9D-CCC0C9B34252}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 0.0, + "label": "Value" + } + ], + "m_format": "AutoComponent_RPC: I'm Player #{Value}\n", + "m_numericPrecision": 0, + "m_arrayBindingMap": [ + { + "Key": 1, + "Value": { + "m_id": "{BA146872-FBFF-4662-A569-8F1B4C8774AC}" + } + } + ], + "m_unresolvedString": [ + "AutoComponent_RPC: I'm Player #", + {}, + "\n" + ], + "m_formatSlotMap": { + "Value": { + "m_id": "{BA146872-FBFF-4662-A569-8F1B4C8774AC}" + } + } + } + } + }, + { + "Id": { + "id": 8715574901648 + }, + "Name": "SC-Node(TimeDelayNodeableNode)", + "Components": { + "Component_[8216689437045635826]": { + "$type": "TimeDelayNodeableNode", + "Id": 8216689437045635826, + "Slots": [ + { + "id": { + "m_id": "{D2337DC6-F126-4254-B296-2DE6BA03993F}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Start", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{5809EA65-214B-43A9-8674-B89E9ADF1AE6}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Delay", + "toolTip": "The amount of time to delay before the Done is signalled.", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{AC3B9B74-5A7A-4AC9-89AA-B255879D6F63}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "On Start", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{25568B15-5372-4C2D-8280-2B433251EACA}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Done", + "toolTip": "Signaled after waiting for the specified amount of times.", + "DisplayGroup": { + "Value": 271442091 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + }, + "IsLatent": true + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 1.0, + "label": "Delay" + } + ], + "nodeable": { + "m_timeUnits": 2 + }, + "slotExecutionMap": { + "ins": [ + { + "_slotId": { + "m_id": "{D2337DC6-F126-4254-B296-2DE6BA03993F}" + }, + "_inputs": [ + { + "_slotId": { + "m_id": "{5809EA65-214B-43A9-8674-B89E9ADF1AE6}" + } + } + ], + "_outs": [ + { + "_slotId": { + "m_id": "{AC3B9B74-5A7A-4AC9-89AA-B255879D6F63}" + }, + "_name": "On Start", + "_interfaceSourceId": "{C071AF8D-5D00-0000-E074-ECBC15020000}" + } + ], + "_interfaceSourceId": "{C3B60A69-2ADF-0000-4062-ABA615020000}" + } + ], + "latents": [ + { + "_slotId": { + "m_id": "{25568B15-5372-4C2D-8280-2B433251EACA}" + }, + "_name": "Done", + "_interfaceSourceId": "{C3B60A69-2ADF-0000-4062-ABA615020000}" + } + ] + } + } + } + }, + { + "Id": { + "id": 8741344705424 + }, + "Name": "SC-Node(AuthorityToAutonomous_PlayerNumberByEntityId)", + "Components": { + "Component_[8243210565080727934]": { + "$type": "{E42861BD-1956-45AE-8DD7-CCFC1E3E5ACF} Method", + "Id": 8243210565080727934, + "Slots": [ + { + "id": { + "m_id": "{D8767DB8-4BD8-4907-A3A4-BE0AE4F1A774}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Source", + "toolTip": "The Source containing the NetworkTestPlayerComponentController", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{2B948544-DD45-4DE1-A9FC-7AFBE1CAB202}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "player_number", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1, + "IsReference": true, + "VariableReference": { + "m_id": "{71675BCB-6546-4B79-9D5E-912982945852}" + } + }, + { + "id": { + "m_id": "{1FDB4A9A-D46A-49E8-B734-475230EB7C06}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{964EAD23-8DF5-47A9-BF07-1E5C7CD0CC6C}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 1 + }, + "isNullPointer": false, + "$type": "EntityId", + "value": { + "id": 2901262558 + }, + "label": "Source" + }, + { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 0.0, + "label": "player_number" + } + ], + "methodType": 2, + "methodName": "AuthorityToAutonomous_PlayerNumberByEntityId", + "className": "NetworkTestPlayerComponent", + "resultSlotIDs": [ + {} + ], + "inputSlots": [ + { + "m_id": "{D8767DB8-4BD8-4907-A3A4-BE0AE4F1A774}" + }, + { + "m_id": "{2B948544-DD45-4DE1-A9FC-7AFBE1CAB202}" + } + ], + "prettyClassName": "NetworkTestPlayerComponent" + } + } + }, + { + "Id": { + "id": 8745639672720 + }, + "Name": "SC-Node(Start)", + "Components": { + "Component_[8447409406288787781]": { + "$type": "Start", + "Id": 8447409406288787781, + "Slots": [ + { + "id": { + "m_id": "{A8EA9EF2-A3A6-46B5-8D43-08EF6B6B5B32}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "toolTip": "Signaled when the entity that owns this graph is fully activated.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ] + } + } + }, + { + "Id": { + "id": 8728459803536 + }, + "Name": "SC-Node(Gate)", + "Components": { + "Component_[8679383768392231909]": { + "$type": "Gate", + "Id": 8679383768392231909, + "Slots": [ + { + "id": { + "m_id": "{3E89B67B-1EF2-4DAB-8028-59A97527F3DF}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Condition", + "toolTip": "If true the node will signal the Output and proceed execution", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{8AE7F430-C4A9-444E-B42A-BDDFE96C387A}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "toolTip": "Input signal", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{78C92586-C0E1-449F-8EB2-B1CE3BFC8AE7}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "True", + "toolTip": "Signaled if the condition provided evaluates to true.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{47D87C86-2D61-46D3-A0FC-138F84FD352B}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "False", + "toolTip": "Signaled if the condition provided evaluates to false.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 0 + }, + "isNullPointer": false, + "$type": "bool", + "value": false, + "label": "Condition" + } + ] + } + } + } + ], + "m_connections": [ + { + "Id": { + "id": 8754229607312 + }, + "Name": "srcEndpoint=(IsNetEntityRoleAuthority: Out), destEndpoint=(If: In)", + "Components": { + "Component_[3645153988172561571]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 3645153988172561571, + "sourceEndpoint": { + "nodeId": { + "id": 8724164836240 + }, + "slotId": { + "m_id": "{1071F455-D5A0-4C7A-AF91-648A0F197885}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8728459803536 + }, + "slotId": { + "m_id": "{8AE7F430-C4A9-444E-B42A-BDDFE96C387A}" + } + } + } + } + }, + { + "Id": { + "id": 8758524574608 + }, + "Name": "srcEndpoint=(IsNetEntityRoleAuthority: Is Role Authority), destEndpoint=(If: Condition)", + "Components": { + "Component_[17942926291787646743]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 17942926291787646743, + "sourceEndpoint": { + "nodeId": { + "id": 8724164836240 + }, + "slotId": { + "m_id": "{BA87B4ED-9A52-4A0D-8920-CD0ED4E839EA}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8728459803536 + }, + "slotId": { + "m_id": "{3E89B67B-1EF2-4DAB-8028-59A97527F3DF}" + } + } + } + } + }, + { + "Id": { + "id": 8762819541904 + }, + "Name": "srcEndpoint=(If: True), destEndpoint=(Send Script Event: In)", + "Components": { + "Component_[3298020356088639785]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 3298020356088639785, + "sourceEndpoint": { + "nodeId": { + "id": 8728459803536 + }, + "slotId": { + "m_id": "{78C92586-C0E1-449F-8EB2-B1CE3BFC8AE7}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8711279934352 + }, + "slotId": { + "m_id": "{2FF1A0A1-59C6-4DCF-AE1D-296BD5964D4E}" + } + } + } + } + }, + { + "Id": { + "id": 8767114509200 + }, + "Name": "srcEndpoint=(Send Script Event: Out), destEndpoint=(Send Script Event: In)", + "Components": { + "Component_[5482500452520221078]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 5482500452520221078, + "sourceEndpoint": { + "nodeId": { + "id": 8711279934352 + }, + "slotId": { + "m_id": "{F2955681-A901-432D-99A3-53818F46CDE7}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8749934640016 + }, + "slotId": { + "m_id": "{23DBACD8-7784-4E18-A51C-258B25DF4C19}" + } + } + } + } + }, + { + "Id": { + "id": 8771409476496 + }, + "Name": "srcEndpoint=(Send Script Event: Out), destEndpoint=(AuthorityToAutonomous_PlayerNumberByEntityId: In)", + "Components": { + "Component_[16156808606878296902]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 16156808606878296902, + "sourceEndpoint": { + "nodeId": { + "id": 8749934640016 + }, + "slotId": { + "m_id": "{19C850D7-7F1E-4D41-AFD9-5A4FA03D54F0}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8741344705424 + }, + "slotId": { + "m_id": "{1FDB4A9A-D46A-49E8-B734-475230EB7C06}" + } + } + } + } + }, + { + "Id": { + "id": 8775704443792 + }, + "Name": "srcEndpoint=(AuthorityToAutonomous_PlayerNumberByEntityId: Out), destEndpoint=(Print: In)", + "Components": { + "Component_[17367899649716276273]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 17367899649716276273, + "sourceEndpoint": { + "nodeId": { + "id": 8741344705424 + }, + "slotId": { + "m_id": "{964EAD23-8DF5-47A9-BF07-1E5C7CD0CC6C}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8737049738128 + }, + "slotId": { + "m_id": "{F3ED8C08-D751-492A-A39A-7B7734727A5A}" + } + } + } + } + }, + { + "Id": { + "id": 8779999411088 + }, + "Name": "srcEndpoint=(On Graph Start: Out), destEndpoint=(TimeDelay: Start)", + "Components": { + "Component_[13463448697016307967]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 13463448697016307967, + "sourceEndpoint": { + "nodeId": { + "id": 8745639672720 + }, + "slotId": { + "m_id": "{A8EA9EF2-A3A6-46B5-8D43-08EF6B6B5B32}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8715574901648 + }, + "slotId": { + "m_id": "{D2337DC6-F126-4254-B296-2DE6BA03993F}" + } + } + } + } + }, + { + "Id": { + "id": 8784294378384 + }, + "Name": "srcEndpoint=(GetAuthorityToAutonomous_PlayerNumberEventByEntityId: Event), destEndpoint=(AuthorityToAutonomous_PlayerNumber Notify Event: AuthorityToAutonomous_PlayerNumber Notify Event)", + "Components": { + "Component_[9477060643694737434]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 9477060643694737434, + "sourceEndpoint": { + "nodeId": { + "id": 8719869868944 + }, + "slotId": { + "m_id": "{7262E6CD-BADF-4DD0-8FCE-3A02C3F31CC8}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8706984967056 + }, + "slotId": { + "m_id": "{8C7E88EA-8FEE-45D0-9A2E-78BC4A18F508}" + } + } + } + } + }, + { + "Id": { + "id": 8788589345680 + }, + "Name": "srcEndpoint=(GetAuthorityToAutonomous_PlayerNumberEventByEntityId: Out), destEndpoint=(AuthorityToAutonomous_PlayerNumber Notify Event: Connect)", + "Components": { + "Component_[16543380658701699472]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 16543380658701699472, + "sourceEndpoint": { + "nodeId": { + "id": 8719869868944 + }, + "slotId": { + "m_id": "{1A6BCB27-F99F-4B6B-89CC-F2BE2A698331}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8706984967056 + }, + "slotId": { + "m_id": "{46E6B649-CAA4-4318-960D-5E4854E21BB2}" + } + } + } + } + }, + { + "Id": { + "id": 8792884312976 + }, + "Name": "srcEndpoint=(AuthorityToAutonomous_PlayerNumber Notify Event: player_number), destEndpoint=(Print: Value)", + "Components": { + "Component_[864863482692400383]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 864863482692400383, + "sourceEndpoint": { + "nodeId": { + "id": 8706984967056 + }, + "slotId": { + "m_id": "{82D3E2FD-ADFA-47F7-A889-D1172BF2EC49}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8732754770832 + }, + "slotId": { + "m_id": "{BA146872-FBFF-4662-A569-8F1B4C8774AC}" + } + } + } + } + }, + { + "Id": { + "id": 8797179280272 + }, + "Name": "srcEndpoint=(AuthorityToAutonomous_PlayerNumber Notify Event: OnEvent), destEndpoint=(Print: In)", + "Components": { + "Component_[2451057837093425972]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 2451057837093425972, + "sourceEndpoint": { + "nodeId": { + "id": 8706984967056 + }, + "slotId": { + "m_id": "{586BE222-2DEA-4E08-968F-07CA4EB96C54}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8732754770832 + }, + "slotId": { + "m_id": "{D206E5BC-3746-4A18-80C7-DBD335FD05FE}" + } + } + } + } + }, + { + "Id": { + "id": 8801474247568 + }, + "Name": "srcEndpoint=(On Graph Start: Out), destEndpoint=(GetAuthorityToAutonomous_PlayerNumberEventByEntityId: In)", + "Components": { + "Component_[12180981889720748145]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 12180981889720748145, + "sourceEndpoint": { + "nodeId": { + "id": 8745639672720 + }, + "slotId": { + "m_id": "{A8EA9EF2-A3A6-46B5-8D43-08EF6B6B5B32}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8719869868944 + }, + "slotId": { + "m_id": "{211BD78B-E01E-44F8-B44E-2FD988047BE9}" + } + } + } + } + }, + { + "Id": { + "id": 8805769214864 + }, + "Name": "srcEndpoint=(TimeDelay: Done), destEndpoint=(IsNetEntityRoleAuthority: In)", + "Components": { + "Component_[5772191552099194657]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 5772191552099194657, + "sourceEndpoint": { + "nodeId": { + "id": 8715574901648 + }, + "slotId": { + "m_id": "{25568B15-5372-4C2D-8280-2B433251EACA}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8724164836240 + }, + "slotId": { + "m_id": "{B6C4BE5E-CDE4-4EC7-98D0-A019CD80041C}" + } + } + } + } + } + ], + "m_scriptEventAssets": [ + [ + { + "id": 8749934640016 + }, + {} + ], + [ + { + "id": 8711279934352 + }, + {} + ] + ] + }, + "m_assetType": "{3E2AC8CD-713F-453E-967F-29517F331784}", + "versionData": { + "_grammarVersion": 1, + "_runtimeVersion": 1, + "_fileVersion": 1 + }, + "m_variableCounter": 1, + "GraphCanvasData": [ + { + "Key": { + "id": 8706984967056 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "HandlerNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 820.0, + 620.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".azeventhandler" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{F112D217-FAC8-4577-B67A-DFDF47842F7D}" + } + } + } + }, + { + "Key": { + "id": 8711279934352 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 1240.0, + 260.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{13BD3C1C-EDBB-419E-8465-495935414A1A}" + } + } + } + }, + { + "Key": { + "id": 8715574901648 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "TimeNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 200.0, + 260.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{5DF902FE-B0C4-4563-B2BA-17996B24E211}" + } + } + } + }, + { + "Key": { + "id": 8719869868944 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 380.0, + 620.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{BBBE60FC-0215-4A5A-BEBE-4FC869E5EECE}" + } + } + } + }, + { + "Key": { + "id": 8724164836240 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 500.0, + 260.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{348E780E-3A4E-47C7-ACF5-C7B2CB387517}" + } + } + } + }, + { + "Key": { + "id": 8728459803536 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "LogicNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 940.0, + 260.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{53C8DAF1-FFF3-4AF8-A7FB-BC0B4E492B37}" + } + } + } + }, + { + "Key": { + "id": 8732754770832 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "StringNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 1440.0, + 620.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{74ED5AE1-A269-46D4-B968-FEDF513C9CF1}" + } + } + } + }, + { + "Key": { + "id": 8737049738128 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "StringNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 2280.0, + 260.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{B91C0E41-E6B5-46DE-885F-6BC6CFB2E813}" + } + } + } + }, + { + "Key": { + "id": 8741344705424 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 1840.0, + 260.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{59FFF3C1-2D7B-47EA-AE35-ED15DCB95CC8}" + } + } + } + }, + { + "Key": { + "id": 8745639672720 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "TimeNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 40.0, + 280.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{B4CB62D9-9965-42E2-81FF-BDADDBD14CBE}" + } + } + } + }, + { + "Key": { + "id": 8749934640016 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 1540.0, + 260.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{FD844BFD-72DA-44BA-B92A-AFDB58263B91}" + } + } + } + }, + { + "Key": { + "id": 2816238339133127497 + }, + "Value": { + "ComponentData": { + "{5F84B500-8C45-40D1-8EFC-A5306B241444}": { + "$type": "SceneComponentSaveData", + "ViewParams": { + "AnchorX": 260.0, + "AnchorY": 479.0 + } + } + } + } + } + ], + "StatisticsHelper": { + "InstanceCounter": [ + { + "Key": 4199610336680704683, + "Value": 1 + }, + { + "Key": 4847610523576971761, + "Value": 1 + }, + { + "Key": 6462358712820489356, + "Value": 1 + }, + { + "Key": 7760188923571293852, + "Value": 1 + }, + { + "Key": 8065262779685207188, + "Value": 1 + }, + { + "Key": 8452971738487658154, + "Value": 1 + }, + { + "Key": 10684225535275896474, + "Value": 2 + }, + { + "Key": 12248403816200817622, + "Value": 1 + }, + { + "Key": 12248403882232298424, + "Value": 1 + }, + { + "Key": 16232169425081397848, + "Value": 1 + } + ] + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC_NetLevelEntity.scriptcanvas b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC_NetLevelEntity.scriptcanvas new file mode 100644 index 0000000000..3869dfdfcb --- /dev/null +++ b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC_NetLevelEntity.scriptcanvas @@ -0,0 +1,1946 @@ +{ + "Type": "JsonSerialization", + "Version": 1, + "ClassName": "ScriptCanvasData", + "ClassData": { + "m_scriptCanvas": { + "Id": { + "id": 1685762441320719908 + }, + "Name": "AutoComponent_RPC_NetLevelEntity", + "Components": { + "Component_[2936040539888065977]": { + "$type": "{4D755CA9-AB92-462C-B24F-0B3376F19967} Graph", + "Id": 2936040539888065977, + "m_graphData": { + "m_nodes": [ + { + "Id": { + "id": 56986727032248 + }, + "Name": "SC-Node(RepeaterNodeableNode)", + "Components": { + "Component_[11069913642528675281]": { + "$type": "RepeaterNodeableNode", + "Id": 11069913642528675281, + "Slots": [ + { + "id": { + "m_id": "{07267CBA-B377-4B57-8A04-E322F8BFC07F}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Start", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{A9CCCCF4-BC3E-44B8-B2BB-2EEFBF475F82}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Repetitions", + "toolTip": "How many times to repeat.", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{E490B225-8A15-4CA1-9F25-6D8F9F8E398F}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Interval", + "toolTip": "The Interval between repetitions. If zero, all repititions execute immediately, before On Start", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{92077333-D7F5-4E54-80FD-0363876B5510}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "On Start", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{91CF89F3-906C-4860-B84E-9BD7D6842CA8}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Complete", + "toolTip": "Signaled upon node exit", + "DisplayGroup": { + "Value": 1114099747 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + }, + "IsLatent": true + }, + { + "id": { + "m_id": "{C1CCBA7B-A13B-4FCE-99ED-8FD1A8F72869}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Action", + "toolTip": "Signaled every repetition", + "DisplayGroup": { + "Value": 1204587666 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + }, + "IsLatent": true + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 99.0, + "label": "Repetitions" + }, + { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 1.0, + "label": "Interval" + } + ], + "nodeable": { + "m_timeUnits": 2 + }, + "slotExecutionMap": { + "ins": [ + { + "_slotId": { + "m_id": "{07267CBA-B377-4B57-8A04-E322F8BFC07F}" + }, + "_inputs": [ + { + "_slotId": { + "m_id": "{A9CCCCF4-BC3E-44B8-B2BB-2EEFBF475F82}" + } + }, + { + "_slotId": { + "m_id": "{E490B225-8A15-4CA1-9F25-6D8F9F8E398F}" + } + } + ], + "_outs": [ + { + "_slotId": { + "m_id": "{92077333-D7F5-4E54-80FD-0363876B5510}" + }, + "_name": "On Start", + "_interfaceSourceId": "{60330D5B-FB7F-0000-8039-14DD7C020000}" + } + ], + "_interfaceSourceId": "{E1D0AF7E-837B-0000-0033-BA267C020000}" + } + ], + "latents": [ + { + "_slotId": { + "m_id": "{91CF89F3-906C-4860-B84E-9BD7D6842CA8}" + }, + "_name": "Complete", + "_interfaceSourceId": "{E1D0AF7E-837B-0000-0033-BA267C020000}" + }, + { + "_slotId": { + "m_id": "{C1CCBA7B-A13B-4FCE-99ED-8FD1A8F72869}" + }, + "_name": "Action", + "_interfaceSourceId": "{E1D0AF7E-837B-0000-0033-BA267C020000}" + } + ] + } + } + } + }, + { + "Id": { + "id": 57003906901432 + }, + "Name": "SC-Node(DrawTextOnEntity)", + "Components": { + "Component_[14125366736968050670]": { + "$type": "{E42861BD-1956-45AE-8DD7-CCFC1E3E5ACF} Method", + "Id": 14125366736968050670, + "Slots": [ + { + "id": { + "m_id": "{6BD7BF07-D1B6-4CC2-A861-C4334AA3A025}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "EntityId: 0", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{AB0304C4-CD52-4351-A009-CD959CDA6E2B}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "String: 1", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{EB877F87-C03A-4692-ABBB-2317E98E8C6F}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Color: 2", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{E2D11762-F47C-4341-806A-DBB4FBAEC235}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Number: 3", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{1673B8A0-D4EC-4CC7-8F80-0419BB5560EB}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{5F720C70-EA4F-4883-B5BE-4278E75370E8}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 1 + }, + "isNullPointer": false, + "$type": "EntityId", + "value": { + "id": 2901262558 + }, + "label": "Entity Id" + }, + { + "scriptCanvasType": { + "m_type": 5 + }, + "isNullPointer": false, + "$type": "{03AAAB3F-5C47-5A66-9EBC-D5FA4DB353C9} AZStd::string", + "value": "AutoComponent_RPC_NetLevelEntity: I'm a client playing some superficial fx", + "label": "Color" + }, + { + "scriptCanvasType": { + "m_type": 12 + }, + "isNullPointer": false, + "$type": "Color", + "value": [ + 1.0, + 0.0, + 0.0, + 1.0 + ], + "label": "Color: 2" + }, + { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 2.0, + "label": "Number: 3" + } + ], + "methodType": 0, + "methodName": "DrawTextOnEntity", + "className": "DebugDrawRequestBus", + "resultSlotIDs": [ + {} + ], + "inputSlots": [ + { + "m_id": "{6BD7BF07-D1B6-4CC2-A861-C4334AA3A025}" + }, + { + "m_id": "{AB0304C4-CD52-4351-A009-CD959CDA6E2B}" + }, + { + "m_id": "{EB877F87-C03A-4692-ABBB-2317E98E8C6F}" + }, + { + "m_id": "{E2D11762-F47C-4341-806A-DBB4FBAEC235}" + } + ], + "prettyClassName": "DebugDrawRequestBus" + } + } + }, + { + "Id": { + "id": 56999611934136 + }, + "Name": "SC-Node(Print)", + "Components": { + "Component_[15472692142045278273]": { + "$type": "Print", + "Id": 15472692142045278273, + "Slots": [ + { + "id": { + "m_id": "{2F11CF04-DC4B-4881-8D74-AB0E51B4A278}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "toolTip": "Input signal", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{6CE4DAB2-4D8E-461E-B9B2-34338EBBAD97}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "m_format": "AutoComponent_RPC_NetLevelEntity: Authority sending RPC to play some fx.\n", + "m_unresolvedString": [ + "AutoComponent_RPC_NetLevelEntity: Authority sending RPC to play some fx.\n" + ] + } + } + }, + { + "Id": { + "id": 56995316966840 + }, + "Name": "SC-Node(Print)", + "Components": { + "Component_[15717135232290736332]": { + "$type": "Print", + "Id": 15717135232290736332, + "Slots": [ + { + "id": { + "m_id": "{7CAD6E31-6218-4326-8FFB-0523F545E250}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "toolTip": "Input signal", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{C38BB068-BF1B-4734-BFFA-10B258870349}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "m_format": "AutoComponent_RPC_NetLevelEntity: I'm a client playing some fx.\n", + "m_unresolvedString": [ + "AutoComponent_RPC_NetLevelEntity: I'm a client playing some fx.\n" + ] + } + } + }, + { + "Id": { + "id": 8318619017825 + }, + "Name": "SC-EventNode(AuthorityToClientNoParams_PlayFx Notify Event)", + "Components": { + "Component_[15772128920819427182]": { + "$type": "AzEventHandler", + "Id": 15772128920819427182, + "Slots": [ + { + "id": { + "m_id": "{2A42C379-8E3B-46EF-BC63-C1D5395CB583}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + }, + { + "$type": "ConnectionLimitContract", + "limit": 1 + }, + { + "$type": "RestrictedNodeContract", + "m_nodeId": { + "id": 7820402811489 + } + } + ], + "slotName": "Connect", + "toolTip": "Connect the AZ Event to this AZ Event Handler.", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{3DB9829E-6088-49B9-A56D-4D1884C679BD}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Disconnect", + "toolTip": "Disconnect current AZ Event from this AZ Event Handler.", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{9AC3CF57-B648-4B43-8FCA-8576B6EA350B}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "On Connected", + "toolTip": "Signaled when a connection has taken place.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{5FB8D529-6FC6-4543-99B5-5B147EBD7BE6}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "On Disconnected", + "toolTip": "Signaled when this event handler is disconnected.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{0481BBFE-D31E-421F-A6C2-8A7AF3012545}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "OnEvent", + "toolTip": "Triggered when the AZ Event invokes Signal() function.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + }, + "IsLatent": true + }, + { + "id": { + "m_id": "{5F809F1C-ED4E-4391-9E33-AD3B64561A40}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + }, + { + "$type": "ConnectionLimitContract", + "limit": 1 + }, + { + "$type": "RestrictedNodeContract", + "m_nodeId": { + "id": 7820402811489 + } + } + ], + "slotName": "AuthorityToClientNoParams_PlayFx Notify Event", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 4, + "m_azType": "{F429F985-AF00-529B-8449-16E56694E5F9}" + }, + "isNullPointer": true, + "label": "AuthorityToClientNoParams_PlayFx Notify Event" + } + ], + "m_azEventEntry": { + "m_eventName": "AuthorityToClientNoParams_PlayFx Notify Event", + "m_eventSlotId": { + "m_id": "{5F809F1C-ED4E-4391-9E33-AD3B64561A40}" + } + } + } + } + }, + { + "Id": { + "id": 56991021999544 + }, + "Name": "SC-Node(Print)", + "Components": { + "Component_[15785913678997669879]": { + "$type": "Print", + "Id": 15785913678997669879, + "Slots": [ + { + "id": { + "m_id": "{8E1B9705-148A-42E4-831E-D7B2877358E3}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "toolTip": "Input signal", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{CEBD2B9C-7DBA-486A-88DB-19F9C406B18E}" + }, + "DynamicTypeOverride": 3, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Value", + "toolTip": "Value which replaces instances of {Value} in the resulting string.", + "DisplayDataType": { + "m_type": 5 + }, + "DisplayGroup": { + "Value": 1015031923 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{E9B979F9-D682-4B58-8E88-6102387FE70B}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 5 + }, + "isNullPointer": false, + "$type": "{03AAAB3F-5C47-5A66-9EBC-D5FA4DB353C9} AZStd::string", + "value": "", + "label": "Value" + } + ], + "m_format": "AutoComponent_RPC_NetLevelEntity Activated on entity: {Value}\n", + "m_arrayBindingMap": [ + { + "Key": 1, + "Value": { + "m_id": "{CEBD2B9C-7DBA-486A-88DB-19F9C406B18E}" + } + } + ], + "m_unresolvedString": [ + "AutoComponent_RPC_NetLevelEntity Activated on entity: ", + {}, + "\n" + ], + "m_formatSlotMap": { + "Value": { + "m_id": "{CEBD2B9C-7DBA-486A-88DB-19F9C406B18E}" + } + } + } + } + }, + { + "Id": { + "id": 57025381737912 + }, + "Name": "SC-Node(Start)", + "Components": { + "Component_[1888047318201703857]": { + "$type": "Start", + "Id": 1888047318201703857, + "Slots": [ + { + "id": { + "m_id": "{28664064-2483-465A-9BB1-4E1890048CDF}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "toolTip": "Signaled when the entity that owns this graph is fully activated.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ] + } + } + }, + { + "Id": { + "id": 8310662318335 + }, + "Name": "SC-Node(GetEntityName)", + "Components": { + "Component_[2232030369305027010]": { + "$type": "{E42861BD-1956-45AE-8DD7-CCFC1E3E5ACF} Method", + "Id": 2232030369305027010, + "Slots": [ + { + "id": { + "m_id": "{F69C5762-0CAB-4A54-9C81-C99CDB73C834}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "EntityId: 0", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{03554C56-8237-4C19-B9F8-87DEA1AC3ED0}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{6ECBD749-25FE-4813-B34E-EF46BC09E616}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{36D47097-8F0C-4CBD-8DE2-32F4754C569F}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "String", + "DisplayDataType": { + "m_type": 5 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 2 + }, + "DataType": 1 + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 1 + }, + "isNullPointer": false, + "$type": "EntityId", + "value": { + "id": 2901262558 + }, + "label": "Entity Id" + } + ], + "methodType": 0, + "methodName": "GetEntityName", + "className": "GameEntityContextRequestBus", + "resultSlotIDs": [ + {} + ], + "inputSlots": [ + { + "m_id": "{F69C5762-0CAB-4A54-9C81-C99CDB73C834}" + } + ], + "prettyClassName": "GameEntityContextRequestBus" + } + } + }, + { + "Id": { + "id": 8400576252253 + }, + "Name": "SC-Node(AuthorityToClientNoParams_PlayFxByEntityId)", + "Components": { + "Component_[6332803108634970671]": { + "$type": "{E42861BD-1956-45AE-8DD7-CCFC1E3E5ACF} Method", + "Id": 6332803108634970671, + "Slots": [ + { + "id": { + "m_id": "{87B7266B-D7B1-4CAD-9898-4D7F0274DAB0}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Source", + "toolTip": "The Source containing the NetworkTestPlayerComponentController", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{AB0D7C00-A334-449A-AC56-EA3167AB8900}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{A52302D6-9DF9-45C2-960D-19BF90A4A931}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 1 + }, + "isNullPointer": false, + "$type": "EntityId", + "value": { + "id": 2901262558 + }, + "label": "Source" + } + ], + "methodType": 2, + "methodName": "AuthorityToClientNoParams_PlayFxByEntityId", + "className": "NetworkTestPlayerComponent", + "resultSlotIDs": [ + {} + ], + "inputSlots": [ + { + "m_id": "{87B7266B-D7B1-4CAD-9898-4D7F0274DAB0}" + } + ], + "prettyClassName": "NetworkTestPlayerComponent" + } + } + }, + { + "Id": { + "id": 57012496836024 + }, + "Name": "SC-Node(TimeDelayNodeableNode)", + "Components": { + "Component_[8951348653904382148]": { + "$type": "TimeDelayNodeableNode", + "Id": 8951348653904382148, + "Slots": [ + { + "id": { + "m_id": "{EA0DF0AE-2FF7-4670-8D99-7CF863038E68}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Start", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{9C6D8500-B49B-4407-B2EB-40B1CD4CE762}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Delay", + "toolTip": "The amount of time to delay before the Done is signalled.", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{FE2A3D2F-7AC2-431D-B80C-C363DB475919}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "On Start", + "DisplayGroup": { + "Value": 2675529103 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{158B30BE-BD39-40AE-A8A8-F0E5694F0180}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Done", + "toolTip": "Signaled after waiting for the specified amount of times.", + "DisplayGroup": { + "Value": 271442091 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + }, + "IsLatent": true + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 1.0, + "label": "Delay" + } + ], + "nodeable": { + "m_timeUnits": 2 + }, + "slotExecutionMap": { + "ins": [ + { + "_slotId": { + "m_id": "{EA0DF0AE-2FF7-4670-8D99-7CF863038E68}" + }, + "_inputs": [ + { + "_slotId": { + "m_id": "{9C6D8500-B49B-4407-B2EB-40B1CD4CE762}" + } + } + ], + "_outs": [ + { + "_slotId": { + "m_id": "{FE2A3D2F-7AC2-431D-B80C-C363DB475919}" + }, + "_name": "On Start", + "_interfaceSourceId": "{4C400000-7C02-0000-B86E-0FACE0000000}" + } + ], + "_interfaceSourceId": "{24000000-0000-0000-0000-F421FC7F0000}" + } + ], + "latents": [ + { + "_slotId": { + "m_id": "{158B30BE-BD39-40AE-A8A8-F0E5694F0180}" + }, + "_name": "Done", + "_interfaceSourceId": "{24000000-0000-0000-0000-F421FC7F0000}" + } + ] + } + } + } + }, + { + "Id": { + "id": 7820402811489 + }, + "Name": "SC-Node(GetAuthorityToClientNoParams_PlayFxEventByEntityId)", + "Components": { + "Component_[9263945554457190064]": { + "$type": "{E42861BD-1956-45AE-8DD7-CCFC1E3E5ACF} Method", + "Id": 9263945554457190064, + "Slots": [ + { + "id": { + "m_id": "{F22A7438-E72F-4757-90D9-99F03C91E10D}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "EntityId: 0", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{510F56FD-6778-4DB8-BDDE-258335431CC6}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{94C2AF04-6BFA-4E5A-9490-C7479A7AF61E}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{9C6DDF96-6BF0-45ED-B15F-2E6C2FF5F886}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Event<>", + "DisplayDataType": { + "m_type": 4, + "m_azType": "{F429F985-AF00-529B-8449-16E56694E5F9}" + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 2 + }, + "DataType": 1 + } + ], + "Datums": [ + { + "scriptCanvasType": { + "m_type": 1 + }, + "isNullPointer": false, + "$type": "EntityId", + "value": { + "id": 2901262558 + }, + "label": "EntityId: 0" + } + ], + "methodType": 2, + "methodName": "GetAuthorityToClientNoParams_PlayFxEventByEntityId", + "className": "NetworkTestPlayerComponent", + "resultSlotIDs": [ + {} + ], + "inputSlots": [ + { + "m_id": "{F22A7438-E72F-4757-90D9-99F03C91E10D}" + } + ], + "prettyClassName": "NetworkTestPlayerComponent" + } + } + } + ], + "m_connections": [ + { + "Id": { + "id": 57029676705208 + }, + "Name": "srcEndpoint=(On Graph Start: Out), destEndpoint=(TimeDelay: Start)", + "Components": { + "Component_[5204535376548158590]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 5204535376548158590, + "sourceEndpoint": { + "nodeId": { + "id": 57025381737912 + }, + "slotId": { + "m_id": "{28664064-2483-465A-9BB1-4E1890048CDF}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 57012496836024 + }, + "slotId": { + "m_id": "{EA0DF0AE-2FF7-4670-8D99-7CF863038E68}" + } + } + } + } + }, + { + "Id": { + "id": 57055446508984 + }, + "Name": "srcEndpoint=(TimeDelay: Done), destEndpoint=(Repeater: Start)", + "Components": { + "Component_[6292481678297438578]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 6292481678297438578, + "sourceEndpoint": { + "nodeId": { + "id": 57012496836024 + }, + "slotId": { + "m_id": "{158B30BE-BD39-40AE-A8A8-F0E5694F0180}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 56986727032248 + }, + "slotId": { + "m_id": "{07267CBA-B377-4B57-8A04-E322F8BFC07F}" + } + } + } + } + }, + { + "Id": { + "id": 9392713697629 + }, + "Name": "srcEndpoint=(Repeater: Action), destEndpoint=(AuthorityToClientNoParams_PlayFxByEntityId: In)", + "Components": { + "Component_[17811480012084226596]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 17811480012084226596, + "sourceEndpoint": { + "nodeId": { + "id": 56986727032248 + }, + "slotId": { + "m_id": "{C1CCBA7B-A13B-4FCE-99ED-8FD1A8F72869}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8400576252253 + }, + "slotId": { + "m_id": "{AB0D7C00-A334-449A-AC56-EA3167AB8900}" + } + } + } + } + }, + { + "Id": { + "id": 10269167405311 + }, + "Name": "srcEndpoint=(GetEntityName: String), destEndpoint=(Print: Value)", + "Components": { + "Component_[11931728297561282182]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 11931728297561282182, + "sourceEndpoint": { + "nodeId": { + "id": 8310662318335 + }, + "slotId": { + "m_id": "{36D47097-8F0C-4CBD-8DE2-32F4754C569F}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 56991021999544 + }, + "slotId": { + "m_id": "{CEBD2B9C-7DBA-486A-88DB-19F9C406B18E}" + } + } + } + } + }, + { + "Id": { + "id": 11042261518591 + }, + "Name": "srcEndpoint=(GetEntityName: Out), destEndpoint=(Print: In)", + "Components": { + "Component_[5559381044656171146]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 5559381044656171146, + "sourceEndpoint": { + "nodeId": { + "id": 8310662318335 + }, + "slotId": { + "m_id": "{6ECBD749-25FE-4813-B34E-EF46BC09E616}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 56991021999544 + }, + "slotId": { + "m_id": "{8E1B9705-148A-42E4-831E-D7B2877358E3}" + } + } + } + } + }, + { + "Id": { + "id": 36365388695807 + }, + "Name": "srcEndpoint=(TimeDelay: Done), destEndpoint=(GetEntityName: In)", + "Components": { + "Component_[5574600651313925988]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 5574600651313925988, + "sourceEndpoint": { + "nodeId": { + "id": 57012496836024 + }, + "slotId": { + "m_id": "{158B30BE-BD39-40AE-A8A8-F0E5694F0180}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8310662318335 + }, + "slotId": { + "m_id": "{03554C56-8237-4C19-B9F8-87DEA1AC3ED0}" + } + } + } + } + }, + { + "Id": { + "id": 9022993654369 + }, + "Name": "srcEndpoint=(GetAuthorityToClientNoParams_PlayFxEventByEntityId: Event<>), destEndpoint=(AuthorityToClientNoParams_PlayFx Notify Event: AuthorityToClientNoParams_PlayFx Notify Event)", + "Components": { + "Component_[4910818715692868417]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 4910818715692868417, + "sourceEndpoint": { + "nodeId": { + "id": 7820402811489 + }, + "slotId": { + "m_id": "{9C6DDF96-6BF0-45ED-B15F-2E6C2FF5F886}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8318619017825 + }, + "slotId": { + "m_id": "{5F809F1C-ED4E-4391-9E33-AD3B64561A40}" + } + } + } + } + }, + { + "Id": { + "id": 9078828229217 + }, + "Name": "srcEndpoint=(GetAuthorityToClientNoParams_PlayFxEventByEntityId: Out), destEndpoint=(AuthorityToClientNoParams_PlayFx Notify Event: Connect)", + "Components": { + "Component_[16758724763058723803]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 16758724763058723803, + "sourceEndpoint": { + "nodeId": { + "id": 7820402811489 + }, + "slotId": { + "m_id": "{94C2AF04-6BFA-4E5A-9490-C7479A7AF61E}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 8318619017825 + }, + "slotId": { + "m_id": "{2A42C379-8E3B-46EF-BC63-C1D5395CB583}" + } + } + } + } + }, + { + "Id": { + "id": 9808972669537 + }, + "Name": "srcEndpoint=(TimeDelay: Done), destEndpoint=(GetAuthorityToClientNoParams_PlayFxEventByEntityId: In)", + "Components": { + "Component_[597205010205160938]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 597205010205160938, + "sourceEndpoint": { + "nodeId": { + "id": 57012496836024 + }, + "slotId": { + "m_id": "{158B30BE-BD39-40AE-A8A8-F0E5694F0180}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 7820402811489 + }, + "slotId": { + "m_id": "{510F56FD-6778-4DB8-BDDE-258335431CC6}" + } + } + } + } + }, + { + "Id": { + "id": 10148275085921 + }, + "Name": "srcEndpoint=(AuthorityToClientNoParams_PlayFx Notify Event: OnEvent), destEndpoint=(Print: In)", + "Components": { + "Component_[1594149632687531010]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 1594149632687531010, + "sourceEndpoint": { + "nodeId": { + "id": 8318619017825 + }, + "slotId": { + "m_id": "{0481BBFE-D31E-421F-A6C2-8A7AF3012545}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 56995316966840 + }, + "slotId": { + "m_id": "{7CAD6E31-6218-4326-8FFB-0523F545E250}" + } + } + } + } + }, + { + "Id": { + "id": 10629311423073 + }, + "Name": "srcEndpoint=(AuthorityToClientNoParams_PlayFx Notify Event: OnEvent), destEndpoint=(DrawTextOnEntity: In)", + "Components": { + "Component_[17976200298405988971]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 17976200298405988971, + "sourceEndpoint": { + "nodeId": { + "id": 8318619017825 + }, + "slotId": { + "m_id": "{0481BBFE-D31E-421F-A6C2-8A7AF3012545}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 57003906901432 + }, + "slotId": { + "m_id": "{1673B8A0-D4EC-4CC7-8F80-0419BB5560EB}" + } + } + } + } + }, + { + "Id": { + "id": 42045766425613 + }, + "Name": "srcEndpoint=(Repeater: Action), destEndpoint=(Print: In)", + "Components": { + "Component_[1911118463107071864]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 1911118463107071864, + "sourceEndpoint": { + "nodeId": { + "id": 56986727032248 + }, + "slotId": { + "m_id": "{C1CCBA7B-A13B-4FCE-99ED-8FD1A8F72869}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 56999611934136 + }, + "slotId": { + "m_id": "{2F11CF04-DC4B-4881-8D74-AB0E51B4A278}" + } + } + } + } + } + ] + }, + "m_assetType": "{3E2AC8CD-713F-453E-967F-29517F331784}", + "versionData": { + "_grammarVersion": 1, + "_runtimeVersion": 1, + "_fileVersion": 1 + }, + "GraphCanvasData": [ + { + "Key": { + "id": 7820402811489 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + -100.0, + 400.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{F35F8202-B5EE-4ADD-9FF6-AF214A094266}" + } + } + } + }, + { + "Key": { + "id": 8310662318335 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 80.0, + -320.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{346AFC26-B2EF-4495-AA1A-347BF77CB99D}" + } + } + } + }, + { + "Key": { + "id": 8318619017825 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "HandlerNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 340.0, + 400.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".azeventhandler" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{67499699-CA73-48B4-87E0-C66F4A3EA7CB}" + } + } + } + }, + { + "Key": { + "id": 8400576252253 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 420.0, + -60.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{2B6329F7-4CE7-4E01-B1A4-1FFCAB2D0B72}" + } + } + } + }, + { + "Key": { + "id": 56986727032248 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "DefaultNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 80.0, + -60.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{41B7477C-D5B9-49AC-AFA3-AAAE2A6ED7C5}" + } + } + } + }, + { + "Key": { + "id": 56991021999544 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "StringNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 540.0, + -320.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{0CF0846C-1D21-4B33-8723-1538FD4FD04A}" + } + } + } + }, + { + "Key": { + "id": 56995316966840 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "StringNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 800.0, + 260.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{0D04EBA6-E1E7-4DF7-BAA9-CC87F4689CD2}" + } + } + } + }, + { + "Key": { + "id": 56999611934136 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "StringNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 420.0, + 100.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{A4FDCB87-B021-48B9-ABCB-AECA986B33D6}" + } + } + } + }, + { + "Key": { + "id": 57003906901432 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MethodNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 800.0, + 460.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData", + "SubStyle": ".method" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{82D0ED1B-98D3-4AEF-B1DA-2F27CACD3A4D}" + } + } + } + }, + { + "Key": { + "id": 57012496836024 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "DefaultNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + -220.0, + -40.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{D3F081D7-40C1-4C31-B298-B18C6AFDFD25}" + } + } + } + }, + { + "Key": { + "id": 57025381737912 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "TimeNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + -380.0, + -20.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{675C7E90-B89E-4347-A3C6-B8D12B6EA698}" + } + } + } + }, + { + "Key": { + "id": 1685762441320719908 + }, + "Value": { + "ComponentData": { + "{5F84B500-8C45-40D1-8EFC-A5306B241444}": { + "$type": "SceneComponentSaveData", + "ViewParams": { + "AnchorX": -349.0, + "AnchorY": 10.0 + } + } + } + } + } + ], + "StatisticsHelper": { + "InstanceCounter": [ + { + "Key": 4199610336680704683, + "Value": 1 + }, + { + "Key": 4847610523576971761, + "Value": 1 + }, + { + "Key": 6462358712820489356, + "Value": 1 + }, + { + "Key": 7087687843968394353, + "Value": 1 + }, + { + "Key": 8679770052035517025, + "Value": 1 + }, + { + "Key": 10684225535275896474, + "Value": 3 + }, + { + "Key": 11983076003173356132, + "Value": 1 + }, + { + "Key": 13774516196858047560, + "Value": 1 + }, + { + "Key": 13774516226790665785, + "Value": 1 + } + ] + } + }, + "Component_[630514155173445772]": { + "$type": "EditorGraphVariableManagerComponent", + "Id": 630514155173445772 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/GlobalGameData.scriptcanvas b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/GlobalGameData.scriptcanvas new file mode 100644 index 0000000000..3ba5cc6b7d --- /dev/null +++ b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/GlobalGameData.scriptcanvas @@ -0,0 +1,662 @@ +{ + "Type": "JsonSerialization", + "Version": 1, + "ClassName": "ScriptCanvasData", + "ClassData": { + "m_scriptCanvas": { + "Id": { + "id": 17732469402520 + }, + "Name": "Untitled-1", + "Components": { + "Component_[16492301523567686923]": { + "$type": "{4D755CA9-AB92-462C-B24F-0B3376F19967} Graph", + "Id": 16492301523567686923, + "m_graphData": { + "m_nodes": [ + { + "Id": { + "id": 17741059337112 + }, + "Name": "SC-Node(OperatorAdd)", + "Components": { + "Component_[11612963594766700030]": { + "$type": "OperatorAdd", + "Id": 11612963594766700030, + "Slots": [ + { + "id": { + "m_id": "{B7529112-C29F-45F0-811C-DB8EE18EB8B8}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "In", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{49618851-F6B2-4B90-BFDF-ADBAAA84BBA4}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Out", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{4612C904-82DF-4B48-8485-4C878AF9A4D1}" + }, + "DynamicTypeOverride": 3, + "contracts": [ + { + "$type": "SlotTypeContract" + }, + { + "$type": "MathOperatorContract", + "NativeTypes": [ + { + "m_type": 3 + }, + { + "m_type": 6 + }, + { + "m_type": 8 + }, + { + "m_type": 9 + }, + { + "m_type": 10 + }, + { + "m_type": 11 + }, + { + "m_type": 12 + }, + { + "m_type": 14 + }, + { + "m_type": 15 + } + ] + } + ], + "slotName": "Number", + "toolTip": "An operand to use in performing the specified Operation", + "DisplayDataType": { + "m_type": 3 + }, + "DisplayGroup": { + "Value": 1114760223 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DynamicGroup": { + "Value": 1114760223 + }, + "DataType": 1, + "IsReference": true, + "VariableReference": { + "m_id": "{8451E795-6A0E-44CE-81FD-AEF0EE5B0400}" + } + }, + { + "id": { + "m_id": "{610B3BFB-9043-47A0-9694-5F14A1947E36}" + }, + "DynamicTypeOverride": 3, + "contracts": [ + { + "$type": "SlotTypeContract" + }, + { + "$type": "MathOperatorContract", + "NativeTypes": [ + { + "m_type": 3 + }, + { + "m_type": 6 + }, + { + "m_type": 8 + }, + { + "m_type": 9 + }, + { + "m_type": 10 + }, + { + "m_type": 11 + }, + { + "m_type": 12 + }, + { + "m_type": 14 + }, + { + "m_type": 15 + } + ] + } + ], + "slotName": "Number", + "toolTip": "An operand to use in performing the specified Operation", + "DisplayDataType": { + "m_type": 3 + }, + "DisplayGroup": { + "Value": 1114760223 + }, + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DynamicGroup": { + "Value": 1114760223 + }, + "DataType": 1 + }, + { + "id": { + "m_id": "{36FFF1AB-C208-47CB-8271-436C85E0AE42}" + }, + "DynamicTypeOverride": 3, + "contracts": [ + { + "$type": "SlotTypeContract" + }, + { + "$type": "MathOperatorContract", + "NativeTypes": [ + { + "m_type": 3 + }, + { + "m_type": 6 + }, + { + "m_type": 8 + }, + { + "m_type": 9 + }, + { + "m_type": 10 + }, + { + "m_type": 11 + }, + { + "m_type": 12 + }, + { + "m_type": 14 + }, + { + "m_type": 15 + } + ] + } + ], + "slotName": "Result", + "toolTip": "The result of the specified operation", + "DisplayDataType": { + "m_type": 3 + }, + "DisplayGroup": { + "Value": 1114760223 + }, + "Descriptor": { + "ConnectionType": 2, + "SlotType": 2 + }, + "DynamicGroup": { + "Value": 1114760223 + }, + "DataType": 1, + "IsReference": true, + "VariableReference": { + "m_id": "{8451E795-6A0E-44CE-81FD-AEF0EE5B0400}" + } + } + ], + "Datums": [ + { + "isOverloadedStorage": false, + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 0.0, + "label": "Number" + }, + { + "isOverloadedStorage": false, + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 1.0, + "label": "Number" + } + ] + } + } + }, + { + "Id": { + "id": 17736764369816 + }, + "Name": "ReceiveScriptEvent", + "Components": { + "Component_[16408183651077237195]": { + "$type": "ReceiveScriptEvent", + "Id": 16408183651077237195, + "Slots": [ + { + "id": { + "m_id": "{8DC10581-B8DF-473C-9C75-996111DBF560}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Connect", + "toolTip": "Connect this event handler to the specified entity.", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{E60D1951-E56D-41F8-84C5-AD0BA803DD51}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Disconnect", + "toolTip": "Disconnect this event handler.", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{1BCE6CAC-B1C0-43FA-B4F5-E9A34D5064E5}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "OnConnected", + "toolTip": "Signaled when a connection has taken place.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{FEB42E9A-D562-4BBD-90AB-32255124BFE8}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "OnDisconnected", + "toolTip": "Signaled when this event handler is disconnected.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{C9EF936B-8C74-42B4-8793-67FC7FD3BCBC}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "OnFailure", + "toolTip": "Signaled when it is not possible to connect this handler.", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + } + }, + { + "id": { + "m_id": "{76985C7A-761A-4CEF-9F55-6DD2B136317A}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "ExecutionSlot:NewPlayerScriptActive", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + }, + "IsLatent": true + }, + { + "id": { + "m_id": "{5CD8E1E9-6192-4B7D-9C2C-6C18BE99CF44}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "Number", + "Descriptor": { + "ConnectionType": 1, + "SlotType": 2 + }, + "DataType": 1, + "IsReference": true, + "VariableReference": { + "m_id": "{8451E795-6A0E-44CE-81FD-AEF0EE5B0400}" + } + }, + { + "id": { + "m_id": "{9FDB71AA-0F19-406D-82CA-508A2CA10F95}" + }, + "contracts": [ + { + "$type": "SlotTypeContract" + } + ], + "slotName": "ExecutionSlot:GetNumberOfActivePlayers", + "Descriptor": { + "ConnectionType": 2, + "SlotType": 1 + }, + "IsLatent": true + } + ], + "Datums": [ + { + "isOverloadedStorage": false, + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 0.0, + "label": "Number" + } + ], + "m_version": 1, + "m_eventMap": [ + { + "Key": { + "Value": 242067946 + }, + "Value": { + "m_scriptEventAssetId": { + "guid": "{FE1B1992-8220-5DD3-A60A-AEC85EB91C54}" + }, + "m_eventName": "GetNumberOfActivePlayers", + "m_eventSlotId": { + "m_id": "{9FDB71AA-0F19-406D-82CA-508A2CA10F95}" + }, + "m_resultSlotId": { + "m_id": "{5CD8E1E9-6192-4B7D-9C2C-6C18BE99CF44}" + } + } + }, + { + "Key": { + "Value": 2930121176 + }, + "Value": { + "m_scriptEventAssetId": { + "guid": "{FE1B1992-8220-5DD3-A60A-AEC85EB91C54}" + }, + "m_eventName": "NewPlayerScriptActive", + "m_eventSlotId": { + "m_id": "{76985C7A-761A-4CEF-9F55-6DD2B136317A}" + } + } + } + ], + "m_eventSlotMapping": { + "{155BF981-AD70-4D29-81A6-1517FAE59FB1}": { + "m_id": "{5CD8E1E9-6192-4B7D-9C2C-6C18BE99CF44}" + }, + "{65D394D3-F90D-4F10-94BF-F5E1581CF2CF}": { + "m_id": "{76985C7A-761A-4CEF-9F55-6DD2B136317A}" + }, + "{67784749-9B41-429C-9C97-3D296182EB67}": { + "m_id": "{9FDB71AA-0F19-406D-82CA-508A2CA10F95}" + } + }, + "m_scriptEventAssetId": { + "guid": "{FE1B1992-8220-5DD3-A60A-AEC85EB91C54}" + }, + "m_asset": { + "assetId": { + "guid": "{FE1B1992-8220-5DD3-A60A-AEC85EB91C54}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/globalgamedata.scriptevents" + } + } + } + } + ], + "m_connections": [ + { + "Id": { + "id": 17745354304408 + }, + "Name": "srcEndpoint=(Receive Script Event: ExecutionSlot:NewPlayerScriptActive), destEndpoint=(Add (+): In)", + "Components": { + "Component_[8782209668839578826]": { + "$type": "{64CA5016-E803-4AC4-9A36-BDA2C890C6EB} Connection", + "Id": 8782209668839578826, + "sourceEndpoint": { + "nodeId": { + "id": 17736764369816 + }, + "slotId": { + "m_id": "{76985C7A-761A-4CEF-9F55-6DD2B136317A}" + } + }, + "targetEndpoint": { + "nodeId": { + "id": 17741059337112 + }, + "slotId": { + "m_id": "{B7529112-C29F-45F0-811C-DB8EE18EB8B8}" + } + } + } + } + } + ], + "m_scriptEventAssets": [ + [ + { + "id": 17736764369816 + }, + {} + ] + ] + }, + "m_assetType": "{3E2AC8CD-713F-453E-967F-29517F331784}", + "versionData": { + "_grammarVersion": 1, + "_runtimeVersion": 1, + "_fileVersion": 1 + }, + "m_variableCounter": 1, + "GraphCanvasData": [ + { + "Key": { + "id": 17732469402520 + }, + "Value": { + "ComponentData": { + "{5F84B500-8C45-40D1-8EFC-A5306B241444}": { + "$type": "SceneComponentSaveData" + } + } + } + }, + { + "Key": { + "id": 17736764369816 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + -360.0, + -60.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{C419A1CF-CBA8-416B-BF6C-4B574C3E59E3}" + }, + "{D8BBE799-7E4D-495A-B69A-1E3940670891}": { + "$type": "ScriptEventReceiverHandlerNodeDescriptorSaveData", + "EventNames": [ + [ + { + "Value": 242067946 + }, + "GetNumberOfActivePlayers" + ], + [ + { + "Value": 2930121176 + }, + "NewPlayerScriptActive" + ] + ] + } + } + } + }, + { + "Key": { + "id": 17741059337112 + }, + "Value": { + "ComponentData": { + "{24CB38BB-1705-4EC5-8F63-B574571B4DCD}": { + "$type": "NodeSaveData" + }, + "{328FF15C-C302-458F-A43D-E1794DE0904E}": { + "$type": "GeneralNodeTitleComponentSaveData", + "PaletteOverride": "MathNodeTitlePalette" + }, + "{7CC444B1-F9B3-41B5-841B-0C4F2179F111}": { + "$type": "GeometrySaveData", + "Position": [ + 120.0, + 100.0 + ] + }, + "{B0B99C8A-03AF-4CF6-A926-F65C874C3D97}": { + "$type": "StylingComponentSaveData" + }, + "{B1F49A35-8408-40DA-B79E-F1E3B64322CE}": { + "$type": "PersistentIdComponentSaveData", + "PersistentId": "{0D0751AD-8164-4196-9C09-8CDB9AAA296F}" + } + } + } + } + ], + "StatisticsHelper": { + "InstanceCounter": [ + { + "Key": 1244476766431948410, + "Value": 1 + }, + { + "Key": 1678857390775488101, + "Value": 1 + }, + { + "Key": 1678857392390856307, + "Value": 1 + } + ] + } + }, + "Component_[16498171485036643402]": { + "$type": "EditorGraphVariableManagerComponent", + "Id": 16498171485036643402, + "m_variableData": { + "m_nameVariableMap": [ + { + "Key": { + "m_id": "{8451E795-6A0E-44CE-81FD-AEF0EE5B0400}" + }, + "Value": { + "Datum": { + "isOverloadedStorage": false, + "scriptCanvasType": { + "m_type": 3 + }, + "isNullPointer": false, + "$type": "double", + "value": 0.0 + }, + "VariableId": { + "m_id": "{8451E795-6A0E-44CE-81FD-AEF0EE5B0400}" + }, + "VariableName": "ActivePlayerCount" + } + } + ] + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/GlobalGameData.scriptevents b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/GlobalGameData.scriptevents new file mode 100644 index 0000000000..059713e14b --- /dev/null +++ b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/GlobalGameData.scriptevents @@ -0,0 +1,106 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/Player.prefab b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/Player.prefab new file mode 100644 index 0000000000..2653809dda --- /dev/null +++ b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/Player.prefab @@ -0,0 +1,195 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "Player", + "Components": { + "Component_[10603663676997462041]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 10603663676997462041 + }, + "Component_[11066377844757909329]": { + "$type": "EditorPrefabComponent", + "Id": 11066377844757909329 + }, + "Component_[11664640320098005944]": { + "$type": "EditorEntityIconComponent", + "Id": 11664640320098005944 + }, + "Component_[12551690377468870725]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 12551690377468870725, + "Parent Entity": "" + }, + "Component_[16402163080075698011]": { + "$type": "EditorOnlyEntityComponent", + "Id": 16402163080075698011 + }, + "Component_[3491366785918494447]": { + "$type": "EditorLockComponent", + "Id": 3491366785918494447 + }, + "Component_[4830373679514129871]": { + "$type": "EditorVisibilityComponent", + "Id": 4830373679514129871 + }, + "Component_[5144323498211834874]": { + "$type": "SelectionComponent", + "Id": 5144323498211834874 + }, + "Component_[5267607163086533733]": { + "$type": "EditorInspectorComponent", + "Id": 5267607163086533733 + }, + "Component_[6678300504118618849]": { + "$type": "EditorPendingCompositionComponent", + "Id": 6678300504118618849 + }, + "Component_[8384628950786300469]": { + "$type": "EditorEntitySortComponent", + "Id": 8384628950786300469, + "Child Entity Order": [ + "Entity_[10070247746456]" + ] + } + } + }, + "Entities": { + "Entity_[10070247746456]": { + "Id": "Entity_[10070247746456]", + "Name": "Player", + "Components": { + "Component_[1059478843478789313]": { + "$type": "EditorInspectorComponent", + "Id": 1059478843478789313, + "ComponentOrderEntryArray": [ + { + "ComponentId": 9878555871810913249 + }, + { + "ComponentId": 11481641385923146202, + "SortIndex": 1 + }, + { + "ComponentId": 11440172471478606933, + "SortIndex": 2 + }, + { + "ComponentId": 17461691807054668218, + "SortIndex": 3 + }, + { + "ComponentId": 15530420875454157766, + "SortIndex": 4 + }, + { + "ComponentId": 10596595655489113153, + "SortIndex": 5 + } + ] + }, + "Component_[10596595655489113153]": { + "$type": "EditorScriptCanvasComponent", + "Id": 10596595655489113153, + "m_name": "AutoComponent_RPC", + "m_assetHolder": { + "m_asset": { + "assetId": { + "guid": "{5ED120C4-07DC-56F1-80A7-37BFC98FD74E}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/autocomponent_rpc.scriptcanvas" + } + }, + "runtimeDataIsValid": true, + "runtimeDataOverrides": { + "source": { + "assetId": { + "guid": "{5ED120C4-07DC-56F1-80A7-37BFC98FD74E}" + }, + "assetHint": "levels/multiplayer/autocomponent_rpc/autocomponent_rpc.scriptcanvas" + } + } + }, + "Component_[11440172471478606933]": { + "$type": "GenericComponentWrapper", + "Id": 11440172471478606933, + "m_template": { + "$type": "Multiplayer::NetworkTransformComponent" + } + }, + "Component_[11481641385923146202]": { + "$type": "GenericComponentWrapper", + "Id": 11481641385923146202, + "m_template": { + "$type": "NetBindComponent" + } + }, + "Component_[13110996849704981748]": { + "$type": "EditorVisibilityComponent", + "Id": 13110996849704981748 + }, + "Component_[1472895075383059499]": { + "$type": "EditorLockComponent", + "Id": 1472895075383059499 + }, + "Component_[1526920553231193509]": { + "$type": "EditorPendingCompositionComponent", + "Id": 1526920553231193509 + }, + "Component_[15530420875454157766]": { + "$type": "GenericComponentWrapper", + "Id": 15530420875454157766, + "m_template": { + "$type": "Multiplayer::LocalPredictionPlayerInputComponent" + } + }, + "Component_[1699895912837266792]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1699895912837266792 + }, + "Component_[17461691807054668218]": { + "$type": "GenericComponentWrapper", + "Id": 17461691807054668218, + "m_template": { + "$type": "AutomatedTesting::NetworkTestPlayerComponent" + } + }, + "Component_[3622545398462507871]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3622545398462507871 + }, + "Component_[5778259918231688598]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5778259918231688598, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{F322592F-43BC-50E7-903C-CC231846093F}", + "subId": 276443623 + }, + "assetHint": "objects/_primitives/_cylinder_1x1.azmodel" + } + } + } + }, + "Component_[7004633483882343256]": { + "$type": "SelectionComponent", + "Id": 7004633483882343256 + }, + "Component_[8469628382507693850]": { + "$type": "EditorEntitySortComponent", + "Id": 8469628382507693850 + }, + "Component_[9407892837096707905]": { + "$type": "EditorEntityIconComponent", + "Id": 9407892837096707905 + }, + "Component_[9878555871810913249]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 9878555871810913249, + "Parent Entity": "ContainerEntity" + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/tags.txt b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/tags.txt new file mode 100644 index 0000000000..0d6c1880e7 --- /dev/null +++ b/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/tags.txt @@ -0,0 +1,12 @@ +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 diff --git a/AutomatedTesting/Levels/Performance/10KEntityCpuPerfTest/10KEntityCpuPerfTest.prefab b/AutomatedTesting/Levels/Performance/10KEntityCpuPerfTest/10KEntityCpuPerfTest.prefab new file mode 100644 index 0000000000..5024ca9192 --- /dev/null +++ b/AutomatedTesting/Levels/Performance/10KEntityCpuPerfTest/10KEntityCpuPerfTest.prefab @@ -0,0 +1,1032 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]", + "Instance_[470615713748]/ContainerEntity", + "Instance_[62786296211412]/ContainerEntity", + "Instance_[513945563413]/ContainerEntity", + "Instance_[612729811221]/ContainerEntity", + "Instance_[745873797397]/ContainerEntity" + ] + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 4792520350429473643 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[12198510776899974386]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 12198510776899974386, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + } + }, + "Instances": { + "Instance_[470615713748]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[513945563413]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 10.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[612729811221]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 15.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[62786296211412]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 5.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873797397]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 20.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873797497]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 25.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873797597]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 30.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873797697]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 35.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873797797]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 40.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873797897]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 45.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873797997]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798097]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 55.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798197]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 60.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798297]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 65.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798397]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 70.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798497]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 75.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798597]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 80.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798697]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 85.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798797]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 90.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798897]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 95.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873798997]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 100.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[745873799097]": { + "Source": "Prefabs/TestData/Graphics/AtomCubeWall.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Parent Entity", + "value": "../Entity_[1146574390643]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/0", + "value": 50.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/1", + "value": 105.0 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5052757994340238524]/Transform Data/Translate/2", + "value": 1.0 + } + ] + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Performance/10KEntityCpuPerfTest/tags.txt b/AutomatedTesting/Levels/Performance/10KEntityCpuPerfTest/tags.txt new file mode 100644 index 0000000000..0d6c1880e7 --- /dev/null +++ b/AutomatedTesting/Levels/Performance/10KEntityCpuPerfTest/tags.txt @@ -0,0 +1,12 @@ +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 diff --git a/AutomatedTesting/Levels/Performance/10kVegInstancesTest/10KVegInstancesTest.prefab b/AutomatedTesting/Levels/Performance/10kVegInstancesTest/10KVegInstancesTest.prefab new file mode 100644 index 0000000000..4e6b17de73 --- /dev/null +++ b/AutomatedTesting/Levels/Performance/10kVegInstancesTest/10KVegInstancesTest.prefab @@ -0,0 +1,4216 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]", + "Entity_[655472831242]", + "Entity_[659767798538]" + ] + }, + "Component_[14900044899939389494]": { + "$type": "EditorDebugComponent", + "Id": 14900044899939389494, + "Configuration": { + "ShowDebugStats": true + } + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[16599802339219703605]": { + "$type": "EditorLevelSettingsComponent", + "Id": 16599802339219703605, + "Configuration": { + "AreaSystemConfig": { + "ViewRectangleSize": 25, + "SectorDensity": 2, + "SectorSizeInMeters": 10 + } + } + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 17772187112516355261 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1172344194419]": { + "Id": "Entity_[1172344194419]", + "Name": "Shader Ball", + "Components": { + "Component_[10789351944715265527]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10789351944715265527 + }, + "Component_[12037033284781049225]": { + "$type": "EditorEntitySortComponent", + "Id": 12037033284781049225 + }, + "Component_[13759153306105970079]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13759153306105970079 + }, + "Component_[14135560884830586279]": { + "$type": "EditorInspectorComponent", + "Id": 14135560884830586279 + }, + "Component_[16247165675903986673]": { + "$type": "EditorVisibilityComponent", + "Id": 16247165675903986673 + }, + "Component_[18082433625958885247]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18082433625958885247 + }, + "Component_[6472623349872972660]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6472623349872972660, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Rotate": [ + 0.0, + 0.10000000149011612, + 180.0 + ] + } + }, + "Component_[6495255223970673916]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 6495255223970673916, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{FD340C30-755C-5911-92A3-19A3F7A77931}", + "subId": 281415304 + }, + "assetHint": "objects/shaderball/shaderball_default_1m.azmodel" + } + } + } + }, + "Component_[8056625192494070973]": { + "$type": "SelectionComponent", + "Id": 8056625192494070973 + }, + "Component_[8550141614185782969]": { + "$type": "EditorEntityIconComponent", + "Id": 8550141614185782969 + }, + "Component_[9439770997198325425]": { + "$type": "EditorLockComponent", + "Id": 9439770997198325425 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1172344194419]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11231930600558681245]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 11231930600558681245, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + }, + "Entity_[2994134174757065]": { + "Id": "Entity_[2994134174757065]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 31.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994138469724361]": { + "Id": "Entity_[2994138469724361]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 33.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994142764691657]": { + "Id": "Entity_[2994142764691657]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 29.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994147059658953]": { + "Id": "Entity_[2994147059658953]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 27.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994151354626249]": { + "Id": "Entity_[2994151354626249]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 19.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994155649593545]": { + "Id": "Entity_[2994155649593545]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 25.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994159944560841]": { + "Id": "Entity_[2994159944560841]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 37.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994164239528137]": { + "Id": "Entity_[2994164239528137]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 35.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994168534495433]": { + "Id": "Entity_[2994168534495433]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 21.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[2994172829462729]": { + "Id": "Entity_[2994172829462729]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 23.24283218383789 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446213842399433]": { + "Id": "Entity_[3446213842399433]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 49.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446218137366729]": { + "Id": "Entity_[3446218137366729]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 41.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446222432334025]": { + "Id": "Entity_[3446222432334025]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 45.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446226727301321]": { + "Id": "Entity_[3446226727301321]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 57.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446231022268617]": { + "Id": "Entity_[3446231022268617]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 53.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446235317235913]": { + "Id": "Entity_[3446235317235913]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 43.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446239612203209]": { + "Id": "Entity_[3446239612203209]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 51.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446243907170505]": { + "Id": "Entity_[3446243907170505]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 47.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446248202137801]": { + "Id": "Entity_[3446248202137801]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 39.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[3446252497105097]": { + "Id": "Entity_[3446252497105097]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 55.431697845458984 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073064319250633]": { + "Id": "Entity_[4073064319250633]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 72.24310302734375 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073068614217929]": { + "Id": "Entity_[4073068614217929]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 60.243099212646484 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073072909185225]": { + "Id": "Entity_[4073072909185225]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 78.24310302734375 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073077204152521]": { + "Id": "Entity_[4073077204152521]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 68.24310302734375 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073081499119817]": { + "Id": "Entity_[4073081499119817]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 62.243099212646484 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073085794087113]": { + "Id": "Entity_[4073085794087113]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 76.24310302734375 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073090089054409]": { + "Id": "Entity_[4073090089054409]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 70.24310302734375 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073094384021705]": { + "Id": "Entity_[4073094384021705]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 64.24310302734375 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073098678989001]": { + "Id": "Entity_[4073098678989001]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 66.24310302734375 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[4073102973956297]": { + "Id": "Entity_[4073102973956297]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 74.24310302734375 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[612523158282]": { + "Id": "Entity_[612523158282]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 0.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[616818125578]": { + "Id": "Entity_[616818125578]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 18.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[621113092874]": { + "Id": "Entity_[621113092874]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 2.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[625408060170]": { + "Id": "Entity_[625408060170]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 16.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[629703027466]": { + "Id": "Entity_[629703027466]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 14.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[633997994762]": { + "Id": "Entity_[633997994762]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 12.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[638292962058]": { + "Id": "Entity_[638292962058]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 4.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[642587929354]": { + "Id": "Entity_[642587929354]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 10.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[646882896650]": { + "Id": "Entity_[646882896650]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 8.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[651177863946]": { + "Id": "Entity_[651177863946]", + "Name": "Surface", + "Components": { + "Component_[11461736083966389166]": { + "$type": "EditorSurfaceDataShapeComponent", + "Id": 11461736083966389166 + }, + "Component_[13283029886763197381]": { + "$type": "EditorLockComponent", + "Id": 13283029886763197381 + }, + "Component_[14567565716714370511]": { + "$type": "SelectionComponent", + "Id": 14567565716714370511 + }, + "Component_[14826005606950858247]": { + "$type": "EditorEntitySortComponent", + "Id": 14826005606950858247 + }, + "Component_[15952534836289892585]": { + "$type": "EditorInspectorComponent", + "Id": 15952534836289892585 + }, + "Component_[16429683758229234581]": { + "$type": "EditorPendingCompositionComponent", + "Id": 16429683758229234581 + }, + "Component_[3145304225809715428]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 3145304225809715428, + "Parent Entity": "Entity_[655472831242]", + "Transform Data": { + "Translate": [ + 24.860464096069336, + 6.0520172119140625, + 6.0 + ] + } + }, + "Component_[3194434268397003277]": { + "$type": "EditorBoxShapeComponent", + "Id": 3194434268397003277, + "Visible": false, + "DisplayFilled": false, + "BoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 0.10000000149011612 + ] + } + } + }, + "Component_[5124743265172522601]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5124743265172522601 + }, + "Component_[6141261141385234831]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6141261141385234831 + }, + "Component_[8075217947437400102]": { + "$type": "EditorVisibilityComponent", + "Id": 8075217947437400102 + }, + "Component_[9742596769363363433]": { + "$type": "EditorEntityIconComponent", + "Id": 9742596769363363433 + } + } + }, + "Entity_[655472831242]": { + "Id": "Entity_[655472831242]", + "Name": "Surfaces", + "Components": { + "Component_[11463830567025741777]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11463830567025741777, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 25.139535903930664, + 43.94798278808594, + 0.0 + ] + } + }, + "Component_[16576383876931487287]": { + "$type": "EditorLockComponent", + "Id": 16576383876931487287 + }, + "Component_[17475328349202721984]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 17475328349202721984 + }, + "Component_[2693664693208376125]": { + "$type": "EditorVisibilityComponent", + "Id": 2693664693208376125 + }, + "Component_[3772848404212958248]": { + "$type": "EditorInspectorComponent", + "Id": 3772848404212958248 + }, + "Component_[3891212684133169478]": { + "$type": "SelectionComponent", + "Id": 3891212684133169478 + }, + "Component_[4930031329153667734]": { + "$type": "EditorEntityIconComponent", + "Id": 4930031329153667734 + }, + "Component_[5015604486311198963]": { + "$type": "EditorEntitySortComponent", + "Id": 5015604486311198963, + "Child Entity Order": [ + "Entity_[612523158282]", + "Entity_[621113092874]", + "Entity_[638292962058]", + "Entity_[651177863946]", + "Entity_[646882896650]", + "Entity_[642587929354]", + "Entity_[633997994762]", + "Entity_[629703027466]", + "Entity_[625408060170]", + "Entity_[616818125578]", + "Entity_[2994164239528137]", + "Entity_[2994155649593545]", + "Entity_[2994134174757065]", + "Entity_[2994142764691657]", + "Entity_[2994138469724361]", + "Entity_[2994159944560841]", + "Entity_[2994151354626249]", + "Entity_[2994147059658953]", + "Entity_[2994172829462729]", + "Entity_[2994168534495433]", + "Entity_[3446243907170505]", + "Entity_[3446213842399433]", + "Entity_[3446239612203209]", + "Entity_[3446226727301321]", + "Entity_[3446218137366729]", + "Entity_[3446231022268617]", + "Entity_[3446222432334025]", + "Entity_[3446252497105097]", + "Entity_[3446248202137801]", + "Entity_[3446235317235913]", + "Entity_[4073090089054409]", + "Entity_[4073064319250633]", + "Entity_[4073077204152521]", + "Entity_[4073068614217929]", + "Entity_[4073072909185225]", + "Entity_[4073081499119817]", + "Entity_[4073085794087113]", + "Entity_[4073102973956297]", + "Entity_[4073094384021705]", + "Entity_[4073098678989001]" + ] + }, + "Component_[7096718211285552582]": { + "$type": "EditorOnlyEntityComponent", + "Id": 7096718211285552582 + }, + "Component_[8091190759736241533]": { + "$type": "EditorPendingCompositionComponent", + "Id": 8091190759736241533 + } + } + }, + "Entity_[659767798538]": { + "Id": "Entity_[659767798538]", + "Name": "VegArea", + "Components": { + "Component_[10457867987348570858]": { + "$type": "EditorInspectorComponent", + "Id": 10457867987348570858 + }, + "Component_[1229363445910756890]": { + "$type": "{DD96FD51-A86B-48BC-A6AB-89183B538269} EditorSpawnerComponent", + "Id": 1229363445910756890, + "PreviewEntity": "Entity_[659767798538]" + }, + "Component_[12481711086985445589]": { + "$type": "EditorVisibilityComponent", + "Id": 12481711086985445589 + }, + "Component_[14421356574908560819]": { + "$type": "EditorAxisAlignedBoxShapeComponent", + "Id": 14421356574908560819, + "Visible": false, + "DisplayFilled": false, + "AxisAlignedBoxShape": { + "Configuration": { + "IsFilled": false, + "Dimensions": [ + 200.0, + 200.0, + 200.0 + ] + } + } + }, + "Component_[14627293932927606859]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 14627293932927606859, + "Parent Entity": "Entity_[1146574390643]", + "Transform Data": { + "Translate": [ + 25.139535903930664, + 43.94798278808594, + 0.0 + ] + } + }, + "Component_[16742116787858765489]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16742116787858765489 + }, + "Component_[17369607211365211528]": { + "$type": "EditorEntitySortComponent", + "Id": 17369607211365211528, + "Child Entity Order": [ + "Instance_[919926567113]/ContainerEntity", + "Instance_[1031595716809]/ContainerEntity", + "Instance_[1160444735689]/ContainerEntity", + "Instance_[1306473623753]/ContainerEntity", + "Instance_[1469682381001]/ContainerEntity", + "Instance_[1650071007433]/ContainerEntity", + "Instance_[1847639503049]/ContainerEntity", + "Instance_[2062387867849]/ContainerEntity", + "Instance_[2294316101833]/ContainerEntity", + "Instance_[2543424205001]/ContainerEntity", + "Instance_[2809712177353]/ContainerEntity", + "Instance_[3093180018889]/ContainerEntity", + "Instance_[3398122696905]/ContainerEntity" + ] + }, + "Component_[17539394596964090620]": { + "$type": "EditorDescriptorListComponent", + "Id": 17539394596964090620, + "Configuration": { + "Descriptors": [ + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{60CF6C60-8620-5173-814C-ED8B0C395BA7}", + "subId": 1611714993 + }, + "assetHint": "prefabs/testdata/graphics/cubealuminumpolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{B030470B-92ED-5673-B108-5BD3C31A3795}", + "subId": 2910987375 + }, + "assetHint": "prefabs/testdata/graphics/cubebrasspolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{D4AC76BB-BA32-5787-A862-3C6296503126}", + "subId": 1351414441 + }, + "assetHint": "prefabs/testdata/graphics/cubechromepolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{6E0DF0BD-2B50-5353-A063-88AAEEBED799}", + "subId": 1382904365 + }, + "assetHint": "prefabs/testdata/graphics/cubecobaltpolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{CB9E61C4-1122-56D8-8906-2FF8FC4D1876}", + "subId": 3884585917 + }, + "assetHint": "prefabs/testdata/graphics/cubecopperpolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{9105AA91-FE70-56C2-BA83-E08F268C333F}", + "subId": 2449326585 + }, + "assetHint": "prefabs/testdata/graphics/cubegoldpolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{7DB86E6D-05C1-5B3C-88B4-DC9039005E1F}", + "subId": 932993536 + }, + "assetHint": "prefabs/testdata/graphics/cubeironpolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{D8EEB566-07A9-5F39-9B89-66492858F178}", + "subId": 2937511027 + }, + "assetHint": "prefabs/testdata/graphics/cubemercurypbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{7988D594-BA33-5843-886B-9E23FD9B1B3F}", + "subId": 3637668335 + }, + "assetHint": "prefabs/testdata/graphics/cubenickelpolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{CDDFE051-9910-5CD5-BD62-6FC729910CE5}", + "subId": 3334536131 + }, + "assetHint": "prefabs/testdata/graphics/cubepalladiumpolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{F336F1A7-7FDF-5972-A48E-58DC83D152A4}", + "subId": 610633662 + }, + "assetHint": "prefabs/testdata/graphics/cubeplatinumpolishedpbr.spawnable" + } + }, + "Advanced": true + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{32B00E51-BC05-5F03-A9AA-2D7AFE680EAC}", + "subId": 3534297619 + }, + "assetHint": "prefabs/testdata/graphics/cubesilverpolishedpbr.spawnable" + } + } + }, + { + "SpawnerType": "{74BEEDB5-81CF-409F-B375-0D93D81EF2E3}", + "InstanceSpawner": { + "$type": "PrefabInstanceSpawner", + "SpawnableAsset": { + "assetId": { + "guid": "{BBAB8640-03D2-5138-B52F-D031F29AF8C9}", + "subId": 923463205 + }, + "assetHint": "prefabs/testdata/graphics/cubetitaniumpolishedpbr.spawnable" + } + } + } + ] + } + }, + "Component_[2434532182352640072]": { + "$type": "EditorLockComponent", + "Id": 2434532182352640072 + }, + "Component_[6884260241620821202]": { + "$type": "SelectionComponent", + "Id": 6884260241620821202 + }, + "Component_[7575363224499024733]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7575363224499024733 + }, + "Component_[9440481613501976688]": { + "$type": "EditorEntityIconComponent", + "Id": 9440481613501976688 + }, + "Component_[9636552512161785427]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9636552512161785427 + } + } + } + }, + "Instances": { + "Instance_[1031595716809]": { + "Source": "Prefabs/TestData/Graphics/CubeAluminumPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[1006636009791072742]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[1006636009791072742]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[1006636009791072742]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[1160444735689]": { + "Source": "Prefabs/TestData/Graphics/CubeBrassPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[17333992135029064645]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[17333992135029064645]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[17333992135029064645]/Transform Data/Translate/1", + "value": 1.4970321655273438 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[17333992135029064645]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[1306473623753]": { + "Source": "Prefabs/TestData/Graphics/CubeChromePolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[15205683346512266293]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[15205683346512266293]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[15205683346512266293]/Transform Data/Translate/1", + "value": 3.06375503540039 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[15205683346512266293]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[1469682381001]": { + "Source": "Prefabs/TestData/Graphics/CubeCobaltPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[12811832964126776693]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[12811832964126776693]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[12811832964126776693]/Transform Data/Translate/1", + "value": 4.512233734130859 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[12811832964126776693]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[1650071007433]": { + "Source": "Prefabs/TestData/Graphics/CubeCopperPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5749675910289562089]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5749675910289562089]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5749675910289562089]/Transform Data/Translate/1", + "value": 5.966960906982422 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[5749675910289562089]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[1847639503049]": { + "Source": "Prefabs/TestData/Graphics/CubeGoldPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[11570676153379582500]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[11570676153379582500]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[11570676153379582500]/Transform Data/Translate/1", + "value": 7.424510955810547 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[11570676153379582500]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[2062387867849]": { + "Source": "Prefabs/TestData/Graphics/CubeIronPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[17506200912680653288]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[17506200912680653288]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[17506200912680653288]/Transform Data/Translate/1", + "value": 8.888202667236328 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[17506200912680653288]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[2294316101833]": { + "Source": "Prefabs/TestData/Graphics/CubeNickelPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[12821987693261496174]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[12821987693261496174]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[12821987693261496174]/Transform Data/Translate/1", + "value": 10.4295654296875 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[12821987693261496174]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[2543424205001]": { + "Source": "Prefabs/TestData/Graphics/CubePalladiumPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[16012620721047170064]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[16012620721047170064]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[16012620721047170064]/Transform Data/Translate/1", + "value": 12.071407318115234 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[16012620721047170064]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[2809712177353]": { + "Source": "Prefabs/TestData/Graphics/CubePlatinumPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[1499102502234135899]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[1499102502234135899]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[1499102502234135899]/Transform Data/Translate/1", + "value": 13.582500457763672 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[1499102502234135899]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[3093180018889]": { + "Source": "Prefabs/TestData/Graphics/CubeSilverPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[18049054501916401618]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[18049054501916401618]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[18049054501916401618]/Transform Data/Translate/1", + "value": 15.026111602783203 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[18049054501916401618]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[3398122696905]": { + "Source": "Prefabs/TestData/Graphics/CubeTitaniumPolishedPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[14924371629431224666]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[14924371629431224666]/Transform Data/Translate/0", + "value": -264.5232849121094 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[14924371629431224666]/Transform Data/Translate/1", + "value": 16.513294219970703 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[14924371629431224666]/Transform Data/Translate/2", + "value": 1.0 + } + ] + }, + "Instance_[919926567113]": { + "Source": "Prefabs/TestData/Graphics/CubeMercuryPBR.prefab", + "Patches": [ + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[2268958959705742396]/Parent Entity", + "value": "../Entity_[659767798538]" + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[2268958959705742396]/Transform Data/Translate/0", + "value": -270.14752197265625 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[2268958959705742396]/Transform Data/Translate/1", + "value": 10.24942398071289 + }, + { + "op": "replace", + "path": "/ContainerEntity/Components/Component_[2268958959705742396]/Transform Data/Translate/2", + "value": 1.0 + } + ] + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/Performance/10kVegInstancesTest/tags.txt b/AutomatedTesting/Levels/Performance/10kVegInstancesTest/tags.txt new file mode 100644 index 0000000000..0d6c1880e7 --- /dev/null +++ b/AutomatedTesting/Levels/Performance/10kVegInstancesTest/tags.txt @@ -0,0 +1,12 @@ +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 diff --git a/AutomatedTesting/Levels/Physics/Joints_HingeNoLimitsConstrained/Joints_HingeNoLimitsConstrained.ly b/AutomatedTesting/Levels/Physics/Joints_HingeNoLimitsConstrained/Joints_HingeNoLimitsConstrained.ly index 9babf84ba4..18b503bab5 100644 --- a/AutomatedTesting/Levels/Physics/Joints_HingeNoLimitsConstrained/Joints_HingeNoLimitsConstrained.ly +++ b/AutomatedTesting/Levels/Physics/Joints_HingeNoLimitsConstrained/Joints_HingeNoLimitsConstrained.ly @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:60276c07b45a734e4f71d695278167ea61e884f8b513906168c9642078ad5954 -size 6045 +oid sha256:0d004c329a7c5044a8fe05b6dbbf9b19de29c60acec75f13fdbc344a55aab8c7 +size 6404 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/0.ly b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/0.ly new file mode 100644 index 0000000000..b908d29eab --- /dev/null +++ b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/0.ly @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e89946c224d2e765931e8ba8e33133ac24651af321a404016d9a9ea8c323db6c +size 8563 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/filelist.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/filelist.xml new file mode 100644 index 0000000000..bb94b733b3 --- /dev/null +++ b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/filelist.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/level.pak b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/level.pak new file mode 100644 index 0000000000..614e41c4b2 --- /dev/null +++ b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/level.pak @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a46437ba86135567d87d43af0c4d499bf3cfe321721dbaf6e3cda8e49427ee1 +size 40212 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/tags.txt b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/tags.txt new file mode 100644 index 0000000000..0d6c1880e7 --- /dev/null +++ b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/tags.txt @@ -0,0 +1,12 @@ +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/terraintexture.pak b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/terraintexture.pak similarity index 100% rename from AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/terraintexture.pak rename to AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/0/terraintexture.pak diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/1.ly b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/1.ly new file mode 100644 index 0000000000..216426fc2a --- /dev/null +++ b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/1.ly @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:95996da3902d885060e700c573d13144bab246b930dfeedaed6066c13c879b11 +size 8737 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/filelist.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/filelist.xml new file mode 100644 index 0000000000..5f5b4928fc --- /dev/null +++ b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/filelist.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/level.pak b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/level.pak new file mode 100644 index 0000000000..d920770374 --- /dev/null +++ b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/level.pak @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:894dfd4ab92aa4d1d6003aebf82cf7ff854a8b3684e010234e073879f88b64e5 +size 40210 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/tags.txt b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/tags.txt new file mode 100644 index 0000000000..0d6c1880e7 --- /dev/null +++ b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/tags.txt @@ -0,0 +1,12 @@ +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 +0,0,0,0,0,0 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/terraintexture.pak b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/terraintexture.pak similarity index 100% rename from AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/terraintexture.pak rename to AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/1/terraintexture.pak diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/C15425935_Material_LibraryUpdatedAcrossLevels_0.ly b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/C15425935_Material_LibraryUpdatedAcrossLevels_0.ly deleted file mode 100644 index a5953fc44b..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/C15425935_Material_LibraryUpdatedAcrossLevels_0.ly +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:969b77ee335d2a04524a27c765dd2f2bdee048661f3ff7be0766ba69d18d5842 -size 10409 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/filelist.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/filelist.xml deleted file mode 100644 index 9a78b1bfd5..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/filelist.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/level.pak b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/level.pak deleted file mode 100644 index 8e6b3b29cb..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/level.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:547d7fdfcd959569b69d78eb6f63c7c19fc90840d69ca2d46eca8a3e82b8db75 -size 39337 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/Environment.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/Environment.xml deleted file mode 100644 index 4ba36f66ae..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/Environment.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/GameTokens.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/GameTokens.xml deleted file mode 100644 index 668a4583bd..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/GameTokens.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/TerrainTexture.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/TerrainTexture.xml deleted file mode 100644 index f43df05b22..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/TerrainTexture.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/TimeOfDay.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/TimeOfDay.xml deleted file mode 100644 index 456d609b8a..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/TimeOfDay.xml +++ /dev/null @@ -1,356 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/VegetationMap.dat b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/VegetationMap.dat deleted file mode 100644 index dce5631cd0..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/leveldata/VegetationMap.dat +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:0e6a5435c928079b27796f6b202bbc2623e7e454244ddc099a3cadf33b7cb9e9 -size 63 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/terrain/terrain.pxheightfield b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/terrain/terrain.pxheightfield deleted file mode 100644 index 011356e521..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_0/terrain/terrain.pxheightfield +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:19096597087688692a225c1955f73d22c46354995fca1df8dff107a90c2f17a2 -size 4202594 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/C15425935_Material_LibraryUpdatedAcrossLevels_1.ly b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/C15425935_Material_LibraryUpdatedAcrossLevels_1.ly deleted file mode 100644 index 9f48f08a1b..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/C15425935_Material_LibraryUpdatedAcrossLevels_1.ly +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:29f752c141514cb4b50aea07e6b63de5c8f43149ddac37722e9ddb8b5f4a667d -size 9495 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/filelist.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/filelist.xml deleted file mode 100644 index 9a78b1bfd5..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/filelist.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/level.pak b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/level.pak deleted file mode 100644 index 8e6b3b29cb..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/level.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:547d7fdfcd959569b69d78eb6f63c7c19fc90840d69ca2d46eca8a3e82b8db75 -size 39337 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/Environment.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/Environment.xml deleted file mode 100644 index 4ba36f66ae..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/Environment.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/GameTokens.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/GameTokens.xml deleted file mode 100644 index 668a4583bd..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/GameTokens.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/TerrainTexture.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/TerrainTexture.xml deleted file mode 100644 index f43df05b22..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/TerrainTexture.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/TimeOfDay.xml b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/TimeOfDay.xml deleted file mode 100644 index 456d609b8a..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/TimeOfDay.xml +++ /dev/null @@ -1,356 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/VegetationMap.dat b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/VegetationMap.dat deleted file mode 100644 index dce5631cd0..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/leveldata/VegetationMap.dat +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:0e6a5435c928079b27796f6b202bbc2623e7e454244ddc099a3cadf33b7cb9e9 -size 63 diff --git a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/terrain/terrain.pxheightfield b/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/terrain/terrain.pxheightfield deleted file mode 100644 index 011356e521..0000000000 --- a/AutomatedTesting/Levels/Physics/Material_LibraryUpdatedAcrossLevels/C15425935_Material_LibraryUpdatedAcrossLevels_1/terrain/terrain.pxheightfield +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:19096597087688692a225c1955f73d22c46354995fca1df8dff107a90c2f17a2 -size 4202594 diff --git a/AutomatedTesting/Levels/Physics/RigidBody_KinematicModeWorks/RigidBody_KinematicModeWorks.ly b/AutomatedTesting/Levels/Physics/RigidBody_KinematicModeWorks/RigidBody_KinematicModeWorks.ly index d6052ffa7c..a4b28a9e96 100644 --- a/AutomatedTesting/Levels/Physics/RigidBody_KinematicModeWorks/RigidBody_KinematicModeWorks.ly +++ b/AutomatedTesting/Levels/Physics/RigidBody_KinematicModeWorks/RigidBody_KinematicModeWorks.ly @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cb97ada674d123c67d7a32eb65e81fa66472cf51f748054c4a4297649f2a0f40 -size 5568 +oid sha256:0f645243fb623258ed4b063c5a18ea414560496f97d7234782ca97884e0ed8f0 +size 5961 diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/Environment.xml b/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/Environment.xml deleted file mode 100644 index 4ba36f66ae..0000000000 --- a/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/Environment.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - - - diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/TerrainTexture.xml b/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/TerrainTexture.xml deleted file mode 100644 index f43df05b22..0000000000 --- a/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/TerrainTexture.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/TimeOfDay.xml b/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/TimeOfDay.xml deleted file mode 100644 index c5b404318e..0000000000 --- a/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/TimeOfDay.xml +++ /dev/null @@ -1,356 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/VegetationMap.dat b/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/VegetationMap.dat deleted file mode 100644 index dce5631cd0..0000000000 --- a/AutomatedTesting/Levels/TestDependenciesLevel/LevelData/VegetationMap.dat +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:0e6a5435c928079b27796f6b202bbc2623e7e454244ddc099a3cadf33b7cb9e9 -size 63 diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/TerrainTexture.pak b/AutomatedTesting/Levels/TestDependenciesLevel/TerrainTexture.pak deleted file mode 100644 index fe3604a050..0000000000 --- a/AutomatedTesting/Levels/TestDependenciesLevel/TerrainTexture.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8739c76e681f900923b900c9df0ef75cf421d39cabb54650c4b9ad19b6a76d85 -size 22 diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/TestDependenciesLevel.ly b/AutomatedTesting/Levels/TestDependenciesLevel/TestDependenciesLevel.ly deleted file mode 100644 index 95cc91cd6b..0000000000 --- a/AutomatedTesting/Levels/TestDependenciesLevel/TestDependenciesLevel.ly +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:825828fe7c183e765315f933a8b1eb25283739d34d62cb84c34e2dcb56591d6e -size 12415 diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/TestDependenciesLevel.prefab b/AutomatedTesting/Levels/TestDependenciesLevel/TestDependenciesLevel.prefab new file mode 100644 index 0000000000..cf30cb178c --- /dev/null +++ b/AutomatedTesting/Levels/TestDependenciesLevel/TestDependenciesLevel.prefab @@ -0,0 +1,555 @@ +{ + "ContainerEntity": { + "Id": "Entity_[1146574390643]", + "Name": "Level", + "Components": { + "Component_[10641544592923449938]": { + "$type": "EditorInspectorComponent", + "Id": 10641544592923449938 + }, + "Component_[12039882709170782873]": { + "$type": "EditorOnlyEntityComponent", + "Id": 12039882709170782873 + }, + "Component_[12265484671603697631]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12265484671603697631 + }, + "Component_[14126657869720434043]": { + "$type": "EditorEntitySortComponent", + "Id": 14126657869720434043, + "Child Entity Order": [ + "Entity_[1176639161715]" + ] + }, + "Component_[15230859088967841193]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15230859088967841193, + "Parent Entity": "" + }, + "Component_[16239496886950819870]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16239496886950819870 + }, + "Component_[5688118765544765547]": { + "$type": "EditorEntityIconComponent", + "Id": 5688118765544765547 + }, + "Component_[6545738857812235305]": { + "$type": "SelectionComponent", + "Id": 6545738857812235305 + }, + "Component_[7247035804068349658]": { + "$type": "EditorPrefabComponent", + "Id": 7247035804068349658 + }, + "Component_[9307224322037797205]": { + "$type": "EditorLockComponent", + "Id": 9307224322037797205 + }, + "Component_[9562516168917670048]": { + "$type": "EditorVisibilityComponent", + "Id": 9562516168917670048 + } + } + }, + "Entities": { + "Entity_[1155164325235]": { + "Id": "Entity_[1155164325235]", + "Name": "Sun", + "Components": { + "Component_[10440557478882592717]": { + "$type": "SelectionComponent", + "Id": 10440557478882592717 + }, + "Component_[13620450453324765907]": { + "$type": "EditorLockComponent", + "Id": 13620450453324765907 + }, + "Component_[2134313378593666258]": { + "$type": "EditorInspectorComponent", + "Id": 2134313378593666258 + }, + "Component_[234010807770404186]": { + "$type": "EditorVisibilityComponent", + "Id": 234010807770404186 + }, + "Component_[2970359110423865725]": { + "$type": "EditorEntityIconComponent", + "Id": 2970359110423865725 + }, + "Component_[3722854130373041803]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3722854130373041803 + }, + "Component_[5992533738676323195]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5992533738676323195 + }, + "Component_[7378860763541895402]": { + "$type": "AZ::Render::EditorDirectionalLightComponent", + "Id": 7378860763541895402, + "Controller": { + "Configuration": { + "Intensity": 1.0, + "CameraEntityId": "", + "ShadowFilterMethod": 1 + } + } + }, + "Component_[7892834440890947578]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 7892834440890947578, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + 0.0, + 0.0, + 13.487043380737305 + ], + "Rotate": [ + -76.13099670410156, + -0.847000002861023, + -15.8100004196167 + ] + } + }, + "Component_[8599729549570828259]": { + "$type": "EditorEntitySortComponent", + "Id": 8599729549570828259 + }, + "Component_[952797371922080273]": { + "$type": "EditorPendingCompositionComponent", + "Id": 952797371922080273 + } + } + }, + "Entity_[1159459292531]": { + "Id": "Entity_[1159459292531]", + "Name": "Ground", + "Components": { + "Component_[11701138785793981042]": { + "$type": "SelectionComponent", + "Id": 11701138785793981042 + }, + "Component_[12260880513256986252]": { + "$type": "EditorEntityIconComponent", + "Id": 12260880513256986252 + }, + "Component_[13711420870643673468]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 13711420870643673468 + }, + "Component_[138002849734991713]": { + "$type": "EditorOnlyEntityComponent", + "Id": 138002849734991713 + }, + "Component_[16578565737331764849]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16578565737331764849, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[16919232076966545697]": { + "$type": "EditorInspectorComponent", + "Id": 16919232076966545697 + }, + "Component_[5182430712893438093]": { + "$type": "EditorMaterialComponent", + "Id": 5182430712893438093 + }, + "Component_[5675108321710651991]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 5675108321710651991, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{0CD745C0-6AA8-569A-A68A-73A3270986C4}", + "subId": 277889906 + }, + "assetHint": "objects/groudplane/groundplane_512x512m.azmodel" + } + } + } + }, + "Component_[5681893399601237518]": { + "$type": "EditorEntitySortComponent", + "Id": 5681893399601237518 + }, + "Component_[592692962543397545]": { + "$type": "EditorPendingCompositionComponent", + "Id": 592692962543397545 + }, + "Component_[7090012899106946164]": { + "$type": "EditorLockComponent", + "Id": 7090012899106946164 + }, + "Component_[9410832619875640998]": { + "$type": "EditorVisibilityComponent", + "Id": 9410832619875640998 + } + } + }, + "Entity_[1163754259827]": { + "Id": "Entity_[1163754259827]", + "Name": "Camera", + "Components": { + "Component_[11895140916889160460]": { + "$type": "EditorEntityIconComponent", + "Id": 11895140916889160460 + }, + "Component_[16880285896855930892]": { + "$type": "{CA11DA46-29FF-4083-B5F6-E02C3A8C3A3D} EditorCameraComponent", + "Id": 16880285896855930892, + "Controller": { + "Configuration": { + "Field of View": 55.0, + "EditorEntityId": 3342481886060234850 + } + } + }, + "Component_[17187464423780271193]": { + "$type": "EditorLockComponent", + "Id": 17187464423780271193 + }, + "Component_[17495696818315413311]": { + "$type": "EditorEntitySortComponent", + "Id": 17495696818315413311 + }, + "Component_[18086214374043522055]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18086214374043522055, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Translate": [ + -2.3000001907348633, + -3.9368600845336914, + 1.0 + ], + "Rotate": [ + -2.050307512283325, + 1.9552897214889526, + -43.623355865478516 + ] + } + }, + "Component_[18387556550380114975]": { + "$type": "SelectionComponent", + "Id": 18387556550380114975 + }, + "Component_[2654521436129313160]": { + "$type": "EditorVisibilityComponent", + "Id": 2654521436129313160 + }, + "Component_[5265045084611556958]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5265045084611556958 + }, + "Component_[7169798125182238623]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7169798125182238623 + }, + "Component_[7255796294953281766]": { + "$type": "GenericComponentWrapper", + "Id": 7255796294953281766, + "m_template": { + "$type": "FlyCameraInputComponent" + } + }, + "Component_[8866210352157164042]": { + "$type": "EditorInspectorComponent", + "Id": 8866210352157164042 + }, + "Component_[9129253381063760879]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9129253381063760879 + } + } + }, + "Entity_[1168049227123]": { + "Id": "Entity_[1168049227123]", + "Name": "Grid", + "Components": { + "Component_[11443347433215807130]": { + "$type": "EditorEntityIconComponent", + "Id": 11443347433215807130 + }, + "Component_[11779275529534764488]": { + "$type": "SelectionComponent", + "Id": 11779275529534764488 + }, + "Component_[14249419413039427459]": { + "$type": "EditorInspectorComponent", + "Id": 14249419413039427459 + }, + "Component_[15448581635946161318]": { + "$type": "AZ::Render::EditorGridComponent", + "Id": 15448581635946161318, + "Controller": { + "Configuration": { + "primarySpacing": 4.0, + "primaryColor": [ + 0.501960813999176, + 0.501960813999176, + 0.501960813999176 + ], + "secondarySpacing": 0.5, + "secondaryColor": [ + 0.250980406999588, + 0.250980406999588, + 0.250980406999588 + ] + } + } + }, + "Component_[1843303322527297409]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1843303322527297409 + }, + "Component_[380249072065273654]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 380249072065273654, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[7476660583684339787]": { + "$type": "EditorPendingCompositionComponent", + "Id": 7476660583684339787 + }, + "Component_[7557626501215118375]": { + "$type": "EditorEntitySortComponent", + "Id": 7557626501215118375 + }, + "Component_[7984048488947365511]": { + "$type": "EditorVisibilityComponent", + "Id": 7984048488947365511 + }, + "Component_[8118181039276487398]": { + "$type": "EditorOnlyEntityComponent", + "Id": 8118181039276487398 + }, + "Component_[9189909764215270515]": { + "$type": "EditorLockComponent", + "Id": 9189909764215270515 + } + } + }, + "Entity_[1172344194419]": { + "Id": "Entity_[1172344194419]", + "Name": "Shader Ball", + "Components": { + "Component_[10789351944715265527]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10789351944715265527 + }, + "Component_[12037033284781049225]": { + "$type": "EditorEntitySortComponent", + "Id": 12037033284781049225 + }, + "Component_[13759153306105970079]": { + "$type": "EditorPendingCompositionComponent", + "Id": 13759153306105970079 + }, + "Component_[14135560884830586279]": { + "$type": "EditorInspectorComponent", + "Id": 14135560884830586279 + }, + "Component_[16247165675903986673]": { + "$type": "EditorVisibilityComponent", + "Id": 16247165675903986673 + }, + "Component_[18082433625958885247]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 18082433625958885247 + }, + "Component_[6472623349872972660]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6472623349872972660, + "Parent Entity": "Entity_[1176639161715]", + "Transform Data": { + "Rotate": [ + 0.0, + 0.10000000149011612, + 180.0 + ] + } + }, + "Component_[6495255223970673916]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 6495255223970673916, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{FD340C30-755C-5911-92A3-19A3F7A77931}", + "subId": 281415304 + }, + "assetHint": "objects/shaderball/shaderball_default_1m.azmodel" + } + } + } + }, + "Component_[8056625192494070973]": { + "$type": "SelectionComponent", + "Id": 8056625192494070973 + }, + "Component_[8550141614185782969]": { + "$type": "EditorEntityIconComponent", + "Id": 8550141614185782969 + }, + "Component_[9439770997198325425]": { + "$type": "EditorLockComponent", + "Id": 9439770997198325425 + } + } + }, + "Entity_[1176639161715]": { + "Id": "Entity_[1176639161715]", + "Name": "Atom Default Environment", + "Components": { + "Component_[10757302973393310045]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 10757302973393310045, + "Parent Entity": "Entity_[1146574390643]" + }, + "Component_[14505817420424255464]": { + "$type": "EditorInspectorComponent", + "Id": 14505817420424255464, + "ComponentOrderEntryArray": [ + { + "ComponentId": 10757302973393310045 + } + ] + }, + "Component_[14988041764659020032]": { + "$type": "EditorLockComponent", + "Id": 14988041764659020032 + }, + "Component_[15808690248755038124]": { + "$type": "SelectionComponent", + "Id": 15808690248755038124 + }, + "Component_[15900837685796817138]": { + "$type": "EditorVisibilityComponent", + "Id": 15900837685796817138 + }, + "Component_[3298767348226484884]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3298767348226484884 + }, + "Component_[4076975109609220594]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4076975109609220594 + }, + "Component_[5679760548946028854]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 5679760548946028854 + }, + "Component_[5855590796136709437]": { + "$type": "EditorEntitySortComponent", + "Id": 5855590796136709437, + "Child Entity Order": [ + "Entity_[1155164325235]", + "Entity_[1180934129011]", + "Entity_[1172344194419]", + "Entity_[1168049227123]", + "Entity_[1163754259827]", + "Entity_[1159459292531]" + ] + }, + "Component_[9277695270015777859]": { + "$type": "EditorEntityIconComponent", + "Id": 9277695270015777859 + } + } + }, + "Entity_[1180934129011]": { + "Id": "Entity_[1180934129011]", + "Name": "Global Sky", + "Components": { + "Component_[11231930600558681245]": { + "$type": "AZ::Render::EditorHDRiSkyboxComponent", + "Id": 11231930600558681245, + "Controller": { + "Configuration": { + "CubemapAsset": { + "assetId": { + "guid": "{215E47FD-D181-5832-B1AB-91673ABF6399}", + "subId": 1000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_skyboxcm.exr.streamingimage" + } + } + } + }, + "Component_[11980494120202836095]": { + "$type": "SelectionComponent", + "Id": 11980494120202836095 + }, + "Component_[1428633914413949476]": { + "$type": "EditorLockComponent", + "Id": 1428633914413949476 + }, + "Component_[14936200426671614999]": { + "$type": "AZ::Render::EditorImageBasedLightComponent", + "Id": 14936200426671614999, + "Controller": { + "Configuration": { + "diffuseImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 3000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_ibldiffuse.exr.streamingimage" + }, + "specularImageAsset": { + "assetId": { + "guid": "{3FD09945-D0F2-55C8-B9AF-B2FD421FE3BE}", + "subId": 2000 + }, + "assetHint": "lightingpresets/highcontrast/goegap_4k_iblglobalcm_iblspecular.exr.streamingimage" + } + } + } + }, + "Component_[14994774102579326069]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14994774102579326069 + }, + "Component_[15417479889044493340]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15417479889044493340 + }, + "Component_[15826613364991382688]": { + "$type": "EditorEntitySortComponent", + "Id": 15826613364991382688 + }, + "Component_[1665003113283562343]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1665003113283562343 + }, + "Component_[3704934735944502280]": { + "$type": "EditorEntityIconComponent", + "Id": 3704934735944502280 + }, + "Component_[5698542331457326479]": { + "$type": "EditorVisibilityComponent", + "Id": 5698542331457326479 + }, + "Component_[6644513399057217122]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 6644513399057217122, + "Parent Entity": "Entity_[1176639161715]" + }, + "Component_[931091830724002070]": { + "$type": "EditorInspectorComponent", + "Id": 931091830724002070 + } + } + } + }, + "Instances": { + "Instance_[425258647110]": { + "Source": "assets/simple_pot_fbx.procprefab" + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/filelist.xml b/AutomatedTesting/Levels/TestDependenciesLevel/filelist.xml deleted file mode 100644 index b5164a4aee..0000000000 --- a/AutomatedTesting/Levels/TestDependenciesLevel/filelist.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/AutomatedTesting/Levels/TestDependenciesLevel/level.pak b/AutomatedTesting/Levels/TestDependenciesLevel/level.pak deleted file mode 100644 index dfba7fb4e3..0000000000 --- a/AutomatedTesting/Levels/TestDependenciesLevel/level.pak +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:2611b691998640a0e802461f47b5b876f6832fbece62d34cc25da53e135e1c38 -size 44525 diff --git a/AutomatedTesting/Objects/ShaderBall_simple.fbx b/AutomatedTesting/Objects/ShaderBall_simple.fbx new file mode 100644 index 0000000000..50b7b8f44d --- /dev/null +++ b/AutomatedTesting/Objects/ShaderBall_simple.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f5f7a86a693878c10f91783955cc72535bf7d7c495163087a4c1982f228d27f0 +size 2145248 diff --git a/AutomatedTesting/Objects/bunny.fbx b/AutomatedTesting/Objects/bunny.fbx new file mode 100644 index 0000000000..f0a16349f7 --- /dev/null +++ b/AutomatedTesting/Objects/bunny.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef71257b240a7e704731806f8cd4b966af5d3c60f22881f9c6a6320180ee71a4 +size 2496384 diff --git a/AutomatedTesting/Objects/cone.fbx b/AutomatedTesting/Objects/cone.fbx new file mode 100644 index 0000000000..081b8b119d --- /dev/null +++ b/AutomatedTesting/Objects/cone.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:531b6473b314259504ab595e4983838b5866035ef4d70cedaf4cc9c7d9e65c3a +size 24512 diff --git a/AutomatedTesting/Objects/cube.fbx b/AutomatedTesting/Objects/cube.fbx new file mode 100644 index 0000000000..616c7b4ff3 --- /dev/null +++ b/AutomatedTesting/Objects/cube.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e32877eab35459499c73ff093df898f93bf3e7379de25eef6875d693be9bec81 +size 18015 diff --git a/AutomatedTesting/Objects/cylinder.fbx b/AutomatedTesting/Objects/cylinder.fbx new file mode 100644 index 0000000000..18ab200b4c --- /dev/null +++ b/AutomatedTesting/Objects/cylinder.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2949a50eec079a7d43a1d92e056c580ef625ee39e00e91cc25318319e37dcd3b +size 115689 diff --git a/AutomatedTesting/Objects/plane.fbx b/AutomatedTesting/Objects/plane.fbx new file mode 100644 index 0000000000..b274bfa282 --- /dev/null +++ b/AutomatedTesting/Objects/plane.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0a1f8d75dcd85e8b4aa57f6c0c81af0300ff96915ba3c2b591095c215d5e1d8c +size 12072 diff --git a/AutomatedTesting/Objects/suzanne.fbx b/AutomatedTesting/Objects/suzanne.fbx new file mode 100644 index 0000000000..171a6d21e9 --- /dev/null +++ b/AutomatedTesting/Objects/suzanne.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3bcfac5de831c269dac58e7d73d1dc61eb8d9f6d8a241f5c029537b6bcdf166 +size 1088304 diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/AtomCubeWall.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/AtomCubeWall.prefab new file mode 100644 index 0000000000..eda62c6f52 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/AtomCubeWall.prefab @@ -0,0 +1,102345 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "AtomCubeWall", + "Components": { + "Component_[1378762968271397696]": { + "$type": "EditorPrefabComponent", + "Id": 1378762968271397696 + }, + "Component_[15861901244881316506]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 15861901244881316506 + }, + "Component_[1667542861598358689]": { + "$type": "EditorVisibilityComponent", + "Id": 1667542861598358689 + }, + "Component_[2970248835877935836]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2970248835877935836 + }, + "Component_[3475481110579263685]": { + "$type": "EditorEntityIconComponent", + "Id": 3475481110579263685 + }, + "Component_[4960733274366718926]": { + "$type": "EditorOnlyEntityComponent", + "Id": 4960733274366718926 + }, + "Component_[5052757994340238524]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 5052757994340238524, + "Parent Entity": "" + }, + "Component_[5847627832229774671]": { + "$type": "SelectionComponent", + "Id": 5847627832229774671 + }, + "Component_[686142448804056059]": { + "$type": "EditorInspectorComponent", + "Id": 686142448804056059 + }, + "Component_[8743584510936460932]": { + "$type": "EditorLockComponent", + "Id": 8743584510936460932 + }, + "Component_[9497718940671573904]": { + "$type": "EditorEntitySortComponent", + "Id": 9497718940671573904, + "Child Entity Order": [ + "Entity_[728313751508]", + "Entity_[3017531320276]", + "Entity_[2149947926484]", + "Entity_[3236574652372]", + "Entity_[2618099361748]", + "Entity_[1922314659796]", + "Entity_[2493545310164]", + "Entity_[887227541460]", + "Entity_[1458458191828]", + "Entity_[1638846818260]", + "Entity_[479205648340]", + "Entity_[2850027595732]", + "Entity_[947357083604]", + "Entity_[3640301578196]", + "Entity_[3094840731604]", + "Entity_[483500615636]", + "Entity_[4327496345556]", + "Entity_[2880092366804]", + "Entity_[487795582932]", + "Entity_[3348243802068]", + "Entity_[3983898961876]", + "Entity_[3429848180692]", + "Entity_[1497112897492]", + "Entity_[2295976814548]", + "Entity_[504975452116]", + "Entity_[2351811389396]", + "Entity_[3507157592020]", + "Entity_[646709372884]", + "Entity_[577989896148]", + "Entity_[2545084917716]", + "Entity_[2609509427156]", + "Entity_[3919474452436]", + "Entity_[3305294129108]", + "Entity_[3030416222164]", + "Entity_[1973854267348]", + "Entity_[4275956738004]", + "Entity_[2892977268692]", + "Entity_[2390466095060]", + "Entity_[3790625433556]", + "Entity_[3185035044820]", + "Entity_[492090550228]", + "Entity_[2781308118996]", + "Entity_[1230824925140]", + "Entity_[3399783409620]", + "Entity_[2098408318932]", + "Entity_[1862185117652]", + "Entity_[3090545764308]", + "Entity_[1600192112596]", + "Entity_[762673489876]", + "Entity_[2029688842196]", + "Entity_[917292312532]", + "Entity_[706838915028]", + "Entity_[745493620692]", + "Entity_[2562264786900]", + "Entity_[2141357991892]", + "Entity_[556515059668]", + "Entity_[2575149688788]", + "Entity_[535040223188]", + "Entity_[530745255892]", + "Entity_[496385517524]", + "Entity_[3043301124052]", + "Entity_[2635279230932]", + "Entity_[2777013151700]", + "Entity_[3425553213396]", + "Entity_[2716883609556]", + "Entity_[1909429757908]", + "Entity_[3524337461204]", + "Entity_[3116315568084]", + "Entity_[4495000070100]", + "Entity_[865752704980]", + "Entity_[831392966612]", + "Entity_[2373286225876]", + "Entity_[3876524779476]", + "Entity_[500680484820]", + "Entity_[509270419412]", + "Entity_[513565386708]", + "Entity_[2953106810836]", + "Entity_[4125632882644]", + "Entity_[3756265695188]", + "Entity_[2025393874900]", + "Entity_[3159265241044]", + "Entity_[2003919038420]", + "Entity_[1385443747796]", + "Entity_[719723816916]", + "Entity_[2476365440980]", + "Entity_[3296704194516]", + "Entity_[4314611443668]", + "Entity_[1329609172948]", + "Entity_[517860354004]", + "Entity_[4245891966932]", + "Entity_[1540062570452]", + "Entity_[522155321300]", + "Entity_[1814940477396]", + "Entity_[1093385971668]", + "Entity_[4215827195860]", + "Entity_[3966719092692]", + "Entity_[771263424468]", + "Entity_[526450288596]", + "Entity_[681069111252]", + "Entity_[1205055121364]", + "Entity_[2368991258580]", + "Entity_[3258049488852]", + "Entity_[4104158046164]", + "Entity_[912997345236]", + "Entity_[1282364532692]", + "Entity_[1617371981780]", + "Entity_[4357561116628]", + "Entity_[629529503700]", + "Entity_[2845732628436]", + "Entity_[2557969819604]", + "Entity_[2210077468628]", + "Entity_[1411213551572]", + "Entity_[1634551850964]", + "Entity_[552220092372]", + "Entity_[1905134790612]", + "Entity_[1552947472340]", + "Entity_[2317451651028]", + "Entity_[1278069565396]", + "Entity_[3142085371860]", + "Entity_[1123450742740]", + "Entity_[539335190484]", + "Entity_[3416963278804]", + "Entity_[1136335644628]", + "Entity_[1677501523924]", + "Entity_[3180740077524]", + "Entity_[2630984263636]", + "Entity_[638119438292]", + "Entity_[754083555284]", + "Entity_[1771990804436]", + "Entity_[981716821972]", + "Entity_[844277868500]", + "Entity_[543630157780]", + "Entity_[1733336098772]", + "Entity_[3283819292628]", + "Entity_[1007486625748]", + "Entity_[4013963732948]", + "Entity_[1673206556628]", + "Entity_[2940221908948]", + "Entity_[595169765332]", + "Entity_[3897999615956]", + "Entity_[1325314205652]", + "Entity_[547925125076]", + "Entity_[2424825833428]", + "Entity_[2347516422100]", + "Entity_[612349634516]", + "Entity_[1918019692500]", + "Entity_[1754810935252]", + "Entity_[4301726541780]", + "Entity_[3584467003348]", + "Entity_[560810026964]", + "Entity_[2832847726548]", + "Entity_[2016803940308]", + "Entity_[3915179485140]", + "Entity_[4585194383316]", + "Entity_[569399961556]", + "Entity_[3520042493908]", + "Entity_[3859344910292]", + "Entity_[2463480539092]", + "Entity_[4039733536724]", + "Entity_[779853359060]", + "Entity_[2983171581908]", + "Entity_[1832120346580]", + "Entity_[2334631520212]", + "Entity_[603759699924]", + "Entity_[1342494074836]", + "Entity_[2673933936596]", + "Entity_[565104994260]", + "Entity_[3279524325332]", + "Entity_[573694928852]", + "Entity_[3601646872532]", + "Entity_[582284863444]", + "Entity_[4443460462548]", + "Entity_[1879364986836]", + "Entity_[1750515967956]", + "Entity_[4082683209684]", + "Entity_[620939569108]", + "Entity_[973126887380]", + "Entity_[1179285317588]", + "Entity_[1406918584276]", + "Entity_[2330336552916]", + "Entity_[2253027141588]", + "Entity_[1802055575508]", + "Entity_[3992488896468]", + "Entity_[1359673944020]", + "Entity_[1424098453460]", + "Entity_[1720451196884]", + "Entity_[3545812297684]", + "Entity_[4482115168212]", + "Entity_[4589489350612]", + "Entity_[3906589550548]", + "Entity_[4224417130452]", + "Entity_[3412668311508]", + "Entity_[3812100270036]", + "Entity_[3447028049876]", + "Entity_[2068343547860]", + "Entity_[1887954921428]", + "Entity_[4546539677652]", + "Entity_[4147107719124]", + "Entity_[1196465186772]", + "Entity_[2987466549204]", + "Entity_[2695408773076]", + "Entity_[2691113805780]", + "Entity_[4202942293972]", + "Entity_[2171422762964]", + "Entity_[1501407864788]", + "Entity_[4563719546836]", + "Entity_[4417690658772]", + "Entity_[3683251251156]", + "Entity_[2046868711380]", + "Entity_[4529359808468]", + "Entity_[3837870073812]", + "Entity_[3163560208340]", + "Entity_[2785603086292]", + "Entity_[3073365895124]", + "Entity_[2523610081236]", + "Entity_[4159992621012]", + "Entity_[1978149234644]", + "Entity_[4035438569428]", + "Entity_[1759105902548]", + "Entity_[2145652959188]", + "Entity_[934472181716]", + "Entity_[3975309027284]", + "Entity_[3721905956820]", + "Entity_[2918747072468]", + "Entity_[3666071381972]", + "Entity_[3893704648660]", + "Entity_[2313156683732]", + "Entity_[2510725179348]", + "Entity_[1059026233300]", + "Entity_[2403350996948]", + "Entity_[1286659499988]", + "Entity_[3356833736660]", + "Entity_[2497840277460]", + "Entity_[2648164132820]", + "Entity_[3605941839828]", + "Entity_[741198653396]", + "Entity_[2579444656084]", + "Entity_[1840710281172]", + "Entity_[1960969365460]", + "Entity_[2764128249812]", + "Entity_[4469230266324]", + "Entity_[4022553667540]", + "Entity_[4336086280148]", + "Entity_[1471343093716]", + "Entity_[2837142693844]", + "Entity_[2703998707668]", + "Entity_[4409100724180]", + "Entity_[4237302032340]", + "Entity_[3039006156756]", + "Entity_[4430575560660]", + "Entity_[3335358900180]", + "Entity_[2923042039764]", + "Entity_[4593784317908]", + "Entity_[1213645055956]", + "Entity_[4344676214740]", + "Entity_[827097999316]", + "Entity_[951652050900]", + "Entity_[4413395691476]", + "Entity_[4207237261268]", + "Entity_[4056913405908]", + "Entity_[2721178576852]", + "Entity_[2081228449748]", + "Entity_[3794920400852]", + "Entity_[4194352359380]", + "Entity_[2965991712724]", + "Entity_[1415508518868]", + "Entity_[4031143602132]", + "Entity_[3197919946708]", + "Entity_[3099135698900]", + "Entity_[1570127341524]", + "Entity_[4516474906580]", + "Entity_[3438438115284]", + "Entity_[4172877522900]", + "Entity_[2433415768020]", + "Entity_[4473525233620]", + "Entity_[3760560662484]", + "Entity_[4052618438612]", + "Entity_[1643141785556]", + "Entity_[1368263878612]", + "Entity_[3240869619668]", + "Entity_[4572309481428]", + "Entity_[2798487988180]", + "Entity_[1101975906260]", + "Entity_[1518587733972]", + "Entity_[3962424125396]", + "Entity_[4267366803412]", + "Entity_[4095568111572]", + "Entity_[1557242439636]", + "Entity_[3936654321620]", + "Entity_[2665344002004]", + "Entity_[4044028504020]", + "Entity_[4447755429844]", + "Entity_[1243709827028]", + "Entity_[977421854676]", + "Entity_[2901567203284]", + "Entity_[642414405588]", + "Entity_[4323201378260]", + "Entity_[1767695837140]", + "Entity_[3691841185748]", + "Entity_[1492817930196]", + "Entity_[3674661316564]", + "Entity_[3515747526612]", + "Entity_[2871502432212]", + "Entity_[2506430212052]", + "Entity_[3777740531668]", + "Entity_[2386171127764]", + "Entity_[1265184663508]", + "Entity_[586579830740]", + "Entity_[3120610535380]", + "Entity_[2420530866132]", + "Entity_[2725473544148]", + "Entity_[1252299761620]", + "Entity_[2321746618324]", + "Entity_[3820690204628]", + "Entity_[3979603994580]", + "Entity_[3318179030996]", + "Entity_[1505702832084]", + "Entity_[1428393420756]", + "Entity_[3678956283860]", + "Entity_[1338199107540]", + "Entity_[895817476052]", + "Entity_[1660321654740]", + "Entity_[4525064841172]", + "Entity_[698248980436]", + "Entity_[4134222817236]", + "Entity_[2265912043476]", + "Entity_[1312429303764]", + "Entity_[4254481901524]", + "Entity_[4499295037396]", + "Entity_[3000351451092]", + "Entity_[3988193929172]", + "Entity_[655299307476]", + "Entity_[1346789042132]", + "Entity_[3769150597076]", + "Entity_[2480660408276]", + "Entity_[1866480084948]", + "Entity_[2214372435924]", + "Entity_[1046141331412]", + "Entity_[2261617076180]", + "Entity_[2042573744084]", + "Entity_[1183580284884]", + "Entity_[861457737684]", + "Entity_[1033256429524]", + "Entity_[711133882324]", + "Entity_[3928064387028]", + "Entity_[1316724271060]", + "Entity_[1003191658452]", + "Entity_[2218667403220]", + "Entity_[2991761516500]", + "Entity_[4452050397140]", + "Entity_[2291681847252]", + "Entity_[2751243347924]", + "Entity_[1784875706324]", + "Entity_[3176445110228]", + "Entity_[2815667857364]", + "Entity_[4533654775764]", + "Entity_[3610236807124]", + "Entity_[3880819746772]", + "Entity_[3124905502676]", + "Entity_[3494272690132]", + "Entity_[835687933908]", + "Entity_[1363968911316]", + "Entity_[3378308573140]", + "Entity_[1703271327700]", + "Entity_[3636006610900]", + "Entity_[2180012697556]", + "Entity_[1389738715092]", + "Entity_[4580899416020]", + "Entity_[3322473998292]", + "Entity_[878637606868]", + "Entity_[3550107264980]", + "Entity_[1166400415700]", + "Entity_[4370446018516]", + "Entity_[2240142239700]", + "Entity_[2399056029652]", + "Entity_[2729768511444]", + "Entity_[4310316476372]", + "Entity_[3189330012116]", + "Entity_[3047596091348]", + "Entity_[3867934844884]", + "Entity_[2867207464916]", + "Entity_[3575877068756]", + "Entity_[2446300669908]", + "Entity_[2536494983124]", + "Entity_[3262344456148]", + "Entity_[4486410135508]", + "Entity_[2519315113940]", + "Entity_[1724746164180]", + "Entity_[4048323471316]", + "Entity_[3051891058644]", + "Entity_[1419803486164]", + "Entity_[797033228244]", + "Entity_[1041846364116]", + "Entity_[4460640331732]", + "Entity_[3833575106516]", + "Entity_[3464207919060]", + "Entity_[1651731720148]", + "Entity_[1162105448404]", + "Entity_[663889242068]", + "Entity_[2755538315220]", + "Entity_[4507884971988]", + "Entity_[1522882701268]", + "Entity_[4151402686420]", + "Entity_[1144925579220]", + "Entity_[3850754975700]", + "Entity_[1467048126420]", + "Entity_[3945244256212]", + "Entity_[3958129158100]", + "Entity_[4061208373204]", + "Entity_[4555129612244]", + "Entity_[1299544401876]", + "Entity_[2897272235988]", + "Entity_[882932574164]", + "Entity_[4396215822292]", + "Entity_[1106270873556]", + "Entity_[2188602632148]", + "Entity_[2807077922772]", + "Entity_[998896691156]", + "Entity_[4331791312852]", + "Entity_[2197192566740]", + "Entity_[2738358446036]", + "Entity_[986011789268]", + "Entity_[4138517784532]", + "Entity_[1239414859732]", + "Entity_[1273774598100]", + "Entity_[2338926487508]", + "Entity_[2450595637204]", + "Entity_[784148326356]", + "Entity_[3704726087636]", + "Entity_[689659045844]", + "Entity_[3571582101460]", + "Entity_[1900839823316]", + "Entity_[1114860808148]", + "Entity_[4426280593364]", + "Entity_[4280251705300]", + "Entity_[4108453013460]", + "Entity_[1793465640916]", + "Entity_[4404805756884]", + "Entity_[2394761062356]", + "Entity_[2175717730260]", + "Entity_[3532927395796]", + "Entity_[3459912951764]", + "Entity_[1217940023252]", + "Entity_[1097680938964]", + "Entity_[3751970727892]", + "Entity_[1028961462228]", + "Entity_[3747675760596]", + "Entity_[4220122163156]", + "Entity_[3717610989524]", + "Entity_[3288114259924]", + "Entity_[1595897145300]", + "Entity_[1149220546516]", + "Entity_[599464732628]", + "Entity_[2583739623380]", + "Entity_[1436983355348]", + "Entity_[1913724725204]", + "Entity_[2935926941652]", + "Entity_[1690386425812]", + "Entity_[3206509881300]", + "Entity_[2137063024596]", + "Entity_[1054731266004]", + "Entity_[3842165041108]", + "Entity_[4001078831060]", + "Entity_[4348971182036]", + "Entity_[4293136607188]", + "Entity_[1222234990548]", + "Entity_[968831920084]", + "Entity_[4391920854996]", + "Entity_[2592329557972]", + "Entity_[870047672276]", + "Entity_[1711861262292]", + "Entity_[1608782047188]", + "Entity_[4306021509076]", + "Entity_[1999624071124]", + "Entity_[1269479630804]", + "Entity_[1140630611924]", + "Entity_[2227257337812]", + "Entity_[3339653867476]", + "Entity_[2854322563028]", + "Entity_[1024666494932]", + "Entity_[2686818838484]", + "Entity_[2300271781844]", + "Entity_[4361856083924]", + "Entity_[1527177668564]", + "Entity_[1372558845908]", + "Entity_[1514292766676]", + "Entity_[1943789496276]", + "Entity_[4340381247444]", + "Entity_[1737631066068]", + "Entity_[3996783863764]", + "Entity_[1574422308820]", + "Entity_[2059753613268]", + "Entity_[4009668765652]", + "Entity_[3713316022228]", + "Entity_[3846460008404]", + "Entity_[2553674852308]", + "Entity_[1321019238356]", + "Entity_[3167855175636]", + "Entity_[2961696745428]", + "Entity_[788443293652]", + "Entity_[4250186934228]", + "Entity_[4074093275092]", + "Entity_[3537222363092]", + "Entity_[4318906410964]", + "Entity_[1664616622036]", + "Entity_[4297431574484]", + "Entity_[4065503340500]", + "Entity_[994601723860]", + "Entity_[4142812751828]", + "Entity_[1333904140244]", + "Entity_[4117042948052]", + "Entity_[2996056483796]", + "Entity_[4263071836116]", + "Entity_[3940949288916]", + "Entity_[1351084009428]", + "Entity_[2094113351636]", + "Entity_[1797760608212]", + "Entity_[4241596999636]", + "Entity_[857162770388]", + "Entity_[3855049942996]", + "Entity_[2742653413332]", + "Entity_[2416235898836]", + "Entity_[3472797853652]", + "Entity_[3644596545492]", + "Entity_[2759833282516]", + "Entity_[4185762424788]", + "Entity_[3077660862420]", + "Entity_[2154242893780]", + "Entity_[2794193020884]", + "Entity_[1819235444692]", + "Entity_[3004646418388]", + "Entity_[1810645510100]", + "Entity_[4078388242388]", + "Entity_[4503590004692]", + "Entity_[2270207010772]", + "Entity_[3902294583252]", + "Entity_[3270934390740]", + "Entity_[1780580739028]", + "Entity_[3567287134164]", + "Entity_[3511452559316]", + "Entity_[4190057392084]", + "Entity_[1355378976724]", + "Entity_[3249459554260]", + "Entity_[3137790404564]", + "Entity_[4129927849940]", + "Entity_[2235847272404]", + "Entity_[4086978176980]", + "Entity_[3657481447380]", + "Entity_[2841437661140]", + "Entity_[2862912497620]", + "Entity_[4005373798356]", + "Entity_[3786330466260]", + "Entity_[814213097428]", + "Entity_[1308134336468]", + "Entity_[1707566294996]", + "Entity_[2356106356692]", + "Entity_[3889409681364]", + "Entity_[1153515513812]", + "Entity_[4542244710356]", + "Entity_[3614531774420]", + "Entity_[4434870527956]", + "Entity_[3202214914004]", + "Entity_[616644601812]", + "Entity_[2978876614612]", + "Entity_[3421258246100]", + "Entity_[4177172490196]", + "Entity_[2119883155412]", + "Entity_[1986739169236]", + "Entity_[2661049034708]", + "Entity_[3648891512788]", + "Entity_[4026848634836]", + "Entity_[2283091912660]", + "Entity_[1020371527636]", + "Entity_[990306756564]", + "Entity_[3498567657428]", + "Entity_[964536952788]", + "Entity_[2605214459860]", + "Entity_[2802782955476]", + "Entity_[2162832828372]", + "Entity_[2639574198228]", + "Entity_[4353266149332]", + "Entity_[4550834644948]", + "Entity_[2888682301396]", + "Entity_[3726200924116]", + "Entity_[2326041585620]", + "Entity_[1303839369172]", + "Entity_[3227984717780]", + "Entity_[1462753159124]", + "Entity_[2278796945364]", + "Entity_[1698976360404]", + "Entity_[4464935299028]", + "Entity_[2669638969300]", + "Entity_[801328195540]", + "Entity_[1565832374228]", + "Entity_[2377581193172]", + "Entity_[2970286680020]", + "Entity_[4387625887700]", + "Entity_[1763400869844]", + "Entity_[1789170673620]", + "Entity_[3021826287572]", + "Entity_[1982444201940]", + "Entity_[1625961916372]", + "Entity_[2613804394452]", + "Entity_[4211532228564]", + "Entity_[3807805302740]", + "Entity_[3502862624724]", + "Entity_[775558391764]", + "Entity_[3326768965588]", + "Entity_[2532200015828]", + "Entity_[3154970273748]", + "Entity_[3872229812180]", + "Entity_[3382603540436]", + "Entity_[1991034136532]", + "Entity_[1119155775444]", + "Entity_[2699703740372]", + "Entity_[2515020146644]", + "Entity_[1952379430868]", + "Entity_[1011781593044]", + "Entity_[4421985626068]", + "Entity_[1402623616980]", + "Entity_[4568014514132]", + "Entity_[4576604448724]", + "Entity_[3253754521556]", + "Entity_[1630256883668]", + "Entity_[2222962370516]", + "Entity_[3219394783188]", + "Entity_[3232279685076]", + "Entity_[3107725633492]", + "Entity_[633824470996]", + "Entity_[1896544856020]", + "Entity_[724018784212]", + "Entity_[1531472635860]", + "Entity_[2588034590676]", + "Entity_[3408373344212]", + "Entity_[852867803092]", + "Entity_[904407410644]", + "Entity_[2489250342868]", + "Entity_[3554402232276]", + "Entity_[921587279828]", + "Entity_[1827825379284]", + "Entity_[1295249434580]", + "Entity_[2540789950420]", + "Entity_[4271661770708]", + "Entity_[3442733082580]", + "Entity_[2527905048532]", + "Entity_[1544357537748]", + "Entity_[608054667220]", + "Entity_[2734063478740]", + "Entity_[4477820200916]", + "Entity_[693954013140]", + "Entity_[2931631974356]", + "Entity_[2111293220820]", + "Entity_[736903686100]", + "Entity_[1170695382996]", + "Entity_[3597351905236]", + "Entity_[2033983809492]", + "Entity_[839982901204]", + "Entity_[3562992166868]", + "Entity_[2914452105172]", + "Entity_[766968457172]", + "Entity_[848572835796]", + "Entity_[2132768057300]", + "Entity_[3395488442324]", + "Entity_[1883659954132]", + "Entity_[1484227995604]", + "Entity_[1849300215764]", + "Entity_[3343948834772]", + "Entity_[1587307210708]", + "Entity_[2467775506388]", + "Entity_[3971014059988]", + "Entity_[874342639572]", + "Entity_[1187875252180]", + "Entity_[1995329103828]", + "Entity_[3485682755540]", + "Entity_[2910157137876]", + "Entity_[4228712097748]", + "Entity_[3064775960532]", + "Entity_[2102703286228]", + "Entity_[3150675306452]", + "Entity_[2051163678676]", + "Entity_[2643869165524]", + "Entity_[1591602178004]", + "Entity_[2244437206996]", + "Entity_[2746948380628]", + "Entity_[1256594728916]", + "Entity_[1248004794324]", + "Entity_[3215099815892]", + "Entity_[2626689296340]", + "Entity_[672479176660]", + "Entity_[891522508756]", + "Entity_[1965264332756]", + "Entity_[1260889696212]", + "Entity_[955947018196]", + "Entity_[1445573289940]", + "Entity_[3653186480084]", + "Entity_[2459185571796]", + "Entity_[3588761970644]", + "Entity_[2304566749140]", + "Entity_[2948811843540]", + "Entity_[1080501069780]", + "Entity_[3829280139220]", + "Entity_[1127745710036]", + "Entity_[685364078548]", + "Entity_[3060480993236]", + "Entity_[2549379885012]", + "Entity_[3700431120340]", + "Entity_[2201487534036]", + "Entity_[3365423671252]", + "Entity_[925882247124]", + "Entity_[3361128703956]", + "Entity_[2308861716436]", + "Entity_[3086250797012]", + "Entity_[1686091458516]", + "Entity_[3623121709012]", + "Entity_[1776285771732]", + "Entity_[1376853813204]", + "Entity_[960241985492]", + "Entity_[3309589096404]", + "Entity_[1449868257236]", + "Entity_[3013236352980]", + "Entity_[2600919492564]", + "Entity_[3172150142932]", + "Entity_[2205782501332]", + "Entity_[4258776868820]", + "Entity_[2927337007060]", + "Entity_[1969559300052]", + "Entity_[1488522962900]", + "Entity_[809918130132]", + "Entity_[3558697199572]", + "Entity_[4383330920404]", + "Entity_[1381148780500]", + "Entity_[4233007065044]", + "Entity_[3292409227220]", + "Entity_[3910884517844]", + "Entity_[1935199561684]", + "Entity_[2076933482452]", + "Entity_[900112443348]", + "Entity_[2274501978068]", + "Entity_[1089091004372]", + "Entity_[3193624979412]", + "Entity_[1892249888724]", + "Entity_[1209350088660]", + "Entity_[3885114714068]", + "Entity_[2957401778132]", + "Entity_[2231552305108]", + "Entity_[2192897599444]", + "Entity_[943062116308]", + "Entity_[2974581647316]", + "Entity_[3580172036052]", + "Entity_[3627416676308]", + "Entity_[4559424579540]", + "Entity_[2454890604500]", + "Entity_[1475638061012]", + "Entity_[2824257791956]", + "Entity_[4198647326676]", + "Entity_[4520769873876]", + "Entity_[1479933028308]", + "Entity_[2566559754196]", + "Entity_[1604487079892]", + "Entity_[1561537406932]", + "Entity_[3331063932884]", + "Entity_[1729041131476]", + "Entity_[676774143956]", + "Entity_[2158537861076]", + "Entity_[1948084463572]", + "Entity_[4112747980756]", + "Entity_[1132040677332]", + "Entity_[1870775052244]", + "Entity_[3468502886356]", + "Entity_[1174990350292]", + "Entity_[715428849620]", + "Entity_[590874798036]", + "Entity_[3773445564372]", + "Entity_[1716156229588]", + "Entity_[3803510335444]", + "Entity_[1441278322644]", + "Entity_[2248732174292]", + "Entity_[4284546672596]", + "Entity_[3369718638548]", + "Entity_[4598079285204]", + "Entity_[659594274772]", + "Entity_[2381876160468]", + "Entity_[2115588188116]", + "Entity_[3764855629780]", + "Entity_[2811372890068]", + "Entity_[1746221000660]", + "Entity_[3034711189460]", + "Entity_[4366151051220]", + "Entity_[1157810481108]", + "Entity_[651004340180]", + "Entity_[2875797399508]", + "Entity_[2257322108884]", + "Entity_[3223689750484]", + "Entity_[2570854721492]", + "Entity_[4456345364436]", + "Entity_[1578717276116]", + "Entity_[2656754067412]", + "Entity_[1926609627092]", + "Entity_[2772718184404]", + "Entity_[1647436752852]", + "Entity_[3210804848596]", + "Entity_[818508064724]", + "Entity_[4537949743060]", + "Entity_[4018258700244]", + "Entity_[2768423217108]", + "Entity_[1432688388052]", + "Entity_[2360401323988]", + "Entity_[2343221454804]", + "Entity_[2622394329044]", + "Entity_[792738260948]", + "Entity_[1694681393108]", + "Entity_[2038278776788]", + "Entity_[3266639423444]", + "Entity_[4155697653716]", + "Entity_[3313884063700]", + "Entity_[2442005702612]", + "Entity_[1084796037076]", + "Entity_[1535767603156]", + "Entity_[3391193475028]", + "Entity_[3923769419732]", + "Entity_[3782035498964]", + "Entity_[3953834190804]", + "Entity_[625234536404]", + "Entity_[4512179939284]", + "Entity_[3081955829716]", + "Entity_[3275229358036]", + "Entity_[4091273144276]", + "Entity_[2858617530324]", + "Entity_[1235119892436]", + "Entity_[3300999161812]", + "Entity_[2021098907604]", + "Entity_[2596624525268]", + "Entity_[3069070927828]", + "Entity_[2905862170580]", + "Entity_[3734790858708]", + "Entity_[3008941385684]", + "Entity_[4490705102804]", + "Entity_[822803032020]", + "Entity_[3709021054932]", + "Entity_[2484955375572]", + "Entity_[2502135244756]", + "Entity_[3404078376916]", + "Entity_[3687546218452]", + "Entity_[3112020600788]", + "Entity_[3056186025940]", + "Entity_[749788587988]", + "Entity_[4379035953108]", + "Entity_[1067616167892]", + "Entity_[3352538769364]", + "Entity_[4099863078868]", + "Entity_[2411940931540]", + "Entity_[1656026687444]", + "Entity_[3932359354324]", + "Entity_[1741926033364]", + "Entity_[4168582555604]", + "Entity_[2064048580564]", + "Entity_[758378522580]", + "Entity_[2678228903892]", + "Entity_[3631711643604]", + "Entity_[2287386879956]", + "Entity_[1845005248468]", + "Entity_[3477092820948]", + "Entity_[2089818384340]", + "Entity_[1037551396820]", + "Entity_[702543947732]", + "Entity_[1681796491220]", + "Entity_[908702377940]", + "Entity_[2106998253524]", + "Entity_[3129200469972]", + "Entity_[3863639877588]", + "Entity_[1050436298708]", + "Entity_[2012508973012]", + "Entity_[3618826741716]", + "Entity_[3386898507732]", + "Entity_[3434143147988]", + "Entity_[2437710735316]", + "Entity_[4288841639892]", + "Entity_[1875070019540]", + "Entity_[2128473090004]", + "Entity_[3949539223508]", + "Entity_[3489977722836]", + "Entity_[1668911589332]", + "Entity_[1398328649684]", + "Entity_[3541517330388]", + "Entity_[1806350542804]", + "Entity_[2085523417044]", + "Entity_[732608718804]", + "Entity_[4439165495252]", + "Entity_[3528632428500]", + "Entity_[2407645964244]", + "Entity_[1930904594388]", + "Entity_[4374740985812]", + "Entity_[1509997799380]", + "Entity_[1290954467284]", + "Entity_[2819962824660]", + "Entity_[2944516876244]", + "Entity_[1583012243412]", + "Entity_[1613077014484]", + "Entity_[3451323017172]", + "Entity_[938767149012]", + "Entity_[3739085826004]", + "Entity_[1192170219476]", + "Entity_[3824985171924]", + "Entity_[1956674398164]", + "Entity_[2789898053588]", + "Entity_[3146380339156]", + "Entity_[3670366349268]", + "Entity_[2429120800724]", + "Entity_[1076206102484]", + "Entity_[1394033682388]", + "Entity_[3455617984468]", + "Entity_[2712588642260]", + "Entity_[4181467457492]", + "Entity_[3103430666196]", + "Entity_[1200760154068]", + "Entity_[4121337915348]", + "Entity_[2652459100116]", + "Entity_[1621666949076]", + "Entity_[1063321200596]", + "Entity_[1823530411988]", + "Entity_[2682523871188]", + "Entity_[3696136153044]", + "Entity_[3816395237332]", + "Entity_[1939494528980]", + "Entity_[2884387334100]", + "Entity_[2124178122708]", + "Entity_[3026121254868]", + "Entity_[1853595183060]", + "Entity_[2828552759252]", + "Entity_[2364696291284]", + "Entity_[2072638515156]", + "Entity_[2008214005716]", + "Entity_[930177214420]", + "Entity_[2472070473684]", + "Entity_[3133495437268]", + "Entity_[668184209364]", + "Entity_[3593056937940]", + "Entity_[3481387788244]", + "Entity_[1016076560340]", + "Entity_[3730495891412]", + "Entity_[2055458645972]", + "Entity_[1454163224532]", + "Entity_[2167127795668]", + "Entity_[2184307664852]", + "Entity_[1836415313876]", + "Entity_[3374013605844]", + "Entity_[2708293674964]", + "Entity_[3743380793300]", + "Entity_[3661776414676]", + "Entity_[805623162836]", + "Entity_[4400510789588]", + "Entity_[1071911135188]", + "Entity_[1857890150356]", + "Entity_[3245164586964]", + "Entity_[1226529957844]", + "Entity_[1548652505044]", + "Entity_[1110565840852]", + "Entity_[3799215368148]", + "Entity_[4164287588308]", + "Entity_[4069798307796]" + ] + } + } + }, + "Entities": { + "Entity_[1003191658452]": { + "Id": "Entity_[1003191658452]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1007486625748]": { + "Id": "Entity_[1007486625748]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1011781593044]": { + "Id": "Entity_[1011781593044]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1016076560340]": { + "Id": "Entity_[1016076560340]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1020371527636]": { + "Id": "Entity_[1020371527636]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1024666494932]": { + "Id": "Entity_[1024666494932]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1028961462228]": { + "Id": "Entity_[1028961462228]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1033256429524]": { + "Id": "Entity_[1033256429524]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1037551396820]": { + "Id": "Entity_[1037551396820]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1041846364116]": { + "Id": "Entity_[1041846364116]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1046141331412]": { + "Id": "Entity_[1046141331412]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1050436298708]": { + "Id": "Entity_[1050436298708]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1054731266004]": { + "Id": "Entity_[1054731266004]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1059026233300]": { + "Id": "Entity_[1059026233300]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1063321200596]": { + "Id": "Entity_[1063321200596]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1067616167892]": { + "Id": "Entity_[1067616167892]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1071911135188]": { + "Id": "Entity_[1071911135188]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1076206102484]": { + "Id": "Entity_[1076206102484]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1080501069780]": { + "Id": "Entity_[1080501069780]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1084796037076]": { + "Id": "Entity_[1084796037076]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1089091004372]": { + "Id": "Entity_[1089091004372]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1093385971668]": { + "Id": "Entity_[1093385971668]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1097680938964]": { + "Id": "Entity_[1097680938964]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1101975906260]": { + "Id": "Entity_[1101975906260]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1106270873556]": { + "Id": "Entity_[1106270873556]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1110565840852]": { + "Id": "Entity_[1110565840852]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1114860808148]": { + "Id": "Entity_[1114860808148]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1119155775444]": { + "Id": "Entity_[1119155775444]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1123450742740]": { + "Id": "Entity_[1123450742740]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1127745710036]": { + "Id": "Entity_[1127745710036]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1132040677332]": { + "Id": "Entity_[1132040677332]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1136335644628]": { + "Id": "Entity_[1136335644628]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1140630611924]": { + "Id": "Entity_[1140630611924]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1144925579220]": { + "Id": "Entity_[1144925579220]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1149220546516]": { + "Id": "Entity_[1149220546516]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1153515513812]": { + "Id": "Entity_[1153515513812]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1157810481108]": { + "Id": "Entity_[1157810481108]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1162105448404]": { + "Id": "Entity_[1162105448404]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1166400415700]": { + "Id": "Entity_[1166400415700]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1170695382996]": { + "Id": "Entity_[1170695382996]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1174990350292]": { + "Id": "Entity_[1174990350292]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1179285317588]": { + "Id": "Entity_[1179285317588]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1183580284884]": { + "Id": "Entity_[1183580284884]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1187875252180]": { + "Id": "Entity_[1187875252180]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1192170219476]": { + "Id": "Entity_[1192170219476]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1196465186772]": { + "Id": "Entity_[1196465186772]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1200760154068]": { + "Id": "Entity_[1200760154068]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1205055121364]": { + "Id": "Entity_[1205055121364]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1209350088660]": { + "Id": "Entity_[1209350088660]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1213645055956]": { + "Id": "Entity_[1213645055956]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1217940023252]": { + "Id": "Entity_[1217940023252]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1222234990548]": { + "Id": "Entity_[1222234990548]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1226529957844]": { + "Id": "Entity_[1226529957844]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1230824925140]": { + "Id": "Entity_[1230824925140]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1235119892436]": { + "Id": "Entity_[1235119892436]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1239414859732]": { + "Id": "Entity_[1239414859732]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1243709827028]": { + "Id": "Entity_[1243709827028]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1248004794324]": { + "Id": "Entity_[1248004794324]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1252299761620]": { + "Id": "Entity_[1252299761620]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1256594728916]": { + "Id": "Entity_[1256594728916]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1260889696212]": { + "Id": "Entity_[1260889696212]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1265184663508]": { + "Id": "Entity_[1265184663508]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1269479630804]": { + "Id": "Entity_[1269479630804]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1273774598100]": { + "Id": "Entity_[1273774598100]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1278069565396]": { + "Id": "Entity_[1278069565396]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1282364532692]": { + "Id": "Entity_[1282364532692]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1286659499988]": { + "Id": "Entity_[1286659499988]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1290954467284]": { + "Id": "Entity_[1290954467284]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1295249434580]": { + "Id": "Entity_[1295249434580]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1299544401876]": { + "Id": "Entity_[1299544401876]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1303839369172]": { + "Id": "Entity_[1303839369172]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1308134336468]": { + "Id": "Entity_[1308134336468]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1312429303764]": { + "Id": "Entity_[1312429303764]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1316724271060]": { + "Id": "Entity_[1316724271060]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1321019238356]": { + "Id": "Entity_[1321019238356]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1325314205652]": { + "Id": "Entity_[1325314205652]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1329609172948]": { + "Id": "Entity_[1329609172948]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1333904140244]": { + "Id": "Entity_[1333904140244]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1338199107540]": { + "Id": "Entity_[1338199107540]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1342494074836]": { + "Id": "Entity_[1342494074836]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1346789042132]": { + "Id": "Entity_[1346789042132]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1351084009428]": { + "Id": "Entity_[1351084009428]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1355378976724]": { + "Id": "Entity_[1355378976724]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1359673944020]": { + "Id": "Entity_[1359673944020]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1363968911316]": { + "Id": "Entity_[1363968911316]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1368263878612]": { + "Id": "Entity_[1368263878612]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1372558845908]": { + "Id": "Entity_[1372558845908]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1376853813204]": { + "Id": "Entity_[1376853813204]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1381148780500]": { + "Id": "Entity_[1381148780500]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1385443747796]": { + "Id": "Entity_[1385443747796]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1389738715092]": { + "Id": "Entity_[1389738715092]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1394033682388]": { + "Id": "Entity_[1394033682388]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1398328649684]": { + "Id": "Entity_[1398328649684]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1402623616980]": { + "Id": "Entity_[1402623616980]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1406918584276]": { + "Id": "Entity_[1406918584276]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1411213551572]": { + "Id": "Entity_[1411213551572]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1415508518868]": { + "Id": "Entity_[1415508518868]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1419803486164]": { + "Id": "Entity_[1419803486164]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1424098453460]": { + "Id": "Entity_[1424098453460]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1428393420756]": { + "Id": "Entity_[1428393420756]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1432688388052]": { + "Id": "Entity_[1432688388052]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1436983355348]": { + "Id": "Entity_[1436983355348]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1441278322644]": { + "Id": "Entity_[1441278322644]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1445573289940]": { + "Id": "Entity_[1445573289940]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1449868257236]": { + "Id": "Entity_[1449868257236]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1454163224532]": { + "Id": "Entity_[1454163224532]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1458458191828]": { + "Id": "Entity_[1458458191828]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1462753159124]": { + "Id": "Entity_[1462753159124]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1467048126420]": { + "Id": "Entity_[1467048126420]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1471343093716]": { + "Id": "Entity_[1471343093716]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1475638061012]": { + "Id": "Entity_[1475638061012]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1479933028308]": { + "Id": "Entity_[1479933028308]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1484227995604]": { + "Id": "Entity_[1484227995604]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1488522962900]": { + "Id": "Entity_[1488522962900]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1492817930196]": { + "Id": "Entity_[1492817930196]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1497112897492]": { + "Id": "Entity_[1497112897492]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1501407864788]": { + "Id": "Entity_[1501407864788]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1505702832084]": { + "Id": "Entity_[1505702832084]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1509997799380]": { + "Id": "Entity_[1509997799380]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1514292766676]": { + "Id": "Entity_[1514292766676]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1518587733972]": { + "Id": "Entity_[1518587733972]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1522882701268]": { + "Id": "Entity_[1522882701268]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1527177668564]": { + "Id": "Entity_[1527177668564]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1531472635860]": { + "Id": "Entity_[1531472635860]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1535767603156]": { + "Id": "Entity_[1535767603156]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1540062570452]": { + "Id": "Entity_[1540062570452]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1544357537748]": { + "Id": "Entity_[1544357537748]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1548652505044]": { + "Id": "Entity_[1548652505044]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1552947472340]": { + "Id": "Entity_[1552947472340]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1557242439636]": { + "Id": "Entity_[1557242439636]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1561537406932]": { + "Id": "Entity_[1561537406932]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 54.6579704284668 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1565832374228]": { + "Id": "Entity_[1565832374228]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1570127341524]": { + "Id": "Entity_[1570127341524]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1574422308820]": { + "Id": "Entity_[1574422308820]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1578717276116]": { + "Id": "Entity_[1578717276116]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1583012243412]": { + "Id": "Entity_[1583012243412]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1587307210708]": { + "Id": "Entity_[1587307210708]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1591602178004]": { + "Id": "Entity_[1591602178004]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1595897145300]": { + "Id": "Entity_[1595897145300]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1600192112596]": { + "Id": "Entity_[1600192112596]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1604487079892]": { + "Id": "Entity_[1604487079892]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1608782047188]": { + "Id": "Entity_[1608782047188]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1613077014484]": { + "Id": "Entity_[1613077014484]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1617371981780]": { + "Id": "Entity_[1617371981780]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1621666949076]": { + "Id": "Entity_[1621666949076]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1625961916372]": { + "Id": "Entity_[1625961916372]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1630256883668]": { + "Id": "Entity_[1630256883668]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1634551850964]": { + "Id": "Entity_[1634551850964]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1638846818260]": { + "Id": "Entity_[1638846818260]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1643141785556]": { + "Id": "Entity_[1643141785556]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1647436752852]": { + "Id": "Entity_[1647436752852]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1651731720148]": { + "Id": "Entity_[1651731720148]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1656026687444]": { + "Id": "Entity_[1656026687444]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1660321654740]": { + "Id": "Entity_[1660321654740]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1664616622036]": { + "Id": "Entity_[1664616622036]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1668911589332]": { + "Id": "Entity_[1668911589332]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1673206556628]": { + "Id": "Entity_[1673206556628]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1677501523924]": { + "Id": "Entity_[1677501523924]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1681796491220]": { + "Id": "Entity_[1681796491220]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1686091458516]": { + "Id": "Entity_[1686091458516]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1690386425812]": { + "Id": "Entity_[1690386425812]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1694681393108]": { + "Id": "Entity_[1694681393108]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1698976360404]": { + "Id": "Entity_[1698976360404]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1703271327700]": { + "Id": "Entity_[1703271327700]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1707566294996]": { + "Id": "Entity_[1707566294996]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 54.6579704284668 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1711861262292]": { + "Id": "Entity_[1711861262292]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1716156229588]": { + "Id": "Entity_[1716156229588]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1720451196884]": { + "Id": "Entity_[1720451196884]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1724746164180]": { + "Id": "Entity_[1724746164180]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1729041131476]": { + "Id": "Entity_[1729041131476]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1733336098772]": { + "Id": "Entity_[1733336098772]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1737631066068]": { + "Id": "Entity_[1737631066068]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1741926033364]": { + "Id": "Entity_[1741926033364]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1746221000660]": { + "Id": "Entity_[1746221000660]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1750515967956]": { + "Id": "Entity_[1750515967956]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1754810935252]": { + "Id": "Entity_[1754810935252]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1759105902548]": { + "Id": "Entity_[1759105902548]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1763400869844]": { + "Id": "Entity_[1763400869844]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1767695837140]": { + "Id": "Entity_[1767695837140]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1771990804436]": { + "Id": "Entity_[1771990804436]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1776285771732]": { + "Id": "Entity_[1776285771732]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1780580739028]": { + "Id": "Entity_[1780580739028]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1784875706324]": { + "Id": "Entity_[1784875706324]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1789170673620]": { + "Id": "Entity_[1789170673620]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1793465640916]": { + "Id": "Entity_[1793465640916]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1797760608212]": { + "Id": "Entity_[1797760608212]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1802055575508]": { + "Id": "Entity_[1802055575508]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1806350542804]": { + "Id": "Entity_[1806350542804]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1810645510100]": { + "Id": "Entity_[1810645510100]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1814940477396]": { + "Id": "Entity_[1814940477396]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1819235444692]": { + "Id": "Entity_[1819235444692]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1823530411988]": { + "Id": "Entity_[1823530411988]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1827825379284]": { + "Id": "Entity_[1827825379284]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1832120346580]": { + "Id": "Entity_[1832120346580]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1836415313876]": { + "Id": "Entity_[1836415313876]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1840710281172]": { + "Id": "Entity_[1840710281172]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1845005248468]": { + "Id": "Entity_[1845005248468]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1849300215764]": { + "Id": "Entity_[1849300215764]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1853595183060]": { + "Id": "Entity_[1853595183060]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1857890150356]": { + "Id": "Entity_[1857890150356]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1862185117652]": { + "Id": "Entity_[1862185117652]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1866480084948]": { + "Id": "Entity_[1866480084948]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1870775052244]": { + "Id": "Entity_[1870775052244]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1875070019540]": { + "Id": "Entity_[1875070019540]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1879364986836]": { + "Id": "Entity_[1879364986836]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 114.53101348876953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1883659954132]": { + "Id": "Entity_[1883659954132]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1887954921428]": { + "Id": "Entity_[1887954921428]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1892249888724]": { + "Id": "Entity_[1892249888724]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1896544856020]": { + "Id": "Entity_[1896544856020]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1900839823316]": { + "Id": "Entity_[1900839823316]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1905134790612]": { + "Id": "Entity_[1905134790612]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1909429757908]": { + "Id": "Entity_[1909429757908]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1913724725204]": { + "Id": "Entity_[1913724725204]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1918019692500]": { + "Id": "Entity_[1918019692500]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1922314659796]": { + "Id": "Entity_[1922314659796]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1926609627092]": { + "Id": "Entity_[1926609627092]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1930904594388]": { + "Id": "Entity_[1930904594388]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1935199561684]": { + "Id": "Entity_[1935199561684]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1939494528980]": { + "Id": "Entity_[1939494528980]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1943789496276]": { + "Id": "Entity_[1943789496276]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1948084463572]": { + "Id": "Entity_[1948084463572]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1952379430868]": { + "Id": "Entity_[1952379430868]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 24.573455810546875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1956674398164]": { + "Id": "Entity_[1956674398164]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1960969365460]": { + "Id": "Entity_[1960969365460]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1965264332756]": { + "Id": "Entity_[1965264332756]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1969559300052]": { + "Id": "Entity_[1969559300052]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1973854267348]": { + "Id": "Entity_[1973854267348]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1978149234644]": { + "Id": "Entity_[1978149234644]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1982444201940]": { + "Id": "Entity_[1982444201940]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1986739169236]": { + "Id": "Entity_[1986739169236]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1991034136532]": { + "Id": "Entity_[1991034136532]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1995329103828]": { + "Id": "Entity_[1995329103828]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[1999624071124]": { + "Id": "Entity_[1999624071124]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2003919038420]": { + "Id": "Entity_[2003919038420]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2008214005716]": { + "Id": "Entity_[2008214005716]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2012508973012]": { + "Id": "Entity_[2012508973012]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2016803940308]": { + "Id": "Entity_[2016803940308]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2021098907604]": { + "Id": "Entity_[2021098907604]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2025393874900]": { + "Id": "Entity_[2025393874900]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2029688842196]": { + "Id": "Entity_[2029688842196]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2033983809492]": { + "Id": "Entity_[2033983809492]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2038278776788]": { + "Id": "Entity_[2038278776788]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2042573744084]": { + "Id": "Entity_[2042573744084]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2046868711380]": { + "Id": "Entity_[2046868711380]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2051163678676]": { + "Id": "Entity_[2051163678676]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2055458645972]": { + "Id": "Entity_[2055458645972]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2059753613268]": { + "Id": "Entity_[2059753613268]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2064048580564]": { + "Id": "Entity_[2064048580564]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2068343547860]": { + "Id": "Entity_[2068343547860]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2072638515156]": { + "Id": "Entity_[2072638515156]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2076933482452]": { + "Id": "Entity_[2076933482452]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2081228449748]": { + "Id": "Entity_[2081228449748]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2085523417044]": { + "Id": "Entity_[2085523417044]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2089818384340]": { + "Id": "Entity_[2089818384340]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2094113351636]": { + "Id": "Entity_[2094113351636]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2098408318932]": { + "Id": "Entity_[2098408318932]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2102703286228]": { + "Id": "Entity_[2102703286228]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2106998253524]": { + "Id": "Entity_[2106998253524]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2111293220820]": { + "Id": "Entity_[2111293220820]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2115588188116]": { + "Id": "Entity_[2115588188116]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2119883155412]": { + "Id": "Entity_[2119883155412]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2124178122708]": { + "Id": "Entity_[2124178122708]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2128473090004]": { + "Id": "Entity_[2128473090004]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2132768057300]": { + "Id": "Entity_[2132768057300]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2137063024596]": { + "Id": "Entity_[2137063024596]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2141357991892]": { + "Id": "Entity_[2141357991892]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2145652959188]": { + "Id": "Entity_[2145652959188]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2149947926484]": { + "Id": "Entity_[2149947926484]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2154242893780]": { + "Id": "Entity_[2154242893780]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2158537861076]": { + "Id": "Entity_[2158537861076]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2162832828372]": { + "Id": "Entity_[2162832828372]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2167127795668]": { + "Id": "Entity_[2167127795668]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2171422762964]": { + "Id": "Entity_[2171422762964]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2175717730260]": { + "Id": "Entity_[2175717730260]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2180012697556]": { + "Id": "Entity_[2180012697556]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2184307664852]": { + "Id": "Entity_[2184307664852]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2188602632148]": { + "Id": "Entity_[2188602632148]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2192897599444]": { + "Id": "Entity_[2192897599444]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2197192566740]": { + "Id": "Entity_[2197192566740]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2201487534036]": { + "Id": "Entity_[2201487534036]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2205782501332]": { + "Id": "Entity_[2205782501332]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2210077468628]": { + "Id": "Entity_[2210077468628]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2214372435924]": { + "Id": "Entity_[2214372435924]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2218667403220]": { + "Id": "Entity_[2218667403220]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2222962370516]": { + "Id": "Entity_[2222962370516]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2227257337812]": { + "Id": "Entity_[2227257337812]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2231552305108]": { + "Id": "Entity_[2231552305108]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2235847272404]": { + "Id": "Entity_[2235847272404]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2240142239700]": { + "Id": "Entity_[2240142239700]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2244437206996]": { + "Id": "Entity_[2244437206996]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2248732174292]": { + "Id": "Entity_[2248732174292]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2253027141588]": { + "Id": "Entity_[2253027141588]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2257322108884]": { + "Id": "Entity_[2257322108884]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2261617076180]": { + "Id": "Entity_[2261617076180]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2265912043476]": { + "Id": "Entity_[2265912043476]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2270207010772]": { + "Id": "Entity_[2270207010772]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2274501978068]": { + "Id": "Entity_[2274501978068]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2278796945364]": { + "Id": "Entity_[2278796945364]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2283091912660]": { + "Id": "Entity_[2283091912660]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2287386879956]": { + "Id": "Entity_[2287386879956]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2291681847252]": { + "Id": "Entity_[2291681847252]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2295976814548]": { + "Id": "Entity_[2295976814548]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2300271781844]": { + "Id": "Entity_[2300271781844]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2304566749140]": { + "Id": "Entity_[2304566749140]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2308861716436]": { + "Id": "Entity_[2308861716436]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2313156683732]": { + "Id": "Entity_[2313156683732]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2317451651028]": { + "Id": "Entity_[2317451651028]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2321746618324]": { + "Id": "Entity_[2321746618324]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2326041585620]": { + "Id": "Entity_[2326041585620]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2330336552916]": { + "Id": "Entity_[2330336552916]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2334631520212]": { + "Id": "Entity_[2334631520212]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2338926487508]": { + "Id": "Entity_[2338926487508]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2343221454804]": { + "Id": "Entity_[2343221454804]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2347516422100]": { + "Id": "Entity_[2347516422100]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2351811389396]": { + "Id": "Entity_[2351811389396]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2356106356692]": { + "Id": "Entity_[2356106356692]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2360401323988]": { + "Id": "Entity_[2360401323988]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2364696291284]": { + "Id": "Entity_[2364696291284]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2368991258580]": { + "Id": "Entity_[2368991258580]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2373286225876]": { + "Id": "Entity_[2373286225876]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2377581193172]": { + "Id": "Entity_[2377581193172]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2381876160468]": { + "Id": "Entity_[2381876160468]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2386171127764]": { + "Id": "Entity_[2386171127764]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2390466095060]": { + "Id": "Entity_[2390466095060]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2394761062356]": { + "Id": "Entity_[2394761062356]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2399056029652]": { + "Id": "Entity_[2399056029652]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2403350996948]": { + "Id": "Entity_[2403350996948]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2407645964244]": { + "Id": "Entity_[2407645964244]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2411940931540]": { + "Id": "Entity_[2411940931540]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2416235898836]": { + "Id": "Entity_[2416235898836]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2420530866132]": { + "Id": "Entity_[2420530866132]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2424825833428]": { + "Id": "Entity_[2424825833428]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2429120800724]": { + "Id": "Entity_[2429120800724]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2433415768020]": { + "Id": "Entity_[2433415768020]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2437710735316]": { + "Id": "Entity_[2437710735316]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2442005702612]": { + "Id": "Entity_[2442005702612]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2446300669908]": { + "Id": "Entity_[2446300669908]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2450595637204]": { + "Id": "Entity_[2450595637204]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2454890604500]": { + "Id": "Entity_[2454890604500]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2459185571796]": { + "Id": "Entity_[2459185571796]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2463480539092]": { + "Id": "Entity_[2463480539092]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2467775506388]": { + "Id": "Entity_[2467775506388]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2472070473684]": { + "Id": "Entity_[2472070473684]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2476365440980]": { + "Id": "Entity_[2476365440980]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2480660408276]": { + "Id": "Entity_[2480660408276]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2484955375572]": { + "Id": "Entity_[2484955375572]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2489250342868]": { + "Id": "Entity_[2489250342868]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2493545310164]": { + "Id": "Entity_[2493545310164]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2497840277460]": { + "Id": "Entity_[2497840277460]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2502135244756]": { + "Id": "Entity_[2502135244756]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2506430212052]": { + "Id": "Entity_[2506430212052]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2510725179348]": { + "Id": "Entity_[2510725179348]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2515020146644]": { + "Id": "Entity_[2515020146644]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2519315113940]": { + "Id": "Entity_[2519315113940]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2523610081236]": { + "Id": "Entity_[2523610081236]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2527905048532]": { + "Id": "Entity_[2527905048532]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2532200015828]": { + "Id": "Entity_[2532200015828]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2536494983124]": { + "Id": "Entity_[2536494983124]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2540789950420]": { + "Id": "Entity_[2540789950420]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2545084917716]": { + "Id": "Entity_[2545084917716]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2549379885012]": { + "Id": "Entity_[2549379885012]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2553674852308]": { + "Id": "Entity_[2553674852308]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2557969819604]": { + "Id": "Entity_[2557969819604]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2562264786900]": { + "Id": "Entity_[2562264786900]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2566559754196]": { + "Id": "Entity_[2566559754196]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2570854721492]": { + "Id": "Entity_[2570854721492]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2575149688788]": { + "Id": "Entity_[2575149688788]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2579444656084]": { + "Id": "Entity_[2579444656084]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2583739623380]": { + "Id": "Entity_[2583739623380]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2588034590676]": { + "Id": "Entity_[2588034590676]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2592329557972]": { + "Id": "Entity_[2592329557972]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2596624525268]": { + "Id": "Entity_[2596624525268]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2600919492564]": { + "Id": "Entity_[2600919492564]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2605214459860]": { + "Id": "Entity_[2605214459860]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2609509427156]": { + "Id": "Entity_[2609509427156]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2613804394452]": { + "Id": "Entity_[2613804394452]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2618099361748]": { + "Id": "Entity_[2618099361748]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2622394329044]": { + "Id": "Entity_[2622394329044]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2626689296340]": { + "Id": "Entity_[2626689296340]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2630984263636]": { + "Id": "Entity_[2630984263636]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2635279230932]": { + "Id": "Entity_[2635279230932]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2639574198228]": { + "Id": "Entity_[2639574198228]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2643869165524]": { + "Id": "Entity_[2643869165524]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2648164132820]": { + "Id": "Entity_[2648164132820]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2652459100116]": { + "Id": "Entity_[2652459100116]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2656754067412]": { + "Id": "Entity_[2656754067412]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2661049034708]": { + "Id": "Entity_[2661049034708]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2665344002004]": { + "Id": "Entity_[2665344002004]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2669638969300]": { + "Id": "Entity_[2669638969300]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2673933936596]": { + "Id": "Entity_[2673933936596]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2678228903892]": { + "Id": "Entity_[2678228903892]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2682523871188]": { + "Id": "Entity_[2682523871188]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2686818838484]": { + "Id": "Entity_[2686818838484]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2691113805780]": { + "Id": "Entity_[2691113805780]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2695408773076]": { + "Id": "Entity_[2695408773076]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2699703740372]": { + "Id": "Entity_[2699703740372]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2703998707668]": { + "Id": "Entity_[2703998707668]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2708293674964]": { + "Id": "Entity_[2708293674964]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2712588642260]": { + "Id": "Entity_[2712588642260]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2716883609556]": { + "Id": "Entity_[2716883609556]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2721178576852]": { + "Id": "Entity_[2721178576852]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2725473544148]": { + "Id": "Entity_[2725473544148]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2729768511444]": { + "Id": "Entity_[2729768511444]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2734063478740]": { + "Id": "Entity_[2734063478740]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2738358446036]": { + "Id": "Entity_[2738358446036]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2742653413332]": { + "Id": "Entity_[2742653413332]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2746948380628]": { + "Id": "Entity_[2746948380628]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2751243347924]": { + "Id": "Entity_[2751243347924]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2755538315220]": { + "Id": "Entity_[2755538315220]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2759833282516]": { + "Id": "Entity_[2759833282516]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2764128249812]": { + "Id": "Entity_[2764128249812]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2768423217108]": { + "Id": "Entity_[2768423217108]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2772718184404]": { + "Id": "Entity_[2772718184404]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2777013151700]": { + "Id": "Entity_[2777013151700]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2781308118996]": { + "Id": "Entity_[2781308118996]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2785603086292]": { + "Id": "Entity_[2785603086292]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2789898053588]": { + "Id": "Entity_[2789898053588]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2794193020884]": { + "Id": "Entity_[2794193020884]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2798487988180]": { + "Id": "Entity_[2798487988180]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2802782955476]": { + "Id": "Entity_[2802782955476]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2807077922772]": { + "Id": "Entity_[2807077922772]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2811372890068]": { + "Id": "Entity_[2811372890068]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2815667857364]": { + "Id": "Entity_[2815667857364]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2819962824660]": { + "Id": "Entity_[2819962824660]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2824257791956]": { + "Id": "Entity_[2824257791956]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2828552759252]": { + "Id": "Entity_[2828552759252]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2832847726548]": { + "Id": "Entity_[2832847726548]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2837142693844]": { + "Id": "Entity_[2837142693844]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2841437661140]": { + "Id": "Entity_[2841437661140]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2845732628436]": { + "Id": "Entity_[2845732628436]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2850027595732]": { + "Id": "Entity_[2850027595732]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2854322563028]": { + "Id": "Entity_[2854322563028]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2858617530324]": { + "Id": "Entity_[2858617530324]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2862912497620]": { + "Id": "Entity_[2862912497620]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2867207464916]": { + "Id": "Entity_[2867207464916]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2871502432212]": { + "Id": "Entity_[2871502432212]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2875797399508]": { + "Id": "Entity_[2875797399508]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2880092366804]": { + "Id": "Entity_[2880092366804]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2884387334100]": { + "Id": "Entity_[2884387334100]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2888682301396]": { + "Id": "Entity_[2888682301396]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2892977268692]": { + "Id": "Entity_[2892977268692]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2897272235988]": { + "Id": "Entity_[2897272235988]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2901567203284]": { + "Id": "Entity_[2901567203284]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2905862170580]": { + "Id": "Entity_[2905862170580]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2910157137876]": { + "Id": "Entity_[2910157137876]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2914452105172]": { + "Id": "Entity_[2914452105172]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2918747072468]": { + "Id": "Entity_[2918747072468]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2923042039764]": { + "Id": "Entity_[2923042039764]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2927337007060]": { + "Id": "Entity_[2927337007060]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2931631974356]": { + "Id": "Entity_[2931631974356]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2935926941652]": { + "Id": "Entity_[2935926941652]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2940221908948]": { + "Id": "Entity_[2940221908948]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2944516876244]": { + "Id": "Entity_[2944516876244]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2948811843540]": { + "Id": "Entity_[2948811843540]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2953106810836]": { + "Id": "Entity_[2953106810836]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 99.47334289550781 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2957401778132]": { + "Id": "Entity_[2957401778132]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2961696745428]": { + "Id": "Entity_[2961696745428]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2965991712724]": { + "Id": "Entity_[2965991712724]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2970286680020]": { + "Id": "Entity_[2970286680020]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2974581647316]": { + "Id": "Entity_[2974581647316]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2978876614612]": { + "Id": "Entity_[2978876614612]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2983171581908]": { + "Id": "Entity_[2983171581908]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2987466549204]": { + "Id": "Entity_[2987466549204]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2991761516500]": { + "Id": "Entity_[2991761516500]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[2996056483796]": { + "Id": "Entity_[2996056483796]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3000351451092]": { + "Id": "Entity_[3000351451092]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3004646418388]": { + "Id": "Entity_[3004646418388]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3008941385684]": { + "Id": "Entity_[3008941385684]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3013236352980]": { + "Id": "Entity_[3013236352980]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3017531320276]": { + "Id": "Entity_[3017531320276]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3021826287572]": { + "Id": "Entity_[3021826287572]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3026121254868]": { + "Id": "Entity_[3026121254868]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3030416222164]": { + "Id": "Entity_[3030416222164]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3034711189460]": { + "Id": "Entity_[3034711189460]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3039006156756]": { + "Id": "Entity_[3039006156756]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3043301124052]": { + "Id": "Entity_[3043301124052]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3047596091348]": { + "Id": "Entity_[3047596091348]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3051891058644]": { + "Id": "Entity_[3051891058644]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 69.38883209228516 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3056186025940]": { + "Id": "Entity_[3056186025940]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3060480993236]": { + "Id": "Entity_[3060480993236]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3064775960532]": { + "Id": "Entity_[3064775960532]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3069070927828]": { + "Id": "Entity_[3069070927828]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3073365895124]": { + "Id": "Entity_[3073365895124]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3077660862420]": { + "Id": "Entity_[3077660862420]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3081955829716]": { + "Id": "Entity_[3081955829716]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3086250797012]": { + "Id": "Entity_[3086250797012]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3090545764308]": { + "Id": "Entity_[3090545764308]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3094840731604]": { + "Id": "Entity_[3094840731604]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3099135698900]": { + "Id": "Entity_[3099135698900]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3103430666196]": { + "Id": "Entity_[3103430666196]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3107725633492]": { + "Id": "Entity_[3107725633492]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3112020600788]": { + "Id": "Entity_[3112020600788]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3116315568084]": { + "Id": "Entity_[3116315568084]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3120610535380]": { + "Id": "Entity_[3120610535380]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3124905502676]": { + "Id": "Entity_[3124905502676]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3129200469972]": { + "Id": "Entity_[3129200469972]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3133495437268]": { + "Id": "Entity_[3133495437268]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3137790404564]": { + "Id": "Entity_[3137790404564]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3142085371860]": { + "Id": "Entity_[3142085371860]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3146380339156]": { + "Id": "Entity_[3146380339156]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3150675306452]": { + "Id": "Entity_[3150675306452]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3154970273748]": { + "Id": "Entity_[3154970273748]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3159265241044]": { + "Id": "Entity_[3159265241044]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3163560208340]": { + "Id": "Entity_[3163560208340]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3167855175636]": { + "Id": "Entity_[3167855175636]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3172150142932]": { + "Id": "Entity_[3172150142932]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3176445110228]": { + "Id": "Entity_[3176445110228]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3180740077524]": { + "Id": "Entity_[3180740077524]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3185035044820]": { + "Id": "Entity_[3185035044820]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3189330012116]": { + "Id": "Entity_[3189330012116]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3193624979412]": { + "Id": "Entity_[3193624979412]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3197919946708]": { + "Id": "Entity_[3197919946708]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3202214914004]": { + "Id": "Entity_[3202214914004]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3206509881300]": { + "Id": "Entity_[3206509881300]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3210804848596]": { + "Id": "Entity_[3210804848596]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3215099815892]": { + "Id": "Entity_[3215099815892]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3219394783188]": { + "Id": "Entity_[3219394783188]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3223689750484]": { + "Id": "Entity_[3223689750484]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3227984717780]": { + "Id": "Entity_[3227984717780]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3232279685076]": { + "Id": "Entity_[3232279685076]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3236574652372]": { + "Id": "Entity_[3236574652372]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3240869619668]": { + "Id": "Entity_[3240869619668]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3245164586964]": { + "Id": "Entity_[3245164586964]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3249459554260]": { + "Id": "Entity_[3249459554260]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3253754521556]": { + "Id": "Entity_[3253754521556]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3258049488852]": { + "Id": "Entity_[3258049488852]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3262344456148]": { + "Id": "Entity_[3262344456148]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3266639423444]": { + "Id": "Entity_[3266639423444]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3270934390740]": { + "Id": "Entity_[3270934390740]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3275229358036]": { + "Id": "Entity_[3275229358036]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3279524325332]": { + "Id": "Entity_[3279524325332]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3283819292628]": { + "Id": "Entity_[3283819292628]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3288114259924]": { + "Id": "Entity_[3288114259924]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3292409227220]": { + "Id": "Entity_[3292409227220]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3296704194516]": { + "Id": "Entity_[3296704194516]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3300999161812]": { + "Id": "Entity_[3300999161812]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3305294129108]": { + "Id": "Entity_[3305294129108]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3309589096404]": { + "Id": "Entity_[3309589096404]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3313884063700]": { + "Id": "Entity_[3313884063700]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3318179030996]": { + "Id": "Entity_[3318179030996]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3322473998292]": { + "Id": "Entity_[3322473998292]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3326768965588]": { + "Id": "Entity_[3326768965588]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3331063932884]": { + "Id": "Entity_[3331063932884]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3335358900180]": { + "Id": "Entity_[3335358900180]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3339653867476]": { + "Id": "Entity_[3339653867476]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3343948834772]": { + "Id": "Entity_[3343948834772]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3348243802068]": { + "Id": "Entity_[3348243802068]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3352538769364]": { + "Id": "Entity_[3352538769364]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3356833736660]": { + "Id": "Entity_[3356833736660]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3361128703956]": { + "Id": "Entity_[3361128703956]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3365423671252]": { + "Id": "Entity_[3365423671252]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3369718638548]": { + "Id": "Entity_[3369718638548]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3374013605844]": { + "Id": "Entity_[3374013605844]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3378308573140]": { + "Id": "Entity_[3378308573140]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3382603540436]": { + "Id": "Entity_[3382603540436]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3386898507732]": { + "Id": "Entity_[3386898507732]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3391193475028]": { + "Id": "Entity_[3391193475028]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3395488442324]": { + "Id": "Entity_[3395488442324]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3399783409620]": { + "Id": "Entity_[3399783409620]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3404078376916]": { + "Id": "Entity_[3404078376916]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3408373344212]": { + "Id": "Entity_[3408373344212]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3412668311508]": { + "Id": "Entity_[3412668311508]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3416963278804]": { + "Id": "Entity_[3416963278804]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3421258246100]": { + "Id": "Entity_[3421258246100]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3425553213396]": { + "Id": "Entity_[3425553213396]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3429848180692]": { + "Id": "Entity_[3429848180692]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3434143147988]": { + "Id": "Entity_[3434143147988]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3438438115284]": { + "Id": "Entity_[3438438115284]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3442733082580]": { + "Id": "Entity_[3442733082580]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3447028049876]": { + "Id": "Entity_[3447028049876]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3451323017172]": { + "Id": "Entity_[3451323017172]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3455617984468]": { + "Id": "Entity_[3455617984468]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3459912951764]": { + "Id": "Entity_[3459912951764]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3464207919060]": { + "Id": "Entity_[3464207919060]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3468502886356]": { + "Id": "Entity_[3468502886356]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3472797853652]": { + "Id": "Entity_[3472797853652]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3477092820948]": { + "Id": "Entity_[3477092820948]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3481387788244]": { + "Id": "Entity_[3481387788244]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3485682755540]": { + "Id": "Entity_[3485682755540]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3489977722836]": { + "Id": "Entity_[3489977722836]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3494272690132]": { + "Id": "Entity_[3494272690132]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3498567657428]": { + "Id": "Entity_[3498567657428]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3502862624724]": { + "Id": "Entity_[3502862624724]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3507157592020]": { + "Id": "Entity_[3507157592020]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3511452559316]": { + "Id": "Entity_[3511452559316]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3515747526612]": { + "Id": "Entity_[3515747526612]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3520042493908]": { + "Id": "Entity_[3520042493908]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 84.44650268554688 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3524337461204]": { + "Id": "Entity_[3524337461204]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3528632428500]": { + "Id": "Entity_[3528632428500]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3532927395796]": { + "Id": "Entity_[3532927395796]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3537222363092]": { + "Id": "Entity_[3537222363092]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3541517330388]": { + "Id": "Entity_[3541517330388]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3545812297684]": { + "Id": "Entity_[3545812297684]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3550107264980]": { + "Id": "Entity_[3550107264980]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3554402232276]": { + "Id": "Entity_[3554402232276]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3558697199572]": { + "Id": "Entity_[3558697199572]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3562992166868]": { + "Id": "Entity_[3562992166868]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3567287134164]": { + "Id": "Entity_[3567287134164]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3571582101460]": { + "Id": "Entity_[3571582101460]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3575877068756]": { + "Id": "Entity_[3575877068756]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3580172036052]": { + "Id": "Entity_[3580172036052]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3584467003348]": { + "Id": "Entity_[3584467003348]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3588761970644]": { + "Id": "Entity_[3588761970644]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3593056937940]": { + "Id": "Entity_[3593056937940]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3597351905236]": { + "Id": "Entity_[3597351905236]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3601646872532]": { + "Id": "Entity_[3601646872532]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3605941839828]": { + "Id": "Entity_[3605941839828]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3610236807124]": { + "Id": "Entity_[3610236807124]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3614531774420]": { + "Id": "Entity_[3614531774420]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3618826741716]": { + "Id": "Entity_[3618826741716]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3623121709012]": { + "Id": "Entity_[3623121709012]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3627416676308]": { + "Id": "Entity_[3627416676308]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3631711643604]": { + "Id": "Entity_[3631711643604]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3636006610900]": { + "Id": "Entity_[3636006610900]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3640301578196]": { + "Id": "Entity_[3640301578196]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3644596545492]": { + "Id": "Entity_[3644596545492]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3648891512788]": { + "Id": "Entity_[3648891512788]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3653186480084]": { + "Id": "Entity_[3653186480084]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3657481447380]": { + "Id": "Entity_[3657481447380]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3661776414676]": { + "Id": "Entity_[3661776414676]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3666071381972]": { + "Id": "Entity_[3666071381972]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3670366349268]": { + "Id": "Entity_[3670366349268]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3674661316564]": { + "Id": "Entity_[3674661316564]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3678956283860]": { + "Id": "Entity_[3678956283860]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3683251251156]": { + "Id": "Entity_[3683251251156]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3687546218452]": { + "Id": "Entity_[3687546218452]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3691841185748]": { + "Id": "Entity_[3691841185748]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3696136153044]": { + "Id": "Entity_[3696136153044]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3700431120340]": { + "Id": "Entity_[3700431120340]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3704726087636]": { + "Id": "Entity_[3704726087636]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3709021054932]": { + "Id": "Entity_[3709021054932]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3713316022228]": { + "Id": "Entity_[3713316022228]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3717610989524]": { + "Id": "Entity_[3717610989524]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3721905956820]": { + "Id": "Entity_[3721905956820]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3726200924116]": { + "Id": "Entity_[3726200924116]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3730495891412]": { + "Id": "Entity_[3730495891412]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3734790858708]": { + "Id": "Entity_[3734790858708]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3739085826004]": { + "Id": "Entity_[3739085826004]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3743380793300]": { + "Id": "Entity_[3743380793300]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3747675760596]": { + "Id": "Entity_[3747675760596]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3751970727892]": { + "Id": "Entity_[3751970727892]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3756265695188]": { + "Id": "Entity_[3756265695188]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3760560662484]": { + "Id": "Entity_[3760560662484]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3764855629780]": { + "Id": "Entity_[3764855629780]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3769150597076]": { + "Id": "Entity_[3769150597076]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3773445564372]": { + "Id": "Entity_[3773445564372]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3777740531668]": { + "Id": "Entity_[3777740531668]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3782035498964]": { + "Id": "Entity_[3782035498964]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3786330466260]": { + "Id": "Entity_[3786330466260]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3790625433556]": { + "Id": "Entity_[3790625433556]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3794920400852]": { + "Id": "Entity_[3794920400852]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3799215368148]": { + "Id": "Entity_[3799215368148]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3803510335444]": { + "Id": "Entity_[3803510335444]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3807805302740]": { + "Id": "Entity_[3807805302740]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3812100270036]": { + "Id": "Entity_[3812100270036]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3816395237332]": { + "Id": "Entity_[3816395237332]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 9.51578426361084 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3820690204628]": { + "Id": "Entity_[3820690204628]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3824985171924]": { + "Id": "Entity_[3824985171924]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3829280139220]": { + "Id": "Entity_[3829280139220]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3833575106516]": { + "Id": "Entity_[3833575106516]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3837870073812]": { + "Id": "Entity_[3837870073812]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3842165041108]": { + "Id": "Entity_[3842165041108]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3846460008404]": { + "Id": "Entity_[3846460008404]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3850754975700]": { + "Id": "Entity_[3850754975700]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3855049942996]": { + "Id": "Entity_[3855049942996]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3859344910292]": { + "Id": "Entity_[3859344910292]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3863639877588]": { + "Id": "Entity_[3863639877588]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3867934844884]": { + "Id": "Entity_[3867934844884]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3872229812180]": { + "Id": "Entity_[3872229812180]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3876524779476]": { + "Id": "Entity_[3876524779476]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3880819746772]": { + "Id": "Entity_[3880819746772]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3885114714068]": { + "Id": "Entity_[3885114714068]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3889409681364]": { + "Id": "Entity_[3889409681364]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3893704648660]": { + "Id": "Entity_[3893704648660]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3897999615956]": { + "Id": "Entity_[3897999615956]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3902294583252]": { + "Id": "Entity_[3902294583252]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3906589550548]": { + "Id": "Entity_[3906589550548]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3910884517844]": { + "Id": "Entity_[3910884517844]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3915179485140]": { + "Id": "Entity_[3915179485140]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3919474452436]": { + "Id": "Entity_[3919474452436]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3923769419732]": { + "Id": "Entity_[3923769419732]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3928064387028]": { + "Id": "Entity_[3928064387028]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3932359354324]": { + "Id": "Entity_[3932359354324]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3936654321620]": { + "Id": "Entity_[3936654321620]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3940949288916]": { + "Id": "Entity_[3940949288916]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3945244256212]": { + "Id": "Entity_[3945244256212]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3949539223508]": { + "Id": "Entity_[3949539223508]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 24.573455810546875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3953834190804]": { + "Id": "Entity_[3953834190804]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3958129158100]": { + "Id": "Entity_[3958129158100]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3962424125396]": { + "Id": "Entity_[3962424125396]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3966719092692]": { + "Id": "Entity_[3966719092692]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3971014059988]": { + "Id": "Entity_[3971014059988]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3975309027284]": { + "Id": "Entity_[3975309027284]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3979603994580]": { + "Id": "Entity_[3979603994580]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3983898961876]": { + "Id": "Entity_[3983898961876]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3988193929172]": { + "Id": "Entity_[3988193929172]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3992488896468]": { + "Id": "Entity_[3992488896468]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E56377B1-6310-5311-A494-135BE50B74F0}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[3996783863764]": { + "Id": "Entity_[3996783863764]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4001078831060]": { + "Id": "Entity_[4001078831060]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4005373798356]": { + "Id": "Entity_[4005373798356]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4009668765652]": { + "Id": "Entity_[4009668765652]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4013963732948]": { + "Id": "Entity_[4013963732948]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4018258700244]": { + "Id": "Entity_[4018258700244]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4022553667540]": { + "Id": "Entity_[4022553667540]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4026848634836]": { + "Id": "Entity_[4026848634836]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4031143602132]": { + "Id": "Entity_[4031143602132]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4035438569428]": { + "Id": "Entity_[4035438569428]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4039733536724]": { + "Id": "Entity_[4039733536724]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4044028504020]": { + "Id": "Entity_[4044028504020]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4048323471316]": { + "Id": "Entity_[4048323471316]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4052618438612]": { + "Id": "Entity_[4052618438612]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4056913405908]": { + "Id": "Entity_[4056913405908]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4061208373204]": { + "Id": "Entity_[4061208373204]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4065503340500]": { + "Id": "Entity_[4065503340500]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4069798307796]": { + "Id": "Entity_[4069798307796]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4074093275092]": { + "Id": "Entity_[4074093275092]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4078388242388]": { + "Id": "Entity_[4078388242388]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 39.60029602050781 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4082683209684]": { + "Id": "Entity_[4082683209684]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4086978176980]": { + "Id": "Entity_[4086978176980]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4091273144276]": { + "Id": "Entity_[4091273144276]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 39.60029602050781 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4095568111572]": { + "Id": "Entity_[4095568111572]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4099863078868]": { + "Id": "Entity_[4099863078868]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4104158046164]": { + "Id": "Entity_[4104158046164]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4108453013460]": { + "Id": "Entity_[4108453013460]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 84.44650268554688 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4112747980756]": { + "Id": "Entity_[4112747980756]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4117042948052]": { + "Id": "Entity_[4117042948052]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4121337915348]": { + "Id": "Entity_[4121337915348]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4125632882644]": { + "Id": "Entity_[4125632882644]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4129927849940]": { + "Id": "Entity_[4129927849940]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4134222817236]": { + "Id": "Entity_[4134222817236]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4138517784532]": { + "Id": "Entity_[4138517784532]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4142812751828]": { + "Id": "Entity_[4142812751828]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4147107719124]": { + "Id": "Entity_[4147107719124]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4151402686420]": { + "Id": "Entity_[4151402686420]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4155697653716]": { + "Id": "Entity_[4155697653716]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4159992621012]": { + "Id": "Entity_[4159992621012]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4164287588308]": { + "Id": "Entity_[4164287588308]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4168582555604]": { + "Id": "Entity_[4168582555604]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4172877522900]": { + "Id": "Entity_[4172877522900]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4177172490196]": { + "Id": "Entity_[4177172490196]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4181467457492]": { + "Id": "Entity_[4181467457492]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4185762424788]": { + "Id": "Entity_[4185762424788]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4190057392084]": { + "Id": "Entity_[4190057392084]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4194352359380]": { + "Id": "Entity_[4194352359380]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4198647326676]": { + "Id": "Entity_[4198647326676]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4202942293972]": { + "Id": "Entity_[4202942293972]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4207237261268]": { + "Id": "Entity_[4207237261268]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4211532228564]": { + "Id": "Entity_[4211532228564]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4215827195860]": { + "Id": "Entity_[4215827195860]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4220122163156]": { + "Id": "Entity_[4220122163156]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4224417130452]": { + "Id": "Entity_[4224417130452]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4228712097748]": { + "Id": "Entity_[4228712097748]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4233007065044]": { + "Id": "Entity_[4233007065044]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4237302032340]": { + "Id": "Entity_[4237302032340]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4241596999636]": { + "Id": "Entity_[4241596999636]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4245891966932]": { + "Id": "Entity_[4245891966932]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4250186934228]": { + "Id": "Entity_[4250186934228]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4254481901524]": { + "Id": "Entity_[4254481901524]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4258776868820]": { + "Id": "Entity_[4258776868820]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4263071836116]": { + "Id": "Entity_[4263071836116]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4267366803412]": { + "Id": "Entity_[4267366803412]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4271661770708]": { + "Id": "Entity_[4271661770708]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4275956738004]": { + "Id": "Entity_[4275956738004]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4280251705300]": { + "Id": "Entity_[4280251705300]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4284546672596]": { + "Id": "Entity_[4284546672596]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4288841639892]": { + "Id": "Entity_[4288841639892]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4293136607188]": { + "Id": "Entity_[4293136607188]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4297431574484]": { + "Id": "Entity_[4297431574484]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4301726541780]": { + "Id": "Entity_[4301726541780]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4306021509076]": { + "Id": "Entity_[4306021509076]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4310316476372]": { + "Id": "Entity_[4310316476372]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4314611443668]": { + "Id": "Entity_[4314611443668]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4318906410964]": { + "Id": "Entity_[4318906410964]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4323201378260]": { + "Id": "Entity_[4323201378260]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4327496345556]": { + "Id": "Entity_[4327496345556]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4331791312852]": { + "Id": "Entity_[4331791312852]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4336086280148]": { + "Id": "Entity_[4336086280148]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4340381247444]": { + "Id": "Entity_[4340381247444]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4344676214740]": { + "Id": "Entity_[4344676214740]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4348971182036]": { + "Id": "Entity_[4348971182036]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4353266149332]": { + "Id": "Entity_[4353266149332]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4357561116628]": { + "Id": "Entity_[4357561116628]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4361856083924]": { + "Id": "Entity_[4361856083924]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4366151051220]": { + "Id": "Entity_[4366151051220]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4370446018516]": { + "Id": "Entity_[4370446018516]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4374740985812]": { + "Id": "Entity_[4374740985812]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4379035953108]": { + "Id": "Entity_[4379035953108]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4383330920404]": { + "Id": "Entity_[4383330920404]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4387625887700]": { + "Id": "Entity_[4387625887700]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4391920854996]": { + "Id": "Entity_[4391920854996]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4396215822292]": { + "Id": "Entity_[4396215822292]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4400510789588]": { + "Id": "Entity_[4400510789588]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4404805756884]": { + "Id": "Entity_[4404805756884]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4409100724180]": { + "Id": "Entity_[4409100724180]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4413395691476]": { + "Id": "Entity_[4413395691476]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4417690658772]": { + "Id": "Entity_[4417690658772]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4421985626068]": { + "Id": "Entity_[4421985626068]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4426280593364]": { + "Id": "Entity_[4426280593364]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4430575560660]": { + "Id": "Entity_[4430575560660]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4434870527956]": { + "Id": "Entity_[4434870527956]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4439165495252]": { + "Id": "Entity_[4439165495252]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4443460462548]": { + "Id": "Entity_[4443460462548]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4447755429844]": { + "Id": "Entity_[4447755429844]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4452050397140]": { + "Id": "Entity_[4452050397140]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4456345364436]": { + "Id": "Entity_[4456345364436]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4460640331732]": { + "Id": "Entity_[4460640331732]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4464935299028]": { + "Id": "Entity_[4464935299028]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4469230266324]": { + "Id": "Entity_[4469230266324]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4473525233620]": { + "Id": "Entity_[4473525233620]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4477820200916]": { + "Id": "Entity_[4477820200916]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4482115168212]": { + "Id": "Entity_[4482115168212]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4486410135508]": { + "Id": "Entity_[4486410135508]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4490705102804]": { + "Id": "Entity_[4490705102804]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4495000070100]": { + "Id": "Entity_[4495000070100]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4499295037396]": { + "Id": "Entity_[4499295037396]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4503590004692]": { + "Id": "Entity_[4503590004692]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CDA13277-5EAB-5E2A-93F5-B7003597FBCE}" + }, + "assetHint": "materials/presets/pbr/metal_silver.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4507884971988]": { + "Id": "Entity_[4507884971988]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4512179939284]": { + "Id": "Entity_[4512179939284]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4516474906580]": { + "Id": "Entity_[4516474906580]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4520769873876]": { + "Id": "Entity_[4520769873876]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4525064841172]": { + "Id": "Entity_[4525064841172]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4529359808468]": { + "Id": "Entity_[4529359808468]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4533654775764]": { + "Id": "Entity_[4533654775764]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4537949743060]": { + "Id": "Entity_[4537949743060]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4542244710356]": { + "Id": "Entity_[4542244710356]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4546539677652]": { + "Id": "Entity_[4546539677652]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4550834644948]": { + "Id": "Entity_[4550834644948]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4555129612244]": { + "Id": "Entity_[4555129612244]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4559424579540]": { + "Id": "Entity_[4559424579540]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4563719546836]": { + "Id": "Entity_[4563719546836]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4568014514132]": { + "Id": "Entity_[4568014514132]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{80E0F2A7-1EE4-597F-80EF-985C65BCE2EB}" + }, + "assetHint": "materials/presets/pbr/metal_brass.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4572309481428]": { + "Id": "Entity_[4572309481428]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4576604448724]": { + "Id": "Entity_[4576604448724]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4580899416020]": { + "Id": "Entity_[4580899416020]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4585194383316]": { + "Id": "Entity_[4585194383316]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4589489350612]": { + "Id": "Entity_[4589489350612]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4593784317908]": { + "Id": "Entity_[4593784317908]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[4598079285204]": { + "Id": "Entity_[4598079285204]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[479205648340]": { + "Id": "Entity_[479205648340]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[483500615636]": { + "Id": "Entity_[483500615636]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[487795582932]": { + "Id": "Entity_[487795582932]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[492090550228]": { + "Id": "Entity_[492090550228]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[496385517524]": { + "Id": "Entity_[496385517524]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[500680484820]": { + "Id": "Entity_[500680484820]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[504975452116]": { + "Id": "Entity_[504975452116]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[509270419412]": { + "Id": "Entity_[509270419412]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[513565386708]": { + "Id": "Entity_[513565386708]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{5BC13D95-377E-53EA-9A93-156384BE8B04}" + }, + "assetHint": "materials/presets/pbr/metal_gold_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[517860354004]": { + "Id": "Entity_[517860354004]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[522155321300]": { + "Id": "Entity_[522155321300]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E23FC75B-4142-55F1-B9AE-884826E7EB23}" + }, + "assetHint": "materials/presets/pbr/metal_platinum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[526450288596]": { + "Id": "Entity_[526450288596]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[530745255892]": { + "Id": "Entity_[530745255892]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[535040223188]": { + "Id": "Entity_[535040223188]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[539335190484]": { + "Id": "Entity_[539335190484]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[543630157780]": { + "Id": "Entity_[543630157780]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[547925125076]": { + "Id": "Entity_[547925125076]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[552220092372]": { + "Id": "Entity_[552220092372]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[556515059668]": { + "Id": "Entity_[556515059668]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[560810026964]": { + "Id": "Entity_[560810026964]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[565104994260]": { + "Id": "Entity_[565104994260]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[569399961556]": { + "Id": "Entity_[569399961556]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[573694928852]": { + "Id": "Entity_[573694928852]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[577989896148]": { + "Id": "Entity_[577989896148]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[582284863444]": { + "Id": "Entity_[582284863444]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[586579830740]": { + "Id": "Entity_[586579830740]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[590874798036]": { + "Id": "Entity_[590874798036]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[595169765332]": { + "Id": "Entity_[595169765332]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[599464732628]": { + "Id": "Entity_[599464732628]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[603759699924]": { + "Id": "Entity_[603759699924]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[608054667220]": { + "Id": "Entity_[608054667220]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DC0598ED-1EDD-5B37-892E-E0867621D74C}" + }, + "assetHint": "materials/presets/pbr/metal_palladium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[612349634516]": { + "Id": "Entity_[612349634516]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[616644601812]": { + "Id": "Entity_[616644601812]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[620939569108]": { + "Id": "Entity_[620939569108]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[625234536404]": { + "Id": "Entity_[625234536404]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[629529503700]": { + "Id": "Entity_[629529503700]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[633824470996]": { + "Id": "Entity_[633824470996]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[638119438292]": { + "Id": "Entity_[638119438292]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[642414405588]": { + "Id": "Entity_[642414405588]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[646709372884]": { + "Id": "Entity_[646709372884]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[651004340180]": { + "Id": "Entity_[651004340180]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[655299307476]": { + "Id": "Entity_[655299307476]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[659594274772]": { + "Id": "Entity_[659594274772]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[663889242068]": { + "Id": "Entity_[663889242068]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[668184209364]": { + "Id": "Entity_[668184209364]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[672479176660]": { + "Id": "Entity_[672479176660]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[676774143956]": { + "Id": "Entity_[676774143956]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[681069111252]": { + "Id": "Entity_[681069111252]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[685364078548]": { + "Id": "Entity_[685364078548]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[689659045844]": { + "Id": "Entity_[689659045844]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[693954013140]": { + "Id": "Entity_[693954013140]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 9.51578426361084 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[698248980436]": { + "Id": "Entity_[698248980436]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[702543947732]": { + "Id": "Entity_[702543947732]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[706838915028]": { + "Id": "Entity_[706838915028]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 74.93071746826172 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[711133882324]": { + "Id": "Entity_[711133882324]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[715428849620]": { + "Id": "Entity_[715428849620]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[719723816916]": { + "Id": "Entity_[719723816916]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[724018784212]": { + "Id": "Entity_[724018784212]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[728313751508]": { + "Id": "Entity_[728313751508]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E54E46E7-9FA3-54D7-B5F8-8DCCDF17BC24}" + }, + "assetHint": "materials/presets/pbr/metal_silver_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[732608718804]": { + "Id": "Entity_[732608718804]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[736903686100]": { + "Id": "Entity_[736903686100]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[741198653396]": { + "Id": "Entity_[741198653396]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A3F3CD98-1634-5542-AD5A-78E91BE21AE9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[745493620692]": { + "Id": "Entity_[745493620692]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[749788587988]": { + "Id": "Entity_[749788587988]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[754083555284]": { + "Id": "Entity_[754083555284]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[758378522580]": { + "Id": "Entity_[758378522580]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[762673489876]": { + "Id": "Entity_[762673489876]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[766968457172]": { + "Id": "Entity_[766968457172]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[771263424468]": { + "Id": "Entity_[771263424468]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[775558391764]": { + "Id": "Entity_[775558391764]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[779853359060]": { + "Id": "Entity_[779853359060]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[784148326356]": { + "Id": "Entity_[784148326356]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[788443293652]": { + "Id": "Entity_[788443293652]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[792738260948]": { + "Id": "Entity_[792738260948]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 39.56034851074219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[797033228244]": { + "Id": "Entity_[797033228244]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 114.53101348876953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[801328195540]": { + "Id": "Entity_[801328195540]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 22.53014373779297, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[805623162836]": { + "Id": "Entity_[805623162836]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[809918130132]": { + "Id": "Entity_[809918130132]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[814213097428]": { + "Id": "Entity_[814213097428]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{60D4CA04-A2FE-5AE7-B472-694C38D05183}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[818508064724]": { + "Id": "Entity_[818508064724]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[822803032020]": { + "Id": "Entity_[822803032020]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -42.53056335449219, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{AE350D9F-0000-526D-B49C-4303D687BB86}" + }, + "assetHint": "materials/presets/pbr/metal_brass_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[827097999316]": { + "Id": "Entity_[827097999316]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[831392966612]": { + "Id": "Entity_[831392966612]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[835687933908]": { + "Id": "Entity_[835687933908]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 79.38228607177734 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[839982901204]": { + "Id": "Entity_[839982901204]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 45.14218521118164 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[844277868500]": { + "Id": "Entity_[844277868500]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 84.40655517578125 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[848572835796]": { + "Id": "Entity_[848572835796]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[852867803092]": { + "Id": "Entity_[852867803092]", + "Name": "Entity1", + "Components": { + "Component_[1057179753323467068]": { + "$type": "EditorMaterialComponent", + "Id": 1057179753323467068, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 1057179753323467068, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 12.530143737792969, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[857162770388]": { + "Id": "Entity_[857162770388]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[861457737684]": { + "Id": "Entity_[861457737684]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 2.5301437377929688, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[865752704980]": { + "Id": "Entity_[865752704980]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[870047672276]": { + "Id": "Entity_[870047672276]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -37.53056335449219, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{B7C712DC-4839-58BB-B522-A4F120084CF5}" + }, + "assetHint": "materials/presets/pbr/metal_chrome.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[874342639572]": { + "Id": "Entity_[874342639572]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 4.451573371887207 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[878637606868]": { + "Id": "Entity_[878637606868]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 89.95755767822266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[882932574164]": { + "Id": "Entity_[882932574164]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{94CF2BD7-7D09-5577-B1D8-3FF85B15E127}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[887227541460]": { + "Id": "Entity_[887227541460]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 69.34888458251953 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[891522508756]": { + "Id": "Entity_[891522508756]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 0.0 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[895817476052]": { + "Id": "Entity_[895817476052]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[900112443348]": { + "Id": "Entity_[900112443348]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 34.53608703613281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[904407410644]": { + "Id": "Entity_[904407410644]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{C60A39AF-BB76-51BD-9468-A88C9A6F78D7}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[908702377940]": { + "Id": "Entity_[908702377940]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[912997345236]": { + "Id": "Entity_[912997345236]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[917292312532]": { + "Id": "Entity_[917292312532]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 94.40913391113281 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[921587279828]": { + "Id": "Entity_[921587279828]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -27.530563354492188, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[925882247124]": { + "Id": "Entity_[925882247124]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 17.53014373779297, + -0.00018183141946792603, + 15.057670593261719 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": {}, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{721188E0-B7CC-5D06-8D5D-39AF8ABF2EF9}" + }, + "assetHint": "materials/presets/pbr/metal_titanium.azmaterial" + } + } + }, + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[930177214420]": { + "Id": "Entity_[930177214420]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -7.5305633544921875, + -0.00018183141946792603, + 9.475835800170898 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{DD1E26AE-80FB-5DB6-8786-26D438190A38}" + }, + "assetHint": "materials/presets/pbr/metal_nickel.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[934472181716]": { + "Id": "Entity_[934472181716]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 47.53014373779297, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[938767149012]": { + "Id": "Entity_[938767149012]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 32.53014373779297, + -0.00018183141946792603, + 24.533506393432617 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[943062116308]": { + "Id": "Entity_[943062116308]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -22.530563354492188, + -0.00018183141946792603, + 30.08451271057129 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[947357083604]": { + "Id": "Entity_[947357083604]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 7.530143737792969, + -0.00018183141946792603, + 105.0152359008789 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[951652050900]": { + "Id": "Entity_[951652050900]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -32.53056335449219, + -0.00018183141946792603, + 114.4910659790039 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{99976D73-6248-5D66-AD15-E8F52B0AFE36}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[955947018196]": { + "Id": "Entity_[955947018196]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{970148AC-7258-5EC8-9CE7-F4EF93164D93}" + }, + "assetHint": "materials/presets/pbr/metal_iron_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[960241985492]": { + "Id": "Entity_[960241985492]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[964536952788]": { + "Id": "Entity_[964536952788]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -2.5305633544921875, + -0.00018183141946792603, + 19.50924301147461 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{9187B84B-425F-5D11-B4D7-35BBDB0959D1}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[968831920084]": { + "Id": "Entity_[968831920084]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 27.53014373779297, + -0.00018183141946792603, + 64.32462310791016 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A78EA2FC-688B-5E3A-A7F6-DB413D11D4CF}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[973126887380]": { + "Id": "Entity_[973126887380]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + -0.00018183141946792603, + 109.46680450439453 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2D054071-BEF7-53C0-A8C9-E4F026BD8364}" + }, + "assetHint": "materials/presets/pbr/metal_copper_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[977421854676]": { + "Id": "Entity_[977421854676]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 69.38883209228516 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[981716821972]": { + "Id": "Entity_[981716821972]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 42.53014373779297, + -0.00018183141946792603, + 99.43339538574219 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FE52E7C8-064D-506A-9C26-433EB93747DE}" + }, + "assetHint": "materials/presets/pbr/metal_gold.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[986011789268]": { + "Id": "Entity_[986011789268]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + 37.53014373779297, + 0.010651908814907074, + 99.47334289550781 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E621C5BF-B8E1-55F0-A791-EC960F2FA46F}" + }, + "assetHint": "materials/presets/pbr/metal_copper.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[990306756564]": { + "Id": "Entity_[990306756564]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -47.53056335449219, + -0.00018183141946792603, + 49.593753814697266 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{549D26B8-881D-569F-AF05-961F36A43F4F}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_matte.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[994601723860]": { + "Id": "Entity_[994601723860]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -17.530563354492188, + -0.00018183141946792603, + 54.618019104003906 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{892EA944-0325-5FA6-94D7-4AB4FC02A0F5}" + }, + "assetHint": "materials/presets/pbr/metal_iron.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + }, + "Entity_[998896691156]": { + "Id": "Entity_[998896691156]", + "Name": "Entity1", + "Components": { + "Component_[11525365929370623807]": { + "$type": "EditorVisibilityComponent", + "Id": 11525365929370623807 + }, + "Component_[12334620273692642550]": { + "$type": "EditorLockComponent", + "Id": 12334620273692642550 + }, + "Component_[14389735759337977675]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14389735759337977675 + }, + "Component_[16184381538555246534]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 16184381538555246534, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + }, + "Component_[17962478023087084794]": { + "$type": "SelectionComponent", + "Id": 17962478023087084794 + }, + "Component_[18071675051915092508]": { + "$type": "EditorEntityIconComponent", + "Id": 18071675051915092508 + }, + "Component_[2115498007879087044]": { + "$type": "EditorInspectorComponent", + "Id": 2115498007879087044, + "ComponentOrderEntryArray": [ + { + "ComponentId": 399415038452606756 + }, + { + "ComponentId": 16184381538555246534, + "SortIndex": 1 + }, + { + "ComponentId": 7827190074535394331, + "SortIndex": 2 + } + ] + }, + "Component_[3518973002096080237]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3518973002096080237 + }, + "Component_[399415038452606756]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 399415038452606756, + "Parent Entity": "ContainerEntity", + "Transform Data": { + "Translate": [ + -12.530563354492188, + -0.00018183141946792603, + 59.873046875 + ] + } + }, + "Component_[4564240319609068082]": { + "$type": "EditorEntitySortComponent", + "Id": 4564240319609068082 + }, + "Component_[7827190074535394331]": { + "$type": "EditorMaterialComponent", + "Id": 7827190074535394331, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[8092226976542590265]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 8092226976542590265 + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeAluminumPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeAluminumPolishedPBR.prefab new file mode 100644 index 0000000000..afec89bcc0 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeAluminumPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeAluminumPolishedPBR", + "Components": { + "Component_[1006636009791072742]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 1006636009791072742, + "Parent Entity": "" + }, + "Component_[1076262440422199293]": { + "$type": "EditorEntitySortComponent", + "Id": 1076262440422199293, + "Child Entity Order": [ + "Entity_[1040185651401]" + ] + }, + "Component_[10918235158079012184]": { + "$type": "EditorEntityIconComponent", + "Id": 10918235158079012184 + }, + "Component_[14325323304581185195]": { + "$type": "EditorOnlyEntityComponent", + "Id": 14325323304581185195 + }, + "Component_[15952647410502679667]": { + "$type": "EditorPendingCompositionComponent", + "Id": 15952647410502679667 + }, + "Component_[1646402264018781142]": { + "$type": "EditorVisibilityComponent", + "Id": 1646402264018781142 + }, + "Component_[2017972571432187012]": { + "$type": "EditorInspectorComponent", + "Id": 2017972571432187012 + }, + "Component_[478000835478069459]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 478000835478069459 + }, + "Component_[7132130710158542124]": { + "$type": "EditorPrefabComponent", + "Id": 7132130710158542124 + }, + "Component_[7457311619910333402]": { + "$type": "SelectionComponent", + "Id": 7457311619910333402 + }, + "Component_[8761313808145525748]": { + "$type": "EditorLockComponent", + "Id": 8761313808145525748 + } + } + }, + "Entities": { + "Entity_[1040185651401]": { + "Id": "Entity_[1040185651401]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{64C1F6A6-6BDA-551A-BE56-1829E5913278}" + }, + "assetHint": "materials/presets/pbr/metal_aluminum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeBrassPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeBrassPolishedPBR.prefab new file mode 100644 index 0000000000..beca9c9dba --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeBrassPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeBrassPolishedPBR", + "Components": { + "Component_[11392538078593907718]": { + "$type": "EditorVisibilityComponent", + "Id": 11392538078593907718 + }, + "Component_[15271285664593091377]": { + "$type": "EditorPrefabComponent", + "Id": 15271285664593091377 + }, + "Component_[16445950008096288691]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16445950008096288691 + }, + "Component_[17031759897155285515]": { + "$type": "EditorOnlyEntityComponent", + "Id": 17031759897155285515 + }, + "Component_[17333992135029064645]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17333992135029064645, + "Parent Entity": "" + }, + "Component_[2440848159410013062]": { + "$type": "EditorInspectorComponent", + "Id": 2440848159410013062 + }, + "Component_[4872690920600271776]": { + "$type": "EditorEntityIconComponent", + "Id": 4872690920600271776 + }, + "Component_[8105157811055641931]": { + "$type": "SelectionComponent", + "Id": 8105157811055641931 + }, + "Component_[8121804356127130254]": { + "$type": "EditorLockComponent", + "Id": 8121804356127130254 + }, + "Component_[9156467458085058309]": { + "$type": "EditorPendingCompositionComponent", + "Id": 9156467458085058309 + }, + "Component_[998572165026441124]": { + "$type": "EditorEntitySortComponent", + "Id": 998572165026441124, + "Child Entity Order": [ + "Entity_[1169034670281]" + ] + } + } + }, + "Entities": { + "Entity_[1169034670281]": { + "Id": "Entity_[1169034670281]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FC69F2F8-F73B-5A0C-B8B7-94BAA45780FC}" + }, + "assetHint": "materials/presets/pbr/metal_brass_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeChromePolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeChromePolishedPBR.prefab new file mode 100644 index 0000000000..6f933ad666 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeChromePolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeChromePolishedPBR", + "Components": { + "Component_[10194322458002226643]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10194322458002226643 + }, + "Component_[12036481316264753863]": { + "$type": "EditorVisibilityComponent", + "Id": 12036481316264753863 + }, + "Component_[12378089635489881977]": { + "$type": "EditorInspectorComponent", + "Id": 12378089635489881977 + }, + "Component_[14430665156325163680]": { + "$type": "EditorPendingCompositionComponent", + "Id": 14430665156325163680 + }, + "Component_[15205683346512266293]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 15205683346512266293, + "Parent Entity": "" + }, + "Component_[16051828087924530008]": { + "$type": "EditorLockComponent", + "Id": 16051828087924530008 + }, + "Component_[3910753277078082783]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 3910753277078082783 + }, + "Component_[4999195701117409226]": { + "$type": "EditorEntityIconComponent", + "Id": 4999195701117409226 + }, + "Component_[5435519106043975119]": { + "$type": "EditorEntitySortComponent", + "Id": 5435519106043975119, + "Child Entity Order": [ + "Entity_[1315063558345]" + ] + }, + "Component_[6762050164377989214]": { + "$type": "EditorPrefabComponent", + "Id": 6762050164377989214 + }, + "Component_[7395721573111063938]": { + "$type": "SelectionComponent", + "Id": 7395721573111063938 + } + } + }, + "Entities": { + "Entity_[1315063558345]": { + "Id": "Entity_[1315063558345]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CAF50181-3384-5DF2-9304-C6E48E83C72D}" + }, + "assetHint": "materials/presets/pbr/metal_chrome_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeCobaltPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeCobaltPolishedPBR.prefab new file mode 100644 index 0000000000..82ed5264dd --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeCobaltPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeCobaltPolishedPBR", + "Components": { + "Component_[12811832964126776693]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 12811832964126776693, + "Parent Entity": "" + }, + "Component_[13295886036381057017]": { + "$type": "EditorPrefabComponent", + "Id": 13295886036381057017 + }, + "Component_[13767840970182343359]": { + "$type": "SelectionComponent", + "Id": 13767840970182343359 + }, + "Component_[16269039178417460408]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 16269039178417460408 + }, + "Component_[16338942903899315753]": { + "$type": "EditorLockComponent", + "Id": 16338942903899315753 + }, + "Component_[16938354010512315058]": { + "$type": "EditorVisibilityComponent", + "Id": 16938354010512315058 + }, + "Component_[18087692989611771228]": { + "$type": "EditorEntitySortComponent", + "Id": 18087692989611771228, + "Child Entity Order": [ + "Entity_[1478272315593]" + ] + }, + "Component_[2408892657833094901]": { + "$type": "EditorInspectorComponent", + "Id": 2408892657833094901 + }, + "Component_[3273159330768091937]": { + "$type": "EditorPendingCompositionComponent", + "Id": 3273159330768091937 + }, + "Component_[8251134042453350781]": { + "$type": "EditorEntityIconComponent", + "Id": 8251134042453350781 + }, + "Component_[9830348537229676775]": { + "$type": "EditorOnlyEntityComponent", + "Id": 9830348537229676775 + } + } + }, + "Entities": { + "Entity_[1478272315593]": { + "Id": "Entity_[1478272315593]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{93DF55AE-8D1B-5AD1-A609-05F1BD9F6EA0}" + }, + "assetHint": "materials/presets/pbr/metal_cobalt_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeCopperPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeCopperPolishedPBR.prefab new file mode 100644 index 0000000000..ca6680593b --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeCopperPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeCopperPolishedPBR", + "Components": { + "Component_[14120317269315619433]": { + "$type": "SelectionComponent", + "Id": 14120317269315619433 + }, + "Component_[143917687187100454]": { + "$type": "EditorInspectorComponent", + "Id": 143917687187100454 + }, + "Component_[15260876699496078513]": { + "$type": "EditorPrefabComponent", + "Id": 15260876699496078513 + }, + "Component_[1746418914802949089]": { + "$type": "EditorOnlyEntityComponent", + "Id": 1746418914802949089 + }, + "Component_[18443523081045072277]": { + "$type": "EditorPendingCompositionComponent", + "Id": 18443523081045072277 + }, + "Component_[4010874908443542212]": { + "$type": "EditorLockComponent", + "Id": 4010874908443542212 + }, + "Component_[4271734532103635304]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4271734532103635304 + }, + "Component_[4383829137523954163]": { + "$type": "EditorEntityIconComponent", + "Id": 4383829137523954163 + }, + "Component_[5749675910289562089]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 5749675910289562089, + "Parent Entity": "" + }, + "Component_[6232920837132171119]": { + "$type": "EditorVisibilityComponent", + "Id": 6232920837132171119 + }, + "Component_[7306146920796854544]": { + "$type": "EditorEntitySortComponent", + "Id": 7306146920796854544, + "Child Entity Order": [ + "Entity_[1658660942025]" + ] + } + } + }, + "Entities": { + "Entity_[1658660942025]": { + "Id": "Entity_[1658660942025]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{CF5C7B01-4912-58AE-991A-F25251E505AC}" + }, + "assetHint": "materials/presets/pbr/metal_copper_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeGoldPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeGoldPolishedPBR.prefab new file mode 100644 index 0000000000..f6b678bb32 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeGoldPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeGoldPolishedPBR", + "Components": { + "Component_[10011820011377711118]": { + "$type": "EditorLockComponent", + "Id": 10011820011377711118 + }, + "Component_[10068789746496377466]": { + "$type": "EditorPrefabComponent", + "Id": 10068789746496377466 + }, + "Component_[11570676153379582500]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11570676153379582500, + "Parent Entity": "" + }, + "Component_[13003038310843603631]": { + "$type": "EditorVisibilityComponent", + "Id": 13003038310843603631 + }, + "Component_[15807328745370882636]": { + "$type": "SelectionComponent", + "Id": 15807328745370882636 + }, + "Component_[2750440106393392905]": { + "$type": "EditorEntitySortComponent", + "Id": 2750440106393392905, + "Child Entity Order": [ + "Entity_[1856229437641]" + ] + }, + "Component_[2761752922494043610]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 2761752922494043610 + }, + "Component_[3027606009106407466]": { + "$type": "EditorInspectorComponent", + "Id": 3027606009106407466 + }, + "Component_[4326682049246572673]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4326682049246572673 + }, + "Component_[5821381882600148312]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821381882600148312 + }, + "Component_[6068739143830165037]": { + "$type": "EditorEntityIconComponent", + "Id": 6068739143830165037 + } + } + }, + "Entities": { + "Entity_[1856229437641]": { + "Id": "Entity_[1856229437641]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{FB4657EB-FB3A-5EC3-A772-DC36D6F733C3}" + }, + "assetHint": "materials/presets/pbr/metal_gold_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeIronPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeIronPolishedPBR.prefab new file mode 100644 index 0000000000..f7118b4084 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeIronPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeIronPolishedPBR", + "Components": { + "Component_[10744633821142630765]": { + "$type": "EditorOnlyEntityComponent", + "Id": 10744633821142630765 + }, + "Component_[15160812085690623525]": { + "$type": "EditorPrefabComponent", + "Id": 15160812085690623525 + }, + "Component_[17506200912680653288]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 17506200912680653288, + "Parent Entity": "" + }, + "Component_[1779514216896114299]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1779514216896114299 + }, + "Component_[2089200513910230823]": { + "$type": "EditorPendingCompositionComponent", + "Id": 2089200513910230823 + }, + "Component_[3904312129158421170]": { + "$type": "EditorEntityIconComponent", + "Id": 3904312129158421170 + }, + "Component_[5126366677360310098]": { + "$type": "EditorVisibilityComponent", + "Id": 5126366677360310098 + }, + "Component_[6443652007083636420]": { + "$type": "EditorEntitySortComponent", + "Id": 6443652007083636420, + "Child Entity Order": [ + "Entity_[2070977802441]" + ] + }, + "Component_[8531209872369121358]": { + "$type": "EditorInspectorComponent", + "Id": 8531209872369121358 + }, + "Component_[8558242753126803571]": { + "$type": "SelectionComponent", + "Id": 8558242753126803571 + }, + "Component_[8938179055081804896]": { + "$type": "EditorLockComponent", + "Id": 8938179055081804896 + } + } + }, + "Entities": { + "Entity_[2070977802441]": { + "Id": "Entity_[2070977802441]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{A7F03135-ECAD-5440-99DB-E84ABA3D50DA}" + }, + "assetHint": "materials/presets/pbr/metal_iron_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeMercuryPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeMercuryPBR.prefab new file mode 100644 index 0000000000..2977bff25b --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeMercuryPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeMercuryPBR", + "Components": { + "Component_[11796219437064669544]": { + "$type": "SelectionComponent", + "Id": 11796219437064669544 + }, + "Component_[12551667429170676889]": { + "$type": "EditorPrefabComponent", + "Id": 12551667429170676889 + }, + "Component_[12693460746131498096]": { + "$type": "EditorInspectorComponent", + "Id": 12693460746131498096 + }, + "Component_[14262931207267008977]": { + "$type": "EditorEntityIconComponent", + "Id": 14262931207267008977 + }, + "Component_[18045441039226816973]": { + "$type": "EditorEntitySortComponent", + "Id": 18045441039226816973, + "Child Entity Order": [ + "Entity_[928516501705]" + ] + }, + "Component_[2268958959705742396]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 2268958959705742396, + "Parent Entity": "" + }, + "Component_[3379321424051234761]": { + "$type": "EditorVisibilityComponent", + "Id": 3379321424051234761 + }, + "Component_[3967973434353405611]": { + "$type": "EditorLockComponent", + "Id": 3967973434353405611 + }, + "Component_[6260092263143569388]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 6260092263143569388 + }, + "Component_[6596926416684557718]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6596926416684557718 + }, + "Component_[9068640134216835201]": { + "$type": "EditorPendingCompositionComponent", + "Id": 9068640134216835201 + } + } + }, + "Entities": { + "Entity_[928516501705]": { + "Id": "Entity_[928516501705]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{F2AD0EBF-7137-58D1-9991-9552FAD41B19}" + }, + "assetHint": "materials/presets/pbr/metal_mercury.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeNickelPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeNickelPolishedPBR.prefab new file mode 100644 index 0000000000..22fa0873b1 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeNickelPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeNickelPolishedPBR", + "Components": { + "Component_[10826024012928681054]": { + "$type": "EditorPendingCompositionComponent", + "Id": 10826024012928681054 + }, + "Component_[12821987693261496174]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 12821987693261496174, + "Parent Entity": "" + }, + "Component_[1347237730046420905]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 1347237730046420905 + }, + "Component_[13962868105035894085]": { + "$type": "EditorInspectorComponent", + "Id": 13962868105035894085 + }, + "Component_[17956955568472089321]": { + "$type": "EditorOnlyEntityComponent", + "Id": 17956955568472089321 + }, + "Component_[1982369816302736367]": { + "$type": "EditorLockComponent", + "Id": 1982369816302736367 + }, + "Component_[2765278216943439310]": { + "$type": "EditorEntityIconComponent", + "Id": 2765278216943439310 + }, + "Component_[2823302329697962266]": { + "$type": "SelectionComponent", + "Id": 2823302329697962266 + }, + "Component_[5490362878017390612]": { + "$type": "EditorVisibilityComponent", + "Id": 5490362878017390612 + }, + "Component_[7468073145776592577]": { + "$type": "EditorEntitySortComponent", + "Id": 7468073145776592577, + "Child Entity Order": [ + "Entity_[2302906036425]" + ] + }, + "Component_[7692885660975737763]": { + "$type": "EditorPrefabComponent", + "Id": 7692885660975737763 + } + } + }, + "Entities": { + "Entity_[2302906036425]": { + "Id": "Entity_[2302906036425]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{E66E4343-F45A-536D-AAE1-C4D096420640}" + }, + "assetHint": "materials/presets/pbr/metal_nickel_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubePalladiumPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubePalladiumPolishedPBR.prefab new file mode 100644 index 0000000000..ace44a3d34 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubePalladiumPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubePalladiumPolishedPBR", + "Components": { + "Component_[10678536274818457672]": { + "$type": "EditorInspectorComponent", + "Id": 10678536274818457672 + }, + "Component_[12041428694628704247]": { + "$type": "EditorPendingCompositionComponent", + "Id": 12041428694628704247 + }, + "Component_[12143022343588526078]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 12143022343588526078 + }, + "Component_[15178316190409605112]": { + "$type": "EditorVisibilityComponent", + "Id": 15178316190409605112 + }, + "Component_[16012620721047170064]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 16012620721047170064, + "Parent Entity": "" + }, + "Component_[1646888921009876369]": { + "$type": "EditorPrefabComponent", + "Id": 1646888921009876369 + }, + "Component_[17677550467282239311]": { + "$type": "EditorEntitySortComponent", + "Id": 17677550467282239311, + "Child Entity Order": [ + "Entity_[2552014139593]" + ] + }, + "Component_[4972639499125068141]": { + "$type": "EditorLockComponent", + "Id": 4972639499125068141 + }, + "Component_[5526570610744382545]": { + "$type": "SelectionComponent", + "Id": 5526570610744382545 + }, + "Component_[6509459924043770606]": { + "$type": "EditorOnlyEntityComponent", + "Id": 6509459924043770606 + }, + "Component_[7268409859686144269]": { + "$type": "EditorEntityIconComponent", + "Id": 7268409859686144269 + } + } + }, + "Entities": { + "Entity_[2552014139593]": { + "Id": "Entity_[2552014139593]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{D0E9960A-4B31-5136-BAC6-5482B203D3B4}" + }, + "assetHint": "materials/presets/pbr/metal_palladium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubePlatinumPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubePlatinumPolishedPBR.prefab new file mode 100644 index 0000000000..79bc443342 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubePlatinumPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubePlatinumPolishedPBR", + "Components": { + "Component_[12172311178585433096]": { + "$type": "EditorEntityIconComponent", + "Id": 12172311178585433096 + }, + "Component_[14133734575774270778]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14133734575774270778 + }, + "Component_[1499102502234135899]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 1499102502234135899, + "Parent Entity": "" + }, + "Component_[17753826932279572795]": { + "$type": "EditorOnlyEntityComponent", + "Id": 17753826932279572795 + }, + "Component_[3472150728361446089]": { + "$type": "EditorPrefabComponent", + "Id": 3472150728361446089 + }, + "Component_[5413614787652013946]": { + "$type": "EditorLockComponent", + "Id": 5413614787652013946 + }, + "Component_[6608132617418028580]": { + "$type": "EditorEntitySortComponent", + "Id": 6608132617418028580, + "Child Entity Order": [ + "Entity_[2818302111945]" + ] + }, + "Component_[6809102061425149362]": { + "$type": "EditorInspectorComponent", + "Id": 6809102061425149362 + }, + "Component_[6916818921856882722]": { + "$type": "EditorPendingCompositionComponent", + "Id": 6916818921856882722 + }, + "Component_[7486700682637381880]": { + "$type": "SelectionComponent", + "Id": 7486700682637381880 + }, + "Component_[7993011597330638847]": { + "$type": "EditorVisibilityComponent", + "Id": 7993011597330638847 + } + } + }, + "Entities": { + "Entity_[2818302111945]": { + "Id": "Entity_[2818302111945]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{79419183-FFCE-5A89-AA16-C2789D81AF75}" + }, + "assetHint": "materials/presets/pbr/metal_platinum_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeSilverPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeSilverPolishedPBR.prefab new file mode 100644 index 0000000000..74a166e09c --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeSilverPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeSilverPolishedPBR", + "Components": { + "Component_[10846467226799581471]": { + "$type": "EditorPrefabComponent", + "Id": 10846467226799581471 + }, + "Component_[11321068769303258722]": { + "$type": "SelectionComponent", + "Id": 11321068769303258722 + }, + "Component_[14255141886015898000]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 14255141886015898000 + }, + "Component_[14442599743555977836]": { + "$type": "EditorLockComponent", + "Id": 14442599743555977836 + }, + "Component_[15390328167304917483]": { + "$type": "EditorOnlyEntityComponent", + "Id": 15390328167304917483 + }, + "Component_[16667892946203958068]": { + "$type": "EditorInspectorComponent", + "Id": 16667892946203958068 + }, + "Component_[17957849336986334052]": { + "$type": "EditorPendingCompositionComponent", + "Id": 17957849336986334052 + }, + "Component_[18049054501916401618]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 18049054501916401618, + "Parent Entity": "" + }, + "Component_[362051120594559781]": { + "$type": "EditorVisibilityComponent", + "Id": 362051120594559781 + }, + "Component_[5852346937789040993]": { + "$type": "EditorEntitySortComponent", + "Id": 5852346937789040993, + "Child Entity Order": [ + "Entity_[3101769953481]" + ] + }, + "Component_[7250311833503679341]": { + "$type": "EditorEntityIconComponent", + "Id": 7250311833503679341 + } + } + }, + "Entities": { + "Entity_[3101769953481]": { + "Id": "Entity_[3101769953481]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{2AC06FA3-7670-542E-8996-DF346AFF1B61}" + }, + "assetHint": "materials/presets/pbr/metal_silver_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/Prefabs/TestData/Graphics/CubeTitaniumPolishedPBR.prefab b/AutomatedTesting/Prefabs/TestData/Graphics/CubeTitaniumPolishedPBR.prefab new file mode 100644 index 0000000000..c732fee593 --- /dev/null +++ b/AutomatedTesting/Prefabs/TestData/Graphics/CubeTitaniumPolishedPBR.prefab @@ -0,0 +1,156 @@ +{ + "ContainerEntity": { + "Id": "ContainerEntity", + "Name": "CubeTitaniumPolishedPBR", + "Components": { + "Component_[11835136016071721229]": { + "$type": "EditorInspectorComponent", + "Id": 11835136016071721229 + }, + "Component_[14924371629431224666]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 14924371629431224666, + "Parent Entity": "" + }, + "Component_[15534521734777674027]": { + "$type": "EditorPrefabComponent", + "Id": 15534521734777674027 + }, + "Component_[16612248066971579226]": { + "$type": "SelectionComponent", + "Id": 16612248066971579226 + }, + "Component_[16806731875899878085]": { + "$type": "EditorLockComponent", + "Id": 16806731875899878085 + }, + "Component_[3294763415970396682]": { + "$type": "EditorOnlyEntityComponent", + "Id": 3294763415970396682 + }, + "Component_[3871617444656658973]": { + "$type": "EditorEntitySortComponent", + "Id": 3871617444656658973, + "Child Entity Order": [ + "Entity_[3406712631497]" + ] + }, + "Component_[6604961087017250006]": { + "$type": "EditorEntityIconComponent", + "Id": 6604961087017250006 + }, + "Component_[6721284225512452216]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 6721284225512452216 + }, + "Component_[8673188027501037544]": { + "$type": "EditorPendingCompositionComponent", + "Id": 8673188027501037544 + }, + "Component_[9993323762911548658]": { + "$type": "EditorVisibilityComponent", + "Id": 9993323762911548658 + } + } + }, + "Entities": { + "Entity_[3406712631497]": { + "Id": "Entity_[3406712631497]", + "Name": "Entity1", + "Components": { + "Component_[11024839750215572075]": { + "$type": "SelectionComponent", + "Id": 11024839750215572075 + }, + "Component_[11384176886283708819]": { + "$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent", + "Id": 11384176886283708819, + "Parent Entity": "ContainerEntity" + }, + "Component_[1606410272595503925]": { + "$type": "EditorMaterialComponent", + "Id": 1606410272595503925, + "Controller": { + "Configuration": { + "materials": [ + { + "Key": { + "materialSlotStableId": 2418540911 + }, + "Value": { + "MaterialAsset": { + "assetId": { + "guid": "{3F0DF0C4-5F23-5EB1-B762-7344AFFDC011}" + }, + "assetHint": "materials/presets/pbr/metal_titanium_polished.azmaterial" + } + } + } + ] + } + } + }, + "Component_[16470114336751653654]": { + "$type": "EditorInspectorComponent", + "Id": 16470114336751653654, + "ComponentOrderEntryArray": [ + { + "ComponentId": 11384176886283708819 + }, + { + "ComponentId": 89717634602996901, + "SortIndex": 1 + }, + { + "ComponentId": 1606410272595503925, + "SortIndex": 2 + } + ] + }, + "Component_[4303036201889516060]": { + "$type": "EditorLockComponent", + "Id": 4303036201889516060 + }, + "Component_[44336138790150350]": { + "$type": "EditorEntitySortComponent", + "Id": 44336138790150350 + }, + "Component_[4558973254917759795]": { + "$type": "EditorDisabledCompositionComponent", + "Id": 4558973254917759795 + }, + "Component_[4674030476408790307]": { + "$type": "EditorPendingCompositionComponent", + "Id": 4674030476408790307 + }, + "Component_[4802851695039968062]": { + "$type": "EditorVisibilityComponent", + "Id": 4802851695039968062 + }, + "Component_[5821006029055754615]": { + "$type": "EditorOnlyEntityComponent", + "Id": 5821006029055754615 + }, + "Component_[8587156575497792590]": { + "$type": "EditorEntityIconComponent", + "Id": 8587156575497792590 + }, + "Component_[89717634602996901]": { + "$type": "AZ::Render::EditorMeshComponent", + "Id": 89717634602996901, + "Controller": { + "Configuration": { + "ModelAsset": { + "assetId": { + "guid": "{E14975EF-E676-51A4-B826-3EF59CB645AA}", + "subId": 285127096 + }, + "assetHint": "testdata/objects/cube/cube.azmodel" + } + } + } + } + } + } + } +} \ No newline at end of file diff --git a/AutomatedTesting/TestAssets/test_chunks_builder.py b/AutomatedTesting/TestAssets/test_chunks_builder.py index 2fd1ad9db9..b18902a34c 100755 --- a/AutomatedTesting/TestAssets/test_chunks_builder.py +++ b/AutomatedTesting/TestAssets/test_chunks_builder.py @@ -28,7 +28,7 @@ def update_manifest(scene): meshGroup = sceneManifest.add_mesh_group(chunkName) meshGroup['id'] = '{' + str(uuid.uuid5(uuid.NAMESPACE_DNS, scene.sourceFilename + chunkName)) + '}' sceneManifest.mesh_group_add_comment(meshGroup, 'auto generated by test_chunks_builder') - sceneManifest.mesh_group_set_origin(meshGroup, None, 0, 0, 0, 1.0) + sceneManifest.mesh_group_add_advanced_coordinate_system(meshGroup) for meshIndex in range(len(chunkNameList)): if (activeMeshIndex == meshIndex): sceneManifest.mesh_group_select_node(meshGroup, chunkNameList[meshIndex]) diff --git a/AutomatedTesting/project.json b/AutomatedTesting/project.json index 9222777ef3..5a4b303570 100644 --- a/AutomatedTesting/project.json +++ b/AutomatedTesting/project.json @@ -5,12 +5,15 @@ "modules": [], "project_id": "{D816AFAE-4BB7-4FEF-88F4-E2B786DCF29D}", "android_settings": { - "package_name": "com.lumberyard.yourgame", + "package_name": "org.o3de.automatedtesting", "version_number": 1, - "version_name": "1.0.0.0", + "version_name": "1.0.0", "orientation": "landscape" }, "engine": "o3de", "display_name": "AutomatedTesting", - "icon_path": "preview.png" -} + "icon_path": "preview.png", + "external_subdirectories": [ + "Gem" + ] +} \ No newline at end of file diff --git a/CMakeLists.txt b/CMakeLists.txt index f61a9561e8..c81581fe0f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -49,21 +49,56 @@ include(cmake/O3DEJson.cmake) # Subdirectory processing ################################################################################ +# this function is building up the LY_EXTERNAL_SUBDIRS global property +function(add_engine_gem_json_external_subdirectories gem_path) + set(gem_json_path ${gem_path}/gem.json) + if(EXISTS ${gem_json_path}) + read_json_external_subdirs(gem_external_subdirs ${gem_path}/gem.json) + foreach(gem_external_subdir ${gem_external_subdirs}) + file(REAL_PATH ${gem_external_subdir} real_external_subdir BASE_DIRECTORY ${gem_path}) + set_property(GLOBAL APPEND PROPERTY LY_EXTERNAL_SUBDIRS ${real_external_subdir}) + add_engine_gem_json_external_subdirectories(${real_external_subdir}) + endforeach() + endif() +endfunction() + function(add_engine_json_external_subdirectories) - read_json_external_subdirs(external_subdis ${LY_ROOT_FOLDER}/engine.json) - foreach(external_subdir ${external_subdis}) - file(REAL_PATH ${external_subdir} real_external_subdir BASE_DIRECTORY ${LY_ROOT_FOLDER}) - list(APPEND engine_external_subdirs ${real_external_subdir}) + read_json_external_subdirs(engine_external_subdirs ${LY_ROOT_FOLDER}/engine.json) + foreach(engine_external_subdir ${engine_external_subdirs}) + file(REAL_PATH ${engine_external_subdir} real_external_subdir BASE_DIRECTORY ${LY_ROOT_FOLDER}) + set_property(GLOBAL APPEND PROPERTY LY_EXTERNAL_SUBDIRS ${real_external_subdir}) + add_engine_gem_json_external_subdirectories(${real_external_subdir}) endforeach() +endfunction() - set_property(GLOBAL APPEND PROPERTY LY_EXTERNAL_SUBDIRS ${engine_external_subdirs}) +function(add_subdirectory_on_externalsubdirs) + get_property(external_subdirs GLOBAL PROPERTY LY_EXTERNAL_SUBDIRS) + list(APPEND LY_EXTERNAL_SUBDIRS ${external_subdirs}) + # Loop over the additional external subdirectories and invoke add_subdirectory on them + foreach(external_directory ${LY_EXTERNAL_SUBDIRS}) + # Hash the external_directory name and append it to the Binary Directory section of add_subdirectory + # This is to deal with potential situations where multiple external directories has the same last directory name + # For example if D:/Company1/RayTracingGem and F:/Company2/Path/RayTracingGem were both added as a subdirectory + file(REAL_PATH ${external_directory} full_directory_path) + string(SHA256 full_directory_hash ${full_directory_path}) + # Truncate the full_directory_hash down to 8 characters to avoid hitting the Windows 260 character path limit + # when the external subdirectory contains relative paths of significant length + string(SUBSTRING ${full_directory_hash} 0 8 full_directory_hash) + # Use the last directory as the suffix path to use for the Binary Directory + get_filename_component(directory_name ${external_directory} NAME) + add_subdirectory(${external_directory} ${CMAKE_BINARY_DIR}/External/${directory_name}-${full_directory_hash}) + endforeach() endfunction() # Add the projects first so the Launcher can find them include(cmake/Projects.cmake) if(NOT INSTALLED_ENGINE) - + # Add external subdirectories listed in the engine.json. LY_EXTERNAL_SUBDIRS is a cache variable so the user can add extra + # external subdirectories. This should go before adding the rest of the targets so the targets are availbe to the launcher. + add_engine_json_external_subdirectories() + add_subdirectory_on_externalsubdirs() + # Add the rest of the targets add_subdirectory(Assets) add_subdirectory(Code) @@ -73,31 +108,11 @@ if(NOT INSTALLED_ENGINE) add_subdirectory(Templates) add_subdirectory(Tools) - # Add external subdirectories listed in the engine.json. LY_EXTERNAL_SUBDIRS is a cache variable so the user can add extra - # external subdirectories - add_engine_json_external_subdirectories() else() ly_find_o3de_packages() + add_subdirectory_on_externalsubdirs() endif() -get_property(external_subdirs GLOBAL PROPERTY LY_EXTERNAL_SUBDIRS) -list(APPEND LY_EXTERNAL_SUBDIRS ${external_subdirs}) - -# Loop over the additional external subdirectories and invoke add_subdirectory on them -foreach(external_directory ${LY_EXTERNAL_SUBDIRS}) - # Hash the extenal_directory name and append it to the Binary Directory section of add_subdirectory - # This is to deal with potential situations where multiple external directories has the same last directory name - # For example if D:/Company1/RayTracingGem and F:/Company2/Path/RayTracingGem were both added as a subdirectory - file(REAL_PATH ${external_directory} full_directory_path) - string(SHA256 full_directory_hash ${full_directory_path}) - # Truncate the full_directory_hash down to 8 characters to avoid hitting the Windows 260 character path limit - # when the external subdirectory contains relative paths of significant length - string(SUBSTRING ${full_directory_hash} 0 8 full_directory_hash) - # Use the last directory as the suffix path to use for the Binary Directory - get_filename_component(directory_name ${external_directory} NAME) - add_subdirectory(${external_directory} ${CMAKE_BINARY_DIR}/External/${directory_name}-${full_directory_hash}) -endforeach() - ################################################################################ # Post-processing ################################################################################ diff --git a/Code/Editor/AboutDialog.cpp b/Code/Editor/AboutDialog.cpp index c0fd39e1ae..ba086cad5d 100644 --- a/Code/Editor/AboutDialog.cpp +++ b/Code/Editor/AboutDialog.cpp @@ -30,8 +30,6 @@ CAboutDialog::CAboutDialog(QString versionText, QString richTextCopyrightNotice, m_ui->setupUi(this); setWindowFlags(windowFlags() & ~Qt::WindowContextHelpButtonHint); - connect(m_ui->m_transparentAgreement, &QLabel::linkActivated, this, &CAboutDialog::OnCustomerAgreement); - m_ui->m_transparentTrademarks->setText(versionText); m_ui->m_transparentAllRightReserved->setObjectName("copyrightNotice"); @@ -84,9 +82,4 @@ void CAboutDialog::mouseReleaseEvent(QMouseEvent* event) QDialog::mouseReleaseEvent(event); } -void CAboutDialog::OnCustomerAgreement() -{ - QDesktopServices::openUrl(QUrl(QStringLiteral("https://www.o3debinaries.org/license"))); -} - #include diff --git a/Code/Editor/AboutDialog.h b/Code/Editor/AboutDialog.h index db079a6ec7..279d7cd399 100644 --- a/Code/Editor/AboutDialog.h +++ b/Code/Editor/AboutDialog.h @@ -30,8 +30,6 @@ public: private: - void OnCustomerAgreement(); - void mouseReleaseEvent(QMouseEvent* event) override; void paintEvent(QPaintEvent* event) override; diff --git a/Code/Editor/AboutDialog.ui b/Code/Editor/AboutDialog.ui index 09a7c18841..a7433c620f 100644 --- a/Code/Editor/AboutDialog.ui +++ b/Code/Editor/AboutDialog.ui @@ -181,14 +181,17 @@ - + - Terms of Use + <a href="https://www.o3debinaries.org/license">Terms of Use</a> + + + Qt::RichText Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop - + true @@ -274,11 +277,6 @@ QWidget
qsvgwidget.h
- - ClickableLabel - QLabel -
QtUI/ClickableLabel.h
-
diff --git a/Code/Editor/Animation/AnimationBipedBoneNames.cpp b/Code/Editor/Animation/AnimationBipedBoneNames.cpp deleted file mode 100644 index 72502fe61d..0000000000 --- a/Code/Editor/Animation/AnimationBipedBoneNames.cpp +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include "EditorDefs.h" - -#include "AnimationBipedBoneNames.h" - -namespace EditorAnimationBones::Biped -{ - const char* Pelvis = "Bip01 Pelvis"; - const char* Head = "Bip01 Head"; - const char* Weapon = "weapon_bone"; - - const char* LeftEye = "eye_bone_left"; - const char* RightEye = "eye_bone_right"; - - const char* Spine[5] = { "Bip01 Spine", "Bip01 Spine1", "Bip01 Spine2", "Bip01 Spine3", "Bip01 Spine4" }; - const char* Neck[2] = { "Bip01 Neck", "Bip01 Neck1" }; - - const char* LeftHeel = "Bip01 L Heel"; - const char* LeftToe[2] = { "Bip01 L Toe0", "Bip01 L Toe1" }; - - const char* RightHeel = "Bip01 R Heel"; - const char* RightToe[2] = { "Bip01 R Toe0", "Bip01 R Toe1" }; -} // namespace EditorAnimationBones::Biped diff --git a/Code/Editor/Animation/AnimationBipedBoneNames.h b/Code/Editor/Animation/AnimationBipedBoneNames.h deleted file mode 100644 index fdcfff7c82..0000000000 --- a/Code/Editor/Animation/AnimationBipedBoneNames.h +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef CRYINCLUDE_EDITOR_ANIMATION_ANIMATIONBIPEDBONENAMES_H -#define CRYINCLUDE_EDITOR_ANIMATION_ANIMATIONBIPEDBONENAMES_H -#pragma once - -namespace EditorAnimationBones -{ - namespace Biped - { - extern const char* Pelvis; - extern const char* Head; - extern const char* Weapon; - - extern const char* Spine[5]; - extern const char* Neck[2]; - - extern const char* LeftEye; - extern const char* RightEye; - - extern const char* LeftHeel; - extern const char* RightHeel; - extern const char* LeftToe[2]; - extern const char* RightToe[2]; - } -} - - -#endif // CRYINCLUDE_EDITOR_ANIMATION_ANIMATIONBIPEDBONENAMES_H diff --git a/Code/Editor/AzAssetBrowser/AzAssetBrowserWindow.cpp b/Code/Editor/AzAssetBrowser/AzAssetBrowserWindow.cpp index bcaaa02b67..a7faea36f6 100644 --- a/Code/Editor/AzAssetBrowser/AzAssetBrowserWindow.cpp +++ b/Code/Editor/AzAssetBrowser/AzAssetBrowserWindow.cpp @@ -17,6 +17,7 @@ #include #include #include +#include // AzQtComponents #include @@ -83,6 +84,9 @@ AzAssetBrowserWindow::AzAssetBrowserWindow(QWidget* parent) m_ui->m_assetBrowserTableViewWidget->setVisible(false); m_ui->m_toggleDisplayViewBtn->setVisible(false); m_ui->m_searchWidget->SetFilterInputInterval(AZStd::chrono::milliseconds(250)); + + m_assetBrowserModel->SetFilterModel(m_filterModel.data()); + if (ed_useNewAssetBrowserTableView) { m_ui->m_toggleDisplayViewBtn->setVisible(true); diff --git a/Code/Editor/BaseLibrary.cpp b/Code/Editor/BaseLibrary.cpp deleted file mode 100644 index 15742bd254..0000000000 --- a/Code/Editor/BaseLibrary.cpp +++ /dev/null @@ -1,232 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "BaseLibrary.h" -#include "BaseLibraryItem.h" -#include "Include/IBaseLibraryManager.h" -#include -#include - -////////////////////////////////////////////////////////////////////////// -// CBaseLibrary implementation. -////////////////////////////////////////////////////////////////////////// -CBaseLibrary::CBaseLibrary(IBaseLibraryManager* pManager) - : m_pManager(pManager) - , m_bModified(false) - , m_bLevelLib(false) - , m_bNewLibrary(true) -{ -} - -////////////////////////////////////////////////////////////////////////// -CBaseLibrary::~CBaseLibrary() -{ - m_items.clear(); -} - -////////////////////////////////////////////////////////////////////////// -IBaseLibraryManager* CBaseLibrary::GetManager() -{ - return m_pManager; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibrary::RemoveAllItems() -{ - AddRef(); - for (int i = 0; i < m_items.size(); i++) - { - // Unregister item in case it was registered. It is ok if it wasn't. This is still safe to call. - m_pManager->UnregisterItem(m_items[i]); - // Clear library item. - m_items[i]->m_library = nullptr; - } - m_items.clear(); - Release(); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibrary::SetName(const QString& name) -{ - //the fullname of the items in the library will be changed due to library's name change - //so we need unregistered them and register them after their name changed. - for (int i = 0; i < m_items.size(); i++) - { - m_pManager->UnregisterItem(m_items[i]); - } - - m_name = name; - - for (int i = 0; i < m_items.size(); i++) - { - m_pManager->RegisterItem(m_items[i]); - } - - SetModified(); -} - -////////////////////////////////////////////////////////////////////////// -const QString& CBaseLibrary::GetName() const -{ - return m_name; -} - -////////////////////////////////////////////////////////////////////////// -bool CBaseLibrary::Save() -{ - return true; -} - -////////////////////////////////////////////////////////////////////////// -bool CBaseLibrary::Load(const QString& filename) -{ - m_filename = filename; - SetModified(false); - m_bNewLibrary = false; - return true; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibrary::SetModified(bool bModified) -{ - if (bModified != m_bModified) - { - m_bModified = bModified; - emit Modified(bModified); - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibrary::AddItem(IDataBaseItem* item, bool bRegister) -{ - - CBaseLibraryItem* pLibItem = (CBaseLibraryItem*)item; - // Check if item is already assigned to this library. - if (pLibItem->m_library != this) - { - pLibItem->m_library = this; - m_items.push_back(pLibItem); - SetModified(); - if (bRegister) - { - m_pManager->RegisterItem(pLibItem); - } - } -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibrary::GetItem(int index) -{ - assert(index >= 0 && index < m_items.size()); - return m_items[index]; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibrary::RemoveItem(IDataBaseItem* item) -{ - - for (int i = 0; i < m_items.size(); i++) - { - if (m_items[i] == item) - { - // Unregister item in case it was registered. It is ok if it wasn't. This is still safe to call. - m_pManager->UnregisterItem(m_items[i]); - m_items.erase(m_items.begin() + i); - SetModified(); - break; - } - } -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibrary::FindItem(const QString& name) -{ - for (int i = 0; i < m_items.size(); i++) - { - if (QString::compare(m_items[i]->GetName(), name, Qt::CaseInsensitive) == 0) - { - return m_items[i]; - } - } - return nullptr; -} - -bool CBaseLibrary::AddLibraryToSourceControl(const QString& fullPathName) const -{ - IEditor* pEditor = GetIEditor(); - IFileUtil* pFileUtil = pEditor ? pEditor->GetFileUtil() : nullptr; - if (pFileUtil) - { - return pFileUtil->CheckoutFile(fullPathName.toUtf8().data(), nullptr); - } - - return false; -} - -bool CBaseLibrary::SaveLibrary(const char* name, bool saveEmptyLibrary) -{ - assert(name != nullptr); - if (name == nullptr) - { - CryFatalError("The library you are attempting to save has no name specified."); - return false; - } - - QString fileName(GetFilename()); - if (fileName.isEmpty() && !saveEmptyLibrary) - { - return false; - } - - fileName = Path::GamePathToFullPath(fileName); - - XmlNodeRef root = GetIEditor()->GetSystem()->CreateXmlNode(name); - Serialize(root, false); - bool bRes = XmlHelpers::SaveXmlNode(GetIEditor()->GetFileUtil(), root, fileName.toUtf8().data()); - if (m_bNewLibrary) - { - AddLibraryToSourceControl(fileName); - m_bNewLibrary = false; - } - if (!bRes) - { - QByteArray filenameUtf8 = fileName.toUtf8(); - AZStd::string strMessage = AZStd::string::format("The file %s is read-only and the save of the library couldn't be performed. Try to remove the \"read-only\" flag or check-out the file and then try again.", filenameUtf8.data()); - CryMessageBox(strMessage.c_str(), "Saving Error", MB_OK | MB_ICONWARNING); - } - return bRes; -} - -//CONFETTI BEGIN -void CBaseLibrary::ChangeItemOrder(CBaseLibraryItem* item, unsigned int newLocation) -{ - std::vector<_smart_ptr > temp; - for (unsigned int i = 0; i < m_items.size(); i++) - { - if (i == newLocation) - { - temp.push_back(_smart_ptr(item)); - } - if (m_items[i] != item) - { - temp.push_back(m_items[i]); - } - } - // If newLocation is greater than the original size, append the item to end of the list - if (newLocation >= m_items.size()) - { - temp.push_back(_smart_ptr(item)); - } - m_items = temp; -} -//CONFETTI END - -#include diff --git a/Code/Editor/BaseLibrary.h b/Code/Editor/BaseLibrary.h deleted file mode 100644 index 55079d3fde..0000000000 --- a/Code/Editor/BaseLibrary.h +++ /dev/null @@ -1,129 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_BASELIBRARY_H -#define CRYINCLUDE_EDITOR_BASELIBRARY_H -#pragma once - -#if !defined(Q_MOC_RUN) -#include "Include/IDataBaseLibrary.h" -#include "Include/IBaseLibraryManager.h" -#include "Include/EditorCoreAPI.h" -#include "Util/TRefCountBase.h" - -#include -#endif - -// Ensure we don't try to dllimport when moc includes us -#if defined(Q_MOC_BUILD) && !defined(EDITOR_CORE) -#define EDITOR_CORE -#endif - -/** This a base class for all Libraries used by Editor. -*/ -class EDITOR_CORE_API CBaseLibrary - : public QObject - , public TRefCountBase -{ - Q_OBJECT - -public: - explicit CBaseLibrary(IBaseLibraryManager* pManager); - ~CBaseLibrary(); - - //! Set library name. - virtual void SetName(const QString& name); - //! Get library name. - const QString& GetName() const override; - - //! Set new filename for this library. - virtual bool SetFilename(const QString& filename, [[maybe_unused]] bool checkForUnique = true) { m_filename = filename.toLower(); return true; }; - const QString& GetFilename() const override { return m_filename; }; - - bool Save() override = 0; - bool Load(const QString& filename) override = 0; - void Serialize(XmlNodeRef& node, bool bLoading) override = 0; - - //! Mark library as modified. - void SetModified(bool bModified = true) override; - //! Check if library was modified. - bool IsModified() const override { return m_bModified; }; - - ////////////////////////////////////////////////////////////////////////// - // Working with items. - ////////////////////////////////////////////////////////////////////////// - //! Add a new prototype to library. - void AddItem(IDataBaseItem* item, bool bRegister = true) override; - //! Get number of known prototypes. - int GetItemCount() const override { return static_cast(m_items.size()); } - //! Get prototype by index. - IDataBaseItem* GetItem(int index) override; - - //! Delete item by pointer of item. - void RemoveItem(IDataBaseItem* item) override; - - //! Delete all items from library. - void RemoveAllItems() override; - - //! Find library item by name. - //! Using linear search. - IDataBaseItem* FindItem(const QString& name) override; - - //! Check if this library is local level library. - bool IsLevelLibrary() const override { return m_bLevelLib; }; - - //! Set library to be level library. - void SetLevelLibrary(bool bEnable) override { m_bLevelLib = bEnable; }; - - ////////////////////////////////////////////////////////////////////////// - //! Return manager for this library. - IBaseLibraryManager* GetManager() override; - - // Saves the library with the main tag defined by the parameter name - bool SaveLibrary(const char* name, bool saveEmptyLibrary = false); - - //CONFETTI BEGIN - // Used to change the library item order - void ChangeItemOrder(CBaseLibraryItem* item, unsigned int newLocation) override; - //CONFETTI END - -signals: - void Modified(bool bModified); - -private: - // Add the library to the source control - bool AddLibraryToSourceControl(const QString& fullPathName) const; - -protected: - - //! Name of the library. - QString m_name; - //! Filename of the library. - QString m_filename; - - //! Flag set when library was modified. - bool m_bModified; - - // Flag set when the library is just created and it's not yet saved for the first time. - bool m_bNewLibrary; - - //! Level library is saved within the level .ly file and is local for this level. - bool m_bLevelLib; - - ////////////////////////////////////////////////////////////////////////// - // Manager. - IBaseLibraryManager* m_pManager; - - AZ_PUSH_DISABLE_DLL_EXPORT_MEMBER_WARNING - // Array of all our library items. - std::vector<_smart_ptr > m_items; - AZ_POP_DISABLE_DLL_EXPORT_MEMBER_WARNING -}; - -#endif // CRYINCLUDE_EDITOR_BASELIBRARY_H diff --git a/Code/Editor/BaseLibraryItem.cpp b/Code/Editor/BaseLibraryItem.cpp deleted file mode 100644 index e3788bc3e4..0000000000 --- a/Code/Editor/BaseLibraryItem.cpp +++ /dev/null @@ -1,261 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "BaseLibraryItem.h" -#include "BaseLibrary.h" -#include "BaseLibraryManager.h" -#include "Undo/IUndoObject.h" - -#include - -//undo object for multi-changes inside library item. such as set all variables to default values. -//For example: change particle emitter shape will lead to multiple variable changes -class CUndoBaseLibraryItem - : public IUndoObject -{ -public: - CUndoBaseLibraryItem(IBaseLibraryManager *libMgr, CBaseLibraryItem* libItem, bool ignoreChild) - : m_libMgr(libMgr) - { - assert(libItem); - assert(libMgr); - - m_itemPath = libItem->GetFullName(); - - //serialize the lib item to undo - m_undoCtx.node = GetIEditor()->GetSystem()->CreateXmlNode("Undo"); - m_undoCtx.bIgnoreChilds = ignoreChild; - m_undoCtx.bLoading = false; //saving - m_undoCtx.bUniqName = false; //don't generate new name - m_undoCtx.bCopyPaste = true; //so it won't override guid - m_undoCtx.bUndo = true; - libItem->Serialize(m_undoCtx); - - //evaluate size - XmlString xmlStr = m_undoCtx.node->getXML(); - m_size = sizeof(CUndoBaseLibraryItem); - m_size += static_cast(xmlStr.GetAllocatedMemory()); - m_size += m_itemPath.length(); - } - - -protected: - int GetSize() override - { - return m_size; - } - - void Undo(bool bUndo) override - { - //find the libItem - IDataBaseItem *libItem = m_libMgr->FindItemByName(m_itemPath); - if (libItem == nullptr) - { - //the undo stack is not reliable any more.. - assert(false); - return; - } - - //save for redo - if (bUndo) - { - m_redoCtx.node = GetIEditor()->GetSystem()->CreateXmlNode("Redo"); - m_redoCtx.bIgnoreChilds = m_undoCtx.bIgnoreChilds; - m_redoCtx.bLoading = false; //saving - m_redoCtx.bUniqName = false; - m_redoCtx.bCopyPaste = true; - m_redoCtx.bUndo = true; - libItem->Serialize(m_redoCtx); - - XmlString xmlStr = m_redoCtx.node->getXML(); - m_size += static_cast(xmlStr.GetAllocatedMemory()); - } - - //load previous saved data - m_undoCtx.bLoading = true; - libItem->Serialize(m_undoCtx); - } - - void Redo() override - { - //find the libItem - IDataBaseItem *libItem = m_libMgr->FindItemByName(m_itemPath); - if (libItem == nullptr || m_redoCtx.node == nullptr) - { - //the undo stack is not reliable any more.. - assert(false); - return; - } - - m_redoCtx.bLoading = true; - libItem->Serialize(m_redoCtx); - } - -private: - QString m_itemPath; - IDataBaseItem::SerializeContext m_undoCtx; //saved before operation - IDataBaseItem::SerializeContext m_redoCtx; //saved after operation so used for redo - IBaseLibraryManager* m_libMgr; - int m_size; -}; - -////////////////////////////////////////////////////////////////////////// -// CBaseLibraryItem implementation. -////////////////////////////////////////////////////////////////////////// -CBaseLibraryItem::CBaseLibraryItem() -{ - m_library = nullptr; - GenerateId(); - m_bModified = false; -} - -CBaseLibraryItem::~CBaseLibraryItem() -{ -} - -////////////////////////////////////////////////////////////////////////// -QString CBaseLibraryItem::GetFullName() const -{ - QString name; - if (m_library) - { - name = m_library->GetName() + "."; - } - name += m_name; - return name; -} - -////////////////////////////////////////////////////////////////////////// -QString CBaseLibraryItem::GetGroupName() -{ - QString str = GetName(); - int p = str.lastIndexOf('.'); - if (p >= 0) - { - return str.mid(0, p); - } - return ""; -} - -////////////////////////////////////////////////////////////////////////// -QString CBaseLibraryItem::GetShortName() -{ - QString str = GetName(); - int p = str.lastIndexOf('.'); - if (p >= 0) - { - return str.mid(p + 1); - } - p = str.lastIndexOf('/'); - if (p >= 0) - { - return str.mid(p + 1); - } - return str; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryItem::SetName(const QString& name) -{ - assert(m_library); - if (name == m_name) - { - return; - } - QString oldName = GetFullName(); - m_name = name; - ((CBaseLibraryManager*)m_library->GetManager())->OnRenameItem(this, oldName); -} - -////////////////////////////////////////////////////////////////////////// -const QString& CBaseLibraryItem::GetName() const -{ - return m_name; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryItem::GenerateId() -{ - GUID guid = AZ::Uuid::CreateRandom(); - SetGUID(guid); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryItem::SetGUID(REFGUID guid) -{ - if (m_library) - { - ((CBaseLibraryManager*)m_library->GetManager())->RegisterItem(this, guid); - } - m_guid = guid; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryItem::Serialize(SerializeContext& ctx) -{ - assert(m_library); - - XmlNodeRef node = ctx.node; - if (ctx.bLoading) - { - QString name = m_name; - // Loading - node->getAttr("Name", name); - - if (!ctx.bUniqName) - { - SetName(name); - } - else - { - SetName(GetLibrary()->GetManager()->MakeUniqueItemName(name)); - } - - if (!ctx.bCopyPaste) - { - GUID guid; - if (node->getAttr("Id", guid)) - { - SetGUID(guid); - } - } - } - else - { - // Saving. - node->setAttr("Name", m_name.toUtf8().data()); - node->setAttr("Id", m_guid); - node->setAttr("Library", GetLibrary()->GetName().toUtf8().data()); - } - m_bModified = false; -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseLibrary* CBaseLibraryItem::GetLibrary() const -{ - return m_library; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryItem::SetLibrary(CBaseLibrary* pLibrary) -{ - m_library = pLibrary; -} - -//! Mark library as modified. -void CBaseLibraryItem::SetModified(bool bModified) -{ - m_bModified = bModified; - if (m_bModified && m_library != nullptr) - { - m_library->SetModified(bModified); - } -} diff --git a/Code/Editor/BaseLibraryItem.h b/Code/Editor/BaseLibraryItem.h deleted file mode 100644 index 53cf0add2b..0000000000 --- a/Code/Editor/BaseLibraryItem.h +++ /dev/null @@ -1,114 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_BASELIBRARYITEM_H -#define CRYINCLUDE_EDITOR_BASELIBRARYITEM_H -#pragma once - -#include "Include/IDataBaseItem.h" -#include "BaseLibrary.h" - -#include - -class CBaseLibrary; - -////////////////////////////////////////////////////////////////////////// -AZ_PUSH_DISABLE_DLL_EXPORT_BASECLASS_WARNING -/** Base class for all items contained in BaseLibraray. -*/ -class EDITOR_CORE_API CBaseLibraryItem - : public TRefCountBase -{ - AZ_POP_DISABLE_DLL_EXPORT_BASECLASS_WARNING -public: - CBaseLibraryItem(); - ~CBaseLibraryItem(); - - //! Set item name. - //! Its virtual, in case you want to override it in derrived item. - virtual void SetName(const QString& name); - //! Get item name. - const QString& GetName() const; - - //! Get full item name, including name of library. - //! Name formed by adding dot after name of library - //! eg. library Pickup and item PickupRL form full item name: "Pickups.PickupRL". - QString GetFullName() const; - - //! Get only nameof group from prototype. - QString GetGroupName(); - //! Get short name of prototype without group. - QString GetShortName(); - - //! Return Library this item are contained in. - //! Item can only be at one library. - IDataBaseLibrary* GetLibrary() const; - void SetLibrary(CBaseLibrary* pLibrary); - - ////////////////////////////////////////////////////////////////////////// - //! Serialize library item to archive. - virtual void Serialize(SerializeContext& ctx); - - ////////////////////////////////////////////////////////////////////////// - //! Generate new unique id for this item. - void GenerateId(); - //! Returns GUID of this material. - const GUID& GetGUID() const { return m_guid; } - - //! Mark library as modified. - void SetModified(bool bModified = true); - //! Check if library was modified. - bool IsModified() const { return m_bModified; }; - - //! Returns true if the item is registered, otherwise false - bool IsRegistered() const { return m_bRegistered; }; - - //! Validate item for errors. - virtual void Validate() {}; - - //! Get number of sub childs. - virtual int GetChildCount() const { return 0; } - //! Get sub child by index. - virtual CBaseLibraryItem* GetChild([[maybe_unused]] int index) const { return nullptr; } - - - ////////////////////////////////////////////////////////////////////////// - //! Gathers resources by this item. - virtual void GatherUsedResources([[maybe_unused]] CUsedResources& resources) {}; - - //! Get if stored item is enabled - virtual bool GetIsEnabled() { return true; }; - - - int IsParticleItem = -1; -protected: - void SetGUID(REFGUID guid); - friend class CBaseLibrary; - friend class CBaseLibraryManager; - // Name of this prototype. - QString m_name; - AZ_PUSH_DISABLE_DLL_EXPORT_MEMBER_WARNING - //! Reference to prototype library who contains this prototype. - _smart_ptr m_library; - AZ_POP_DISABLE_DLL_EXPORT_MEMBER_WARNING - - //! Every base library item have unique id. - GUID m_guid; - // True when item modified by editor. - bool m_bModified; - // True when item registered in manager. - bool m_bRegistered = false; -}; - -Q_DECLARE_METATYPE(CBaseLibraryItem*); - -TYPEDEF_AUTOPTR(CBaseLibraryItem); - - -#endif // CRYINCLUDE_EDITOR_BASELIBRARYITEM_H diff --git a/Code/Editor/BaseLibraryManager.cpp b/Code/Editor/BaseLibraryManager.cpp deleted file mode 100644 index 0e51a5238c..0000000000 --- a/Code/Editor/BaseLibraryManager.cpp +++ /dev/null @@ -1,822 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - - -#include "EditorDefs.h" - -#include "BaseLibraryManager.h" - -// Editor -#include "BaseLibraryItem.h" -#include "ErrorReport.h" -#include "Undo/IUndoObject.h" - -////////////////////////////////////////////////////////////////////////// -// CBaseLibraryManager implementation. -////////////////////////////////////////////////////////////////////////// -CBaseLibraryManager::CBaseLibraryManager() -{ - m_bUniqNameMap = false; - m_bUniqGuidMap = true; - GetIEditor()->RegisterNotifyListener(this); -} - -////////////////////////////////////////////////////////////////////////// -CBaseLibraryManager::~CBaseLibraryManager() -{ - ClearAll(); - GetIEditor()->UnregisterNotifyListener(this); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::ClearAll() -{ - // Delete all items from all libraries. - for (int i = 0; i < m_libs.size(); i++) - { - m_libs[i]->RemoveAllItems(); - } - - // if we will not copy maps locally then destructors of the elements of - // the map will operate on the already invalid map object - // see: - // CBaseLibraryManager::UnregisterItem() - // CBaseLibraryManager::DeleteItem() - // CMaterial::~CMaterial() - - ItemsGUIDMap itemsGuidMap; - ItemsNameMap itemsNameMap; - - { - AZStd::lock_guard lock(m_itemsNameMapMutex); - std::swap(itemsGuidMap, m_itemsGuidMap); - std::swap(itemsNameMap, m_itemsNameMap); - - m_libs.clear(); - } -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseLibrary* CBaseLibraryManager::FindLibrary(const QString& library) -{ - const int index = FindLibraryIndex(library); - return index == -1 ? nullptr : m_libs[index]; -} - -////////////////////////////////////////////////////////////////////////// -int CBaseLibraryManager::FindLibraryIndex(const QString& library) -{ - QString lib = library; - lib.replace('\\', '/'); - for (int i = 0; i < m_libs.size(); i++) - { - QString _lib = m_libs[i]->GetFilename(); - _lib.replace('\\', '/'); - if (QString::compare(lib, m_libs[i]->GetName(), Qt::CaseInsensitive) == 0 || QString::compare(lib, _lib, Qt::CaseInsensitive) == 0) - { - return i; - } - } - return -1; -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibraryManager::FindItem(REFGUID guid) const -{ - CBaseLibraryItem* pMtl = stl::find_in_map(m_itemsGuidMap, guid, nullptr); - return pMtl; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::SplitFullItemName(const QString& fullItemName, QString& libraryName, QString& itemName) -{ - int p; - p = fullItemName.indexOf('.'); - if (p < 0 || !QString::compare(fullItemName.mid(p + 1), "mtl", Qt::CaseInsensitive)) - { - libraryName = ""; - itemName = fullItemName; - return; - } - libraryName = fullItemName.mid(0, p); - itemName = fullItemName.mid(p + 1); -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibraryManager::FindItemByName(const QString& fullItemName) -{ - AZStd::lock_guard lock(m_itemsNameMapMutex); - return stl::find_in_map(m_itemsNameMap, fullItemName, nullptr); -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibraryManager::LoadItemByName(const QString& fullItemName) -{ - QString libraryName, itemName; - SplitFullItemName(fullItemName, libraryName, itemName); - - if (!FindLibrary(libraryName)) - { - LoadLibrary(MakeFilename(libraryName)); - } - - return FindItemByName(fullItemName); -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibraryManager::FindItemByName(const char* fullItemName) -{ - return FindItemByName(QString(fullItemName)); -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibraryManager::LoadItemByName(const char* fullItemName) -{ - return LoadItemByName(QString(fullItemName)); -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibraryManager::CreateItem(IDataBaseLibrary* pLibrary) -{ - assert(pLibrary); - - // Add item to this library. - TSmartPtr pItem = MakeNewItem(); - pLibrary->AddItem(pItem); - return pItem; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::DeleteItem(IDataBaseItem* pItem) -{ - assert(pItem); - - UnregisterItem((CBaseLibraryItem*)pItem); - if (pItem->GetLibrary()) - { - pItem->GetLibrary()->RemoveItem(pItem); - } -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseLibrary* CBaseLibraryManager::LoadLibrary(const QString& inFilename, [[maybe_unused]] bool bReload) -{ - if (auto lib = FindLibrary(inFilename)) - { - return lib; - } - - TSmartPtr pLib = MakeNewLibrary(); - if (!pLib->Load(MakeFilename(inFilename))) - { - Error(QObject::tr("Failed to Load Item Library: %1").arg(inFilename).toUtf8().data()); - return nullptr; - } - - m_libs.push_back(pLib); - return pLib; -} - -////////////////////////////////////////////////////////////////////////// -int CBaseLibraryManager::GetModifiedLibraryCount() const -{ - int count = 0; - for (int i = 0; i < m_libs.size(); i++) - { - if (m_libs[i]->IsModified()) - { - count++; - } - } - return count; -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseLibrary* CBaseLibraryManager::AddLibrary(const QString& library, bool bIsLevelLibrary, bool bIsLoading) -{ - // Make a filename from name of library. - QString filename = library; - - if (filename.indexOf(".xml") == -1) // if its already a filename, we don't do anything - { - filename.replace(' ', '_'); - if (!bIsLevelLibrary) - { - filename = MakeFilename(library); - } - else - { - // if its the level library it gets saved in the level and should not be concatenated with any other file name - filename = filename + ".xml"; - } - } - - IDataBaseLibrary* pBaseLib = FindLibrary(library); //library name - if (!pBaseLib) - { - pBaseLib = FindLibrary(filename); //library file name - } - if (pBaseLib) - { - return pBaseLib; - } - - CBaseLibrary* lib = MakeNewLibrary(); - lib->SetName(library); - lib->SetLevelLibrary(bIsLevelLibrary); - lib->SetFilename(filename, !bIsLoading); - // set modified to true, so even empty particle libraries get saved - lib->SetModified(true); - - m_libs.push_back(lib); - return lib; -} - -////////////////////////////////////////////////////////////////////////// -QString CBaseLibraryManager::MakeFilename(const QString& library) -{ - QString filename = library; - filename.replace(' ', '_'); - filename.replace(".xml", ""); - - // make it contain the canonical libs path: - Path::ConvertBackSlashToSlash(filename); - - QString LibsPath(GetLibsPath()); - Path::ConvertBackSlashToSlash(LibsPath); - - if (filename.left(LibsPath.length()).compare(LibsPath, Qt::CaseInsensitive) == 0) - { - filename = filename.mid(LibsPath.length()); - } - - return LibsPath + filename + ".xml"; -} - -////////////////////////////////////////////////////////////////////////// -bool CBaseLibraryManager::IsUniqueFilename(const QString& library) -{ - QString resultPath = MakeFilename(library); - CCryFile xmlFile; - // If we can find a file for the path - return !xmlFile.Open(resultPath.toUtf8().data(), "rb"); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::DeleteLibrary(const QString& library, bool forceDeleteLevel) -{ - for (int i = 0; i < m_libs.size(); i++) - { - if (QString::compare(library, m_libs[i]->GetName(), Qt::CaseInsensitive) == 0) - { - CBaseLibrary* pLibrary = m_libs[i]; - // Check if not level library, they cannot be deleted. - if (!pLibrary->IsLevelLibrary() || forceDeleteLevel) - { - for (int j = 0; j < pLibrary->GetItemCount(); j++) - { - UnregisterItem((CBaseLibraryItem*)pLibrary->GetItem(j)); - } - pLibrary->RemoveAllItems(); - - if (pLibrary->IsLevelLibrary()) - { - m_pLevelLibrary = nullptr; - } - m_libs.erase(m_libs.begin() + i); - } - break; - } - } -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseLibrary* CBaseLibraryManager::GetLibrary(int index) const -{ - assert(index >= 0 && index < m_libs.size()); - return m_libs[index]; -}; - -////////////////////////////////////////////////////////////////////////// -IDataBaseLibrary* CBaseLibraryManager::GetLevelLibrary() const -{ - IDataBaseLibrary* pLevelLib = nullptr; - - for (int i = 0; i < GetLibraryCount(); i++) - { - if (GetLibrary(i)->IsLevelLibrary()) - { - pLevelLib = GetLibrary(i); - break; - } - } - - - return pLevelLib; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::SaveAllLibs() -{ - for (int i = 0; i < GetLibraryCount(); i++) - { - // Check if library is modified. - IDataBaseLibrary* pLibrary = GetLibrary(i); - - //Level library is saved when the level is saved - if (pLibrary->IsLevelLibrary()) - { - continue; - } - if (pLibrary->IsModified()) - { - if (pLibrary->Save()) - { - pLibrary->SetModified(false); - } - } - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::Serialize(XmlNodeRef& node, bool bLoading) -{ - static const char* const LEVEL_LIBRARY_TAG = "LevelLibrary"; - - QString rootNodeName = GetRootNodeName(); - if (bLoading) - { - XmlNodeRef libs = node->findChild(rootNodeName.toUtf8().data()); - if (libs) - { - for (int i = 0; i < libs->getChildCount(); i++) - { - // Load only library name. - XmlNodeRef libNode = libs->getChild(i); - if (strcmp(libNode->getTag(), LEVEL_LIBRARY_TAG) == 0) - { - if (!m_pLevelLibrary) - { - QString libName; - libNode->getAttr("Name", libName); - m_pLevelLibrary = static_cast(AddLibrary(libName, true)); - } - m_pLevelLibrary->Serialize(libNode, bLoading); - } - else - { - QString libName; - if (libNode->getAttr("Name", libName)) - { - // Load this library. - if (!FindLibrary(libName)) - { - LoadLibrary(MakeFilename(libName)); - } - } - } - } - } - } - else - { - // Save all libraries. - XmlNodeRef libs = node->newChild(rootNodeName.toUtf8().data()); - for (int i = 0; i < GetLibraryCount(); i++) - { - IDataBaseLibrary* pLib = GetLibrary(i); - if (pLib->IsLevelLibrary()) - { - // Level libraries are saved in in level. - XmlNodeRef libNode = libs->newChild(LEVEL_LIBRARY_TAG); - pLib->Serialize(libNode, bLoading); - } - else - { - // Save only library name. - XmlNodeRef libNode = libs->newChild("Library"); - libNode->setAttr("Name", pLib->GetName().toUtf8().data()); - } - } - SaveAllLibs(); - } -} - -////////////////////////////////////////////////////////////////////////// -QString CBaseLibraryManager::MakeUniqueItemName(const QString& srcName, const QString& libName) -{ - // unlikely we'll ever encounter more than 16 - std::vector possibleDuplicates; - possibleDuplicates.reserve(16); - - // search for strings in the database that might have a similar name (ignore case) - IDataBaseItemEnumerator* pEnum = GetItemEnumerator(); - for (IDataBaseItem* pItem = pEnum->GetFirst(); pItem != nullptr; pItem = pEnum->GetNext()) - { - //Check if the item is in the target library first. - IDataBaseLibrary* itemLibrary = pItem->GetLibrary(); - QString itemLibraryName; - if (itemLibrary) - { - itemLibraryName = itemLibrary->GetName(); - } - - // Item is not in the library so there cannot be a naming conflict. - if (!libName.isEmpty() && !itemLibraryName.isEmpty() && itemLibraryName != libName) - { - continue; - } - - const QString& name = pItem->GetName(); - if (name.startsWith(srcName, Qt::CaseInsensitive)) - { - possibleDuplicates.push_back(AZStd::string(name.toUtf8().data())); - } - } - pEnum->Release(); - - if (possibleDuplicates.empty()) - { - return srcName; - } - - std::sort(possibleDuplicates.begin(), possibleDuplicates.end(), [](const AZStd::string& strOne, const AZStd::string& strTwo) - { - // I can assume size sorting since if the length is different, either one of the two strings doesn't - // closely match the string we are trying to duplicate, or it's a bigger number (X1 vs X10) - if (strOne.size() != strTwo.size()) - { - return strOne.size() < strTwo.size(); - } - else - { - return azstricmp(strOne.c_str(), strTwo.c_str()) < 0; - } - } - ); - - int num = 0; - QString returnValue = srcName; - while (num < possibleDuplicates.size() && QString::compare(possibleDuplicates[num].c_str(), returnValue, Qt::CaseInsensitive) == 0) - { - returnValue = QStringLiteral("%1%2%3").arg(srcName).arg("_").arg(num); - ++num; - } - - return returnValue; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::Validate() -{ - IDataBaseItemEnumerator* pEnum = GetItemEnumerator(); - for (IDataBaseItem* pItem = pEnum->GetFirst(); pItem != nullptr; pItem = pEnum->GetNext()) - { - pItem->Validate(); - } - pEnum->Release(); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::RegisterItem(CBaseLibraryItem* pItem, REFGUID newGuid) -{ - assert(pItem); - - bool bNotify = false; - - if (m_bUniqGuidMap) - { - REFGUID oldGuid = pItem->GetGUID(); - if (!GuidUtil::IsEmpty(oldGuid)) - { - m_itemsGuidMap.erase(oldGuid); - } - if (GuidUtil::IsEmpty(newGuid)) - { - return; - } - CBaseLibraryItem* pOldItem = stl::find_in_map(m_itemsGuidMap, newGuid, nullptr); - if (!pOldItem) - { - pItem->m_guid = newGuid; - m_itemsGuidMap[newGuid] = pItem; - pItem->m_bRegistered = true; - bNotify = true; - } - else - { - if (pOldItem != pItem) - { - ReportDuplicateItem(pItem, pOldItem); - } - } - } - - if (m_bUniqNameMap) - { - QString fullName = pItem->GetFullName(); - if (!pItem->GetName().isEmpty()) - { - CBaseLibraryItem* pOldItem = static_cast(FindItemByName(fullName)); - if (!pOldItem) - { - AZStd::lock_guard lock(m_itemsNameMapMutex); - m_itemsNameMap[fullName] = pItem; - pItem->m_bRegistered = true; - bNotify = true; - } - else - { - if (pOldItem != pItem) - { - ReportDuplicateItem(pItem, pOldItem); - } - } - } - } - - // Notify listeners. - if (bNotify) - { - NotifyItemEvent(pItem, EDB_ITEM_EVENT_ADD); - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::RegisterItem(CBaseLibraryItem* pItem) -{ - assert(pItem); - - bool bNotify = false; - - if (m_bUniqGuidMap) - { - if (GuidUtil::IsEmpty(pItem->GetGUID())) - { - return; - } - CBaseLibraryItem* pOldItem = stl::find_in_map(m_itemsGuidMap, pItem->GetGUID(), nullptr); - if (!pOldItem) - { - m_itemsGuidMap[pItem->GetGUID()] = pItem; - pItem->m_bRegistered = true; - bNotify = true; - } - else - { - if (pOldItem != pItem) - { - ReportDuplicateItem(pItem, pOldItem); - } - } - } - - if (m_bUniqNameMap) - { - QString fullName = pItem->GetFullName(); - if (!fullName.isEmpty()) - { - CBaseLibraryItem* pOldItem = static_cast(FindItemByName(fullName)); - if (!pOldItem) - { - AZStd::lock_guard lock(m_itemsNameMapMutex); - m_itemsNameMap[fullName] = pItem; - pItem->m_bRegistered = true; - bNotify = true; - } - else - { - if (pOldItem != pItem) - { - ReportDuplicateItem(pItem, pOldItem); - } - } - } - } - - // Notify listeners. - if (bNotify) - { - NotifyItemEvent(pItem, EDB_ITEM_EVENT_ADD); - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::SetRegisteredFlag(CBaseLibraryItem* pItem, bool bFlag) -{ - pItem->m_bRegistered = bFlag; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::ReportDuplicateItem(CBaseLibraryItem* pItem, CBaseLibraryItem* pOldItem) -{ - QString sLibName; - if (pOldItem->GetLibrary()) - { - sLibName = pOldItem->GetLibrary()->GetName(); - } - CErrorRecord err; - err.pItem = pItem; - err.error = QStringLiteral("Item %1 with duplicate GUID to loaded item %2 ignored").arg(pItem->GetFullName(), pOldItem->GetFullName()); - GetIEditor()->GetErrorReport()->ReportError(err); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::UnregisterItem(CBaseLibraryItem* pItem) -{ - // Notify listeners. - NotifyItemEvent(pItem, EDB_ITEM_EVENT_DELETE); - - if (!pItem) - { - return; - } - - if (m_bUniqGuidMap) - { - m_itemsGuidMap.erase(pItem->GetGUID()); - } - if (m_bUniqNameMap && !pItem->GetFullName().isEmpty()) - { - AZStd::lock_guard lock(m_itemsNameMapMutex); - auto findIter = m_itemsNameMap.find(pItem->GetFullName()); - if (findIter != m_itemsNameMap.end()) - { - _smart_ptr item = findIter->second; - m_itemsNameMap.erase(findIter); - } - } - - pItem->m_bRegistered = false; -} - -////////////////////////////////////////////////////////////////////////// -QString CBaseLibraryManager::MakeFullItemName(IDataBaseLibrary* pLibrary, const QString& group, const QString& itemName) -{ - assert(pLibrary); - QString name = pLibrary->GetName() + "."; - if (!group.isEmpty()) - { - name += group + "."; - } - name += itemName; - return name; -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::GatherUsedResources(CUsedResources& resources) -{ - IDataBaseItemEnumerator* pEnum = GetItemEnumerator(); - for (IDataBaseItem* pItem = pEnum->GetFirst(); pItem != nullptr; pItem = pEnum->GetNext()) - { - pItem->GatherUsedResources(resources); - } - pEnum->Release(); -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItemEnumerator* CBaseLibraryManager::GetItemEnumerator() -{ - if (m_bUniqNameMap) - { - return new CDataBaseItemEnumerator(&m_itemsNameMap); - } - else - { - return new CDataBaseItemEnumerator(&m_itemsGuidMap); - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::OnEditorNotifyEvent(EEditorNotifyEvent event) -{ - switch (event) - { - case eNotify_OnBeginNewScene: - SetSelectedItem(nullptr); - ClearAll(); - break; - case eNotify_OnBeginSceneOpen: - SetSelectedItem(nullptr); - ClearAll(); - break; - case eNotify_OnCloseScene: - SetSelectedItem(nullptr); - ClearAll(); - break; - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::OnRenameItem(CBaseLibraryItem* pItem, const QString& oldName) -{ - m_itemsNameMapMutex.lock(); - if (!oldName.isEmpty()) - { - m_itemsNameMap.erase(oldName); - } - if (!pItem->GetFullName().isEmpty()) - { - m_itemsNameMap[pItem->GetFullName()] = pItem; - } - m_itemsNameMapMutex.unlock(); - - OnItemChanged(pItem); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::AddListener(IDataBaseManagerListener* pListener) -{ - stl::push_back_unique(m_listeners, pListener); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::RemoveListener(IDataBaseManagerListener* pListener) -{ - stl::find_and_erase(m_listeners, pListener); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::NotifyItemEvent(IDataBaseItem* pItem, EDataBaseItemEvent event) -{ - // Notify listeners. - if (!m_listeners.empty()) - { - for (int i = 0; i < m_listeners.size(); i++) - { - m_listeners[i]->OnDataBaseItemEvent(pItem, event); - } - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::OnItemChanged(IDataBaseItem* pItem) -{ - NotifyItemEvent(pItem, EDB_ITEM_EVENT_CHANGED); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::OnUpdateProperties(IDataBaseItem* pItem, bool bRefresh) -{ - NotifyItemEvent(pItem, bRefresh ? EDB_ITEM_EVENT_UPDATE_PROPERTIES - : EDB_ITEM_EVENT_UPDATE_PROPERTIES_NO_EDITOR_REFRESH); -} - -////////////////////////////////////////////////////////////////////////// -void CBaseLibraryManager::SetSelectedItem(IDataBaseItem* pItem) -{ - if (m_pSelectedItem == pItem) - { - return; - } - m_pSelectedItem = (CBaseLibraryItem*)pItem; - NotifyItemEvent(m_pSelectedItem, EDB_ITEM_EVENT_SELECTED); -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibraryManager::GetSelectedItem() const -{ - return m_pSelectedItem; -} - -////////////////////////////////////////////////////////////////////////// -IDataBaseItem* CBaseLibraryManager::GetSelectedParentItem() const -{ - return m_pSelectedParent; -} - -void CBaseLibraryManager::ChangeLibraryOrder(IDataBaseLibrary* lib, unsigned int newLocation) -{ - if (!lib || newLocation >= m_libs.size() || lib == m_libs[newLocation]) - { - return; - } - - for (int i = 0; i < m_libs.size(); i++) - { - if (lib == m_libs[i]) - { - _smart_ptr curLib = m_libs[i]; - m_libs.erase(m_libs.begin() + i); - m_libs.insert(m_libs.begin() + newLocation, curLib); - return; - } - } -} - -bool CBaseLibraryManager::SetLibraryName(CBaseLibrary* lib, const QString& name) -{ - // SetFilename will validate if the name is duplicate with exist libraries. - if (lib->SetFilename(MakeFilename(name))) - { - lib->SetName(name); - return true; - } - return false; -} diff --git a/Code/Editor/BaseLibraryManager.h b/Code/Editor/BaseLibraryManager.h deleted file mode 100644 index 118c7ef1f0..0000000000 --- a/Code/Editor/BaseLibraryManager.h +++ /dev/null @@ -1,226 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - - -#ifndef CRYINCLUDE_EDITOR_BASELIBRARYMANAGER_H -#define CRYINCLUDE_EDITOR_BASELIBRARYMANAGER_H -#pragma once - -#include "Include/IBaseLibraryManager.h" -#include "Include/IDataBaseItem.h" -#include "Include/IDataBaseLibrary.h" -#include "Include/IDataBaseManager.h" -#include "Util/TRefCountBase.h" -#include "Util/GuidUtil.h" -#include "BaseLibrary.h" -#include "Util/smartptr.h" -#include -#include - -AZ_PUSH_DISABLE_DLL_EXPORT_BASECLASS_WARNING -/** Manages all Libraries and Items. -*/ -class SANDBOX_API CBaseLibraryManager - : public IBaseLibraryManager -{ -AZ_POP_DISABLE_DLL_EXPORT_BASECLASS_WARNING -public: - CBaseLibraryManager(); - ~CBaseLibraryManager(); - - //! Clear all libraries. - void ClearAll() override; - - ////////////////////////////////////////////////////////////////////////// - // IDocListener implementation. - ////////////////////////////////////////////////////////////////////////// - void OnEditorNotifyEvent(EEditorNotifyEvent event) override; - - ////////////////////////////////////////////////////////////////////////// - // Library items. - ////////////////////////////////////////////////////////////////////////// - //! Make a new item in specified library. - IDataBaseItem* CreateItem(IDataBaseLibrary* pLibrary) override; - //! Delete item from library and manager. - void DeleteItem(IDataBaseItem* pItem) override; - - //! Find Item by its GUID. - IDataBaseItem* FindItem(REFGUID guid) const override; - IDataBaseItem* FindItemByName(const QString& fullItemName) override; - IDataBaseItem* LoadItemByName(const QString& fullItemName) override; - virtual IDataBaseItem* FindItemByName(const char* fullItemName); - virtual IDataBaseItem* LoadItemByName(const char* fullItemName); - - IDataBaseItemEnumerator* GetItemEnumerator() override; - - ////////////////////////////////////////////////////////////////////////// - // Set item currently selected. - void SetSelectedItem(IDataBaseItem* pItem) override; - // Get currently selected item. - IDataBaseItem* GetSelectedItem() const override; - IDataBaseItem* GetSelectedParentItem() const override; - - ////////////////////////////////////////////////////////////////////////// - // Libraries. - ////////////////////////////////////////////////////////////////////////// - //! Add Item library. - IDataBaseLibrary* AddLibrary(const QString& library, bool bIsLevelLibrary = false, bool bIsLoading = true) override; - void DeleteLibrary(const QString& library, bool forceDeleteLevel = false) override; - //! Get number of libraries. - int GetLibraryCount() const override { return static_cast(m_libs.size()); }; - //! Get number of modified libraries. - int GetModifiedLibraryCount() const override; - - //! Get Item library by index. - IDataBaseLibrary* GetLibrary(int index) const override; - - //! Get Level Item library. - IDataBaseLibrary* GetLevelLibrary() const override; - - //! Find Items Library by name. - IDataBaseLibrary* FindLibrary(const QString& library) override; - - //! Find Items Library's index by name. - int FindLibraryIndex(const QString& library) override; - - //! Load Items library. - IDataBaseLibrary* LoadLibrary(const QString& filename, bool bReload = false) override; - - //! Save all modified libraries. - void SaveAllLibs() override; - - //! Serialize property manager. - void Serialize(XmlNodeRef& node, bool bLoading) override; - - //! Export items to game. - void Export([[maybe_unused]] XmlNodeRef& node) override {}; - - //! Returns unique name base on input name. - QString MakeUniqueItemName(const QString& name, const QString& libName = "") override; - QString MakeFullItemName(IDataBaseLibrary* pLibrary, const QString& group, const QString& itemName) override; - - //! Root node where this library will be saved. - QString GetRootNodeName() override = 0; - //! Path to libraries in this manager. - QString GetLibsPath() override = 0; - - ////////////////////////////////////////////////////////////////////////// - //! Validate library items for errors. - void Validate() override; - - ////////////////////////////////////////////////////////////////////////// - void GatherUsedResources(CUsedResources& resources) override; - - void AddListener(IDataBaseManagerListener* pListener) override; - void RemoveListener(IDataBaseManagerListener* pListener) override; - - ////////////////////////////////////////////////////////////////////////// - void RegisterItem(CBaseLibraryItem* pItem, REFGUID newGuid) override; - void RegisterItem(CBaseLibraryItem* pItem) override; - void UnregisterItem(CBaseLibraryItem* pItem) override; - - // Only Used internally. - void OnRenameItem(CBaseLibraryItem* pItem, const QString& oldName) override; - - // Called by items to indicated that they have been modified. - // Sends item changed event to listeners. - void OnItemChanged(IDataBaseItem* pItem) override; - void OnUpdateProperties(IDataBaseItem* pItem, bool bRefresh) override; - - QString MakeFilename(const QString& library); - bool IsUniqueFilename(const QString& library) override; - - //CONFETTI BEGIN - // Used to change the library item order - void ChangeLibraryOrder(IDataBaseLibrary* lib, unsigned int newLocation) override; - - bool SetLibraryName(CBaseLibrary* lib, const QString& name) override; - -protected: - void SplitFullItemName(const QString& fullItemName, QString& libraryName, QString& itemName); - void NotifyItemEvent(IDataBaseItem* pItem, EDataBaseItemEvent event); - void SetRegisteredFlag(CBaseLibraryItem* pItem, bool bFlag); - - ////////////////////////////////////////////////////////////////////////// - // Must be overriden. - //! Makes a new Item. - virtual CBaseLibraryItem* MakeNewItem() = 0; - virtual CBaseLibrary* MakeNewLibrary() = 0; - ////////////////////////////////////////////////////////////////////////// - - virtual void ReportDuplicateItem(CBaseLibraryItem* pItem, CBaseLibraryItem* pOldItem); - -protected: - bool m_bUniqGuidMap; - bool m_bUniqNameMap; - - AZ_PUSH_DISABLE_DLL_EXPORT_MEMBER_WARNING - //! Array of all loaded entity items libraries. - std::vector<_smart_ptr > m_libs; - - // There is always one current level library. - TSmartPtr m_pLevelLibrary; - - // GUID to item map. - typedef std::map, guid_less_predicate> ItemsGUIDMap; - ItemsGUIDMap m_itemsGuidMap; - - // Case insensitive name to items map. - typedef std::map, stl::less_stricmp> ItemsNameMap; - ItemsNameMap m_itemsNameMap; - AZStd::mutex m_itemsNameMapMutex; - - std::vector m_listeners; - - // Currently selected item. - _smart_ptr m_pSelectedItem; - _smart_ptr m_pSelectedParent; - AZ_POP_DISABLE_DLL_EXPORT_MEMBER_WARNING -}; - -////////////////////////////////////////////////////////////////////////// -template -class CDataBaseItemEnumerator - : public IDataBaseItemEnumerator -{ - TMap* m_pMap; - typename TMap::iterator m_iterator; - -public: - CDataBaseItemEnumerator(TMap* pMap) - { - assert(pMap); - m_pMap = pMap; - m_iterator = m_pMap->begin(); - } - void Release() override { delete this; }; - IDataBaseItem* GetFirst() override - { - m_iterator = m_pMap->begin(); - if (m_iterator == m_pMap->end()) - { - return 0; - } - return m_iterator->second; - } - IDataBaseItem* GetNext() override - { - if (m_iterator != m_pMap->end()) - { - m_iterator++; - } - if (m_iterator == m_pMap->end()) - { - return 0; - } - return m_iterator->second; - } -}; - -#endif // CRYINCLUDE_EDITOR_BASELIBRARYMANAGER_H diff --git a/Code/Editor/CMakeLists.txt b/Code/Editor/CMakeLists.txt index 3358b49dce..9d74f8e3a2 100644 --- a/Code/Editor/CMakeLists.txt +++ b/Code/Editor/CMakeLists.txt @@ -63,7 +63,7 @@ ly_add_target( set(pal_cmake_files "") foreach(enabled_platform ${LY_PAL_TOOLS_ENABLED}) string(TOLOWER ${enabled_platform} enabled_platform_lowercase) - ly_get_list_relative_pal_filename(pal_cmake_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${enabled_platform}) + o3de_pal_dir(pal_cmake_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${enabled_platform} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) list(APPEND pal_cmake_files ${pal_cmake_dir}/editor_lib_${enabled_platform_lowercase}_files.cmake) endforeach() diff --git a/Code/Editor/Common/spline_edit-00.png b/Code/Editor/Common/spline_edit-00.png deleted file mode 100644 index 0243becc2b..0000000000 --- a/Code/Editor/Common/spline_edit-00.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:58ef978b31b31df9aaf715a0e9b006fde414a17a3ff15a3bf680eaad7418867a -size 364 diff --git a/Code/Editor/Common/spline_edit-01.png b/Code/Editor/Common/spline_edit-01.png deleted file mode 100644 index 4789ee0820..0000000000 --- a/Code/Editor/Common/spline_edit-01.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:98a681ec3d89ee57c5d1057fe984dcf8ad45721f47ae4df57fa358fbee85e616 -size 385 diff --git a/Code/Editor/Common/spline_edit-02.png b/Code/Editor/Common/spline_edit-02.png deleted file mode 100644 index 476883a514..0000000000 --- a/Code/Editor/Common/spline_edit-02.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:24a2b2c9242a841c20e7815dab0d80a575844055328aea413d28b7283b65a92e -size 386 diff --git a/Code/Editor/Common/spline_edit-03.png b/Code/Editor/Common/spline_edit-03.png deleted file mode 100644 index c1e79719a5..0000000000 --- a/Code/Editor/Common/spline_edit-03.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:ce23a276fec849b8f832fab96d3b738793335c27d37ae3813158387f3415b508 -size 377 diff --git a/Code/Editor/Common/spline_edit-04.png b/Code/Editor/Common/spline_edit-04.png deleted file mode 100644 index e9cfb9d79e..0000000000 --- a/Code/Editor/Common/spline_edit-04.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:c03befab41765200f4f28dbf1e0b2a702d2244bfa79b0d463f5d58d0a26095fc -size 386 diff --git a/Code/Editor/Common/spline_edit-05.png b/Code/Editor/Common/spline_edit-05.png deleted file mode 100644 index 3046c6008d..0000000000 --- a/Code/Editor/Common/spline_edit-05.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:418c3f0f27854b3795841359014d87686a7bf94daf2568d9cfd3ffac22675f69 -size 386 diff --git a/Code/Editor/Common/spline_edit-06.png b/Code/Editor/Common/spline_edit-06.png deleted file mode 100644 index 3c170baa3e..0000000000 --- a/Code/Editor/Common/spline_edit-06.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:d3a831f34ac53c9b1f20037290e8a2b62a3cfb8a4f86467591f44fd2a0e3c15b -size 379 diff --git a/Code/Editor/Common/spline_edit-07.png b/Code/Editor/Common/spline_edit-07.png deleted file mode 100644 index 1c87d462ed..0000000000 --- a/Code/Editor/Common/spline_edit-07.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:4267102ca7a889c34eff905480a68878d4d56e15bc723a5b0575cd472e259f5d -size 389 diff --git a/Code/Editor/Common/spline_edit-08.png b/Code/Editor/Common/spline_edit-08.png deleted file mode 100644 index 52c436f877..0000000000 --- a/Code/Editor/Common/spline_edit-08.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a0df013dd102b87348fba18b4da5443591309e9c40166d27ae928636924154ea -size 388 diff --git a/Code/Editor/Common/spline_edit-09.png b/Code/Editor/Common/spline_edit-09.png deleted file mode 100644 index 1223730915..0000000000 --- a/Code/Editor/Common/spline_edit-09.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:e713076ab5abbbb2cf28da431a339e9905acc790e35295f025aa2e79e1c04141 -size 376 diff --git a/Code/Editor/Common/spline_edit-10.png b/Code/Editor/Common/spline_edit-10.png deleted file mode 100644 index 3b2a27bdbf..0000000000 --- a/Code/Editor/Common/spline_edit-10.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:9e5af9d62ceafc3b8a1dfc36772350cd623fcc86c68711b299e143ff133f79b6 -size 387 diff --git a/Code/Editor/Common/spline_edit-11.png b/Code/Editor/Common/spline_edit-11.png deleted file mode 100644 index 7b68ead52b..0000000000 --- a/Code/Editor/Common/spline_edit-11.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:17c5fb3d7b87ea87a98934954c721573c641bc44005a34f1e16589d7f39b71e8 -size 409 diff --git a/Code/Editor/Common/spline_edit-12.png b/Code/Editor/Common/spline_edit-12.png deleted file mode 100644 index 3c7abb2182..0000000000 --- a/Code/Editor/Common/spline_edit-12.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:6f5c78d9f764b62fb7dcf400c91c1edea9d7f88a426ba513fbf70825c6bcd2ac -size 383 diff --git a/Code/Editor/Common/spline_edit-13.png b/Code/Editor/Common/spline_edit-13.png deleted file mode 100644 index f71a5ec300..0000000000 --- a/Code/Editor/Common/spline_edit-13.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:376b549602afffca407525b77c1a9821bf6a0e279792ae2e52fe0a4f7c3c5bd4 -size 364 diff --git a/Code/Editor/Common/spline_edit-14.png b/Code/Editor/Common/spline_edit-14.png deleted file mode 100644 index 4a5f89b089..0000000000 --- a/Code/Editor/Common/spline_edit-14.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:e7dc48f8d324b7563b168f27ebde1e00ee2bd11ba462f114a05b297913e285c5 -size 374 diff --git a/Code/Editor/Common/spline_edit-15.png b/Code/Editor/Common/spline_edit-15.png deleted file mode 100644 index 8542318682..0000000000 --- a/Code/Editor/Common/spline_edit-15.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:66b73afbd6dba1caaedfaae161b277b460b5198f7fc00bec414530116c567276 -size 375 diff --git a/Code/Editor/Common/spline_edit-16.png b/Code/Editor/Common/spline_edit-16.png deleted file mode 100644 index 6926024cbd..0000000000 --- a/Code/Editor/Common/spline_edit-16.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:ae6e6714acf495246f4e59f6e5640f3a4417ea50100d37a116950d2b859aed0c -size 417 diff --git a/Code/Editor/Controls/ConsoleSCBMFC.h b/Code/Editor/Controls/ConsoleSCBMFC.h deleted file mode 100644 index fcf7f71df7..0000000000 --- a/Code/Editor/Controls/ConsoleSCBMFC.h +++ /dev/null @@ -1,111 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_CONTROLS_CONSOLESCBMFC_H -#define CRYINCLUDE_EDITOR_CONTROLS_CONSOLESCBMFC_H -#pragma once - -#if !defined(Q_MOC_RUN) -#include -#include -#include - -#include "ConsoleSCB.h" -#endif - -class QMenu; -class ConsoleWidget; -class QFocusEvent; - -namespace Ui { - class ConsoleMFC; -} - -namespace MFC -{ - -struct ConsoleLine -{ - QString text; - bool newLine; -}; -typedef std::deque Lines; - -class ConsoleLineEdit - : public QLineEdit -{ - Q_OBJECT -public: - explicit ConsoleLineEdit(QWidget* parent = nullptr); - -protected: - void mousePressEvent(QMouseEvent* ev) override; - void mouseDoubleClickEvent(QMouseEvent* ev) override; - void keyPressEvent(QKeyEvent* ev) override; - bool event(QEvent* ev) override; - -signals: - void variableEditorRequested(); - void setWindowTitle(const QString&); - -private: - void DisplayHistory(bool bForward); - QStringList m_history; - unsigned int m_historyIndex; - bool m_bReusedHistory; -}; - -class ConsoleTextEdit - : public QTextEdit -{ - Q_OBJECT -public: - explicit ConsoleTextEdit(QWidget* parent = nullptr); -}; - -class CConsoleSCB - : public QWidget -{ - Q_OBJECT -public: - explicit CConsoleSCB(QWidget* parent = nullptr); - ~CConsoleSCB(); - - static void RegisterViewClass(); - void SetInputFocus(); - void AddToConsole(const QString& text, bool bNewLine); - void FlushText(); - void showPopupAndSetTitle(); - QSize sizeHint() const override; - QSize minimumSizeHint() const override; - static CConsoleSCB* GetCreatedInstance(); - - static void AddToPendingLines(const QString& text, bool bNewLine); // call this function instead of AddToConsole() until an instance of CConsoleSCB exists to prevent messages from getting lost - -public Q_SLOTS: - void OnStyleSettingsChanged(); - -private Q_SLOTS: - void showVariableEditor(); - -private: - QScopedPointer ui; - int m_richEditTextLength; - - Lines m_lines; - static Lines s_pendingLines; - - QList m_colorTable; - SEditorSettings::ConsoleColorTheme m_backgroundTheme; -}; - -} // namespace MFC - -#endif // CRYINCLUDE_EDITOR_CONTROLS_CONSOLESCB_H - diff --git a/Code/Editor/Controls/ConsoleSCBMFC.ui b/Code/Editor/Controls/ConsoleSCBMFC.ui deleted file mode 100644 index b9386558ed..0000000000 --- a/Code/Editor/Controls/ConsoleSCBMFC.ui +++ /dev/null @@ -1,132 +0,0 @@ - - - ConsoleMFC - - - - 0 - 0 - 400 - 120 - - - - - 0 - 0 - - - - Console - - - - 0 - - - 0 - - - - - - 0 - 0 - - - - - - - - - - - - 0 - 0 - - - - - 0 - 20 - - - - - 16777215 - 20 - - - - true - - - - - - - 0 - - - 0 - - - - - - 0 - 0 - - - - - 20 - 0 - - - - - 20 - 30 - - - - - 0 - 0 - - - - - - - - - - - - 0 - 0 - - - - - - - - - - - - MFC::ConsoleLineEdit - QLineEdit -
ConsoleSCBMFC.h
-
-
- - - - -
diff --git a/Code/Editor/Controls/HotTrackingTreeCtrl.cpp b/Code/Editor/Controls/HotTrackingTreeCtrl.cpp deleted file mode 100644 index 54152a9fd4..0000000000 --- a/Code/Editor/Controls/HotTrackingTreeCtrl.cpp +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "HotTrackingTreeCtrl.h" - -// Qt -#include - - -CHotTrackingTreeCtrl::CHotTrackingTreeCtrl(QWidget* parent) - : QTreeWidget(parent) -{ - setMouseTracking(true); - m_hHoverItem = nullptr; -} - -void CHotTrackingTreeCtrl::mouseMoveEvent(QMouseEvent* event) -{ - QTreeWidgetItem* hItem = itemAt(event->pos()); - - if (m_hHoverItem != nullptr) - { - QFont font = m_hHoverItem->font(0); - font.setBold(false); - m_hHoverItem->setFont(0, font); - m_hHoverItem = nullptr; - } - - if (hItem != nullptr) - { - QFont font = hItem->font(0); - font.setBold(true); - hItem->setFont(0, font); - m_hHoverItem = hItem; - } - - QTreeWidget::mouseMoveEvent(event); -} - -#include diff --git a/Code/Editor/Controls/HotTrackingTreeCtrl.h b/Code/Editor/Controls/HotTrackingTreeCtrl.h deleted file mode 100644 index 2ca7e11a91..0000000000 --- a/Code/Editor/Controls/HotTrackingTreeCtrl.h +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_CONTROLS_HOTTRACKINGTREECTRL_H -#define CRYINCLUDE_EDITOR_CONTROLS_HOTTRACKINGTREECTRL_H -#pragma once - -#if !defined(Q_MOC_RUN) -#include -#endif - -class CHotTrackingTreeCtrl - : public QTreeWidget -{ - Q_OBJECT - -public: - CHotTrackingTreeCtrl(QWidget* parent = 0); - virtual ~CHotTrackingTreeCtrl(){}; - -protected: - void mouseMoveEvent(QMouseEvent* event) override; - -private: - QTreeWidgetItem* m_hHoverItem; -}; -#endif // CRYINCLUDE_EDITOR_CONTROLS_HOTTRACKINGTREECTRL_H diff --git a/Code/Editor/Controls/ImageListCtrl.cpp b/Code/Editor/Controls/ImageListCtrl.cpp deleted file mode 100644 index 9c8451c2e9..0000000000 --- a/Code/Editor/Controls/ImageListCtrl.cpp +++ /dev/null @@ -1,567 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "ImageListCtrl.h" - -// Qt -#include -#include - -////////////////////////////////////////////////////////////////////////// -CImageListCtrl::CImageListCtrl(QWidget* parent) - : QAbstractItemView(parent) - , m_itemSize(60, 60) - , m_borderSize(4, 4) - , m_style(DefaultStyle) -{ - setItemDelegate(new QImageListDelegate(this)); - setAutoFillBackground(false); - - QPalette p = palette(); - p.setColor(QPalette::Highlight, QColor(255, 55, 50)); - setPalette(p); - - horizontalScrollBar()->setRange(0, 0); - verticalScrollBar()->setRange(0, 0); -} - -////////////////////////////////////////////////////////////////////////// -CImageListCtrl::~CImageListCtrl() -{ -} - -////////////////////////////////////////////////////////////////////////// -CImageListCtrl::ListStyle CImageListCtrl::Style() const -{ - return m_style; -} - -////////////////////////////////////////////////////////////////////////// -void CImageListCtrl::SetStyle(ListStyle style) -{ - m_style = style; - scheduleDelayedItemsLayout(); -} - -////////////////////////////////////////////////////////////////////////// -const QSize& CImageListCtrl::ItemSize() const -{ - return m_itemSize; -} - -////////////////////////////////////////////////////////////////////////// -void CImageListCtrl::SetItemSize(QSize size) -{ - Q_ASSERT(size.isValid()); - m_itemSize = size; - scheduleDelayedItemsLayout(); -} - -////////////////////////////////////////////////////////////////////////// -const QSize& CImageListCtrl::BorderSize() const -{ - return m_borderSize; -} - -////////////////////////////////////////////////////////////////////////// -void CImageListCtrl::SetBorderSize(QSize size) -{ - Q_ASSERT(size.isValid()); - m_borderSize = size; - scheduleDelayedItemsLayout(); -} - -////////////////////////////////////////////////////////////////////////// -QModelIndexList CImageListCtrl::ItemsInRect(const QRect& rect) const -{ - QModelIndexList list; - - if (!model()) - { - return list; - } - - QHash::const_iterator i; - QHash::const_iterator c = m_geometry.cend(); - for (i = m_geometry.cbegin(); i != c; ++i) - { - if (i.value().intersects(rect)) - { - list << model()->index(i.key(), 0, rootIndex()); - } - } - - return list; -} - -////////////////////////////////////////////////////////////////////////// -void CImageListCtrl::paintEvent(QPaintEvent* event) -{ - QAbstractItemView::paintEvent(event); - - if (!model()) - { - return; - } - - const int rowCount = model()->rowCount(); - - if (m_geometry.isEmpty() && rowCount) - { - updateGeometries(); - } - - QPainter painter(viewport()); - painter.setRenderHints(QPainter::Antialiasing | QPainter::TextAntialiasing); - painter.setBackground(palette().window()); - painter.setFont(font()); - - QStyleOptionViewItem option; - option.palette = palette(); - option.font = font(); - option.fontMetrics = fontMetrics(); - option.decorationAlignment = Qt::AlignCenter; - - const QRect visibleRect(QPoint(horizontalOffset(), verticalOffset()), viewport()->contentsRect().size()); - - painter.translate(-horizontalOffset(), -verticalOffset()); - - for (int r = 0; r < rowCount; ++r) - { - const QModelIndex& index = model()->index(r, 0, rootIndex()); - - option.rect = m_geometry.value(r); - if (!option.rect.intersects(visibleRect)) - { - continue; - } - - option.state = QStyle::State_None; - - if (selectionModel()->isSelected(index)) - { - option.state |= QStyle::State_Selected; - } - - if (currentIndex() == index) - { - option.state |= QStyle::State_HasFocus; - } - - QAbstractItemDelegate* idt = itemDelegate(index); - idt->paint(&painter, option, index); - } -} - -////////////////////////////////////////////////////////////////////////// -void CImageListCtrl::rowsInserted(const QModelIndex& parent, int start, int end) -{ - QAbstractItemView::rowsInserted(parent, start, end); - - if (isVisible()) - { - scheduleDelayedItemsLayout(); - } -} - -////////////////////////////////////////////////////////////////////////// -void CImageListCtrl::updateGeometries() -{ - ClearItemGeometries(); - - if (!model()) - { - return; - } - - const int rowCount = model()->rowCount(); - - const int nPageHorz = viewport()->width(); - const int nPageVert = viewport()->height(); - - if (nPageHorz == 0 || nPageVert == 0 || rowCount <= 0) - { - return; - } - - int x = m_borderSize.width(); - int y = m_borderSize.height(); - - const int nItemWidth = m_itemSize.width() + m_borderSize.width(); - - if (m_style == HorizontalStyle) - { - for (int row = 0; row < rowCount; ++row) - { - m_geometry.insert(row, QRect(QPoint(x, y), m_itemSize)); - x += nItemWidth; - } - - horizontalScrollBar()->setPageStep(viewport()->width()); - horizontalScrollBar()->setRange(0, x - viewport()->width()); - } - else - { - const int nTextHeight = fontMetrics().height(); - const int nItemHeight = m_itemSize.height() + m_borderSize.height() + nTextHeight; - - int nNumOfHorzItems = nPageHorz / nItemWidth; - if (nNumOfHorzItems <= 0) - { - nNumOfHorzItems = 1; - } - - for (int row = 0; row < rowCount; ++row) - { - m_geometry.insert(row, QRect(QPoint(x, y), m_itemSize)); - - if ((row + 1) % nNumOfHorzItems == 0) - { - y += nItemHeight; - x = m_borderSize.width(); - } - else - { - x += nItemWidth; - } - } - - verticalScrollBar()->setPageStep(viewport()->height()); - verticalScrollBar()->setRange(0, (y + nItemHeight) - viewport()->height()); - } -} - -////////////////////////////////////////////////////////////////////////// -QModelIndex CImageListCtrl::indexAt(const QPoint& point) const -{ - if (!model()) - { - return QModelIndex(); - } - - const QPoint p = point + - QPoint(horizontalOffset(), verticalOffset()); - - QHash::const_iterator i; - QHash::const_iterator c = m_geometry.cend(); - for (i = m_geometry.cbegin(); i != c; ++i) - { - if (i.value().contains(p)) - { - return model()->index(i.key(), 0, rootIndex()); - } - } - - return QModelIndex(); -} - -////////////////////////////////////////////////////////////////////////// -void CImageListCtrl::scrollTo(const QModelIndex& index, ScrollHint hint) -{ - if (!index.isValid()) - { - return; - } - - QRect rect = m_geometry.value(index.row()); - - switch (hint) - { - case EnsureVisible: - if (horizontalOffset() > rect.right()) - { - horizontalScrollBar()->setValue(rect.left()); - } - else if ((horizontalOffset() + viewport()->width()) < rect.left()) - { - horizontalScrollBar()->setValue(rect.right() - viewport()->width()); - } - - if (verticalOffset() > rect.bottom()) - { - verticalScrollBar()->setValue(rect.top()); - } - else if ((verticalOffset() + viewport()->height()) < rect.top()) - { - verticalScrollBar()->setValue(rect.bottom() - viewport()->height()); - } - break; - - case PositionAtTop: - horizontalScrollBar()->setValue(rect.left()); - verticalScrollBar()->setValue(rect.top()); - break; - - case PositionAtBottom: - horizontalScrollBar()->setValue(rect.right() - viewport()->width()); - verticalScrollBar()->setValue(rect.bottom() - viewport()->height()); - break; - - case PositionAtCenter: - horizontalScrollBar()->setValue(rect.center().x() - (viewport()->width() / 2)); - verticalScrollBar()->setValue(rect.center().y() - (viewport()->height() / 2)); - break; - } -} - -////////////////////////////////////////////////////////////////////////// -QRect CImageListCtrl::visualRect(const QModelIndex& index) const -{ - if (!index.isValid()) - { - return QRect(); - } - - - if (!m_geometry.contains(index.row())) - { - return QRect(); - } - - return m_geometry.value(index.row()) - .translated(-horizontalOffset(), -verticalOffset()); -} - -////////////////////////////////////////////////////////////////////////// -QRect CImageListCtrl::ItemGeometry(const QModelIndex& index) const -{ - Q_ASSERT(index.model() == model()); - Q_ASSERT(m_geometry.contains(index.row())); - - return m_geometry.value(index.row()); -} - -void CImageListCtrl::SetItemGeometry(const QModelIndex& index, const QRect& rect) -{ - Q_ASSERT(index.model() == model()); - m_geometry.insert(index.row(), rect); - update(rect); -} - -void CImageListCtrl::ClearItemGeometries() -{ - m_geometry.clear(); -} - -////////////////////////////////////////////////////////////////////////// -int CImageListCtrl::horizontalOffset() const -{ - return horizontalScrollBar()->value(); -} - -////////////////////////////////////////////////////////////////////////// -int CImageListCtrl::verticalOffset() const -{ - return verticalScrollBar()->value(); -} - -////////////////////////////////////////////////////////////////////////// -bool CImageListCtrl::isIndexHidden([[maybe_unused]] const QModelIndex& index) const -{ - return false; /* not supported */ -} - -////////////////////////////////////////////////////////////////////////// -QModelIndex CImageListCtrl::moveCursor(CursorAction cursorAction, [[maybe_unused]] Qt::KeyboardModifiers modifiers) -{ - if (!model()) - { - return QModelIndex(); - } - - const int rowCount = model()->rowCount(); - - if (0 == rowCount) - { - return QModelIndex(); - } - - switch (cursorAction) - { - case MoveHome: - return model()->index(0, 0, rootIndex()); - - case MoveEnd: - return model()->index(rowCount - 1, 0, rootIndex()); - - case MovePrevious: - { - QModelIndex current = currentIndex(); - if (current.isValid()) - { - return model()->index((current.row() - 1) % rowCount, 0, rootIndex()); - } - } break; - - case MoveNext: - { - QModelIndex current = currentIndex(); - if (current.isValid()) - { - return model()->index((current.row() + 1) % rowCount, 0, rootIndex()); - } - } break; - - case MoveUp: - case MoveDown: - case MoveLeft: - case MoveRight: - case MovePageUp: - case MovePageDown: - /* TODO */ - break; - } - return QModelIndex(); -} - -////////////////////////////////////////////////////////////////////////// -void CImageListCtrl::setSelection(const QRect& rect, QItemSelectionModel::SelectionFlags flags) -{ - if (!model()) - { - return; - } - - const QRect lrect = - rect.translated(horizontalOffset(), verticalOffset()); - - QHash::const_iterator i; - QHash::const_iterator c = m_geometry.cend(); - for (i = m_geometry.cbegin(); i != c; ++i) - { - if (i.value().intersects(lrect)) - { - selectionModel()->select(model()->index(i.key(), 0, rootIndex()), flags); - } - } -} - -////////////////////////////////////////////////////////////////////////// -QRegion CImageListCtrl::visualRegionForSelection(const QItemSelection& selection) const -{ - QRegion region; - - foreach(const QModelIndex &index, selection.indexes()) - { - region += visualRect(index); - } - - return region; -} - -////////////////////////////////////////////////////////////////////////// -QImageListDelegate::QImageListDelegate(QObject* parent) - : QAbstractItemDelegate(parent) -{ -} - -////////////////////////////////////////////////////////////////////////// -void QImageListDelegate::paint(QPainter* painter, - const QStyleOptionViewItem& option, const QModelIndex& index) const -{ - painter->save(); - - painter->setFont(option.font); - - if (option.rect.isValid()) - { - painter->setClipRect(option.rect); - } - - QRect innerRect = option.rect.adjusted(1, 1, -1, -1); - - QRect textRect(innerRect.left(), innerRect.bottom() - option.fontMetrics.height(), - innerRect.width(), option.fontMetrics.height() + 1); - - /* fill item background */ - - painter->fillRect(option.rect, option.palette.color(QPalette::Base)); - - /* draw image */ - - if (index.data(Qt::DecorationRole).isValid()) - { - const QPixmap& p = index.data(Qt::DecorationRole).value(); - if (p.isNull() || p.size() == QSize(1, 1)) - { - emit InvalidPixmapGenerated(index); - } - else - { - painter->drawPixmap(innerRect, p); - } - } - - /* draw text */ - - const QColor trColor = option.palette.color(QPalette::Shadow); - painter->fillRect(textRect, (option.state & QStyle::State_Selected) ? - trColor.lighter() : trColor); - - if (option.state & QStyle::State_Selected) - { - painter->setPen(QPen(option.palette.color(QPalette::HighlightedText))); - - QFont f = painter->font(); - f.setBold(true); - painter->setFont(f); - } - else - { - painter->setPen(QPen(option.palette.color(QPalette::Text))); - } - - painter->drawText(textRect, index.data(Qt::DisplayRole).toString(), - QTextOption(option.decorationAlignment)); - - painter->setPen(QPen(option.palette.color(QPalette::Shadow))); - painter->drawRect(textRect); - - /* draw border */ - - if (option.state & QStyle::State_Selected) - { - QPen pen(option.palette.color(QPalette::Highlight)); - pen.setWidth(2); - painter->setPen(pen); - painter->drawRect(innerRect); - } - else - { - painter->setPen(QPen(option.palette.color(QPalette::Shadow))); - painter->drawRect(option.rect); - } - - if (option.state & QStyle::State_HasFocus) - { - QPen pen(Qt::DotLine); - pen.setColor(option.palette.color(QPalette::AlternateBase)); - painter->setPen(pen); - painter->drawRect(option.rect); - } - - painter->restore(); -} - -////////////////////////////////////////////////////////////////////////// -QSize QImageListDelegate::sizeHint(const QStyleOptionViewItem& option, - [[maybe_unused]] const QModelIndex& index) const -{ - return option.rect.size(); -} - -////////////////////////////////////////////////////////////////////////// -QVector QImageListDelegate::paintingRoles() const -{ - return QVector() << Qt::DecorationRole << Qt::DisplayRole; -} - -#include diff --git a/Code/Editor/Controls/ImageListCtrl.h b/Code/Editor/Controls/ImageListCtrl.h deleted file mode 100644 index db393c8497..0000000000 --- a/Code/Editor/Controls/ImageListCtrl.h +++ /dev/null @@ -1,97 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_CONTROLS_IMAGELISTCTRL_H -#define CRYINCLUDE_EDITOR_CONTROLS_IMAGELISTCTRL_H -#pragma once - -#if !defined(Q_MOC_RUN) -#include - -#include -#endif - -////////////////////////////////////////////////////////////////////////// -// Custom control to display list of images. -////////////////////////////////////////////////////////////////////////// -class CImageListCtrl - : public QAbstractItemView -{ - Q_OBJECT -public: - enum ListStyle - { - DefaultStyle, - HorizontalStyle - }; - -public: - CImageListCtrl(QWidget* parent = nullptr); - ~CImageListCtrl(); - - ListStyle Style() const; - void SetStyle(ListStyle style); - - const QSize& ItemSize() const; - void SetItemSize(QSize size); - - const QSize& BorderSize() const; - void SetBorderSize(QSize size); - - // Get all items inside specified rectangle. - QModelIndexList ItemsInRect(const QRect& rect) const; - - QModelIndex indexAt(const QPoint& point) const override; - void scrollTo(const QModelIndex& index, ScrollHint hint = EnsureVisible) override; - QRect visualRect(const QModelIndex& index) const override; - -protected: - QRect ItemGeometry(const QModelIndex& index) const; - void SetItemGeometry(const QModelIndex& index, const QRect& rect); - void ClearItemGeometries(); - - int horizontalOffset() const override; - int verticalOffset() const override; - bool isIndexHidden(const QModelIndex& index) const override; - QModelIndex moveCursor(CursorAction cursorAction, Qt::KeyboardModifiers modifiers) override; - void setSelection(const QRect& rect, QItemSelectionModel::SelectionFlags flags) override; - QRegion visualRegionForSelection(const QItemSelection& selection) const override; - - void paintEvent(QPaintEvent* event) override; - void rowsInserted(const QModelIndex& parent, int start, int end) override; - - void updateGeometries() override; - -private: - QHash m_geometry; - QSize m_itemSize; - QSize m_borderSize; - ListStyle m_style; -}; - -class QImageListDelegate - : public QAbstractItemDelegate -{ - Q_OBJECT -signals: - void InvalidPixmapGenerated(const QModelIndex& index) const; -public: - QImageListDelegate(QObject* parent = nullptr); - - void paint(QPainter* painter, - const QStyleOptionViewItem& option, - const QModelIndex& index) const override; - - QSize sizeHint(const QStyleOptionViewItem& option, - const QModelIndex& index) const override; - - QVector paintingRoles() const override; -}; - -#endif // CRYINCLUDE_EDITOR_CONTROLS_IMAGELISTCTRL_H diff --git a/Code/Editor/Controls/MultiMonHelper.cpp b/Code/Editor/Controls/MultiMonHelper.cpp deleted file mode 100644 index 5b3ed3a204..0000000000 --- a/Code/Editor/Controls/MultiMonHelper.cpp +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "MultiMonHelper.h" - -// Qt -#include - -//////////////////////////////////////////////////////////////////////////// -void ClipOrCenterRectToMonitor(QRect *prc, const UINT flags) -{ - const QScreen* currentScreen = nullptr; - QRect rc; - - Q_ASSERT(prc); - - const auto screens = qApp->screens(); - for (auto screen : screens) - { - if (screen->geometry().contains(prc->center())) - { - currentScreen = screen; - break; - } - } - - if (!currentScreen) - { - return; - } - - const int w = prc->width(); - const int h = prc->height(); - - if (flags & MONITOR_WORKAREA) - { - rc = currentScreen->availableGeometry(); - } - else - { - rc = currentScreen->geometry(); - } - - // center or clip the passed rect to the monitor rect - if (flags & MONITOR_CENTER) - { - prc->setLeft(rc.left() + (rc.right() - rc.left() - w) / 2); - prc->setTop(rc.top() + (rc.bottom() - rc.top() - h) / 2); - prc->setRight(prc->left() + w); - prc->setBottom(prc->top() + h); - } - else - { - prc->setLeft(qMax(rc.left(), qMin(rc.right() - w, prc->left()))); - prc->setTop(qMax(rc.top(), qMin(rc.bottom() - h, prc->top()))); - prc->setRight(prc->left() + w); - prc->setBottom(prc->top() + h); - } -} diff --git a/Code/Editor/Controls/MultiMonHelper.h b/Code/Editor/Controls/MultiMonHelper.h deleted file mode 100644 index 54e47bf022..0000000000 --- a/Code/Editor/Controls/MultiMonHelper.h +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_CONTROLS_MULTIMONHELPER_H -#define CRYINCLUDE_EDITOR_CONTROLS_MULTIMONHELPER_H -#pragma once - -// Taken from: http://msdn.microsoft.com/en-us/library/dd162826(v=vs.85).aspx -#define MONITOR_CENTER 0x0001 // center rect to monitor -#define MONITOR_CLIP 0x0000 // clip rect to monitor -#define MONITOR_WORKAREA 0x0002 // use monitor work area -#define MONITOR_AREA 0x0000 // use monitor entire area - -// -// ClipOrCenterRectToMonitor -// -// The most common problem apps have when running on a -// multimonitor system is that they "clip" or "pin" windows -// based on the SM_CXSCREEN and SM_CYSCREEN system metrics. -// Because of app compatibility reasons these system metrics -// return the size of the primary monitor. -// -// This shows how you use the multi-monitor functions -// to do the same thing. -// -// params: -// prc : pointer to QRect to modify -// flags : some combination of the MONITOR_* flags above -// -// example: -// -// ClipOrCenterRectToMonitor(&aRect, MONITOR_CLIP | MONITOR_WORKAREA); -// -// Takes parameter pointer to RECT "aRect" and flags MONITOR_CLIP | MONITOR_WORKAREA -// This will modify aRect without resizing it so that it remains within the on-screen boundaries. -void ClipOrCenterRectToMonitor(QRect *prc, const UINT flags); - -#endif // CRYINCLUDE_EDITOR_CONTROLS_MULTIMONHELPER_H diff --git a/Code/Editor/Controls/NumberCtrl.cpp b/Code/Editor/Controls/NumberCtrl.cpp deleted file mode 100644 index 473dd7e4af..0000000000 --- a/Code/Editor/Controls/NumberCtrl.cpp +++ /dev/null @@ -1,143 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "NumberCtrl.h" - - -QNumberCtrl::QNumberCtrl(QWidget* parent) - : QDoubleSpinBox(parent) - , m_bMouseDown(false) - , m_bDragged(false) - , m_bUndoEnabled(false) - , m_prevValue(0) -{ - connect(this, &QAbstractSpinBox::editingFinished, this, &QNumberCtrl::onEditingFinished); -} - -void QNumberCtrl::changeEvent(QEvent* event) -{ - if (event->type() == QEvent::EnabledChange) - { - setButtonSymbols(isEnabled() ? UpDownArrows : NoButtons); - } - - QDoubleSpinBox::changeEvent(event); -} - - -void QNumberCtrl::SetRange(double newMin, double newMax) -{ - // Avoid setting this value if its close to the current value, because otherwise qt will pump events into the queue to redraw/etc. - if ( (!AZ::IsClose(this->minimum(), newMin, DBL_EPSILON)) || (!AZ::IsClose(this->maximum(), newMax, DBL_EPSILON)) ) - { - setRange(newMin, newMax); - } -} - - -void QNumberCtrl::mousePressEvent(QMouseEvent* event) -{ - if (event->button() == Qt::LeftButton) - { - emit mousePressed(); - - m_bMouseDown = true; - m_bDragged = false; - m_mousePos = event->pos(); - - if (m_bUndoEnabled && !CUndo::IsRecording()) - { - GetIEditor()->BeginUndo(); - } - - emit dragStarted(); - - grabMouse(); - } - - QDoubleSpinBox::mousePressEvent(event); -} - -void QNumberCtrl::mouseReleaseEvent(QMouseEvent* event) -{ - QDoubleSpinBox::mouseReleaseEvent(event); - - if (event->button() == Qt::LeftButton) - { - m_bMouseDown = m_bDragged = false; - - emit valueUpdated(); - emit valueChanged(); - - if (m_bUndoEnabled && CUndo::IsRecording()) - { - GetIEditor()->AcceptUndo(m_undoText); - } - - emit dragFinished(); - - releaseMouse(); - - m_prevValue = value(); - - emit mouseReleased(); - } -} - -void QNumberCtrl::mouseMoveEvent(QMouseEvent* event) -{ - QDoubleSpinBox::mousePressEvent(event); - - if (m_bMouseDown) - { - m_bDragged = true; - - int dy = event->pos().y() - m_mousePos.y(); - setValue(value() - singleStep() * dy); - - emit valueUpdated(); - - m_mousePos = event->pos(); - } -} - -void QNumberCtrl::EnableUndo(const QString& undoText) -{ - m_undoText = undoText; - m_bUndoEnabled = true; -} - -void QNumberCtrl::focusInEvent(QFocusEvent* event) -{ - m_prevValue = value(); - QDoubleSpinBox::focusInEvent(event); -} - -void QNumberCtrl::onEditingFinished() -{ - bool undo = m_bUndoEnabled && !CUndo::IsRecording() && m_prevValue != value(); - if (undo) - { - GetIEditor()->BeginUndo(); - } - - emit valueUpdated(); - emit valueChanged(); - - if (undo) - { - GetIEditor()->AcceptUndo(m_undoText); - } - - m_prevValue = value(); -} - -#include diff --git a/Code/Editor/Controls/NumberCtrl.h b/Code/Editor/Controls/NumberCtrl.h deleted file mode 100644 index 22ee7b867f..0000000000 --- a/Code/Editor/Controls/NumberCtrl.h +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_CONTROLS_NUMBERCTRL_H -#define CRYINCLUDE_EDITOR_CONTROLS_NUMBERCTRL_H -#pragma once - -// NumberCtrl.h : header file -// - -#if !defined(Q_MOC_RUN) -#include -#endif - -class QNumberCtrl - : public QDoubleSpinBox -{ - Q_OBJECT - -public: - QNumberCtrl(QWidget* parent = nullptr); - - bool IsDragging() const { return m_bDragged; } - - //! If called will enable undo with given text when control is modified. - void EnableUndo(const QString& undoText); - void SetRange(double newMin, double maxRange); - -Q_SIGNALS: - void dragStarted(); - void dragFinished(); - - void valueUpdated(); - void valueChanged(); - - void mouseReleased(); - void mousePressed(); - -protected: - void changeEvent(QEvent* event) override; - void focusInEvent(QFocusEvent* event) override; - void mousePressEvent(QMouseEvent* event) override; - void mouseMoveEvent(QMouseEvent* event) override; - void mouseReleaseEvent(QMouseEvent* event) override; - -private: - void onEditingFinished(); - void onValueChanged(double d); - - bool m_bMouseDown; - bool m_bDragged; - QPoint m_mousePos; - bool m_bUndoEnabled; - double m_prevValue; - QString m_undoText; -}; - -#endif // CRYINCLUDE_EDITOR_CONTROLS_NUMBERCTRL_H diff --git a/Code/Editor/Controls/TextEditorCtrl.cpp b/Code/Editor/Controls/TextEditorCtrl.cpp deleted file mode 100644 index c372138d80..0000000000 --- a/Code/Editor/Controls/TextEditorCtrl.cpp +++ /dev/null @@ -1,93 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "TextEditorCtrl.h" - - -// CTextEditorCtrl -CTextEditorCtrl::CTextEditorCtrl(QWidget* pParent) - : QTextEdit(pParent) -{ - m_bModified = true; - - QFont font; - font.setFamily("Courier New"); - font.setFixedPitch(true); - font.setPointSize(10); - setFont(font); - - setLineWrapMode(NoWrap); - - connect(this, &QTextEdit::textChanged, this, &CTextEditorCtrl::OnChange); -} - -CTextEditorCtrl::~CTextEditorCtrl() -{ -} - - -// CTextEditorCtrl message handlers - -void CTextEditorCtrl::LoadFile(const QString& sFileName) -{ - if (m_filename == sFileName) - { - return; - } - - m_filename = sFileName; - - clear(); - - CCryFile file(sFileName.toUtf8().data(), "rb"); - if (file.Open(sFileName.toUtf8().data(), "rb")) - { - size_t length = file.GetLength(); - - QByteArray text; - text.resize(static_cast(length)); - file.ReadRaw(text.data(), length); - - setPlainText(text); - } - - m_bModified = false; -} - -////////////////////////////////////////////////////////////////////////// -void CTextEditorCtrl::SaveFile(const QString& sFileName) -{ - if (sFileName.isEmpty()) - { - return; - } - - if (!CFileUtil::OverwriteFile(sFileName.toUtf8().data())) - { - return; - } - - QFile file(sFileName); - file.open(QFile::WriteOnly); - - file.write(toPlainText().toUtf8()); - - m_bModified = false; -} - -////////////////////////////////////////////////////////////////////////// -void CTextEditorCtrl::OnChange() -{ - - m_bModified = true; -} - -#include diff --git a/Code/Editor/Controls/TextEditorCtrl.h b/Code/Editor/Controls/TextEditorCtrl.h deleted file mode 100644 index e155185f90..0000000000 --- a/Code/Editor/Controls/TextEditorCtrl.h +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_CONTROLS_TEXTEDITORCTRL_H -#define CRYINCLUDE_EDITOR_CONTROLS_TEXTEDITORCTRL_H -#pragma once - -// CTextEditorCtrl -#if !defined(Q_MOC_RUN) -#include -#endif - -class CTextEditorCtrl - : public QTextEdit -{ - Q_OBJECT - -public: - CTextEditorCtrl(QWidget* pParent = nullptr); - virtual ~CTextEditorCtrl(); - - void LoadFile(const QString& sFileName); - void SaveFile(const QString& sFileName); - QString GetFilename() const { return m_filename; } - - bool IsModified() const { return m_bModified; } - - //! Must be called after OnChange message. - void OnChange(); - -protected: - QString m_filename; - bool m_bModified; -}; - -#endif // CRYINCLUDE_EDITOR_CONTROLS_TEXTEDITORCTRL_H diff --git a/Code/Editor/Controls/TreeCtrlUtils.h b/Code/Editor/Controls/TreeCtrlUtils.h deleted file mode 100644 index 7498360d2e..0000000000 --- a/Code/Editor/Controls/TreeCtrlUtils.h +++ /dev/null @@ -1,322 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_CONTROLS_TREECTRLUTILS_H -#define CRYINCLUDE_EDITOR_CONTROLS_TREECTRLUTILS_H -#pragma once - -#include - -namespace TreeCtrlUtils -{ - template - class TreeItemIterator - : public P - { - public: - typedef P Traits; - - //iterator traits, required by STL - typedef ptrdiff_t difference_type; - typedef HTREEITEM value_type; - typedef HTREEITEM* pointer; - typedef HTREEITEM& reference; - typedef std::forward_iterator_tag iterator_category; - - TreeItemIterator() - : pCtrl(0) - , hItem(0) {} - explicit TreeItemIterator(const P& traits) - : P(traits) - , pCtrl(0) - , hItem(0) {} - TreeItemIterator(const TreeItemIterator& other) - : P(other) - , pCtrl(other.pCtrl) - , hItem(other.hItem) {} - TreeItemIterator(CTreeCtrl* pCtrl, HTREEITEM hItem) - : pCtrl(pCtrl) - , hItem(hItem) {} - TreeItemIterator(CTreeCtrl* pCtrl, HTREEITEM hItem, const P& traits) - : P(traits) - , pCtrl(pCtrl) - , hItem(hItem) {} - - HTREEITEM operator*() {return hItem; } - bool operator==(const TreeItemIterator& other) const {return pCtrl == other.pCtrl && hItem == other.hItem; } - bool operator!=(const TreeItemIterator& other) const {return pCtrl != other.pCtrl || hItem != other.hItem; } - - TreeItemIterator& operator++() - { - HTREEITEM hNextItem = 0; - if (RecurseToChildren(hItem)) - { - hNextItem = (pCtrl ? pCtrl->GetChildItem(hItem) : 0); - } - while (pCtrl && hItem && !hNextItem) - { - hNextItem = pCtrl->GetNextSiblingItem(hItem); - if (!hNextItem) - { - hItem = pCtrl->GetParentItem(hItem); - } - } - hItem = hNextItem; - - return *this; - } - - TreeItemIterator operator++(int) {TreeItemIterator old = *this; ++(*this); return old; } - - CTreeCtrl* pCtrl; - HTREEITEM hItem; - }; - - class NonRecursiveTreeItemIteratorTraits - { - public: - bool RecurseToChildren(HTREEITEM hItem) {return false; } - }; - typedef TreeItemIterator NonRecursiveTreeItemIterator; - - class RecursiveTreeItemIteratorTraits - { - public: - bool RecurseToChildren(HTREEITEM hItem) {return true; } - }; - typedef TreeItemIterator RecursiveTreeItemIterator; - - inline RecursiveTreeItemIterator BeginTreeItemsRecursive(CTreeCtrl* pCtrl, HTREEITEM hItem = 0) - { - if (hItem == 0) - { - hItem = (pCtrl ? pCtrl->GetRootItem() : 0); - } - return RecursiveTreeItemIterator(pCtrl, hItem); - } - - inline RecursiveTreeItemIterator EndTreeItemsRecursive(CTreeCtrl* pCtrl, HTREEITEM hItem = 0) - { - HTREEITEM hEndItem = 0; - HTREEITEM hParent = hItem; - do - { - if (hParent) - { - hEndItem = pCtrl->GetNextSiblingItem(hParent); - } - hParent = (pCtrl && hParent ? pCtrl->GetParentItem(hParent) : 0); - } - while (hParent && !hEndItem); - return RecursiveTreeItemIterator(pCtrl, hEndItem); - } - - inline NonRecursiveTreeItemIterator BeginTreeItemsNonRecursive(CTreeCtrl* pCtrl, HTREEITEM hItem = 0) - { - if (hItem == 0) - { - hItem = (pCtrl ? pCtrl->GetRootItem() : 0); - } - if (hItem) - { - hItem = pCtrl->GetChildItem(hItem); - } - return NonRecursiveTreeItemIterator(pCtrl, hItem); - } - - inline NonRecursiveTreeItemIterator EndTreeItemsNonRecursive(CTreeCtrl* pCtrl, HTREEITEM hItem = 0) - { - HTREEITEM hEndItem = 0; - HTREEITEM hParent = 0; - while (hParent && !hEndItem) - { - hParent = (pCtrl && hItem ? pCtrl->GetParentItem(hItem) : 0); - if (hParent) - { - hEndItem = pCtrl->GetNextSiblingItem(hParent); - } - } - return NonRecursiveTreeItemIterator(pCtrl, hEndItem); - } - - template - class TreeItemDataIterator - { - public: - typedef T Type; - typedef TreeItemIterator

InternalIterator; - - //iterator traits, required by STL - typedef ptrdiff_t difference_type; - typedef Type* value_type; - typedef Type** pointer; - typedef Type*& reference; - typedef std::forward_iterator_tag iterator_category; - - TreeItemDataIterator() {} - TreeItemDataIterator(const TreeItemDataIterator& other) - : iterator(other.iterator) {AdvanceToValidIterator(); } - explicit TreeItemDataIterator(const InternalIterator& iterator) - : iterator(iterator) {AdvanceToValidIterator(); } - - Type* operator*() {return reinterpret_cast(iterator.pCtrl->GetItemData(iterator.hItem)); } - bool operator==(const TreeItemDataIterator& other) const {return iterator == other.iterator; } - bool operator!=(const TreeItemDataIterator& other) const {return iterator != other.iterator; } - - HTREEITEM GetTreeItem() {return iterator.hItem; } - - TreeItemDataIterator& operator++() - { - ++iterator; - AdvanceToValidIterator(); - return *this; - } - - TreeItemDataIterator operator++(int) {TreeItemDataIterator old = *this; ++(*this); return old; } - - private: - void AdvanceToValidIterator() - { - while (iterator.pCtrl && iterator.hItem && !iterator.pCtrl->GetItemData(iterator.hItem)) - { - ++iterator; - } - } - - InternalIterator iterator; - }; - - template - class RecursiveItemDataIteratorType - { - public: typedef TreeItemDataIterator type; - }; - template - inline TreeItemDataIterator BeginTreeItemDataRecursive(CTreeCtrl* pCtrl, HTREEITEM hItem = 0) - { - return TreeItemDataIterator(BeginTreeItemsRecursive(pCtrl, hItem)); - } - - template - inline TreeItemDataIterator EndTreeItemDataRecursive(CTreeCtrl* pCtrl, HTREEITEM hItem = 0) - { - return TreeItemDataIterator(EndTreeItemsRecursive(pCtrl, hItem)); - } - - template - class NonRecursiveItemDataIteratorType - { - typedef TreeItemDataIterator type; - }; - template - inline TreeItemDataIterator BeginTreeItemDataNonRecursive(CTreeCtrl* pCtrl, HTREEITEM hItem = 0) - { - return TreeItemDataIterator(BeginTreeItemsNonRecursive(pCtrl, hItem)); - } - - template - inline TreeItemDataIterator EndTreeItemDataNonRecursive(CTreeCtrl* pCtrl, HTREEITEM hItem = 0) - { - return TreeItemDataIterator(EndTreeItemsNonRecursive(pCtrl, hItem)); - } - - class SelectedTreeItemIterator - { - public: - SelectedTreeItemIterator() - : pCtrl(0) - , hItem(0) {} - SelectedTreeItemIterator(const SelectedTreeItemIterator& other) - : pCtrl(other.pCtrl) - , hItem(other.hItem) {} - SelectedTreeItemIterator(CXTTreeCtrl* pCtrl, HTREEITEM hItem) - : pCtrl(pCtrl) - , hItem(hItem) {} - - HTREEITEM operator*() {return hItem; } - bool operator==(const SelectedTreeItemIterator& other) const {return pCtrl == other.pCtrl && hItem == other.hItem; } - bool operator!=(const SelectedTreeItemIterator& other) const {return pCtrl != other.pCtrl || hItem != other.hItem; } - - SelectedTreeItemIterator& operator++() - { - hItem = (pCtrl ? pCtrl->GetNextSelectedItem(hItem) : 0); - - return *this; - } - - SelectedTreeItemIterator operator++(int) {SelectedTreeItemIterator old = *this; ++(*this); return old; } - - CXTTreeCtrl* pCtrl; - HTREEITEM hItem; - }; - - SelectedTreeItemIterator BeginSelectedTreeItems(CXTTreeCtrl* pCtrl) - { - return SelectedTreeItemIterator(pCtrl, (pCtrl ? pCtrl->GetFirstSelectedItem() : 0)); - } - - SelectedTreeItemIterator EndSelectedTreeItems(CXTTreeCtrl* pCtrl) - { - return SelectedTreeItemIterator(pCtrl, 0); - } - - template - class SelectedTreeItemDataIterator - { - public: - typedef T Type; - typedef SelectedTreeItemIterator InternalIterator; - - SelectedTreeItemDataIterator() {} - SelectedTreeItemDataIterator(const SelectedTreeItemDataIterator& other) - : iterator(other.iterator) {AdvanceToValidIterator(); } - explicit SelectedTreeItemDataIterator(const InternalIterator& iterator) - : iterator(iterator) {AdvanceToValidIterator(); } - - Type* operator*() {return reinterpret_cast(iterator.pCtrl->GetItemData(iterator.hItem)); } - bool operator==(const SelectedTreeItemDataIterator& other) const {return iterator == other.iterator; } - bool operator!=(const SelectedTreeItemDataIterator& other) const {return iterator != other.iterator; } - - HTREEITEM GetTreeItem() {return iterator.hItem; } - - SelectedTreeItemDataIterator& operator++() - { - ++iterator; - AdvanceToValidIterator(); - return *this; - } - - SelectedTreeItemDataIterator operator++(int) {SelectedTreeItemDataIterator old = *this; ++(*this); return old; } - - private: - void AdvanceToValidIterator() - { - while (iterator.pCtrl && iterator.hItem && !iterator.pCtrl->GetItemData(iterator.hItem)) - { - ++iterator; - } - } - - InternalIterator iterator; - }; - - template - SelectedTreeItemDataIterator BeginSelectedTreeItemData(CXTTreeCtrl* pCtrl) - { - return SelectedTreeItemDataIterator(BeginSelectedTreeItems(pCtrl)); - } - - template - SelectedTreeItemDataIterator EndSelectedTreeItemData(CXTTreeCtrl* pCtrl) - { - return SelectedTreeItemDataIterator(EndSelectedTreeItems(pCtrl)); - } -} - -#endif // CRYINCLUDE_EDITOR_CONTROLS_TREECTRLUTILS_H diff --git a/Code/Editor/Core/LevelEditorMenuHandler.cpp b/Code/Editor/Core/LevelEditorMenuHandler.cpp index a90b0a597a..05f06c87aa 100644 --- a/Code/Editor/Core/LevelEditorMenuHandler.cpp +++ b/Code/Editor/Core/LevelEditorMenuHandler.cpp @@ -104,6 +104,11 @@ namespace } } + // Currently (December 13, 2021), this function is only used by slice editor code. + // When the slice editor is not enabled, there are no references to the + // HideActionWhileEntitiesDeselected function, causing a compiler warning and + // subsequently a build error. +#ifdef ENABLE_SLICE_EDITOR void HideActionWhileEntitiesDeselected(QAction* action, EEditorNotifyEvent editorNotifyEvent) { if (action == nullptr) @@ -127,6 +132,7 @@ namespace break; } } +#endif void DisableActionWhileInSimMode(QAction* action, EEditorNotifyEvent editorNotifyEvent) { @@ -374,7 +380,6 @@ QMenu* LevelEditorMenuHandler::CreateFileMenu() { DisableActionWhileLevelChanges(fileOpenSlice, e); })); -#endif // Save Selected Slice auto saveSelectedSlice = fileMenu.AddAction(ID_FILE_SAVE_SELECTED_SLICE); @@ -391,7 +396,7 @@ QMenu* LevelEditorMenuHandler::CreateFileMenu() { HideActionWhileEntitiesDeselected(saveSliceToRoot, e); })); - +#endif // Open Recent m_mostRecentLevelsMenu = fileMenu.AddMenu(tr("Open Recent")); connect(m_mostRecentLevelsMenu, &QMenu::aboutToShow, this, &LevelEditorMenuHandler::UpdateMRUFiles); @@ -439,9 +444,10 @@ QMenu* LevelEditorMenuHandler::CreateFileMenu() // Show Log File fileMenu.AddAction(ID_FILE_EDITLOGFILE); +#ifdef ENABLE_SLICE_EDITOR fileMenu.AddSeparator(); - fileMenu.AddAction(ID_FILE_RESAVESLICES); +#endif fileMenu.AddSeparator(); diff --git a/Code/Editor/CryEdit.cpp b/Code/Editor/CryEdit.cpp index 4415308730..1c4e22b99e 100644 --- a/Code/Editor/CryEdit.cpp +++ b/Code/Editor/CryEdit.cpp @@ -380,13 +380,13 @@ void CCryEditApp::RegisterActionHandlers() ON_COMMAND(ID_IMPORT_ASSET, OnOpenAssetImporter) ON_COMMAND(ID_EDIT_LEVELDATA, OnEditLevelData) ON_COMMAND(ID_FILE_EDITLOGFILE, OnFileEditLogFile) - ON_COMMAND(ID_FILE_RESAVESLICES, OnFileResaveSlices) ON_COMMAND(ID_FILE_EDITEDITORINI, OnFileEditEditorini) ON_COMMAND(ID_PREFERENCES, OnPreferences) ON_COMMAND(ID_REDO, OnRedo) ON_COMMAND(ID_TOOLBAR_WIDGET_REDO, OnRedo) ON_COMMAND(ID_FILE_OPEN_LEVEL, OnOpenLevel) #ifdef ENABLE_SLICE_EDITOR + ON_COMMAND(ID_FILE_RESAVESLICES, OnFileResaveSlices) ON_COMMAND(ID_FILE_NEW_SLICE, OnCreateSlice) ON_COMMAND(ID_FILE_OPEN_SLICE, OnOpenSlice) #endif @@ -1352,8 +1352,27 @@ void CCryEditApp::CompileCriticalAssets() const } } assetsInQueueNotifcation.BusDisconnect(); - CCryEditApp::OutputStartupMessage(QString("Asset Processor is now ready.")); + // Signal the "CriticalAssetsCompiled" lifecycle event + // Also reload the "assetcatalog.xml" if it exists + if (auto settingsRegistry = AZ::SettingsRegistry::Get(); settingsRegistry != nullptr) + { + AZ::ComponentApplicationLifecycle::SignalEvent(*settingsRegistry, "CriticalAssetsCompiled", R"({})"); + // Reload the assetcatalog.xml at this point again + // Start Monitoring Asset changes over the network and load the AssetCatalog + auto LoadCatalog = [settingsRegistry](AZ::Data::AssetCatalogRequests* assetCatalogRequests) + { + if (AZ::IO::FixedMaxPath assetCatalogPath; + settingsRegistry->Get(assetCatalogPath.Native(), AZ::SettingsRegistryMergeUtils::FilePathKey_CacheRootFolder)) + { + assetCatalogPath /= "assetcatalog.xml"; + assetCatalogRequests->LoadCatalog(assetCatalogPath.c_str()); + } + }; + AZ::Data::AssetCatalogRequestBus::Broadcast(AZStd::move(LoadCatalog)); + } + + CCryEditApp::OutputStartupMessage(QString("Asset Processor is now ready.")); } bool CCryEditApp::ConnectToAssetProcessor() const @@ -1669,7 +1688,7 @@ bool CCryEditApp::InitInstance() return false; } - if (AZ::SettingsRegistryInterface* settingsRegistry = AZ::SettingsRegistry::Get()) + if (auto settingsRegistry = AZ::SettingsRegistry::Get(); settingsRegistry != nullptr) { AZ::ComponentApplicationLifecycle::SignalEvent(*settingsRegistry, "LegacySystemInterfaceCreated", R"({})"); } @@ -2629,6 +2648,7 @@ void CCryEditApp::OnFileEditLogFile() CFileUtil::EditTextFile(CLogFile::GetLogFileName(), 0, IFileUtil::FILE_TYPE_SCRIPT); } +#ifdef ENABLE_SLICE_EDITOR void CCryEditApp::OnFileResaveSlices() { AZStd::vector sliceAssetInfos; @@ -2759,6 +2779,7 @@ void CCryEditApp::OnFileResaveSlices() } } +#endif ////////////////////////////////////////////////////////////////////////// void CCryEditApp::OnFileEditEditorini() diff --git a/Code/Editor/EditMode/DeepSelection.cpp b/Code/Editor/EditMode/DeepSelection.cpp deleted file mode 100644 index 3e232a230c..0000000000 --- a/Code/Editor/EditMode/DeepSelection.cpp +++ /dev/null @@ -1,138 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "DeepSelection.h" - -// Editor -#include "Objects/BaseObject.h" - - -//! Functor for sorting selected objects on deep selection mode. -struct NearDistance -{ - NearDistance(){} - bool operator()(const CDeepSelection::RayHitObject& lhs, const CDeepSelection::RayHitObject& rhs) const - { - return lhs.distance < rhs.distance; - } -}; - -//----------------------------------------------------------------------------- -CDeepSelection::CDeepSelection() - : m_Mode(DSM_NONE) - , m_previousMode(DSM_NONE) - , m_CandidateObjectCount(0) - , m_CurrentSelectedPos(-1) -{ - m_LastPickPoint = QPoint(-1, -1); -} - -//----------------------------------------------------------------------------- -CDeepSelection::~CDeepSelection() -{ -} - -//----------------------------------------------------------------------------- -void CDeepSelection::Reset(bool bResetLastPick) -{ - for (int i = 0; i < m_CandidateObjectCount; ++i) - { - m_RayHitObjects[i].object->ClearFlags(OBJFLAG_NO_HITTEST); - } - - m_CandidateObjectCount = 0; - m_CurrentSelectedPos = -1; - - m_RayHitObjects.clear(); - - if (bResetLastPick) - { - m_LastPickPoint = QPoint(-1, -1); - } -} - -//----------------------------------------------------------------------------- -void CDeepSelection::AddObject(float distance, CBaseObject* pObj) -{ - m_RayHitObjects.push_back(RayHitObject(distance, pObj)); -} - -//----------------------------------------------------------------------------- -bool CDeepSelection::OnCycling (const QPoint& pt) -{ - QPoint diff = m_LastPickPoint - pt; - LONG epsilon = 2; - m_LastPickPoint = pt; - - if (abs(diff.x()) < epsilon && abs(diff.y()) < epsilon) - { - return true; - } - else - { - return false; - } -} - -//----------------------------------------------------------------------------- -void CDeepSelection::ExcludeHitTest(int except) -{ - int nExcept = except % m_CandidateObjectCount; - - for (int i = 0; i < m_CandidateObjectCount; ++i) - { - m_RayHitObjects[i].object->SetFlags(OBJFLAG_NO_HITTEST); - } - - m_RayHitObjects[nExcept].object->ClearFlags(OBJFLAG_NO_HITTEST); -} - -//----------------------------------------------------------------------------- -int CDeepSelection::CollectCandidate(float fMinDistance, float fRange) -{ - m_CandidateObjectCount = 0; - - if (!m_RayHitObjects.empty()) - { - std::sort(m_RayHitObjects.begin(), m_RayHitObjects.end(), NearDistance()); - - for (std::vector::iterator itr = m_RayHitObjects.begin(); - itr != m_RayHitObjects.end(); ++itr) - { - if (itr->distance - fMinDistance < fRange) - { - ++m_CandidateObjectCount; - } - else - { - break; - } - } - } - - return m_CandidateObjectCount; -} - -//----------------------------------------------------------------------------- -CBaseObject* CDeepSelection::GetCandidateObject(int index) -{ - m_CurrentSelectedPos = index % m_CandidateObjectCount; - - return m_RayHitObjects[m_CurrentSelectedPos].object; -} - -//----------------------------------------------------------------------------- -//! -void CDeepSelection::SetMode(EDeepSelectionMode mode) -{ - m_previousMode = m_Mode; - m_Mode = mode; -} diff --git a/Code/Editor/EditMode/DeepSelection.h b/Code/Editor/EditMode/DeepSelection.h deleted file mode 100644 index b6f652abc5..0000000000 --- a/Code/Editor/EditMode/DeepSelection.h +++ /dev/null @@ -1,87 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -// Description : Deep Selection Header - - -#ifndef CRYINCLUDE_EDITOR_EDITMODE_DEEPSELECTION_H -#define CRYINCLUDE_EDITOR_EDITMODE_DEEPSELECTION_H -#pragma once - -class CBaseObject; - -//! Deep Selection -//! Additional output information of HitContext on using "deep selection mode". -//! At the deep selection mode, it supports second selection pass for easy -//! selection on crowded area with two different method. -//! One is to show pop menu of candidate objects list. Another is the cyclic -//! selection on pick clicking. -class CDeepSelection - : public _i_reference_target_t -{ -public: - //! Deep Selection Mode Definition - enum EDeepSelectionMode - { - DSM_NONE = 0, // Not using deep selection. - DSM_POP = 1, // Deep selection mode with pop context menu. - DSM_CYCLE = 2 // Deep selection mode with cyclic selection on each clinking same point. - }; - - //! Subclass for container of the selected object with hit distance. - struct RayHitObject - { - RayHitObject(float dist, CBaseObject* pObj) - : distance(dist) - , object(pObj) - { - } - - float distance; - CBaseObject* object; - }; - - //! Constructor - CDeepSelection(); - virtual ~CDeepSelection(); - - void Reset(bool bResetLastPick = false); - void AddObject(float distance, CBaseObject* pObj); - //! Check if clicking point is same position with last position, - //! to decide whether to continue cycling mode. - bool OnCycling (const QPoint& pt); - //! All objects in list are excluded for hitting test except one, current selection. - void ExcludeHitTest(int except); - void SetMode(EDeepSelectionMode mode); - inline EDeepSelectionMode GetMode() const { return m_Mode; } - inline EDeepSelectionMode GetPreviousMode() const { return m_previousMode; } - //! Collect object in the deep selection range. The distance from the minimum - //! distance is less than deep selection range. - int CollectCandidate(float fMinDistance, float fRange); - //! Return the candidate object in index position, then it is to be current - //! selection position. - CBaseObject* GetCandidateObject(int index); - //! Return the current selection position that is update in "GetCandidateObject" - //! function call. - inline int GetCurrentSelectPos() const { return m_CurrentSelectedPos; } - //! Return the number of objects in the deep selection range. - inline int GetCandidateObjectCount() const { return m_CandidateObjectCount; } - -private: - //! Current mode - EDeepSelectionMode m_Mode; - EDeepSelectionMode m_previousMode; - //! Last picking point to check whether cyclic selection continue. - QPoint m_LastPickPoint; - //! List of the selected objects with ray hitting - std::vector m_RayHitObjects; - int m_CandidateObjectCount; - int m_CurrentSelectedPos; -}; -#endif // CRYINCLUDE_EDITOR_EDITMODE_DEEPSELECTION_H diff --git a/Code/Editor/EditorPanelUtils.cpp b/Code/Editor/EditorPanelUtils.cpp deleted file mode 100644 index a270de5978..0000000000 --- a/Code/Editor/EditorPanelUtils.cpp +++ /dev/null @@ -1,542 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - - -#include "EditorDefs.h" - -#include "EditorPanelUtils.h" - -#include - -// Qt -#include -#include -#include - -// Editor -#include "IEditorPanelUtils.h" -#include "Objects/EntityObject.h" -#include "CryEditDoc.h" -#include "ViewManager.h" -#include "Controls/QToolTipWidget.h" -#include "Objects/SelectionGroup.h" - - - -#ifndef PI -#define PI 3.14159265358979323f -#endif - - -struct ToolTip -{ - bool isValid; - QString title; - QString content; - QString specialContent; - QString disabledContent; -}; - -// internal implementation for better compile times - should also never be used externally, use IParticleEditorUtils interface for that. -class CEditorPanelUtils_Impl - : public IEditorPanelUtils -{ -public: - void SetViewportDragOperation(void(* dropCallback)(CViewport* viewport, int dragPointX, int dragPointY, void* custom), void* custom) override - { - for (int i = 0; i < GetIEditor()->GetViewManager()->GetViewCount(); i++) - { - GetIEditor()->GetViewManager()->GetView(i)->SetGlobalDropCallback(dropCallback, custom); - } - } - -public: - - int PreviewWindow_GetDisplaySettingsDebugFlags(CDisplaySettings* settings) override - { - CRY_ASSERT(settings); - return settings->GetDebugFlags(); - } - - void PreviewWindow_SetDisplaySettingsDebugFlags(CDisplaySettings* settings, int flags) override - { - CRY_ASSERT(settings); - settings->SetDebugFlags(flags); - } - -protected: - QVector hotkeys; - bool m_hotkeysAreEnabled; -public: - - bool HotKey_Import() override - { - QVector > keys; - QString filepath = QFileDialog::getOpenFileName(nullptr, "Select shortcut configuration to load", - QString(), "HotKey Config Files (*.hkxml)"); - QFile file(filepath); - if (!file.open(QIODevice::ReadOnly)) - { - return false; - } - QXmlStreamReader stream(&file); - bool result = true; - - while (!stream.isEndDocument()) - { - if (stream.isStartElement()) - { - if (stream.name() == "HotKey") - { - QPair key; - QXmlStreamAttributes att = stream.attributes(); - for (QXmlStreamAttribute attr : att) - { - if (attr.name().compare(QLatin1String("path"), Qt::CaseInsensitive) == 0) - { - key.first = attr.value().toString(); - } - if (attr.name().compare(QLatin1String("sequence"), Qt::CaseInsensitive) == 0) - { - key.second = attr.value().toString(); - } - } - if (!key.first.isEmpty()) - { - keys.push_back(key); // we allow blank key sequences for unassigned shortcuts - } - else - { - result = false; //but not blank paths! - } - } - } - stream.readNext(); - } - file.close(); - - if (result) - { - HotKey_BuildDefaults(); - for (QPair key : keys) - { - for (int j = 0; j < hotkeys.count(); j++) - { - if (hotkeys[j].path.compare(key.first, Qt::CaseInsensitive) == 0) - { - hotkeys[j].SetPath(key.first.toStdString().c_str()); - hotkeys[j].SetSequenceFromString(key.second.toStdString().c_str()); - } - } - } - } - return result; - } - - void HotKey_Export() override - { - auto settingDir = AZ::IO::FixedMaxPath(AZ::Utils::GetEnginePath()) / "Editor" / "Plugins" / "ParticleEditorPlugin" / "settings"; - QString filepath = QFileDialog::getSaveFileName(nullptr, "Select shortcut configuration to load", settingDir.c_str(), "HotKey Config Files (*.hkxml)"); - QFile file(filepath); - if (!file.open(QIODevice::WriteOnly)) - { - return; - } - - QXmlStreamWriter stream(&file); - stream.setAutoFormatting(true); - stream.writeStartDocument(); - stream.writeStartElement("HotKeys"); - - for (HotKey key : hotkeys) - { - stream.writeStartElement("HotKey"); - stream.writeAttribute("path", key.path); - stream.writeAttribute("sequence", key.sequence.toString()); - stream.writeEndElement(); - } - stream.writeEndElement(); - stream.writeEndDocument(); - file.close(); - } - - QKeySequence HotKey_GetShortcut(const char* path) override - { - for (HotKey combo : hotkeys) - { - if (combo.IsMatch(path)) - { - return combo.sequence; - } - } - return QKeySequence(); - } - - bool HotKey_IsPressed(const QKeyEvent* event, const char* path) override - { - if (!m_hotkeysAreEnabled) - { - return false; - } - unsigned int keyInt = 0; - //Capture any modifiers - Qt::KeyboardModifiers modifiers = QApplication::keyboardModifiers(); - if (modifiers & Qt::ShiftModifier) - { - keyInt += Qt::SHIFT; - } - if (modifiers & Qt::ControlModifier) - { - keyInt += Qt::CTRL; - } - if (modifiers & Qt::AltModifier) - { - keyInt += Qt::ALT; - } - if (modifiers & Qt::MetaModifier) - { - keyInt += Qt::META; - } - //Capture any key - keyInt += event->key(); - - QString t0 = QKeySequence(keyInt).toString(); - QString t1 = HotKey_GetShortcut(path).toString(); - - //if strings match then shortcut is pressed - if (t1.compare(t0, Qt::CaseInsensitive) == 0) - { - return true; - } - return false; - } - - bool HotKey_IsPressed(const QShortcutEvent* event, const char* path) override - { - if (!m_hotkeysAreEnabled) - { - return false; - } - - QString t0 = event->key().toString(); - QString t1 = HotKey_GetShortcut(path).toString(); - - //if strings match then shortcut is pressed - if (t1.compare(t0, Qt::CaseInsensitive) == 0) - { - return true; - } - return false; - } - - bool HotKey_LoadExisting() override - { - QSettings settings("O3DE", "O3DE"); - QString group = "Hotkeys/"; - - HotKey_BuildDefaults(); - - int size = settings.beginReadArray(group); - - for (int i = 0; i < size; i++) - { - settings.setArrayIndex(i); - QPair hotkey; - hotkey.first = settings.value("name").toString(); - hotkey.second = settings.value("keySequence").toString(); - if (!hotkey.first.isEmpty()) - { - for (int j = 0; j < hotkeys.count(); j++) - { - if (hotkeys[j].path.compare(hotkey.first, Qt::CaseInsensitive) == 0) - { - hotkeys[j].SetPath(hotkey.first.toStdString().c_str()); - hotkeys[j].SetSequenceFromString(hotkey.second.toStdString().c_str()); - } - } - } - } - - settings.endArray(); - if (hotkeys.isEmpty()) - { - return false; - } - return true; - } - - void HotKey_SaveCurrent() override - { - QSettings settings("O3DE", "O3DE"); - QString group = "Hotkeys/"; - settings.remove("Hotkeys/"); - settings.sync(); - settings.beginWriteArray(group); - int saveIndex = 0; - for (HotKey key : hotkeys) - { - if (!key.path.isEmpty()) - { - settings.setArrayIndex(saveIndex++); - settings.setValue("name", key.path); - settings.setValue("keySequence", key.sequence.toString()); - } - } - settings.endArray(); - settings.sync(); - } - - void HotKey_BuildDefaults() override - { - m_hotkeysAreEnabled = true; - QVector > keys; - while (hotkeys.count() > 0) - { - hotkeys.takeAt(0); - } - - //MENU SELECTION SHORTCUTS//////////////////////////////////////////////// - keys.push_back(QPair("Menus.File Menu", "Alt+F")); - keys.push_back(QPair("Menus.Edit Menu", "Alt+E")); - keys.push_back(QPair("Menus.View Menu", "Alt+V")); - //FILE MENU SHORTCUTS///////////////////////////////////////////////////// - keys.push_back(QPair("File Menu.Create new emitter", "Ctrl+N")); - keys.push_back(QPair("File Menu.Create new library", "Ctrl+Shift+N")); - keys.push_back(QPair("File Menu.Create new folder", "")); - keys.push_back(QPair("File Menu.Import", "Ctrl+I")); - keys.push_back(QPair("File Menu.Import level library", "Ctrl+Shift+I")); - keys.push_back(QPair("File Menu.Save", "Ctrl+S")); - keys.push_back(QPair("File Menu.Close", "Ctrl+Q")); - //EDIT MENU SHORTCUTS///////////////////////////////////////////////////// - keys.push_back(QPair("Edit Menu.Copy", "Ctrl+C")); - keys.push_back(QPair("Edit Menu.Paste", "Ctrl+V")); - keys.push_back(QPair("Edit Menu.Duplicate", "Ctrl+D")); - keys.push_back(QPair("Edit Menu.Undo", "Ctrl+Z")); - keys.push_back(QPair("Edit Menu.Redo", "Ctrl+Shift+Z")); - keys.push_back(QPair("Edit Menu.Group", "Ctrl+G")); - keys.push_back(QPair("Edit Menu.Ungroup", "Ctrl+Shift+G")); - keys.push_back(QPair("Edit Menu.Rename", "Ctrl+R")); - keys.push_back(QPair("Edit Menu.Reset", "")); - keys.push_back(QPair("Edit Menu.Edit Hotkeys", "")); - keys.push_back(QPair("Edit Menu.Assign to selected", "Ctrl+Space")); - keys.push_back(QPair("Edit Menu.Insert Comment", "Ctrl+Alt+M")); - keys.push_back(QPair("Edit Menu.Enable/Disable Emitter", "Ctrl+E")); - keys.push_back(QPair("File Menu.Enable All", "")); - keys.push_back(QPair("File Menu.Disable All", "")); - keys.push_back(QPair("Edit Menu.Delete", "Del")); - //VIEW MENU SHORTCUTS///////////////////////////////////////////////////// - keys.push_back(QPair("View Menu.Reset Layout", "")); - //PLAYBACK CONTROL//////////////////////////////////////////////////////// - keys.push_back(QPair("Previewer.Play/Pause Toggle", "Space")); - keys.push_back(QPair("Previewer.Step forward through time", "c")); - keys.push_back(QPair("Previewer.Loop Toggle", "z")); - keys.push_back(QPair("Previewer.Reset Playback", "x")); - keys.push_back(QPair("Previewer.Focus", "Ctrl+F")); - keys.push_back(QPair("Previewer.Zoom In", "w")); - keys.push_back(QPair("Previewer.Zoom Out", "s")); - keys.push_back(QPair("Previewer.Pan Left", "a")); - keys.push_back(QPair("Previewer.Pan Right", "d")); - - for (QPair key : keys) - { - unsigned int index = hotkeys.count(); - hotkeys.push_back(HotKey()); - hotkeys[index].SetPath(key.first.toStdString().c_str()); - hotkeys[index].SetSequenceFromString(key.second.toStdString().c_str()); - } - } - - void HotKey_SetKeys(QVector keys) override - { - hotkeys = keys; - } - - QVector HotKey_GetKeys() override - { - return hotkeys; - } - - QString HotKey_GetPressedHotkey(const QKeyEvent* event) override - { - if (!m_hotkeysAreEnabled) - { - return ""; - } - for (HotKey key : hotkeys) - { - if (HotKey_IsPressed(event, key.path.toUtf8())) - { - return key.path; - } - } - return ""; - } - QString HotKey_GetPressedHotkey(const QShortcutEvent* event) override - { - if (!m_hotkeysAreEnabled) - { - return ""; - } - for (HotKey key : hotkeys) - { - if (HotKey_IsPressed(event, key.path.toUtf8())) - { - return key.path; - } - } - return ""; - } - //building the default hotkey list re-enables hotkeys - //do not use this when rebuilding the default list is a possibility. - void HotKey_SetEnabled(bool val) override - { - m_hotkeysAreEnabled = val; - } - - bool HotKey_IsEnabled() const override - { - return m_hotkeysAreEnabled; - } - -protected: - QMap m_tooltips; - - void ToolTip_ParseNode(XmlNodeRef node) - { - if (QString(node->getTag()).compare("tooltip", Qt::CaseInsensitive) != 0) - { - unsigned int childCount = node->getChildCount(); - - for (unsigned int i = 0; i < childCount; i++) - { - ToolTip_ParseNode(node->getChild(i)); - } - } - - QString title = node->getAttr("title"); - QString content = node->getAttr("content"); - QString specialContent = node->getAttr("special_content"); - QString disabledContent = node->getAttr("disabled_content"); - - QMap::iterator itr = m_tooltips.insert(node->getAttr("path"), ToolTip()); - itr->isValid = true; - itr->title = title; - itr->content = content; - itr->specialContent = specialContent; - itr->disabledContent = disabledContent; - - unsigned int childCount = node->getChildCount(); - - for (unsigned int i = 0; i < childCount; i++) - { - ToolTip_ParseNode(node->getChild(i)); - } - } - - ToolTip GetToolTip(QString path) - { - if (m_tooltips.contains(path)) - { - return m_tooltips[path]; - } - ToolTip temp; - temp.isValid = false; - return temp; - } - -public: - void ToolTip_LoadConfigXML(QString filepath) override - { - XmlNodeRef node = GetIEditor()->GetSystem()->LoadXmlFromFile(filepath.toStdString().c_str()); - ToolTip_ParseNode(node); - } - - void ToolTip_BuildFromConfig(IQToolTip* tooltip, QString path, QString option, QString optionalData = "", bool isEnabled = true) override - { - AZ_Assert(tooltip, "tooltip cannot be null"); - - QString title = ToolTip_GetTitle(path, option); - QString content = ToolTip_GetContent(path, option); - QString specialContent = ToolTip_GetSpecialContentType(path, option); - QString disabledContent = ToolTip_GetDisabledContent(path, option); - - // Even if these items are empty, we set them anyway to clear out any data that was left over from when the tooltip was used for a different object. - tooltip->SetTitle(title); - tooltip->SetContent(content); - - //this only handles simple creation...if you need complex call this then add specials separate - if (!specialContent.contains("::")) - { - tooltip->AddSpecialContent(specialContent, optionalData); - } - - if (!isEnabled) // If disabled, add disabled value - { - tooltip->AppendContent(disabledContent); - } - } - - QString ToolTip_GetTitle(QString path, QString option) override - { - if (!option.isEmpty() && GetToolTip(path + "." + option).isValid) - { - return GetToolTip(path + "." + option).title; - } - if (!option.isEmpty() && GetToolTip("Options." + option).isValid) - { - return GetToolTip("Options." + option).title; - } - return GetToolTip(path).title; - } - - QString ToolTip_GetContent(QString path, QString option) override - { - if (!option.isEmpty() && GetToolTip(path + "." + option).isValid) - { - return GetToolTip(path + "." + option).content; - } - if (!option.isEmpty() && GetToolTip("Options." + option).isValid) - { - return GetToolTip("Options." + option).content; - } - return GetToolTip(path).content; - } - - QString ToolTip_GetSpecialContentType(QString path, QString option) override - { - if (!option.isEmpty() && GetToolTip(path + "." + option).isValid) - { - return GetToolTip(path + "." + option).specialContent; - } - if (!option.isEmpty() && GetToolTip("Options." + option).isValid) - { - return GetToolTip("Options." + option).specialContent; - } - return GetToolTip(path).specialContent; - } - - QString ToolTip_GetDisabledContent(QString path, QString option) override - { - if (!option.isEmpty() && GetToolTip(path + "." + option).isValid) - { - return GetToolTip(path + "." + option).disabledContent; - } - if (!option.isEmpty() && GetToolTip("Options." + option).isValid) - { - return GetToolTip("Options." + option).disabledContent; - } - return GetToolTip(path).disabledContent; - } -}; - -IEditorPanelUtils* CreateEditorPanelUtils() -{ - return new CEditorPanelUtils_Impl(); -} - diff --git a/Code/Editor/EditorPanelUtils.h b/Code/Editor/EditorPanelUtils.h deleted file mode 100644 index 6ac15ebfc9..0000000000 --- a/Code/Editor/EditorPanelUtils.h +++ /dev/null @@ -1,16 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -// Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. -#ifndef CRYINCLUDE_CRYEDITOR_EDITORPANELUTILS_H -#define CRYINCLUDE_CRYEDITOR_EDITORPANELUTILS_H -#pragma once - -struct IEditorPanelUtils; -IEditorPanelUtils* CreateEditorPanelUtils(); - -#endif diff --git a/Code/Editor/EditorPreferencesPageAWS.cpp b/Code/Editor/EditorPreferencesPageAWS.cpp index 68a9d6889f..9279dce7bc 100644 --- a/Code/Editor/EditorPreferencesPageAWS.cpp +++ b/Code/Editor/EditorPreferencesPageAWS.cpp @@ -28,7 +28,7 @@ void CEditorPreferencesPage_AWS::Reflect(AZ::SerializeContext& serialize) if (editContext) { editContext->Class("Options", "") - ->DataElement(AZ::Edit::UIHandlers::CheckBox, &UsageOptions::m_awsAttributionEnabled, "Allow O3DE to send information about your use of AWS Core Gem to AWS", + ->DataElement(AZ::Edit::UIHandlers::CheckBox, &UsageOptions::m_awsAttributionEnabled, "Allow O3DE to send information about your use of AWS Core Gem to AWS", ""); editContext->Class("AWS Preferences", "AWS Preferences") diff --git a/Code/Editor/EditorPreferencesPageViewportGeneral.cpp b/Code/Editor/EditorPreferencesPageViewportGeneral.cpp index 77560e24f8..f33cc3f725 100644 --- a/Code/Editor/EditorPreferencesPageViewportGeneral.cpp +++ b/Code/Editor/EditorPreferencesPageViewportGeneral.cpp @@ -41,8 +41,6 @@ void CEditorPreferencesPage_ViewportGeneral::Reflect(AZ::SerializeContext& seria ->Field("ShowBBoxes", &Display::m_showBBoxes) ->Field("DrawEntityLabels", &Display::m_drawEntityLabels) ->Field("ShowTriggerBounds", &Display::m_showTriggerBounds) - ->Field("ShowIcons", &Display::m_showIcons) - ->Field("DistanceScaleIcons", &Display::m_distanceScaleIcons) ->Field("ShowFrozenHelpers", &Display::m_showFrozenHelpers) ->Field("FillSelectedShapes", &Display::m_fillSelectedShapes) ->Field("ShowGridGuide", &Display::m_showGridGuide) @@ -118,10 +116,6 @@ void CEditorPreferencesPage_ViewportGeneral::Reflect(AZ::SerializeContext& seria AZ::Edit::UIHandlers::CheckBox, &Display::m_drawEntityLabels, "Always Draw Entity Labels", "Always Draw Entity Labels") ->DataElement( AZ::Edit::UIHandlers::CheckBox, &Display::m_showTriggerBounds, "Always Show Trigger Bounds", "Always Show Trigger Bounds") - ->DataElement(AZ::Edit::UIHandlers::CheckBox, &Display::m_showIcons, "Show Object Icons", "Show Object Icons") - ->DataElement( - AZ::Edit::UIHandlers::CheckBox, &Display::m_distanceScaleIcons, "Scale Object Icons with Distance", - "Scale Object Icons with Distance") ->DataElement( AZ::Edit::UIHandlers::CheckBox, &Display::m_showFrozenHelpers, "Show Helpers of Frozen Objects", "Show Helpers of Frozen Objects") @@ -244,8 +238,6 @@ void CEditorPreferencesPage_ViewportGeneral::OnApply() } gSettings.viewports.bDrawEntityLabels = m_display.m_drawEntityLabels; gSettings.viewports.bShowTriggerBounds = m_display.m_showTriggerBounds; - gSettings.viewports.bShowIcons = m_display.m_showIcons; - gSettings.viewports.bDistanceScaleIcons = m_display.m_distanceScaleIcons; gSettings.viewports.nShowFrozenHelpers = m_display.m_showFrozenHelpers; gSettings.viewports.bFillSelectedShapes = m_display.m_fillSelectedShapes; gSettings.viewports.bShowGridGuide = m_display.m_showGridGuide; @@ -300,8 +292,6 @@ void CEditorPreferencesPage_ViewportGeneral::InitializeSettings() m_display.m_showBBoxes = (ds->GetRenderFlags() & RENDER_FLAG_BBOX) == RENDER_FLAG_BBOX; m_display.m_drawEntityLabels = gSettings.viewports.bDrawEntityLabels; m_display.m_showTriggerBounds = gSettings.viewports.bShowTriggerBounds; - m_display.m_showIcons = gSettings.viewports.bShowIcons; - m_display.m_distanceScaleIcons = gSettings.viewports.bDistanceScaleIcons; m_display.m_showFrozenHelpers = gSettings.viewports.nShowFrozenHelpers; m_display.m_fillSelectedShapes = gSettings.viewports.bFillSelectedShapes; m_display.m_showGridGuide = gSettings.viewports.bShowGridGuide; diff --git a/Code/Editor/EditorPreferencesPageViewportGeneral.h b/Code/Editor/EditorPreferencesPageViewportGeneral.h index be89cc6df4..2d2a207d6c 100644 --- a/Code/Editor/EditorPreferencesPageViewportGeneral.h +++ b/Code/Editor/EditorPreferencesPageViewportGeneral.h @@ -62,8 +62,6 @@ private: bool m_showBBoxes; bool m_drawEntityLabels; bool m_showTriggerBounds; - bool m_showIcons; - bool m_distanceScaleIcons; bool m_showFrozenHelpers; bool m_fillSelectedShapes; bool m_showGridGuide; diff --git a/Code/Editor/EditorViewportWidget.cpp b/Code/Editor/EditorViewportWidget.cpp index 754ea84544..a8180bcace 100644 --- a/Code/Editor/EditorViewportWidget.cpp +++ b/Code/Editor/EditorViewportWidget.cpp @@ -454,9 +454,6 @@ void EditorViewportWidget::Update() // Render { - // TODO: Move out this logic to a controller and refactor to work with Atom - ProcessRenderLisneters(m_displayContext); - m_displayContext.Flush2D(); // Post Render Callback @@ -585,11 +582,11 @@ void EditorViewportWidget::OnEditorNotifyEvent(EEditorNotifyEvent event) case eNotify_OnCloseScene: m_renderViewport->SetScene(nullptr); - SetDefaultCamera(); break; case eNotify_OnEndSceneOpen: UpdateScene(); + SetDefaultCamera(); break; case eNotify_OnBeginNewScene: @@ -1030,8 +1027,6 @@ void EditorViewportWidget::OnTitleMenu(QMenu* menu) AZ::ViewportHelpers::AddCheckbox(menu, tr("Show Safe Frame"), &gSettings.viewports.bShowSafeFrame); AZ::ViewportHelpers::AddCheckbox(menu, tr("Show Construction Plane"), &gSettings.snap.constructPlaneDisplay); AZ::ViewportHelpers::AddCheckbox(menu, tr("Show Trigger Bounds"), &gSettings.viewports.bShowTriggerBounds); - AZ::ViewportHelpers::AddCheckbox(menu, tr("Show Icons"), &gSettings.viewports.bShowIcons, &gSettings.viewports.bShowSizeBasedIcons); - AZ::ViewportHelpers::AddCheckbox(menu, tr("Show Size-based Icons"), &gSettings.viewports.bShowSizeBasedIcons, &gSettings.viewports.bShowIcons); AZ::ViewportHelpers::AddCheckbox(menu, tr("Show Helpers of Frozen Objects"), &gSettings.viewports.nShowFrozenHelpers); if (!m_predefinedAspectRatios.IsEmpty()) diff --git a/Code/Editor/ErrorRecorder.cpp b/Code/Editor/ErrorRecorder.cpp index 999dab323c..253e103527 100644 --- a/Code/Editor/ErrorRecorder.cpp +++ b/Code/Editor/ErrorRecorder.cpp @@ -7,7 +7,6 @@ */ #include "EditorDefs.h" #include "ErrorRecorder.h" -#include "BaseLibraryItem.h" #include "Include/IErrorReport.h" diff --git a/Code/Editor/ErrorRecorder.h b/Code/Editor/ErrorRecorder.h index e4b3706a16..beacc3f0e5 100644 --- a/Code/Editor/ErrorRecorder.h +++ b/Code/Editor/ErrorRecorder.h @@ -14,6 +14,8 @@ #define CRYINCLUDE_EDITOR_CORE_ERRORRECORDER_H #pragma once +#include "Include/EditorCoreAPI.h" + ////////////////////////////////////////////////////////////////////////// //! Automatic class to record and display error. class EDITOR_CORE_API CErrorsRecorder diff --git a/Code/Editor/ErrorReport.cpp b/Code/Editor/ErrorReport.cpp index 4fd7d41a96..f93ea7606d 100644 --- a/Code/Editor/ErrorReport.cpp +++ b/Code/Editor/ErrorReport.cpp @@ -67,24 +67,6 @@ QString CErrorRecord::GetErrorText() const { str += QString("\t "); } - if (pItem) - { - switch (pItem->GetType()) - { - case EDB_TYPE_MATERIAL: - str += QString("\t Material=\""); - break; - case EDB_TYPE_PARTICLE: - str += QString("\t Particle=\""); - break; - case EDB_TYPE_MUSIC: - str += QString("\t Music=\""); - break; - default: - str += QString("\t Item=\""); - } - str += pItem->GetFullName() + "\""; - } if (pObject) { str += QString("\t Object=\"") + pObject->GetName() + "\""; @@ -101,7 +83,6 @@ CErrorReport::CErrorReport() m_bImmediateMode = true; m_bShowErrors = true; m_pObject = nullptr; - m_pItem = nullptr; m_pParticle = nullptr; } @@ -140,10 +121,6 @@ void CErrorReport::ReportError(CErrorRecord& err) { err.pObject = m_pObject; } - else if (err.pItem == nullptr && m_pItem != nullptr) - { - err.pItem = m_pItem; - } m_errors.push_back(err); } bNoRecurse = false; @@ -255,12 +232,6 @@ void CErrorReport::SetCurrentValidatorObject(CBaseObject* pObject) m_pObject = pObject; } -////////////////////////////////////////////////////////////////////////// -void CErrorReport::SetCurrentValidatorItem(CBaseLibraryItem* pItem) -{ - m_pItem = pItem; -} - ////////////////////////////////////////////////////////////////////////// void CErrorReport::SetCurrentFile(const QString& file) { diff --git a/Code/Editor/ErrorReport.h b/Code/Editor/ErrorReport.h index 3b9a860301..98d230e383 100644 --- a/Code/Editor/ErrorReport.h +++ b/Code/Editor/ErrorReport.h @@ -17,8 +17,11 @@ // forward declarations. class CParticleItem; -#include "BaseLibraryItem.h" +#include +#include + #include "Objects/BaseObject.h" +#include "Include/EditorCoreAPI.h" #include "Include/IErrorReport.h" #include "ErrorRecorder.h" @@ -56,16 +59,13 @@ public: int count; //! Object that caused this error. _smart_ptr pObject; - //! Library Item that caused this error. - _smart_ptr pItem; int flags; CErrorRecord(CBaseObject* object, ESeverity _severity, const QString& _error, int _flags = 0, int _count = 0, - CBaseLibraryItem* item = 0, EValidatorModule _module = VALIDATOR_MODULE_EDITOR) + EValidatorModule _module = VALIDATOR_MODULE_EDITOR) : severity(_severity) , module(_module) , pObject(object) - , pItem(item) , flags(_flags) , count(_count) , error(_error) @@ -77,7 +77,6 @@ public: severity = ESEVERITY_WARNING; module = VALIDATOR_MODULE_EDITOR; pObject = 0; - pItem = 0; flags = 0; count = 0; } @@ -116,8 +115,6 @@ public: //! Assign current Object to which new reported warnings are assigned. void SetCurrentValidatorObject(CBaseObject* pObject); - //! Assign current Item to which new reported warnings are assigned. - void SetCurrentValidatorItem(CBaseLibraryItem* pItem); //! Assign current filename. void SetCurrentFile(const QString& file); @@ -127,7 +124,6 @@ private: bool m_bImmediateMode; bool m_bShowErrors; _smart_ptr m_pObject; - _smart_ptr m_pItem; CParticleItem* m_pParticle; QString m_currentFilename; }; diff --git a/Code/Editor/ErrorReportDialog.cpp b/Code/Editor/ErrorReportDialog.cpp index 2d551d6c8b..bbeede79ef 100644 --- a/Code/Editor/ErrorReportDialog.cpp +++ b/Code/Editor/ErrorReportDialog.cpp @@ -362,10 +362,6 @@ void CErrorReportDialog::CopyToClipboard() { str += QString::fromLatin1(" [Object: %1]").arg(pRecord->pObject->GetName()); } - if (pRecord->pItem) - { - str += QString::fromLatin1(" [Material: %1]").arg(pRecord->pItem->GetName()); - } str += QString::fromLatin1("\r\n"); } } diff --git a/Code/Editor/ErrorReportTableModel.cpp b/Code/Editor/ErrorReportTableModel.cpp index f5dce1a86d..923991bb62 100644 --- a/Code/Editor/ErrorReportTableModel.cpp +++ b/Code/Editor/ErrorReportTableModel.cpp @@ -149,11 +149,7 @@ QVariant CErrorReportTableModel::data(const CErrorRecord& record, int column, in case ColumnFile: return record.file; case ColumnObject: - if (record.pItem) - { - return record.pItem->GetFullName(); - } - else if (record.pObject) + if (record.pObject) { return record.pObject->GetName(); } diff --git a/Code/Editor/Geometry/TriMesh.cpp b/Code/Editor/Geometry/TriMesh.cpp deleted file mode 100644 index efc201095d..0000000000 --- a/Code/Editor/Geometry/TriMesh.cpp +++ /dev/null @@ -1,587 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "TriMesh.h" - -// Editor -#include "Util/fastlib.h" -#include "Objects/SubObjSelection.h" - - -////////////////////////////////////////////////////////////////////////// -CTriMesh::CTriMesh() -{ - pFaces = nullptr; - pVertices = nullptr; - pWSVertices = nullptr; - pUV = nullptr; - pColors = nullptr; - pEdges = nullptr; - pWeights = nullptr; - - nFacesCount = 0; - nVertCount = 0; - nUVCount = 0; - nEdgeCount = 0; - - selectionType = SO_ELEM_NONE; - - memset(m_streamSize, 0, sizeof(m_streamSize)); - memset(m_streamSel, 0, sizeof(m_streamSel)); - streamSelMask = 0; - - m_streamSel[VERTICES] = &vertSel; - m_streamSel[EDGES] = &edgeSel; - m_streamSel[FACES] = &faceSel; -} - -////////////////////////////////////////////////////////////////////////// -CTriMesh::~CTriMesh() -{ - free(pFaces); - free(pEdges); - free(pVertices); - free(pUV); - free(pColors); - free(pWSVertices); - free(pWeights); -} - -// Set stream size. -void CTriMesh::ReallocStream(int stream, int nNewCount) -{ - assert(stream >= 0 && stream < LAST_STREAM); - if (stream < 0 || stream >= LAST_STREAM) - { - return; - } - if (m_streamSize[stream] == nNewCount) - { - return; // Stream already have required size. - } - void* pStream = nullptr; - int nElementSize = 0; - GetStreamInfo(stream, pStream, nElementSize); - pStream = ReAllocElements(pStream, nNewCount, nElementSize); - m_streamSize[stream] = nNewCount; - - switch (stream) - { - case VERTICES: - pVertices = (CTriVertex*)pStream; - nVertCount = nNewCount; - vertSel.resize(nNewCount); - break; - case FACES: - pFaces = (CTriFace*)pStream; - nFacesCount = nNewCount; - faceSel.resize(nNewCount); - break; - case EDGES: - pEdges = (CTriEdge*)pStream; - nEdgeCount = nNewCount; - edgeSel.resize(nNewCount); - break; - case TEXCOORDS: - pUV = (SMeshTexCoord*)pStream; - nUVCount = nNewCount; - break; - case COLORS: - pColors = (SMeshColor*)pStream; - break; - case WEIGHTS: - pWeights = (float*)pStream; - break; - case LINES: - pLines = (CTriLine*)pStream; - break; - case WS_POSITIONS: - pWSVertices = (Vec3*)pStream; - break; - default: - assert(0); // unknown stream. - } - m_streamSize[stream] = nNewCount; -} - -// Set stream size. -void CTriMesh::GetStreamInfo(int stream, void*& pStream, int& nElementSize) const -{ - assert(stream >= 0 && stream < LAST_STREAM); - switch (stream) - { - case VERTICES: - pStream = pVertices; - nElementSize = sizeof(CTriVertex); - break; - case FACES: - pStream = pFaces; - nElementSize = sizeof(CTriFace); - break; - case EDGES: - pStream = pEdges; - nElementSize = sizeof(CTriEdge); - break; - case TEXCOORDS: - pStream = pUV; - nElementSize = sizeof(SMeshTexCoord); - break; - case COLORS: - pStream = pColors; - nElementSize = sizeof(SMeshColor); - break; - case WEIGHTS: - pStream = pWeights; - nElementSize = sizeof(float); - break; - case LINES: - pStream = pLines; - nElementSize = sizeof(CTriLine); - break; - case WS_POSITIONS: - pStream = pWSVertices; - nElementSize = sizeof(Vec3); - break; - default: - assert(0); // unknown stream. - } -} - -////////////////////////////////////////////////////////////////////////// -void* CTriMesh::ReAllocElements(void* old_ptr, int new_elem_num, int size_of_element) -{ - return realloc(old_ptr, new_elem_num * size_of_element); -} - -///////////////////////////////////////////////////////////////////////////////////// -inline int FindVertexInHash(const Vec3& vPosToFind, const CTriVertex* pVectors, std::vector& hash, float fEpsilon) -{ - for (uint32 i = 0; i < hash.size(); i++) - { - const Vec3& v0 = pVectors[hash[i]].pos; - const Vec3& v1 = vPosToFind; - if (fabsf(v0.y - v1.y) < fEpsilon && fabsf(v0.x - v1.x) < fEpsilon && fabsf(v0.z - v1.z) < fEpsilon) - { - return hash[i]; - } - } - return -1; -} - -///////////////////////////////////////////////////////////////////////////////////// -inline int FindTexCoordInHash(const SMeshTexCoord& coordToFind, const SMeshTexCoord* pCoords, std::vector& hash, float fEpsilon) -{ - for (uint32 i = 0; i < hash.size(); i++) - { - const SMeshTexCoord& t0 = pCoords[hash[i]]; - const SMeshTexCoord& t1 = coordToFind; - - if (t0.IsEquivalent(t1, fEpsilon)) - { - return hash[i]; - } - } - return -1; -} - - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::SharePositions() -{ - float fEpsilon = 0.0001f; - float fHashScale = 256.0f / MAX(bbox.GetSize().GetLength(), fEpsilon); - std::vector arrHashTable[256]; - - CTriVertex* pNewVerts = new CTriVertex[GetVertexCount()]; - SMeshColor* pNewColors = nullptr; - if (pColors) - { - pNewColors = new SMeshColor[GetVertexCount()]; - } - - int nLastIndex = 0; - for (int f = 0; f < GetFacesCount(); f++) - { - CTriFace& face = pFaces[f]; - for (int i = 0; i < 3; i++) - { - const Vec3& v = pVertices[face.v[i]].pos; - uint8 nHash = static_cast(RoundFloatToInt((v.x + v.y + v.z) * fHashScale)); - - int find = FindVertexInHash(v, pNewVerts, arrHashTable[nHash], fEpsilon); - if (find < 0) - { - pNewVerts[nLastIndex] = pVertices[face.v[i]]; - if (pColors) - { - pNewColors[nLastIndex] = pColors[face.v[i]]; - } - face.v[i] = nLastIndex; - // Reserve some space already. - arrHashTable[nHash].reserve(100); - arrHashTable[nHash].push_back(nLastIndex); - nLastIndex++; - } - else - { - face.v[i] = find; - } - } - } - - SetVertexCount(nLastIndex); - memcpy(pVertices, pNewVerts, nLastIndex * sizeof(CTriVertex)); - delete []pNewVerts; - - if (pColors) - { - SetColorsCount(nLastIndex); - memcpy(pColors, pNewColors, nLastIndex * sizeof(SMeshColor)); - delete []pNewColors; - } -} - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::ShareUV() -{ - float fEpsilon = 0.0001f; - float fHashScale = 256.0f; - std::vector arrHashTable[256]; - - SMeshTexCoord* pNewUV = new SMeshTexCoord[GetUVCount()]; - - int nLastIndex = 0; - for (int f = 0; f < GetFacesCount(); f++) - { - CTriFace& face = pFaces[f]; - for (int i = 0; i < 3; i++) - { - const Vec2 uv = pUV[face.uv[i]].GetUV(); - uint8 nHash = static_cast(RoundFloatToInt((uv.x + uv.y) * fHashScale)); - - int find = FindTexCoordInHash(pUV[face.uv[i]], pNewUV, arrHashTable[nHash], fEpsilon); - if (find < 0) - { - pNewUV[nLastIndex] = pUV[face.uv[i]]; - face.uv[i] = nLastIndex; - arrHashTable[nHash].reserve(100); - arrHashTable[nHash].push_back(nLastIndex); - nLastIndex++; - } - else - { - face.uv[i] = find; - } - } - } - - SetUVCount(nLastIndex); - memcpy(pUV, pNewUV, nLastIndex * sizeof(SMeshTexCoord)); - delete []pNewUV; -} - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::CalcFaceNormals() -{ - for (int i = 0; i < nFacesCount; i++) - { - CTriFace& face = pFaces[i]; - Vec3 p1 = pVertices[face.v[0]].pos; - Vec3 p2 = pVertices[face.v[1]].pos; - Vec3 p3 = pVertices[face.v[2]].pos; - face.normal = (p2 - p1).Cross(p3 - p1); - face.normal.Normalize(); - } -} - -#define TEX_EPS 0.001f -#define VER_EPS 0.001f - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::CopyStream(CTriMesh& fromMesh, int stream) -{ - void* pTrgStream = nullptr; - void* pSrcStream = nullptr; - int nElemSize = 0; - fromMesh.GetStreamInfo(stream, pSrcStream, nElemSize); - if (pSrcStream) - { - ReallocStream(stream, fromMesh.GetStreamSize(stream)); - GetStreamInfo(stream, pTrgStream, nElemSize); - memcpy(pTrgStream, pSrcStream, nElemSize * fromMesh.GetStreamSize(stream)); - } -} - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::Copy(CTriMesh& fromMesh, int nCopyFlags) -{ - streamSelMask = fromMesh.streamSelMask; - - if (nCopyFlags & COPY_VERTICES) - { - CopyStream(fromMesh, VERTICES); - } - if (nCopyFlags & COPY_FACES) - { - CopyStream(fromMesh, FACES); - } - if (nCopyFlags & COPY_EDGES) - { - CopyStream(fromMesh, EDGES); - } - if (nCopyFlags & COPY_TEXCOORDS) - { - CopyStream(fromMesh, TEXCOORDS); - } - if (nCopyFlags & COPY_COLORS) - { - CopyStream(fromMesh, COLORS); - } - if (nCopyFlags & COPY_WEIGHTS) - { - CopyStream(fromMesh, WEIGHTS); - } - if (nCopyFlags & COPY_LINES) - { - CopyStream(fromMesh, LINES); - } - - if (nCopyFlags & COPY_VERT_SEL) - { - vertSel = fromMesh.vertSel; - } - if (nCopyFlags & COPY_EDGE_SEL) - { - edgeSel = fromMesh.edgeSel; - } - if (nCopyFlags & COPY_FACE_SEL) - { - faceSel = fromMesh.faceSel; - } -} - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::UpdateEdges() -{ - SetEdgeCount(GetFacesCount() * 3); - - std::map edgemap; - - int nEdges = 0; - for (int i = 0; i < GetFacesCount(); i++) - { - CTriFace& face = pFaces[i]; - for (int j = 0; j < 3; j++) - { - int v0 = j; - int v1 = (j != 2) ? j + 1 : 0; - CTriEdge edge; - edge.flags = 0; - - // First vertex index must always be smaller. - if (face.v[v0] < face.v[v1]) - { - edge.v[0] = face.v[v0]; - edge.v[1] = face.v[v1]; - } - else - { - edge.v[0] = face.v[v1]; - edge.v[1] = face.v[v0]; - } - edge.face[0] = i; - edge.face[1] = -1; - int nedge = stl::find_in_map(edgemap, edge, -1); - if (nedge >= 0) - { - // Assign this face as a second member of the edge. - if (pEdges[nedge].face[1] < 0) - { - pEdges[nedge].face[1] = i; - } - - face.edge[j] = nedge; - } - else - { - edgemap[edge] = nEdges; - pEdges[nEdges] = edge; - face.edge[j] = nEdges; - nEdges++; - } - } - } - - SetEdgeCount(nEdges); -} - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::SoftSelection(const SSubObjSelOptions& options) -{ - int i; - int nVerts = GetVertexCount(); - CTriVertex* pVerts = pVertices; - - for (i = 0; i < nVerts; i++) - { - if (pWeights[i] == 1.0f) - { - const Vec3& vp = pVerts[i].pos; - for (int j = 0; j < nVerts; j++) - { - if (pWeights[j] != 1.0f) - { - if (vp.IsEquivalent(pVerts[j].pos, options.fSoftSelFalloff)) - { - float fDist = vp.GetDistance(pVerts[j].pos); - if (fDist < options.fSoftSelFalloff) - { - float fWeight = 1.0f - (fDist / options.fSoftSelFalloff); - if (fWeight > pWeights[j]) - { - pWeights[j] = fWeight; - } - } - } - } - } - } - } -} - -////////////////////////////////////////////////////////////////////////// -bool CTriMesh::UpdateSelection() -{ - bool bAnySelected = false; - if (selectionType == SO_ELEM_VERTEX) - { - for (int i = 0; i < GetVertexCount(); i++) - { - if (vertSel[i]) - { - bAnySelected = true; - pWeights[i] = 1.0f; - } - else - { - pWeights[i] = 0; - } - } - } - if (selectionType == SO_ELEM_EDGE) - { - // Clear weights. - for (int i = 0; i < GetVertexCount(); i++) - { - pWeights[i] = 0; - } - - for (int i = 0; i < GetEdgeCount(); i++) - { - if (edgeSel[i]) - { - bAnySelected = true; - CTriEdge& edge = pEdges[i]; - for (int j = 0; j < 2; j++) - { - pWeights[edge.v[j]] = 1.0f; - } - } - } - } - else if (selectionType == SO_ELEM_FACE) - { - // Clear weights. - for (int i = 0; i < GetVertexCount(); i++) - { - pWeights[i] = 0; - } - - for (int i = 0; i < GetFacesCount(); i++) - { - if (faceSel[i]) - { - bAnySelected = true; - CTriFace& face = pFaces[i]; - for (int j = 0; j < 3; j++) - { - pWeights[face.v[j]] = 1.0f; - } - } - } - } - return bAnySelected; -} - - -////////////////////////////////////////////////////////////////////////// -bool CTriMesh::ClearSelection() -{ - bool bWasSelected = false; - // Remove all selections. - int i; - for (i = 0; i < GetVertexCount(); i++) - { - pWeights[i] = 0; - } - streamSelMask = 0; - for (int ii = 0; ii < LAST_STREAM; ii++) - { - if (m_streamSel[ii] && !m_streamSel[ii]->is_zero()) - { - bWasSelected = true; - m_streamSel[ii]->clear(); - } - } - return bWasSelected; -} - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::GetEdgesByVertex(MeshElementsArray& inVertices, MeshElementsArray& outEdges) -{ - // Brute force algorithm using binary search. - // for every edge check if edge vertex is inside inVertices array. - std::sort(inVertices.begin(), inVertices.end()); - for (int i = 0; i < GetEdgeCount(); i++) - { - if (stl::binary_find(inVertices.begin(), inVertices.end(), static_cast(pEdges[i].v[0])) != inVertices.end()) - { - outEdges.push_back(i); - } - else if (stl::binary_find(inVertices.begin(), inVertices.end(), static_cast(pEdges[i].v[1])) != inVertices.end()) - { - outEdges.push_back(i); - } - } -} - -////////////////////////////////////////////////////////////////////////// -void CTriMesh::GetFacesByVertex(MeshElementsArray& inVertices, MeshElementsArray& outFaces) -{ - // Brute force algorithm using binary search. - // for every face check if face vertex is inside inVertices array. - std::sort(inVertices.begin(), inVertices.end()); - for (int i = 0; i < GetFacesCount(); i++) - { - if (stl::binary_find(inVertices.begin(), inVertices.end(), static_cast(pFaces[i].v[0])) != inVertices.end()) - { - outFaces.push_back(i); - } - else if (stl::binary_find(inVertices.begin(), inVertices.end(), static_cast(pFaces[i].v[1])) != inVertices.end()) - { - outFaces.push_back(i); - } - else if (stl::binary_find(inVertices.begin(), inVertices.end(), static_cast(pFaces[i].v[2])) != inVertices.end()) - { - outFaces.push_back(i); - } - } -} diff --git a/Code/Editor/Geometry/TriMesh.h b/Code/Editor/Geometry/TriMesh.h deleted file mode 100644 index a6c58b8f9d..0000000000 --- a/Code/Editor/Geometry/TriMesh.h +++ /dev/null @@ -1,238 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_GEOMETRY_TRIMESH_H -#define CRYINCLUDE_EDITOR_GEOMETRY_TRIMESH_H -#pragma once - -#include -#include "Util/bitarray.h" - -struct SSubObjSelOptions; - -typedef std::vector MeshElementsArray; - -////////////////////////////////////////////////////////////////////////// -// Vertex used in the TriMesh. -////////////////////////////////////////////////////////////////////////// -struct CTriVertex -{ - Vec3 pos; - //float weight; // Selection weight in 0-1 range. -}; - -////////////////////////////////////////////////////////////////////////// -// Triangle face used by the Triangle mesh. -////////////////////////////////////////////////////////////////////////// -struct CTriFace -{ - uint32 v[3]; // Indices to vertices array. - uint32 uv[3]; // Indices to texture coordinates array. - Vec3 n[3]; // Vertex normals at face vertices. - Vec3 normal; // Face normal. - uint32 edge[3]; // Indices to the face edges. - unsigned char MatID; // Index of face sub material. - unsigned char flags; // see ETriMeshFlags -}; - -////////////////////////////////////////////////////////////////////////// -// Mesh edge. -////////////////////////////////////////////////////////////////////////// -struct CTriEdge -{ - uint32 v[2]; // Indices to edge vertices. - int face[2]; // Indices to edge faces (-1 if no face). - uint32 flags; // see ETriMeshFlags - - CTriEdge() {} - bool operator==(const CTriEdge& edge) const - { - if ((v[0] == edge.v[0] && v[1] == edge.v[1]) || - (v[0] == edge.v[1] && v[1] == edge.v[0])) - { - return true; - } - return false; - } - bool operator!=(const CTriEdge& edge) const { return !(*this == edge); } - bool operator<(const CTriEdge& edge) const { return (*(uint64*)v < *(uint64*)edge.v); } - bool operator>(const CTriEdge& edge) const { return (*(uint64*)v > *(uint64*)edge.v); } -}; - -////////////////////////////////////////////////////////////////////////// -// Mesh line. -////////////////////////////////////////////////////////////////////////// -struct CTriLine -{ - uint32 v[2]; // Indices to edge vertices. - - CTriLine() {} - bool operator==(const CTriLine& edge) const - { - if ((v[0] == edge.v[0] && v[1] == edge.v[1]) || - (v[0] == edge.v[1] && v[1] == edge.v[0])) - { - return true; - } - return false; - } - bool operator!=(const CTriLine& edge) const { return !(*this == edge); } - bool operator<(const CTriLine& edge) const { return (*(uint64*)v < *(uint64*)edge.v); } - bool operator>(const CTriLine& edge) const { return (*(uint64*)v > *(uint64*)edge.v); } -}; - -////////////////////////////////////////////////////////////////////////// -struct CTriMeshPoly -{ - std::vector v; // Indices to vertices array. - std::vector uv; // Indices to texture coordinates array. - std::vector n; // Vertex normals at face vertices. - Vec3 normal; // Polygon normal. - uint32 edge[3]; // Indices to the face edges. - unsigned char MatID; // Index of face sub material. - unsigned char flags; // optional flags. -}; - -////////////////////////////////////////////////////////////////////////// -// CTriMesh is used in the Editor as a general purpose editable triangle mesh. -////////////////////////////////////////////////////////////////////////// -class CTriMesh -{ -public: - enum EStream - { - VERTICES, - FACES, - EDGES, - TEXCOORDS, - COLORS, - WEIGHTS, - LINES, - WS_POSITIONS, - LAST_STREAM, - }; - enum ECopyFlags - { - COPY_VERTICES = BIT(1), - COPY_FACES = BIT(2), - COPY_EDGES = BIT(3), - COPY_TEXCOORDS = BIT(4), - COPY_COLORS = BIT(5), - COPY_VERT_SEL = BIT(6), - COPY_EDGE_SEL = BIT(7), - COPY_FACE_SEL = BIT(8), - COPY_WEIGHTS = BIT(9), - COPY_LINES = BIT(10), - COPY_ALL = 0xFFFF, - }; - // geometry data - CTriFace* pFaces; - CTriEdge* pEdges; - CTriVertex* pVertices; - SMeshTexCoord* pUV; - SMeshColor* pColors; // If allocated same size as pVerts array. - Vec3* pWSVertices; // World space vertices. - float* pWeights; - CTriLine* pLines; - - int nFacesCount; - int nVertCount; - int nUVCount; - int nEdgeCount; - int nLinesCount; - - AABB bbox; - - ////////////////////////////////////////////////////////////////////////// - // Selections. - ////////////////////////////////////////////////////////////////////////// - CBitArray vertSel; - CBitArray edgeSel; - CBitArray faceSel; - // Every bit of the selection mask correspond to a stream, if bit is set this stream have some elements selected - int streamSelMask; - - // Selection element type. - // see ESubObjElementType - int selectionType; - - ////////////////////////////////////////////////////////////////////////// - // Vertices of the front facing triangles. - CBitArray frontFacingVerts; - - ////////////////////////////////////////////////////////////////////////// - // Functions. - ////////////////////////////////////////////////////////////////////////// - CTriMesh(); - ~CTriMesh(); - - int GetFacesCount() const { return nFacesCount; } - int GetVertexCount() const { return nVertCount; } - int GetUVCount() const { return nUVCount; } - int GetEdgeCount() const { return nEdgeCount; } - int GetLinesCount() const { return nLinesCount; } - - ////////////////////////////////////////////////////////////////////////// - void SetFacesCount(int nNewCount) { ReallocStream(FACES, nNewCount); } - void SetVertexCount(int nNewCount) - { - ReallocStream(VERTICES, nNewCount); - if (pColors) - { - ReallocStream(COLORS, nNewCount); - } - ReallocStream(WEIGHTS, nNewCount); - } - void SetColorsCount(int nNewCount) { ReallocStream(COLORS, nNewCount); } - void SetUVCount(int nNewCount) { ReallocStream(TEXCOORDS, nNewCount); } - void SetEdgeCount(int nNewCount) { ReallocStream(EDGES, nNewCount); } - void SetLinesCount(int nNewCount) { ReallocStream(LINES, nNewCount); } - - void ReallocStream(int stream, int nNewCount); - void GetStreamInfo(int stream, void*& pStream, int& nElementSize) const; - int GetStreamSize(int stream) const { return m_streamSize[stream]; }; - - // Calculate per face normal. - void CalcFaceNormals(); - - ////////////////////////////////////////////////////////////////////////// - // Welding functions. - ////////////////////////////////////////////////////////////////////////// - void SharePositions(); - void ShareUV(); - ////////////////////////////////////////////////////////////////////////// - // Recreate edges of the mesh. - void UpdateEdges(); - - void Copy(CTriMesh& fromMesh, int nCopyFlags = COPY_ALL); - - ////////////////////////////////////////////////////////////////////////// - // Sub-object selection specific methods. - ////////////////////////////////////////////////////////////////////////// - // Return true if something is selected. - bool UpdateSelection(); - // Clear all selections, return true if something was selected. - bool ClearSelection(); - void SoftSelection(const SSubObjSelOptions& options); - CBitArray* GetStreamSelection(int nStream) { return m_streamSel[nStream]; }; - // Returns true if specified stream have any selected elements. - bool StreamHaveSelection(int nStream) { return streamSelMask & (1 << nStream); } - void GetEdgesByVertex(MeshElementsArray& inVertices, MeshElementsArray& outEdges); - void GetFacesByVertex(MeshElementsArray& inVertices, MeshElementsArray& outFaces); - -private: - void* ReAllocElements(void* old_ptr, int new_elem_num, int size_of_element); - void CopyStream(CTriMesh& fromMesh, int stream); - - // For internal use. - int m_streamSize[LAST_STREAM]; - CBitArray* m_streamSel[LAST_STREAM]; -}; - -#endif // CRYINCLUDE_EDITOR_GEOMETRY_TRIMESH_H diff --git a/Code/Editor/IEditor.h b/Code/Editor/IEditor.h index c6f72a7dbc..90f1b63f55 100644 --- a/Code/Editor/IEditor.h +++ b/Code/Editor/IEditor.h @@ -44,7 +44,6 @@ class CMusicManager; struct IEditorParticleManager; class CEAXPresetManager; class CErrorReport; -class CBaseLibraryItem; class ICommandManager; class CEditorCommandManager; class CHyperGraphManager; @@ -52,10 +51,7 @@ class CConsoleSynchronization; class CUIEnumsDatabase; struct ISourceControl; struct IEditorClassFactory; -struct IDataBaseItem; struct ITransformManipulator; -struct IDataBaseManager; -class IFacialEditor; class CDialog; #if defined(AZ_PLATFORM_WINDOWS) class C3DConnexionDriver; @@ -69,7 +65,6 @@ class CSelectionTreeManager; struct SEditorSettings; class CGameExporter; class IAWSResourceManager; -struct IEditorPanelUtils; namespace WinWidget { @@ -83,8 +78,6 @@ struct IEventLoopHook; struct IErrorReport; // Vladimir@conffx struct IFileUtil; // Vladimir@conffx struct IEditorLog; // Vladimir@conffx -struct IEditorMaterialManager; // Vladimir@conffx -struct IBaseLibraryManager; // Vladimir@conffx struct IImageUtil; // Vladimir@conffx struct IEditorParticleUtils; // Leroy@conffx struct ILogFile; // Vladimir@conffx @@ -520,14 +513,8 @@ struct IEditor //! Get access to object manager. virtual struct IObjectManager* GetObjectManager() = 0; virtual CSettingsManager* GetSettingsManager() = 0; - //! Get DB manager that own items of specified type. - virtual IDataBaseManager* GetDBItemManager(EDataBaseItemType itemType) = 0; - virtual IBaseLibraryManager* GetMaterialManagerLibrary() = 0; // Vladimir@conffx - virtual IEditorMaterialManager* GetIEditorMaterialManager() = 0; // Vladimir@Conffx //! Returns IconManager. virtual IIconManager* GetIconManager() = 0; - //! Get Panel Editor Utilities - virtual IEditorPanelUtils* GetEditorPanelUtils() = 0; //! Get Music Manager. virtual CMusicManager* GetMusicManager() = 0; virtual float GetTerrainElevation(float x, float y) = 0; diff --git a/Code/Editor/IEditorImpl.cpp b/Code/Editor/IEditorImpl.cpp index e5df6be58e..38006c6fca 100644 --- a/Code/Editor/IEditorImpl.cpp +++ b/Code/Editor/IEditorImpl.cpp @@ -81,9 +81,6 @@ AZ_POP_DISABLE_WARNING // AWSNativeSDK #include -#include "IEditorPanelUtils.h" -#include "EditorPanelUtils.h" - #include "Core/QtEditorApplication.h" // for Editor::EditorQtApplication static CCryEditDoc * theDocument; @@ -143,7 +140,6 @@ CEditorImpl::CEditorImpl() , m_QtApplication(static_cast(qApp)) , m_pImageUtil(nullptr) , m_pLogFile(nullptr) - , m_panelEditorUtils(nullptr) { // note that this is a call into EditorCore.dll, which stores the g_pEditorPointer for all shared modules that share EditorCore.dll // this means that they don't need to do SetIEditor(...) themselves and its available immediately @@ -167,8 +163,6 @@ CEditorImpl::CEditorImpl() m_pDisplaySettings->LoadRegistry(); m_pPluginManager = new CPluginManager; - m_panelEditorUtils = CreateEditorPanelUtils(); - m_pObjectManager = new CObjectManager; m_pViewManager = new CViewManager; m_pIconManager = new CIconManager; @@ -301,8 +295,6 @@ CEditorImpl::~CEditorImpl() SAFE_DELETE(m_pViewManager) SAFE_DELETE(m_pObjectManager) // relies on prefab manager - SAFE_DELETE(m_panelEditorUtils); - // some plugins may be exporter - this must be above plugin manager delete. SAFE_DELETE(m_pExportManager); @@ -900,11 +892,6 @@ void CEditorImpl::CloseView(const GUID& classId) } } -IDataBaseManager* CEditorImpl::GetDBItemManager([[maybe_unused]] EDataBaseItemType itemType) -{ - return nullptr; -} - bool CEditorImpl::SelectColor(QColor& color, QWidget* parent) { const AZ::Color c = AzQtComponents::fromQColor(color); @@ -1445,7 +1432,7 @@ ISourceControl* CEditorImpl::GetSourceControl() { IClassDesc* pClass = classes[i]; ISourceControl* pSCM = nullptr; - HRESULT hRes = pClass->QueryInterface(__uuidof(ISourceControl), (void**)&pSCM); + HRESULT hRes = pClass->QueryInterface(__az_uuidof(ISourceControl), (void**)&pSCM); if (!FAILED(hRes) && pSCM) { m_pSourceControl = pSCM; @@ -1632,18 +1619,6 @@ SEditorSettings* CEditorImpl::GetEditorSettings() return &gSettings; } -// Vladimir@Conffx -IBaseLibraryManager* CEditorImpl::GetMaterialManagerLibrary() -{ - return nullptr; -} - -// Vladimir@Conffx -IEditorMaterialManager* CEditorImpl::GetIEditorMaterialManager() -{ - return nullptr; -} - IImageUtil* CEditorImpl::GetImageUtil() { return m_pImageUtil; @@ -1658,8 +1633,3 @@ void CEditorImpl::DestroyQMimeData(QMimeData* data) const { delete data; } - -IEditorPanelUtils* CEditorImpl::GetEditorPanelUtils() -{ - return m_panelEditorUtils; -} diff --git a/Code/Editor/IEditorImpl.h b/Code/Editor/IEditorImpl.h index 4976c0c1ca..7867912941 100644 --- a/Code/Editor/IEditorImpl.h +++ b/Code/Editor/IEditorImpl.h @@ -157,7 +157,6 @@ public: void LockSelection(bool bLock) override; bool IsSelectionLocked() override; - IDataBaseManager* GetDBItemManager(EDataBaseItemType itemType) override; CMusicManager* GetMusicManager() override { return m_pMusicManager; }; IEditorFileMonitor* GetFileMonitor() override; @@ -294,11 +293,8 @@ public: void RegisterObjectContextMenuExtension(TContextMenuExtensionFunc func) override; SSystemGlobalEnvironment* GetEnv() override; - IBaseLibraryManager* GetMaterialManagerLibrary() override; // Vladimir@Conffx - IEditorMaterialManager* GetIEditorMaterialManager() override; // Vladimir@Conffx IImageUtil* GetImageUtil() override; // Vladimir@conffx SEditorSettings* GetEditorSettings() override; - IEditorPanelUtils* GetEditorPanelUtils() override; ILogFile* GetLogFile() override { return m_pLogFile; } void UnloadPlugins() override; @@ -356,7 +352,6 @@ protected: CErrorsDlg* m_pErrorsDlg; //! Source control interface. ISourceControl* m_pSourceControl; - IEditorPanelUtils* m_panelEditorUtils; CSelectionTreeManager* m_pSelectionTreeManager; diff --git a/Code/Editor/IEditorPanelUtils.h b/Code/Editor/IEditorPanelUtils.h deleted file mode 100644 index 4649213ae7..0000000000 --- a/Code/Editor/IEditorPanelUtils.h +++ /dev/null @@ -1,131 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - */ - -#ifndef CRYINCLUDE_CRYEDITOR_IPANELEDITORUTILS_H -#define CRYINCLUDE_CRYEDITOR_IPANELEDITORUTILS_H -#pragma once - -#include "Cry_Vector3.h" - -#include "DisplaySettings.h" -#include "Include/IDisplayViewport.h" -#include "Include/IIconManager.h" -#include -#include -#include -#include - -class CBaseObject; -class CViewport; -class IQToolTip; - -struct HotKey -{ - HotKey() - : path("") - , sequence(QKeySequence()) - { - } - void CopyFrom(const HotKey& other) - { - path = other.path; - sequence = other.sequence; - } - void SetPath(const char* _path) - { - path = QString(_path); - } - void SetSequenceFromString(const char* _sequence) - { - sequence = QKeySequence::fromString(_sequence); - } - void SetSequence(const QKeySequence& other) - { - sequence = other; - } - bool IsMatch(QString _path) - { - return path.compare(_path, Qt::CaseInsensitive) == 0; - } - bool IsMatch(QKeySequence _sequence) - { - return sequence.matches(_sequence); - } - bool operator < (const HotKey& other) const - { - //split the paths into lists compare per level - QStringList m_categories = path.split('.'); - QStringList o_categories = other.path.split('.'); - int m_catSize = m_categories.size(); - int o_catSize = o_categories.size(); - int size = (m_catSize < o_catSize) ? m_catSize : o_catSize; - - //sort categories to keep them together - for (int i = 0; i < size; i++) - { - if (m_categories[i] < o_categories[i]) - { - return true; - } - if (m_categories[i] > o_categories[i]) - { - return false; - } - } - //if comparing a category and a item in that category the category is < item - return m_catSize > o_catSize; - } - QKeySequence sequence; - QString path; -}; - -struct IEditorPanelUtils -{ - virtual ~IEditorPanelUtils() {} - virtual void SetViewportDragOperation(void(*)(CViewport* viewport, int dragPointX, int dragPointY, void* custom), void* custom) = 0; - - //PREVIEW WINDOW UTILS//////////////////////////////////////////////////// - virtual int PreviewWindow_GetDisplaySettingsDebugFlags(CDisplaySettings* settings) = 0; - virtual void PreviewWindow_SetDisplaySettingsDebugFlags(CDisplaySettings* settings, int flags) = 0; - - //HOTKEY UTILS//////////////////////////////////////////////////////////// - virtual bool HotKey_Import() = 0; - virtual void HotKey_Export() = 0; - virtual QKeySequence HotKey_GetShortcut(const char* path) = 0; - virtual bool HotKey_IsPressed(const QKeyEvent* event, const char* path) = 0; - virtual bool HotKey_IsPressed(const QShortcutEvent* event, const char* path) = 0; - virtual bool HotKey_LoadExisting() = 0; - virtual void HotKey_SaveCurrent() = 0; - virtual void HotKey_BuildDefaults() = 0; - virtual void HotKey_SetKeys(QVector keys) = 0; - virtual QVector HotKey_GetKeys() = 0; - virtual QString HotKey_GetPressedHotkey(const QKeyEvent* event) = 0; - virtual QString HotKey_GetPressedHotkey(const QShortcutEvent* event) = 0; - virtual void HotKey_SetEnabled(bool val) = 0; - virtual bool HotKey_IsEnabled() const = 0; - - //TOOLTIP UTILS/////////////////////////////////////////////////////////// - - //! Loads a table of tooltip configuration data from an xml file. - virtual void ToolTip_LoadConfigXML(QString filepath) = 0; - - //! Initializes a QToolTipWidget from loaded configuration data (see ToolTip_LoadConfigXML()) - //! \param tooltip Will be initialized using loaded configuration data - //! \param path Variable serialization path. Will be used as the key for looking up data in the configuration table. (ex: "Rotation.Rotation_Rate_X") - //! \param option Name of a sub-option of the variable specified by "path". (ex: "Emitter_Strength" will look up the tooltip data for "Rotation.Rotation_Rate_X.Emitter_Strength") - //! \param optionalData The argument to be used with "special_content" feature. See ToolTip_GetSpecialContentType() and QToolTipWidget::AddSpecialContent(). - //! \param isEnabled If false, the tooltip will indicate the reason why the widget is disabled. - virtual void ToolTip_BuildFromConfig(IQToolTip* tooltip, QString path, QString option, QString optionalData = "", bool isEnabled = true) = 0; - - virtual QString ToolTip_GetTitle(QString path, QString option = "") = 0; - virtual QString ToolTip_GetContent(QString path, QString option = "") = 0; - virtual QString ToolTip_GetSpecialContentType(QString path, QString option = "") = 0; - virtual QString ToolTip_GetDisabledContent(QString path, QString option = "") = 0; -}; - - -#endif diff --git a/Code/Editor/Include/HitContext.h b/Code/Editor/Include/HitContext.h index ceff0adb22..b49117bb60 100644 --- a/Code/Editor/Include/HitContext.h +++ b/Code/Editor/Include/HitContext.h @@ -17,7 +17,6 @@ class CGizmo; class CBaseObject; struct IDisplayViewport; -class CDeepSelection; struct AABB; #include @@ -105,8 +104,6 @@ struct HitContext CBaseObject* object; //! gizmo object that have been hit. CGizmo* gizmo; - //! for deep selection mode - CDeepSelection* pDeepSelection; //! For linking tool const char* name; //! true if this hit was from the object icon @@ -131,7 +128,6 @@ struct HitContext bIgnoreAxis = false; bOnlyGizmo = false; bUseSelectionHelpers = false; - pDeepSelection = 0; name = nullptr; iconHit = false; } diff --git a/Code/Editor/Include/IAnimationCompressionManager.h b/Code/Editor/Include/IAnimationCompressionManager.h deleted file mode 100644 index 64cebf620a..0000000000 --- a/Code/Editor/Include/IAnimationCompressionManager.h +++ /dev/null @@ -1,20 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IANIMATIONCOMPRESSIONMANAGER_H -#define CRYINCLUDE_EDITOR_INCLUDE_IANIMATIONCOMPRESSIONMANAGER_H -#pragma once - -struct IAnimationCompressionManager -{ - virtual bool IsEnabled() const = 0; - virtual void UpdateLocalAnimations() = 0; -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_IANIMATIONCOMPRESSIONMANAGER_H diff --git a/Code/Editor/Include/IAssetItem.h b/Code/Editor/Include/IAssetItem.h deleted file mode 100644 index ff80331af5..0000000000 --- a/Code/Editor/Include/IAssetItem.h +++ /dev/null @@ -1,433 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -// Description : Standard interface for asset display in the asset browser, -// this header should be used to create plugins. -// The method Release of this interface should NOT be called. -// Instead, the FreeData from the database (from IAssetItemDatabase) should -// be used as it will safely release all the items from the database. -// It is still possible to call the release method, but this is not the -// recomended method, specially for usage outside of the plugins because there -// is no guarantee that a the asset will be properly removed from the database -// manager. - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IASSETITEM_H -#define CRYINCLUDE_EDITOR_INCLUDE_IASSETITEM_H -#pragma once - -struct IAssetItemDatabase; - -namespace AssetViewer -{ - // Used in GetAssetFieldValue for each asset type to check if field name is the right one - inline bool IsFieldName(const char* pIncomingFieldName, const char* pFieldName) - { - return !strncmp(pIncomingFieldName, pFieldName, strlen(pIncomingFieldName)); - } -} - -// Description: -// This interface allows the programmer to extend asset display types visible in the asset browser. -struct IAssetItem - : public IUnknown -{ - DEFINE_UUID(0x04F20346, 0x2EC3, 0x43f2, 0xBD, 0xA1, 0x2C, 0x0B, 0x97, 0x76, 0xF3, 0x84); - - // The supported asset flags - enum EAssetFlags - { - // asset is visible in the database for filtering and sorting (not asset view control related) - eFlag_Visible = BIT(0), - // the asset is loaded - eFlag_Loaded = BIT(1), - // the asset is loaded - eFlag_Cached = BIT(2), - // the asset is selected in a selection set - eFlag_Selected = BIT(3), - // this asset is invalid, no thumb is shown/available - eFlag_Invalid = BIT(4), - // this asset has some errors/warnings, in the asset browser it will show some blinking/red elements - // and the user can check out the errors. Error text will be fetched using GetAssetFieldValue( "errors", &someStringVar ) - eFlag_HasErrors = BIT(5), - // this flag is set when the asset is rendering its contents using GDI, and not the engine's rendering capabilities - // (this flags is used as hint for the preview tool, which will use a double-buffer canvas if this flag is set, - // and send a memory HDC to the OnBeginPreview method, for drawing of the asset) - eFlag_UseGdiRendering = BIT(6), - // set if this asset is draggable into the render viewports, and can be created there - eFlag_CanBeDraggedInViewports = BIT(7), - // set if this asset can be moved after creation, otherwise the asset instance will just be created where user clicked - eFlag_CanBeMovedAfterDroppedIntoViewport = BIT(8), - // the asset thumbnail image is loaded - eFlag_ThumbnailLoaded = BIT(9), - // the asset thumbnail image is loaded - eFlag_UsedInLevel = BIT(10) - }; - - // Asset field name and field values map - typedef std::map < QString/*fieldName*/, QString/*value*/ > TAssetFieldValuesMap; - // Dependency category names and corresponding files map, example: "Textures"=>{ "foam.dds","water.dds","normal.dds" } - typedef std::map < QString/*dependencyCategory*/, std::set/*dependency filenames*/ > TAssetDependenciesMap; - - virtual ~IAssetItem() { - } - - // Description: - // Get the hash number/key used for database thumbnail and info records management - virtual uint32 GetHash() const = 0; - // Description: - // Set the hash number/key used for database thumbnail and info records management - virtual void SetHash(uint32 hash) = 0; - // Description: - // Get the owner database for this asset - // Return Value: - // The owner database for this asset - // See Also: - // SetOwnerDatabase() - virtual IAssetItemDatabase* GetOwnerDatabase() const = 0; - // Description: - // Set the owner database for this asset - // Arguments: - // piOwnerDisplayDatabase - the owner database - // See Also: - // GetOwnerDatabase() - virtual void SetOwnerDatabase(IAssetItemDatabase* pOwnerDisplayDatabase) = 0; - // Description: - // Get the asset's dependency files / objects - // Return Value: - // The vector with filenames which this asset is dependent upon, ex.: ["Textures"].(vector of textures) - virtual const TAssetDependenciesMap& GetDependencies() const = 0; - // Description: - // Set the file size of this asset in bytes - // Arguments: - // aSize - size of the file in bytes - // See Also: - // GetFileSize() - virtual void SetFileSize(quint64 aSize) = 0; - // Description: - // Get the file size of this asset in bytes - // Return Value: - // The file size of this asset in bytes - // See Also: - // SetFileSize() - virtual quint64 GetFileSize() const = 0; - // Description: - // Set asset filename (extension included and no path) - // Arguments: - // pName - the asset filename (extension included and no path) - // See Also: - // GetFilename() - virtual void SetFilename(const char* pName) = 0; - // Description: - // Get asset filename (extension included and no path) - // Return Value: - // The asset filename (extension included and no path) - // See Also: - // SetFilename() - virtual QString GetFilename() const = 0; - // Description: - // Set the asset's relative path - // Arguments: - // pName - file's relative path - // See Also: - // GetRelativePath() - virtual void SetRelativePath(const char* pName) = 0; - // Description: - // Get the asset's relative path - // Return Value: - // The asset's relative path - // See Also: - // SetRelativePath() - virtual QString GetRelativePath() const = 0; - // Description: - // Set the file extension ( dot(s) must be included ) - // Arguments: - // pExt - the file's extension - // See Also: - // GetFileExtension() - virtual void SetFileExtension(const char* pExt) = 0; - // Description: - // Get the file extension ( dot(s) included ) - // Return Value: - // The file extension ( dot(s) included ) - // See Also: - // SetFileExtension() - virtual QString GetFileExtension() const = 0; - // Description: - // Get the asset flags, with values from IAssetItem::EAssetFlags - // Return Value: - // The asset flags, with values from IAssetItem::EAssetFlags - // See Also: - // SetFlags(), SetFlag(), IsFlagSet() - virtual UINT GetFlags() const = 0; - // Description: - // Set the asset flags - // Arguments: - // aFlags - flags, OR-ed values from IAssetItem::EAssetFlags - // See Also: - // GetFlags(), SetFlag(), IsFlagSet() - virtual void SetFlags(UINT aFlags) = 0; - // Description: - // Set/clear a single flag bit for the asset - // Arguments: - // aFlag - the flag to set/clear, with values from IAssetItem::EAssetFlags - // See Also: - // GetFlags(), SetFlags(), IsFlagSet() - virtual void SetFlag(EAssetFlags aFlag, bool bSet = true) = 0; - // Description: - // Check if a specified flag is set - // Arguments: - // aFlag - the flag to check, with values from IAssetItem::EAssetFlags - // Return Value: - // True if the flag is set - // See Also: - // GetFlags(), SetFlags(), SetFlag() - virtual bool IsFlagSet(EAssetFlags aFlag) const = 0; - // Description: - // Set this asset's index; used in sorting, selections, and to know where an asset is in the current list - // Arguments: - // aIndex - the asset's index - // See Also: - // GetIndex() - virtual void SetIndex(UINT aIndex) = 0; - // Description: - // Get the asset's index in the current list - // Return Value: - // The asset's index in the current list - // See Also: - // SetIndex() - virtual UINT GetIndex() const = 0; - // Description: - // Get the asset's field raw data value into a user location, you must check the field's type ( from asset item's owner database ) - // before using this function and send the correct pointer to destination according to the type ( int8, float32, string, etc. ) - // Arguments: - // pFieldName - the asset field name to query the value for - // pDest - the destination variable address, must be the same type as the field type - // Return Value: - // True if the asset field name is found and the value is returned correctly - // See Also: - // SetAssetFieldValue() - virtual QVariant GetAssetFieldValue(const char* pFieldName) const = 0; - // Description: - // Set the asset's field raw data value from a user location, you must check the field's type ( from asset item's owner database ) - // before using this function and send the correct pointer to source according to the type ( int8, float32, string, etc. ) - // Arguments: - // pFieldName - the asset field name to set the value for - // pSrc - the source variable address, must be the same type as the field type - // Return Value: - // True if the asset field name is found and the value is set correctly - // See Also: - // GetAssetFieldValue() - virtual bool SetAssetFieldValue(const char* pFieldName, void* pSrc) = 0; - // Description: - // Get the drawing rectangle for the asset's thumb ( absolute viewer canvas location ) - // Arguments: - // rstDrawingRectangle - destination location to set with the asset's thumbnail rectangle location - // See Also: - // SetDrawingRectangle() - virtual void GetDrawingRectangle(QRect& rstDrawingRectangle) const = 0; - // Description: - // Set the drawing rectangle for the asset's thumb ( absolute viewer canvas location ) - // Arguments: - // crstDrawingRectangle - source to set the asset's thumbnail rectangle - // See Also: - // GetDrawingRectangle() - virtual void SetDrawingRectangle(const QRect& crstDrawingRectangle) = 0; - // Description: - // Checks if the given 2D point is inside the asset's thumb rectangle - // Arguments: - // nX - mouse pointer position on X axis, relative to the asset viewer control - // nY - mouse pointer position on Y axis, relative to the asset viewer control - // Return Value: - // True if the given 2D point is inside the asset's thumb rectangle - // See Also: - // HitTest(CRect) - virtual bool HitTest(int nX, int nY) const = 0; - // Description: - // Checks if the given rectangle intersects the asset thumb's rectangle - // Arguments: - // nX - mouse pointer position on X axis, relative to the asset viewer control - // nY - mouse pointer position on Y axis, relative to the asset viewer control - // Return Value: - // True if the given rectangle intersects the asset thumb's rectangle - // See Also: - // HitTest(int nX,int nY) - virtual bool HitTest(const QRect& roTestRect) const = 0; - // Description: - // When user drags this asset item into a viewport, this method is called when the dragging operation ends - // and the mouse button is released, for the asset to return an instance of the asset object to be placed in the level - // Arguments: - // aX - instance's X position component in world coordinates - // aY - instance's Y position component in world coordinates - // aZ - instance's Z position component in world coordinates - // Return Value: - // The newly created asset instance (Example: BrushObject*) - // See Also: - // MoveInstanceInViewport() - virtual void* CreateInstanceInViewport(float aX, float aY, float aZ) = 0; - // Description: - // When the mouse button is released after level object creation, the user now can move the mouse - // and move the asset instance in the 3D world - // Arguments: - // pDraggedObject - the actual entity or brush object (CBaseObject* usually) to be moved around with the mouse - // returned by the CreateInstanceInViewport() - // aNewX - the new X world coordinates of the asset instance - // aNewY - the new Y world coordinates of the asset instance - // aNewZ - the new Z world coordinates of the asset instance - // Return Value: - // True if asset instance was moved properly - // See Also: - // CreateInstanceInViewport() - virtual bool MoveInstanceInViewport(const void* pDraggedObject, float aNewX, float aNewY, float aNewZ) = 0; - // Description: - // This will be called when the user presses ESCAPE key when dragging the asset in the viewport, you must delete the given object - // because the creation was aborted - // Arguments: - // pDraggedObject - the asset instance to be deleted ( you must cast to the needed type, and delete it properly ) - // See Also: - // CreateInstanceInViewport() - virtual void AbortCreateInstanceInViewport(const void* pDraggedObject) = 0; - // Description: - // This method is used to cache/load asset's data, so it can be previewed/rendered - // Return Value: - // True if the asset was successfully cached - // See Also: - // UnCache() - virtual bool Cache() = 0; - // Description: - // This method is used to force cache/load asset's data, so it can be previewed/rendered - // Return Value: - // True if the asset was successfully forced cached - // See Also: - // UnCache(), Cache() - virtual bool ForceCache() = 0; - // Description: - // This method is used to load the thumbnail image of the asset - // Return Value: - // True if thumb loaded ok - // See Also: - // UnloadThumbnail() - virtual bool LoadThumbnail() = 0; - // Description: - // This method is used to unload the thumbnail image of the asset - // See Also: - // LoadThumbnail() - virtual void UnloadThumbnail() = 0; - // Description: - // This is called when the asset starts to be previewed in full detail, so here you can load the whole asset, in fine detail - // ( textures are fully loaded, models etc. ). It is called once, when the Preview dialog is shown - // Arguments: - // hPreviewWnd - the window handle of the quick preview dialog - // hMemDC - the memory DC used to render assets that can render themselves in the DC, otherwise they will render in the dialog's HWND - // See Also: - // OnEndPreview(), GetCustomPreviewPanelHeader() - virtual void OnBeginPreview(QWidget* hPreviewWnd) = 0; - // Description: - // Called when the Preview dialog is closed, you may release the detail asset data here - // See Also: - // OnBeginPreview(), GetCustomPreviewPanelHeader() - virtual void OnEndPreview() = 0; - // Description: - // If the asset has a special preview panel with utility controls, to be placed at the top of the Preview window, it can return an child dialog window - // otherwise it can return nullptr, if no panel is available - // Arguments: - // pParentWnd - a valid CDialog*, or nullptr - // Return Value: - // A valid child dialog window handle, if this asset wants to have a custom panel in the top side of the Asset Preview window, - // otherwise it can return nullptr, if no panel is available - // See Also: - // OnBeginPreview(), OnEndPreview() - virtual QWidget* GetCustomPreviewPanelHeader(QWidget* pParentWnd) = 0; - virtual QWidget* GetCustomPreviewPanelFooter(QWidget* pParentWnd) = 0; - // Description: - // Used when dragging/rotate/zoom a model, or other asset that can support preview - // Arguments: - // hRenderWindow - the rendering window handle - // rstViewport - the viewport rectangle - // aMouseX - the render window relative mouse pointer X coordinate - // aMouseY - the render window relative mouse pointer Y coordinate - // aMouseDeltaX - the X coordinate delta between two mouse movements - // aMouseDeltaY - the Y coordinate delta between two mouse movements - // aMouseWheelDelta - the mouse wheel scroll delta/step - // aKeyFlags - the key flags, see WM_LBUTTONUP - // See Also: - // OnPreviewRenderKeyEvent() - virtual void PreviewRender( - QWidget* hRenderWindow, - const QRect& rstViewport, - int aMouseX = 0, int aMouseY = 0, - int aMouseDeltaX = 0, int aMouseDeltaY = 0, - int aMouseWheelDelta = 0, UINT aKeyFlags = 0) = 0; - // Description: - // This is called when the user manipulates the assets in interactive render and a key is pressed ( with down or up state ) - // Arguments: - // bKeyDown - true if this is a WM_KEYDOWN event, else it is a WM_KEYUP event - // aChar - the char/key code pressed/released - // aKeyFlags - the key flags, compatible with WM_KEYDOWN/UP events - // See Also: - // InteractiveRender() - virtual void OnPreviewRenderKeyEvent(bool bKeyDown, UINT aChar, UINT aKeyFlags) = 0; - // Description: - // Called when user clicked once on the thumb image - // Arguments: - // point - mouse coordinates relative to the thumbnail rectangle - // aKeyFlags - the key flags, see WM_LBUTTONDOWN - // See Also: - // OnThumbDblClick() - virtual void OnThumbClick(const QPoint& point, Qt::MouseButtons buttons, Qt::KeyboardModifiers modifiers) = 0; - // Description: - // Called when user double clicked on the thumb image - // Arguments: - // point - mouse coordinates relative to the thumbnail rectangle - // aKeyFlags - the key flags, see WM_LBUTTONDOWN - // See Also: - // OnThumbClick() - //! called when user clicked twice on the thumb image - virtual void OnThumbDblClick(const QPoint& point, Qt::MouseButtons buttons, Qt::KeyboardModifiers modifiers) = 0; - // Description: - // Draw the cached thumb bitmap only, if any, no other kind of rendering - // Arguments: - // hDC - the destination DC, where to draw the thumb - // rRect - the destination rectangle - // Return Value: - // True if drawing of the thumbnail was done OK - // See Also: - // Render() - virtual bool DrawThumbImage(QPainter* painter, const QRect& rRect) = 0; - // Description: - // Writes asset info to a XML node. - // This is needed to save cached info as a persistent XML file for the next run of the editor. - // Arguments: - // node - An XML node to contain the info - // See Also: - // FromXML() - virtual void ToXML(XmlNodeRef& node) const = 0; - // Description: - // Gets asset info from a XML node. - // This is needed to get the asset info from previous runs of the editor without re-caching it. - // Arguments: - // node - An XML node that contains info for this asset - // See Also: - // ToXML() - virtual void FromXML(const XmlNodeRef& node) = 0; - - // From IUnknown - virtual HRESULT STDMETHODCALLTYPE QueryInterface([[maybe_unused]] const IID& riid, [[maybe_unused]] void** ppvObject) - { - return E_NOINTERFACE; - }; - virtual ULONG STDMETHODCALLTYPE AddRef() - { - return 0; - }; - virtual ULONG STDMETHODCALLTYPE Release() - { - return 0; - }; -}; -#endif // CRYINCLUDE_EDITOR_INCLUDE_IASSETITEM_H diff --git a/Code/Editor/Include/IAssetItemDatabase.h b/Code/Editor/Include/IAssetItemDatabase.h deleted file mode 100644 index 39fd60e8c6..0000000000 --- a/Code/Editor/Include/IAssetItemDatabase.h +++ /dev/null @@ -1,259 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -// Description : Standard interface for asset database creators used to -// create an asset plugin for the asset browser -// The category of the plugin must be Asset Item DB - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IASSETITEMDATABASE_H -#define CRYINCLUDE_EDITOR_INCLUDE_IASSETITEMDATABASE_H -#pragma once -struct IAssetItem; -struct IAssetViewer; - -class QString; -class QStringList; - -// Description: -// This struct keeps the info, filter and sorting settings for an asset field -struct SAssetField -{ - // the condition for the current filter on the field - enum EAssetFilterCondition - { - eCondition_Any = 0, - // string conditions - // this also supports '*' and '?' as wildcards inside text - eCondition_Contains, - // this filter will search the target for at least one of the words specified - // ( ex: filter: "water car moon" , field value : "the_great_moon.dds", this will pass the test - // it also supports '*' and '?' as wildcards inside words text - eCondition_ContainsOneOfTheWords, - eCondition_StartsWith, - eCondition_EndsWith, - // string & numerical conditions - eCondition_Equal, - eCondition_Greater, - eCondition_Less, - eCondition_GreaterOrEqual, - eCondition_LessOrEqual, - eCondition_Not, - eCondition_InsideRange - }; - - // the asset field type - enum EAssetFieldType - { - eType_None = 0, - eType_Bool, - eType_Int8, - eType_Int16, - eType_Int32, - eType_Int64, - eType_Float, - eType_Double, - eType_String - }; - - // used when a field can have different specific values - typedef QStringList TFieldEnumValues; - - SAssetField( - const char* pFieldName = "", - const char* pDisplayName = "Unnamed field", - EAssetFieldType aFieldType = eType_None, - UINT aColumnWidth = 50, - bool bVisibleInUI = true, - bool bReadOnly = true) - { - m_fieldName = pFieldName; - m_displayName = pDisplayName; - m_fieldType = aFieldType; - m_filterCondition = eCondition_Equal; - m_bUseEnumValues = false; - m_bReadOnly = bReadOnly; - m_listColumnWidth = aColumnWidth; - m_bFieldVisibleInUI = bVisibleInUI; - m_bPostFilter = false; - - SetupEnumValues(); - } - - void SetupEnumValues() - { - m_bUseEnumValues = true; - - if (m_fieldType == eType_Bool) - { - m_enumValues.clear(); - m_enumValues.push_back("Yes"); - m_enumValues.push_back("No"); - } - } - - // the field's display name, used in UI - QString m_displayName, - // the field internal name, used in C++ code - m_fieldName, - // the current filter value, if its empty "" then no filter is applied - m_filterValue, - // the field's max value, valid when the field's filter condition is eAssertFilterCondition_InsideRange - m_maxFilterValue, - // the name of the database holding this field, used in Asset Browser preset editor, if its "" then the field - // is common to all current databases - m_parentDatabaseName; - // is this field visible in the UI ? - bool m_bFieldVisibleInUI, - // if true, then you cannot modify this field of an asset item, only use it - m_bReadOnly, - // this field filter is applied after the other filters - m_bPostFilter; - // the field data type - EAssetFieldType m_fieldType; - // the filter's condition - EAssetFilterCondition m_filterCondition; - // use the enum list values to choose a value for the field ? - bool m_bUseEnumValues; - // this map is used when asset field has m_bUseEnumValues on true, - // choose a value for the field from this list in the UI - TFieldEnumValues m_enumValues; - // recommended list column width - unsigned int m_listColumnWidth; -}; - -struct SFieldFiltersPreset -{ - QString presetName2; - QStringList checkedDatabaseNames; - bool bUsedInLevel; - std::vector fields; -}; - -// Description: -// This interface allows the programmer to extend asset display types -// visible in the asset browser. -struct IAssetItemDatabase - : public IUnknown -{ - DEFINE_UUID(0xFB09B039, 0x1D9D, 0x4057, 0xA5, 0xF0, 0xAA, 0x3C, 0x7B, 0x97, 0xAE, 0xA8) - - typedef std::vector TAssetFields; - typedef std::map < QString/*field name*/, SAssetField > TAssetFieldFiltersMap; - typedef std::map < QString/*asset filename*/, IAssetItem* > TFilenameAssetMap; - typedef AZStd::function MetaDataChangeListener; - - // Description: - // Refresh the database by scanning the folders/paks for files, does not load the files, only filename and filesize are fetched - virtual void Refresh() = 0; - // Description: - // Fills the asset meta data from the loaded xml meta data DB. - // Arguments: - // db - the database XML node from where to cache the info - virtual void PrecacheFieldsInfoFromFileDB(const XmlNodeRef& db) = 0; - // Description: - // Return all assets loaded/scanned by this database - // Return Value: - // The assets map reference (filename-asset) - virtual TFilenameAssetMap& GetAssets() = 0; - // Description: - // Get an asset item by its filename - // Return Value: - // A single asset from the database given the filename - virtual IAssetItem* GetAsset(const char* pAssetFilename) = 0; - // Description: - // Return the asset fields this database's items support - // Return Value: - // The asset fields vector reference - virtual TAssetFields& GetAssetFields() = 0; - // Description: - // Return an asset field object pointer by the field internal name - // Arguments: - // pFieldName - the internal field's name (ex: "filename", "relativepath") - // Return Value: - // The asset field object pointer - virtual SAssetField* GetAssetFieldByName(const char* pFieldName) = 0; - // Description: - // Get the database name - // Return Value: - // Returns the database name, ex: "Textures" - virtual const char* GetDatabaseName() const = 0; - // Description: - // Get the database supported file name extension(s) - // Return Value: - // Returns the supported extensions, separated by comma, ex: "tga,bmp,dds" - virtual const char* GetSupportedExtensions() const = 0; - // Description: - // Free the database internal data structures - virtual void FreeData() = 0; - // Description: - // Apply filters to this database which will set/unset the IAssetItem::eAssetFlag_Visible of each asset, based - // on the given field filters - // Arguments: - // rFieldFilters - a reference to the field filters map (fieldname-field) - // See Also: - // ClearFilters() - virtual void ApplyFilters(const TAssetFieldFiltersMap& rFieldFilters) = 0; - // Description: - // Clear the current filters, by setting the IAssetItem::eAssetFlag_Visible of each asset to true - // See Also: - // ApplyFilters() - virtual void ClearFilters() = 0; - virtual QWidget* CreateDbFilterDialog(QWidget* pParent, IAssetViewer* pViewerCtrl) = 0; - virtual void UpdateDbFilterDialogUI(QWidget* pDlg) = 0; - virtual void OnAssetBrowserOpen() = 0; - virtual void OnAssetBrowserClose() = 0; - // Description: - // Gets the filename for saving new cached asset info. - // Return Value: - // A file name to save new transactions to the persistent asset info DB - // See Also: - // CAssetInfoFileDB, IAssetItem::ToXML(), IAssetItem::FromXML() - virtual const char* GetTransactionFilename() const = 0; - // Description: - // Adds a callback to be called when the meta data of this asset changed. - // Arguments: - // callBack - A functor to be added - // Return Value: - // True if successful, false otherwise. - // See Also: - // RemoveMetaDataChangeListener() - virtual bool AddMetaDataChangeListener(MetaDataChangeListener callBack) = 0; - // Description: - // Removes a callback from the list of meta data change listeners. - // Arguments: - // callBack - A functor to be removed - // Return Value: - // True if successful, false otherwise. - // See Also: - // AddMetaDataCHangeListener() - virtual bool RemoveMetaDataChangeListener(MetaDataChangeListener callBack) = 0; - // Description: - // The method that should be called when the meta data of an asset item changes to notify all listeners - // Arguments: - // pAssetItem - An asset item whose meta data have changed - // See Also: - // AddMetaDataCHangeListener(), RemoveMetaDataChangeListener() - virtual void OnMetaDataChange(const IAssetItem* pAssetItem) = 0; - - //! from IUnknown - virtual HRESULT STDMETHODCALLTYPE QueryInterface([[maybe_unused]] REFIID riid, [[maybe_unused]] void** ppvObject) - { - return E_NOINTERFACE; - }; - virtual ULONG STDMETHODCALLTYPE AddRef() - { - return 0; - }; - virtual ULONG STDMETHODCALLTYPE Release() - { - return 0; - }; -}; -#endif // CRYINCLUDE_EDITOR_INCLUDE_IASSETITEMDATABASE_H diff --git a/Code/Editor/Include/IAssetViewer.h b/Code/Editor/Include/IAssetViewer.h deleted file mode 100644 index 488ee8e508..0000000000 --- a/Code/Editor/Include/IAssetViewer.h +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -// Description : This file declares a control which objective is to display -// multiple assets allowing selection and preview of such things -// It also handles scrolling and changes in the thumbnail display size - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IASSETVIEWER_H -#define CRYINCLUDE_EDITOR_INCLUDE_IASSETVIEWER_H -#pragma once -#include "IObservable.h" -#include "IAssetItemDatabase.h" - -struct IAssetItem; -struct IAssetItemDatabase; - -// Description: -// Observer for the asset viewer events -struct IAssetViewerObserver -{ - virtual void OnChangeStatusBarInfo(UINT nSelectedItems, UINT nVisibleItems, UINT nTotalItems) {}; - virtual void OnSelectionChanged() {}; - virtual void OnChangedPreviewedAsset(IAssetItem* pAsset) {}; - virtual void OnAssetDblClick(IAssetItem* pAsset) {}; - virtual void OnAssetFilterChanged() {}; -}; - -// Description: -// The asset viewer interface for the asset database plugins to use -struct IAssetViewer -{ - DEFINE_OBSERVABLE_PURE_METHODS(IAssetViewerObserver); - - virtual HWND GetRenderWindow() = 0; - virtual void ApplyFilters(const IAssetItemDatabase::TAssetFieldFiltersMap& rFieldFilters) = 0; - virtual const IAssetItemDatabase::TAssetFieldFiltersMap& GetCurrentFilters() = 0; - virtual void ClearFilters() = 0; -}; -#endif // CRYINCLUDE_EDITOR_INCLUDE_IASSETVIEWER_H diff --git a/Code/Editor/Include/IBaseLibraryManager.h b/Code/Editor/Include/IBaseLibraryManager.h deleted file mode 100644 index 4116b573fa..0000000000 --- a/Code/Editor/Include/IBaseLibraryManager.h +++ /dev/null @@ -1,143 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IBASELIBRARYMANAGER_H -#define CRYINCLUDE_EDITOR_INCLUDE_IBASELIBRARYMANAGER_H -#pragma once - -#include -#include "Include/IDataBaseItem.h" -#include "Include/IDataBaseLibrary.h" -#include "Include/IDataBaseManager.h" -#include "Util/TRefCountBase.h" - -class CBaseLibraryItem; -class CBaseLibrary; - -struct IBaseLibraryManager - : public TRefCountBase - , public IEditorNotifyListener -{ - //! Clear all libraries. - virtual void ClearAll() = 0; - - ////////////////////////////////////////////////////////////////////////// - // IDocListener implementation. - ////////////////////////////////////////////////////////////////////////// - virtual void OnEditorNotifyEvent(EEditorNotifyEvent event) = 0; - - ////////////////////////////////////////////////////////////////////////// - // Library items. - ////////////////////////////////////////////////////////////////////////// - //! Make a new item in specified library. - virtual IDataBaseItem* CreateItem(IDataBaseLibrary* pLibrary) = 0; - //! Delete item from library and manager. - virtual void DeleteItem(IDataBaseItem* pItem) = 0; - - //! Find Item by its GUID. - virtual IDataBaseItem* FindItem(REFGUID guid) const = 0; - virtual IDataBaseItem* FindItemByName(const QString& fullItemName) = 0; - virtual IDataBaseItem* LoadItemByName(const QString& fullItemName) = 0; - - virtual IDataBaseItemEnumerator* GetItemEnumerator() = 0; - - ////////////////////////////////////////////////////////////////////////// - // Set item currently selected. - virtual void SetSelectedItem(IDataBaseItem* pItem) = 0; - // Get currently selected item. - virtual IDataBaseItem* GetSelectedItem() const = 0; - virtual IDataBaseItem* GetSelectedParentItem() const = 0; - - ////////////////////////////////////////////////////////////////////////// - // Libraries. - ////////////////////////////////////////////////////////////////////////// - //! Add Item library. - virtual IDataBaseLibrary* AddLibrary(const QString& library, bool isLevelLibrary = false, bool bIsLoading = true) = 0; - virtual void DeleteLibrary(const QString& library, bool forceDeleteLevel = false) = 0; - //! Get number of libraries. - virtual int GetLibraryCount() const = 0; - //! Get number of modified libraries. - virtual int GetModifiedLibraryCount() const = 0; - - //! Get Item library by index. - virtual IDataBaseLibrary* GetLibrary(int index) const = 0; - - //! Get Level Item library. - virtual IDataBaseLibrary* GetLevelLibrary() const = 0; - - //! Find Items Library by name. - virtual IDataBaseLibrary* FindLibrary(const QString& library) = 0; - - //! Find the Library's index by name. - virtual int FindLibraryIndex(const QString& library) = 0; - - //! Load Items library. -#ifdef LoadLibrary -#undef LoadLibrary -#endif - virtual IDataBaseLibrary* LoadLibrary(const QString& filename, bool bReload = false) = 0; - - //! Save all modified libraries. - virtual void SaveAllLibs() = 0; - - //! Serialize property manager. - virtual void Serialize(XmlNodeRef& node, bool bLoading) = 0; - - //! Export items to game. - virtual void Export(XmlNodeRef& node) = 0; - - //! Returns unique name base on input name. - // Vera@conffx, add LibName parameter so we could make an unique name depends on input library. - // Arguments: - // - name: name of the item - // - libName: The library of the item. Given the library name, the function will return a unique name in the library - // Default value "": The function will ignore the library name and return a unique name in the manager - virtual QString MakeUniqueItemName(const QString& name, const QString& libName = "") = 0; - virtual QString MakeFullItemName(IDataBaseLibrary* pLibrary, const QString& group, const QString& itemName) = 0; - - //! Root node where this library will be saved. - virtual QString GetRootNodeName() = 0; - //! Path to libraries in this manager. - virtual QString GetLibsPath() = 0; - - ////////////////////////////////////////////////////////////////////////// - //! Validate library items for errors. - virtual void Validate() = 0; - - ////////////////////////////////////////////////////////////////////////// - virtual void GatherUsedResources(CUsedResources& resources) = 0; - - virtual void AddListener(IDataBaseManagerListener* pListener) = 0; - virtual void RemoveListener(IDataBaseManagerListener* pListener) = 0; - - ////////////////////////////////////////////////////////////////////////// - virtual void RegisterItem(CBaseLibraryItem* pItem, REFGUID newGuid) = 0; - virtual void RegisterItem(CBaseLibraryItem* pItem) = 0; - virtual void UnregisterItem(CBaseLibraryItem* pItem) = 0; - - // Only Used internally. - virtual void OnRenameItem(CBaseLibraryItem* pItem, const QString& oldName) = 0; - - // Called by items to indicated that they have been modified. - // Sends item changed event to listeners. - virtual void OnItemChanged(IDataBaseItem* pItem) = 0; - virtual void OnUpdateProperties(IDataBaseItem* pItem, bool bRefresh) = 0; - - //CONFETTI BEGIN - // Used to change the library item order - virtual void ChangeLibraryOrder(IDataBaseLibrary* lib, unsigned int newLocation) = 0; - // simplifies the library renaming process - virtual bool SetLibraryName(CBaseLibrary* lib, const QString& name) = 0; - - - //Check if the file name is unique. - //Params: library: library name. NOT the file path. - virtual bool IsUniqueFilename(const QString& library) = 0; - //CONFETTI END -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_IBASELIBRARYMANAGER_H diff --git a/Code/Editor/Include/IConsoleConnectivity.h b/Code/Editor/Include/IConsoleConnectivity.h deleted file mode 100644 index 0f5e9bf35c..0000000000 --- a/Code/Editor/Include/IConsoleConnectivity.h +++ /dev/null @@ -1,85 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -// Description : Standard interface for console connectivity plugins. - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_ICONSOLECONNECTIVITY_H -#define CRYINCLUDE_EDITOR_INCLUDE_ICONSOLECONNECTIVITY_H -#pragma once - - -////////////////////////////////////////////////////////////////////////// -// Description -// This interface provide access to the console connectivity -// functionality. -////////////////////////////////////////////////////////////////////////// -struct IConsoleConnectivity - : public IUnknown -{ - DEFINE_UUID(0x4DAA85E1, 0x8498, 0x402f, 0x9B, 0x85, 0x7F, 0x62, 0x9D, 0x76, 0x79, 0x8A); - - ////////////////////////////////////////////////////////////////////////// - //TODO: Must add the useful interface here. - ////////////////////////////////////////////////////////////////////////// - - // Description: - // Checks if a development console is connected to the development PC. - // See Also: - // Arguments: - // Nothing - // Return: - // bool - true if it is connected, false otherwise. - virtual bool IsConnectedToConsole() = 0; - - // Description: - // Send a file from the specified local filename to the console platform creating the full path - // as required so it can copy to the remote filename. - // See Also: - // Nothing - // Arguments: - // szLocalFileName - is the local filename from which you want to copy the file. - // szRemoteFilename - is the full path and filename to where you want to copy the file. - // Return: - // bool - true if the copy succeeded, false otherwise. - virtual bool SendFile(const char* szLocalFileName, const char* szRemoteFilename) = 0; - - // Description: - // Notifies to the console that a file has been changed, typically uploaded. - // This will be usually called after a SendFile (see above) call, so that the - // system running on the console may decide what to do with this new file. - // Typically the system will have to load or reloads this new file. - // See Also: - // SendFile - // Arguments: - // szRemoteFilename - is the full path and filename in the console of the changed - // file. - // Return: - // bool - true if succeeded sending the notification, false otherwise. - virtual bool NotifyFileChange(const char* szRemoteFilename) = 0; - - - // Description: - // Gets the the title IP for the connected console . - // Arguments: - // dwConsoleAddressPlaceholder - is the pointer to the placeholder of the variable - // which will contain the title IP of the console. - // Return: - // bool - true if dwConsoleAddressPlaceholder now contains the IP address, else false. - virtual bool GetConsoleAddress(DWORD* dwConsoleAddressPlaceholder) = 0; - ////////////////////////////////////////////////////////////////////////// - // IUnknown - ////////////////////////////////////////////////////////////////////////// - virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject) { return E_NOINTERFACE; }; - virtual ULONG STDMETHODCALLTYPE AddRef() { return 0; }; - virtual ULONG STDMETHODCALLTYPE Release() { return 0; }; - ////////////////////////////////////////////////////////////////////////// -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_ICONSOLECONNECTIVITY_H diff --git a/Code/Editor/Include/IDataBaseItem.h b/Code/Editor/Include/IDataBaseItem.h deleted file mode 100644 index 6be5f49c2d..0000000000 --- a/Code/Editor/Include/IDataBaseItem.h +++ /dev/null @@ -1,92 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IDATABASEITEM_H -#define CRYINCLUDE_EDITOR_INCLUDE_IDATABASEITEM_H -#pragma once - -#include -#include - -struct IDataBaseLibrary; -class CUsedResources; - -////////////////////////////////////////////////////////////////////////// -/** Base class for all items contained in BaseLibraray. -*/ -struct IDataBaseItem -{ - struct SerializeContext - { - XmlNodeRef node; - bool bUndo; - bool bLoading; - bool bCopyPaste; - bool bIgnoreChilds; - bool bUniqName; - SerializeContext() - : node(0) - , bLoading(false) - , bCopyPaste(false) - , bIgnoreChilds(false) - , bUniqName(false) - , bUndo(false) {}; - SerializeContext(XmlNodeRef _node, bool bLoad) - : node(_node) - , bLoading(bLoad) - , bCopyPaste(false) - , bIgnoreChilds(false) - , bUniqName(false) - , bUndo(false) {}; - SerializeContext(const SerializeContext& ctx) - : node(ctx.node) - , bLoading(ctx.bLoading) - , bCopyPaste(ctx.bCopyPaste) - , bIgnoreChilds(ctx.bIgnoreChilds) - , bUniqName(ctx.bUniqName) - , bUndo(ctx.bUndo) {}; - }; - - virtual EDataBaseItemType GetType() const = 0; - - //! Return Library this item are contained in. - //! Item can only be at one library. - virtual IDataBaseLibrary* GetLibrary() const = 0; - - //! Change item name. - virtual void SetName(const QString& name) = 0; - //! Get item name. - virtual const QString& GetName() const = 0; - - //! Get full item name, including name of library. - //! Name formed by adding dot after name of library - //! eg. library Pickup and item PickupRL form full item name: "Pickups.PickupRL". - virtual QString GetFullName() const = 0; - - //! Get only nameof group from prototype. - virtual QString GetGroupName() = 0; - //! Get short name of prototype without group. - virtual QString GetShortName() = 0; - - //! Serialize library item to archive. - virtual void Serialize(SerializeContext& ctx) = 0; - - //! Generate new unique id for this item. - virtual void GenerateId() = 0; - //! Returns GUID of this material. - virtual const GUID& GetGUID() const = 0; - - //! Validate item for errors. - virtual void Validate() {}; - - //! Gathers resources by this item. - virtual void GatherUsedResources([[maybe_unused]] CUsedResources& resources) {}; -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_IDATABASEITEM_H diff --git a/Code/Editor/Include/IDataBaseLibrary.h b/Code/Editor/Include/IDataBaseLibrary.h deleted file mode 100644 index 75437d93e2..0000000000 --- a/Code/Editor/Include/IDataBaseLibrary.h +++ /dev/null @@ -1,118 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IDATABASELIBRARY_H -#define CRYINCLUDE_EDITOR_INCLUDE_IDATABASELIBRARY_H -#pragma once - - -struct IDataBaseManager; -struct IDataBaseItem; - -class QString; -class XmlNodeRef; - -////////////////////////////////////////////////////////////////////////// -// Description: -// Interface to access specific library of editor data base. -// Ex. Archetype library, Material Library. -// See Also: -// IDataBaseItem,IDataBaseManager -////////////////////////////////////////////////////////////////////////// -struct IDataBaseLibrary -{ - // Description: - // Return IDataBaseManager interface to the manager for items stored in this library. - virtual IDataBaseManager* GetManager() = 0; - - // Description: - // Return library name. - virtual const QString& GetName() const = 0; - - // Description: - // Return filename where this library is stored. - virtual const QString& GetFilename() const = 0; - - // Description: - // Save contents of library to file. - virtual bool Save() = 0; - - // Description: - // Load library from file. - // Arguments: - // filename - Full specified library filename (relative to root game folder). - virtual bool Load(const QString& filename) = 0; - - // Description: - // Serialize library parameters and items to/from XML node. - virtual void Serialize(XmlNodeRef& node, bool bLoading) = 0; - - // Description: - // Marks library as modified, indicates that some item in library was modified. - virtual void SetModified(bool bModified = true) = 0; - - // Description: - // Check if library parameters or any items where modified. - // If any item was modified library may need saving before closing editor. - virtual bool IsModified() const = 0; - - // Description: - // Check if this library is not shared and internal to current level. - virtual bool IsLevelLibrary() const = 0; - - // Description: - // Make this library accessible only from current Level. (not shared) - virtual void SetLevelLibrary(bool bEnable) = 0; - - // Description: - // Associate a new item with the library. - // Watch out if item was already in another library. - virtual void AddItem(IDataBaseItem* pItem, bool bRegister = true) = 0; - - // Description: - // Return number of items in library. - virtual int GetItemCount() const = 0; - - // Description: - // Get item by index. - // See Also: - // GetItemCount - // Arguments: - // index - Index from 0 to GetItemCount() - virtual IDataBaseItem* GetItem(int index) = 0; - - // Description: - // Remove item from library, does not destroy item, - // only unliks it from this library, to delete item use IDataBaseManager. - // See Also: - // AddItem - virtual void RemoveItem(IDataBaseItem* item) = 0; - - // Description: - // Remove all items from library, does not destroy items, - // only unliks them from this library, to delete item use IDataBaseManager. - // See Also: - // RemoveItem,AddItem - virtual void RemoveAllItems() = 0; - - // Description: - // Find item in library by name. - // This function usually uses linear search so it is not particularry fast. - // See Also: - // GetItem - virtual IDataBaseItem* FindItem(const QString& name) = 0; - - - //CONFETTI BEGIN - // Used to change the library item order - virtual void ChangeItemOrder(CBaseLibraryItem* item, unsigned int newLocation) = 0; - //CONFETTI END -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_IDATABASELIBRARY_H diff --git a/Code/Editor/Include/IDataBaseManager.h b/Code/Editor/Include/IDataBaseManager.h deleted file mode 100644 index 3d701d51fc..0000000000 --- a/Code/Editor/Include/IDataBaseManager.h +++ /dev/null @@ -1,134 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IDATABASEMANAGER_H -#define CRYINCLUDE_EDITOR_INCLUDE_IDATABASEMANAGER_H -#pragma once - -#include - -struct IDataBaseItem; -struct IDataBaseLibrary; -class CUsedResources; - -enum EDataBaseItemEvent -{ - EDB_ITEM_EVENT_ADD, - EDB_ITEM_EVENT_DELETE, - EDB_ITEM_EVENT_CHANGED, - EDB_ITEM_EVENT_SELECTED, - EDB_ITEM_EVENT_UPDATE_PROPERTIES, - EDB_ITEM_EVENT_UPDATE_PROPERTIES_NO_EDITOR_REFRESH -}; - -////////////////////////////////////////////////////////////////////////// -// Description: -// Callback class to intercept item creation and deletion events. -////////////////////////////////////////////////////////////////////////// -struct IDataBaseManagerListener -{ - virtual void OnDataBaseItemEvent(IDataBaseItem* pItem, EDataBaseItemEvent event) = 0; -}; - -////////////////////////////////////////////////////////////////////////// -// Description: -// his interface is used to enumerate al items registered to the database manager. -////////////////////////////////////////////////////////////////////////// -struct IDataBaseItemEnumerator -{ - virtual ~IDataBaseItemEnumerator() = default; - - virtual void Release() = 0; - virtual IDataBaseItem* GetFirst() = 0; - virtual IDataBaseItem* GetNext() = 0; -}; - -////////////////////////////////////////////////////////////////////////// -// -// Interface to the collection of all items or specific type -// in data base libraries. -// -////////////////////////////////////////////////////////////////////////// -struct IDataBaseManager -{ - //! Clear all libraries. - virtual void ClearAll() = 0; - - ////////////////////////////////////////////////////////////////////////// - // Library items. - ////////////////////////////////////////////////////////////////////////// - //! Make a new item in specified library. - virtual IDataBaseItem* CreateItem(IDataBaseLibrary* pLibrary) = 0; - //! Delete item from library and manager. - virtual void DeleteItem(IDataBaseItem* pItem) = 0; - - //! Find Item by its GUID. - virtual IDataBaseItem* FindItem(REFGUID guid) const = 0; - virtual IDataBaseItem* FindItemByName(const QString& fullItemName) = 0; - - virtual IDataBaseItemEnumerator* GetItemEnumerator() = 0; - - // Select one item in DB. - virtual void SetSelectedItem(IDataBaseItem* pItem) = 0; - - ////////////////////////////////////////////////////////////////////////// - // Libraries. - ////////////////////////////////////////////////////////////////////////// - //! Add Item library. Set isLevelLibrary to true if its the "level" library which gets saved inside the level - virtual IDataBaseLibrary* AddLibrary(const QString& library, bool isLevelLibrary = false, bool bIsLoading = true) = 0; - virtual void DeleteLibrary(const QString& library, bool forceDeleteLibrary = false) = 0; - //! Get number of libraries. - virtual int GetLibraryCount() const = 0; - //! Get Item library by index. - virtual IDataBaseLibrary* GetLibrary(int index) const = 0; - - //! Find Items Library by name. - virtual IDataBaseLibrary* FindLibrary(const QString& library) = 0; - - //! Load Items library. -#ifdef LoadLibrary -#undef LoadLibrary -#endif - virtual IDataBaseLibrary* LoadLibrary(const QString& filename, bool bReload = false) = 0; - - //! Save all modified libraries. - virtual void SaveAllLibs() = 0; - - //! Serialize property manager. - virtual void Serialize(XmlNodeRef& node, bool bLoading) = 0; - - //! Export items to game. - virtual void Export([[maybe_unused]] XmlNodeRef& node) {}; - - //! Returns unique name base on input name. - virtual QString MakeUniqueItemName(const QString& name, const QString& libName = "") = 0; - virtual QString MakeFullItemName(IDataBaseLibrary* pLibrary, const QString& group, const QString& itemName) = 0; - - //! Root node where this library will be saved. - virtual QString GetRootNodeName() = 0; - //! Path to libraries in this manager. - virtual QString GetLibsPath() = 0; - - ////////////////////////////////////////////////////////////////////////// - //! Validate library items for errors. - virtual void Validate() = 0; - - // Description: - // Collects names of all resource files used by managed items. - // Arguments: - // resources - Structure where all filenames are collected. - virtual void GatherUsedResources(CUsedResources& resources) = 0; - - ////////////////////////////////////////////////////////////////////////// - // Register listeners. - virtual void AddListener(IDataBaseManagerListener* pListener) = 0; - virtual void RemoveListener(IDataBaseManagerListener* pListener) = 0; -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_IDATABASEMANAGER_H diff --git a/Code/Editor/Include/IEditorClassFactory.h b/Code/Editor/Include/IEditorClassFactory.h index dd47f803e2..6c85192436 100644 --- a/Code/Editor/Include/IEditorClassFactory.h +++ b/Code/Editor/Include/IEditorClassFactory.h @@ -31,10 +31,7 @@ struct IUnknown }; #endif -#ifdef __uuidof -#undef __uuidof -#endif -#define __uuidof(T) T::uuid() +#define __az_uuidof(T) T::uuid() #if defined(AZ_PLATFORM_LINUX) || defined(AZ_PLATFORM_MAC) @@ -107,7 +104,7 @@ struct IClassDesc template HRESULT STDMETHODCALLTYPE QueryInterface(Q** pp) { - return QueryInterface(__uuidof(Q), (void**)pp); + return QueryInterface(__az_uuidof(Q), (void**)pp); } ////////////////////////////////////////////////////////////////////////// diff --git a/Code/Editor/Include/IEditorMaterial.h b/Code/Editor/Include/IEditorMaterial.h deleted file mode 100644 index 329b0ae53f..0000000000 --- a/Code/Editor/Include/IEditorMaterial.h +++ /dev/null @@ -1,20 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - - -#include "BaseLibraryItem.h" -#include - -struct IEditorMaterial - : public CBaseLibraryItem -{ - virtual int GetFlags() const = 0; - virtual IMaterial* GetMatInfo(bool bUseExistingEngineMaterial = false) = 0; - virtual void DisableHighlightForFrame() = 0; -}; diff --git a/Code/Editor/Include/IEditorMaterialManager.h b/Code/Editor/Include/IEditorMaterialManager.h deleted file mode 100644 index 6f71c5ddd1..0000000000 --- a/Code/Editor/Include/IEditorMaterialManager.h +++ /dev/null @@ -1,21 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef CRYINCLUDE_EDITOR_MATERIAL_IEDITORMATERIALMANAGER_H -#define CRYINCLUDE_EDITOR_MATERIAL_IEDITORMATERIALMANAGER_H -#pragma once - -#include -#include - - -struct IEditorMaterialManager -{ - virtual void GotoMaterial(IMaterial* pMaterial) = 0; -}; - -#endif // CRYINCLUDE_EDITOR_MATERIAL_MATERIALMANAGER_H diff --git a/Code/Editor/Include/IErrorReport.h b/Code/Editor/Include/IErrorReport.h index 7bf00d6973..c409dbc7dd 100644 --- a/Code/Editor/Include/IErrorReport.h +++ b/Code/Editor/Include/IErrorReport.h @@ -14,7 +14,6 @@ // forward declarations. class CParticleItem; class CBaseObject; -class CBaseLibraryItem; class CErrorRecord; class QString; @@ -52,9 +51,6 @@ struct IErrorReport //! Assign current Object to which new reported warnings are assigned. virtual void SetCurrentValidatorObject(CBaseObject* pObject) = 0; - //! Assign current Item to which new reported warnings are assigned. - virtual void SetCurrentValidatorItem(CBaseLibraryItem* pItem) = 0; - //! Assign current filename. virtual void SetCurrentFile(const QString& file) = 0; }; diff --git a/Code/Editor/Include/IFacialEditor.h b/Code/Editor/Include/IFacialEditor.h deleted file mode 100644 index 5dfa9ab03f..0000000000 --- a/Code/Editor/Include/IFacialEditor.h +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IFACIALEDITOR_H -#define CRYINCLUDE_EDITOR_INCLUDE_IFACIALEDITOR_H -#pragma once - - -class IFacialEditor -{ -public: - enum EyeType - { - EYE_LEFT, - EYE_RIGHT - }; - - virtual int GetNumMorphTargets() const = 0; - virtual const char* GetMorphTargetName(int index) const = 0; - virtual void PreviewEffector(int index, float value) = 0; - virtual void ClearAllPreviewEffectors() = 0; - virtual void SetForcedNeckRotation(const Quat& rotation) = 0; - virtual void SetForcedEyeRotation(const Quat& rotation, EyeType eye) = 0; - virtual int GetJoystickCount() const = 0; - virtual const char* GetJoystickName(int joystickIndex) const = 0; - virtual void SetJoystickPosition(int joystickIndex, float x, float y) = 0; - virtual void GetJoystickPosition(int joystickIndex, float& x, float& y) const = 0; - virtual void LoadJoystickFile(const char* filename) = 0; - virtual void LoadCharacter(const char* filename) = 0; - virtual void LoadSequence(const char* filename) = 0; - virtual void SetVideoFrameResolution(int width, int height, int bpp) = 0; - virtual int GetVideoFramePitch() = 0; - virtual void* GetVideoFrameBits() = 0; - virtual void ShowVideoFramePane() = 0; -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_IFACIALEDITOR_H diff --git a/Code/Editor/Include/IFileUtil.h b/Code/Editor/Include/IFileUtil.h index 036a0bc5ee..ea2fe1f1a3 100644 --- a/Code/Editor/Include/IFileUtil.h +++ b/Code/Editor/Include/IFileUtil.h @@ -116,9 +116,6 @@ struct IFileUtil virtual bool ExtractFile(QString& file, bool bMsgBoxAskForExtraction = true, const char* pDestinationFilename = nullptr) = 0; virtual void EditTextureFile(const char* txtureFile, bool bUseGameFolder) = 0; - //! dcc filename calculation and extraction sub-routines - virtual bool CalculateDccFilename(const QString& assetFilename, QString& dccFilename) = 0; - //! Reformat filter string for (MFC) CFileDialog style file filtering virtual void FormatFilterString(QString& filter) = 0; diff --git a/Code/Editor/Include/IRenderListener.h b/Code/Editor/Include/IRenderListener.h deleted file mode 100644 index 892a42b701..0000000000 --- a/Code/Editor/Include/IRenderListener.h +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -// Description : Interface for rendering custom 3D elements in the main -// render viewport. Particularly usefull for debug geometries. - - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_IRENDERLISTENER_H -#define CRYINCLUDE_EDITOR_INCLUDE_IRENDERLISTENER_H -#pragma once - - -struct DisplayContext; - -struct IRenderListener - : public IUnknown -{ - DEFINE_UUID(0x8D52F857, 0x1027, 0x4346, 0xAC, 0x7B, 0xF6, 0x20, 0xDA, 0x7C, 0xCE, 0x42) - - virtual void Render(DisplayContext& rDisplayContext) = 0; -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_IRENDERLISTENER_H diff --git a/Code/Editor/Include/ITextureDatabaseUpdater.h b/Code/Editor/Include/ITextureDatabaseUpdater.h deleted file mode 100644 index 4482135b47..0000000000 --- a/Code/Editor/Include/ITextureDatabaseUpdater.h +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -// Description : This file declares the interface used by the texture viewer -// and (implemented first implemented by the Texture Database Creator) to -// syncronize their threads. A thread interace could be useful there. - -#ifndef CRYINCLUDE_EDITOR_INCLUDE_ITEXTUREDATABASEUPDATER_H -#define CRYINCLUDE_EDITOR_INCLUDE_ITEXTUREDATABASEUPDATER_H -#pragma once - - -class CTextureDatabaseItem; - -struct ITextureDatabaseUpdater -{ -public: - ////////////////////////////////////////////////////////////////////////// - // Thread control - virtual void NotifyShutDown() = 0; - virtual void Lock() = 0; - virtual void Unlock() = 0; - virtual void WaitForThread() = 0; - ////////////////////////////////////////////////////////////////////////// - - ////////////////////////////////////////////////////////////////////////// - // Data access - virtual CTextureDatabaseItem* GetItem(const char* szAddItem) = 0; - ////////////////////////////////////////////////////////////////////////// -}; - -#endif // CRYINCLUDE_EDITOR_INCLUDE_ITEXTUREDATABASEUPDATER_H diff --git a/Code/Editor/Include/IViewPane.h b/Code/Editor/Include/IViewPane.h index b4a25a87a9..f2425fb954 100644 --- a/Code/Editor/Include/IViewPane.h +++ b/Code/Editor/Include/IViewPane.h @@ -60,7 +60,7 @@ struct IViewPaneClass ////////////////////////////////////////////////////////////////////////// HRESULT STDMETHODCALLTYPE QueryInterface(const IID& riid, void** ppvObj) { - if (riid == __uuidof(IViewPaneClass)) + if (riid == __az_uuidof(IViewPaneClass)) { *ppvObj = this; return S_OK; diff --git a/Code/Editor/Lib/Tests/IEditorMock.h b/Code/Editor/Lib/Tests/IEditorMock.h index 390ffebe79..aaee34c2c6 100644 --- a/Code/Editor/Lib/Tests/IEditorMock.h +++ b/Code/Editor/Lib/Tests/IEditorMock.h @@ -85,9 +85,6 @@ public: MOCK_METHOD0(IsSelectionLocked, bool()); MOCK_METHOD0(GetObjectManager, struct IObjectManager* ()); MOCK_METHOD0(GetSettingsManager, CSettingsManager* ()); - MOCK_METHOD1(GetDBItemManager, IDataBaseManager* (EDataBaseItemType)); - MOCK_METHOD0(GetMaterialManagerLibrary, IBaseLibraryManager* ()); - MOCK_METHOD0(GetIEditorMaterialManager, IEditorMaterialManager* ()); MOCK_METHOD0(GetIconManager, IIconManager* ()); MOCK_METHOD0(GetMusicManager, CMusicManager* ()); MOCK_METHOD2(GetTerrainElevation, float(float , float )); @@ -187,6 +184,5 @@ public: MOCK_METHOD0(UnloadPlugins, void()); MOCK_METHOD0(LoadPlugins, void()); MOCK_METHOD1(GetSearchPath, QString(EEditorPathName)); - MOCK_METHOD0(GetEditorPanelUtils, IEditorPanelUtils* ()); }; diff --git a/Code/Editor/Lib/Tests/test_ClickableLabel.cpp b/Code/Editor/Lib/Tests/test_ClickableLabel.cpp deleted file mode 100644 index a676714992..0000000000 --- a/Code/Editor/Lib/Tests/test_ClickableLabel.cpp +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include "EditorDefs.h" -#include -#include -#include - -#include - -using namespace AZ; -using namespace ::testing; - -namespace UnitTest -{ - class TestingClickableLabel - : public ScopedAllocatorSetupFixture - { - public: - ClickableLabel m_clickableLabel; - }; - - TEST_F(TestingClickableLabel, CursorDoesNotUpdateWhileDisabled) - { - m_clickableLabel.setEnabled(false); - - QApplication::setOverrideCursor(QCursor(Qt::BlankCursor)); - QEnterEvent enterEvent{ QPointF(), QPointF(), QPointF() }; - QApplication::sendEvent(&m_clickableLabel, &enterEvent); - - const Qt::CursorShape cursorShape = QApplication::overrideCursor()->shape(); - EXPECT_THAT(cursorShape, Ne(Qt::PointingHandCursor)); - EXPECT_THAT(cursorShape, Eq(Qt::BlankCursor)); - } - - TEST_F(TestingClickableLabel, DoesNotRespondToDblClickWhileDisabled) - { - m_clickableLabel.setEnabled(false); - - bool linkActivated = false; - QObject::connect(&m_clickableLabel, &QLabel::linkActivated, [&linkActivated]() - { - linkActivated = true; - }); - - QMouseEvent mouseEvent { - QEvent::MouseButtonDblClick, QPointF(), - Qt::LeftButton, Qt::LeftButton, Qt::NoModifier }; - QApplication::sendEvent(&m_clickableLabel, &mouseEvent); - - EXPECT_THAT(linkActivated, Eq(false)); - } -} // namespace UnitTest diff --git a/Code/Editor/Lib/Tests/test_DisplaySettingsPythonBindings.cpp b/Code/Editor/Lib/Tests/test_DisplaySettingsPythonBindings.cpp index fd65634d4e..b73cb039ea 100644 --- a/Code/Editor/Lib/Tests/test_DisplaySettingsPythonBindings.cpp +++ b/Code/Editor/Lib/Tests/test_DisplaySettingsPythonBindings.cpp @@ -35,6 +35,11 @@ namespace DisplaySettingsPythonBindingsUnitTests m_app.Start(appDesc); m_app.RegisterComponentDescriptor(AzToolsFramework::DisplaySettingsPythonFuncsHandler::CreateDescriptor()); + + // Without this, the user settings component would attempt to save on finalize/shutdown. Since the file is + // shared across the whole engine, if multiple tests are run in parallel, the saving could cause a crash + // in the unit tests. + AZ::UserSettingsComponentRequestBus::Broadcast(&AZ::UserSettingsComponentRequests::DisableSaveOnFinalize); } void TearDown() override diff --git a/Code/Editor/LightmapCompiler/SimpleTriangleRasterizer.cpp b/Code/Editor/LightmapCompiler/SimpleTriangleRasterizer.cpp deleted file mode 100644 index 736465cac1..0000000000 --- a/Code/Editor/LightmapCompiler/SimpleTriangleRasterizer.cpp +++ /dev/null @@ -1,506 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include "EditorDefs.h" - -#include "SimpleTriangleRasterizer.h" - -#include - -#if !defined FLT_MAX -#define FLT_MAX 3.402823466e+38F -#endif - -void CSimpleTriangleRasterizer::lambertHorizlineConservative(float fx1, float fx2, int yy, IRasterizeSink* inpSink) -{ - int x1 = (int)floorf(fx1 + 0.25f), x2 = (int)floorf(fx2 + .75f); - - if (x1 < m_iMinX) - { - x1 = m_iMinX; - } - if (x2 > m_iMaxX + 1) - { - x2 = m_iMaxX + 1; - } - if (x1 > m_iMaxX + 1) - { - x1 = m_iMaxX + 1; - } - if (x2 < m_iMinX) - { - x2 = m_iMinX; - } - - - inpSink->Line(fx1, fx2, x1, x2, yy); -} - -void CSimpleTriangleRasterizer::lambertHorizlineSubpixelCorrect(float fx1, float fx2, int yy, IRasterizeSink* inpSink) -{ - int x1 = (int)floorf(fx1 + 0.5f), x2 = (int)floorf(fx2 + 0.5f); - // int x1=(int)floorf(fx1*1023.f/1024.f+1.f),x2=(int)floorf(fx2*1023.f/1024.f+1.f); - - if (x1 < m_iMinX) - { - x1 = m_iMinX; - } - if (x2 > m_iMaxX) - { - x2 = m_iMaxX; - } - if (x1 > m_iMaxX) - { - x1 = m_iMaxX; - } - if (x2 < m_iMinX) - { - x2 = m_iMinX; - } - - inpSink->Line(fx1, fx2, x1, x2, yy); -} - -// optimizable -void CSimpleTriangleRasterizer::CopyAndSortY(const float infX[3], const float infY[3], float outfX[3], float outfY[3]) -{ - outfX[0] = infX[0]; - outfY[0] = infY[0]; - outfX[1] = infX[1]; - outfY[1] = infY[1]; - outfX[2] = infX[2]; - outfY[2] = infY[2]; - - // Sort the coordinates, so that (x[1], y[1]) becomes the highest coord - float tmp; - - if (outfY[0] > outfY[1]) - { - if (outfY[1] > outfY[2]) - { - tmp = outfY[0]; - outfY[0] = outfY[1]; - outfY[1] = tmp; - tmp = outfX[0]; - outfX[0] = outfX[1]; - outfX[1] = tmp; - tmp = outfY[1]; - outfY[1] = outfY[2]; - outfY[2] = tmp; - tmp = outfX[1]; - outfX[1] = outfX[2]; - outfX[2] = tmp; - - if (outfY[0] > outfY[1]) - { - tmp = outfY[0]; - outfY[0] = outfY[1]; - outfY[1] = tmp; - tmp = outfX[0]; - outfX[0] = outfX[1]; - outfX[1] = tmp; - } - } - else - { - tmp = outfY[0]; - outfY[0] = outfY[1]; - outfY[1] = tmp; - tmp = outfX[0]; - outfX[0] = outfX[1]; - outfX[1] = tmp; - - if (outfY[1] > outfY[2]) - { - tmp = outfY[1]; - outfY[1] = outfY[2]; - outfY[2] = tmp; - tmp = outfX[1]; - outfX[1] = outfX[2]; - outfX[2] = tmp; - } - } - } - else - { - if (outfY[1] > outfY[2]) - { - tmp = outfY[1]; - outfY[1] = outfY[2]; - outfY[2] = tmp; - tmp = outfX[1]; - outfX[1] = outfX[2]; - outfX[2] = tmp; - - if (outfY[0] > outfY[1]) - { - tmp = outfY[0]; - outfY[0] = outfY[1]; - outfY[1] = tmp; - tmp = outfX[0]; - outfX[0] = outfX[1]; - outfX[1] = tmp; - } - } - } -} - -void CSimpleTriangleRasterizer::CallbackFillRectConservative(float _x[3], float _y[3], IRasterizeSink* inpSink) -{ - inpSink->Triangle(m_iMinY); - - float fMinX = (std::min)(_x[0], (std::min)(_x[1], _x[2])); - float fMaxX = (std::max)(_x[0], (std::max)(_x[1], _x[2])); - float fMinY = (std::min)(_y[0], (std::min)(_y[1], _y[2])); - float fMaxY = (std::max)(_y[0], (std::max)(_y[1], _y[2])); - - int iMinX = (std::max)(m_iMinX, (int)floorf(fMinX)); - int iMaxX = (std::min)(m_iMaxX + 1, (int)ceilf(fMaxX)); - int iMinY = (std::max)(m_iMinY, (int)floorf(fMinY)); - int iMaxY = (std::min)(m_iMaxY + 1, (int)ceilf(fMaxY)); - - for (int y = iMinY; y < iMaxY; y++) - { - inpSink->Line(fMinX, fMaxX, iMinX, iMaxX, y); - } -} - - - - -void CSimpleTriangleRasterizer::CallbackFillConservative(float _x[3], float _y[3], IRasterizeSink* inpSink) -{ - float x[3], y[3]; - - CopyAndSortY(_x, _y, x, y); - - // Calculate interpolation steps - float fX1toX2step = 0.0f; - float fX1toX3step = 0.0f; - float fX2toX3step = 0.0f; - if (fabsf(y[1] - y[0]) > FLT_EPSILON) - { - fX1toX2step = (x[1] - x[0]) / (float)(y[1] - y[0]); - } - if (fabsf(y[2] - y[0]) > FLT_EPSILON) - { - fX1toX3step = (x[2] - x[0]) / (float)(y[2] - y[0]); - } - if (fabsf(y[2] - y[1]) > FLT_EPSILON) - { - fX2toX3step = (x[2] - x[1]) / (float)(y[2] - y[1]); - } - - float fX1toX2 = x[0], fX1toX3 = x[0], fX2toX3 = x[1]; - bool bFirstLine = true; - bool bTriangleCallDone = false; - - // Go through the scanlines of the triangle - int yy = (int)floorf(y[0]); // was floor - - for (; yy <= (int)floorf(y[2]); yy++) - // for(yy=m_iMinY; yy<=m_iMaxY; yy++) // juhu - { - float fSubPixelYStart = 0.0f, fSubPixelYEnd = 1.0f; - float start, end; - - // first line - if (bFirstLine) - { - fSubPixelYStart = y[0] - floorf(y[0]); - start = x[0]; - end = x[0]; - bFirstLine = false; - } - else - { - // top part without middle corner line - if (yy <= (int)floorf(y[1])) - { - start = (std::min)(fX1toX2, fX1toX3); - end = (std::max)(fX1toX2, fX1toX3); - } - else - { - start = (std::min)(fX2toX3, fX1toX3); - end = (std::max)(fX2toX3, fX1toX3); - } - } - - // middle corner line - if (yy == (int)floorf(y[1])) - { - fSubPixelYEnd = y[1] - floorf(y[1]); - - fX1toX3 += fX1toX3step * (fSubPixelYEnd - fSubPixelYStart); - start = (std::min)(start, fX1toX3); - end = (std::max)(end, fX1toX3); - start = (std::min)(start, x[1]); - end = (std::max)(end, x[1]); - - fSubPixelYStart = fSubPixelYEnd; - fSubPixelYEnd = 1.0f; - } - - // last line - if (yy == (int)floorf(y[2])) - { - start = (std::min)(start, x[2]); - end = (std::max)(end, x[2]); - } - else - { - // top part without middle corner line - if (yy < (int)floorf(y[1])) - { - fX1toX2 += fX1toX2step * (fSubPixelYEnd - fSubPixelYStart); - start = (std::min)(start, fX1toX2); - end = (std::max)(end, fX1toX2); - } - else - { - fX2toX3 += fX2toX3step * (fSubPixelYEnd - fSubPixelYStart); - start = (std::min)(start, fX2toX3); - end = (std::max)(end, fX2toX3); - } - - fX1toX3 += fX1toX3step * (fSubPixelYEnd - fSubPixelYStart); - start = (std::min)(start, fX1toX3); - end = (std::max)(end, fX1toX3); - } - - if (yy >= m_iMinY && yy <= m_iMaxY) - { - if (!bTriangleCallDone) - { - inpSink->Triangle(yy); - bTriangleCallDone = true; - } - - lambertHorizlineConservative(start, end, yy, inpSink); - } - } -} - - - -void CSimpleTriangleRasterizer::CallbackFillSubpixelCorrect(float _x[3], float _y[3], IRasterizeSink* inpSink) -{ - float x[3], y[3]; - - CopyAndSortY(_x, _y, x, y); - - if (fabs(y[0] - floorf(y[0])) < FLT_EPSILON) - { - y[0] -= FLT_EPSILON; - } - - // Calculate interpolation steps - float fX1toX2step = 0.0f; - float fX1toX3step = 0.0f; - float fX2toX3step = 0.0f; - if (fabsf(y[1] - y[0]) > FLT_EPSILON) - { - fX1toX2step = (x[1] - x[0]) / (y[1] - y[0]); - } - if (fabsf(y[2] - y[0]) > FLT_EPSILON) - { - fX1toX3step = (x[2] - x[0]) / (y[2] - y[0]); - } - if (fabsf(y[2] - y[1]) > FLT_EPSILON) - { - fX2toX3step = (x[2] - x[1]) / (y[2] - y[1]); - } - - float fX1toX2 = x[0], fX1toX3 = x[0], fX2toX3 = x[1]; - bool bFirstLine = true; - bool bTriangleCallDone = false; - - y[0] -= 0.5f; - y[1] -= 0.5f; - y[2] -= 0.5f; - // y[0]=y[0]*1023.f/1024.f+1.f; - // y[1]=y[1]*1023.f/1024.f+1.f; - // y[2]=y[2]*1023.f/1024.f+1.f; - - for (int yy = (int)floorf(y[0]); yy <= (int)floorf(y[2]); yy++) - { - float fSubPixelYStart = 0.0f, fSubPixelYEnd = 1.0f; - float start, end; - - // first line - if (bFirstLine) - { - fSubPixelYStart = y[0] - floorf(y[0]); - start = x[0]; - end = x[0]; - bFirstLine = false; - } - else - { - // top part without middle corner line - if (yy <= (int)floorf(y[1])) - { - start = (std::min)(fX1toX2, fX1toX3); - end = (std::max)(fX1toX2, fX1toX3); - } - else - { - start = (std::min)(fX2toX3, fX1toX3); - end = (std::max)(fX2toX3, fX1toX3); - } - } - - // middle corner line - if (yy == (int)floorf(y[1])) - { - fSubPixelYEnd = y[1] - floorf(y[1]); - - fX1toX3 += fX1toX3step * (fSubPixelYEnd - fSubPixelYStart); - - fSubPixelYStart = fSubPixelYEnd; - fSubPixelYEnd = 1.0f; - } - - // last line - if (yy != (int)floorf(y[2])) - { - // top part without middle corner line - if (yy < (int)floorf(y[1])) - { - fX1toX2 += fX1toX2step * (fSubPixelYEnd - fSubPixelYStart); - } - else - { - fX2toX3 += fX2toX3step * (fSubPixelYEnd - fSubPixelYStart); - } - - fX1toX3 += fX1toX3step * (fSubPixelYEnd - fSubPixelYStart); - } - - if (start != end) - { - if (yy >= m_iMinY && yy <= m_iMaxY) - { - if (!bTriangleCallDone) - { - inpSink->Triangle(yy); - bTriangleCallDone = true; - } - - lambertHorizlineSubpixelCorrect(start, end, yy, inpSink); - } - } - } -} - - - - -// shrink triangle by n pixel, optimizable -void CSimpleTriangleRasterizer::ShrinkTriangle(float inoutfX[3], float inoutfY[3], float infAmount) -{ - float fX[3] = { inoutfX[0], inoutfX[1], inoutfX[2] }; - float fY[3] = { inoutfY[0], inoutfY[1], inoutfY[2] }; - - /* - // move edge to opposing vertex - float dx,dy,fLength; - - for(int a=0;a<3;a++) - { - int b=a+1;if(b>=3)b=0; - int c=b+1;if(c>=3)c=0; - - dx=fX[a]-(fX[b]+fX[c])*0.5f; - dy=fY[a]-(fY[b]+fY[c])*0.5f; - fLength=(float)sqrt(dx*dx+dy*dy); - if(fLength>1.0f) - { - dx/=fLength;dy/=fLength; - inoutfX[b]+=dx;inoutfY[b]+=dy; - inoutfX[c]+=dx;inoutfY[c]+=dy; - } - } - */ - - /* - // move vertex to opposing edge - float dx,dy,fLength; - - for(int a=0;a<3;a++) - { - int b=a+1;if(b>=3)b=0; - int c=b+1;if(c>=3)c=0; - - dx=fX[a]-(fX[b]+fX[c])*0.5f; - dy=fY[a]-(fY[b]+fY[c])*0.5f; - fLength=(float)sqrt(dx*dx+dy*dy); - if(fLength>1.0f) - { - dx/=fLength;dy/=fLength; - inoutfX[a]-=dx;inoutfY[a]-=dy; - } - } - */ - - // move vertex to get edges shifted perpendicular for 1 unit - for (int a = 0; a < 3; a++) - { - float dx1, dy1, dx2, dy2, fLength; - - int b = a + 1; - if (b >= 3) - { - b = 0; - } - int c = b + 1; - if (c >= 3) - { - c = 0; - } - - dx1 = fX[b] - fX[a]; - dy1 = fY[b] - fY[a]; - fLength = (float)sqrt(dx1 * dx1 + dy1 * dy1); - if (infAmount > 0) - { - if (fLength < infAmount) - { - continue; - } - } - if (fLength == 0.0f) - { - continue; - } - dx1 /= fLength; - dy1 /= fLength; - - dx2 = fX[c] - fX[a]; - dy2 = fY[c] - fY[a]; - fLength = (float)sqrt(dx2 * dx2 + dy2 * dy2); - if (infAmount > 0) - { - if (fLength < infAmount) - { - continue; - } - } - if (fLength == 0.0f) - { - continue; - } - dx2 /= fLength; - dy2 /= fLength; - - inoutfX[a] += (dx1 + dx2) * infAmount; - inoutfY[a] += (dy1 + dy2) * infAmount; - } -} diff --git a/Code/Editor/LightmapCompiler/SimpleTriangleRasterizer.h b/Code/Editor/LightmapCompiler/SimpleTriangleRasterizer.h deleted file mode 100644 index bcfdd7b6da..0000000000 --- a/Code/Editor/LightmapCompiler/SimpleTriangleRasterizer.h +++ /dev/null @@ -1,181 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#ifndef CRYINCLUDE_EDITOR_LIGHTMAPCOMPILER_SIMPLETRIANGLERASTERIZER_H -#define CRYINCLUDE_EDITOR_LIGHTMAPCOMPILER_SIMPLETRIANGLERASTERIZER_H -#pragma once - -class CSimpleTriangleRasterizer -{ -public: - - class IRasterizeSink - { - public: - - //! is called once per triangel for the first possible visible line - //! /param iniStartY - virtual void Triangle([[maybe_unused]] const int iniStartY) - { - } - - //! callback function - //! /param infXLeft included - not clipped against left and reight border - //! /param infXRight excluded - not clipped against left and reight border - //! /param iniXLeft included - //! /param iniXRight excluded - //! /param iniY - virtual void Line(const float infXLeft, const float infXRight, - const int iniXLeft, const int iniXRight, const int iniY) = 0; - }; - - typedef unsigned long DWORD; - - // ----------------------------------------------------- - - //! implementation sink sample - class CDWORDFlatFill - : public IRasterizeSink - { - public: - - //! constructor - CDWORDFlatFill(DWORD* inpBuffer, const DWORD indwPitchInPixels, DWORD indwValue) - { - m_dwValue = indwValue; - m_pBuffer = inpBuffer; - m_dwPitchInPixels = indwPitchInPixels; - } - - virtual void Triangle(const int iniY) - { - m_pBufferLine = &m_pBuffer[iniY * m_dwPitchInPixels]; - } - - virtual void Line([[maybe_unused]] const float infXLeft, [[maybe_unused]] const float infXRight, - const int iniLeft, const int iniRight, [[maybe_unused]] const int iniY) - { - DWORD* mem = &m_pBufferLine[iniLeft]; - - for (int x = iniLeft; x < iniRight; x++) - { - *mem++ = m_dwValue; - } - - m_pBufferLine += m_dwPitchInPixels; - } - - private: - DWORD m_dwValue; //!< fill value - DWORD* m_pBufferLine; //!< to get rid of the multiplication per line - - DWORD m_dwPitchInPixels; //!< in DWORDS, not in Bytes - DWORD* m_pBuffer; //!< pointer to the buffer - }; - - // ----------------------------------------------------- - - //! constructor - //! /param iniWidth excluded - //! /param iniHeight excluded - CSimpleTriangleRasterizer(const int iniWidth, const int iniHeight) - { - m_iMinX = 0; - m_iMinY = 0; - m_iMaxX = iniWidth - 1; - m_iMaxY = iniHeight - 1; - } - /* - //! constructor - //! /param iniMinX included - //! /param iniMinY included - //! /param iniMaxX included - //! /param iniMaxY included - CSimpleTriangleRasterizer( const int iniMinX, const int iniMinY, const int iniMaxX, const int iniMaxY ) - { - m_iMinX=iniMinX; - m_iMinY=iniMinY; - m_iMaxX=iniMaxX; - m_iMaxY=iniMaxY; - } - */ - //! simple triangle filler with clipping (optimizable), not subpixel correct - //! /param pBuffer pointer o the color buffer - //! /param indwWidth width of the color buffer - //! /param indwHeight height of the color buffer - //! /param x array of the x coordiantes of the three vertices - //! /param y array of the x coordiantes of the three vertices - //! /param indwValue value of the triangle - void DWORDFlatFill(DWORD* inpBuffer, const DWORD indwPitchInPixels, float x[3], float y[3], DWORD indwValue, bool inbConservative) - { - CDWORDFlatFill pix(inpBuffer, indwPitchInPixels, indwValue); - - if (inbConservative) - { - CallbackFillConservative(x, y, &pix); - } - else - { - CallbackFillSubpixelCorrect(x, y, &pix); - } - } - - // Rectangle around triangle - more stable - use for debugging purpose - void CallbackFillRectConservative(float x[3], float y[3], IRasterizeSink * inpSink); - - - //! subpixel correct triangle filler (conservative or not conservative) - //! \param pBuffer pointe to the DWORD - //! \param indwWidth width of the buffer pBuffer pointes to - //! \param indwHeight height of the buffer pBuffer pointes to - //! \param x array of the x coordiantes of the three vertices - //! \param y array of the x coordiantes of the three vertices - //! \param inpSink pointer to the sink interface (is called per triangle and per triangle line) - void CallbackFillConservative(float x[3], float y[3], IRasterizeSink * inpSink); - - //! subpixel correct triangle filler (conservative or not conservative) - //! \param pBuffer pointe to the DWORD - //! \param indwWidth width of the buffer pBuffer pointes to - //! \param indwHeight height of the buffer pBuffer pointes to - //! \param x array of the x coordiantes of the three vertices - //! \param y array of the x coordiantes of the three vertices - //! \param inpSink pointer to the sink interface (is called per triangle and per triangle line) - void CallbackFillSubpixelCorrect(float x[3], float y[3], IRasterizeSink * inpSink); - - //! - //! /param inoutfX - //! /param inoutfY - //! /param infAmount could be positive or negative - static void ShrinkTriangle(float inoutfX[3], float inoutfY[3], float infAmount); - -private: - - // Clipping Rect; - - int m_iMinX; //!< minimum x value included - int m_iMinY; //!< minimum y value included - int m_iMaxX; //!< maximum x value included - int m_iMaxY; //!< maximum x value included - - void lambertHorizlineConservative(float fx1, float fx2, int y, IRasterizeSink* inpSink); - void lambertHorizlineSubpixelCorrect(float fx1, float fx2, int y, IRasterizeSink* inpSink); - void CopyAndSortY(const float infX[3], const float infY[3], float outfX[3], float outfY[3]); -}; - - -// extension ideas: -// * callback with coverage mask (possible non ordered sampling) -// * z-buffer behaviour -// * gouraud shading -// * texture mapping with nearest/bicubic/bilinear filter -// * further primitives: thick line, ellipse -// * build a template version -// * - -#endif // CRYINCLUDE_EDITOR_LIGHTMAPCOMPILER_SIMPLETRIANGLERASTERIZER_H diff --git a/Code/Editor/MainWindow.cpp b/Code/Editor/MainWindow.cpp index f92e39f285..bbebac96a3 100644 --- a/Code/Editor/MainWindow.cpp +++ b/Code/Editor/MainWindow.cpp @@ -643,11 +643,11 @@ void MainWindow::InitActions() .SetStatusTip(tr("Create a new slice")); am->AddAction(ID_FILE_OPEN_SLICE, tr("Open Slice...")) .SetStatusTip(tr("Open an existing slice")); -#endif am->AddAction(ID_FILE_SAVE_SELECTED_SLICE, tr("Save selected slice")).SetShortcut(tr("Alt+S")) .SetStatusTip(tr("Save the selected slice to the first level root")); am->AddAction(ID_FILE_SAVE_SLICE_TO_ROOT, tr("Save Slice to root")).SetShortcut(tr("Ctrl+Alt+S")) .SetStatusTip(tr("Save the selected slice to the top level root")); +#endif am->AddAction(ID_FILE_SAVE_LEVEL, tr("&Save")) .SetShortcut(tr("Ctrl+S")) .SetReserved() @@ -677,7 +677,9 @@ void MainWindow::InitActions() .RegisterUpdateCallback(cryEdit, &CCryEditApp::OnUpdateSelected); am->AddAction(ID_FILE_EXPORTOCCLUSIONMESH, tr("Export Occlusion Mesh")); am->AddAction(ID_FILE_EDITLOGFILE, tr("Show Log File")); +#ifdef ENABLE_SLICE_EDITOR am->AddAction(ID_FILE_RESAVESLICES, tr("Resave All Slices")); +#endif am->AddAction(ID_FILE_PROJECT_MANAGER_SETTINGS, tr("Edit Project Settings...")); am->AddAction(ID_FILE_PROJECT_MANAGER_NEW, tr("New Project...")); am->AddAction(ID_FILE_PROJECT_MANAGER_OPEN, tr("Open Project...")); diff --git a/Code/Editor/MainWindow.qrc b/Code/Editor/MainWindow.qrc index 4506a4a2a8..c68e05ef41 100644 --- a/Code/Editor/MainWindow.qrc +++ b/Code/Editor/MainWindow.qrc @@ -166,7 +166,6 @@ arhitype_tree_01.png arhitype_tree_02.png arhitype_tree_03.png - water.png bmp00005_00.png bmp00005_01.png bmp00005_02.png diff --git a/Code/Editor/NewLevelDialog.cpp b/Code/Editor/NewLevelDialog.cpp index c773acdb6f..a97eb30f57 100644 --- a/Code/Editor/NewLevelDialog.cpp +++ b/Code/Editor/NewLevelDialog.cpp @@ -115,7 +115,6 @@ CNewLevelDialog::~CNewLevelDialog() void CNewLevelDialog::OnStartup() { UpdateData(false); - setFocus(); } void CNewLevelDialog::UpdateData(bool fromUi) diff --git a/Code/Editor/NewLevelDialog.ui b/Code/Editor/NewLevelDialog.ui index 14227fbb53..93a88dc897 100644 --- a/Code/Editor/NewLevelDialog.ui +++ b/Code/Editor/NewLevelDialog.ui @@ -133,6 +133,9 @@ 1 + + LEVEL + diff --git a/Code/Editor/Objects/BaseObject.cpp b/Code/Editor/Objects/BaseObject.cpp index 86840789dd..c14547407b 100644 --- a/Code/Editor/Objects/BaseObject.cpp +++ b/Code/Editor/Objects/BaseObject.cpp @@ -36,12 +36,6 @@ // To use the Andrew's algorithm in order to make convex hull from the points, this header is needed. #include "Util/GeometryUtil.h" -namespace { - QColor kLinkColorParent = QColor(0, 255, 255); - QColor kLinkColorChild = QColor(0, 0, 255); - QColor kLinkColorGray = QColor(128, 128, 128); -} - extern CObjectManager* g_pObjectManager; ////////////////////////////////////////////////////////////////////////// @@ -761,72 +755,6 @@ void CBaseObject::SetModified(bool) { } -void CBaseObject::DrawDefault(DisplayContext& dc, const QColor& labelColor) -{ - Vec3 wp = GetWorldPos(); - - bool bDisplaySelectionHelper = false; - if (!CanBeDrawn(dc, bDisplaySelectionHelper)) - { - return; - } - - // Draw link between parent and child. - if (dc.flags & DISPLAY_LINKS) - { - if (GetParent()) - { - dc.DrawLine(GetParentAttachPointWorldTM().GetTranslation(), wp, IsFrozen() ? kLinkColorGray : kLinkColorParent, IsFrozen() ? kLinkColorGray : kLinkColorChild); - } - size_t nChildCount = GetChildCount(); - for (size_t i = 0; i < nChildCount; ++i) - { - const CBaseObject* pChild = GetChild(i); - dc.DrawLine(pChild->GetParentAttachPointWorldTM().GetTranslation(), pChild->GetWorldPos(), pChild->IsFrozen() ? kLinkColorGray : kLinkColorParent, pChild->IsFrozen() ? kLinkColorGray : kLinkColorChild); - } - } - - // Draw Bounding box - if (dc.flags & DISPLAY_BBOX) - { - AABB box; - GetBoundBox(box); - dc.SetColor(Vec3(1, 1, 1)); - dc.DrawWireBox(box.min, box.max); - } - - if (IsHighlighted()) - { - DrawHighlight(dc); - } - - if (IsSelected()) - { - DrawArea(dc); - - CSelectionGroup* pSelection = GetObjectManager()->GetSelection(); - - // If the number of selected object is over 2, the merged boundbox should be used to render the measurement axis. - if (!pSelection || (pSelection && pSelection->GetCount() == 1)) - { - DrawDimensions(dc); - } - } - - if (bDisplaySelectionHelper) - { - DrawSelectionHelper(dc, wp, labelColor, 1.0f); - } - else if (!(dc.flags & DISPLAY_HIDENAMES)) - { - DrawLabel(dc, wp, labelColor); - } - - SetDrawTextureIconProperties(dc, wp); - DrawTextureIcon(dc, wp); - DrawWarningIcons(dc, wp); -} - ////////////////////////////////////////////////////////////////////////// void CBaseObject::DrawDimensions(DisplayContext&, AABB*) { @@ -850,91 +778,6 @@ void CBaseObject::DrawSelectionHelper(DisplayContext& dc, const Vec3& pos, const dc.SetState(nPrevState); } -////////////////////////////////////////////////////////////////////////// -void CBaseObject::SetDrawTextureIconProperties(DisplayContext& dc, const Vec3& pos, float alpha, int texIconFlags) -{ - if (gSettings.viewports.bShowIcons || gSettings.viewports.bShowSizeBasedIcons) - { - if (IsHighlighted()) - { - dc.SetColor(QColor(255, 120, 0), 0.8f * alpha); - } - else if (IsSelected()) - { - dc.SetSelectedColor(alpha); - } - else if (IsFrozen()) - { - dc.SetFreezeColor(); - } - else - { - dc.SetColor(QColor(255, 255, 255), alpha); - } - - m_vDrawIconPos = pos; - - int nIconFlags = texIconFlags; - if (CheckFlags(OBJFLAG_SHOW_ICONONTOP)) - { - Vec3 objectPos = GetWorldPos(); - - AABB box; - GetBoundBox(box); - m_vDrawIconPos.z = (m_vDrawIconPos.z - objectPos.z) + box.max.z; - nIconFlags |= DisplayContext::TEXICON_ALIGN_BOTTOM; - } - m_nIconFlags = nIconFlags; - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseObject::DrawTextureIcon(DisplayContext& dc, [[maybe_unused]] const Vec3& pos, [[maybe_unused]] float alpha) -{ - if (m_nTextureIcon && (gSettings.viewports.bShowIcons || gSettings.viewports.bShowSizeBasedIcons)) - { - dc.DrawTextureLabel(GetTextureIconDrawPos(), OBJECT_TEXTURE_ICON_SIZEX, OBJECT_TEXTURE_ICON_SIZEY, GetTextureIcon(), GetTextureIconFlags()); - } -} - -////////////////////////////////////////////////////////////////////////// -void CBaseObject::DrawWarningIcons(DisplayContext& dc, const Vec3&) -{ - if (gSettings.viewports.bShowIcons || gSettings.viewports.bShowSizeBasedIcons) - { - const int warningIconSizeX = OBJECT_TEXTURE_ICON_SIZEX / 2; - const int warningIconSizeY = OBJECT_TEXTURE_ICON_SIZEY / 2; - - const int iconOffsetX = m_nTextureIcon ? (-OBJECT_TEXTURE_ICON_SIZEX / 2) : 0; - const int iconOffsetY = m_nTextureIcon ? (-OBJECT_TEXTURE_ICON_SIZEY / 2) : 0; - - if (gSettings.viewports.bShowScaleWarnings) - { - const EScaleWarningLevel scaleWarningLevel = GetScaleWarningLevel(); - - if (scaleWarningLevel != eScaleWarningLevel_None) - { - dc.SetColor(QColor(255, scaleWarningLevel == eScaleWarningLevel_RescaledNonUniform ? 50 : 255, 50), 1.0f); - dc.DrawTextureLabel(GetTextureIconDrawPos(), warningIconSizeX, warningIconSizeY, - GetIEditor()->GetIconManager()->GetIconTexture(eIcon_ScaleWarning), GetTextureIconFlags(), - -warningIconSizeX / 2, iconOffsetX - (warningIconSizeY / 2)); - } - } - - if (gSettings.viewports.bShowRotationWarnings) - { - const ERotationWarningLevel rotationWarningLevel = GetRotationWarningLevel(); - if (rotationWarningLevel != eRotationWarningLevel_None) - { - dc.SetColor(QColor(255, rotationWarningLevel == eRotationWarningLevel_RotatedNonRectangular ? 50 : 255, 50), 1.0f); - dc.DrawTextureLabel(GetTextureIconDrawPos(), warningIconSizeX, warningIconSizeY, - GetIEditor()->GetIconManager()->GetIconTexture(eIcon_RotationWarning), GetTextureIconFlags(), - warningIconSizeX / 2, iconOffsetY - (warningIconSizeY / 2)); - } - } - } -} - ////////////////////////////////////////////////////////////////////////// void CBaseObject::DrawLabel(DisplayContext& dc, const Vec3& pos, const QColor& lC, float alpha, float size) { diff --git a/Code/Editor/Objects/BaseObject.h b/Code/Editor/Objects/BaseObject.h index f78755e81d..fea248c7f7 100644 --- a/Code/Editor/Objects/BaseObject.h +++ b/Code/Editor/Objects/BaseObject.h @@ -398,9 +398,6 @@ public: // Interface to be implemented in plugins. ////////////////////////////////////////////////////////////////////////// - //! Draw object to specified viewport. - virtual void Display([[maybe_unused]] DisplayContext& disp) {} - //! Perform intersection testing of this object. //! Return true if was hit. virtual bool HitTest([[maybe_unused]] HitContext& hc) { return false; }; @@ -529,8 +526,6 @@ protected: void ResolveParent(CBaseObject* object); void SetColor(const QColor& color); - //! Draw default object items. - virtual void DrawDefault(DisplayContext& dc, const QColor& labelColor = QColor(255, 255, 255)); //! Draw object label. void DrawLabel(DisplayContext& dc, const Vec3& pos, const QColor& labelColor = QColor(255, 255, 255), float alpha = 1.0f, float size = 1.f); //! Draw 3D Axis at object position. @@ -539,10 +534,6 @@ protected: void DrawArea(DisplayContext& dc); //! Draw selection helper. void DrawSelectionHelper(DisplayContext& dc, const Vec3& pos, const QColor& labelColor = QColor(255, 255, 255), float alpha = 1.0f); - //! Draw helper icon. - virtual void DrawTextureIcon(DisplayContext& dc, const Vec3& pos, float alpha = 1.0f); - //! Draw warning icons - virtual void DrawWarningIcons(DisplayContext& dc, const Vec3& pos); //! Check if dimension's figures can be displayed before draw them. virtual void DrawDimensions(DisplayContext& dc, AABB* pMergedBoundBox = nullptr); @@ -575,7 +566,6 @@ protected: //! Only used by ObjectManager. bool IsPotentiallyVisible() const; - void SetDrawTextureIconProperties(DisplayContext& dc, const Vec3& pos, float alpha = 1.0f, int texIconFlags = 0); const Vec3& GetTextureIconDrawPos(){ return m_vDrawIconPos; }; int GetTextureIconFlags(){ return m_nIconFlags; }; diff --git a/Code/Editor/Objects/EntityObject.h b/Code/Editor/Objects/EntityObject.h index c3e379bccc..c6b7e4ce2d 100644 --- a/Code/Editor/Objects/EntityObject.h +++ b/Code/Editor/Objects/EntityObject.h @@ -27,6 +27,7 @@ #define CLASS_ENVIRONMENT_LIGHT "EnvironmentLight" class CEntityObject; +class CSelectionGroup; class QMenu; /*! diff --git a/Code/Editor/Objects/ObjectLoader.h b/Code/Editor/Objects/ObjectLoader.h index fc1014ad03..fa576fa983 100644 --- a/Code/Editor/Objects/ObjectLoader.h +++ b/Code/Editor/Objects/ObjectLoader.h @@ -13,6 +13,8 @@ #include "ErrorReport.h" #include +#include + class CErrorRecord; struct IObjectManager; diff --git a/Code/Editor/Objects/ObjectManager.cpp b/Code/Editor/Objects/ObjectManager.cpp index 1dea6ece7f..06233d4dd2 100644 --- a/Code/Editor/Objects/ObjectManager.cpp +++ b/Code/Editor/Objects/ObjectManager.cpp @@ -26,7 +26,6 @@ #include "Util/Image.h" #include "ObjectManagerLegacyUndo.h" #include "Include/HitContext.h" -#include "EditMode/DeepSelection.h" #include "Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.h" #include diff --git a/Code/Editor/Plugin.cpp b/Code/Editor/Plugin.cpp index 68f8d8833b..16c386e31c 100644 --- a/Code/Editor/Plugin.cpp +++ b/Code/Editor/Plugin.cpp @@ -155,7 +155,7 @@ IViewPaneClass* CClassFactory::FindViewPaneClassByTitle(const char* pPaneTitle) { IViewPaneClass* viewPane = nullptr; IClassDesc* desc = m_classes[i]; - if (SUCCEEDED(desc->QueryInterface(__uuidof(IViewPaneClass), (void**)&viewPane))) + if (SUCCEEDED(desc->QueryInterface(__az_uuidof(IViewPaneClass), (void**)&viewPane))) { if (QString::compare(viewPane->GetPaneTitle(), pPaneTitle) == 0) { diff --git a/Code/Editor/Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.cpp b/Code/Editor/Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.cpp index fbb700723b..a70c200417 100644 --- a/Code/Editor/Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.cpp +++ b/Code/Editor/Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.cpp @@ -723,97 +723,6 @@ CComponentEntityObject* CComponentEntityObject::FindObjectForEntity(AZ::EntityId return nullptr; } -void CComponentEntityObject::Display(DisplayContext& dc) -{ - if (!(dc.flags & DISPLAY_2D)) - { - m_entityIconVisible = false; - } - - bool displaySelectionHelper = false; - if (!CanBeDrawn(dc, displaySelectionHelper)) - { - return; - } - - DrawDefault(dc); - - bool showIcons = m_hasIcon; - if (showIcons) - { - SEditorSettings* editorSettings = GetIEditor()->GetEditorSettings(); - if (!editorSettings->viewports.bShowIcons && !editorSettings->viewports.bShowSizeBasedIcons) - { - showIcons = false; - } - } - - if (m_entityId.IsValid()) - { - // Draw link to parent if this or the parent object are selected. - { - AZ::EntityId parentId; - EBUS_EVENT_ID_RESULT(parentId, m_entityId, AZ::TransformBus, GetParentId); - if (parentId.IsValid()) - { - bool isParentVisible = false; - AzToolsFramework::EditorEntityInfoRequestBus::EventResult(isParentVisible, parentId, &AzToolsFramework::EditorEntityInfoRequestBus::Events::IsVisible); - - CComponentEntityObject* parentObject = CComponentEntityObject::FindObjectForEntity(parentId); - if (isParentVisible && (IsSelected() || (parentObject && parentObject->IsSelected()))) - { - const QColor kLinkColorParent(0, 255, 255); - const QColor kLinkColorChild(0, 0, 255); - - AZ::Vector3 parentTranslation; - EBUS_EVENT_ID_RESULT(parentTranslation, parentId, AZ::TransformBus, GetWorldTranslation); - dc.DrawLine(AZVec3ToLYVec3(parentTranslation), GetWorldTM().GetTranslation(), kLinkColorParent, kLinkColorChild); - } - } - } - - // Don't draw icons if we have an ancestor in the same location that has an icon - makes sure - // ancestor icons draw on top and are able to be selected over children. Also check if a descendant - // is selected at the same location. In cases of entity hierarchies where numerous ancestors have - // no position offset, we need this so the ancestors don't draw over us when we're selected - if (showIcons) - { - if ((dc.flags & DISPLAY_2D) || - IsSelected() || - IsAncestorIconDrawingAtSameLocation() || - IsDescendantSelectedAtSameLocation()) - { - showIcons = false; - } - } - - // Allow components to override in-editor visualization. - { - const AzFramework::DisplayContextRequestGuard displayContextGuard(dc); - - AzFramework::DebugDisplayRequestBus::BusPtr debugDisplayBus; - AzFramework::DebugDisplayRequestBus::Bind( - debugDisplayBus, AzFramework::g_defaultSceneEntityDebugDisplayId); - AZ_Assert(debugDisplayBus, "Invalid DebugDisplayRequestBus."); - - AzFramework::DebugDisplayRequests* debugDisplay = - AzFramework::DebugDisplayRequestBus::FindFirstHandler(debugDisplayBus); - - AzFramework::EntityDebugDisplayEventBus::Event( - m_entityId, &AzFramework::EntityDebugDisplayEvents::DisplayEntityViewport, - AzFramework::ViewportInfo{ dc.GetView()->asCViewport()->GetViewportId() }, - *debugDisplay); - } - } -} - -void CComponentEntityObject::DrawDefault(DisplayContext& dc, const QColor& labelColor) -{ - CEntityObject::DrawDefault(dc, labelColor); - - DrawAccent(dc); -} - bool CComponentEntityObject::IsIsolated() const { return m_isIsolated; diff --git a/Code/Editor/Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.h b/Code/Editor/Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.h index 7ccea8da84..62209965a5 100644 --- a/Code/Editor/Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.h +++ b/Code/Editor/Plugins/ComponentEntityEditorPlugin/Objects/ComponentEntityObject.h @@ -55,7 +55,6 @@ public: bool SetRotation(const Quat& rotate, int flags) override; bool SetScale(const Vec3& scale, int flags) override; void InvalidateTM(int nWhyFlags) override; - void Display(DisplayContext& disp) override; bool HitTest(HitContext& hc) override; void GetLocalBounds(AABB& box) override; void GetBoundBox(AABB& box) override; @@ -69,7 +68,6 @@ public: void DetachThis(bool bKeepPos = true) override; XmlNodeRef Export(const QString& levelPath, XmlNodeRef& xmlNode) override; void DeleteEntity() override; - void DrawDefault(DisplayContext& dc, const QColor& labelColor = QColor(255, 255, 255)) override; bool IsIsolated() const override; bool IsSelected() const override; diff --git a/Code/Editor/Plugins/ComponentEntityEditorPlugin/UI/Outliner/OutlinerListModel.cpp b/Code/Editor/Plugins/ComponentEntityEditorPlugin/UI/Outliner/OutlinerListModel.cpp index 08d79adcf5..1c361b050d 100644 --- a/Code/Editor/Plugins/ComponentEntityEditorPlugin/UI/Outliner/OutlinerListModel.cpp +++ b/Code/Editor/Plugins/ComponentEntityEditorPlugin/UI/Outliner/OutlinerListModel.cpp @@ -53,6 +53,7 @@ #include #include #include +#include #include "OutlinerDisplayOptionsMenu.h" #include "OutlinerSortFilterProxyModel.hxx" @@ -252,17 +253,7 @@ QVariant OutlinerListModel::dataForName(const QModelIndex& index, int role) cons if (s_paintingName && !m_filterString.empty()) { // highlight characters in filter - int highlightTextIndex = 0; - do - { - highlightTextIndex = label.lastIndexOf(QString(m_filterString.c_str()), highlightTextIndex - 1, Qt::CaseInsensitive); - if (highlightTextIndex >= 0) - { - const QString BACKGROUND_COLOR{ "#707070" }; - label.insert(static_cast(highlightTextIndex + m_filterString.length()), ""); - label.insert(highlightTextIndex, ""); - } - } while(highlightTextIndex > 0); + label = AzToolsFramework::RichTextHighlighter::HighlightText(label, m_filterString.c_str()); } return label; } @@ -2609,16 +2600,11 @@ void OutlinerItemDelegate::paint(QPainter* painter, const QStyleOptionViewItem& optionV4.widget->style()->drawControl(QStyle::CE_ItemViewItem, &optionV4, painter); // Now we setup a Text Document so it can draw the rich text - QTextDocument textDoc; - textDoc.setDefaultFont(optionV4.font); - textDoc.setDefaultStyleSheet("body {color: white}"); - textDoc.setHtml("" + entityNameRichText + ""); int verticalOffset = GetEntityNameVerticalOffset(entityId); painter->translate(textRect.topLeft() + QPoint(0, verticalOffset)); - textDoc.setTextWidth(textRect.width()); - textDoc.drawContents(painter, QRectF(0, 0, textRect.width(), textRect.height())); - painter->restore(); + AzToolsFramework::RichTextHighlighter::PaintHighlightedRichText(entityNameRichText, painter, optionV4, textRect); + OutlinerListModel::s_paintingName = false; } else diff --git a/Code/Editor/Plugins/PerforcePlugin/PerforceSourceControl.h b/Code/Editor/Plugins/PerforcePlugin/PerforceSourceControl.h index ec06fdc82a..794dca0f86 100644 --- a/Code/Editor/Plugins/PerforcePlugin/PerforceSourceControl.h +++ b/Code/Editor/Plugins/PerforcePlugin/PerforceSourceControl.h @@ -49,7 +49,7 @@ public: // from IUnknown HRESULT STDMETHODCALLTYPE QueryInterface(const IID& riid, void** ppvObj) { - if (riid == __uuidof(ISourceControl) /* && m_pIntegrator*/) + if (riid == __az_uuidof(ISourceControl) /* && m_pIntegrator*/) { *ppvObj = this; return S_OK; diff --git a/Code/Editor/PreferencesStdPages.cpp b/Code/Editor/PreferencesStdPages.cpp index 1dd40702a7..77b912a44e 100644 --- a/Code/Editor/PreferencesStdPages.cpp +++ b/Code/Editor/PreferencesStdPages.cpp @@ -50,7 +50,7 @@ CStdPreferencesClassDesc::CStdPreferencesClassDesc() HRESULT CStdPreferencesClassDesc::QueryInterface(const IID& riid, void** ppvObj) { - if (riid == __uuidof(IPreferencesPageCreator)) + if (riid == __az_uuidof(IPreferencesPageCreator)) { *ppvObj = (IPreferencesPageCreator*)this; return S_OK; diff --git a/Code/Editor/QtUI/ClickableLabel.cpp b/Code/Editor/QtUI/ClickableLabel.cpp deleted file mode 100644 index b0694e5f18..0000000000 --- a/Code/Editor/QtUI/ClickableLabel.cpp +++ /dev/null @@ -1,101 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#include "EditorDefs.h" - -#include "ClickableLabel.h" - - -ClickableLabel::ClickableLabel(const QString& text, QWidget* parent) - : QLabel(parent) - , m_text(text) - , m_showDecoration(false) -{ - setTextFormat(Qt::RichText); - setTextInteractionFlags(Qt::TextBrowserInteraction); -} - -ClickableLabel::ClickableLabel(QWidget* parent) - : QLabel(parent) - , m_showDecoration(false) -{ - setTextFormat(Qt::RichText); - setTextInteractionFlags(Qt::TextBrowserInteraction); -} - -void ClickableLabel::showEvent([[maybe_unused]] QShowEvent* event) -{ - updateFormatting(false); -} - -void ClickableLabel::enterEvent(QEvent* ev) -{ - if (!isEnabled()) - { - return; - } - - updateFormatting(true); - QApplication::setOverrideCursor(QCursor(Qt::PointingHandCursor)); - QLabel::enterEvent(ev); -} - -void ClickableLabel::leaveEvent(QEvent* ev) -{ - if (!isEnabled()) - { - return; - } - - updateFormatting(false); - QApplication::restoreOverrideCursor(); - QLabel::leaveEvent(ev); -} - -void ClickableLabel::setText(const QString& text) -{ - m_text = text; - QLabel::setText(text); - updateFormatting(false); -} - -void ClickableLabel::setShowDecoration(bool b) -{ - m_showDecoration = b; - updateFormatting(false); -} - -void ClickableLabel::updateFormatting(bool mouseOver) -{ - //FIXME: this should be done differently. Using a style sheet would be easiest. - - QColor c = palette().color(QPalette::WindowText); - if (mouseOver || m_showDecoration) - { - QLabel::setText(QString(R"(%2)").arg(c.name(), m_text)); - } - else - { - QLabel::setText(m_text); - } -} - -bool ClickableLabel::event(QEvent* e) -{ - if (isEnabled()) - { - if (e->type() == QEvent::MouseButtonDblClick) - { - emit linkActivated(QString()); - return true; //ignore - } - } - - return QLabel::event(e); -} - -#include diff --git a/Code/Editor/QtUI/ClickableLabel.h b/Code/Editor/QtUI/ClickableLabel.h deleted file mode 100644 index 2b14676eae..0000000000 --- a/Code/Editor/QtUI/ClickableLabel.h +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once -#ifndef CRYINCLUDE_EDITORCOMMON_CLICKABLELABEL_H -#define CRYINCLUDE_EDITORCOMMON_CLICKABLELABEL_H - -#if !defined(Q_MOC_RUN) -#include -#endif - -class SANDBOX_API ClickableLabel - : public QLabel -{ - Q_OBJECT -public: - explicit ClickableLabel(const QString& text, QWidget* parent = nullptr); - explicit ClickableLabel(QWidget* parent = nullptr); - bool event(QEvent* e) override; - - void setText(const QString& text); - void setShowDecoration(bool b); - -protected: - void showEvent(QShowEvent* event) override; - void enterEvent(QEvent* ev) override; - void leaveEvent(QEvent* ev) override; - -private: - void updateFormatting(bool mouseOver); - QString m_text; - bool m_showDecoration; -}; - -#endif diff --git a/Code/Editor/Resource.h b/Code/Editor/Resource.h index 432f07a531..ef72bfc9be 100644 --- a/Code/Editor/Resource.h +++ b/Code/Editor/Resource.h @@ -196,7 +196,6 @@ #define ID_FILE_EXPORT_TERRAINAREA 33904 #define ID_FILE_EXPORT_TERRAINAREAWITHOBJECTS 33910 #define ID_FILE_EXPORT_SELECTEDOBJECTS 33911 -#define ID_TERRAIN_TIMEOFDAY 33912 #define ID_SPLINE_PREVIOUS_KEY 33916 #define ID_SPLINE_NEXT_KEY 33917 #define ID_SPLINE_FLATTEN_ALL 33918 @@ -290,7 +289,6 @@ #define ID_TV_TRACKS_TOOLBAR_LAST 35183 // for up to 100 "Add Tracks..." dynamically added Track View Track buttons #define ID_OPEN_TERRAIN_EDITOR 36007 #define ID_OPEN_UICANVASEDITOR 36010 -#define ID_TERRAIN_TIMEOFDAYBUTTON 36011 #define ID_OPEN_TERRAINTEXTURE_EDITOR 36012 #define ID_SKINS_REFRESH 36014 #define ID_FILE_GENERATETERRAIN 36016 diff --git a/Code/Editor/Settings.cpp b/Code/Editor/Settings.cpp index acb48c3545..8561e6dba3 100644 --- a/Code/Editor/Settings.cpp +++ b/Code/Editor/Settings.cpp @@ -142,9 +142,6 @@ SEditorSettings::SEditorSettings() viewports.bShowMeshStatsOnMouseOver = false; viewports.bDrawEntityLabels = false; viewports.bShowTriggerBounds = false; - viewports.bShowIcons = true; - viewports.bDistanceScaleIcons = true; - viewports.bShowSizeBasedIcons = false; viewports.nShowFrozenHelpers = true; viewports.bFillSelectedShapes = false; viewports.nTopMapTextureResolution = 512; @@ -534,8 +531,6 @@ void SEditorSettings::Save(bool isEditorClosing) SaveValue("Settings", "ShowMeshStatsOnMouseOver", viewports.bShowMeshStatsOnMouseOver); SaveValue("Settings", "DrawEntityLabels", viewports.bDrawEntityLabels); SaveValue("Settings", "ShowTriggerBounds", viewports.bShowTriggerBounds); - SaveValue("Settings", "ShowIcons", viewports.bShowIcons); - SaveValue("Settings", "ShowSizeBasedIcons", viewports.bShowSizeBasedIcons); SaveValue("Settings", "ShowFrozenHelpers", viewports.nShowFrozenHelpers); SaveValue("Settings", "FillSelectedShapes", viewports.bFillSelectedShapes); SaveValue("Settings", "MapTextureResolution", viewports.nTopMapTextureResolution); @@ -736,8 +731,6 @@ void SEditorSettings::Load() LoadValue("Settings", "ShowMeshStatsOnMouseOver", viewports.bShowMeshStatsOnMouseOver); LoadValue("Settings", "DrawEntityLabels", viewports.bDrawEntityLabels); LoadValue("Settings", "ShowTriggerBounds", viewports.bShowTriggerBounds); - LoadValue("Settings", "ShowIcons", viewports.bShowIcons); - LoadValue("Settings", "ShowSizeBasedIcons", viewports.bShowSizeBasedIcons); LoadValue("Settings", "ShowFrozenHelpers", viewports.nShowFrozenHelpers); LoadValue("Settings", "FillSelectedShapes", viewports.bFillSelectedShapes); LoadValue("Settings", "MapTextureResolution", viewports.nTopMapTextureResolution); diff --git a/Code/Editor/Settings.h b/Code/Editor/Settings.h index 9276d9b715..0ebb70501d 100644 --- a/Code/Editor/Settings.h +++ b/Code/Editor/Settings.h @@ -136,13 +136,6 @@ struct SViewportsSettings bool bDrawEntityLabels; //! Show Trigger bounds. bool bShowTriggerBounds; - //! Show Icons in viewport. - bool bShowIcons; - //! Scale icons with distance, so they aren't a fixed size no matter how far away you are - bool bDistanceScaleIcons; - - //! Show Size-based Icons in viewport. - bool bShowSizeBasedIcons; //! Show Helpers in viewport for frozen objects. int nShowFrozenHelpers; diff --git a/Code/Editor/TimeOfDay/main-00.png b/Code/Editor/TimeOfDay/main-00.png deleted file mode 100644 index 2c44fec541..0000000000 --- a/Code/Editor/TimeOfDay/main-00.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:5201dbba6c8114914ed680b04b72a5e18e22c0519a514bcccdc7ae8d32670b4e -size 993 diff --git a/Code/Editor/TimeOfDay/main-01.png b/Code/Editor/TimeOfDay/main-01.png deleted file mode 100644 index 5cc1bf33d8..0000000000 --- a/Code/Editor/TimeOfDay/main-01.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:48a7250ad41c5e298079ddd13910b58baca2ef592defcc162ccc9df542d28905 -size 981 diff --git a/Code/Editor/TimeOfDay/main-02.png b/Code/Editor/TimeOfDay/main-02.png deleted file mode 100644 index b7d90648a3..0000000000 --- a/Code/Editor/TimeOfDay/main-02.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:98b9e9abcc54b4f3e6903ad74bb50f364bfe4c8cd9fedc9653a6603d64a1ee0a -size 838 diff --git a/Code/Editor/TimeOfDay/main-03.png b/Code/Editor/TimeOfDay/main-03.png deleted file mode 100644 index e073dbf60b..0000000000 --- a/Code/Editor/TimeOfDay/main-03.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:1199c834fc8de69f9d7c76e8c7fbd84e9b92713b9f07b513137085e5089432cb -size 857 diff --git a/Code/Editor/TimeOfDay/main-04.png b/Code/Editor/TimeOfDay/main-04.png deleted file mode 100644 index 6049dbfe18..0000000000 --- a/Code/Editor/TimeOfDay/main-04.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:79b44be1dbe5518e06dc8c8823d00462136d39ffe60a32ef4f64dc0712654d33 -size 646 diff --git a/Code/Editor/TimeOfDay/main-05.png b/Code/Editor/TimeOfDay/main-05.png deleted file mode 100644 index 054419f39a..0000000000 --- a/Code/Editor/TimeOfDay/main-05.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:6ea7450c1a278570e2a1dba3a8b4d7d4e5f0d054e8371139ebdb5220c405d355 -size 537 diff --git a/Code/Editor/TimeOfDay/main-06.png b/Code/Editor/TimeOfDay/main-06.png deleted file mode 100644 index 35f8afdae2..0000000000 --- a/Code/Editor/TimeOfDay/main-06.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:bc73f0720f2ff877aff5c6646938b7fc509a69d92e766fecb9fa010eecadee7b -size 606 diff --git a/Code/Editor/TimeOfDay/main-07.png b/Code/Editor/TimeOfDay/main-07.png deleted file mode 100644 index aca9597355..0000000000 --- a/Code/Editor/TimeOfDay/main-07.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:e63519ed54fc19a4b4a2a38cb2c5f148b7404ac614d4aab039b71fee64cd7425 -size 569 diff --git a/Code/Editor/TimeOfDay/main-08.png b/Code/Editor/TimeOfDay/main-08.png deleted file mode 100644 index abeb114fc2..0000000000 --- a/Code/Editor/TimeOfDay/main-08.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8742cad4b8f8f5bba59abb9cc028db84de222ed8b393398f6837fea16bb4a1d8 -size 563 diff --git a/Code/Editor/TimeOfDay/main-09.png b/Code/Editor/TimeOfDay/main-09.png deleted file mode 100644 index cc77b8c9e2..0000000000 --- a/Code/Editor/TimeOfDay/main-09.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:ef85628301b4edc4f858f0988e4f072772be3feb92d27a2ec33b72a27bcee7ff -size 583 diff --git a/Code/Editor/TimeOfDay/main-10.png b/Code/Editor/TimeOfDay/main-10.png deleted file mode 100644 index dc463c6497..0000000000 --- a/Code/Editor/TimeOfDay/main-10.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:d17bfbdee6d37566b241adf64241ef47b62145aaac3e9e8f9691d1fb866b5fcb -size 717 diff --git a/Code/Editor/TimeOfDay/main-11.png b/Code/Editor/TimeOfDay/main-11.png deleted file mode 100644 index d686ab18c8..0000000000 --- a/Code/Editor/TimeOfDay/main-11.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:98b629abf927bcea41d8857b1761d12a37836471d7106b2f5210337c0ace0d9c -size 1103 diff --git a/Code/Editor/TimeOfDay/main-12.png b/Code/Editor/TimeOfDay/main-12.png deleted file mode 100644 index 069510ab24..0000000000 --- a/Code/Editor/TimeOfDay/main-12.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:e949111b33e28834995807cab30ecb58d988a81a2d58fa166117962c85b8e149 -size 849 diff --git a/Code/Editor/TrackView/TrackViewSequence.h b/Code/Editor/TrackView/TrackViewSequence.h index a392ad00f9..8f686af0cb 100644 --- a/Code/Editor/TrackView/TrackViewSequence.h +++ b/Code/Editor/TrackView/TrackViewSequence.h @@ -11,6 +11,7 @@ #define CRYINCLUDE_EDITOR_TRACKVIEW_TRACKVIEWSEQUENCE_H #pragma once +#include #include "IMovieSystem.h" #include diff --git a/Code/Editor/TrackView/TrackViewSequenceManager.cpp b/Code/Editor/TrackView/TrackViewSequenceManager.cpp index d7c1e3c709..515af4df38 100644 --- a/Code/Editor/TrackView/TrackViewSequenceManager.cpp +++ b/Code/Editor/TrackView/TrackViewSequenceManager.cpp @@ -408,20 +408,6 @@ void CTrackViewSequenceManager::OnSequenceRemoved(CTrackViewSequence* sequence) } } -//////////////////////////////////////////////////////////////////////////// -void CTrackViewSequenceManager::OnDataBaseItemEvent([[maybe_unused]] IDataBaseItem* pItem, EDataBaseItemEvent event) -{ - if (event != EDataBaseItemEvent::EDB_ITEM_EVENT_ADD) - { - const size_t numSequences = m_sequences.size(); - - for (size_t i = 0; i < numSequences; ++i) - { - m_sequences[i]->UpdateDynamicParams(); - } - } -} - //////////////////////////////////////////////////////////////////////////// CTrackViewAnimNodeBundle CTrackViewSequenceManager::GetAllRelatedAnimNodes(const AZ::EntityId entityId) const { diff --git a/Code/Editor/TrackView/TrackViewSequenceManager.h b/Code/Editor/TrackView/TrackViewSequenceManager.h index 1474323dc6..6c65a7f1a9 100644 --- a/Code/Editor/TrackView/TrackViewSequenceManager.h +++ b/Code/Editor/TrackView/TrackViewSequenceManager.h @@ -13,13 +13,11 @@ #include "TrackViewSequence.h" -#include "IDataBaseManager.h" #include class CTrackViewSequenceManager : public IEditorNotifyListener - , public IDataBaseManagerListener , public ITrackViewSequenceManager , public AZ::EntitySystemBus::Handler { @@ -65,8 +63,6 @@ private: void OnSequenceAdded(CTrackViewSequence* pSequence); void OnSequenceRemoved(CTrackViewSequence* pSequence); - void OnDataBaseItemEvent(IDataBaseItem* pItem, EDataBaseItemEvent event) override; - // AZ::EntitySystemBus void OnEntityNameChanged(const AZ::EntityId& entityId, const AZStd::string& name) override; void OnEntityDestruction(const AZ::EntityId& entityId) override; diff --git a/Code/Editor/Util/EditorUtils.cpp b/Code/Editor/Util/EditorUtils.cpp index adae34773a..47264a51ab 100644 --- a/Code/Editor/Util/EditorUtils.cpp +++ b/Code/Editor/Util/EditorUtils.cpp @@ -176,23 +176,6 @@ QString TrimTrailingZeros(QString str) return str; } -////////////////////////////////////////////////////////////////////////// -// This function is supposed to format float in user-friendly way, -// omitting the exponent notation. -// -// Why not using printf? Its formatting rules has following drawbacks: -// %g - will use exponent for small numbers; -// %.Nf - doesn't allow to control total amount of significant numbers, -// which exposes limited precision during binary-to-decimal fraction -// conversion. -////////////////////////////////////////////////////////////////////////// -void FormatFloatForUI(QString& str, int significantDigits, double value) -{ - str = TrimTrailingZeros(QString::number(value, 'f', significantDigits)); - return; -} -//////////////////////////////////////////////////////////////////////////- - ////////////////////////////////////////////////////////////////////////// QColor ColorLinearToGamma(ColorF col) { diff --git a/Code/Editor/Util/EditorUtils.h b/Code/Editor/Util/EditorUtils.h index e950d75012..5a69633d0f 100644 --- a/Code/Editor/Util/EditorUtils.h +++ b/Code/Editor/Util/EditorUtils.h @@ -212,22 +212,6 @@ namespace XmlHelpers ////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////// -// Drag Drop helper functions -////////////////////////////////////////////////////////////////////////// -namespace EditorDragDropHelpers -{ - inline QString GetAnimationNameClipboardFormat() - { - return QStringLiteral("application/x-animation-browser-copy"); - } - - inline QString GetFragmentClipboardFormat() - { - return QStringLiteral("application/x-preview-fragment-properties"); - } -} - ////////////////////////////////////////////////////////////////////////// /*! @@ -292,116 +276,6 @@ public: } }; - -////////////////////////////////////////////////////////////////////////// -// -// Convert String representation of color to RGB integer value. -// -////////////////////////////////////////////////////////////////////////// -inline QColor String2Color(const QString& val) -{ - unsigned int r = 0, g = 0, b = 0; - int res = 0; - res = azsscanf(val.toUtf8().data(), "R:%d,G:%d,B:%d", &r, &g, &b); - if (res != 3) - { - res = azsscanf(val.toUtf8().data(), "R:%d G:%d B:%d", &r, &g, &b); - } - if (res != 3) - { - res = azsscanf(val.toUtf8().data(), "%d,%d,%d", &r, &g, &b); - } - if (res != 3) - { - res = azsscanf(val.toUtf8().data(), "%d %d %d", &r, &g, &b); - } - if (res != 3) - { - azsscanf(val.toUtf8().data(), "%x", &r); - return r; - } - - return QColor(r, g, b); -} - -// Converts QColor to Vector. -inline Vec3 Rgb2Vec(const QColor& color) -{ - return Vec3(aznumeric_cast(color.redF()), aznumeric_cast(color.greenF()), aznumeric_cast(color.blueF())); -} - -// Converts QColor to ColorF. -inline ColorF Rgb2ColorF(const QColor& color) -{ - return ColorF(aznumeric_cast(color.redF()), aznumeric_cast(color.greenF()), aznumeric_cast(color.blueF()), 1.0f); -} - -// Converts QColor to Vector. -inline QColor Vec2Rgb(const Vec3& color) -{ - return QColor(aznumeric_cast(color.x * 255), aznumeric_cast(color.y * 255), aznumeric_cast(color.z * 255)); -} - -// Converts ColorF to QColor. -inline QColor ColorF2Rgb(const ColorF& color) -{ - return QColor(aznumeric_cast(color.r * 255), aznumeric_cast(color.g * 255), aznumeric_cast(color.b * 255)); -} - -////////////////////////////////////////////////////////////////////////// -// Tokenize string. -////////////////////////////////////////////////////////////////////////// -inline QString TokenizeString(const QString& s, LPCSTR pszTokens, int& iStart) -{ - assert(iStart >= 0); - - QByteArray str = s.toUtf8(); - - if (pszTokens == nullptr) - { - return str; - } - - auto pszPlace = str.begin() + iStart; - auto pszEnd = str.end(); - if (pszPlace < pszEnd) - { - int nIncluding = (int)strspn(pszPlace, pszTokens); - ; - - if ((pszPlace + nIncluding) < pszEnd) - { - pszPlace += nIncluding; - int nExcluding = (int)strcspn(pszPlace, pszTokens); - - int iFrom = iStart + nIncluding; - int nUntil = nExcluding; - iStart = iFrom + nUntil + 1; - - return (str.mid(iFrom, nUntil)); - } - } - - // return empty string, done tokenizing - iStart = -1; - return ""; -} - -// This template function will join strings from a vector into a single string, using a separator char -template -inline void JoinStrings(const QList& rStrings, QString& rDestStr, char aSeparator = ',') -{ - for (size_t i = 0, iCount = rStrings.size(); i < iCount; ++i) - { - rDestStr += rStrings[i]; - - if (i < iCount - 1) - { - rDestStr += aSeparator; - } - } -} - // This function will split a string containing separated strings, into a vector of strings // better version of TokenizeString inline void SplitString(const QString& rSrcStr, QStringList& rDestStrings, char aSeparator = ',') @@ -435,45 +309,6 @@ inline void SplitString(const QString& rSrcStr, QStringList& rDestStrings, char } } -// Format unsigned number to string with 1000s separator -inline QString FormatWithThousandsSeperator(const unsigned int number) -{ - QString string; - - string = QString::number(number); - - for (int p = string.length() - 3; p > 0; p -= 3) - { - string.insert(p, ','); - } - - return string; -} - - -void FormatFloatForUI(QString& str, int significantDigits, double value); - -////////////////////////////////////////////////////////////////////////// -// Simply sub string searching case insensitive. -////////////////////////////////////////////////////////////////////////// -inline const char* strstri(const char* pString, const char* pSubstring) -{ - int i, j, k; - for (i = 0; pString[i]; i++) - { - for (j = i, k = 0; tolower(pString[j]) == tolower(pSubstring[k]); j++, k++) - { - if (!pSubstring[k + 1]) - { - return (pString + i); - } - } - } - - return nullptr; -} - - inline bool CheckVirtualKey(Qt::MouseButton button) { return (qApp->property("pressedMouseButtons").toInt() & button) != 0; diff --git a/Code/Editor/Util/FileUtil.cpp b/Code/Editor/Util/FileUtil.cpp index 9f96d45381..ce2d399dcc 100644 --- a/Code/Editor/Util/FileUtil.cpp +++ b/Code/Editor/Util/FileUtil.cpp @@ -42,8 +42,6 @@ #include "CheckOutDialog.h" #include "ISourceControl.h" #include "Dialogs/Generic/UserOptions.h" -#include "IAssetItem.h" -#include "IAssetItemDatabase.h" #include "Include/IObjectManager.h" #include "UsedResources.h" #include "Objects/BaseObject.h" @@ -223,106 +221,6 @@ void CFileUtil::EditTextureFile(const char* textureFile, [[maybe_unused]] bool b } } - -////////////////////////////////////////////////////////////////////////// -bool CFileUtil::CalculateDccFilename(const QString& assetFilename, QString& dccFilename) -{ - if (ExtractDccFilenameFromAssetDatabase(assetFilename, dccFilename)) - { - return true; - } - - if (ExtractDccFilenameUsingNamingConventions(assetFilename, dccFilename)) - { - return true; - } - - GetIEditor()->GetEnv()->pLog->LogError("Failed to find psd file for texture: '%s'", assetFilename.toUtf8().data()); - return false; -} - -////////////////////////////////////////////////////////////////////////// -bool CFileUtil::ExtractDccFilenameFromAssetDatabase(const QString& assetFilename, QString& dccFilename) -{ - IAssetItemDatabase* pCurrentDatabaseInterface = nullptr; - std::vector assetDatabasePlugins; - IEditorClassFactory* pClassFactory = GetIEditor()->GetClassFactory(); - pClassFactory->GetClassesByCategory("Asset Item DB", assetDatabasePlugins); - - for (size_t i = 0; i < assetDatabasePlugins.size(); ++i) - { - if (assetDatabasePlugins[i]->QueryInterface(__uuidof(IAssetItemDatabase), (void**)&pCurrentDatabaseInterface) == S_OK) - { - if (!pCurrentDatabaseInterface) - { - continue; - } - - QString assetDatabaseDccFilename; - IAssetItem* pAssetItem = pCurrentDatabaseInterface->GetAsset(assetFilename.toUtf8().data()); - if (pAssetItem) - { - if ((pAssetItem->GetFlags() & IAssetItem::eFlag_Cached)) - { - QVariant v = pAssetItem->GetAssetFieldValue("dccfilename"); - assetDatabaseDccFilename = v.toString(); - if (!v.isNull()) - { - dccFilename = assetDatabaseDccFilename; - dccFilename = Path::GetRelativePath(dccFilename, false); - - uint32 attr = CFileUtil::GetAttributes(dccFilename.toUtf8().data()); - - if (CFileUtil::FileExists(dccFilename)) - { - return true; - } - else if (GetIEditor()->IsSourceControlAvailable() && (attr & SCC_FILE_ATTRIBUTE_MANAGED)) - { - return CFileUtil::GetLatestFromSourceControl(dccFilename.toUtf8().data()); - } - } - } - } - } - } - return false; -} - -////////////////////////////////////////////////////////////////////////// -bool CFileUtil::ExtractDccFilenameUsingNamingConventions(const QString& assetFilename, QString& dccFilename) -{ - //else to try find it by naming conventions - QString tempStr = assetFilename; - int foundSplit = -1; - if ((foundSplit = tempStr.lastIndexOf('.')) > 0) - { - QString first = tempStr.mid(0, foundSplit); - tempStr = first + ".psd"; - } - if (CFileUtil::FileExists(tempStr)) - { - dccFilename = tempStr; - return true; - } - - //else try to find it by replacing post fix _ with .psd - tempStr = assetFilename; - foundSplit = -1; - if ((foundSplit = tempStr.lastIndexOf('_')) > 0) - { - QString first = tempStr.mid(0, foundSplit); - tempStr = first + ".psd"; - } - if (CFileUtil::FileExists(tempStr)) - { - dccFilename = tempStr; - return true; - } - - return false; -} - ////////////////////////////////////////////////////////////////////////// void CFileUtil::FormatFilterString(QString& filter) { diff --git a/Code/Editor/Util/FileUtil.h b/Code/Editor/Util/FileUtil.h index fc0fc942fe..a4ff5009a2 100644 --- a/Code/Editor/Util/FileUtil.h +++ b/Code/Editor/Util/FileUtil.h @@ -29,9 +29,6 @@ public: static void EditTextFile(const char* txtFile, int line = 0, IFileUtil::ETextFileType fileType = IFileUtil::FILE_TYPE_SCRIPT); static void EditTextureFile(const char* txtureFile, bool bUseGameFolder); - //! dcc filename calculation and extraction sub-routines - static bool CalculateDccFilename(const QString& assetFilename, QString& dccFilename); - //! Reformat filter string for (MFC) CFileDialog style file filtering static void FormatFilterString(QString& filter); @@ -155,9 +152,6 @@ private: // Keep this variant of this method private! pIsSelected is captured in a lambda, and so requires menu use exec() and never use show() static void PopulateQMenu(QWidget* caller, QMenu* menu, AZStd::string_view fullGamePath, bool* pIsSelected); - - static bool ExtractDccFilenameFromAssetDatabase(const QString& assetFilename, QString& dccFilename); - static bool ExtractDccFilenameUsingNamingConventions(const QString& assetFilename, QString& dccFilename); }; class CAutoRestorePrimaryCDRoot diff --git a/Code/Editor/Util/FileUtil_impl.cpp b/Code/Editor/Util/FileUtil_impl.cpp index 28090d28d5..31e3532f33 100644 --- a/Code/Editor/Util/FileUtil_impl.cpp +++ b/Code/Editor/Util/FileUtil_impl.cpp @@ -30,11 +30,6 @@ void CFileUtil_impl::EditTextureFile(const char* txtureFile, bool bUseGameFolder CFileUtil::EditTextureFile(txtureFile, bUseGameFolder); } -bool CFileUtil_impl::CalculateDccFilename(const QString& assetFilename, QString& dccFilename) -{ - return CFileUtil::CalculateDccFilename(assetFilename, dccFilename); -} - void CFileUtil_impl::FormatFilterString(QString& filter) { CFileUtil::FormatFilterString(filter); diff --git a/Code/Editor/Util/FileUtil_impl.h b/Code/Editor/Util/FileUtil_impl.h index aa8d0bf3b5..3c8e138dab 100644 --- a/Code/Editor/Util/FileUtil_impl.h +++ b/Code/Editor/Util/FileUtil_impl.h @@ -39,9 +39,6 @@ public: bool ExtractFile(QString& file, bool bMsgBoxAskForExtraction = true, const char* pDestinationFilename = nullptr) override; void EditTextureFile(const char* txtureFile, bool bUseGameFolder) override; - //! dcc filename calculation and extraction sub-routines - bool CalculateDccFilename(const QString& assetFilename, QString& dccFilename) override; - //! Reformat filter string for (MFC) CFileDialog style file filtering void FormatFilterString(QString& filter) override; diff --git a/Code/Editor/Viewport.cpp b/Code/Editor/Viewport.cpp index 437dcead3b..dcf86abb02 100644 --- a/Code/Editor/Viewport.cpp +++ b/Code/Editor/Viewport.cpp @@ -30,7 +30,6 @@ #include "Objects/ObjectManager.h" #include "Util/3DConnexionDriver.h" #include "PluginManager.h" -#include "Include/IRenderListener.h" #include "GameEngine.h" #include "Settings.h" @@ -227,61 +226,6 @@ void QtViewport::GetDimensions(int* pWidth, int* pHeight) const } } -////////////////////////////////////////////////////////////////////////// -void QtViewport::RegisterRenderListener(IRenderListener* piListener) -{ -#ifdef _DEBUG - size_t nCount(0); - size_t nTotal(0); - - nTotal = m_cRenderListeners.size(); - for (nCount = 0; nCount < nTotal; ++nCount) - { - if (m_cRenderListeners[nCount] == piListener) - { - assert(!"Registered the same RenderListener multiple times."); - break; - } - } -#endif //_DEBUG - m_cRenderListeners.push_back(piListener); -} - -////////////////////////////////////////////////////////////////////////// -bool QtViewport::UnregisterRenderListener(IRenderListener* piListener) -{ - size_t nCount(0); - size_t nTotal(0); - - nTotal = m_cRenderListeners.size(); - for (nCount = 0; nCount < nTotal; ++nCount) - { - if (m_cRenderListeners[nCount] == piListener) - { - m_cRenderListeners.erase(m_cRenderListeners.begin() + nCount); - return true; - } - } - return false; -} - -////////////////////////////////////////////////////////////////////////// -bool QtViewport::IsRenderListenerRegistered(IRenderListener* piListener) -{ - size_t nCount(0); - size_t nTotal(0); - - nTotal = m_cRenderListeners.size(); - for (nCount = 0; nCount < nTotal; ++nCount) - { - if (m_cRenderListeners[nCount] == piListener) - { - return true; - } - } - return false; -} - ////////////////////////////////////////////////////////////////////////// void QtViewport::AddPostRenderer(IPostRenderer* pPostRenderer) { @@ -1164,18 +1108,6 @@ bool QtViewport::GetAdvancedSelectModeFlag() return m_bAdvancedSelectMode; } -////////////////////////////////////////////////////////////////////////// -void QtViewport::ProcessRenderLisneters(DisplayContext& rstDisplayContext) -{ - size_t nCount(0); - size_t nTotal(0); - - nTotal = m_cRenderListeners.size(); - for (nCount = 0; nCount < nTotal; ++nCount) - { - m_cRenderListeners[nCount]->Render(rstDisplayContext); - } -} ////////////////////////////////////////////////////////////////////////// #if defined(AZ_PLATFORM_WINDOWS) // Note: Both CreateAnglesYPR and CreateOrientationYPR were copied verbatim from Cry_Camera.h which has been removed. diff --git a/Code/Editor/Viewport.h b/Code/Editor/Viewport.h index a71df6a9cd..d992eb4cb0 100644 --- a/Code/Editor/Viewport.h +++ b/Code/Editor/Viewport.h @@ -43,10 +43,8 @@ class CLayoutViewPane; class CViewManager; class CBaseObjectsCache; struct HitContext; -struct IRenderListener; class CImageEx; class QMenu; -struct IDataBaseItem; /** Type of viewport. */ @@ -105,10 +103,6 @@ public: //! Access to view manager. CViewManager* GetViewManager() const { return m_viewManager; }; - virtual void RegisterRenderListener(IRenderListener* piListener) = 0; - virtual bool UnregisterRenderListener(IRenderListener* piListener) = 0; - virtual bool IsRenderListenerRegistered(IRenderListener* piListener) = 0; - virtual void AddPostRenderer(IPostRenderer* pPostRenderer) = 0; virtual bool RemovePostRenderer(IPostRenderer* pPostRenderer) = 0; @@ -230,8 +224,6 @@ public: // Drag and drop support on viewports. // To be overrided in derived classes. ////////////////////////////////////////////////////////////////////////// - virtual bool CanDrop([[maybe_unused]] const QPoint& point, [[maybe_unused]] IDataBaseItem* pItem) { return false; }; - virtual void Drop([[maybe_unused]] const QPoint& point, [[maybe_unused]] IDataBaseItem* pItem) {}; virtual void SetGlobalDropCallback(DropCallback dropCallback, void* dropCallbackCustom) { m_dropCallback = dropCallback; @@ -480,10 +472,6 @@ public: void ResetCursor() override; void SetSupplementaryCursorStr(const QString& str) override; - void RegisterRenderListener(IRenderListener* piListener) override; - bool UnregisterRenderListener(IRenderListener* piListener) override; - bool IsRenderListenerRegistered(IRenderListener* piListener) override; - void AddPostRenderer(IPostRenderer* pPostRenderer) override; bool RemovePostRenderer(IPostRenderer* pPostRenderer) override; @@ -511,8 +499,6 @@ protected: void setRenderOverlayVisible(bool); bool isRenderOverlayVisible() const; - void ProcessRenderLisneters(DisplayContext& rstDisplayContext); - void mousePressEvent(QMouseEvent* event) override; void mouseReleaseEvent(QMouseEvent* event) override; void mouseDoubleClickEvent(QMouseEvent* event) override; @@ -600,8 +586,6 @@ protected: // Same construction matrix is shared by all viewports. Matrix34 m_constructionMatrix[LAST_COORD_SYSTEM]; - std::vector m_cRenderListeners; - typedef std::vector<_smart_ptr > PostRenderers; PostRenderers m_postRenderers; AZ_POP_DISABLE_DLL_EXPORT_MEMBER_WARNING diff --git a/Code/Editor/ViewportTitleDlg.cpp b/Code/Editor/ViewportTitleDlg.cpp index 888089fd72..90aa044d25 100644 --- a/Code/Editor/ViewportTitleDlg.cpp +++ b/Code/Editor/ViewportTitleDlg.cpp @@ -14,6 +14,7 @@ #include "ViewportTitleDlg.h" // Qt +#include #include #include @@ -43,6 +44,7 @@ #include #include #include +#include #include @@ -51,6 +53,8 @@ AZ_PUSH_DISABLE_DLL_EXPORT_MEMBER_WARNING AZ_POP_DISABLE_DLL_EXPORT_MEMBER_WARNING #endif //! defined(Q_MOC_RUN) +static constexpr int MiniumOverflowMenuWidth = 200; + // CViewportTitleDlg dialog namespace @@ -257,21 +261,56 @@ void CViewportTitleDlg::SetupHelpersButton() void CViewportTitleDlg::SetupOverflowMenu() { - // Setup the overflow menu - QMenu* overFlowMenu = new QMenu(this); + // simple override of QMenu that does not respond to keyboard events + // note: this prevents the menu from being prematurely closed + class IgnoreKeyboardMenu : public QMenu + { + public: + IgnoreKeyboardMenu(QWidget *parent = nullptr) : QMenu(parent) + { + } - m_audioMuteAction = new QAction("Mute Audio", overFlowMenu); - connect(m_audioMuteAction, &QAction::triggered, this, &CViewportTitleDlg::OnBnClickedMuteAudio); - overFlowMenu->addAction(m_audioMuteAction); + private: + void keyPressEvent(QKeyEvent* event) override + { + // regular escape key handling + if (event->key() == Qt::Key_Escape) + { + QMenu::keyPressEvent(event); + } + } + }; - overFlowMenu->addSeparator(); + // setup the overflow menu + auto* overflowMenu = new IgnoreKeyboardMenu(this); + overflowMenu->setMinimumWidth(MiniumOverflowMenuWidth); - m_enableGridSnappingAction = new QAction("Enable Grid Snapping", overFlowMenu); - connect(m_enableGridSnappingAction, &QAction::triggered, this, &CViewportTitleDlg::OnGridSnappingToggled); - m_enableGridSnappingAction->setCheckable(true); - overFlowMenu->addAction(m_enableGridSnappingAction); + m_audioMuteAction = new QAction("Mute Audio", overflowMenu); + connect(m_audioMuteAction, &QAction::triggered, this, &CViewportTitleDlg::OnBnClickedMuteAudio); + overflowMenu->addAction(m_audioMuteAction); + + overflowMenu->addSeparator(); + + m_enableGridSnappingCheckBox = new QCheckBox("Enable Grid Snapping", overflowMenu); + AzQtComponents::CheckBox::applyToggleSwitchStyle(m_enableGridSnappingCheckBox); + auto gridSnappingWidgetAction = new QWidgetAction(overflowMenu); + gridSnappingWidgetAction->setDefaultWidget(m_enableGridSnappingCheckBox); + connect(m_enableGridSnappingCheckBox, &QCheckBox::stateChanged, this, &CViewportTitleDlg::OnGridSnappingToggled); + overflowMenu->addAction(gridSnappingWidgetAction); + + m_enableGridVisualizationCheckBox = new QCheckBox("Show Grid", overflowMenu); + AzQtComponents::CheckBox::applyToggleSwitchStyle(m_enableGridVisualizationCheckBox); + auto gridVisualizationWidgetAction = new QWidgetAction(overflowMenu); + gridVisualizationWidgetAction->setDefaultWidget(m_enableGridVisualizationCheckBox); + connect( + m_enableGridVisualizationCheckBox, &QCheckBox::stateChanged, + [](const int state) + { + SandboxEditor::SetShowingGrid(state == Qt::Checked); + }); + overflowMenu->addAction(gridVisualizationWidgetAction); - m_gridSizeActionWidget = new QWidgetAction(overFlowMenu); + m_gridSizeActionWidget = new QWidgetAction(overflowMenu); m_gridSpinBox = new AzQtComponents::DoubleSpinBox(); m_gridSpinBox->setValue(SandboxEditor::GridSnappingSize()); m_gridSpinBox->setMinimum(1e-2f); @@ -281,31 +320,33 @@ void CViewportTitleDlg::SetupOverflowMenu() m_gridSpinBox, QOverload::of(&AzQtComponents::DoubleSpinBox::valueChanged), this, &CViewportTitleDlg::OnGridSpinBoxChanged); m_gridSizeActionWidget->setDefaultWidget(m_gridSpinBox); - overFlowMenu->addAction(m_gridSizeActionWidget); + overflowMenu->addAction(m_gridSizeActionWidget); - overFlowMenu->addSeparator(); + overflowMenu->addSeparator(); - m_enableAngleSnappingAction = new QAction("Enable Angle Snapping", overFlowMenu); - connect(m_enableAngleSnappingAction, &QAction::triggered, this, &CViewportTitleDlg::OnAngleSnappingToggled); - m_enableAngleSnappingAction->setCheckable(true); - overFlowMenu->addAction(m_enableAngleSnappingAction); + m_enableAngleSnappingCheckBox = new QCheckBox("Enable Angle Snapping", overflowMenu); + AzQtComponents::CheckBox::applyToggleSwitchStyle(m_enableAngleSnappingCheckBox); + auto angleSnappingWidgetAction = new QWidgetAction(overflowMenu); + angleSnappingWidgetAction->setDefaultWidget(m_enableAngleSnappingCheckBox); + connect(m_enableAngleSnappingCheckBox, &QCheckBox::stateChanged, this, &CViewportTitleDlg::OnAngleSnappingToggled); + overflowMenu->addAction(angleSnappingWidgetAction); - m_angleSizeActionWidget = new QWidgetAction(overFlowMenu); + m_angleSizeActionWidget = new QWidgetAction(overflowMenu); m_angleSpinBox = new AzQtComponents::DoubleSpinBox(); m_angleSpinBox->setValue(SandboxEditor::AngleSnappingSize()); m_angleSpinBox->setMinimum(1e-2f); - m_angleSpinBox->setToolTip(tr("Angle Snapping")); + m_angleSpinBox->setToolTip(tr("Angle size")); QObject::connect( m_angleSpinBox, QOverload::of(&AzQtComponents::DoubleSpinBox::valueChanged), this, &CViewportTitleDlg::OnAngleSpinBoxChanged); m_angleSizeActionWidget->setDefaultWidget(m_angleSpinBox); - overFlowMenu->addAction(m_angleSizeActionWidget); + overflowMenu->addAction(m_angleSizeActionWidget); - m_ui->m_overflowBtn->setMenu(overFlowMenu); + m_ui->m_overflowBtn->setMenu(overflowMenu); m_ui->m_overflowBtn->setPopupMode(QToolButton::InstantPopup); - connect(overFlowMenu, &QMenu::aboutToShow, this, &CViewportTitleDlg::UpdateOverFlowMenuState); + connect(overflowMenu, &QMenu::aboutToShow, this, &CViewportTitleDlg::UpdateOverFlowMenuState); UpdateMuteActionText(); } @@ -982,43 +1023,49 @@ void CViewportTitleDlg::CheckForCameraSpeedUpdate() } } -void CViewportTitleDlg::OnGridSnappingToggled() +void CViewportTitleDlg::OnGridSnappingToggled(const int state) { - m_gridSizeActionWidget->setEnabled(m_enableGridSnappingAction->isChecked()); + m_gridSizeActionWidget->setEnabled(state == Qt::Checked); + m_enableGridVisualizationCheckBox->setEnabled(state == Qt::Checked); MainWindow::instance()->GetActionManager()->GetAction(AzToolsFramework::SnapToGrid)->trigger(); } -void CViewportTitleDlg::OnAngleSnappingToggled() +void CViewportTitleDlg::OnAngleSnappingToggled(const int state) { - m_angleSizeActionWidget->setEnabled(m_enableAngleSnappingAction->isChecked()); + m_angleSizeActionWidget->setEnabled(state == Qt::Checked); MainWindow::instance()->GetActionManager()->GetAction(AzToolsFramework::SnapAngle)->trigger(); } -void CViewportTitleDlg::OnGridSpinBoxChanged(double value) +void CViewportTitleDlg::OnGridSpinBoxChanged(const double value) { - SandboxEditor::SetGridSnappingSize(static_cast(value)); + SandboxEditor::SetGridSnappingSize(aznumeric_cast(value)); } -void CViewportTitleDlg::OnAngleSpinBoxChanged(double value) +void CViewportTitleDlg::OnAngleSpinBoxChanged(const double value) { - SandboxEditor::SetAngleSnappingSize(static_cast(value)); + SandboxEditor::SetAngleSnappingSize(aznumeric_cast(value)); } void CViewportTitleDlg::UpdateOverFlowMenuState() { - bool gridSnappingActive = MainWindow::instance()->GetActionManager()->GetAction(AzToolsFramework::SnapToGrid)->isChecked(); + const bool gridSnappingActive = MainWindow::instance()->GetActionManager()->GetAction(AzToolsFramework::SnapToGrid)->isChecked(); { - QSignalBlocker signalBlocker(m_enableGridSnappingAction); - m_enableGridSnappingAction->setChecked(gridSnappingActive); + QSignalBlocker signalBlocker(m_enableGridSnappingCheckBox); + m_enableGridSnappingCheckBox->setChecked(gridSnappingActive); } m_gridSizeActionWidget->setEnabled(gridSnappingActive); - bool angleSnappingActive = MainWindow::instance()->GetActionManager()->GetAction(AzToolsFramework::SnapAngle)->isChecked(); + const bool angleSnappingActive = MainWindow::instance()->GetActionManager()->GetAction(AzToolsFramework::SnapAngle)->isChecked(); { - QSignalBlocker signalBlocker(m_enableAngleSnappingAction); - m_enableAngleSnappingAction->setChecked(angleSnappingActive); + QSignalBlocker signalBlocker(m_enableAngleSnappingCheckBox); + m_enableAngleSnappingCheckBox->setChecked(angleSnappingActive); } m_angleSizeActionWidget->setEnabled(angleSnappingActive); + + { + QSignalBlocker signalBlocker(m_enableGridVisualizationCheckBox); + m_enableGridVisualizationCheckBox->setChecked(SandboxEditor::ShowingGrid()); + } } namespace diff --git a/Code/Editor/ViewportTitleDlg.h b/Code/Editor/ViewportTitleDlg.h index ba3dba858a..b8da7f20ea 100644 --- a/Code/Editor/ViewportTitleDlg.h +++ b/Code/Editor/ViewportTitleDlg.h @@ -140,8 +140,8 @@ protected: void CheckForCameraSpeedUpdate(); - void OnGridSnappingToggled(); - void OnAngleSnappingToggled(); + void OnGridSnappingToggled(int state); + void OnAngleSnappingToggled(int state); void OnGridSpinBoxChanged(double value); void OnAngleSpinBoxChanged(double value); @@ -160,8 +160,9 @@ protected: QAction* m_fullInformationAction = nullptr; QAction* m_compactInformationAction = nullptr; QAction* m_audioMuteAction = nullptr; - QAction* m_enableGridSnappingAction = nullptr; - QAction* m_enableAngleSnappingAction = nullptr; + QCheckBox* m_enableGridSnappingCheckBox = nullptr; + QCheckBox* m_enableGridVisualizationCheckBox = nullptr; + QCheckBox* m_enableAngleSnappingCheckBox = nullptr; QComboBox* m_cameraSpeed = nullptr; AzQtComponents::DoubleSpinBox* m_gridSpinBox = nullptr; AzQtComponents::DoubleSpinBox* m_angleSpinBox = nullptr; @@ -175,7 +176,7 @@ protected: namespace AzToolsFramework { - //! A component to reflect scriptable commands for the Editor + //! A component to reflect scriptable commands for the Editor. class ViewportTitleDlgPythonFuncsHandler : public AZ::Component { diff --git a/Code/Editor/editor_core_files.cmake b/Code/Editor/editor_core_files.cmake index 53dd8d79a5..1f0a5a3618 100644 --- a/Code/Editor/editor_core_files.cmake +++ b/Code/Editor/editor_core_files.cmake @@ -7,17 +7,12 @@ # set(FILES - BaseLibrary.h - BaseLibraryItem.h UsedResources.h UIEnumsDatabase.h Include/EditorCoreAPI.cpp Include/IErrorReport.h - Include/IBaseLibraryManager.h Include/IFileUtil.h Include/EditorCoreAPI.h - Include/IEditorMaterial.h - Include/IEditorMaterialManager.h Include/IImageUtil.h Controls/ReflectedPropertyControl/ReflectedPropertyCtrl.qrc Controls/ReflectedPropertyControl/ReflectedPropertyCtrl.cpp @@ -35,8 +30,6 @@ set(FILES Controls/QBitmapPreviewDialogImp.h Controls/QToolTipWidget.h Controls/QToolTipWidget.cpp - BaseLibraryItem.cpp - BaseLibrary.cpp UsedResources.cpp UIEnumsDatabase.cpp LyViewPaneNames.h diff --git a/Code/Editor/editor_lib_files.cmake b/Code/Editor/editor_lib_files.cmake index fa627176d8..345a8e15e1 100644 --- a/Code/Editor/editor_lib_files.cmake +++ b/Code/Editor/editor_lib_files.cmake @@ -269,14 +269,7 @@ set(FILES LevelTreeModel.h Include/Command.h Include/HitContext.h - Include/IAnimationCompressionManager.h - Include/IAssetItem.h - Include/IAssetItemDatabase.h Include/ICommandManager.h - Include/IConsoleConnectivity.h - Include/IDataBaseItem.h - Include/IDataBaseLibrary.h - Include/IDataBaseManager.h Include/IDisplayViewport.h Include/IEditorClassFactory.h Include/IEventLoopHook.h @@ -288,17 +281,13 @@ set(FILES Include/IObjectManager.h Include/IPlugin.h Include/IPreferencesPage.h - Include/IRenderListener.h Include/ISourceControl.h - Include/ITextureDatabaseUpdater.h Include/ITransformManipulator.h Include/IViewPane.h Include/ObjectEvent.h Util/AffineParts.cpp Objects/BaseObject.cpp Objects/BaseObject.h - Animation/AnimationBipedBoneNames.cpp - Animation/AnimationBipedBoneNames.h AnimationContext.cpp AnimationContext.h AzAssetBrowser/AzAssetBrowserRequestHandler.cpp @@ -336,23 +325,12 @@ set(FILES Controls/ConsoleSCB.qrc Controls/FolderTreeCtrl.cpp Controls/FolderTreeCtrl.h - Controls/HotTrackingTreeCtrl.cpp - Controls/HotTrackingTreeCtrl.h Controls/ImageHistogramCtrl.cpp Controls/ImageHistogramCtrl.h - Controls/ImageListCtrl.cpp - Controls/ImageListCtrl.h - Controls/MultiMonHelper.cpp - Controls/MultiMonHelper.h - Controls/NumberCtrl.cpp - Controls/NumberCtrl.h - Controls/NumberCtrl.h Controls/SplineCtrl.cpp Controls/SplineCtrl.h Controls/SplineCtrlEx.cpp Controls/SplineCtrlEx.h - Controls/TextEditorCtrl.cpp - Controls/TextEditorCtrl.h Controls/TimelineCtrl.cpp Controls/TimelineCtrl.h Controls/WndGridHelper.h @@ -385,9 +363,6 @@ set(FILES ActionManager.h ShortcutDispatcher.cpp ShortcutDispatcher.h - BaseLibraryManager.cpp - BaseLibraryItem.h - BaseLibraryManager.h CheckOutDialog.cpp CheckOutDialog.h CheckOutDialog.ui @@ -470,18 +445,14 @@ set(FILES GameResourcesExporter.cpp GameExporter.h GameResourcesExporter.h - Geometry/TriMesh.cpp - Geometry/TriMesh.h AboutDialog.h AboutDialog.ui DocMultiArchive.h - EditMode/DeepSelection.h FBXExporterDialog.h FileTypeUtils.h GridUtils.h IObservable.h IPostRenderer.h - LightmapCompiler/SimpleTriangleRasterizer.h ToolBox.h TrackViewNewSequenceDialog.h UndoConfigSpec.h @@ -526,8 +497,6 @@ set(FILES PythonEditorFuncs.h QtUI/QCollapsibleGroupBox.h QtUI/QCollapsibleGroupBox.cpp - QtUI/ClickableLabel.h - QtUI/ClickableLabel.cpp QtUI/PixmapLabelPreview.h QtUI/PixmapLabelPreview.cpp QtUI/WaitCursor.h @@ -574,11 +543,9 @@ set(FILES AboutDialog.cpp ErrorReportTableModel.h ErrorReportTableModel.cpp - EditMode/DeepSelection.cpp FBXExporterDialog.cpp FBXExporterDialog.ui FileTypeUtils.cpp - LightmapCompiler/SimpleTriangleRasterizer.cpp ToolBox.cpp TrackViewNewSequenceDialog.cpp TrackViewNewSequenceDialog.ui @@ -800,9 +767,6 @@ set(FILES ViewportTitleDlg.h EditorEnvironment.cpp EditorEnvironment.h - IEditorPanelUtils.h - EditorPanelUtils.h - EditorPanelUtils.cpp ) diff --git a/Code/Editor/editor_lib_test_files.cmake b/Code/Editor/editor_lib_test_files.cmake index 17f36228db..5b66357c41 100644 --- a/Code/Editor/editor_lib_test_files.cmake +++ b/Code/Editor/editor_lib_test_files.cmake @@ -8,7 +8,6 @@ set(FILES Lib/Tests/IEditorMock.h - Lib/Tests/test_ClickableLabel.cpp Lib/Tests/test_CryEditPythonBindings.cpp Lib/Tests/test_CryEditDocPythonBindings.cpp Lib/Tests/test_EditorPythonBindings.cpp diff --git a/Code/Editor/water.png b/Code/Editor/water.png deleted file mode 100644 index 342dee81e3..0000000000 --- a/Code/Editor/water.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:4abde33fa9c29e927e403e275979536e7defbb6476eb375e85f847396645953f -size 41419 diff --git a/Code/Framework/AzCore/AzCore/Component/ComponentApplication.cpp b/Code/Framework/AzCore/AzCore/Component/ComponentApplication.cpp index 693b2f1648..72b6e807d2 100644 --- a/Code/Framework/AzCore/AzCore/Component/ComponentApplication.cpp +++ b/Code/Framework/AzCore/AzCore/Component/ComponentApplication.cpp @@ -565,10 +565,6 @@ namespace AZ m_entityActivatedEvent.DisconnectAllHandlers(); m_entityDeactivatedEvent.DisconnectAllHandlers(); -#if !defined(_RELEASE) - m_budgetTracker.Reset(); -#endif - DestroyAllocator(); } @@ -758,6 +754,12 @@ namespace AZ static_cast(m_settingsRegistry.get())->ClearNotifiers(); static_cast(m_settingsRegistry.get())->ClearMergeEvents(); +#if !defined(_RELEASE) + // the budget tracker must be cleaned up prior to module unloading to ensure + // budgets initialized cross boundary are freed properly + m_budgetTracker.Reset(); +#endif + // Uninit and unload any dynamic modules. m_moduleManager->UnloadModules(); ComponentApplicationLifecycle::SignalEvent(*m_settingsRegistry, "GemsUnloaded", R"({})"); diff --git a/Code/Framework/AzCore/AzCore/DOM/Backends/JSON/JsonSerializationUtils.cpp b/Code/Framework/AzCore/AzCore/DOM/Backends/JSON/JsonSerializationUtils.cpp index 17f9bfea54..3baf78b63d 100644 --- a/Code/Framework/AzCore/AzCore/DOM/Backends/JSON/JsonSerializationUtils.cpp +++ b/Code/Framework/AzCore/AzCore/DOM/Backends/JSON/JsonSerializationUtils.cpp @@ -361,7 +361,7 @@ namespace AZ::Dom::Json bool RapidJsonReadHandler::String(const char* str, rapidjson::SizeType length, bool copy) { - const Lifetime lifetime = copy ? m_stringLifetime : Lifetime::Temporary; + const Lifetime lifetime = !copy ? m_stringLifetime : Lifetime::Temporary; return CheckResult(m_visitor->String(AZStd::string_view(str, length), lifetime)); } @@ -373,11 +373,7 @@ namespace AZ::Dom::Json bool RapidJsonReadHandler::Key(const char* str, rapidjson::SizeType length, [[maybe_unused]] bool copy) { AZStd::string_view key = AZStd::string_view(str, length); - if (!m_visitor->SupportsRawKeys()) - { - m_visitor->Key(AZ::Name(key)); - } - const Lifetime lifetime = copy ? m_stringLifetime : Lifetime::Temporary; + const Lifetime lifetime = !copy ? m_stringLifetime : Lifetime::Temporary; return CheckResult(m_visitor->RawKey(key, lifetime)); } diff --git a/Code/Framework/AzCore/AzCore/DOM/DomUtils.cpp b/Code/Framework/AzCore/AzCore/DOM/DomUtils.cpp index 9751b9cecc..c604373296 100644 --- a/Code/Framework/AzCore/AzCore/DOM/DomUtils.cpp +++ b/Code/Framework/AzCore/AzCore/DOM/DomUtils.cpp @@ -21,4 +21,164 @@ namespace AZ::Dom::Utils { return backend.ReadFromBufferInPlace(string.data(), string.size(), visitor); } -} + + AZ::Outcome WriteToValue(const Backend::WriteCallback& writeCallback) + { + Value value; + AZStd::unique_ptr writer = value.GetWriteHandler(); + Visitor::Result result = writeCallback(*writer); + if (!result.IsSuccess()) + { + return AZ::Failure(result.GetError().FormatVisitorErrorMessage()); + } + return AZ::Success(AZStd::move(value)); + } + + bool DeepCompareIsEqual(const Value& lhs, const Value& rhs) + { + const Value::ValueType& lhsValue = lhs.GetInternalValue(); + const Value::ValueType& rhsValue = rhs.GetInternalValue(); + + if (lhs.IsString() && rhs.IsString()) + { + // If we both hold the same ref counted string we don't need to do a full comparison + if (AZStd::holds_alternative(lhsValue) && lhsValue == rhsValue) + { + return true; + } + return lhs.GetString() == rhs.GetString(); + } + + return AZStd::visit( + [&](auto&& ourValue) -> bool + { + using Alternative = AZStd::decay_t; + + if constexpr (AZStd::is_same_v) + { + if (!rhs.IsObject()) + { + return false; + } + auto&& theirValue = AZStd::get>(rhsValue); + if (ourValue == theirValue) + { + return true; + } + + const Object::ContainerType& ourValues = ourValue->GetValues(); + const Object::ContainerType& theirValues = theirValue->GetValues(); + + if (ourValues.size() != theirValues.size()) + { + return false; + } + + for (size_t i = 0; i < ourValues.size(); ++i) + { + const Object::EntryType& lhsChild = ourValues[i]; + const Object::EntryType& rhsChild = theirValues[i]; + if (lhsChild.first != rhsChild.first || !DeepCompareIsEqual(lhsChild.second, rhsChild.second)) + { + return false; + } + } + + return true; + } + else if constexpr (AZStd::is_same_v) + { + if (!rhs.IsArray()) + { + return false; + } + auto&& theirValue = AZStd::get>(rhsValue); + if (ourValue == theirValue) + { + return true; + } + + const Array::ContainerType& ourValues = ourValue->GetValues(); + const Array::ContainerType& theirValues = theirValue->GetValues(); + + if (ourValues.size() != theirValues.size()) + { + return false; + } + + for (size_t i = 0; i < ourValues.size(); ++i) + { + const Value& lhsChild = ourValues[i]; + const Value& rhsChild = theirValues[i]; + if (!DeepCompareIsEqual(lhsChild, rhsChild)) + { + return false; + } + } + + return true; + } + else if constexpr (AZStd::is_same_v) + { + if (!rhs.IsNode()) + { + return false; + } + auto&& theirValue = AZStd::get>(rhsValue); + if (ourValue == theirValue) + { + return true; + } + + const Node& ourNode = *ourValue; + const Node& theirNode = *theirValue; + + const Object::ContainerType& ourProperties = ourNode.GetProperties(); + const Object::ContainerType& theirProperties = theirNode.GetProperties(); + + if (ourProperties.size() != theirProperties.size()) + { + return false; + } + + for (size_t i = 0; i < ourProperties.size(); ++i) + { + const Object::EntryType& lhsChild = ourProperties[i]; + const Object::EntryType& rhsChild = theirProperties[i]; + if (lhsChild.first != rhsChild.first || !DeepCompareIsEqual(lhsChild.second, rhsChild.second)) + { + return false; + } + } + + const Array::ContainerType& ourChildren = ourNode.GetChildren(); + const Array::ContainerType& theirChildren = theirNode.GetChildren(); + + for (size_t i = 0; i < ourChildren.size(); ++i) + { + const Value& lhsChild = ourChildren[i]; + const Value& rhsChild = theirChildren[i]; + if (!DeepCompareIsEqual(lhsChild, rhsChild)) + { + return false; + } + } + + return true; + } + else + { + return lhs == rhs; + } + }, + lhsValue); + } + + Value DeepCopy(const Value& value, bool copyStrings) + { + Value copiedValue; + AZStd::unique_ptr writer = copiedValue.GetWriteHandler(); + value.Accept(*writer, copyStrings); + return copiedValue; + } +} // namespace AZ::Dom::Utils diff --git a/Code/Framework/AzCore/AzCore/DOM/DomUtils.h b/Code/Framework/AzCore/AzCore/DOM/DomUtils.h index 84a6eb5687..5403b93714 100644 --- a/Code/Framework/AzCore/AzCore/DOM/DomUtils.h +++ b/Code/Framework/AzCore/AzCore/DOM/DomUtils.h @@ -9,9 +9,15 @@ #pragma once #include +#include namespace AZ::Dom::Utils { Visitor::Result ReadFromString(Backend& backend, AZStd::string_view string, AZ::Dom::Lifetime lifetime, Visitor& visitor); Visitor::Result ReadFromStringInPlace(Backend& backend, AZStd::string& string, Visitor& visitor); + + AZ::Outcome WriteToValue(const Backend::WriteCallback& writeCallback); + + bool DeepCompareIsEqual(const Value& lhs, const Value& rhs); + Value DeepCopy(const Value& value, bool copyStrings = true); } // namespace AZ::Dom::Utils diff --git a/Code/Framework/AzCore/AzCore/DOM/DomValue.cpp b/Code/Framework/AzCore/AzCore/DOM/DomValue.cpp new file mode 100644 index 0000000000..6d944c9f45 --- /dev/null +++ b/Code/Framework/AzCore/AzCore/DOM/DomValue.cpp @@ -0,0 +1,1207 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include +#include + +namespace AZ::Dom +{ + namespace Internal + { + template + AZStd::shared_ptr& CheckCopyOnWrite(AZStd::shared_ptr& refCountedPointer) + { + if (refCountedPointer.use_count() == 1) + { + return refCountedPointer; + } + else + { + refCountedPointer = AZStd::allocate_shared(StdValueAllocator(), *refCountedPointer); + return refCountedPointer; + } + } + + template + constexpr size_t GetTypeIndexInternal(size_t index = 0); + + template + constexpr size_t GetTypeIndexInternal(size_t index = 0) + { + if constexpr (AZStd::is_same_v) + { + return index; + } + else + { + return GetTypeIndexInternal(index + 1); + } + } + + template + struct ExtractTypeArgs + { + }; + + template class TypeToExtract, typename... Args> + struct ExtractTypeArgs> + { + template + static constexpr size_t GetTypeIndex() + { + return GetTypeIndexInternal(); + } + }; + } // namespace Internal + + // Helper function, looks up the index of a type within Value::m_value's storage + template + constexpr size_t GetTypeIndex() + { + return Internal::ExtractTypeArgs::GetTypeIndex(); + } + + const Array::ContainerType& Array::GetValues() const + { + return m_values; + } + + const Object::ContainerType& Object::GetValues() const + { + return m_values; + } + + Node::Node(AZ::Name name) + : m_name(AZStd::move(name)) + { + } + + AZ::Name Node::GetName() const + { + return m_name; + } + + void Node::SetName(AZ::Name name) + { + m_name = AZStd::move(name); + } + + Object::ContainerType& Node::GetProperties() + { + return m_properties; + } + + const Object::ContainerType& Node::GetProperties() const + { + return m_properties; + } + + Array::ContainerType& Node::GetChildren() + { + return m_children; + } + + const Array::ContainerType& Node::GetChildren() const + { + return m_children; + } + + Value::Value(SharedStringType sharedString) + : m_value(AZStd::move(sharedString)) + { + } + + Value::Value(const Value& value) + : m_value(value.m_value) + { + } + + Value::Value(Value&& value) noexcept + { + memcpy(this, &value, sizeof(Value)); + memset(&value, 0, sizeof(Value)); + } + + Value::Value(AZStd::string_view stringView, bool copy) + { + if (copy) + { + CopyFromString(stringView); + } + else + { + SetString(stringView); + } + } + + Value::Value(AZStd::any opaqueValue) + : m_value(AZStd::allocate_shared(StdValueAllocator(), AZStd::move(opaqueValue))) + { + } + + Value Value::FromOpaqueValue(const AZStd::any& value) + { + return Value(value); + } + + Value::Value(int8_t value) + : m_value(aznumeric_cast(value)) + { + } + + Value::Value(uint8_t value) + : m_value(aznumeric_cast(value)) + { + } + + Value::Value(int16_t value) + : m_value(aznumeric_cast(value)) + { + } + + Value::Value(uint16_t value) + : m_value(aznumeric_cast(value)) + { + } + + Value::Value(int32_t value) + : m_value(aznumeric_cast(value)) + { + } + + Value::Value(uint32_t value) + : m_value(aznumeric_cast(value)) + { + } + + Value::Value(int64_t value) + : m_value(value) + { + } + + Value::Value(uint64_t value) + : m_value(value) + { + } + + Value::Value(float value) + : m_value(aznumeric_cast(value)) + { + } + + Value::Value(double value) + : m_value(value) + { + } + + Value::Value(bool value) + : m_value(value) + { + } + + Value::Value(Type type) + { + switch (type) + { + case Type::Null: + // Null is the default initialized value + break; + case Type::Bool: + m_value = false; + break; + case Type::Object: + SetObject(); + break; + case Type::Array: + SetArray(); + break; + case Type::String: + SetString(""); + break; + case Type::Int64: + m_value = int64_t{}; + break; + case Type::Uint64: + m_value = uint64_t{}; + break; + case Type::Double: + m_value = double{}; + break; + case Type::Node: + SetNode(""); + break; + case Type::Opaque: + AZ_Assert(false, "AZ::Dom::Value may not be constructed with an empty opaque type"); + break; + } + } + + Value& Value::operator=(const Value& other) + { + m_value = other.m_value; + return *this; + } + + Value& Value::operator=(Value&& other) noexcept + { + SetNull(); + memcpy(this, &other, sizeof(Value)); + memset(&other, 0, sizeof(Value)); + return *this; + } + + bool Value::operator==(const Value& rhs) const + { + if (IsString() && rhs.IsString()) + { + return GetString() == rhs.GetString(); + } + else + { + return m_value == rhs.m_value; + } + } + + bool Value::operator!=(const Value& rhs) const + { + return !operator==(rhs); + } + + void Value::Swap(Value& other) noexcept + { + AZStd::aligned_storage_for_t temp; + memcpy(&temp, this, sizeof(Value)); + memcpy(this, &other, sizeof(Value)); + memcpy(&other, &temp, sizeof(Value)); + } + + Type Dom::Value::GetType() const + { + return AZStd::visit( + [](auto&& value) -> Type + { + using CurrentType = AZStd::decay_t; + if constexpr (AZStd::is_same_v) + { + return Type::Null; + } + else if constexpr (AZStd::is_same_v) + { + return Type::Int64; + } + else if constexpr (AZStd::is_same_v) + { + return Type::Uint64; + } + else if constexpr (AZStd::is_same_v) + { + return Type::Double; + } + else if constexpr (AZStd::is_same_v) + { + return Type::Bool; + } + else if constexpr (AZStd::is_same_v) + { + return Type::String; + } + else if constexpr (AZStd::is_same_v) + { + return Type::String; + } + else if constexpr (AZStd::is_same_v) + { + return Type::String; + } + else if constexpr (AZStd::is_same_v) + { + return Type::Object; + } + else if constexpr (AZStd::is_same_v) + { + return Type::Array; + } + else if constexpr (AZStd::is_same_v) + { + return Type::Node; + } + else if constexpr (AZStd::is_same_v) + { + return Type::Opaque; + } + else + { + AZ_Assert(false, "AZ::Dom::Value::GetType: m_value has an unexpected type"); + } + }, + m_value); + } + + bool Value::IsNull() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsFalse() const + { + const bool* value = AZStd::get_if(&m_value); + return value != nullptr ? !(*value) : false; + } + + bool Value::IsTrue() const + { + const bool* value = AZStd::get_if(&m_value); + return value != nullptr ? *value : false; + } + + bool Value::IsBool() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsNode() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsObject() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsArray() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsOpaqueValue() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsNumber() const + { + return AZStd::visit( + [](auto&& value) -> bool + { + using CurrentType = AZStd::decay_t; + if constexpr (AZStd::is_same_v) + { + return true; + } + else if constexpr (AZStd::is_same_v) + { + return true; + } + else if constexpr (AZStd::is_same_v) + { + return true; + } + else + { + return false; + } + }, + m_value); + } + + bool Value::IsInt() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsUint() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsDouble() const + { + return AZStd::holds_alternative(m_value); + } + + bool Value::IsString() const + { + return AZStd::visit( + [](auto&& value) -> bool + { + using CurrentType = AZStd::decay_t; + if constexpr (AZStd::is_same_v) + { + return true; + } + else if constexpr (AZStd::is_same_v) + { + return true; + } + else if constexpr (AZStd::is_same_v) + { + return true; + } + else + { + return false; + } + }, + m_value); + } + + Value& Value::SetObject() + { + m_value = AZStd::allocate_shared(StdValueAllocator()); + return *this; + } + + const Node& Value::GetNodeInternal() const + { + AZ_Assert(GetType() == Type::Node, "AZ::Dom::Value: attempted to retrieve a node from a non-node value"); + return *AZStd::get(m_value); + } + + Node& Value::GetNodeInternal() + { + AZ_Assert(GetType() == Type::Node, "AZ::Dom::Value: attempted to retrieve a node from a non-node value"); + return *Internal::CheckCopyOnWrite(AZStd::get(m_value)); + } + + const Object::ContainerType& Value::GetObjectInternal() const + { + const Type type = GetType(); + AZ_Assert( + type == Type::Object || type == Type::Node, + "AZ::Dom::Value: attempted to retrieve an object from a value that isn't an object or a node"); + if (type == Type::Object) + { + return AZStd::get(m_value)->m_values; + } + else + { + return AZStd::get(m_value)->GetProperties(); + } + } + + Object::ContainerType& Value::GetObjectInternal() + { + const Type type = GetType(); + AZ_Assert( + type == Type::Object || type == Type::Node, + "AZ::Dom::Value: attempted to retrieve an object from a value that isn't an object or a node"); + if (type == Type::Object) + { + return Internal::CheckCopyOnWrite(AZStd::get(m_value))->m_values; + } + else + { + return Internal::CheckCopyOnWrite(AZStd::get(m_value))->GetProperties(); + } + } + + const Array::ContainerType& Value::GetArrayInternal() const + { + const Type type = GetType(); + AZ_Assert( + type == Type::Array || type == Type::Node, + "AZ::Dom::Value: attempted to retrieve an array from a value that isn't an array or a node"); + if (type == Type::Array) + { + return AZStd::get(m_value)->m_values; + } + else + { + return AZStd::get(m_value)->GetChildren(); + } + } + + Array::ContainerType& Value::GetArrayInternal() + { + const Type type = GetType(); + AZ_Assert( + type == Type::Array || type == Type::Node, + "AZ::Dom::Value: attempted to retrieve an array from a value that isn't an array or node"); + if (type == Type::Array) + { + return Internal::CheckCopyOnWrite(AZStd::get(m_value))->m_values; + } + else + { + return Internal::CheckCopyOnWrite(AZStd::get(m_value))->GetChildren(); + } + } + + size_t Value::MemberCount() const + { + return GetObjectInternal().size(); + } + + size_t Value::MemberCapacity() const + { + return GetObjectInternal().size(); + } + + bool Value::ObjectEmpty() const + { + return GetObjectInternal().empty(); + } + + Value& Value::operator[](KeyType name) + { + Object::ContainerType& object = GetObjectInternal(); + auto existingEntry = AZStd::find_if( + object.begin(), object.end(), + [&name](const Object::EntryType& entry) + { + return entry.first == name; + }); + if (existingEntry != object.end()) + { + return existingEntry->second; + } + else + { + object.emplace_back(name, Value()); + return object[object.size() - 1].second; + } + } + + const Value& Value::operator[](KeyType name) const + { + return FindMember(name)->second; + } + + Value& Value::operator[](AZStd::string_view name) + { + return operator[](AZ::Name(name)); + } + + const Value& Value::operator[](AZStd::string_view name) const + { + return operator[](AZ::Name(name)); + } + + Object::ConstIterator Value::MemberBegin() const + { + return GetObjectInternal().begin(); + } + + Object::ConstIterator Value::MemberEnd() const + { + return GetObjectInternal().end(); + } + + Object::Iterator Value::MemberBegin() + { + return GetObjectInternal().begin(); + } + + Object::Iterator Value::MemberEnd() + { + return GetObjectInternal().end(); + } + + Object::ConstIterator Value::FindMember(KeyType name) const + { + const Object::ContainerType& object = GetObjectInternal(); + return AZStd::find_if( + object.begin(), object.end(), + [&name](const Object::EntryType& entry) + { + return entry.first == name; + }); + } + + Object::ConstIterator Value::FindMember(AZStd::string_view name) const + { + return FindMember(AZ::Name(name)); + } + + Object::Iterator Value::FindMutableMember(KeyType name) + { + Object::ContainerType& object = GetObjectInternal(); + return AZStd::find_if( + object.begin(), object.end(), + [&name](const Object::EntryType& entry) + { + return entry.first == name; + }); + } + + Object::Iterator Value::FindMutableMember(AZStd::string_view name) + { + return FindMutableMember(AZ::Name(name)); + } + + Value& Value::MemberReserve(size_t newCapacity) + { + GetObjectInternal().reserve(newCapacity); + return *this; + } + + bool Value::HasMember(KeyType name) const + { + return FindMember(name) != GetObjectInternal().end(); + } + + bool Value::HasMember(AZStd::string_view name) const + { + return HasMember(AZ::Name(name)); + } + + Value& Value::AddMember(KeyType name, const Value& value) + { + Object::ContainerType& object = GetObjectInternal(); + // Reserve in ReserveIncremenet chunks instead of the default vector doubling strategy + // Profiling has found that this is an aggregate performance gain for typical workflows + object.reserve(AZ_SIZE_ALIGN_UP(object.size() + 1, Object::ReserveIncrement)); + if (auto memberIt = FindMutableMember(name); memberIt != object.end()) + { + memberIt->second = value; + } + else + { + object.emplace_back(AZStd::move(name), value); + } + return *this; + } + + Value& Value::AddMember(AZStd::string_view name, const Value& value) + { + return AddMember(AZ::Name(name), value); + } + + Value& Value::AddMember(AZ::Name name, Value&& value) + { + Object::ContainerType& object = GetObjectInternal(); + if (auto memberIt = FindMutableMember(name); memberIt != object.end()) + { + memberIt->second = value; + } + else + { + object.emplace_back(AZStd::move(name), value); + } + return *this; + } + + Value& Value::AddMember(AZStd::string_view name, Value&& value) + { + return AddMember(AZ::Name(name), value); + } + + void Value::RemoveAllMembers() + { + GetObjectInternal().clear(); + } + + void Value::RemoveMember(KeyType name) + { + Object::ContainerType& object = GetObjectInternal(); + object.erase(AZStd::remove_if( + object.begin(), object.end(), + [&name](const Object::EntryType& entry) + { + return entry.first == name; + })); + } + + void Value::RemoveMember(AZStd::string_view name) + { + RemoveMember(AZ::Name(name)); + } + + Object::Iterator Value::RemoveMember(Object::Iterator pos) + { + Object::ContainerType& object = GetObjectInternal(); + if (!object.empty()) + { + *pos = AZStd::move(object.back()); + object.pop_back(); + } + return object.end(); + } + + Object::Iterator Value::EraseMember(Object::ConstIterator pos) + { + return GetObjectInternal().erase(pos); + } + + Object::Iterator Value::EraseMember(Object::ConstIterator first, Object::ConstIterator last) + { + return GetObjectInternal().erase(first, last); + } + + Object::Iterator Value::EraseMember(KeyType name) + { + return GetObjectInternal().erase(FindMember(name)); + } + + Object::Iterator Value::EraseMember(AZStd::string_view name) + { + return EraseMember(AZ::Name(name)); + } + + Object::ContainerType& Value::GetMutableObject() + { + return GetObjectInternal(); + } + + const Object::ContainerType& Value::GetObject() const + { + return GetObjectInternal(); + } + + Value& Value::SetArray() + { + m_value = AZStd::allocate_shared(StdValueAllocator()); + return *this; + } + + size_t Value::ArraySize() const + { + return GetArrayInternal().size(); + } + + size_t Value::ArrayCapacity() const + { + return GetArrayInternal().capacity(); + } + + bool Value::IsArrayEmpty() const + { + return GetArrayInternal().empty(); + } + + void Value::ClearArray() + { + GetArrayInternal().clear(); + } + + Value& Value::operator[](size_t index) + { + return GetArrayInternal()[index]; + } + + const Value& Value::operator[](size_t index) const + { + return GetArrayInternal()[index]; + } + + Value& Value::MutableArrayAt(size_t index) + { + return operator[](index); + } + + const Value& Value::ArrayAt(size_t index) const + { + return operator[](index); + } + + Array::ConstIterator Value::ArrayBegin() const + { + return GetArrayInternal().begin(); + } + + Array::ConstIterator Value::ArrayEnd() const + { + return GetArrayInternal().end(); + } + + Array::Iterator Value::ArrayBegin() + { + return GetArrayInternal().begin(); + } + + Array::Iterator Value::ArrayEnd() + { + return GetArrayInternal().end(); + } + + Value& Value::ArrayReserve(size_t newCapacity) + { + GetArrayInternal().reserve(newCapacity); + return *this; + } + + Value& Value::ArrayPushBack(Value value) + { + Array::ContainerType& array = GetArrayInternal(); + // Reserve in ReserveIncremenet chunks instead of the default vector doubling strategy + // Profiling has found that this is an aggregate performance gain for typical workflows + array.reserve(AZ_SIZE_ALIGN_UP(array.size() + 1, Array::ReserveIncrement)); + array.push_back(AZStd::move(value)); + return *this; + } + + Value& Value::ArrayPopBack() + { + GetArrayInternal().pop_back(); + return *this; + } + + Array::Iterator Value::ArrayErase(Array::ConstIterator pos) + { + return GetArrayInternal().erase(pos); + } + + Array::Iterator Value::ArrayErase(Array::ConstIterator first, Array::ConstIterator last) + { + return GetArrayInternal().erase(first, last); + } + + Array::ContainerType& Value::GetMutableArray() + { + return GetArrayInternal(); + } + + const Array::ContainerType& Value::GetArray() const + { + return GetArrayInternal(); + } + + void Value::SetNode(AZ::Name name) + { + m_value = AZStd::allocate_shared(StdValueAllocator(), AZStd::move(name)); + } + + void Value::SetNode(AZStd::string_view name) + { + SetNode(AZ::Name(name)); + } + + AZ::Name Value::GetNodeName() const + { + return GetNodeInternal().GetName(); + } + + void Value::SetNodeName(AZ::Name name) + { + GetNodeInternal().SetName(AZStd::move(name)); + } + + void Value::SetNodeName(AZStd::string_view name) + { + SetNodeName(AZ::Name(name)); + } + + void Value::SetNodeValue(Value value) + { + AZ_Assert(GetType() == Type::Node, "AZ::Dom::Value: Attempted to set value for non-node type"); + Array::ContainerType& nodeChildren = GetArrayInternal(); + + // Set the first non-node child, if one is found + for (Value& entry : nodeChildren) + { + if (entry.GetType() != Type::Node) + { + entry = AZStd::move(value); + return; + } + } + + // Otherwise, append the value entry + nodeChildren.push_back(AZStd::move(value)); + } + + Value Value::GetNodeValue() const + { + AZ_Assert(GetType() == Type::Node, "AZ::Dom::Value: Attempted to get value for non-node type"); + const Array::ContainerType& nodeChildren = GetArrayInternal(); + + // Get the first non-node child, if one is found + for (const Value& entry : nodeChildren) + { + if (entry.GetType() != Type::Node) + { + return entry; + } + } + + return Value(); + } + + Node& Value::GetMutableNode() + { + return GetNodeInternal(); + } + + const Node& Value::GetNode() const + { + return GetNodeInternal(); + } + + int64_t Value::GetInt64() const + { + switch (m_value.index()) + { + case GetTypeIndex(): + return AZStd::get(m_value); + case GetTypeIndex(): + return aznumeric_cast(AZStd::get(m_value)); + case GetTypeIndex(): + return aznumeric_cast(AZStd::get(m_value)); + } + AZ_Assert(false, "AZ::Dom::Value: Called GetInt on a non-numeric type"); + return {}; + } + + void Value::SetInt64(int64_t value) + { + m_value = value; + } + + uint64_t Value::GetUint64() const + { + switch (m_value.index()) + { + case GetTypeIndex(): + return aznumeric_cast(AZStd::get(m_value)); + case GetTypeIndex(): + return AZStd::get(m_value); + case GetTypeIndex(): + return aznumeric_cast(AZStd::get(m_value)); + } + AZ_Assert(false, "AZ::Dom::Value: Called GetInt on a non-numeric type"); + return {}; + } + + void Value::SetUint64(uint64_t value) + { + m_value = value; + } + + bool Value::GetBool() const + { + if (IsBool()) + { + return AZStd::get(m_value); + } + AZ_Assert(false, "AZ::Dom::Value: Called GetBool on a non-bool type"); + return {}; + } + + void Value::SetBool(bool value) + { + m_value = value; + } + + double Value::GetDouble() const + { + switch (m_value.index()) + { + case GetTypeIndex(): + return aznumeric_cast(AZStd::get(m_value)); + case GetTypeIndex(): + return aznumeric_cast(AZStd::get(m_value)); + case GetTypeIndex(): + return AZStd::get(m_value); + } + AZ_Assert(false, "AZ::Dom::Value: Called GetInt on a non-numeric type"); + return {}; + } + + void Value::SetDouble(double value) + { + m_value = value; + } + + void Value::SetString(SharedStringType sharedString) + { + m_value = sharedString; + } + + AZStd::string_view Value::GetString() const + { + switch (m_value.index()) + { + case GetTypeIndex(): + return AZStd::get(m_value); + case GetTypeIndex(): + { + auto& buffer = *AZStd::get(m_value); + return { buffer.data(), buffer.size() }; + } + case GetTypeIndex(): + { + const ShortStringType& shortString = AZStd::get(m_value); + return { shortString.data(), shortString.size() }; + } + } + AZ_Assert(false, "AZ::Dom::Value: Called GetString on a non-string type"); + return {}; + } + + size_t Value::GetStringLength() const + { + return GetString().size(); + } + + void Value::SetString(AZStd::string_view value) + { + m_value = value; + } + + void Value::CopyFromString(AZStd::string_view value) + { + if (value.size() <= ShortStringSize) + { + ShortStringType buffer; + buffer.resize_no_construct(value.size()); + memcpy(buffer.data(), value.data(), value.size()); + m_value = buffer; + } + else + { + SharedStringType sharedString = AZStd::allocate_shared(StdValueAllocator(), value.begin(), value.end()); + m_value = AZStd::move(sharedString); + } + } + + const AZStd::any& Value::GetOpaqueValue() const + { + return *AZStd::get(m_value); + } + + void Value::SetOpaqueValue(AZStd::any value) + { + m_value = AZStd::allocate_shared(StdValueAllocator(), AZStd::move(value)); + } + + void Value::SetNull() + { + m_value = AZStd::monostate(); + } + + Visitor::Result Value::Accept(Visitor& visitor, bool copyStrings) const + { + Visitor::Result result = AZ::Success(); + + AZStd::visit( + [&](auto&& arg) + { + using Alternative = AZStd::decay_t; + + if constexpr (AZStd::is_same_v) + { + result = visitor.Null(); + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.Int64(arg); + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.Uint64(arg); + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.Double(arg); + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.Bool(arg); + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.String(arg, copyStrings ? Lifetime::Temporary : Lifetime::Persistent); + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.RefCountedString(arg, copyStrings ? Lifetime::Temporary : Lifetime::Persistent); + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.StartObject(); + if (result.IsSuccess()) + { + const Object::ContainerType& object = GetObjectInternal(); + for (const Object::EntryType& entry : object) + { + result = visitor.Key(entry.first); + if (!result.IsSuccess()) + { + return; + } + result = entry.second.Accept(visitor, copyStrings); + if (!result.IsSuccess()) + { + return; + } + } + result = visitor.EndObject(object.size()); + } + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.StartArray(); + if (result.IsSuccess()) + { + const Array::ContainerType& arrayContainer = GetArrayInternal(); + for (const Value& entry : arrayContainer) + { + result = entry.Accept(visitor, copyStrings); + if (!result.IsSuccess()) + { + return; + } + } + result = visitor.EndArray(arrayContainer.size()); + } + } + else if constexpr (AZStd::is_same_v) + { + const Node& node = *AZStd::get(m_value); + result = visitor.StartNode(node.GetName()); + if (result.IsSuccess()) + { + const Object::ContainerType& object = GetObjectInternal(); + for (const Object::EntryType& entry : object) + { + result = visitor.Key(entry.first); + if (!result.IsSuccess()) + { + return; + } + result = entry.second.Accept(visitor, copyStrings); + if (!result.IsSuccess()) + { + return; + } + } + + const Array::ContainerType& arrayContainer = GetArrayInternal(); + for (const Value& entry : arrayContainer) + { + result = entry.Accept(visitor, copyStrings); + if (!result.IsSuccess()) + { + return; + } + } + + result = visitor.EndNode(object.size(), arrayContainer.size()); + } + } + else if constexpr (AZStd::is_same_v) + { + result = visitor.OpaqueValue(*arg); + } + }, + m_value); + return result; + } + + AZStd::unique_ptr Value::GetWriteHandler() + { + return AZStd::make_unique(*this); + } + + const Value::ValueType& Value::GetInternalValue() const + { + return m_value; + } +} // namespace AZ::Dom diff --git a/Code/Framework/AzCore/AzCore/DOM/DomValue.h b/Code/Framework/AzCore/AzCore/DOM/DomValue.h new file mode 100644 index 0000000000..ecf8326525 --- /dev/null +++ b/Code/Framework/AzCore/AzCore/DOM/DomValue.h @@ -0,0 +1,402 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +namespace AZ::Dom +{ + using KeyType = AZ::Name; + + //! The type of underlying value stored in a value. \see Value + enum class Type + { + Null, + Bool, + Object, + Array, + String, + Int64, + Uint64, + Double, + Node, + Opaque, + }; + + //! The allocator used by Value. + //! Value heap allocates shared_ptrs for its container storage (Array / Object / Node) alongside + class ValueAllocator final : public SimpleSchemaAllocator + { + public: + AZ_TYPE_INFO(ValueAllocator, "{5BC8B389-72C7-459E-B502-12E74D61869F}"); + + using Base = SimpleSchemaAllocator; + + ValueAllocator() + : Base("DomValueAllocator", "Allocator for AZ::Dom::Value") + { + DisableOverriding(); + } + }; + + using StdValueAllocator = AZStdAlloc; + + class Value; + + //! Internal storage for a Value array: an ordered list of Values. + class Array + { + public: + using ContainerType = AZStd::vector; + using Iterator = ContainerType::iterator; + using ConstIterator = ContainerType::const_iterator; + static constexpr const size_t ReserveIncrement = 4; + static_assert((ReserveIncrement & (ReserveIncrement - 1)) == 0, "ReserveIncremenet must be a power of 2"); + + const ContainerType& GetValues() const; + + private: + ContainerType m_values; + + friend class Value; + }; + + using ArrayPtr = AZStd::shared_ptr; + using ConstArrayPtr = AZStd::shared_ptr; + + //! Internal storage for a Value object: an ordered list of Name / Value pairs. + class Object + { + public: + using EntryType = AZStd::pair; + using ContainerType = AZStd::vector; + using Iterator = ContainerType::iterator; + using ConstIterator = ContainerType::const_iterator; + static constexpr const size_t ReserveIncrement = 8; + static_assert((ReserveIncrement & (ReserveIncrement - 1)) == 0, "ReserveIncremenet must be a power of 2"); + + const ContainerType& GetValues() const; + + private: + ContainerType m_values; + + friend class Value; + }; + + using ObjectPtr = AZStd::shared_ptr; + using ConstObjectPtr = AZStd::shared_ptr; + + //! Storage for a Value node: a named Value with both properties and children. + //! Properties are stored as an ordered list of Name / Value pairs. + //! Children are stored as an oredered list of Values. + class Node + { + public: + Node() = default; + Node(const Node&) = default; + Node(Node&&) = default; + explicit Node(AZ::Name name); + + Node& operator=(const Node&) = default; + Node& operator=(Node&&) = default; + + AZ::Name GetName() const; + void SetName(AZ::Name name); + + Object::ContainerType& GetProperties(); + const Object::ContainerType& GetProperties() const; + + Array::ContainerType& GetChildren(); + const Array::ContainerType& GetChildren() const; + + private: + AZ::Name m_name; + Object::ContainerType m_properties; + Array::ContainerType m_children; + + friend class Value; + }; + + using NodePtr = AZStd::shared_ptr; + using ConstNodePtr = AZStd::shared_ptr; + + //! Value is a typed union of Dom types that can represent the types provdied by AZ::Dom::Visitor. + //! Value can be one of the following types: + //! - Null: a type with no value, this is the default type for Value + //! - Bool: a true or false boolean value + //! - Object: a container with an ordered list of Name/Value pairs, analagous to a JSON object + //! - Array: a container with an ordered list of Values, analagous to a JSON array + //! - String: a UTF-8 string + //! - Int64: a signed, 64-bit integer + //! - Uint64: an unsigned, 64-bit integer + //! - Double: a double precision floating point value + //! - Node: a container with a Name, an ordered list of Name/Values pairs (attributes), and an ordered list of Values (children), + //! analagous to an XML node + //! - Opaque: an arbitrary value stored in an AZStd::any. This is a non-serializable representation of an entry used only for in-memory + //! options. This is intended to be used as an intermediate value over the course of DOM transformation and as a proxy to pass through + //! types of which the DOM has no knowledge to other systems. + //! \note Value is a copy-on-write data structure and may be cheaply returned by value. Heap allocated data larger than the size of the + //! value itself (objects, arrays, and nodes) are copied by new Values only when their contents change, so care should be taken in + //! performance critical code to avoid mutation operations such as operator[] to avoid copies. It is recommended that an immutable Value + //! be explicitly be stored as a `const Value` to avoid accidental detach and copy operations. + class Value final + { + public: + // Determine the short string buffer size based on the size of our largest internal type (string_view) + // minus the size of the short string size field. + static constexpr const size_t ShortStringSize = sizeof(AZStd::string_view) - 2; + using ShortStringType = AZStd::fixed_string; + using SharedStringContainer = AZStd::vector; + using SharedStringType = AZStd::shared_ptr; + using OpaqueStorageType = AZStd::shared_ptr; + + //! The internal storage type for Value. + //! These types do not correspond one-to-one with the Value's external Type as there may be multiple storage classes + //! for the same type in some instances, such as string storage. + using ValueType = AZStd::variant< + // Null + AZStd::monostate, + // Int64 + int64_t, + // Uint64 + uint64_t, + // Double + double, + // Bool + bool, + // String + AZStd::string_view, + SharedStringType, + ShortStringType, + // Object + ObjectPtr, + // Array + ArrayPtr, + // Node + NodePtr, + // Opaque + OpaqueStorageType>; + + // Constructors... + Value() = default; + Value(const Value&); + Value(Value&&) noexcept; + Value(AZStd::string_view stringView, bool copy); + explicit Value(const ValueType&); + explicit Value(ValueType&&); + explicit Value(SharedStringType sharedString); + + explicit Value(int8_t value); + explicit Value(uint8_t value); + explicit Value(int16_t value); + explicit Value(uint16_t value); + explicit Value(int32_t value); + explicit Value(uint32_t value); + explicit Value(int64_t value); + explicit Value(uint64_t value); + explicit Value(float value); + explicit Value(double value); + explicit Value(bool value); + + explicit Value(Type type); + + // Disable accidental calls to Value(bool) with pointer types + template + explicit Value(T*) = delete; + + static Value FromOpaqueValue(const AZStd::any& value); + + // Equality / comparison / swap... + Value& operator=(const Value&); + Value& operator=(Value&&) noexcept; + + //! Assignment operator to allow forwarding types constructible via Value(T) to be assigned + template + auto operator=(T&& arg) + -> AZStd::enable_if_t, Value> && AZStd::is_constructible_v, Value&> + { + return operator=(Value(AZStd::forward(arg))); + } + + bool operator==(const Value& rhs) const; + bool operator!=(const Value& rhs) const; + + void Swap(Value& other) noexcept; + + // Type info... + Type GetType() const; + bool IsNull() const; + bool IsFalse() const; + bool IsTrue() const; + bool IsBool() const; + bool IsNode() const; + bool IsObject() const; + bool IsArray() const; + bool IsOpaqueValue() const; + bool IsNumber() const; + bool IsInt() const; + bool IsUint() const; + bool IsDouble() const; + bool IsString() const; + + // Object API (also used by Node)... + Value& SetObject(); + size_t MemberCount() const; + size_t MemberCapacity() const; + bool ObjectEmpty() const; + + Value& operator[](KeyType name); + const Value& operator[](KeyType name) const; + Value& operator[](AZStd::string_view name); + const Value& operator[](AZStd::string_view name) const; + + Object::ConstIterator MemberBegin() const; + Object::ConstIterator MemberEnd() const; + Object::Iterator MemberBegin(); + Object::Iterator MemberEnd(); + + Object::Iterator FindMutableMember(KeyType name); + Object::Iterator FindMutableMember(AZStd::string_view name); + Object::ConstIterator FindMember(KeyType name) const; + Object::ConstIterator FindMember(AZStd::string_view name) const; + + Value& MemberReserve(size_t newCapacity); + bool HasMember(KeyType name) const; + bool HasMember(AZStd::string_view name) const; + + Value& AddMember(KeyType name, const Value& value); + Value& AddMember(AZStd::string_view name, const Value& value); + Value& AddMember(KeyType name, Value&& value); + Value& AddMember(AZStd::string_view name, Value&& value); + + void RemoveAllMembers(); + void RemoveMember(KeyType name); + void RemoveMember(AZStd::string_view name); + Object::Iterator RemoveMember(Object::Iterator pos); + Object::Iterator EraseMember(Object::ConstIterator pos); + Object::Iterator EraseMember(Object::ConstIterator first, Object::ConstIterator last); + Object::Iterator EraseMember(KeyType name); + Object::Iterator EraseMember(AZStd::string_view name); + + Object::ContainerType& GetMutableObject(); + const Object::ContainerType& GetObject() const; + + // Array API (also used by Node)... + Value& SetArray(); + + size_t ArraySize() const; + size_t ArrayCapacity() const; + bool IsArrayEmpty() const; + void ClearArray(); + + Value& operator[](size_t index); + const Value& operator[](size_t index) const; + + Value& MutableArrayAt(size_t index); + const Value& ArrayAt(size_t index) const; + + Array::ConstIterator ArrayBegin() const; + Array::ConstIterator ArrayEnd() const; + Array::Iterator ArrayBegin(); + Array::Iterator ArrayEnd(); + + Value& ArrayReserve(size_t newCapacity); + Value& ArrayPushBack(Value value); + Value& ArrayPopBack(); + + Array::Iterator ArrayErase(Array::ConstIterator pos); + Array::Iterator ArrayErase(Array::ConstIterator first, Array::ConstIterator last); + + Array::ContainerType& GetMutableArray(); + const Array::ContainerType& GetArray() const; + + // Node API (supports both object + array API, plus a dedicated NodeName)... + void SetNode(AZ::Name name); + void SetNode(AZStd::string_view name); + + AZ::Name GetNodeName() const; + void SetNodeName(AZ::Name name); + void SetNodeName(AZStd::string_view name); + //! Convenience method, sets the first non-node element of a Node. + void SetNodeValue(Value value); + //! Convenience method, gets the first non-node element of a Node. + Value GetNodeValue() const; + + Node& GetMutableNode(); + const Node& GetNode() const; + + // int API... + int64_t GetInt64() const; + void SetInt64(int64_t); + + // uint API... + uint64_t GetUint64() const; + void SetUint64(uint64_t); + + // bool API... + bool GetBool() const; + void SetBool(bool); + + // double API... + double GetDouble() const; + void SetDouble(double); + + // String API... + AZStd::string_view GetString() const; + size_t GetStringLength() const; + void SetString(AZStd::string_view); + void SetString(SharedStringType sharedString); + void CopyFromString(AZStd::string_view); + + // Opaque type API... + const AZStd::any& GetOpaqueValue() const; + //! This sets this Value to represent a value of an type that the DOM has + //! no formal knowledge of. Where possible, it should be preferred to + //! serialize an opaque type into a DOM value instead, as serializers + //! and other systems will have no means of dealing with fully arbitrary + //! values. + void SetOpaqueValue(AZStd::any); + + // Null API... + void SetNull(); + + // Visitor API... + Visitor::Result Accept(Visitor& visitor, bool copyStrings) const; + AZStd::unique_ptr GetWriteHandler(); + + //! Gets the internal value of this Value. Note that this value's types may not correspond one-to-one with the Type enumeration, + //! as internally the same type might have different storage mechanisms. Where possible, prefer using the typed API. + const ValueType& GetInternalValue() const; + + private: + const Node& GetNodeInternal() const; + Node& GetNodeInternal(); + const Object::ContainerType& GetObjectInternal() const; + Object::ContainerType& GetObjectInternal(); + const Array::ContainerType& GetArrayInternal() const; + Array::ContainerType& GetArrayInternal(); + + explicit Value(AZStd::any opaqueValue); + + static_assert( + sizeof(ValueType) == sizeof(ShortStringType) + sizeof(size_t), "ValueType should have no members larger than ShortStringType"); + + ValueType m_value; + }; +} // namespace AZ::Dom diff --git a/Code/Framework/AzCore/AzCore/DOM/DomValueWriter.cpp b/Code/Framework/AzCore/AzCore/DOM/DomValueWriter.cpp new file mode 100644 index 0000000000..433e650d04 --- /dev/null +++ b/Code/Framework/AzCore/AzCore/DOM/DomValueWriter.cpp @@ -0,0 +1,262 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include + +namespace AZ::Dom +{ + ValueWriter::ValueWriter(Value& outputValue) + : m_result(outputValue) + { + } + + VisitorFlags ValueWriter::GetVisitorFlags() const + { + return VisitorFlags::SupportsRawKeys | VisitorFlags::SupportsArrays | VisitorFlags::SupportsObjects | VisitorFlags::SupportsNodes; + } + + ValueWriter::ValueInfo::ValueInfo(Value& container) + : m_container(container) + { + } + + Visitor::Result ValueWriter::Null() + { + CurrentValue().SetNull(); + return FinishWrite(); + } + + Visitor::Result ValueWriter::Bool(bool value) + { + CurrentValue().SetBool(value); + return FinishWrite(); + } + + Visitor::Result ValueWriter::Int64(AZ::s64 value) + { + CurrentValue().SetInt64(value); + return FinishWrite(); + } + + Visitor::Result ValueWriter::Uint64(AZ::u64 value) + { + CurrentValue().SetUint64(value); + return FinishWrite(); + } + + Visitor::Result ValueWriter::Double(double value) + { + CurrentValue().SetDouble(value); + return FinishWrite(); + } + + Visitor::Result ValueWriter::String(AZStd::string_view value, Lifetime lifetime) + { + if (lifetime == Lifetime::Persistent) + { + CurrentValue().SetString(value); + } + else + { + CurrentValue().CopyFromString(value); + } + return FinishWrite(); + } + + Visitor::Result ValueWriter::RefCountedString(AZStd::shared_ptr> value, [[maybe_unused]] Lifetime lifetime) + { + CurrentValue().SetString(AZStd::move(value)); + return FinishWrite(); + } + + Visitor::Result ValueWriter::StartObject() + { + CurrentValue().SetObject(); + + m_entryStack.emplace(CurrentValue()); + return VisitorSuccess(); + } + + template + void MoveVectorMemory(AZStd::vector& dest, AZStd::vector& source) + { + dest.resize_no_construct(source.size()); + const size_t size = sizeof(T) * source.size(); + memcpy(dest.data(), source.data(), size); + memset(source.data(), 0, size); + source.resize(0); + } + + Visitor::Result ValueWriter::EndContainer(Type containerType, AZ::u64 attributeCount, AZ::u64 elementCount) + { + const char* endMethodName; + switch (containerType) + { + case Type::Object: + endMethodName = "EndObject"; + break; + case Type::Array: + endMethodName = "EndArray"; + break; + case Type::Node: + endMethodName = "EndNode"; + break; + default: + AZ_Assert(false, "Invalid container type specified"); + return VisitorFailure(VisitorErrorCode::InternalError, "AZ::Dom::ValueWriter: EndContainer called with invalid container type"); + } + + if (m_entryStack.empty()) + { + return VisitorFailure( + VisitorErrorCode::InternalError, + AZStd::string::format("AZ::Dom::ValueWriter: %s called without a matching call", endMethodName)); + } + + const ValueInfo& topEntry = m_entryStack.top(); + Value& container = topEntry.m_container; + ValueBuffer& buffer = GetValueBuffer(); + + if (container.GetType() != containerType) + { + return VisitorFailure( + VisitorErrorCode::InternalError, + AZStd::string::format("AZ::Dom::ValueWriter: %s called from within a different container type", endMethodName)); + } + + if (aznumeric_cast(buffer.m_attributes.size()) != attributeCount) + { + return VisitorFailure( + VisitorErrorCode::InternalError, + AZStd::string::format( + "AZ::Dom::ValueWriter: %s expected %llu attributes but received %zu attributes instead", endMethodName, attributeCount, + buffer.m_attributes.size())); + } + + if (aznumeric_cast(buffer.m_elements.size()) != elementCount) + { + return VisitorFailure( + VisitorErrorCode::InternalError, + AZStd::string::format( + "AZ::Dom::ValueWriter: %s expected %llu elements but received %zu elements instead", endMethodName, elementCount, + buffer.m_elements.size())); + } + + if (buffer.m_attributes.size() > 0) + { + MoveVectorMemory(container.GetMutableObject(), buffer.m_attributes); + } + + if(buffer.m_elements.size() > 0) + { + MoveVectorMemory(container.GetMutableArray(), buffer.m_elements); + } + + m_entryStack.pop(); + return FinishWrite(); + } + + ValueWriter::ValueBuffer& ValueWriter::GetValueBuffer() + { + if (m_entryStack.size() <= m_valueBuffers.size()) + { + return m_valueBuffers[m_entryStack.size() - 1]; + } + + m_valueBuffers.resize(m_entryStack.size()); + return m_valueBuffers[m_entryStack.size() - 1]; + } + + Visitor::Result ValueWriter::EndObject(AZ::u64 attributeCount) + { + return EndContainer(Type::Object, attributeCount, 0); + } + + Visitor::Result ValueWriter::Key(AZ::Name key) + { + AZ_Assert(!m_entryStack.empty(), "Attempmted to push a key with no object"); + AZ_Assert(!m_entryStack.top().m_container.IsArray(), "Attempted to push a key to an array"); + m_entryStack.top().m_key = AZStd::move(key); + return VisitorSuccess(); + } + + Visitor::Result ValueWriter::RawKey(AZStd::string_view key, [[maybe_unused]] Lifetime lifetime) + { + return Key(AZ::Name(key)); + } + + Visitor::Result ValueWriter::StartArray() + { + CurrentValue().SetArray(); + + m_entryStack.emplace(CurrentValue()); + return VisitorSuccess(); + } + + Visitor::Result ValueWriter::EndArray(AZ::u64 elementCount) + { + return EndContainer(Type::Array, 0, elementCount); + } + + Visitor::Result ValueWriter::StartNode(AZ::Name name) + { + CurrentValue().SetNode(name); + + m_entryStack.emplace(CurrentValue()); + return VisitorSuccess(); + } + + Visitor::Result ValueWriter::RawStartNode(AZStd::string_view name, [[maybe_unused]] Lifetime lifetime) + { + return StartNode(AZ::Name(name)); + } + + Visitor::Result ValueWriter::EndNode(AZ::u64 attributeCount, AZ::u64 elementCount) + { + return EndContainer(Type::Node, attributeCount, elementCount); + } + + Visitor::Result ValueWriter::OpaqueValue(OpaqueType& value) + { + CurrentValue().SetOpaqueValue(value); + return FinishWrite(); + } + + Visitor::Result ValueWriter::FinishWrite() + { + if (m_entryStack.empty()) + { + return VisitorSuccess(); + } + + Value value; + m_entryStack.top().m_value.Swap(value); + ValueInfo& newEntry = m_entryStack.top(); + + if (!newEntry.m_key.IsEmpty()) + { + GetValueBuffer().m_attributes.emplace_back(AZStd::move(newEntry.m_key), AZStd::move(value)); + newEntry.m_key = AZ::Name(); + } + else + { + GetValueBuffer().m_elements.emplace_back(AZStd::move(value)); + } + + return VisitorSuccess(); + } + + Value& ValueWriter::CurrentValue() + { + if (m_entryStack.empty()) + { + return m_result; + } + return m_entryStack.top().m_value; + } +} // namespace AZ::Dom diff --git a/Code/Framework/AzCore/AzCore/DOM/DomValueWriter.h b/Code/Framework/AzCore/AzCore/DOM/DomValueWriter.h new file mode 100644 index 0000000000..4fdea293eb --- /dev/null +++ b/Code/Framework/AzCore/AzCore/DOM/DomValueWriter.h @@ -0,0 +1,72 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include + +namespace AZ::Dom +{ + //! Visitor that writes to a Value. + //! Supports all Visitor operations. + class ValueWriter : public Visitor + { + public: + ValueWriter(Value& outputValue); + + VisitorFlags GetVisitorFlags() const override; + Result Null() override; + Result Bool(bool value) override; + Result Int64(AZ::s64 value) override; + Result Uint64(AZ::u64 value) override; + Result Double(double value) override; + + Result String(AZStd::string_view value, Lifetime lifetime) override; + Result RefCountedString(AZStd::shared_ptr> value, Lifetime lifetime) override; + Result StartObject() override; + Result EndObject(AZ::u64 attributeCount) override; + Result Key(AZ::Name key) override; + Result RawKey(AZStd::string_view key, Lifetime lifetime) override; + Result StartArray() override; + Result EndArray(AZ::u64 elementCount) override; + Result StartNode(AZ::Name name) override; + Result RawStartNode(AZStd::string_view name, Lifetime lifetime) override; + Result EndNode(AZ::u64 attributeCount, AZ::u64 elementCount) override; + Result OpaqueValue(OpaqueType& value) override; + + private: + Result FinishWrite(); + Value& CurrentValue(); + Visitor::Result EndContainer(Type containerType, AZ::u64 attributeCount, AZ::u64 elementCount); + + struct ValueInfo + { + ValueInfo(Value& container); + + KeyType m_key; + Value m_value; + Value& m_container; + }; + + struct ValueBuffer + { + Array::ContainerType m_elements; + Object::ContainerType m_attributes; + }; + + ValueBuffer& GetValueBuffer(); + + Value& m_result; + // Stores info about the current value being processed + AZStd::stack>> m_entryStack; + // Provides temporary storage for elements and attributes to prevent extra heap allocations + // These buffers persist to be reused even as the entry stack changes + AZStd::vector> m_valueBuffers; + }; +} // namespace AZ::Dom diff --git a/Code/Framework/AzCore/AzCore/DOM/DomVisitor.cpp b/Code/Framework/AzCore/AzCore/DOM/DomVisitor.cpp index ad314da385..0da4bcd5d3 100644 --- a/Code/Framework/AzCore/AzCore/DOM/DomVisitor.cpp +++ b/Code/Framework/AzCore/AzCore/DOM/DomVisitor.cpp @@ -105,7 +105,12 @@ namespace AZ::Dom return VisitorSuccess(); } - Visitor::Result Visitor::OpaqueValue([[maybe_unused]] const OpaqueType& value, [[maybe_unused]] Lifetime lifetime) + Visitor::Result Visitor::RefCountedString(AZStd::shared_ptr> value, Lifetime lifetime) + { + return String({ value->data(), value->size() }, lifetime); + } + + Visitor::Result Visitor::OpaqueValue([[maybe_unused]] OpaqueType& value) { if (!SupportsOpaqueValues()) { diff --git a/Code/Framework/AzCore/AzCore/DOM/DomVisitor.h b/Code/Framework/AzCore/AzCore/DOM/DomVisitor.h index bbe78131c3..f9930f93c6 100644 --- a/Code/Framework/AzCore/AzCore/DOM/DomVisitor.h +++ b/Code/Framework/AzCore/AzCore/DOM/DomVisitor.h @@ -11,6 +11,8 @@ #include #include #include +#include +#include #include namespace AZ::Dom @@ -167,15 +169,20 @@ namespace AZ::Dom virtual Result Uint64(AZ::u64 value); //! Operates on a double precision, 64 bit floating point value. virtual Result Double(double value); - //! Operates on a string value. As strings are a reference type. - //! Storage semantics are provided to indicate where the value may be stored persistently or requires a copy. + //! Operates on a string value. As strings are a reference type, + //! storage semantics are provided to indicate where the value may be stored persistently or requires a copy. + //! \param lifetime Specifies the lifetime of this string - if the string has a temporary lifetime, it cannot + //! safely be stored as a reference. virtual Result String(AZStd::string_view value, Lifetime lifetime); + //! Operates on a ref-counted string value. S + //! \param lifetime Specifies the lifetime of this string. If the string has a temporary lifetime, it may not + //! be safely stored as a reference, but may still be safely stored as a ref-counted shared_ptr. + virtual Result RefCountedString(AZStd::shared_ptr> value, Lifetime lifetime); //! Operates on an opaque value. As opaque values are a reference type, storage semantics are provided to //! indicate where the value may be stored persistently or requires a copy. //! The base implementation of OpaqueValue rejects the operation, as opaque values are meant for special //! cases with specific implementations, not generic usage. - //! Storage semantics are provided to indicate where the value may be stored persistently or requires a copy. - virtual Result OpaqueValue(const OpaqueType& value, Lifetime lifetime); + virtual Result OpaqueValue(OpaqueType& value); //! Operates on a raw value encoded as a UTF-8 string that hasn't had its type deduced. //! Visitors that support raw values (\see VisitorFlags::SupportsRawValues) may parse the raw value and //! forward it to the corresponding value call or calls of their choice. diff --git a/Code/Framework/AzCore/AzCore/Debug/Budget.h b/Code/Framework/AzCore/AzCore/Debug/Budget.h index 4646ef8b2c..c909302886 100644 --- a/Code/Framework/AzCore/AzCore/Debug/Budget.h +++ b/Code/Framework/AzCore/AzCore/Debug/Budget.h @@ -62,12 +62,16 @@ namespace AZ::Debug // // Anywhere the budget is used, the budget must be declared (either in a header or in the source file itself) // AZ_DECLARE_BUDGET(AzCore); -#define AZ_DEFINE_BUDGET(name) \ - ::AZ::Debug::Budget* AZ_BUDGET_GETTER(name)() \ - { \ - constexpr static uint32_t crc = AZ_CRC_CE(#name); \ - static ::AZ::Debug::Budget* budget = ::AZ::Debug::BudgetTracker::GetBudgetFromEnvironment(#name, crc); \ - return budget; \ +#define AZ_DEFINE_BUDGET(name) \ + ::AZ::Debug::Budget* AZ_BUDGET_GETTER(name)() \ + { \ + static ::AZ::Debug::Budget* budget = nullptr; \ + if (budget == nullptr) \ + { \ + constexpr static uint32_t crc = AZ_CRC_CE(#name); \ + ::AZ::Debug::BudgetTracker::GetBudgetFromEnvironment(budget, #name, crc); \ + } \ + return budget; \ } #endif diff --git a/Code/Framework/AzCore/AzCore/Debug/BudgetTracker.cpp b/Code/Framework/AzCore/AzCore/Debug/BudgetTracker.cpp index 2dac9a566e..faadbfc31a 100644 --- a/Code/Framework/AzCore/AzCore/Debug/BudgetTracker.cpp +++ b/Code/Framework/AzCore/AzCore/Debug/BudgetTracker.cpp @@ -13,23 +13,24 @@ #include #include #include +#include #include namespace AZ::Debug { struct BudgetTracker::BudgetTrackerImpl { - AZStd::unordered_map m_budgets; + AZStd::unordered_map m_budgets; + AZStd::unordered_set m_externalBudgetRefs; }; - Budget* BudgetTracker::GetBudgetFromEnvironment(const char* budgetName, uint32_t crc) + void BudgetTracker::GetBudgetFromEnvironment(Budget*& extBudgetRef, const char* budgetName, uint32_t crc) { BudgetTracker* tracker = Interface::Get(); if (tracker) { - return &tracker->GetBudget(budgetName, crc); + tracker->GetBudget(extBudgetRef, budgetName, crc); } - return nullptr; } BudgetTracker::~BudgetTracker() @@ -54,17 +55,24 @@ namespace AZ::Debug if (m_impl) { Interface::Unregister(this); + + for (auto budgetRef : m_impl->m_externalBudgetRefs) + { + *budgetRef = nullptr; + } + delete m_impl; m_impl = nullptr; } } - Budget& BudgetTracker::GetBudget(const char* budgetName, uint32_t crc) + void BudgetTracker::GetBudget(Budget*& extBudgetRef, const char* budgetName, uint32_t crc) { AZStd::scoped_lock lock{ m_mutex }; - auto it = m_impl->m_budgets.try_emplace(budgetName, budgetName, crc).first; + m_impl->m_externalBudgetRefs.insert(&extBudgetRef); - return it->second; + auto iter = m_impl->m_budgets.try_emplace(budgetName, budgetName, crc).first; + extBudgetRef = &iter->second; } } // namespace AZ::Debug diff --git a/Code/Framework/AzCore/AzCore/Debug/BudgetTracker.h b/Code/Framework/AzCore/AzCore/Debug/BudgetTracker.h index 34d8510349..69e8185746 100644 --- a/Code/Framework/AzCore/AzCore/Debug/BudgetTracker.h +++ b/Code/Framework/AzCore/AzCore/Debug/BudgetTracker.h @@ -20,7 +20,7 @@ namespace AZ::Debug { public: AZ_TYPE_INFO(BudgetTracker, "{E14A746D-BFFE-4C02-90FB-4699B79864A5}"); - static Budget* GetBudgetFromEnvironment(const char* budgetName, uint32_t crc); + static void GetBudgetFromEnvironment(Budget*& extBudgetRef, const char* budgetName, uint32_t crc); ~BudgetTracker(); @@ -28,7 +28,7 @@ namespace AZ::Debug bool Init(); void Reset(); - Budget& GetBudget(const char* budgetName, uint32_t crc); + void GetBudget(Budget*& extBudgetRef, const char* budgetName, uint32_t crc); private: struct BudgetTrackerImpl; diff --git a/Code/Framework/AzCore/AzCore/IO/Path/Path.h b/Code/Framework/AzCore/AzCore/IO/Path/Path.h index 094dee16f2..7f89809294 100644 --- a/Code/Framework/AzCore/AzCore/IO/Path/Path.h +++ b/Code/Framework/AzCore/AzCore/IO/Path/Path.h @@ -484,6 +484,7 @@ namespace AZ::IO // as_posix //! Replicates the behavior of the Python pathlib as_posix method //! by replacing the Windows Path Separator with the Posix Path Seperator + constexpr string_type AsPosix() const; AZStd::string StringAsPosix() const; constexpr AZStd::fixed_string FixedMaxPathStringAsPosix() const noexcept; diff --git a/Code/Framework/AzCore/AzCore/IO/Path/Path.inl b/Code/Framework/AzCore/AzCore/IO/Path/Path.inl index 5ac15fc728..0dc1799528 100644 --- a/Code/Framework/AzCore/AzCore/IO/Path/Path.inl +++ b/Code/Framework/AzCore/AzCore/IO/Path/Path.inl @@ -1043,6 +1043,13 @@ namespace AZ::IO // as_posix // Returns a copy of the path with the path separators converted to PosixPathSeparator template + constexpr auto BasicPath::AsPosix() const -> string_type + { + string_type resultPath(m_path.begin(), m_path.end()); + AZStd::replace(resultPath.begin(), resultPath.end(), WindowsPathSeparator, PosixPathSeparator); + return resultPath; + } + template AZStd::string BasicPath::StringAsPosix() const { AZStd::string resultPath(m_path.begin(), m_path.end()); diff --git a/Code/Framework/AzCore/AzCore/IO/Path/PathReflect.cpp b/Code/Framework/AzCore/AzCore/IO/Path/PathReflect.cpp index 55a991f19f..1d0cdba66c 100644 --- a/Code/Framework/AzCore/AzCore/IO/Path/PathReflect.cpp +++ b/Code/Framework/AzCore/AzCore/IO/Path/PathReflect.cpp @@ -7,6 +7,8 @@ */ #include +#include +#include #include #include @@ -35,10 +37,8 @@ namespace AZ::IO size_t Save(const void* classPtr, IO::GenericStream& stream, bool) override { /// Save paths out using the PosixPathSeparator - PathType path(reinterpret_cast(classPtr)->Native(), AZ::IO::PosixPathSeparator); - path.MakePreferred(); - - return static_cast(stream.Write(path.Native().size(), path.c_str())); + auto posixPathString{ reinterpret_cast(classPtr)->AsPosix() }; + return static_cast(stream.Write(posixPathString.size(), posixPathString.c_str())); } bool Load(void* classPtr, IO::GenericStream& stream, unsigned int, bool) override @@ -73,5 +73,11 @@ namespace AZ::IO AZ::SerializeContext::IDataSerializer::CreateDefaultDeleteDeleter() }) ; } + else if (auto jsonContext = azrtti_cast(context)) + { + jsonContext->Serializer() + ->HandlesType() + ->HandlesType(); + } } } diff --git a/Code/Framework/AzCore/AzCore/Interface/Interface.h b/Code/Framework/AzCore/AzCore/Interface/Interface.h index 8664e2905f..8f72cfa109 100644 --- a/Code/Framework/AzCore/AzCore/Interface/Interface.h +++ b/Code/Framework/AzCore/AzCore/Interface/Interface.h @@ -109,6 +109,7 @@ namespace AZ */ static EnvironmentVariable s_instance; static AZStd::shared_mutex s_mutex; + static bool s_instanceAssigned; }; template @@ -117,6 +118,9 @@ namespace AZ template AZStd::shared_mutex Interface::s_mutex; + template + bool Interface::s_instanceAssigned; + template void Interface::Register(T* type) { @@ -135,18 +139,19 @@ namespace AZ AZStd::unique_lock lock(s_mutex); s_instance = Environment::CreateVariable(GetVariableName()); s_instance.Get() = type; + s_instanceAssigned = true; } template void Interface::Unregister(T* type) { - if (!s_instance || !s_instance.Get()) + if (!s_instanceAssigned) { AZ_Assert(false, "Interface '%s' not registered on this module!", AzTypeInfo::Name()); return; } - if (s_instance.Get() != type) + if (s_instance && s_instance.Get() != type) { AZ_Assert(false, "Interface '%s' is not the same instance that was registered! [Expected '%p', Found '%p']", AzTypeInfo::Name(), type, s_instance.Get()); return; @@ -156,6 +161,7 @@ namespace AZ AZStd::unique_lock lock(s_mutex); *s_instance = nullptr; s_instance.Reset(); + s_instanceAssigned = false; } template @@ -165,9 +171,9 @@ namespace AZ // This is the fast path which won't block. { AZStd::shared_lock lock(s_mutex); - if (s_instance) + if (s_instanceAssigned) { - return s_instance.Get(); + return s_instance ? s_instance.Get() : nullptr; } } @@ -175,6 +181,7 @@ namespace AZ // take the full lock and request it. AZStd::unique_lock lock(s_mutex); s_instance = Environment::FindVariable(GetVariableName()); + s_instanceAssigned = true; return s_instance ? s_instance.Get() : nullptr; } diff --git a/Code/Framework/AzCore/AzCore/Math/IntersectSegment.cpp b/Code/Framework/AzCore/AzCore/Math/IntersectSegment.cpp index 5d13acc34c..4f143cde53 100644 --- a/Code/Framework/AzCore/AzCore/Math/IntersectSegment.cpp +++ b/Code/Framework/AzCore/AzCore/Math/IntersectSegment.cpp @@ -8,1558 +8,1608 @@ #include -using namespace AZ; -using namespace Intersect; - -//========================================================================= -// IntersectSegmentTriangleCCW -// [10/21/2009] -//========================================================================= -bool Intersect::IntersectSegmentTriangleCCW( - const Vector3& p, const Vector3& q, const Vector3& a, const Vector3& b, const Vector3& c, - /*float &u, float &v, float &w,*/ Vector3& normal, float& t) +namespace AZ { - float v, w; // comment this and enable input params if we need the barycentric coordinates + //========================================================================= + // IntersectSegmentTriangleCCW + // [10/21/2009] + //========================================================================= + bool Intersect::IntersectSegmentTriangleCCW( + const Vector3& p, + const Vector3& q, + const Vector3& a, + const Vector3& b, + const Vector3& c, + /*float &u, float &v, float &w,*/ Vector3& normal, + float& t) + { + float v, w; // comment this and enable input params if we need the barycentric coordinates + + Vector3 ab = b - a; + Vector3 ac = c - a; + Vector3 qp = p - q; + + // Compute triangle normal. Can be pre-calculated/cached if + // intersecting multiple segments against the same triangle + normal = ab.Cross(ac); // Right hand CCW + + // Compute denominator d. If d <= 0, segment is parallel to or points + // away from triangle, so exit early + float d = qp.Dot(normal); + if (d <= 0.0f) + { + return false; + } - Vector3 ab = b - a; - Vector3 ac = c - a; - Vector3 qp = p - q; + // Compute intersection t value of pq with plane of triangle. A ray + // intersects iff 0 <= t. Segment intersects iff 0 <= t <= 1. Delay + // dividing by d until intersection has been found to pierce triangle + Vector3 ap = p - a; + t = ap.Dot(normal); - // Compute triangle normal. Can be pre-calculated/cached if - // intersecting multiple segments against the same triangle - normal = ab.Cross(ac); // Right hand CCW + // range segment check t[0,1] (it this case [0,d]) + if (t < 0.0f || t > d) + { + return false; + } - // Compute denominator d. If d <= 0, segment is parallel to or points - // away from triangle, so exit early - float d = qp.Dot(normal); - if (d <= 0.0f) - { - return false; - } + // Compute barycentric coordinate components and test if within bounds + Vector3 e = qp.Cross(ap); + v = ac.Dot(e); + if (v < 0.0f || v > d) + { + return false; + } + w = -ab.Dot(e); + if (w < 0.0f || v + w > d) + { + return false; + } - // Compute intersection t value of pq with plane of triangle. A ray - // intersects iff 0 <= t. Segment intersects iff 0 <= t <= 1. Delay - // dividing by d until intersection has been found to pierce triangle - Vector3 ap = p - a; - t = ap.Dot(normal); + // Segment/ray intersects triangle. Perform delayed division and + // compute the last barycentric coordinate component + float ood = 1.0f / d; + t *= ood; + /*v *= ood; + w *= ood; + u = 1.0f - v - w;*/ - // range segment check t[0,1] (it this case [0,d]) - if (t < 0.0f || t > d) - { - return false; - } + normal.Normalize(); - // Compute barycentric coordinate components and test if within bounds - Vector3 e = qp.Cross(ap); - v = ac.Dot(e); - if (v < 0.0f || v > d) - { - return false; + return true; } - w = -ab.Dot(e); - if (w < 0.0f || v + w > d) + + //========================================================================= + // IntersectSegmentTriangle + // [10/21/2009] + //========================================================================= + bool Intersect::IntersectSegmentTriangle( + const Vector3& p, + const Vector3& q, + const Vector3& a, + const Vector3& b, + const Vector3& c, + /*float &u, float &v, float &w,*/ Vector3& normal, + float& t) { - return false; - } + float v, w; // comment this and enable input params if we need the barycentric coordinates - // Segment/ray intersects triangle. Perform delayed division and - // compute the last barycentric coordinate component - float ood = 1.0f / d; - t *= ood; - /*v *= ood; - w *= ood; - u = 1.0f - v - w;*/ + Vector3 ab = b - a; + Vector3 ac = c - a; + Vector3 qp = p - q; + Vector3 ap = p - a; - normal.Normalize(); + // Compute triangle normal. Can be pre-calculated or cached if + // intersecting multiple segments against the same triangle + normal = ab.Cross(ac); // Right hand CCW - return true; -} + // Compute denominator d. If d <= 0, segment is parallel to or points + // away from triangle, so exit early + float d = qp.Dot(normal); + Vector3 e; + if (d > Constants::FloatEpsilon) + { + // the normal is on the right side + e = qp.Cross(ap); + } + else + { + normal = -normal; -//========================================================================= -// IntersectSegmentTriangle -// [10/21/2009] -//========================================================================= -bool -Intersect::IntersectSegmentTriangle( - const Vector3& p, const Vector3& q, const Vector3& a, const Vector3& b, const Vector3& c, - /*float &u, float &v, float &w,*/ Vector3& normal, float& t) -{ - float v, w; // comment this and enable input params if we need the barycentric coordinates - - Vector3 ab = b - a; - Vector3 ac = c - a; - Vector3 qp = p - q; - Vector3 ap = p - a; - - // Compute triangle normal. Can be pre-calculated or cached if - // intersecting multiple segments against the same triangle - normal = ab.Cross(ac); // Right hand CCW - - // Compute denominator d. If d <= 0, segment is parallel to or points - // away from triangle, so exit early - float d = qp.Dot(normal); - Vector3 e; - if (d > Constants::FloatEpsilon) - { - // the normal is on the right side - e = qp.Cross(ap); - } - else - { - normal = -normal; + // so either have a parallel ray or our normal is flipped + if (d >= -Constants::FloatEpsilon) + { + return false; // parallel + } + d = -d; + e = ap.Cross(qp); + } + + // Compute intersection t value of pq with plane of triangle. A ray + // intersects iff 0 <= t. Segment intersects iff 0 <= t <= 1. Delay + // dividing by d until intersection has been found to pierce triangle + t = ap.Dot(normal); - // so either have a parallel ray or our normal is flipped - if (d >= -Constants::FloatEpsilon) + // range segment check t[0,1] (it this case [0,d]) + if (t < 0.0f || t > d) { - return false; // parallel + return false; } - d = -d; - e = ap.Cross(qp); - } - // Compute intersection t value of pq with plane of triangle. A ray - // intersects iff 0 <= t. Segment intersects iff 0 <= t <= 1. Delay - // dividing by d until intersection has been found to pierce triangle - t = ap.Dot(normal); + // Compute barycentric coordinate components and test if within bounds + v = ac.Dot(e); + if (v < 0.0f || v > d) + { + return false; + } + w = -ab.Dot(e); + if (w < 0.0f || v + w > d) + { + return false; + } - // range segment check t[0,1] (it this case [0,d]) - if (t < 0.0f || t > d) - { - return false; - } + // Segment/ray intersects the triangle. Perform delayed division and + // compute the last barycentric coordinate component + float ood = 1.0f / d; + t *= ood; + // v *= ood; + // w *= ood; + // u = 1.0f - v - w; - // Compute barycentric coordinate components and test if within bounds - v = ac.Dot(e); - if (v < 0.0f || v > d) - { - return false; + normal.Normalize(); + + return true; } - w = -ab.Dot(e); - if (w < 0.0f || v + w > d) + + //========================================================================= + // TestSegmentAABBOrigin + // [10/21/2009] + //========================================================================= + bool Intersect::TestSegmentAABBOrigin(const Vector3& midPoint, const Vector3& halfVector, const Vector3& aabbExtends) { - return false; - } + const Vector3 EPSILON(0.001f); // \todo this is slow load move to a const + Vector3 absHalfVector = halfVector.GetAbs(); + Vector3 absMidpoint = midPoint.GetAbs(); + Vector3 absHalfMidpoint = absHalfVector + aabbExtends; - // Segment/ray intersects the triangle. Perform delayed division and - // compute the last barycentric coordinate component - float ood = 1.0f / d; - t *= ood; - //v *= ood; - //w *= ood; - //u = 1.0f - v - w; + // Try world coordinate axes as separating axes + if (!absMidpoint.IsLessEqualThan(absHalfMidpoint)) + { + return false; + } - normal.Normalize(); + // Add in an epsilon term to counteract arithmetic errors when segment is + // (near) parallel to a coordinate axis (see text for detail) + absHalfVector += EPSILON; - return true; -} + // Try cross products of segment direction vector with coordinate axes + Vector3 absMDCross = midPoint.Cross(halfVector).GetAbs(); + // Vector3 eaDCross = absHalfVector.Cross(aabbExtends); + float ex = aabbExtends.GetX(); + float ey = aabbExtends.GetY(); + float ez = aabbExtends.GetZ(); + float adx = absHalfVector.GetX(); + float ady = absHalfVector.GetY(); + float adz = absHalfVector.GetZ(); -//========================================================================= -// TestSegmentAABBOrigin -// [10/21/2009] -//========================================================================= -bool -AZ::Intersect::TestSegmentAABBOrigin(const Vector3& midPoint, const Vector3& halfVector, const Vector3& aabbExtends) -{ - const Vector3 EPSILON(0.001f); // \todo this is slow load move to a const - Vector3 absHalfVector = halfVector.GetAbs(); - Vector3 absMidpoint = midPoint.GetAbs(); - Vector3 absHalfMidpoint = absHalfVector + aabbExtends; + Vector3 ead(ey * adz + ez * ady, ex * adz + ez * adx, ex * ady + ey * adx); + if (!absMDCross.IsLessEqualThan(ead)) + { + return false; + } - // Try world coordinate axes as separating axes - if (!absMidpoint.IsLessEqualThan(absHalfMidpoint)) - { - return false; + // No separating axis found; segment must be overlapping AABB + return true; } - // Add in an epsilon term to counteract arithmetic errors when segment is - // (near) parallel to a coordinate axis (see text for detail) - absHalfVector += EPSILON; - - // Try cross products of segment direction vector with coordinate axes - Vector3 absMDCross = midPoint.Cross(halfVector).GetAbs(); - //Vector3 eaDCross = absHalfVector.Cross(aabbExtends); - float ex = aabbExtends.GetX(); - float ey = aabbExtends.GetY(); - float ez = aabbExtends.GetZ(); - float adx = absHalfVector.GetX(); - float ady = absHalfVector.GetY(); - float adz = absHalfVector.GetZ(); - - Vector3 ead(ey * adz + ez * ady, ex * adz + ez * adx, ex * ady + ey * adx); - if (!absMDCross.IsLessEqualThan(ead)) + //========================================================================= + // IntersectRayAABB + // [10/21/2009] + //========================================================================= + Intersect::RayAABBIsectTypes Intersect::IntersectRayAABB( + const Vector3& rayStart, + const Vector3& dir, + const Vector3& dirRCP, + const Aabb& aabb, + float& tStart, + float& tEnd, + Vector3& startNormal /*, Vector3& inter*/) { - return false; - } - - // No separating axis found; segment must be overlapping AABB - return true; -} - + // we don't need to test with all 6 normals (just 3) -//========================================================================= -// IntersectRayAABB -// [10/21/2009] -//========================================================================= -RayAABBIsectTypes -AZ::Intersect::IntersectRayAABB( - const Vector3& rayStart, const Vector3& dir, const Vector3& dirRCP, const Aabb& aabb, - float& tStart, float& tEnd, Vector3& startNormal /*, Vector3& inter*/) -{ - // we don't need to test with all 6 normals (just 3) - - const float eps = 0.0001f; // \todo move to constant - float tmin = 0.0f; // set to -RR_FLT_MAX to get first hit on line - float tmax = std::numeric_limits::max(); // set to max distance ray can travel (for segment) + const float eps = 0.0001f; // \todo move to constant + float tmin = 0.0f; // set to -RR_FLT_MAX to get first hit on line + float tmax = std::numeric_limits::max(); // set to max distance ray can travel (for segment) - const Vector3& aabbMin = aabb.GetMin(); - const Vector3& aabbMax = aabb.GetMax(); + const Vector3& aabbMin = aabb.GetMin(); + const Vector3& aabbMax = aabb.GetMax(); - // we unroll manually because there is no way to get in efficient way vectors for - // each axis while getting it as a index - Vector3 time1 = (aabbMin - rayStart) * dirRCP; - Vector3 time2 = (aabbMax - rayStart) * dirRCP; + // we unroll manually because there is no way to get in efficient way vectors for + // each axis while getting it as a index + Vector3 time1 = (aabbMin - rayStart) * dirRCP; + Vector3 time2 = (aabbMax - rayStart) * dirRCP; - // X - if (std::fabs(dir.GetX()) < eps) - { - // Ray is parallel to slab. No hit if origin not within slab - if (rayStart.GetX() < aabbMin.GetX() || rayStart.GetX() > aabbMax.GetX()) + // X + if (std::fabs(dir.GetX()) < eps) { - return ISECT_RAY_AABB_NONE; + // Ray is parallel to slab. No hit if origin not within slab + if (rayStart.GetX() < aabbMin.GetX() || rayStart.GetX() > aabbMax.GetX()) + { + return ISECT_RAY_AABB_NONE; + } } - } - else - { - // Compute intersection t value of ray with near and far plane of slab - float t1 = time1.GetX(); - float t2 = time2.GetX(); - float nSign = -1.0f; - - // Make t1 be intersection with near plane, t2 with far plane - if (t1 > t2) + else { - AZStd::swap(t1, t2); - nSign = 1.0f; - } + // Compute intersection t value of ray with near and far plane of slab + float t1 = time1.GetX(); + float t2 = time2.GetX(); + float nSign = -1.0f; - // Compute the intersection of slab intersections intervals - if (tmin < t1) - { - tmin = t1; + // Make t1 be intersection with near plane, t2 with far plane + if (t1 > t2) + { + AZStd::swap(t1, t2); + nSign = 1.0f; + } - startNormal.Set(nSign, 0.0f, 0.0f); - } + // Compute the intersection of slab intersections intervals + if (tmin < t1) + { + tmin = t1; - tmax = AZ::GetMin(tmax, t2); + startNormal.Set(nSign, 0.0f, 0.0f); + } - // Exit with no collision as soon as slab intersection becomes empty - if (tmin > tmax) - { - return ISECT_RAY_AABB_NONE; - } - } + tmax = AZ::GetMin(tmax, t2); - // Y - if (std::fabs(dir.GetY()) < eps) - { - // Ray is parallel to slab. No hit if origin not within slab - if (rayStart.GetY() < aabbMin.GetY() || rayStart.GetY() > aabbMax.GetY()) - { - return ISECT_RAY_AABB_NONE; + // Exit with no collision as soon as slab intersection becomes empty + if (tmin > tmax) + { + return ISECT_RAY_AABB_NONE; + } } - } - else - { - // Compute intersection t value of ray with near and far plane of slab - float t1 = time1.GetY(); - float t2 = time2.GetY(); - float nSign = -1.0f; - // Make t1 be intersection with near plane, t2 with far plane - if (t1 > t2) + // Y + if (std::fabs(dir.GetY()) < eps) { - AZStd::swap(t1, t2); - nSign = 1.0f; + // Ray is parallel to slab. No hit if origin not within slab + if (rayStart.GetY() < aabbMin.GetY() || rayStart.GetY() > aabbMax.GetY()) + { + return ISECT_RAY_AABB_NONE; + } } - - // Compute the intersection of slab intersections intervals - if (tmin < t1) + else { - tmin = t1; + // Compute intersection t value of ray with near and far plane of slab + float t1 = time1.GetY(); + float t2 = time2.GetY(); + float nSign = -1.0f; - startNormal.Set(0.0f, nSign, 0.0f); - } + // Make t1 be intersection with near plane, t2 with far plane + if (t1 > t2) + { + AZStd::swap(t1, t2); + nSign = 1.0f; + } - tmax = AZ::GetMin(tmax, t2); + // Compute the intersection of slab intersections intervals + if (tmin < t1) + { + tmin = t1; - // Exit with no collision as soon as slab intersection becomes empty - if (tmin > tmax) - { - return ISECT_RAY_AABB_NONE; - } - } + startNormal.Set(0.0f, nSign, 0.0f); + } - // Z - if (std::fabs(dir.GetZ()) < eps) - { - // Ray is parallel to slab. No hit if origin not within slab - if (rayStart.GetZ() < aabbMin.GetZ() || rayStart.GetZ() > aabbMax.GetZ()) - { - return ISECT_RAY_AABB_NONE; - } - } - else - { - // Compute intersection t value of ray with near and far plane of slab - float t1 = time1.GetZ(); - float t2 = time2.GetZ(); - float nSign = -1.0f; + tmax = AZ::GetMin(tmax, t2); - // Make t1 be intersection with near plane, t2 with far plane - if (t1 > t2) - { - AZStd::swap(t1, t2); - nSign = 1.0f; + // Exit with no collision as soon as slab intersection becomes empty + if (tmin > tmax) + { + return ISECT_RAY_AABB_NONE; + } } - // Compute the intersection of slab intersections intervals - if (tmin < t1) + // Z + if (std::fabs(dir.GetZ()) < eps) { - tmin = t1; - - startNormal.Set(0.0f, 0.0f, nSign); + // Ray is parallel to slab. No hit if origin not within slab + if (rayStart.GetZ() < aabbMin.GetZ() || rayStart.GetZ() > aabbMax.GetZ()) + { + return ISECT_RAY_AABB_NONE; + } } - - tmax = AZ::GetMin(tmax, t2); - - // Exit with no collision as soon as slab intersection becomes empty - if (tmin > tmax) + else { - return ISECT_RAY_AABB_NONE; - } - } - - tStart = tmin; - tEnd = tmax; + // Compute intersection t value of ray with near and far plane of slab + float t1 = time1.GetZ(); + float t2 = time2.GetZ(); + float nSign = -1.0f; - if (tmin == 0.0f) // no intersect if the segments starts inside or coincident the aabb - { - return ISECT_RAY_AABB_SA_INSIDE; - } - - // Ray intersects all 3 slabs. Return point (q) and intersection t value (tmin) - //inter = rayStart + dir * tmin; - return ISECT_RAY_AABB_ISECT; -} - -//========================================================================= -// IntersectRayAABB2 -// [2/18/2011] -//========================================================================= -RayAABBIsectTypes -AZ::Intersect::IntersectRayAABB2(const Vector3& rayStart, const Vector3& dirRCP, const Aabb& aabb, float& start, float& end) -{ - float tmin, tmax, tymin, tymax, tzmin, tzmax; - Vector3 vZero = Vector3::CreateZero(); + // Make t1 be intersection with near plane, t2 with far plane + if (t1 > t2) + { + AZStd::swap(t1, t2); + nSign = 1.0f; + } - Vector3 min = (Vector3::CreateSelectCmpGreaterEqual(dirRCP, vZero, aabb.GetMin(), aabb.GetMax()) - rayStart) * dirRCP; - Vector3 max = (Vector3::CreateSelectCmpGreaterEqual(dirRCP, vZero, aabb.GetMax(), aabb.GetMin()) - rayStart) * dirRCP; + // Compute the intersection of slab intersections intervals + if (tmin < t1) + { + tmin = t1; - tmin = min.GetX(); - tmax = max.GetX(); - tymin = min.GetY(); - tymax = max.GetY(); + startNormal.Set(0.0f, 0.0f, nSign); + } - if (tmin > tymax || tymin > tmax) - { - return ISECT_RAY_AABB_NONE; - } + tmax = AZ::GetMin(tmax, t2); - if (tymin > tmin) - { - tmin = tymin; - } + // Exit with no collision as soon as slab intersection becomes empty + if (tmin > tmax) + { + return ISECT_RAY_AABB_NONE; + } + } - if (tymax < tmax) - { - tmax = tymax; - } + tStart = tmin; + tEnd = tmax; - tzmin = min.GetZ(); - tzmax = max.GetZ(); + if (tmin == 0.0f) // no intersect if the segments starts inside or coincident the aabb + { + return ISECT_RAY_AABB_SA_INSIDE; + } - if (tmin > tzmax || tzmin > tmax) - { - return ISECT_RAY_AABB_NONE; + // Ray intersects all 3 slabs. Return point (q) and intersection t value (tmin) + // inter = rayStart + dir * tmin; + return ISECT_RAY_AABB_ISECT; } - if (tzmin > tmin) - { - tmin = tzmin; - } - if (tzmax < tmax) + //========================================================================= + // IntersectRayAABB2 + // [2/18/2011] + //========================================================================= + Intersect::RayAABBIsectTypes Intersect::IntersectRayAABB2( + const Vector3& rayStart, const Vector3& dirRCP, const Aabb& aabb, float& start, float& end) { - tmax = tzmax; - } + float tmin, tmax, tymin, tymax, tzmin, tzmax; + Vector3 vZero = Vector3::CreateZero(); - start = tmin; - end = tmax; + Vector3 min = (Vector3::CreateSelectCmpGreaterEqual(dirRCP, vZero, aabb.GetMin(), aabb.GetMax()) - rayStart) * dirRCP; + Vector3 max = (Vector3::CreateSelectCmpGreaterEqual(dirRCP, vZero, aabb.GetMax(), aabb.GetMin()) - rayStart) * dirRCP; - return ISECT_RAY_AABB_ISECT; -} + tmin = min.GetX(); + tmax = max.GetX(); + tymin = min.GetY(); + tymax = max.GetY(); -bool AZ::Intersect::IntersectRayDisk( - const Vector3& rayOrigin, const Vector3& rayDir, const Vector3& diskCenter, const float diskRadius, const Vector3& diskNormal, float& t) -{ - // First intersect with the plane of the disk - float planeIntersectionDistance; - int intersectionCount = IntersectRayPlane(rayOrigin, rayDir, diskCenter, diskNormal, planeIntersectionDistance); - if (intersectionCount == 1) - { - // If the plane intersection point is inside the disk radius, then it intersected the disk. - Vector3 pointOnPlane = rayOrigin + rayDir * planeIntersectionDistance; - if (pointOnPlane.GetDistance(diskCenter) < diskRadius) + if (tmin > tymax || tymin > tmax) { - t = planeIntersectionDistance; - return true; + return ISECT_RAY_AABB_NONE; } - } - return false; -} -// Reference: Real-Time Collision Detection - 5.3.7 Intersecting Ray or Segment Against Cylinder, and the book's errata. -int AZ::Intersect::IntersectRayCappedCylinder( - const Vector3& rayOrigin, const Vector3& rayDir, - const Vector3& cylinderEnd1, const Vector3& cylinderDir, - float cylinderHeight, float cylinderRadius, float &t1, float &t2) -{ - // dr = rayDir - // dc = cylinderDir - // r = cylinderRadius - // Vector3 cylinderEnd2 = cylinderEnd1 + cylinderHeight * cylinderDir; - Vector3 m = rayOrigin - cylinderEnd1; // vector from cylinderEnd1 to rayOrigin - float dcm = cylinderDir.Dot(m); // projection of m on cylinderDir - float dcdr = cylinderDir.Dot(rayDir); // projection of rayDir on cylinderDir - float drm = rayDir.Dot(m); // projection of m on rayDir - float r2 = cylinderRadius * cylinderRadius; - - if (dcm < 0.0f && dcdr <= 0.0f) - { - return 0; // rayOrigin is outside cylinderEnd1 and rayDir is pointing away from cylinderEnd1 - } - if (dcm > cylinderHeight && dcdr >= 0.0f) - { - return 0; // rayOrigin is outside cylinderEnd2 and rayDir is pointing away from cylinderEnd2 - } - - // point RP on the ray: RP(t) = rayOrigin + t * rayDir - // point CP on the cylinder surface: |(CP - cylinderEnd1) - cylinderDir.Dot(cp - cylinderEnd1) * cylinderDir|^2 = cylinderRadius^2 - // substitute RP(t) for CP: a*t^2 + 2b*t + c = 0, solving for t = [-2b +/- sqrt(4b^2 - 4ac)] / 2a - float a = 1.0f - dcdr * dcdr; // always greater than or equal to 0 - float b = drm - dcm * dcdr; - float c = m.Dot(m) - dcm * dcm - r2; - - const float EPSILON = 0.00001f; + if (tymin > tmin) + { + tmin = tymin; + } - if (fabsf(a) < EPSILON) // the ray is parallel to the cylinder - { - if (c > EPSILON) // the ray is outside the cylinder + if (tymax < tmax) { - return 0; + tmax = tymax; } - else if (dcm < 0.0f) // the ray origin is on cylinderEnd1 side and ray is pointing to cylinderEnd2 + + tzmin = min.GetZ(); + tzmax = max.GetZ(); + + if (tmin > tzmax || tzmin > tmax) { - t1 = -dcm; - t2 = -dcm + cylinderHeight; - return 2; + return ISECT_RAY_AABB_NONE; } - else if (dcm > cylinderHeight) // the ray origin is on cylinderEnd2 side and ray is pointing to cylinderEnd1 + + if (tzmin > tmin) { - t1 = dcm - cylinderHeight; - t2 = dcm; - return 2; + tmin = tzmin; } - else // (dcm > 0.0f && dcm < cylinderHeight) // the ray origin is inside the cylinder + if (tzmax < tmax) { - if (dcdr > 0.0f) // the ray is pointing to cylinderEnd2 - { - t1 = cylinderHeight - dcm; - return 1; - } - else if (dcdr < 0.0f) // the ray is pointing to cylinderEnd1 - { - t2 = dcm; - return 1; - } - else // impossible in theory - { - return 0; - } + tmax = tzmax; } - } - - float discr = b * b - a * c; - if (discr < 0.0f) - { - return 0; - } - float sqrt_discr = sqrt(discr); - float tt1 = (-b - sqrt_discr) / a; - float tt2 = (-b + sqrt_discr) / a; + start = tmin; + end = tmax; - if (tt2 < 0.0f) // both intersections are behind the ray origin - { - return 0; + return ISECT_RAY_AABB_ISECT; } - // Vector3 AP2 = (rayOrigin + tt2 * rayDir) - cylinderEnd1; // vector from cylinderEnd1 to the intersecting point of parameter tt2 - // float s2 = cylinderDir.Dot(AP2); - float s2 = dcm + tt2 * dcdr; - - if (discr < EPSILON) // tt1 == tt2 + bool Intersect::IntersectRayDisk( + const Vector3& rayOrigin, + const Vector3& rayDir, + const Vector3& diskCenter, + const float diskRadius, + const Vector3& diskNormal, + float& t) { - if (s2 >= 0.0f && s2 <= cylinderHeight) + // First intersect with the plane of the disk + float planeIntersectionDistance; + int intersectionCount = IntersectRayPlane(rayOrigin, rayDir, diskCenter, diskNormal, planeIntersectionDistance); + if (intersectionCount == 1) { - t1 = tt1; - return 1; + // If the plane intersection point is inside the disk radius, then it intersected the disk. + Vector3 pointOnPlane = rayOrigin + rayDir * planeIntersectionDistance; + if (pointOnPlane.GetDistance(diskCenter) < diskRadius) + { + t = planeIntersectionDistance; + return true; + } } + return false; } - // Vector3 AP1 = (rayOrigin + tt1 * rayDir) - cylinderEnd1; // vector from cylinderEnd1 to the intersecting point of parameter tt1 - // float s1 = cylinderDir.Dot(AP1); - float s1 = dcm + tt1 * dcdr; - - if (s1 < 0.0f) // intersecting point of parameter tt1 is outside on cylinderEnd1 side + // Reference: Real-Time Collision Detection - 5.3.7 Intersecting Ray or Segment Against Cylinder, and the book's errata. + int Intersect::IntersectRayCappedCylinder( + const Vector3& rayOrigin, + const Vector3& rayDir, + const Vector3& cylinderEnd1, + const Vector3& cylinderDir, + float cylinderHeight, + float cylinderRadius, + float& t1, + float& t2) { - if (s2 < 0.0f) // intersecting point of parameter tt2 is outside on cylinderEnd1 side + // dr = rayDir + // dc = cylinderDir + // r = cylinderRadius + // Vector3 cylinderEnd2 = cylinderEnd1 + cylinderHeight * cylinderDir; + Vector3 m = rayOrigin - cylinderEnd1; // vector from cylinderEnd1 to rayOrigin + float dcm = cylinderDir.Dot(m); // projection of m on cylinderDir + float dcdr = cylinderDir.Dot(rayDir); // projection of rayDir on cylinderDir + float drm = rayDir.Dot(m); // projection of m on rayDir + float r2 = cylinderRadius * cylinderRadius; + + if (dcm < 0.0f && dcdr <= 0.0f) { - return 0; + return 0; // rayOrigin is outside cylinderEnd1 and rayDir is pointing away from cylinderEnd1 } - else if (s2 == 0.0f) // ray touching the brim of the cylinderEnd1 + if (dcm > cylinderHeight && dcdr >= 0.0f) { - t1 = tt2; - return 1; + return 0; // rayOrigin is outside cylinderEnd2 and rayDir is pointing away from cylinderEnd2 } - else + + // point RP on the ray: RP(t) = rayOrigin + t * rayDir + // point CP on the cylinder surface: |(CP - cylinderEnd1) - cylinderDir.Dot(cp - cylinderEnd1) * cylinderDir|^2 = cylinderRadius^2 + // substitute RP(t) for CP: a*t^2 + 2b*t + c = 0, solving for t = [-2b +/- sqrt(4b^2 - 4ac)] / 2a + float a = 1.0f - dcdr * dcdr; // always greater than or equal to 0 + float b = drm - dcm * dcdr; + float c = m.Dot(m) - dcm * dcm - r2; + + const float EPSILON = 0.00001f; + + if (fabsf(a) < EPSILON) // the ray is parallel to the cylinder { - if (s2 > cylinderHeight) // intersecting point of parameter tt2 is outside on cylinderEnd2 side + if (c > EPSILON) // the ray is outside the cylinder { - // t2 can be computed from the equation: dot(rayOrigin + t2 * rayDir - cylinderEnd1, cylinderDir) = cylinderHeight - t2 = (cylinderHeight - dcm) / dcdr; + return 0; } - else + else if (dcm < 0.0f) // the ray origin is on cylinderEnd1 side and ray is pointing to cylinderEnd2 { - t2 = tt2; + t1 = -dcm; + t2 = -dcm + cylinderHeight; + return 2; } - if (dcm > 0.0f) // ray origin inside cylinder + else if (dcm > cylinderHeight) // the ray origin is on cylinderEnd2 side and ray is pointing to cylinderEnd1 { - t1 = t2; - return 1; + t1 = dcm - cylinderHeight; + t2 = dcm; + return 2; } - else + else // (dcm > 0.0f && dcm < cylinderHeight) // the ray origin is inside the cylinder { - // t1 can be computed from the equation: dot(rayOrigin + t1 * rayDir - cylinderEnd1, cylinderDir) = 0 - t1 = -dcm / dcdr; - return 2; + if (dcdr > 0.0f) // the ray is pointing to cylinderEnd2 + { + t1 = cylinderHeight - dcm; + return 1; + } + else if (dcdr < 0.0f) // the ray is pointing to cylinderEnd1 + { + t2 = dcm; + return 1; + } + else // impossible in theory + { + return 0; + } } } - } - else if (s1 > cylinderHeight) // intersecting point of parameter tt1 is outside on cylinderEnd2 side - { - if (s2 > cylinderHeight) // intersecting point of parameter tt2 is outside on cylinderEnd2 side + + float discr = b * b - a * c; + if (discr < 0.0f) { return 0; } - else if (s2 == cylinderHeight) + + float sqrt_discr = sqrt(discr); + float tt1 = (-b - sqrt_discr) / a; + float tt2 = (-b + sqrt_discr) / a; + + if (tt2 < 0.0f) // both intersections are behind the ray origin { - t1 = tt2; - return 1; + return 0; } - else + + // Vector3 AP2 = (rayOrigin + tt2 * rayDir) - cylinderEnd1; // vector from cylinderEnd1 to the intersecting point of parameter tt2 + // float s2 = cylinderDir.Dot(AP2); + float s2 = dcm + tt2 * dcdr; + + if (discr < EPSILON) // tt1 == tt2 { - if (s2 < 0.0f) + if (s2 >= 0.0f && s2 <= cylinderHeight) { - t2 = -dcm / dcdr; + t1 = tt1; + return 1; } - else + } + + // Vector3 AP1 = (rayOrigin + tt1 * rayDir) - cylinderEnd1; // vector from cylinderEnd1 to the intersecting point of parameter tt1 + // float s1 = cylinderDir.Dot(AP1); + float s1 = dcm + tt1 * dcdr; + + if (s1 < 0.0f) // intersecting point of parameter tt1 is outside on cylinderEnd1 side + { + if (s2 < 0.0f) // intersecting point of parameter tt2 is outside on cylinderEnd1 side { - t2 = tt2; + return 0; } - if (dcm < cylinderHeight) + else if (s2 == 0.0f) // ray touching the brim of the cylinderEnd1 { - t1 = t2; + t1 = tt2; return 1; } else { - t1 = (cylinderHeight - dcm) / dcdr; - return 2; - } - } - } - else // intersecting point of parameter tt1 is in between two cylinder ends - { - if (s2 < 0.0f) - { - t2 = -dcm / dcdr; - } - else if (s2 > cylinderHeight) - { - t2 = (cylinderHeight - dcm) / dcdr; - } - else - { - t2 = tt2; + if (s2 > cylinderHeight) // intersecting point of parameter tt2 is outside on cylinderEnd2 side + { + // t2 can be computed from the equation: dot(rayOrigin + t2 * rayDir - cylinderEnd1, cylinderDir) = cylinderHeight + t2 = (cylinderHeight - dcm) / dcdr; + } + else + { + t2 = tt2; + } + if (dcm > 0.0f) // ray origin inside cylinder + { + t1 = t2; + return 1; + } + else + { + // t1 can be computed from the equation: dot(rayOrigin + t1 * rayDir - cylinderEnd1, cylinderDir) = 0 + t1 = -dcm / dcdr; + return 2; + } + } } - if (tt1 > 0.0f) + else if (s1 > cylinderHeight) // intersecting point of parameter tt1 is outside on cylinderEnd2 side { - t1 = tt1; - return 2; + if (s2 > cylinderHeight) // intersecting point of parameter tt2 is outside on cylinderEnd2 side + { + return 0; + } + else if (s2 == cylinderHeight) + { + t1 = tt2; + return 1; + } + else + { + if (s2 < 0.0f) + { + t2 = -dcm / dcdr; + } + else + { + t2 = tt2; + } + if (dcm < cylinderHeight) + { + t1 = t2; + return 1; + } + else + { + t1 = (cylinderHeight - dcm) / dcdr; + return 2; + } + } } - else + else // intersecting point of parameter tt1 is in between two cylinder ends { - t1 = t2; - return 1; + if (s2 < 0.0f) + { + t2 = -dcm / dcdr; + } + else if (s2 > cylinderHeight) + { + t2 = (cylinderHeight - dcm) / dcdr; + } + else + { + t2 = tt2; + } + if (tt1 > 0.0f) + { + t1 = tt1; + return 2; + } + else + { + t1 = t2; + return 1; + } } } -} -int AZ::Intersect::IntersectRayCone( - const Vector3& rayOrigin, const Vector3& rayDir, - const Vector3& coneApex, const Vector3& coneDir, float coneHeight, - float coneBaseRadius, float& t1, float& t2) -{ - // Q = rayOrgin, A = coneApex - Vector3 AQ = rayOrigin - coneApex; - float m = coneDir.Dot(AQ); // projection of m on cylinderDir - float k = coneDir.Dot(rayDir); // projection of rayDir on cylinderDir - - if (m < 0.0f && k <= 0.0f) - { - // rayOrigin is outside the cone on coneApex side and rayDir is pointing away - return 0; - } - if (m > coneHeight && k >= 0.0f) + int Intersect::IntersectRayCone( + const Vector3& rayOrigin, + const Vector3& rayDir, + const Vector3& coneApex, + const Vector3& coneDir, + float coneHeight, + float coneBaseRadius, + float& t1, + float& t2) { - // rayOrigin is outside the cone on coneBase side and rayDir is pointing away - return 0; - } - - float r2 = coneBaseRadius * coneBaseRadius; - float h2 = coneHeight * coneHeight; + // Q = rayOrgin, A = coneApex + Vector3 AQ = rayOrigin - coneApex; + float m = coneDir.Dot(AQ); // projection of m on cylinderDir + float k = coneDir.Dot(rayDir); // projection of rayDir on cylinderDir - float m2 = m * m; - float k2 = k * k; - float q2 = AQ.Dot(AQ); - - float n = rayDir.Dot(AQ); + if (m < 0.0f && k <= 0.0f) + { + // rayOrigin is outside the cone on coneApex side and rayDir is pointing away + return 0; + } + if (m > coneHeight && k >= 0.0f) + { + // rayOrigin is outside the cone on coneBase side and rayDir is pointing away + return 0; + } - const float EPSILON = 0.00001f; + float r2 = coneBaseRadius * coneBaseRadius; + float h2 = coneHeight * coneHeight; - // point RP on the ray: RP(t) = rayOrigin + t * rayDir - // point CP on the cone surface: similar triangle property - // |dot(CP - A, coneDir) * coneDir| / coneHeight = |(CP - A) - (dot(CP - A, coneDir) * coneDir)| coneRadius - // substitute RP(t) for CP: a*t^2 + 2b*t + c = 0, solving for t - float a = (r2 + h2) * k2 - h2; - float b = (r2 + h2) * m * k - h2 * n; - float c = (r2 + h2) * m2 - h2 * q2; + float m2 = m * m; + float k2 = k * k; + float q2 = AQ.Dot(AQ); - float discriminant = b * b - a * c; - if (discriminant < -EPSILON) - { - return 0; - } - discriminant = AZ::GetMax(discriminant, 0.0f); + float n = rayDir.Dot(AQ); - if (fabsf(a) < EPSILON) // the ray is parallel to the cone surface's tangent line - { - if (b < EPSILON && fabsf(c) < EPSILON) // ray overlapping with cone surface - { - t1 = rayDir.Dot(coneApex - rayOrigin); - } - else // ray has only one intersecting point with the cone - { - t1 = -c / (2 * b); - } + const float EPSILON = 0.00001f; - t2 = (coneHeight - m) / k; // t2 can be computed from the equation: dot(Q + t2 * rayDir - A, coneDir) = coneHeight + // point RP on the ray: RP(t) = rayOrigin + t * rayDir + // point CP on the cone surface: similar triangle property + // |dot(CP - A, coneDir) * coneDir| / coneHeight = |(CP - A) - (dot(CP - A, coneDir) * coneDir)| coneRadius + // substitute RP(t) for CP: a*t^2 + 2b*t + c = 0, solving for t + float a = (r2 + h2) * k2 - h2; + float b = (r2 + h2) * m * k - h2 * n; + float c = (r2 + h2) * m2 - h2 * q2; - if (t1 < 0.0f && t2 < 0.0f) + float discriminant = b * b - a * c; + if (discriminant < -EPSILON) { return 0; } + discriminant = AZ::GetMax(discriminant, 0.0f); - if (fabsf(t1 - t2) < EPSILON) // the ray intersects the brim of the circumference of the cone base + if (fabsf(a) < EPSILON) // the ray is parallel to the cone surface's tangent line { - return 1; - } + if (b < EPSILON && fabsf(c) < EPSILON) // ray overlapping with cone surface + { + t1 = rayDir.Dot(coneApex - rayOrigin); + } + else // ray has only one intersecting point with the cone + { + t1 = -c / (2 * b); + } - float s1 = m + t1 * k; // coneDir.Dot(rayOrigin + t1 * rayDir - coneApex); - if (s1 < 0.0f || s1 > coneHeight) - { - return 0; - } - else - { - if (k < 0.0f) // ray shooting from base to apex + t2 = (coneHeight - m) / k; // t2 can be computed from the equation: dot(Q + t2 * rayDir - A, coneDir) = coneHeight + + if (t1 < 0.0f && t2 < 0.0f) { - if (m >= coneHeight) // ray origin outside cone - { - float temp = t1; - t1 = t2; - t2 = temp; - return 2; - } - else if (t1 >= 0.0f) // ray origin inside cone - { - t1 = t2; - return 1; - } - else - { - return 0; - } + return 0; + } + + if (fabsf(t1 - t2) < EPSILON) // the ray intersects the brim of the circumference of the cone base + { + return 1; + } + + float s1 = m + t1 * k; // coneDir.Dot(rayOrigin + t1 * rayDir - coneApex); + if (s1 < 0.0f || s1 > coneHeight) + { + return 0; } else { - if (m > coneHeight) - { - return 0; - } - if (t1 >= 0.0f) // ray origin outside cone + if (k < 0.0f) // ray shooting from base to apex { - return 2; + if (m >= coneHeight) // ray origin outside cone + { + float temp = t1; + t1 = t2; + t2 = temp; + return 2; + } + else if (t1 >= 0.0f) // ray origin inside cone + { + t1 = t2; + return 1; + } + else + { + return 0; + } } else { - t1 = t2; - return 1; + if (m > coneHeight) + { + return 0; + } + if (t1 >= 0.0f) // ray origin outside cone + { + return 2; + } + else + { + t1 = t2; + return 1; + } } } } - } - if (discriminant < EPSILON) // two intersecting points coincide - { - if (fabsf(n * n - q2) < EPSILON) // the ray is through the apex + if (discriminant < EPSILON) // two intersecting points coincide { - float cosineA2 = h2 / (r2 + h2); - float cosineAQ2 = cosineA2 * q2; - - if (m2 > cosineAQ2) // the ray origin is inside the cone or its mirroring counterpart + if (fabsf(n * n - q2) < EPSILON) // the ray is through the apex { - if (m <= 0.0f) // the ray origin outside the cone on the apex side, shooting towards the base - { - t1 = -b / a; - t2 = (coneHeight - m) / k; - return 2; - } - else if (m >= coneHeight) // the ray origin is outside the cone on the base side, shooting towards towards the apex + float cosineA2 = h2 / (r2 + h2); + float cosineAQ2 = cosineA2 * q2; + + if (m2 > cosineAQ2) // the ray origin is inside the cone or its mirroring counterpart { - t1 = (coneHeight - m) / k; - t2 = -b / a; - return 2; + if (m <= 0.0f) // the ray origin outside the cone on the apex side, shooting towards the base + { + t1 = -b / a; + t2 = (coneHeight - m) / k; + return 2; + } + else if (m >= coneHeight) // the ray origin is outside the cone on the base side, shooting towards towards the apex + { + t1 = (coneHeight - m) / k; + t2 = -b / a; + return 2; + } + else + { + if (k > 0.0f) // the ray origin is inside the cone, shooting towards the base + { + t1 = (coneHeight - m) / k; + return 1; + } + else // the ray origin is inside the cone, shooting towards the apex + { + t1 = -b / a; + return 1; + } + } } - else + else // the ray origin is outside the cone { - if (k > 0.0f) // the ray origin is inside the cone, shooting towards the base + t1 = -b / a; + if (t1 > 0.0f) { - t1 = (coneHeight - m) / k; return 1; } - else // the ray origin is inside the cone, shooting towards the apex + else { - t1 = -b / a; - return 1; + return 0; } } } - else // the ray origin is outside the cone + else // the ray is touching the cone surface but not through the apex { t1 = -b / a; if (t1 > 0.0f) { - return 1; - } - else - { - return 0; - } - } - } - else // the ray is touching the cone surface but not through the apex - { - t1 = -b / a; - if (t1 > 0.0f) - { - float s1 = m + t1 * k; // projection length of the line segment from the apex to intersection_t1 onto the coneDir - if (s1 >= 0.0f && s1 <= coneHeight) - { - return 1; + float s1 = m + t1 * k; // projection length of the line segment from the apex to intersection_t1 onto the coneDir + if (s1 >= 0.0f && s1 <= coneHeight) + { + return 1; + } } + return 0; } - return 0; } - } - - float sqrtDiscr = sqrt(discriminant); - float tt1 = (-b - sqrtDiscr) / a; - float tt2 = (-b + sqrtDiscr) / a; - /* Test s1 and s2 to see the positions of the intersecting points relative to the cylinder's two ends. */ + float sqrtDiscr = sqrt(discriminant); + float tt1 = (-b - sqrtDiscr) / a; + float tt2 = (-b + sqrtDiscr) / a; - // s1 = coneDir.Dot(rayOrigin + tt1 * rayDir - coneApex), which expands into the following - float s1 = m + tt1 * k; - // s2 = coneDir.Dot(rayOrigin + tt2 * rayDir - coneApex), which expands into the following - float s2 = m + tt2 * k; + /* Test s1 and s2 to see the positions of the intersecting points relative to the cylinder's two ends. */ - if (s1 < 0.0f) - { - if (s2 < 0.0f || s2 > coneHeight) - { - return 0; - } - else + // s1 = coneDir.Dot(rayOrigin + tt1 * rayDir - coneApex), which expands into the following + float s1 = m + tt1 * k; + // s2 = coneDir.Dot(rayOrigin + tt2 * rayDir - coneApex), which expands into the following + float s2 = m + tt2 * k; + + if (s1 < 0.0f) { - if (tt2 >= 0.0f) // ray origin outside cone - { - t1 = tt2; - t2 = (coneHeight - m) / k; - return 2; - } - else if (m > coneHeight) // ray origin outside cone on the base side, the + if (s2 < 0.0f || s2 > coneHeight) { return 0; } else { - t1 = (coneHeight - m) / k; - return 1; - } - } - } - else if (s1 > coneHeight) - { - if (s2 < 0.0f || s2 > coneHeight ) - { - return 0; - } - else - { - if (tt2 < 0.0f) - { - return 0; - } - else if (m >= coneHeight) - { - t1 = (coneHeight - m) / k; - t2 = tt2; - return 2; - } - else // ray origin inside cone - { - t1 = tt2; - return 1; + if (tt2 >= 0.0f) // ray origin outside cone + { + t1 = tt2; + t2 = (coneHeight - m) / k; + return 2; + } + else if (m > coneHeight) // ray origin outside cone on the base side, the + { + return 0; + } + else + { + t1 = (coneHeight - m) / k; + return 1; + } } } - } - else - { - if (s2 < 0.0f) + else if (s1 > coneHeight) { - if (m >= coneHeight) - { - t1 = (coneHeight - m) / k; - t2 = tt1; - return 2; - } - else if (tt1 >= 0.0f) // ray origin inside cone - { - t1 = tt1; - return 1; - } - else + if (s2 < 0.0f || s2 > coneHeight) { return 0; } - } - else if (s2 > coneHeight) - { - if (tt1 >= 0.0f) - { - t1 = tt1; - t2 = (coneHeight - m) / k; - return 2; - } - else if (m <= coneHeight) - { - t1 = (coneHeight - m) / k; - return 1; - } else { - return 0; + if (tt2 < 0.0f) + { + return 0; + } + else if (m >= coneHeight) + { + t1 = (coneHeight - m) / k; + t2 = tt2; + return 2; + } + else // ray origin inside cone + { + t1 = tt2; + return 1; + } } } else { - if (tt1 >= 0.0f) + if (s2 < 0.0f) { - t1 = tt1; - t2 = tt2; - return 2; + if (m >= coneHeight) + { + t1 = (coneHeight - m) / k; + t2 = tt1; + return 2; + } + else if (tt1 >= 0.0f) // ray origin inside cone + { + t1 = tt1; + return 1; + } + else + { + return 0; + } } - else if (tt2 >= 0.0f) + else if (s2 > coneHeight) { - t1 = tt2; - return 1; + if (tt1 >= 0.0f) + { + t1 = tt1; + t2 = (coneHeight - m) / k; + return 2; + } + else if (m <= coneHeight) + { + t1 = (coneHeight - m) / k; + return 1; + } + else + { + return 0; + } } else { - return 0; - } - } - } -} - -int AZ::Intersect::IntersectRayPlane(const Vector3& rayOrigin, const Vector3& rayDir, const Vector3& planePos, const Vector3& planeNormal, float& t) -{ - // (rayOrigin + t * rayDir - planePos).dot(planeNormal) = 0 - - const float EPSILON = 0.00001f; - - float n = rayDir.Dot(planeNormal); - if (fabsf(n) < EPSILON) - { - return 0; - } - - t = planeNormal.Dot(planePos - rayOrigin) / n; - if (t < 0.0f) - { - return 0; - } - else - { - return 1; - } -} - -int AZ::Intersect::IntersectRayQuad( - const Vector3& rayOrigin, const Vector3& rayDir, const Vector3& vertexA, - const Vector3& vertexB, const Vector3& vertexC, const Vector3& vertexD, float& t) -{ - const float EPSILON = 0.0001f; - - Vector3 AC = vertexC - vertexA; - Vector3 AB = vertexB - vertexA; - Vector3 QA = vertexA - rayOrigin; - - Vector3 triN = AB.Cross(AC); // the normal of the triangle ABC - float dn = rayDir.Dot(triN); - - // Early-out if ray is facing away from ABC triangle - if (dn * triN.Dot(QA) < 0) - { - return 0; - } - - Vector3 E = rayDir.Cross(QA); - float dnAbs = 0.0f; - - if (dn < -EPSILON) // vertices have counter-clock wise winding when looking at the quad from rayOrigin - { - dnAbs = -dn; - } - else if (dn > EPSILON) - { - E = -E; - dnAbs = dn; - } - else // the ray is parallel to the quad plane - { - return 0; - } - - // compute barycentric coordinates - float v = E.Dot(AC); - - if (v >= 0.0f && v < dnAbs) - { - float w = -E.Dot(AB); - if (w < 0.0f || v + w > dnAbs) - { - return 0; - } - } - else if (v < 0.0f && v > -dnAbs) - { - Vector3 DA = vertexA - vertexD; - float w = E.Dot(DA); - if (w > 0.0f || v + w < -dnAbs) // v, w are negative - { - return 0; - } - } - else - { - return 0; - } - - t = triN.Dot(QA) / dn; - return 1; -} - -// reference: Real-Time Collision Detection, 5.3.3 Intersecting Ray or Segment Against Box -bool AZ::Intersect::IntersectRayBox( - const Vector3& rayOrigin, const Vector3& rayDir, const Vector3& boxCenter, const Vector3& boxAxis1, - const Vector3& boxAxis2, const Vector3& boxAxis3, float boxHalfExtent1, float boxHalfExtent2, float boxHalfExtent3, float& t) -{ - const float EPSILON = 0.00001f; - - float tmin = 0.0f; // the nearest to the ray origin - float tmax = AZ::Constants::FloatMax; // the farthest from the ray origin - - Vector3 P = boxCenter - rayOrigin; // precomputed variable for calculating the vector from rayOrigin to a point on each box facet - Vector3 QAp; // vector from rayOrigin to the center of the facet of boxAxis - Vector3 QAn; // vector from rayOrigin to the center of the facet of -boxAxis - float tp = 0.0f; - float tn = 0.0f; - bool isRayOriginInsideBox = true; - - /* Test the slab_1 formed by the planes with normals boxAxis1 and -boxAxis1. */ - - Vector3 axis1 = boxHalfExtent1 * boxAxis1; - - QAp = P + axis1; - tp = QAp.Dot(boxAxis1); - - QAn = P - axis1; - tn = -QAn.Dot(boxAxis1); - - float n = rayDir.Dot(boxAxis1); - if (fabsf(n) < EPSILON) - { - // If the ray is parallel to the slab and the ray origin is outside, return no intersection. - if (tp < 0.0f || tn < 0.0f) - { - return false; + if (tt1 >= 0.0f) + { + t1 = tt1; + t2 = tt2; + return 2; + } + else if (tt2 >= 0.0f) + { + t1 = tt2; + return 1; + } + else + { + return 0; + } + } } } - else + + int Intersect::IntersectRayPlane( + const Vector3& rayOrigin, const Vector3& rayDir, const Vector3& planePos, const Vector3& planeNormal, float& t) { - if (tp < 0.0f || tn < 0.0f) + // (rayOrigin + t * rayDir - planePos).dot(planeNormal) = 0 + + const float EPSILON = 0.00001f; + + float n = rayDir.Dot(planeNormal); + if (fabsf(n) < EPSILON) { - isRayOriginInsideBox = false; + return 0; } - float div = 1.0f / n; - float t1 = tp * div; - float t2 = tn * (-div); - if (t1 > t2) + t = planeNormal.Dot(planePos - rayOrigin) / n; + if (t < 0.0f) { - AZStd::swap(t1, t2); + return 0; } - tmin = AZ::GetMax(tmin, t1); - tmax = AZ::GetMin(tmax, t2); - if (tmin > tmax) + else { - return false; + return 1; } } - /* test the slab_2 formed by plane with normals boxAxis2 and -boxAxis2 */ + int Intersect::IntersectRayQuad( + const Vector3& rayOrigin, + const Vector3& rayDir, + const Vector3& vertexA, + const Vector3& vertexB, + const Vector3& vertexC, + const Vector3& vertexD, + float& t) + { + const float EPSILON = 0.0001f; + + Vector3 AC = vertexC - vertexA; + Vector3 AB = vertexB - vertexA; + Vector3 QA = vertexA - rayOrigin; - Vector3 axis2 = boxHalfExtent2 * boxAxis2; + Vector3 triN = AB.Cross(AC); // the normal of the triangle ABC + float dn = rayDir.Dot(triN); - QAp = P + axis2; - tp = QAp.Dot(boxAxis2); + // Early-out if ray is facing away from ABC triangle + if (dn * triN.Dot(QA) < 0) + { + return 0; + } - QAn = P - axis2; - tn = -QAn.Dot(boxAxis2); + Vector3 E = rayDir.Cross(QA); + float dnAbs = 0.0f; - n = rayDir.Dot(boxAxis2); - if (fabsf(n) < EPSILON) - { - // If the ray is parallel to the slab and the ray origin is outside, return no intersection. - if (tp < 0.0f || tn < 0.0f) + if (dn < -EPSILON) // vertices have counter-clock wise winding when looking at the quad from rayOrigin { - return false; + dnAbs = -dn; } - } - else - { - if (tp < 0.0f || tn < 0.0f) + else if (dn > EPSILON) + { + E = -E; + dnAbs = dn; + } + else // the ray is parallel to the quad plane { - isRayOriginInsideBox = false; + return 0; } - float div = 1.0f / n; - float t1 = tp * div; - float t2 = tn * (-div); - if (t1 > t2) + // compute barycentric coordinates + float v = E.Dot(AC); + + if (v >= 0.0f && v < dnAbs) { - AZStd::swap(t1, t2); + float w = -E.Dot(AB); + if (w < 0.0f || v + w > dnAbs) + { + return 0; + } } - tmin = AZ::GetMax(tmin, t1); - tmax = AZ::GetMin(tmax, t2); - if (tmin > tmax) + else if (v < 0.0f && v > -dnAbs) { - return false; + Vector3 DA = vertexA - vertexD; + float w = E.Dot(DA); + if (w > 0.0f || v + w < -dnAbs) // v, w are negative + { + return 0; + } } + else + { + return 0; + } + + t = triN.Dot(QA) / dn; + return 1; } - /* test the slab_3 formed by plane with normals boxAxis3 and -boxAxis3 */ + // reference: Real-Time Collision Detection, 5.3.3 Intersecting Ray or Segment Against Box + bool Intersect::IntersectRayBox( + const Vector3& rayOrigin, + const Vector3& rayDir, + const Vector3& boxCenter, + const Vector3& boxAxis1, + const Vector3& boxAxis2, + const Vector3& boxAxis3, + float boxHalfExtent1, + float boxHalfExtent2, + float boxHalfExtent3, + float& t) + { + const float EPSILON = 0.00001f; - Vector3 axis3 = boxHalfExtent3 * boxAxis3; + float tmin = 0.0f; // the nearest to the ray origin + float tmax = AZ::Constants::FloatMax; // the farthest from the ray origin - QAp = P + axis3; - tp = QAp.Dot(boxAxis3); + Vector3 P = boxCenter - rayOrigin; // precomputed variable for calculating the vector from rayOrigin to a point on each box facet + Vector3 QAp; // vector from rayOrigin to the center of the facet of boxAxis + Vector3 QAn; // vector from rayOrigin to the center of the facet of -boxAxis + float tp = 0.0f; + float tn = 0.0f; + bool isRayOriginInsideBox = true; - QAn = P - axis3; - tn = -QAn.Dot(boxAxis3); + /* Test the slab_1 formed by the planes with normals boxAxis1 and -boxAxis1. */ - n = rayDir.Dot(boxAxis3); - if (fabsf(n) < EPSILON) - { - // If the ray is parallel to the slab and the ray origin is outside, return no intersection. - if (tp < 0.0f || tn < 0.0f) - { - return false; - } - } - else - { - if (tp < 0.0f || tn < 0.0f) - { - isRayOriginInsideBox = false; - } + Vector3 axis1 = boxHalfExtent1 * boxAxis1; + + QAp = P + axis1; + tp = QAp.Dot(boxAxis1); - float div = 1.0f / n; - float t1 = tp * div; - float t2 = tn * (-div); - if (t1 > t2) + QAn = P - axis1; + tn = -QAn.Dot(boxAxis1); + + float n = rayDir.Dot(boxAxis1); + if (fabsf(n) < EPSILON) { - AZStd::swap(t1, t2); + // If the ray is parallel to the slab and the ray origin is outside, return no intersection. + if (tp < 0.0f || tn < 0.0f) + { + return false; + } } - tmin = AZ::GetMax(tmin, t1); - tmax = AZ::GetMin(tmax, t2); - if (tmin > tmax) + else { - return false; + if (tp < 0.0f || tn < 0.0f) + { + isRayOriginInsideBox = false; + } + + float div = 1.0f / n; + float t1 = tp * div; + float t2 = tn * (-div); + if (t1 > t2) + { + AZStd::swap(t1, t2); + } + tmin = AZ::GetMax(tmin, t1); + tmax = AZ::GetMin(tmax, t2); + if (tmin > tmax) + { + return false; + } } - } - t = (isRayOriginInsideBox ? tmax : tmin); - return true; -} + /* test the slab_2 formed by plane with normals boxAxis2 and -boxAxis2 */ -bool AZ::Intersect::IntersectRayObb(const Vector3& rayOrigin, const Vector3& rayDir, const Obb& obb, float& t) -{ - return AZ::Intersect::IntersectRayBox(rayOrigin, rayDir, obb.GetPosition(), - obb.GetAxisX(), obb.GetAxisY(), obb.GetAxisZ(), - obb.GetHalfLengthX(), obb.GetHalfLengthY(), obb.GetHalfLengthZ(), t); -} + Vector3 axis2 = boxHalfExtent2 * boxAxis2; -//========================================================================= -// IntersectSegmentCylinder -// [10/21/2009] -//========================================================================= -CylinderIsectTypes -AZ::Intersect::IntersectSegmentCylinder( - const Vector3& sa, const Vector3& dir, const Vector3& p, const Vector3& q, const float r, float& t) -{ - const float epsilon = 0.001f; - Vector3 d = q - p; // can be cached - Vector3 m = sa - p; // -"- - Vector3 n = /*sb - sa*/ dir; // -"- + QAp = P + axis2; + tp = QAp.Dot(boxAxis2); - float md = m.Dot(d); - float nd = n.Dot(d); - float dd = d.Dot(d); + QAn = P - axis2; + tn = -QAn.Dot(boxAxis2); - // Test if segment fully outside either endcap of cylinder - if (md < 0.0f && md + nd < 0.0f) - { - return RR_ISECT_RAY_CYL_NONE; // Segment outside 'p' side of cylinder - } - if (md > dd && md + nd > dd) - { - return RR_ISECT_RAY_CYL_NONE; // Segment outside 'q' side of cylinder - } - float nn = n.Dot(n); - float mn = m.Dot(n); - float a = dd * nn - nd * nd; - float k = m.Dot(m) - r * r; - float c = dd * k - md * md; - if (std::fabs(a) < epsilon) - { - // Segment runs parallel to cylinder axis - if (c > 0.0f) + n = rayDir.Dot(boxAxis2); + if (fabsf(n) < EPSILON) { - return RR_ISECT_RAY_CYL_NONE; // 'a' and thus the segment lie outside cylinder + // If the ray is parallel to the slab and the ray origin is outside, return no intersection. + if (tp < 0.0f || tn < 0.0f) + { + return false; + } } - // Now known that segment intersects cylinder; figure out how it intersects - if (md < 0.0f) + else { - t = -mn / nn; // Intersect segment against 'p' endcap - return RR_ISECT_RAY_CYL_P_SIDE; + if (tp < 0.0f || tn < 0.0f) + { + isRayOriginInsideBox = false; + } + + float div = 1.0f / n; + float t1 = tp * div; + float t2 = tn * (-div); + if (t1 > t2) + { + AZStd::swap(t1, t2); + } + tmin = AZ::GetMax(tmin, t1); + tmax = AZ::GetMin(tmax, t2); + if (tmin > tmax) + { + return false; + } } - else if (md > dd) + + /* test the slab_3 formed by plane with normals boxAxis3 and -boxAxis3 */ + + Vector3 axis3 = boxHalfExtent3 * boxAxis3; + + QAp = P + axis3; + tp = QAp.Dot(boxAxis3); + + QAn = P - axis3; + tn = -QAn.Dot(boxAxis3); + + n = rayDir.Dot(boxAxis3); + if (fabsf(n) < EPSILON) { - t = (nd - mn) / nn; // Intersect segment against 'q' endcap - return RR_ISECT_RAY_CYL_Q_SIDE; + // If the ray is parallel to the slab and the ray origin is outside, return no intersection. + if (tp < 0.0f || tn < 0.0f) + { + return false; + } } else { - // 'a' lies inside cylinder - t = 0.0f; - return RR_ISECT_RAY_CYL_SA_INSIDE; + if (tp < 0.0f || tn < 0.0f) + { + isRayOriginInsideBox = false; + } + + float div = 1.0f / n; + float t1 = tp * div; + float t2 = tn * (-div); + if (t1 > t2) + { + AZStd::swap(t1, t2); + } + tmin = AZ::GetMax(tmin, t1); + tmax = AZ::GetMin(tmax, t2); + if (tmin > tmax) + { + return false; + } } + + t = (isRayOriginInsideBox ? tmax : tmin); + return true; } - float b = dd * mn - nd * md; - float discr = b * b - a * c; - if (discr < 0.0f) + + bool Intersect::IntersectRayObb(const Vector3& rayOrigin, const Vector3& rayDir, const Obb& obb, float& t) { - return RR_ISECT_RAY_CYL_NONE; // No real roots; no intersection + return Intersect::IntersectRayBox( + rayOrigin, rayDir, obb.GetPosition(), obb.GetAxisX(), obb.GetAxisY(), obb.GetAxisZ(), obb.GetHalfLengthX(), + obb.GetHalfLengthY(), obb.GetHalfLengthZ(), t); } - t = (-b - Sqrt(discr)) / a; - CylinderIsectTypes result = RR_ISECT_RAY_CYL_PQ; // default along the PQ segment - if (md + t * nd < 0.0f) + //========================================================================= + // IntersectSegmentCylinder + // [10/21/2009] + //========================================================================= + Intersect::CylinderIsectTypes Intersect::IntersectSegmentCylinder( + const Vector3& sa, const Vector3& dir, const Vector3& p, const Vector3& q, const float r, float& t) { - // Intersection outside cylinder on 'p' side - if (nd <= 0.0f) + const float epsilon = 0.001f; + Vector3 d = q - p; // can be cached + Vector3 m = sa - p; // -"- + Vector3 n = /*sb - sa*/ dir; // -"- + + float md = m.Dot(d); + float nd = n.Dot(d); + float dd = d.Dot(d); + + // Test if segment fully outside either endcap of cylinder + if (md < 0.0f && md + nd < 0.0f) { - return RR_ISECT_RAY_CYL_NONE; // Segment pointing away from endcap + return RR_ISECT_RAY_CYL_NONE; // Segment outside 'p' side of cylinder } - float t0 = -md / nd; - // Keep intersection if Dot(S(t) - p, S(t) - p) <= r^2 - if (k + t0 * (2.0f * mn + t0 * nn) <= 0.0f) + if (md > dd && md + nd > dd) { - // if( t0 < 0.0f ) t0 = 0.0f; // it's inside the cylinder - t = t0; - result = RR_ISECT_RAY_CYL_P_SIDE; + return RR_ISECT_RAY_CYL_NONE; // Segment outside 'q' side of cylinder } - else + float nn = n.Dot(n); + float mn = m.Dot(n); + float a = dd * nn - nd * nd; + float k = m.Dot(m) - r * r; + float c = dd * k - md * md; + if (std::fabs(a) < epsilon) { - return RR_ISECT_RAY_CYL_NONE; + // Segment runs parallel to cylinder axis + if (c > 0.0f) + { + return RR_ISECT_RAY_CYL_NONE; // 'a' and thus the segment lie outside cylinder + } + // Now known that segment intersects cylinder; figure out how it intersects + if (md < 0.0f) + { + t = -mn / nn; // Intersect segment against 'p' endcap + return RR_ISECT_RAY_CYL_P_SIDE; + } + else if (md > dd) + { + t = (nd - mn) / nn; // Intersect segment against 'q' endcap + return RR_ISECT_RAY_CYL_Q_SIDE; + } + else + { + // 'a' lies inside cylinder + t = 0.0f; + return RR_ISECT_RAY_CYL_SA_INSIDE; + } } - } - else if (md + t * nd > dd) - { - // Intersection outside cylinder on 'q' side - if (nd >= 0.0f) + float b = dd * mn - nd * md; + float discr = b * b - a * c; + if (discr < 0.0f) { - return RR_ISECT_RAY_CYL_NONE; // Segment pointing away from endcap + return RR_ISECT_RAY_CYL_NONE; // No real roots; no intersection } - float t0 = (dd - md) / nd; - // Keep intersection if Dot(S(t) - q, S(t) - q) <= r^2 - if (k + dd - 2.0f * md + t0 * (2.0f * (mn - nd) + t0 * nn) <= 0.0f) + t = (-b - Sqrt(discr)) / a; + CylinderIsectTypes result = RR_ISECT_RAY_CYL_PQ; // default along the PQ segment + + if (md + t * nd < 0.0f) { - // if( t0 < 0.0f ) t0 = 0.0f; // it's inside the cylinder - t = t0; - result = RR_ISECT_RAY_CYL_Q_SIDE; + // Intersection outside cylinder on 'p' side + if (nd <= 0.0f) + { + return RR_ISECT_RAY_CYL_NONE; // Segment pointing away from endcap + } + float t0 = -md / nd; + // Keep intersection if Dot(S(t) - p, S(t) - p) <= r^2 + if (k + t0 * (2.0f * mn + t0 * nn) <= 0.0f) + { + // if( t0 < 0.0f ) t0 = 0.0f; // it's inside the cylinder + t = t0; + result = RR_ISECT_RAY_CYL_P_SIDE; + } + else + { + return RR_ISECT_RAY_CYL_NONE; + } } - else + else if (md + t * nd > dd) { - return RR_ISECT_RAY_CYL_NONE; + // Intersection outside cylinder on 'q' side + if (nd >= 0.0f) + { + return RR_ISECT_RAY_CYL_NONE; // Segment pointing away from endcap + } + float t0 = (dd - md) / nd; + // Keep intersection if Dot(S(t) - q, S(t) - q) <= r^2 + if (k + dd - 2.0f * md + t0 * (2.0f * (mn - nd) + t0 * nn) <= 0.0f) + { + // if( t0 < 0.0f ) t0 = 0.0f; // it's inside the cylinder + t = t0; + result = RR_ISECT_RAY_CYL_Q_SIDE; + } + else + { + return RR_ISECT_RAY_CYL_NONE; + } } - } - // Segment intersects cylinder between the end-caps; t is correct - if (t > 1.0f) - { - return RR_ISECT_RAY_CYL_NONE; // Intersection lies outside segment - } - else if (t < 0.0f) - { - if (c <= 0.0f) - { - t = 0.0f; - return RR_ISECT_RAY_CYL_SA_INSIDE; // Segment starts inside - } - else + // Segment intersects cylinder between the end-caps; t is correct + if (t > 1.0f) { return RR_ISECT_RAY_CYL_NONE; // Intersection lies outside segment } - } - else - { - return result; - } -} -//========================================================================= -// IntersectSegmentCapsule -// [10/21/2009] -//========================================================================= -CapsuleIsectTypes -AZ::Intersect::IntersectSegmentCapsule(const Vector3& sa, const Vector3& dir, const Vector3& p, const Vector3& q, const float r, float& t) -{ - int result = IntersectSegmentCylinder(sa, dir, p, q, r, t); - - if (result == RR_ISECT_RAY_CYL_SA_INSIDE) - { - return ISECT_RAY_CAPSULE_SA_INSIDE; - } - - if (result == RR_ISECT_RAY_CYL_PQ) - { - return ISECT_RAY_CAPSULE_PQ; - } - - Vector3 dirNorm = dir; - float len = dirNorm.NormalizeWithLength(); - - // check spheres - float timeLenTop, timeLenBottom; - int resultTop = IntersectRaySphere(sa, dirNorm, p, r, timeLenTop); - if (resultTop == ISECT_RAY_SPHERE_SA_INSIDE) - { - return ISECT_RAY_CAPSULE_SA_INSIDE; - } - int resultBottom = IntersectRaySphere(sa, dirNorm, q, r, timeLenBottom); - if (resultBottom == ISECT_RAY_SPHERE_SA_INSIDE) - { - return ISECT_RAY_CAPSULE_SA_INSIDE; - } - - if (resultTop == ISECT_RAY_SPHERE_ISECT) - { - if (resultBottom == ISECT_RAY_SPHERE_ISECT) + else if (t < 0.0f) { - // if we intersect both spheres pick the closest one - if (timeLenTop < timeLenBottom) + if (c <= 0.0f) { - t = timeLenTop / len; - return ISECT_RAY_CAPSULE_P_SIDE; + t = 0.0f; + return RR_ISECT_RAY_CYL_SA_INSIDE; // Segment starts inside } else { - t = timeLenBottom / len; - return ISECT_RAY_CAPSULE_Q_SIDE; + return RR_ISECT_RAY_CYL_NONE; // Intersection lies outside segment } } else { - t = timeLenTop / len; - return ISECT_RAY_CAPSULE_P_SIDE; + return result; } } - - if (resultBottom == ISECT_RAY_SPHERE_ISECT) + //========================================================================= + // IntersectSegmentCapsule + // [10/21/2009] + //========================================================================= + Intersect::CapsuleIsectTypes Intersect::IntersectSegmentCapsule( + const Vector3& sa, const Vector3& dir, const Vector3& p, const Vector3& q, const float r, float& t) { - t = timeLenBottom / len; - return ISECT_RAY_CAPSULE_Q_SIDE; - } + int result = IntersectSegmentCylinder(sa, dir, p, q, r, t); - return ISECT_RAY_CAPSULE_NONE; -} + if (result == RR_ISECT_RAY_CYL_SA_INSIDE) + { + return ISECT_RAY_CAPSULE_SA_INSIDE; + } -//========================================================================= -// IntersectSegmentPolyhedron -// [10/21/2009] -//========================================================================= -bool -AZ::Intersect::IntersectSegmentPolyhedron( - const Vector3& sa, const Vector3& dir, const Plane p[], int numPlanes, - float& tfirst, float& tlast, int& iFirstPlane, int& iLastPlane) -{ - // Compute direction vector for the segment - Vector3 d = /*b - a*/ dir; - // Set initial interval to being the whole segment. For a ray, tlast should be - // set to +RR_FLT_MAX. For a line, additionally tfirst should be set to -RR_FLT_MAX - tfirst = 0.0f; - tlast = 1.0f; - iFirstPlane = -1; - iLastPlane = -1; - // Intersect segment against each plane - for (int i = 0; i < numPlanes; i++) - { - const Vector4& plane = p[i].GetPlaneEquationCoefficients(); + if (result == RR_ISECT_RAY_CYL_PQ) + { + return ISECT_RAY_CAPSULE_PQ; + } - float denom = plane.Dot3(d); - // don't forget we store -D in the plane - float dist = (-plane.GetW()) - plane.Dot3(sa); - // Test if segment runs parallel to the plane - if (denom == 0.0f) + Vector3 dirNorm = dir; + float len = dirNorm.NormalizeWithLength(); + + // check spheres + float timeLenTop, timeLenBottom; + int resultTop = IntersectRaySphere(sa, dirNorm, p, r, timeLenTop); + if (resultTop == ISECT_RAY_SPHERE_SA_INSIDE) { - // If so, return "no intersection" if segment lies outside plane - if (dist < 0.0f) - { - return false; - } + return ISECT_RAY_CAPSULE_SA_INSIDE; } - else + int resultBottom = IntersectRaySphere(sa, dirNorm, q, r, timeLenBottom); + if (resultBottom == ISECT_RAY_SPHERE_SA_INSIDE) + { + return ISECT_RAY_CAPSULE_SA_INSIDE; + } + + if (resultTop == ISECT_RAY_SPHERE_ISECT) { - // Compute parameterized t value for intersection with current plane - float t = dist / denom; - if (denom < 0.0f) + if (resultBottom == ISECT_RAY_SPHERE_ISECT) { - // When entering half space, update tfirst if t is larger - if (t > tfirst) + // if we intersect both spheres pick the closest one + if (timeLenTop < timeLenBottom) + { + t = timeLenTop / len; + return ISECT_RAY_CAPSULE_P_SIDE; + } + else { - tfirst = t; - iFirstPlane = i; + t = timeLenBottom / len; + return ISECT_RAY_CAPSULE_Q_SIDE; } } else { - // When exiting half space, update tlast if t is smaller - if (t < tlast) + t = timeLenTop / len; + return ISECT_RAY_CAPSULE_P_SIDE; + } + } + + if (resultBottom == ISECT_RAY_SPHERE_ISECT) + { + t = timeLenBottom / len; + return ISECT_RAY_CAPSULE_Q_SIDE; + } + + return ISECT_RAY_CAPSULE_NONE; + } + + //========================================================================= + // IntersectSegmentPolyhedron + // [10/21/2009] + //========================================================================= + bool Intersect::IntersectSegmentPolyhedron( + const Vector3& sa, + const Vector3& dir, + const Plane p[], + int numPlanes, + float& tfirst, + float& tlast, + int& iFirstPlane, + int& iLastPlane) + { + // Compute direction vector for the segment + Vector3 d = /*b - a*/ dir; + // Set initial interval to being the whole segment. For a ray, tlast should be + // set to +RR_FLT_MAX. For a line, additionally tfirst should be set to -RR_FLT_MAX + tfirst = 0.0f; + tlast = 1.0f; + iFirstPlane = -1; + iLastPlane = -1; + // Intersect segment against each plane + for (int i = 0; i < numPlanes; i++) + { + const Vector4& plane = p[i].GetPlaneEquationCoefficients(); + + float denom = plane.Dot3(d); + // don't forget we store -D in the plane + float dist = (-plane.GetW()) - plane.Dot3(sa); + // Test if segment runs parallel to the plane + if (denom == 0.0f) + { + // If so, return "no intersection" if segment lies outside plane + if (dist < 0.0f) { - tlast = t; - iLastPlane = i; + return false; } } - - // Exit with "no intersection" if intersection becomes empty - if (tfirst > tlast) + else { - return false; + // Compute parameterized t value for intersection with current plane + float t = dist / denom; + if (denom < 0.0f) + { + // When entering half space, update tfirst if t is larger + if (t > tfirst) + { + tfirst = t; + iFirstPlane = i; + } + } + else + { + // When exiting half space, update tlast if t is smaller + if (t < tlast) + { + tlast = t; + iLastPlane = i; + } + } + + // Exit with "no intersection" if intersection becomes empty + if (tfirst > tlast) + { + return false; + } } } - } - - //DBG_Assert(iFirstPlane!=-1&&iLastPlane!=-1,("We have some bad border case to have only one plane, fix this function!")); - if (iFirstPlane == -1 && iLastPlane == -1) - { - return false; - } - // A nonzero logical intersection, so the segment intersects the polyhedron - return true; -} + // DBG_Assert(iFirstPlane!=-1&&iLastPlane!=-1,("We have some bad border case to have only one plane, fix this function!")); + if (iFirstPlane == -1 && iLastPlane == -1) + { + return false; + } -//========================================================================= -// ClosestSegmentSegment -// [10/21/2009] -//========================================================================= -void -AZ::Intersect::ClosestSegmentSegment( - const Vector3& segment1Start, const Vector3& segment1End, - const Vector3& segment2Start, const Vector3& segment2End, - float& segment1Proportion, float& segment2Proportion, - Vector3& closestPointSegment1, Vector3& closestPointSegment2, - float epsilon) -{ - const Vector3 segment1 = segment1End - segment1Start; - const Vector3 segment2 = segment2End - segment2Start; - const Vector3 segmentStartsVector = segment1Start - segment2Start; - const float segment1LengthSquared = segment1.Dot(segment1); - const float segment2LengthSquared = segment2.Dot(segment2); - - // Check if both segments degenerate into points - if (segment1LengthSquared <= epsilon && segment2LengthSquared <= epsilon) - { - segment1Proportion = 0.0f; - segment2Proportion = 0.0f; - closestPointSegment1 = segment1Start; - closestPointSegment2 = segment2Start; - return; + // A nonzero logical intersection, so the segment intersects the polyhedron + return true; } - float projSegment2SegmentStarts = segment2.Dot(segmentStartsVector); - - // Check if segment 1 degenerates into a point - if (segment1LengthSquared <= epsilon) - { - segment1Proportion = 0.0f; - segment2Proportion = AZ::GetClamp(projSegment2SegmentStarts / segment2LengthSquared, 0.0f, 1.0f); - } - else + //========================================================================= + // ClosestSegmentSegment + // [10/21/2009] + //========================================================================= + void Intersect::ClosestSegmentSegment( + const Vector3& segment1Start, + const Vector3& segment1End, + const Vector3& segment2Start, + const Vector3& segment2End, + float& segment1Proportion, + float& segment2Proportion, + Vector3& closestPointSegment1, + Vector3& closestPointSegment2, + float epsilon) { - float projSegment1SegmentStarts = segment1.Dot(segmentStartsVector); - // Check if segment 2 degenerates into a point - if (segment2LengthSquared <= epsilon) + const Vector3 segment1 = segment1End - segment1Start; + const Vector3 segment2 = segment2End - segment2Start; + const Vector3 segmentStartsVector = segment1Start - segment2Start; + const float segment1LengthSquared = segment1.Dot(segment1); + const float segment2LengthSquared = segment2.Dot(segment2); + + // Check if both segments degenerate into points + if (segment1LengthSquared <= epsilon && segment2LengthSquared <= epsilon) { - segment1Proportion = AZ::GetClamp(-projSegment1SegmentStarts / segment1LengthSquared, 0.0f, 1.0f); + segment1Proportion = 0.0f; segment2Proportion = 0.0f; + closestPointSegment1 = segment1Start; + closestPointSegment2 = segment2Start; + return; + } + + float projSegment2SegmentStarts = segment2.Dot(segmentStartsVector); + + // Check if segment 1 degenerates into a point + if (segment1LengthSquared <= epsilon) + { + segment1Proportion = 0.0f; + segment2Proportion = AZ::GetClamp(projSegment2SegmentStarts / segment2LengthSquared, 0.0f, 1.0f); } else { - // The general non-degenerate case starts here - float projSegment1Segment2 = segment1.Dot(segment2); - float denom = segment1LengthSquared * segment2LengthSquared - projSegment1Segment2 * projSegment1Segment2; // Always nonnegative - - // If segments not parallel, compute closest point on segment1 to segment2, and - // clamp to segment1. Else pick arbitrary segment1Proportion (here 0) - if (denom != 0.0f) + float projSegment1SegmentStarts = segment1.Dot(segmentStartsVector); + // Check if segment 2 degenerates into a point + if (segment2LengthSquared <= epsilon) { - segment1Proportion = AZ::GetClamp((projSegment1Segment2 * projSegment2SegmentStarts - projSegment1SegmentStarts * segment2LengthSquared) / denom, 0.0f, 1.0f); + segment1Proportion = AZ::GetClamp(-projSegment1SegmentStarts / segment1LengthSquared, 0.0f, 1.0f); + segment2Proportion = 0.0f; } else { - segment1Proportion = 0.0f; - } + // The general non-degenerate case starts here + float projSegment1Segment2 = segment1.Dot(segment2); + float denom = + segment1LengthSquared * segment2LengthSquared - projSegment1Segment2 * projSegment1Segment2; // Always nonnegative - // Compute point on segment2 closest to segment1 using - segment2Proportion = (projSegment1Segment2 * segment1Proportion + projSegment2SegmentStarts) / segment2LengthSquared; + // If segments not parallel, compute closest point on segment1 to segment2, and + // clamp to segment1. Else pick arbitrary segment1Proportion (here 0) + if (denom != 0.0f) + { + segment1Proportion = AZ::GetClamp( + (projSegment1Segment2 * projSegment2SegmentStarts - projSegment1SegmentStarts * segment2LengthSquared) / denom, + 0.0f, 1.0f); + } + else + { + segment1Proportion = 0.0f; + } - // If segment2Proportion in [0,1] done. Else clamp segment2Proportion, recompute segment1Proportion for the new value of segment2Proportion - // and clamp segment1Proportion to [0, 1] - if (segment2Proportion < 0.0f) - { - segment2Proportion = 0.0f; - segment1Proportion = AZ::GetClamp(-projSegment1SegmentStarts / segment1LengthSquared, 0.0f, 1.0f); - } - else if (segment2Proportion > 1.0f) - { - segment2Proportion = 1.0f; - segment1Proportion = AZ::GetClamp((projSegment1Segment2 - projSegment1SegmentStarts) / segment1LengthSquared, 0.0f, 1.0f); + // Compute point on segment2 closest to segment1 using + segment2Proportion = (projSegment1Segment2 * segment1Proportion + projSegment2SegmentStarts) / segment2LengthSquared; + + // If segment2Proportion in [0,1] done. Else clamp segment2Proportion, recompute segment1Proportion for the new value of + // segment2Proportion and clamp segment1Proportion to [0, 1] + if (segment2Proportion < 0.0f) + { + segment2Proportion = 0.0f; + segment1Proportion = AZ::GetClamp(-projSegment1SegmentStarts / segment1LengthSquared, 0.0f, 1.0f); + } + else if (segment2Proportion > 1.0f) + { + segment2Proportion = 1.0f; + segment1Proportion = + AZ::GetClamp((projSegment1Segment2 - projSegment1SegmentStarts) / segment1LengthSquared, 0.0f, 1.0f); + } } } - } - - closestPointSegment1 = segment1Start + segment1 * segment1Proportion; - closestPointSegment2 = segment2Start + segment2 * segment2Proportion; -} -void AZ::Intersect::ClosestSegmentSegment( - const Vector3& segment1Start, const Vector3& segment1End, - const Vector3& segment2Start, const Vector3& segment2End, - Vector3& closestPointSegment1, Vector3& closestPointSegment2, - float epsilon) -{ - float proportion1, proportion2; - AZ::Intersect::ClosestSegmentSegment( - segment1Start, segment1End, - segment2Start, segment2End, - proportion1, proportion2, - closestPointSegment1, closestPointSegment2, epsilon); -} + closestPointSegment1 = segment1Start + segment1 * segment1Proportion; + closestPointSegment2 = segment2Start + segment2 * segment2Proportion; + } -void AZ::Intersect::ClosestPointSegment( - const Vector3& point, const Vector3& segmentStart, const Vector3& segmentEnd, - float& proportion, Vector3& closestPointOnSegment) -{ - Vector3 segment = segmentEnd - segmentStart; - // Project point onto segment, but deferring divide by segment.Dot(segment) - proportion = (point - segmentStart).Dot(segment); - if (proportion <= 0.0f) + void Intersect::ClosestSegmentSegment( + const Vector3& segment1Start, + const Vector3& segment1End, + const Vector3& segment2Start, + const Vector3& segment2End, + Vector3& closestPointSegment1, + Vector3& closestPointSegment2, + float epsilon) { - // Point projects outside the [segmentStart, segmentEnd] interval, on the segmentStart side, clamp to segmentStart - proportion = 0.0f; - closestPointOnSegment = segmentStart; + float proportion1, proportion2; + Intersect::ClosestSegmentSegment( + segment1Start, segment1End, segment2Start, segment2End, proportion1, proportion2, closestPointSegment1, closestPointSegment2, + epsilon); } - else + + void Intersect::ClosestPointSegment( + const Vector3& point, const Vector3& segmentStart, const Vector3& segmentEnd, float& proportion, Vector3& closestPointOnSegment) { - float segmentLengthSquared = segment.Dot(segment); - if (proportion >= segmentLengthSquared) + Vector3 segment = segmentEnd - segmentStart; + // Project point onto segment, but deferring divide by segment.Dot(segment) + proportion = (point - segmentStart).Dot(segment); + if (proportion <= 0.0f) { - // Point projects outside the [segmentStart, segmentEnd] interval, on the segmentEnd side, clamp to segmentEnd - proportion = 1.0f; - closestPointOnSegment = segmentEnd; + // Point projects outside the [segmentStart, segmentEnd] interval, on the segmentStart side, clamp to segmentStart + proportion = 0.0f; + closestPointOnSegment = segmentStart; } else { - // Point projects inside the [segmentStart, segmentEnd] interval, must do deferred divide now - proportion = proportion / segmentLengthSquared; - closestPointOnSegment = segmentStart + (proportion * segment); + float segmentLengthSquared = segment.Dot(segment); + if (proportion >= segmentLengthSquared) + { + // Point projects outside the [segmentStart, segmentEnd] interval, on the segmentEnd side, clamp to segmentEnd + proportion = 1.0f; + closestPointOnSegment = segmentEnd; + } + else + { + // Point projects inside the [segmentStart, segmentEnd] interval, must do deferred divide now + proportion = proportion / segmentLengthSquared; + closestPointOnSegment = segmentStart + (proportion * segment); + } } } -} #if 0 ////////////////////////////////////////////////////////////////////////// @@ -2121,3 +2171,5 @@ namespace test } ////////////////////////////////////////////////////////////////////////// #endif + +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Math/Plane.inl b/Code/Framework/AzCore/AzCore/Math/Plane.inl index f33d356312..22c449dc6f 100644 --- a/Code/Framework/AzCore/AzCore/Math/Plane.inl +++ b/Code/Framework/AzCore/AzCore/Math/Plane.inl @@ -19,6 +19,7 @@ namespace AZ AZ_MATH_INLINE Plane Plane::CreateFromNormalAndPoint(const Vector3& normal, const Vector3& point) { + AZ_MATH_ASSERT(normal.IsNormalized(), "This normal is not normalized"); return Plane(Simd::Vec4::ConstructPlane(normal.GetSimdValue(), point.GetSimdValue())); } @@ -65,18 +66,21 @@ namespace AZ AZ_MATH_INLINE void Plane::Set(const Vector3& normal, float d) { + AZ_MATH_ASSERT(normal.IsNormalized(), "This normal is not normalized"); m_plane.Set(normal, d); } AZ_MATH_INLINE void Plane::Set(float a, float b, float c, float d) { + AZ_MATH_ASSERT(Vector3(a, b, c).IsNormalized(), "This normal is not normalized"); m_plane.Set(a, b, c, d); } AZ_MATH_INLINE void Plane::SetNormal(const Vector3& normal) { + AZ_MATH_ASSERT(normal.IsNormalized(), "This normal is not normalized"); m_plane.SetX(normal.GetX()); m_plane.SetY(normal.GetY()); m_plane.SetZ(normal.GetZ()); diff --git a/Code/Framework/AzCore/AzCore/Math/Quaternion.h b/Code/Framework/AzCore/AzCore/Math/Quaternion.h index 83e8012a62..ad454aab4f 100644 --- a/Code/Framework/AzCore/AzCore/Math/Quaternion.h +++ b/Code/Framework/AzCore/AzCore/Math/Quaternion.h @@ -54,11 +54,11 @@ namespace AZ //! Sets components using a Vector3 for the imaginary part and a float for the real part. static Quaternion CreateFromVector3AndValue(const Vector3& v, float w); - //! Sets the quaternion to be a rotation around a specified axis. + //! Sets the quaternion to be a rotation around a specified axis in radians. //! @{ - static Quaternion CreateRotationX(float angle); - static Quaternion CreateRotationY(float angle); - static Quaternion CreateRotationZ(float angle); + static Quaternion CreateRotationX(float angleInRadians); + static Quaternion CreateRotationY(float angleInRadians); + static Quaternion CreateRotationZ(float angleInRadians); //! @} //! Creates a quaternion from a Matrix3x3 @@ -168,6 +168,14 @@ namespace AZ float NormalizeWithLengthEstimate(); //! @} + //! Get the shortest equivalent of the rotation. + //! In case the w component of the quaternion is negative the rotation is > 180° and taking the longer path. + //! The quaternion will be inverted in that case to take the shortest path of rotation. + //! @{ + Quaternion GetShortestEquivalent() const; + void ShortestEquivalent(); + //! @} + //! Linearly interpolate towards a destination quaternion. //! @param[in] dest The quaternion to interpolate towards. //! @param[in] t Normalized interpolation value where 0.0 represents the current and 1.0 the destination value. diff --git a/Code/Framework/AzCore/AzCore/Math/Quaternion.inl b/Code/Framework/AzCore/AzCore/Math/Quaternion.inl index 37319ae146..bd51a90fca 100644 --- a/Code/Framework/AzCore/AzCore/Math/Quaternion.inl +++ b/Code/Framework/AzCore/AzCore/Math/Quaternion.inl @@ -73,27 +73,27 @@ namespace AZ } - AZ_MATH_INLINE Quaternion Quaternion::CreateRotationX(float angle) + AZ_MATH_INLINE Quaternion Quaternion::CreateRotationX(float angleInRadians) { - const float halfAngle = 0.5f * angle; + const float halfAngle = 0.5f * angleInRadians; float sin, cos; SinCos(halfAngle, sin, cos); return Quaternion(sin, 0.0f, 0.0f, cos); } - AZ_MATH_INLINE Quaternion Quaternion::CreateRotationY(float angle) + AZ_MATH_INLINE Quaternion Quaternion::CreateRotationY(float angleInRadians) { - const float halfAngle = 0.5f * angle; + const float halfAngle = 0.5f * angleInRadians; float sin, cos; SinCos(halfAngle, sin, cos); return Quaternion(0.0f, sin, 0.0f, cos); } - AZ_MATH_INLINE Quaternion Quaternion::CreateRotationZ(float angle) + AZ_MATH_INLINE Quaternion Quaternion::CreateRotationZ(float angleInRadians) { - const float halfAngle = 0.5f * angle; + const float halfAngle = 0.5f * angleInRadians; float sin, cos; SinCos(halfAngle, sin, cos); return Quaternion(0.0f, 0.0f, sin, cos); @@ -345,6 +345,23 @@ namespace AZ } + AZ_MATH_INLINE Quaternion Quaternion::GetShortestEquivalent() const + { + if (GetW() < 0.0f) + { + return -(*this); + } + + return *this; + } + + + AZ_MATH_INLINE void Quaternion::ShortestEquivalent() + { + *this = GetShortestEquivalent(); + } + + AZ_MATH_INLINE Quaternion Quaternion::Lerp(const Quaternion& dest, float t) const { if (Dot(dest) >= 0.0f) diff --git a/Code/Framework/AzCore/AzCore/Math/Sfmt.cpp b/Code/Framework/AzCore/AzCore/Math/Sfmt.cpp index 5f4dc9e5df..96c1a6a420 100644 --- a/Code/Framework/AzCore/AzCore/Math/Sfmt.cpp +++ b/Code/Framework/AzCore/AzCore/Math/Sfmt.cpp @@ -9,39 +9,38 @@ #include #include -#include #include +#include #include // for memset namespace AZ::SfmtInternal { - static const int N32 = N * 4; - static const int N64 = N * 2; - static const int POS1 = 122; - static const int SL1 = 18; - static const int SR1 = 11; - static const int SL2 = 1; - static const int SR2 = 1; - static const unsigned int MSK1 = 0xdfffffefU; - static const unsigned int MSK2 = 0xddfecb7fU; - static const unsigned int MSK3 = 0xbffaffffU; - static const unsigned int MSK4 = 0xbffffff6U; - static const unsigned int PARITY1 = 0x00000001U; - static const unsigned int PARITY2 = 0x00000000U; - static const unsigned int PARITY3 = 0x00000000U; - static const unsigned int PARITY4 = 0x13c9e684U; + static const int N32 = N * 4; + static const int N64 = N * 2; + static const int POS1 = 122; + static const int SL1 = 18; + static const int SR1 = 11; + static const int SL2 = 1; + static const int SR2 = 1; + static const unsigned int MSK1 = 0xdfffffefU; + static const unsigned int MSK2 = 0xddfecb7fU; + static const unsigned int MSK3 = 0xbffaffffU; + static const unsigned int MSK4 = 0xbffffff6U; + static const unsigned int PARITY1 = 0x00000001U; + static const unsigned int PARITY2 = 0x00000000U; + static const unsigned int PARITY3 = 0x00000000U; + static const unsigned int PARITY4 = 0x13c9e684U; /** a parity check vector which certificate the period of 2^{MEXP} */ - static unsigned int parity[4] = {PARITY1, PARITY2, PARITY3, PARITY4}; + static unsigned int parity[4] = { PARITY1, PARITY2, PARITY3, PARITY4 }; #ifdef ONLY64 -# define idxof(_i) (_i ^ 1) +#define idxof(_i) (_i ^ 1) #else -# define idxof(_i) _i +#define idxof(_i) _i #endif // ONLY64 - #if AZ_TRAIT_USE_PLATFORM_SIMD_SSE /** * This function represents the recursion formula. @@ -52,7 +51,8 @@ namespace AZ::SfmtInternal * @param mask 128-bit mask * @return output */ - AZ_FORCE_INLINE static Simd::Vec4::Int32Type simd_recursion(Simd::Vec4::Int32Type* a, Simd::Vec4::Int32Type* b, Simd::Vec4::Int32Type c, Simd::Vec4::Int32Type d, Simd::Vec4::Int32Type mask) + AZ_FORCE_INLINE static Simd::Vec4::Int32Type simd_recursion( + Simd::Vec4::Int32Type* a, Simd::Vec4::Int32Type* b, Simd::Vec4::Int32Type c, Simd::Vec4::Int32Type d, Simd::Vec4::Int32Type mask) { Simd::Vec4::Int32Type v, x, y, z; x = *a; @@ -151,7 +151,7 @@ namespace AZ::SfmtInternal inline void rshift128(w128_t* out, w128_t const* in, int shift) { AZ::u64 th, tl, oh, ol; - #ifdef ONLY64 +#ifdef ONLY64 th = ((AZ::u64)in->u[2] << 32) | ((AZ::u64)in->u[3]); tl = ((AZ::u64)in->u[0] << 32) | ((AZ::u64)in->u[1]); @@ -204,7 +204,7 @@ namespace AZ::SfmtInternal #endif } - inline void do_recursion(w128_t* r, w128_t* a, w128_t* b, w128_t* c, w128_t* d) + inline void do_recursion(w128_t* r, w128_t* a, w128_t* b, w128_t* c, w128_t* d) { w128_t x; w128_t y; @@ -229,7 +229,7 @@ namespace AZ::SfmtInternal inline void gen_rand_all(Sfmt& g) { int i; - w128_t* r1, * r2; + w128_t *r1, *r2; r1 = &g.m_sfmt[N - 2]; r2 = &g.m_sfmt[N - 1]; @@ -257,7 +257,7 @@ namespace AZ::SfmtInternal inline void gen_rand_array(Sfmt& g, w128_t* array, int size) { int i, j; - w128_t* r1, * r2; + w128_t *r1, *r2; r1 = &g.m_sfmt[N - 2]; r2 = &g.m_sfmt[N - 1]; @@ -295,82 +295,80 @@ namespace AZ::SfmtInternal #endif } // namespace AZ::SfmtInternal -using namespace AZ; - ////////////////////////////////////////////////////////////////////////// // Statics ////////////////////////////////////////////////////////////////////////// +namespace AZ +{ + static EnvironmentVariable s_sfmt; + static const char* s_globalSfmtName = "GlobalSfmt"; -static EnvironmentVariable s_sfmt; -static const char* s_globalSfmtName = "GlobalSfmt"; + Sfmt& Sfmt::GetInstance() + { + if (!s_sfmt) + { + s_sfmt = AZ::Environment::FindVariable(s_globalSfmtName); + if (!s_sfmt) + { + Sfmt::Create(); + } + } -Sfmt& Sfmt::GetInstance() -{ - if (!s_sfmt) + return s_sfmt.Get(); + } + + void Sfmt::Create() { - s_sfmt = AZ::Environment::FindVariable(s_globalSfmtName); if (!s_sfmt) { - Sfmt::Create(); + s_sfmt = AZ::Environment::CreateVariable(s_globalSfmtName); } } - return s_sfmt.Get(); -} + void Sfmt::Destroy() + { + s_sfmt.Reset(); + } -void Sfmt::Create() -{ - if (!s_sfmt) + //========================================================================= + // Sfmt + // [4/10/2012] + //========================================================================= + Sfmt::Sfmt() { - s_sfmt = AZ::Environment::CreateVariable(s_globalSfmtName); + m_psfmt32 = &m_sfmt[0].u[0]; + m_psfmt64 = reinterpret_cast(m_psfmt32); + + Seed(); } -} -void Sfmt::Destroy() -{ - s_sfmt.Reset(); -} - -//========================================================================= -// Sfmt -// [4/10/2012] -//========================================================================= -Sfmt::Sfmt() -{ - m_psfmt32 = &m_sfmt[0].u[0]; - m_psfmt64 = reinterpret_cast(m_psfmt32); + //========================================================================= + // Seed + // [4/10/2012] + //========================================================================= + Sfmt::Sfmt(AZ::u32* keys, int numKeys) + { + m_psfmt32 = &m_sfmt[0].u[0]; + m_psfmt64 = reinterpret_cast(m_psfmt32); - Seed(); -} + Seed(keys, numKeys); + } -//========================================================================= -// Seed -// [4/10/2012] -//========================================================================= -Sfmt::Sfmt(AZ::u32* keys, int numKeys) -{ - m_psfmt32 = &m_sfmt[0].u[0]; - m_psfmt64 = reinterpret_cast(m_psfmt32); - - Seed(keys, numKeys); -} - -//========================================================================= -// Seed -// [4/10/2012] -//========================================================================= -void -Sfmt::Seed() -{ - // buffer with random values - AZ::u32 buffer[32]; - BetterPseudoRandom rnd; - bool result = rnd.GetRandom(buffer, sizeof(buffer)); - (void)result; - AZ_Warning("System", result, "Failed to seed properly the Smft generator!"); - Seed(buffer, AZ_ARRAY_SIZE(buffer)); -} + //========================================================================= + // Seed + // [4/10/2012] + //========================================================================= + void Sfmt::Seed() + { + // buffer with random values + AZ::u32 buffer[32]; + BetterPseudoRandom rnd; + bool result = rnd.GetRandom(buffer, sizeof(buffer)); + (void)result; + AZ_Warning("System", result, "Failed to seed properly the Smft generator!"); + Seed(buffer, AZ_ARRAY_SIZE(buffer)); + } /** * This function represents a function used in the initialization @@ -388,226 +386,222 @@ Sfmt::Seed() */ #define azsfmt_func2(x) ((x ^ (x >> 27)) * (AZ::u32)1566083941UL) -//========================================================================= -// Seed -// [4/10/2012] -//========================================================================= -void -Sfmt::Seed(AZ::u32* keys, int numKeys) -{ - using SfmtInternal::N; - using SfmtInternal::N32; - int i, j, count; - AZ::u32 r; - int lag; - int mid; - int size = N * 4; - - if (size >= 623) - { - lag = 11; - } - else if (size >= 68) - { - lag = 7; - } - else if (size >= 39) - { - lag = 5; - } - else + //========================================================================= + // Seed + // [4/10/2012] + //========================================================================= + void Sfmt::Seed(AZ::u32* keys, int numKeys) { - lag = 3; - } - mid = (size - lag) / 2; + using SfmtInternal::N; + using SfmtInternal::N32; + int i, j, count; + AZ::u32 r; + int lag; + int mid; + int size = N * 4; + + if (size >= 623) + { + lag = 11; + } + else if (size >= 68) + { + lag = 7; + } + else if (size >= 39) + { + lag = 5; + } + else + { + lag = 3; + } + mid = (size - lag) / 2; - memset(m_sfmt, 0x8b, sizeof(m_sfmt)); - if (numKeys + 1 > SfmtInternal::N32) - { - count = numKeys + 1; - } - else - { - count = N32; - } - r = azsfmt_func1((m_psfmt32[idxof(0)] ^ m_psfmt32[idxof(mid)] ^ m_psfmt32[idxof(N32 - 1)])); - m_psfmt32[idxof(mid)] += r; - r += numKeys; - m_psfmt32[idxof(mid + lag)] += r; - m_psfmt32[idxof(0)] = r; - - count--; - for (i = 1, j = 0; (j < count) && (j < numKeys); j++) - { - r = azsfmt_func1((m_psfmt32[idxof(i)] ^ m_psfmt32[idxof((i + mid) % N32)] ^ m_psfmt32[idxof((i + N32 - 1) % N32)])); - m_psfmt32[idxof((i + mid) % N32)] += r; - r += keys[j] + i; - m_psfmt32[idxof((i + mid + lag) % N32)] += r; - m_psfmt32[idxof(i)] = r; - i = (i + 1) % N32; - } - for (; j < count; j++) - { - r = azsfmt_func1((m_psfmt32[idxof(i)] ^ m_psfmt32[idxof((i + mid) % N32)] ^ m_psfmt32[idxof((i + N32 - 1) % N32)])); - m_psfmt32[idxof((i + mid) % N32)] += r; - r += i; - m_psfmt32[idxof((i + mid + lag) % N32)] += r; - m_psfmt32[idxof(i)] = r; - i = (i + 1) % N32; - } - for (j = 0; j < N32; j++) - { - r = azsfmt_func2((m_psfmt32[idxof(i)] + m_psfmt32[idxof((i + mid) % N32)] + m_psfmt32[idxof((i + N32 - 1) % N32)])); - m_psfmt32[idxof((i + mid) % N32)] ^= r; - r -= i; - m_psfmt32[idxof((i + mid + lag) % N32)] ^= r; - m_psfmt32[idxof(i)] = r; - i = (i + 1) % N32; - } + memset(m_sfmt, 0x8b, sizeof(m_sfmt)); + if (numKeys + 1 > SfmtInternal::N32) + { + count = numKeys + 1; + } + else + { + count = N32; + } + r = azsfmt_func1((m_psfmt32[idxof(0)] ^ m_psfmt32[idxof(mid)] ^ m_psfmt32[idxof(N32 - 1)])); + m_psfmt32[idxof(mid)] += r; + r += numKeys; + m_psfmt32[idxof(mid + lag)] += r; + m_psfmt32[idxof(0)] = r; + + count--; + for (i = 1, j = 0; (j < count) && (j < numKeys); j++) + { + r = azsfmt_func1((m_psfmt32[idxof(i)] ^ m_psfmt32[idxof((i + mid) % N32)] ^ m_psfmt32[idxof((i + N32 - 1) % N32)])); + m_psfmt32[idxof((i + mid) % N32)] += r; + r += keys[j] + i; + m_psfmt32[idxof((i + mid + lag) % N32)] += r; + m_psfmt32[idxof(i)] = r; + i = (i + 1) % N32; + } + for (; j < count; j++) + { + r = azsfmt_func1((m_psfmt32[idxof(i)] ^ m_psfmt32[idxof((i + mid) % N32)] ^ m_psfmt32[idxof((i + N32 - 1) % N32)])); + m_psfmt32[idxof((i + mid) % N32)] += r; + r += i; + m_psfmt32[idxof((i + mid + lag) % N32)] += r; + m_psfmt32[idxof(i)] = r; + i = (i + 1) % N32; + } + for (j = 0; j < N32; j++) + { + r = azsfmt_func2((m_psfmt32[idxof(i)] + m_psfmt32[idxof((i + mid) % N32)] + m_psfmt32[idxof((i + N32 - 1) % N32)])); + m_psfmt32[idxof((i + mid) % N32)] ^= r; + r -= i; + m_psfmt32[idxof((i + mid + lag) % N32)] ^= r; + m_psfmt32[idxof(i)] = r; + i = (i + 1) % N32; + } - m_index = N32; - PeriodCertification(); -} + m_index = N32; + PeriodCertification(); + } #undef azsfmt_func1 #undef azsfmt_func2 -//========================================================================= -// PeriodCertification -// [4/10/2012] -//========================================================================= -void -Sfmt::PeriodCertification() -{ - int inner = 0; - int i, j; - AZ::u32 work; - - for (i = 0; i < 4; i++) + //========================================================================= + // PeriodCertification + // [4/10/2012] + //========================================================================= + void Sfmt::PeriodCertification() { - inner ^= m_psfmt32[idxof(i)] & SfmtInternal::parity[i]; - } - for (i = 16; i > 0; i >>= 1) - { - inner ^= inner >> i; - } - inner &= 1; - /* check OK */ - if (inner == 1) - { - return; - } - /* check NG, and modification */ - for (i = 0; i < 4; i++) - { - work = 1; - for (j = 0; j < 32; j++) + int inner = 0; + int i, j; + AZ::u32 work; + + for (i = 0; i < 4; i++) + { + inner ^= m_psfmt32[idxof(i)] & SfmtInternal::parity[i]; + } + for (i = 16; i > 0; i >>= 1) + { + inner ^= inner >> i; + } + inner &= 1; + /* check OK */ + if (inner == 1) + { + return; + } + /* check NG, and modification */ + for (i = 0; i < 4; i++) { - if ((work & SfmtInternal::parity[i]) != 0) + work = 1; + for (j = 0; j < 32; j++) { - m_psfmt32[idxof(i)] ^= work; - return; + if ((work & SfmtInternal::parity[i]) != 0) + { + m_psfmt32[idxof(i)] ^= work; + return; + } + work = work << 1; } - work = work << 1; } } -} -//========================================================================= -// Rand32 -// [4/10/2012] -//========================================================================= -AZ::u32 Sfmt::Rand32() -{ - int index = m_index.fetch_add(1); - if (index >= SfmtInternal::N32) + //========================================================================= + // Rand32 + // [4/10/2012] + //========================================================================= + AZ::u32 Sfmt::Rand32() { - AZStd::lock_guard lock(m_generationMutex); - // if this thread is the one that sets m_index to 0, then this thread - // does the generation - index += 1; // compare against the result of fetch_add(1) above - if (m_index.compare_exchange_strong(index, 0)) + int index = m_index.fetch_add(1); + if (index >= SfmtInternal::N32) { - SfmtInternal::gen_rand_all(*this); + AZStd::lock_guard lock(m_generationMutex); + // if this thread is the one that sets m_index to 0, then this thread + // does the generation + index += 1; // compare against the result of fetch_add(1) above + if (m_index.compare_exchange_strong(index, 0)) + { + SfmtInternal::gen_rand_all(*this); + } + // try again, with the new table + return Rand32(); } - // try again, with the new table - return Rand32(); + return m_psfmt32[index]; } - return m_psfmt32[index]; -} - -//========================================================================= -// Rand64 -// [4/10/2012] -//========================================================================= -AZ::u64 Sfmt::Rand64() -{ - int index = m_index.fetch_add(2); - if (index >= (SfmtInternal::N32 - 1)) + + //========================================================================= + // Rand64 + // [4/10/2012] + //========================================================================= + AZ::u64 Sfmt::Rand64() { - AZStd::lock_guard lock(m_generationMutex); - // if this thread is the one that sets m_index to 0, then this thread - // does the generation - index += 2; // compare against the result of fetch_add(2) above - if (m_index.compare_exchange_strong(index, 0)) + int index = m_index.fetch_add(2); + if (index >= (SfmtInternal::N32 - 1)) { - SfmtInternal::gen_rand_all(*this); + AZStd::lock_guard lock(m_generationMutex); + // if this thread is the one that sets m_index to 0, then this thread + // does the generation + index += 2; // compare against the result of fetch_add(2) above + if (m_index.compare_exchange_strong(index, 0)) + { + SfmtInternal::gen_rand_all(*this); + } + // try again, with the new table + return Rand64(); } - // try again, with the new table - return Rand64(); + + AZ::u64 r; + r = m_psfmt64[index / 2]; + return r; } - AZ::u64 r; - r = m_psfmt64[index / 2]; - return r; -} - -//========================================================================= -// FillArray32 -// [4/10/2012] -//========================================================================= -void -Sfmt::FillArray32(AZ::u32* array, int size) -{ - AZ_MATH_ASSERT(m_index == SfmtInternal::N32, "Invalid m_index! Reinitialize!"); - AZ_MATH_ASSERT(size % 4 == 0, "Size must be multiple of 4!"); - AZ_MATH_ASSERT(size >= SfmtInternal::N32, "Size must be bigger than %d GetMinArray32Size()!", SfmtInternal::N32); - - SfmtInternal::gen_rand_array(*this, (SfmtInternal::w128_t*)array, size / 4); - m_index = SfmtInternal::N32; -} - -//========================================================================= -// FillArray64 -// [4/10/2012] -//========================================================================= -void -Sfmt::FillArray64(AZ::u64* array, int size) -{ - AZ_MATH_ASSERT(m_index == SfmtInternal::N32, "Invalid m_index! Reinitialize!"); - AZ_MATH_ASSERT(size % 4 == 0, "Size must be multiple of 4!"); - AZ_MATH_ASSERT(size >= SfmtInternal::N64, "Size must be bigger than %d GetMinArray64Size()!", SfmtInternal::N64); - - SfmtInternal::gen_rand_array(*this, (SfmtInternal::w128_t*)array, size / 2); - m_index = SfmtInternal::N32; -} - -//========================================================================= -// GetMinArray32Size -// [4/10/2012] -//========================================================================= -int -Sfmt::GetMinArray32Size() const -{ - return SfmtInternal::N32; -} - -//========================================================================= -// GetMinArray64Size -// [4/10/2012] -//========================================================================= -int -Sfmt::GetMinArray64Size() const -{ - return SfmtInternal::N64; -} + //========================================================================= + // FillArray32 + // [4/10/2012] + //========================================================================= + void Sfmt::FillArray32(AZ::u32* array, int size) + { + AZ_MATH_ASSERT(m_index == SfmtInternal::N32, "Invalid m_index! Reinitialize!"); + AZ_MATH_ASSERT(size % 4 == 0, "Size must be multiple of 4!"); + AZ_MATH_ASSERT(size >= SfmtInternal::N32, "Size must be bigger than %d GetMinArray32Size()!", SfmtInternal::N32); + + SfmtInternal::gen_rand_array(*this, (SfmtInternal::w128_t*)array, size / 4); + m_index = SfmtInternal::N32; + } + + //========================================================================= + // FillArray64 + // [4/10/2012] + //========================================================================= + void Sfmt::FillArray64(AZ::u64* array, int size) + { + AZ_MATH_ASSERT(m_index == SfmtInternal::N32, "Invalid m_index! Reinitialize!"); + AZ_MATH_ASSERT(size % 4 == 0, "Size must be multiple of 4!"); + AZ_MATH_ASSERT(size >= SfmtInternal::N64, "Size must be bigger than %d GetMinArray64Size()!", SfmtInternal::N64); + + SfmtInternal::gen_rand_array(*this, (SfmtInternal::w128_t*)array, size / 2); + m_index = SfmtInternal::N32; + } + + //========================================================================= + // GetMinArray32Size + // [4/10/2012] + //========================================================================= + int Sfmt::GetMinArray32Size() const + { + return SfmtInternal::N32; + } + + //========================================================================= + // GetMinArray64Size + // [4/10/2012] + //========================================================================= + int Sfmt::GetMinArray64Size() const + { + return SfmtInternal::N64; + } + +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Memory/AllocationRecords.cpp b/Code/Framework/AzCore/AzCore/Memory/AllocationRecords.cpp index 680d93501a..2b2f752b06 100644 --- a/Code/Framework/AzCore/AzCore/Memory/AllocationRecords.cpp +++ b/Code/Framework/AzCore/AzCore/Memory/AllocationRecords.cpp @@ -16,438 +16,421 @@ #include -using namespace AZ; -using namespace AZ::Debug; - -// Many PC tools break with alloc/free size mismatches when the memory guard is enabled. Disable for now -//#define ENABLE_MEMORY_GUARD - -//========================================================================= -// AllocationRecords -// [9/16/2009] -//========================================================================= -AllocationRecords::AllocationRecords(unsigned char stackRecordLevels, [[maybe_unused]] bool isMemoryGuard, bool isMarkUnallocatedMemory, const char* allocatorName) - : m_mode(AllocatorManager::Instance().m_defaultTrackingRecordMode) - , m_isAutoIntegrityCheck(false) - , m_isMarkUnallocatedMemory(isMarkUnallocatedMemory) - , m_saveNames(false) - , m_decodeImmediately(false) - , m_numStackLevels(stackRecordLevels) +namespace AZ::Debug +{ + // Many PC tools break with alloc/free size mismatches when the memory guard is enabled. Disable for now + //#define ENABLE_MEMORY_GUARD + + //========================================================================= + // AllocationRecords + // [9/16/2009] + //========================================================================= + AllocationRecords::AllocationRecords( + unsigned char stackRecordLevels, [[maybe_unused]] bool isMemoryGuard, bool isMarkUnallocatedMemory, const char* allocatorName) + : m_mode(AllocatorManager::Instance().m_defaultTrackingRecordMode) + , m_isAutoIntegrityCheck(false) + , m_isMarkUnallocatedMemory(isMarkUnallocatedMemory) + , m_saveNames(false) + , m_decodeImmediately(false) + , m_numStackLevels(stackRecordLevels) #if defined(ENABLE_MEMORY_GUARD) - , m_memoryGuardSize(isMemoryGuard ? sizeof(Debug::GuardValue) : 0) + , m_memoryGuardSize(isMemoryGuard ? sizeof(Debug::GuardValue) : 0) #else - , m_memoryGuardSize(0) + , m_memoryGuardSize(0) #endif - , m_requestedAllocs(0) - , m_requestedBytes(0) - , m_requestedBytesPeak(0) - , m_allocatorName(allocatorName) -{ - -} - -//========================================================================= -// ~AllocationRecords -// [9/16/2009] -//========================================================================= -AllocationRecords::~AllocationRecords() -{ - if (!AllocatorManager::Instance().m_isAllocatorLeaking) - { - // dump all allocation (we should not have any at this point). - bool includeNameAndFilename = (m_saveNames || m_mode == RECORD_FULL); - EnumerateAllocations(PrintAllocationsCB(true, includeNameAndFilename)); - AZ_Error("Memory", m_records.empty(), "We still have %d allocations on record! They must be freed prior to destroy!", m_records.size()); - } -} - -//========================================================================= -// lock -// [9/16/2009] -//========================================================================= -void -AllocationRecords::lock() -{ - m_recordsMutex.lock(); -} - -//========================================================================= -// try_lock -// [9/16/2009] -//========================================================================= -bool AllocationRecords::try_lock() -{ - return m_recordsMutex.try_lock(); -} - -//========================================================================= -// unlock -// [9/16/2009] -//========================================================================= -void -AllocationRecords::unlock() -{ - m_recordsMutex.unlock(); -} - -//========================================================================= -// RegisterAllocation -// [9/11/2009] -//========================================================================= -const AllocationInfo* -AllocationRecords::RegisterAllocation(void* address, size_t byteSize, size_t alignment, const char* name, const char* fileName, int lineNum, unsigned int stackSuppressCount) -{ - (void)stackSuppressCount; - if (m_mode == RECORD_NO_RECORDS) + , m_requestedAllocs(0) + , m_requestedBytes(0) + , m_requestedBytesPeak(0) + , m_allocatorName(allocatorName) { - return nullptr; - } - if (address == nullptr) - { - return nullptr; } - // memory guard - if (m_memoryGuardSize == sizeof(Debug::GuardValue)) + //========================================================================= + // ~AllocationRecords + // [9/16/2009] + //========================================================================= + AllocationRecords::~AllocationRecords() { - if (m_isAutoIntegrityCheck) + if (!AllocatorManager::Instance().m_isAllocatorLeaking) { - IntegrityCheck(); + // dump all allocation (we should not have any at this point). + bool includeNameAndFilename = (m_saveNames || m_mode == RECORD_FULL); + EnumerateAllocations(PrintAllocationsCB(true, includeNameAndFilename)); + AZ_Error( + "Memory", m_records.empty(), "We still have %d allocations on record! They must be freed prior to destroy!", + m_records.size()); } - - AZ_Assert(byteSize>sizeof(Debug::GuardValue), "Did you forget to add the extra MemoryGuardSize() bytes?"); - byteSize -= sizeof(Debug::GuardValue); - new(reinterpret_cast(address)+byteSize) Debug::GuardValue(); } - Debug::AllocationRecordsType::pair_iter_bool iterBool; + //========================================================================= + // lock + // [9/16/2009] + //========================================================================= + void AllocationRecords::lock() { - AZStd::scoped_lock lock(m_recordsMutex); - iterBool = m_records.insert_key(address); - } - - if (!iterBool.second) - { - // If that memory address was already registered, print the stack trace of the previous registration - PrintAllocationsCB(true, (m_saveNames || m_mode == RECORD_FULL))(address, iterBool.first->second, m_numStackLevels); - AZ_Assert(iterBool.second, "Memory address 0x%p is already allocated and in the records!", address); + m_recordsMutex.lock(); } - Debug::AllocationInfo& ai = iterBool.first->second; - ai.m_byteSize = byteSize; - ai.m_alignment = static_cast(alignment); - if ((m_saveNames || m_mode == RECORD_FULL) && name && fileName) + //========================================================================= + // try_lock + // [9/16/2009] + //========================================================================= + bool AllocationRecords::try_lock() { - // In RECORD_FULL mode or when specifically enabled in app descriptor with - // m_allocationRecordsSaveNames, we allocate our own memory to save off name and fileName. - // When testing for memory leaks, on process shutdown AllocationRecords::~AllocationRecords - // gets called to enumerate the remaining (leaked) allocations. Unfortunately, any names - // referenced in dynamic module memory whose modules are unloaded won't be valid - // references anymore and we won't get useful information from the enumeration print. - // This code block ensures we keep our name/fileName valid for when we need it. - const size_t nameLength = strlen(name); - const size_t fileNameLength = strlen(fileName); - const size_t totalLength = nameLength + fileNameLength + 2; // + 2 for terminating null characters - ai.m_namesBlock = m_records.get_allocator().allocate(totalLength, 1); - ai.m_namesBlockSize = totalLength; - char* savedName = reinterpret_cast(ai.m_namesBlock); - char* savedFileName = savedName + nameLength + 1; - memcpy(reinterpret_cast(savedName), reinterpret_cast(name), nameLength + 1); - memcpy(reinterpret_cast(savedFileName), reinterpret_cast(fileName), fileNameLength + 1); - ai.m_name = savedName; - ai.m_fileName = savedFileName; + return m_recordsMutex.try_lock(); } - else + + //========================================================================= + // unlock + // [9/16/2009] + //========================================================================= + void AllocationRecords::unlock() { - ai.m_name = name; - ai.m_fileName = fileName; - ai.m_namesBlock = nullptr; - ai.m_namesBlockSize = 0; + m_recordsMutex.unlock(); } - ai.m_lineNum = lineNum; - ai.m_timeStamp = AZStd::GetTimeNowMicroSecond(); - // if we don't have a fileName,lineNum record the stack or if the user requested it. - if ((fileName == nullptr && m_mode == RECORD_STACK_IF_NO_FILE_LINE) || m_mode == RECORD_FULL) + //========================================================================= + // RegisterAllocation + // [9/11/2009] + //========================================================================= + const AllocationInfo* AllocationRecords::RegisterAllocation( + void* address, + size_t byteSize, + size_t alignment, + const char* name, + const char* fileName, + int lineNum, + unsigned int stackSuppressCount) { - ai.m_stackFrames = m_numStackLevels ? reinterpret_cast(m_records.get_allocator().allocate(sizeof(AZ::Debug::StackFrame)*m_numStackLevels, 1)) : nullptr; - if (ai.m_stackFrames) + (void)stackSuppressCount; + if (m_mode == RECORD_NO_RECORDS) + { + return nullptr; + } + if (address == nullptr) + { + return nullptr; + } + + // memory guard + if (m_memoryGuardSize == sizeof(Debug::GuardValue)) + { + if (m_isAutoIntegrityCheck) + { + IntegrityCheck(); + } + + AZ_Assert(byteSize > sizeof(Debug::GuardValue), "Did you forget to add the extra MemoryGuardSize() bytes?"); + byteSize -= sizeof(Debug::GuardValue); + new (reinterpret_cast(address) + byteSize) Debug::GuardValue(); + } + + Debug::AllocationRecordsType::pair_iter_bool iterBool; + { + AZStd::scoped_lock lock(m_recordsMutex); + iterBool = m_records.insert_key(address); + } + + if (!iterBool.second) + { + // If that memory address was already registered, print the stack trace of the previous registration + PrintAllocationsCB(true, (m_saveNames || m_mode == RECORD_FULL))(address, iterBool.first->second, m_numStackLevels); + AZ_Assert(iterBool.second, "Memory address 0x%p is already allocated and in the records!", address); + } + + Debug::AllocationInfo& ai = iterBool.first->second; + ai.m_byteSize = byteSize; + ai.m_alignment = static_cast(alignment); + if ((m_saveNames || m_mode == RECORD_FULL) && name && fileName) + { + // In RECORD_FULL mode or when specifically enabled in app descriptor with + // m_allocationRecordsSaveNames, we allocate our own memory to save off name and fileName. + // When testing for memory leaks, on process shutdown AllocationRecords::~AllocationRecords + // gets called to enumerate the remaining (leaked) allocations. Unfortunately, any names + // referenced in dynamic module memory whose modules are unloaded won't be valid + // references anymore and we won't get useful information from the enumeration print. + // This code block ensures we keep our name/fileName valid for when we need it. + const size_t nameLength = strlen(name); + const size_t fileNameLength = strlen(fileName); + const size_t totalLength = nameLength + fileNameLength + 2; // + 2 for terminating null characters + ai.m_namesBlock = m_records.get_allocator().allocate(totalLength, 1); + ai.m_namesBlockSize = totalLength; + char* savedName = reinterpret_cast(ai.m_namesBlock); + char* savedFileName = savedName + nameLength + 1; + memcpy(reinterpret_cast(savedName), reinterpret_cast(name), nameLength + 1); + memcpy(reinterpret_cast(savedFileName), reinterpret_cast(fileName), fileNameLength + 1); + ai.m_name = savedName; + ai.m_fileName = savedFileName; + } + else { - Debug::StackRecorder::Record(ai.m_stackFrames, m_numStackLevels, stackSuppressCount + 1); + ai.m_name = name; + ai.m_fileName = fileName; + ai.m_namesBlock = nullptr; + ai.m_namesBlockSize = 0; + } + ai.m_lineNum = lineNum; + ai.m_timeStamp = AZStd::GetTimeNowMicroSecond(); - if (m_decodeImmediately) + // if we don't have a fileName,lineNum record the stack or if the user requested it. + if ((fileName == nullptr && m_mode == RECORD_STACK_IF_NO_FILE_LINE) || m_mode == RECORD_FULL) + { + ai.m_stackFrames = m_numStackLevels ? reinterpret_cast(m_records.get_allocator().allocate( + sizeof(AZ::Debug::StackFrame) * m_numStackLevels, 1)) + : nullptr; + if (ai.m_stackFrames) { - // OPTIONAL DEBUGGING CODE - enable in app descriptor m_allocationRecordsAttemptDecodeImmediately - // This is optionally-enabled code for tracking down memory allocations - // that fail to be decoded. DecodeFrames() typically runs at the end of - // your application when leaks were found. Sometimes you have stack prints - // full of "(module-name not available)" and "(function-name not available)" - // that are not actionable. If you have those, enable this code. It'll slow - // down your process significantly because for every allocation recorded - // we get the stack trace on the spot. Put a breakpoint in DecodeFrames() - // at the "(module-name not available)" and "(function-name not available)" - // locations and now at the moment those allocations happen you'll have the - // full stack trace available and the ability to debug what could be causing it + Debug::StackRecorder::Record(ai.m_stackFrames, m_numStackLevels, stackSuppressCount + 1); + + if (m_decodeImmediately) { - const unsigned char decodeStep = 40; - Debug::SymbolStorage::StackLine lines[decodeStep]; - unsigned char iFrame = 0; - unsigned char numStackLevels = m_numStackLevels; - while (numStackLevels > 0) + // OPTIONAL DEBUGGING CODE - enable in app descriptor m_allocationRecordsAttemptDecodeImmediately + // This is optionally-enabled code for tracking down memory allocations + // that fail to be decoded. DecodeFrames() typically runs at the end of + // your application when leaks were found. Sometimes you have stack prints + // full of "(module-name not available)" and "(function-name not available)" + // that are not actionable. If you have those, enable this code. It'll slow + // down your process significantly because for every allocation recorded + // we get the stack trace on the spot. Put a breakpoint in DecodeFrames() + // at the "(module-name not available)" and "(function-name not available)" + // locations and now at the moment those allocations happen you'll have the + // full stack trace available and the ability to debug what could be causing it { - unsigned char numToDecode = AZStd::GetMin(decodeStep, numStackLevels); - Debug::SymbolStorage::DecodeFrames(&ai.m_stackFrames[iFrame], numToDecode, lines); - numStackLevels -= numToDecode; - iFrame += numToDecode; + const unsigned char decodeStep = 40; + Debug::SymbolStorage::StackLine lines[decodeStep]; + unsigned char iFrame = 0; + unsigned char numStackLevels = m_numStackLevels; + while (numStackLevels > 0) + { + unsigned char numToDecode = AZStd::GetMin(decodeStep, numStackLevels); + Debug::SymbolStorage::DecodeFrames(&ai.m_stackFrames[iFrame], numToDecode, lines); + numStackLevels -= numToDecode; + iFrame += numToDecode; + } } } } } - } - - AllocatorManager::Instance().DebugBreak(address, ai); - // statistics - m_requestedBytes += byteSize; + AllocatorManager::Instance().DebugBreak(address, ai); - size_t currentRequestedBytePeak; - size_t newRequestedBytePeak; - do - { - currentRequestedBytePeak = m_requestedBytesPeak.load(std::memory_order::memory_order_relaxed); - newRequestedBytePeak = AZStd::GetMax(currentRequestedBytePeak, m_requestedBytes.load(std::memory_order::memory_order_relaxed)); - } while (!m_requestedBytesPeak.compare_exchange_weak(currentRequestedBytePeak, newRequestedBytePeak)); + // statistics + m_requestedBytes += byteSize; - ++m_requestedAllocs; + size_t currentRequestedBytePeak; + size_t newRequestedBytePeak; + do + { + currentRequestedBytePeak = m_requestedBytesPeak.load(std::memory_order::memory_order_relaxed); + newRequestedBytePeak = AZStd::GetMax(currentRequestedBytePeak, m_requestedBytes.load(std::memory_order::memory_order_relaxed)); + } while (!m_requestedBytesPeak.compare_exchange_weak(currentRequestedBytePeak, newRequestedBytePeak)); - return &ai; -} + ++m_requestedAllocs; -//========================================================================= -// UnregisterAllocation -// [9/11/2009] -//========================================================================= -void AllocationRecords::UnregisterAllocation(void* address, size_t byteSize, size_t alignment, AllocationInfo* info) -{ - if (m_mode == RECORD_NO_RECORDS) - { - return; - } - if (address == nullptr) - { - return; + return &ai; } - AllocationInfo allocationInfo; + //========================================================================= + // UnregisterAllocation + // [9/11/2009] + //========================================================================= + void AllocationRecords::UnregisterAllocation(void* address, size_t byteSize, size_t alignment, AllocationInfo* info) { - AZStd::scoped_lock lock(m_recordsMutex); - Debug::AllocationRecordsType::iterator iter = m_records.find(address); - // We cannot assert if an allocation does not exist because allocations may have been made before tracking was enabled. - // It is currently impossible to actually track all allocations that happen before a certain point - // AZ_Assert(iter!=m_records.end(), "Could not find address 0x%p in the allocator!", address); - if (iter == m_records.end()) + if (m_mode == RECORD_NO_RECORDS) + { + return; + } + if (address == nullptr) { return; } - allocationInfo = iter->second; - m_records.erase(iter); - // try to be more aggressive and keep the memory footprint low. - // \todo store the load factor at the last rehash to avoid unnecessary rehash - if (m_records.load_factor() < 0.9f) + AllocationInfo allocationInfo; { - m_records.rehash(0); + AZStd::scoped_lock lock(m_recordsMutex); + Debug::AllocationRecordsType::iterator iter = m_records.find(address); + // We cannot assert if an allocation does not exist because allocations may have been made before tracking was enabled. + // It is currently impossible to actually track all allocations that happen before a certain point + // AZ_Assert(iter!=m_records.end(), "Could not find address 0x%p in the allocator!", address); + if (iter == m_records.end()) + { + return; + } + allocationInfo = iter->second; + m_records.erase(iter); + + // try to be more aggressive and keep the memory footprint low. + // \todo store the load factor at the last rehash to avoid unnecessary rehash + if (m_records.load_factor() < 0.9f) + { + m_records.rehash(0); + } } - } - - AllocatorManager::Instance().DebugBreak(address, allocationInfo); + AllocatorManager::Instance().DebugBreak(address, allocationInfo); - (void)byteSize; - (void)alignment; - AZ_Assert(byteSize==0||byteSize==allocationInfo.m_byteSize, "Mismatched byteSize at deallocation! You supplied an invalid value!"); - AZ_Assert(alignment==0||alignment==allocationInfo.m_alignment, "Mismatched alignment at deallocation! You supplied an invalid value!"); + (void)byteSize; + (void)alignment; + AZ_Assert( + byteSize == 0 || byteSize == allocationInfo.m_byteSize, "Mismatched byteSize at deallocation! You supplied an invalid value!"); + AZ_Assert( + alignment == 0 || alignment == allocationInfo.m_alignment, + "Mismatched alignment at deallocation! You supplied an invalid value!"); + + // statistics + m_requestedBytes -= allocationInfo.m_byteSize; - // statistics - m_requestedBytes -= allocationInfo.m_byteSize; - #if defined(ENABLE_MEMORY_GUARD) - // memory guard - if (m_memoryGuardSize == sizeof(Debug::GuardValue)) - { - if (m_isAutoIntegrityCheck) - { - // full integrity check - IntegrityCheck(); - } - else + // memory guard + if (m_memoryGuardSize == sizeof(Debug::GuardValue)) { - // check current allocation - char* guardAddress = reinterpret_cast(address)+allocationInfo.m_byteSize; - Debug::GuardValue* guard = reinterpret_cast(guardAddress); - if (!guard->Validate()) + if (m_isAutoIntegrityCheck) + { + // full integrity check + IntegrityCheck(); + } + else { - AZ_Printf("Memory", "Memory stomp located at address %p, part of allocation:", guardAddress); - PrintAllocationsCB printAlloc(true); - printAlloc(address, allocationInfo, m_numStackLevels); - AZ_Assert(false, "MEMORY STOMP DETECTED!!!"); + // check current allocation + char* guardAddress = reinterpret_cast(address) + allocationInfo.m_byteSize; + Debug::GuardValue* guard = reinterpret_cast(guardAddress); + if (!guard->Validate()) + { + AZ_Printf("Memory", "Memory stomp located at address %p, part of allocation:", guardAddress); + PrintAllocationsCB printAlloc(true); + printAlloc(address, allocationInfo, m_numStackLevels); + AZ_Assert(false, "MEMORY STOMP DETECTED!!!"); + } + guard->~GuardValue(); } - guard->~GuardValue(); } - } #endif - // delete allocation record - if (allocationInfo.m_namesBlock) - { - m_records.get_allocator().deallocate(allocationInfo.m_namesBlock, allocationInfo.m_namesBlockSize, 1); - allocationInfo.m_namesBlock = nullptr; - allocationInfo.m_namesBlockSize = 0; - allocationInfo.m_name = nullptr; - allocationInfo.m_fileName = nullptr; - } - if (allocationInfo.m_stackFrames) - { - m_records.get_allocator().deallocate(allocationInfo.m_stackFrames, sizeof(AZ::Debug::StackFrame)*m_numStackLevels, 1); - allocationInfo.m_stackFrames = nullptr; - } - - if (info) - { - *info = allocationInfo; - } - + // delete allocation record + if (allocationInfo.m_namesBlock) + { + m_records.get_allocator().deallocate(allocationInfo.m_namesBlock, allocationInfo.m_namesBlockSize, 1); + allocationInfo.m_namesBlock = nullptr; + allocationInfo.m_namesBlockSize = 0; + allocationInfo.m_name = nullptr; + allocationInfo.m_fileName = nullptr; + } + if (allocationInfo.m_stackFrames) + { + m_records.get_allocator().deallocate(allocationInfo.m_stackFrames, sizeof(AZ::Debug::StackFrame) * m_numStackLevels, 1); + allocationInfo.m_stackFrames = nullptr; + } + if (info) + { + *info = allocationInfo; + } - // if requested set memory to a specific value. - if (m_isMarkUnallocatedMemory) - { - memset(address, GetUnallocatedMarkValue(), byteSize); - } -} - -//========================================================================= -// ResizeAllocation -// [9/20/2009] -//========================================================================= -void -AllocationRecords::ResizeAllocation(void* address, size_t newSize) -{ - if (m_mode == RECORD_NO_RECORDS) - { - return; + // if requested set memory to a specific value. + if (m_isMarkUnallocatedMemory) + { + memset(address, GetUnallocatedMarkValue(), byteSize); + } } - AllocationInfo* allocationInfo; - { - AZStd::scoped_lock lock(m_recordsMutex); - Debug::AllocationRecordsType::iterator iter = m_records.find(address); - AZ_Assert(iter != m_records.end(), "Could not find address 0x%p in the allocator!", address); - allocationInfo = &iter->second; - } - AllocatorManager::Instance().DebugBreak(address, *allocationInfo); - -#if defined(ENABLE_MEMORY_GUARD) - if (m_memoryGuardSize == sizeof(Debug::GuardValue)) + //========================================================================= + // ResizeAllocation + // [9/20/2009] + //========================================================================= + void AllocationRecords::ResizeAllocation(void* address, size_t newSize) { - if (m_isAutoIntegrityCheck) + if (m_mode == RECORD_NO_RECORDS) { - // full integrity check - IntegrityCheck(); + return; } - else + + AllocationInfo* allocationInfo; + { + AZStd::scoped_lock lock(m_recordsMutex); + Debug::AllocationRecordsType::iterator iter = m_records.find(address); + AZ_Assert(iter != m_records.end(), "Could not find address 0x%p in the allocator!", address); + allocationInfo = &iter->second; + } + AllocatorManager::Instance().DebugBreak(address, *allocationInfo); + +#if defined(ENABLE_MEMORY_GUARD) + if (m_memoryGuardSize == sizeof(Debug::GuardValue)) { - // check memory guard - char* guardAddress = reinterpret_cast(address) + allocationInfo->m_byteSize; - Debug::GuardValue* guard = reinterpret_cast(guardAddress); - if (!guard->Validate()) + if (m_isAutoIntegrityCheck) + { + // full integrity check + IntegrityCheck(); + } + else { - AZ_Printf("Memory", "Memory stomp located at address %p, part of allocation:", guardAddress); - PrintAllocationsCB printAlloc(true); - printAlloc(address, iter->second, m_numStackLevels); - AZ_Assert(false, "MEMORY STOMP DETECTED!!!"); + // check memory guard + char* guardAddress = reinterpret_cast(address) + allocationInfo->m_byteSize; + Debug::GuardValue* guard = reinterpret_cast(guardAddress); + if (!guard->Validate()) + { + AZ_Printf("Memory", "Memory stomp located at address %p, part of allocation:", guardAddress); + PrintAllocationsCB printAlloc(true); + printAlloc(address, iter->second, m_numStackLevels); + AZ_Assert(false, "MEMORY STOMP DETECTED!!!"); + } + guard->~GuardValue(); } - guard->~GuardValue(); + // init the new memory guard + newSize -= sizeof(Debug::GuardValue); + new (reinterpret_cast(address) + newSize) Debug::GuardValue(); } - // init the new memory guard - newSize -= sizeof(Debug::GuardValue); - new(reinterpret_cast(address)+newSize) Debug::GuardValue(); - } #endif - // statistics - m_requestedBytes -= allocationInfo->m_byteSize; - m_requestedBytes += newSize; - size_t currentRequestedBytePeak; - size_t newRequestedBytePeak; - do - { - currentRequestedBytePeak = m_requestedBytesPeak.load(std::memory_order::memory_order_relaxed); - newRequestedBytePeak = AZStd::GetMax(currentRequestedBytePeak, m_requestedBytes.load(std::memory_order::memory_order_relaxed)); - } while (!m_requestedBytesPeak.compare_exchange_weak(currentRequestedBytePeak, newRequestedBytePeak)); - ++m_requestedAllocs; - - // update allocation size - allocationInfo->m_byteSize = newSize; -} - -//========================================================================= -// EnumerateAllocations -// [9/29/2009] -//========================================================================= -void -AllocationRecords::SetMode(Mode mode) -{ - if (mode == RECORD_NO_RECORDS) - { + // statistics + m_requestedBytes -= allocationInfo->m_byteSize; + m_requestedBytes += newSize; + size_t currentRequestedBytePeak; + size_t newRequestedBytePeak; + do { - AZStd::scoped_lock lock(m_recordsMutex); - m_records.clear(); - } - m_requestedBytes = 0; - m_requestedBytesPeak = 0; - m_requestedAllocs = 0; - } - - AZ_Warning("Memory", m_mode != RECORD_NO_RECORDS || mode == RECORD_NO_RECORDS, "Records recording was disabled and now it's enabled! You might get assert when you free memory, if a you have allocations which were not recorded!"); - - m_mode = mode; -} + currentRequestedBytePeak = m_requestedBytesPeak.load(std::memory_order::memory_order_relaxed); + newRequestedBytePeak = AZStd::GetMax(currentRequestedBytePeak, m_requestedBytes.load(std::memory_order::memory_order_relaxed)); + } while (!m_requestedBytesPeak.compare_exchange_weak(currentRequestedBytePeak, newRequestedBytePeak)); + ++m_requestedAllocs; -//========================================================================= -// EnumerateAllocations -// [9/29/2009] -//========================================================================= -void -AllocationRecords::EnumerateAllocations(AllocationInfoCBType cb) -{ - // enumerate all allocations and stop if requested. - // Since allocations can change during the iteration (code that prints out the records could allocate, which will - // mutate m_records), we are going to make a copy and iterate the copy. - Debug::AllocationRecordsType recordsCopy; - { - AZStd::scoped_lock lock(m_recordsMutex); - recordsCopy = m_records; + // update allocation size + allocationInfo->m_byteSize = newSize; } - for (Debug::AllocationRecordsType::const_iterator iter = recordsCopy.begin(); iter != recordsCopy.end(); ++iter) + + //========================================================================= + // EnumerateAllocations + // [9/29/2009] + //========================================================================= + void AllocationRecords::SetMode(Mode mode) { - if (!cb(iter->first, iter->second, m_numStackLevels)) + if (mode == RECORD_NO_RECORDS) { - break; + { + AZStd::scoped_lock lock(m_recordsMutex); + m_records.clear(); + } + m_requestedBytes = 0; + m_requestedBytesPeak = 0; + m_requestedAllocs = 0; } + + AZ_Warning( + "Memory", m_mode != RECORD_NO_RECORDS || mode == RECORD_NO_RECORDS, + "Records recording was disabled and now it's enabled! You might get assert when you free memory, if a you have allocations " + "which were not recorded!"); + + m_mode = mode; } -} - -//========================================================================= -// IntegrityCheck -// [9/9/2011] -//========================================================================= -void -AllocationRecords::IntegrityCheck() const -{ -#if defined(ENABLE_MEMORY_GUARD) - if (m_memoryGuardSize == sizeof(Debug::GuardValue)) + + //========================================================================= + // EnumerateAllocations + // [9/29/2009] + //========================================================================= + void AllocationRecords::EnumerateAllocations(AllocationInfoCBType cb) { + // enumerate all allocations and stop if requested. + // Since allocations can change during the iteration (code that prints out the records could allocate, which will + // mutate m_records), we are going to make a copy and iterate the copy. Debug::AllocationRecordsType recordsCopy; { AZStd::scoped_lock lock(m_recordsMutex); @@ -455,67 +438,93 @@ AllocationRecords::IntegrityCheck() const } for (Debug::AllocationRecordsType::const_iterator iter = recordsCopy.begin(); iter != recordsCopy.end(); ++iter) { - // check memory guard - const char* guardAddress = reinterpret_cast(iter->first)+ iter->second.m_byteSize; - if (!reinterpret_cast(guardAddress)->Validate()) + if (!cb(iter->first, iter->second, m_numStackLevels)) { - // We have to turn off the integrity check at this point if we want to succesfully report the memory - // stomp we just found. If we don't turn this off, the printf just winds off the stack as each memory - // allocation done therein recurses this same code. - *const_cast(&m_isAutoIntegrityCheck) = false; - AZ_Printf("Memory", "Memory stomp located at address %p, part of allocation:", guardAddress); - PrintAllocationsCB printAlloc(true); - printAlloc(iter->first, iter->second, m_numStackLevels); - AZ_Error("Memory", false, "MEMORY STOMP DETECTED!!!"); + break; } } } -#endif -} - -//========================================================================= -// operator() -// [9/29/2009] -//========================================================================= -bool -PrintAllocationsCB::operator()(void* address, const AllocationInfo& info, unsigned char numStackLevels) -{ - if (m_includeNameAndFilename && info.m_name) - { - AZ_Printf("Memory", "Allocation Name: \"%s\" Addr: 0%p Size: %d Alignment: %d\n", info.m_name, address, info.m_byteSize, info.m_alignment); - } - else + + //========================================================================= + // IntegrityCheck + // [9/9/2011] + //========================================================================= + void AllocationRecords::IntegrityCheck() const { - AZ_Printf("Memory", "Allocation Addr: 0%p Size: %d Alignment: %d\n", address, info.m_byteSize, info.m_alignment); +#if defined(ENABLE_MEMORY_GUARD) + if (m_memoryGuardSize == sizeof(Debug::GuardValue)) + { + Debug::AllocationRecordsType recordsCopy; + { + AZStd::scoped_lock lock(m_recordsMutex); + recordsCopy = m_records; + } + for (Debug::AllocationRecordsType::const_iterator iter = recordsCopy.begin(); iter != recordsCopy.end(); ++iter) + { + // check memory guard + const char* guardAddress = reinterpret_cast(iter->first) + iter->second.m_byteSize; + if (!reinterpret_cast(guardAddress)->Validate()) + { + // We have to turn off the integrity check at this point if we want to succesfully report the memory + // stomp we just found. If we don't turn this off, the printf just winds off the stack as each memory + // allocation done therein recurses this same code. + *const_cast(&m_isAutoIntegrityCheck) = false; + AZ_Printf("Memory", "Memory stomp located at address %p, part of allocation:", guardAddress); + PrintAllocationsCB printAlloc(true); + printAlloc(iter->first, iter->second, m_numStackLevels); + AZ_Error("Memory", false, "MEMORY STOMP DETECTED!!!"); + } + } + } +#endif } - if (m_isDetailed) + //========================================================================= + // operator() + // [9/29/2009] + //========================================================================= + bool PrintAllocationsCB::operator()(void* address, const AllocationInfo& info, unsigned char numStackLevels) { - if (!info.m_stackFrames) + if (m_includeNameAndFilename && info.m_name) { - AZ_Printf("Memory", " %s (%d)\n", info.m_fileName, info.m_lineNum); + AZ_Printf( + "Memory", "Allocation Name: \"%s\" Addr: 0%p Size: %d Alignment: %d\n", info.m_name, address, info.m_byteSize, + info.m_alignment); } else { - // Allocation callstack - const unsigned char decodeStep = 40; - Debug::SymbolStorage::StackLine lines[decodeStep]; - unsigned char iFrame = 0; - while (numStackLevels>0) + AZ_Printf("Memory", "Allocation Addr: 0%p Size: %d Alignment: %d\n", address, info.m_byteSize, info.m_alignment); + } + + if (m_isDetailed) + { + if (!info.m_stackFrames) + { + AZ_Printf("Memory", " %s (%d)\n", info.m_fileName, info.m_lineNum); + } + else { - unsigned char numToDecode = AZStd::GetMin(decodeStep, numStackLevels); - Debug::SymbolStorage::DecodeFrames(&info.m_stackFrames[iFrame], numToDecode, lines); - for (unsigned char i = 0; i < numToDecode; ++i) + // Allocation callstack + const unsigned char decodeStep = 40; + Debug::SymbolStorage::StackLine lines[decodeStep]; + unsigned char iFrame = 0; + while (numStackLevels > 0) { - if (info.m_stackFrames[iFrame+i].IsValid()) + unsigned char numToDecode = AZStd::GetMin(decodeStep, numStackLevels); + Debug::SymbolStorage::DecodeFrames(&info.m_stackFrames[iFrame], numToDecode, lines); + for (unsigned char i = 0; i < numToDecode; ++i) { - AZ_Printf("Memory", " %s\n", lines[i]); + if (info.m_stackFrames[iFrame + i].IsValid()) + { + AZ_Printf("Memory", " %s\n", lines[i]); + } } + numStackLevels -= numToDecode; + iFrame += numToDecode; } - numStackLevels -= numToDecode; - iFrame += numToDecode; } } + return true; // continue enumerating } - return true; // continue enumerating -} + +} // namespace AZ::Debug diff --git a/Code/Framework/AzCore/AzCore/Memory/AllocatorBase.cpp b/Code/Framework/AzCore/AzCore/Memory/AllocatorBase.cpp index 61e883bb4e..c2bf9fe45c 100644 --- a/Code/Framework/AzCore/AzCore/Memory/AllocatorBase.cpp +++ b/Code/Framework/AzCore/AzCore/Memory/AllocatorBase.cpp @@ -9,191 +9,361 @@ #include #include -using namespace AZ; +#define RECORDING_ENABLED 0 -AllocatorBase::AllocatorBase(IAllocatorAllocate* allocationSource, const char* name, const char* desc) : - IAllocator(allocationSource), - m_name(name), - m_desc(desc) -{ -} - -AllocatorBase::~AllocatorBase() -{ - AZ_Assert(!m_isReady, "Allocator %s (%s) is being destructed without first having gone through proper calls to PreDestroy() and Destroy(). Use AllocatorInstance<> for global allocators or AllocatorWrapper<> for local allocators.", m_name, m_desc); -} +#if RECORDING_ENABLED -const char* AllocatorBase::GetName() const -{ - return m_name; -} +#include +#include +#include +#include -const char* AllocatorBase::GetDescription() const +namespace { - return m_desc; -} + class DebugAllocator + { + public: + using pointer_type = void*; + using size_type = AZStd::size_t; + using difference_type = AZStd::ptrdiff_t; + using allow_memory_leaks = AZStd::false_type; ///< Regular allocators should not leak. -IAllocatorAllocate* AllocatorBase::GetSchema() -{ - return nullptr; -} + AZ_FORCE_INLINE pointer_type allocate(size_t byteSize, size_t alignment, int = 0) + { + return AZ_OS_MALLOC(byteSize, alignment); + } + AZ_FORCE_INLINE size_type resize(pointer_type, size_type) + { + return 0; + } + AZ_FORCE_INLINE void deallocate(pointer_type ptr, size_type, size_type) + { + AZ_OS_FREE(ptr); + } + }; -Debug::AllocationRecords* AllocatorBase::GetRecords() -{ - return m_records; -} + #pragma pack(push, 1) + struct alignas(1) AllocatorOperation + { + enum OperationType : size_t + { + ALLOCATE, + DEALLOCATE + }; + OperationType m_type: 1; + size_t m_size : 28; // Can represent up to 256Mb requests + size_t m_alignment : 7; // Can represent up to 128 alignment + size_t m_recordId : 28; // Can represent up to 256M simultaneous requests, we reuse ids + }; + #pragma pack(pop) + static_assert(sizeof(AllocatorOperation) == 8); -void AllocatorBase::SetRecords(Debug::AllocationRecords* records) -{ - m_records = records; - m_memoryGuardSize = records ? records->MemoryGuardSize() : 0; -} + static AZStd::mutex s_operationsMutex = {}; -bool AllocatorBase::IsReady() const -{ - return m_isReady; -} + static constexpr size_t s_maxNumberOfAllocationsToRecord = 16384; + static size_t s_numberOfAllocationsRecorded = 0; + static constexpr size_t s_allocationOperationCount = 5 * 1024; + static AZStd::array s_operations = {}; + static uint64_t s_operationCounter = 0; -bool AllocatorBase::CanBeOverridden() const -{ - return m_canBeOverridden; -} + static unsigned int s_nextRecordId = 1; + using AllocatorOperationByAddress = AZStd::unordered_map, DebugAllocator>; + static AllocatorOperationByAddress s_allocatorOperationByAddress; + using AvailableRecordIds = AZStd::vector; + AvailableRecordIds s_availableRecordIds; -void AllocatorBase::PostCreate() -{ - if (m_registrationEnabled) + void RecordAllocatorOperation(AllocatorOperation::OperationType type, void* ptr, size_t size = 0, size_t alignment = 0) { - if (AZ::Environment::IsReady()) + AZStd::scoped_lock lock(s_operationsMutex); + if (s_operationCounter == s_allocationOperationCount) + { + AZ::IO::SystemFile file; + int mode = AZ::IO::SystemFile::OpenMode::SF_OPEN_APPEND | AZ::IO::SystemFile::OpenMode::SF_OPEN_WRITE_ONLY; + if (!file.Exists("memoryrecordings.bin")) + { + mode |= AZ::IO::SystemFile::OpenMode::SF_OPEN_CREATE; + } + file.Open("memoryrecordings.bin", mode); + if (file.IsOpen()) + { + file.Write(&s_operations, sizeof(AllocatorOperation) * s_allocationOperationCount); + file.Close(); + } + s_operationCounter = 0; + } + AllocatorOperation& operation = s_operations[s_operationCounter++]; + operation.m_type = type; + if (type == AllocatorOperation::OperationType::ALLOCATE) { - AllocatorManager::Instance().RegisterAllocator(this); + if (s_numberOfAllocationsRecorded > s_maxNumberOfAllocationsToRecord) + { + // reached limit of allocations, dont record anymore + --s_operationCounter; + return; + } + ++s_numberOfAllocationsRecorded; + operation.m_size = size; + operation.m_alignment = alignment; + unsigned int recordId = 0; + if (!s_availableRecordIds.empty()) + { + recordId = s_availableRecordIds.back(); + s_availableRecordIds.pop_back(); + } + else + { + recordId = s_nextRecordId; + ++s_nextRecordId; + } + operation.m_recordId = recordId; + auto it = s_allocatorOperationByAddress.emplace(ptr, operation); + if (!it.second) + { + // double alloc or resize, leave the current record and return the id + operation = it.first->second; + s_availableRecordIds.emplace_back(recordId); + } } else { - AllocatorManager::PreRegisterAllocator(this); + if (ptr == nullptr) + { + // common scenario, just record the operation + operation.m_size = 0; + operation.m_alignment = 0; + operation.m_recordId = 0; // recordId = 0 will flag this case + } + else + { + auto it = s_allocatorOperationByAddress.find(ptr); + if (it != s_allocatorOperationByAddress.end()) + { + operation.m_size = it->second.m_size; + operation.m_alignment = it->second.m_alignment; + operation.m_recordId = it->second.m_recordId; + s_availableRecordIds.push_back(it->second.m_recordId); + s_allocatorOperationByAddress.erase(it); + } + else + { + // just dont record this operation + --s_operationCounter; + } + } } + } +} +#endif - const auto debugConfig = GetDebugConfig(); - if (!debugConfig.m_excludeFromDebugging) +namespace AZ +{ + AllocatorBase::AllocatorBase(IAllocatorAllocate* allocationSource, const char* name, const char* desc) + : IAllocator(allocationSource) + , m_name(name) + , m_desc(desc) { - SetRecords(aznew Debug::AllocationRecords((unsigned char)debugConfig.m_stackRecordLevels, debugConfig.m_usesMemoryGuards, debugConfig.m_marksUnallocatedMemory, GetName())); } - m_isReady = true; -} + AllocatorBase::~AllocatorBase() + { + AZ_Assert( + !m_isReady, + "Allocator %s (%s) is being destructed without first having gone through proper calls to PreDestroy() and Destroy(). Use " + "AllocatorInstance<> for global allocators or AllocatorWrapper<> for local allocators.", + m_name, m_desc); + } -void AllocatorBase::PreDestroy() -{ - Debug::AllocationRecords* allocatorRecords = GetRecords(); - if(allocatorRecords) + const char* AllocatorBase::GetName() const { - delete allocatorRecords; - SetRecords(nullptr); + return m_name; } - if (m_registrationEnabled && AZ::AllocatorManager::IsReady()) + const char* AllocatorBase::GetDescription() const { - AllocatorManager::Instance().UnRegisterAllocator(this); + return m_desc; } - m_isReady = false; -} + IAllocatorAllocate* AllocatorBase::GetSchema() + { + return nullptr; + } -void AllocatorBase::SetLazilyCreated(bool lazy) -{ - m_isLazilyCreated = lazy; -} + Debug::AllocationRecords* AllocatorBase::GetRecords() + { + return m_records; + } -bool AllocatorBase::IsLazilyCreated() const -{ - return m_isLazilyCreated; -} + void AllocatorBase::SetRecords(Debug::AllocationRecords* records) + { + m_records = records; + m_memoryGuardSize = records ? records->MemoryGuardSize() : 0; + } -void AllocatorBase::SetProfilingActive(bool active) -{ - m_isProfilingActive = active; -} + bool AllocatorBase::IsReady() const + { + return m_isReady; + } -bool AllocatorBase::IsProfilingActive() const -{ - return m_isProfilingActive; -} + bool AllocatorBase::CanBeOverridden() const + { + return m_canBeOverridden; + } -void AllocatorBase::DisableOverriding() -{ - m_canBeOverridden = false; -} + void AllocatorBase::PostCreate() + { + if (m_registrationEnabled) + { + if (AZ::Environment::IsReady()) + { + AllocatorManager::Instance().RegisterAllocator(this); + } + else + { + AllocatorManager::PreRegisterAllocator(this); + } + } -void AllocatorBase::DisableRegistration() -{ - m_registrationEnabled = false; -} + const auto debugConfig = GetDebugConfig(); + if (!debugConfig.m_excludeFromDebugging) + { + SetRecords(aznew Debug::AllocationRecords( + (unsigned char)debugConfig.m_stackRecordLevels, debugConfig.m_usesMemoryGuards, debugConfig.m_marksUnallocatedMemory, + GetName())); + } -void AllocatorBase::ProfileAllocation(void* ptr, size_t byteSize, size_t alignment, const char* name, const char* fileName, int lineNum, int suppressStackRecord) -{ + m_isReady = true; + } + + void AllocatorBase::PreDestroy() + { + Debug::AllocationRecords* allocatorRecords = GetRecords(); + if (allocatorRecords) + { + delete allocatorRecords; + SetRecords(nullptr); + } + + if (m_registrationEnabled && AZ::AllocatorManager::IsReady()) + { + AllocatorManager::Instance().UnRegisterAllocator(this); + } + + m_isReady = false; + } + + void AllocatorBase::SetLazilyCreated(bool lazy) + { + m_isLazilyCreated = lazy; + } + + bool AllocatorBase::IsLazilyCreated() const + { + return m_isLazilyCreated; + } + + void AllocatorBase::SetProfilingActive(bool active) + { + m_isProfilingActive = active; + } + + bool AllocatorBase::IsProfilingActive() const + { + return m_isProfilingActive; + } + + void AllocatorBase::DisableOverriding() + { + m_canBeOverridden = false; + } + + void AllocatorBase::DisableRegistration() + { + m_registrationEnabled = false; + } + + void AllocatorBase::ProfileAllocation( + void* ptr, size_t byteSize, size_t alignment, const char* name, const char* fileName, int lineNum, int suppressStackRecord) + { #if defined(AZ_HAS_VARIADIC_TEMPLATES) && defined(AZ_DEBUG_BUILD) - ++suppressStackRecord; // one more for the fact the ebus is a function + ++suppressStackRecord; // one more for the fact the ebus is a function #endif // AZ_HAS_VARIADIC_TEMPLATES - if (m_isProfilingActive) - { - auto records = GetRecords(); - if (records) + if (m_isProfilingActive) { - records->RegisterAllocation(ptr, byteSize, alignment, name, fileName, lineNum, suppressStackRecord + 1); + auto records = GetRecords(); + if (records) + { + records->RegisterAllocation(ptr, byteSize, alignment, name, fileName, lineNum, suppressStackRecord + 1); + } } + +#if RECORDING_ENABLED + RecordAllocatorOperation(AllocatorOperation::ALLOCATE, ptr, byteSize, alignment); +#endif } -} -void AllocatorBase::ProfileDeallocation(void* ptr, size_t byteSize, size_t alignment, Debug::AllocationInfo* info) -{ - if (m_isProfilingActive) + void AllocatorBase::ProfileDeallocation(void* ptr, size_t byteSize, size_t alignment, Debug::AllocationInfo* info) { - auto records = GetRecords(); - if (records) + if (m_isProfilingActive) { - records->UnregisterAllocation(ptr, byteSize, alignment, info); + auto records = GetRecords(); + if (records) + { + records->UnregisterAllocation(ptr, byteSize, alignment, info); + } } +#if RECORDING_ENABLED + RecordAllocatorOperation(AllocatorOperation::DEALLOCATE, ptr, byteSize, alignment); +#endif } -} -void AllocatorBase::ProfileReallocationBegin([[maybe_unused]] void* ptr, [[maybe_unused]] size_t newSize) -{ -} + void AllocatorBase::ProfileReallocationBegin([[maybe_unused]] void* ptr, [[maybe_unused]] size_t newSize) + { + } -void AllocatorBase::ProfileReallocationEnd(void* ptr, void* newPtr, size_t newSize, size_t newAlignment) -{ - if (m_isProfilingActive) + void AllocatorBase::ProfileReallocationEnd(void* ptr, void* newPtr, size_t newSize, size_t newAlignment) { - Debug::AllocationInfo info; - ProfileDeallocation(ptr, 0, 0, &info); - ProfileAllocation(newPtr, newSize, newAlignment, info.m_name, info.m_fileName, info.m_lineNum, 0); + if (m_isProfilingActive) + { + Debug::AllocationInfo info; + ProfileDeallocation(ptr, 0, 0, &info); + ProfileAllocation(newPtr, newSize, newAlignment, info.m_name, info.m_fileName, info.m_lineNum, 0); + } +#if RECORDING_ENABLED + RecordAllocatorOperation(AllocatorOperation::DEALLOCATE, ptr); + RecordAllocatorOperation(AllocatorOperation::ALLOCATE, newPtr, newSize, newAlignment); +#endif } -} -void AllocatorBase::ProfileReallocation(void* ptr, void* newPtr, size_t newSize, size_t newAlignment) -{ - ProfileReallocationEnd(ptr, newPtr, newSize, newAlignment); -} + void AllocatorBase::ProfileReallocation(void* ptr, void* newPtr, size_t newSize, size_t newAlignment) + { + ProfileReallocationEnd(ptr, newPtr, newSize, newAlignment); + } -void AllocatorBase::ProfileResize(void* ptr, size_t newSize) -{ - if (newSize && m_isProfilingActive) + void AllocatorBase::ProfileResize(void* ptr, size_t newSize) { - auto records = GetRecords(); - if (records) + if (newSize && m_isProfilingActive) { - records->ResizeAllocation(ptr, newSize); + auto records = GetRecords(); + if (records) + { + records->ResizeAllocation(ptr, newSize); + } } +#if RECORDING_ENABLED + RecordAllocatorOperation(AllocatorOperation::ALLOCATE, ptr, newSize); +#endif } -} -bool AllocatorBase::OnOutOfMemory(size_t byteSize, size_t alignment, int flags, const char* name, const char* fileName, int lineNum) -{ - if (AllocatorManager::IsReady() && AllocatorManager::Instance().m_outOfMemoryListener) + bool AllocatorBase::OnOutOfMemory(size_t byteSize, size_t alignment, int flags, const char* name, const char* fileName, int lineNum) { - AllocatorManager::Instance().m_outOfMemoryListener(this, byteSize, alignment, flags, name, fileName, lineNum); - return true; + if (AllocatorManager::IsReady() && AllocatorManager::Instance().m_outOfMemoryListener) + { + AllocatorManager::Instance().m_outOfMemoryListener(this, byteSize, alignment, flags, name, fileName, lineNum); + return true; + } + return false; } - return false; -} + +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapAllocator.cpp b/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapAllocator.cpp index 30b0b78fe5..d55ca8b695 100644 --- a/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapAllocator.cpp +++ b/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapAllocator.cpp @@ -13,186 +13,182 @@ #include -using namespace AZ; - -//========================================================================= -// BestFitExternalMapAllocator -// [1/28/2011] -//========================================================================= -BestFitExternalMapAllocator::BestFitExternalMapAllocator() - : AllocatorBase(this, "BestFitExternalMapAllocator", "Best fit allocator with external tracking storage!") - , m_schema(nullptr) -{} - -//========================================================================= -// Create -// [1/28/2011] -//========================================================================= -bool -BestFitExternalMapAllocator::Create(const Descriptor& desc) +namespace AZ { - AZ_Assert(IsReady() == false, "BestFitExternalMapAllocator was already created!"); - if (IsReady()) + //========================================================================= + // BestFitExternalMapAllocator + // [1/28/2011] + //========================================================================= + BestFitExternalMapAllocator::BestFitExternalMapAllocator() + : AllocatorBase(this, "BestFitExternalMapAllocator", "Best fit allocator with external tracking storage!") + , m_schema(nullptr) { - return false; } - bool isReady = true; + //========================================================================= + // Create + // [1/28/2011] + //========================================================================= + bool BestFitExternalMapAllocator::Create(const Descriptor& desc) + { + AZ_Assert(IsReady() == false, "BestFitExternalMapAllocator was already created!"); + if (IsReady()) + { + return false; + } + + bool isReady = true; + + m_desc = desc; + BestFitExternalMapSchema::Descriptor schemaDesc; + schemaDesc.m_mapAllocator = desc.m_mapAllocator; + schemaDesc.m_memoryBlock = desc.m_memoryBlock; + schemaDesc.m_memoryBlockByteSize = desc.m_memoryBlockByteSize; + + m_schema = azcreate(BestFitExternalMapSchema, (schemaDesc), SystemAllocator); + if (m_schema == nullptr) + { + isReady = false; + } + + return isReady; + } - m_desc = desc; - BestFitExternalMapSchema::Descriptor schemaDesc; - schemaDesc.m_mapAllocator = desc.m_mapAllocator; - schemaDesc.m_memoryBlock = desc.m_memoryBlock; - schemaDesc.m_memoryBlockByteSize = desc.m_memoryBlockByteSize; + //========================================================================= + // Destroy + // [1/28/2011] + //========================================================================= + void BestFitExternalMapAllocator::Destroy() + { + azdestroy(m_schema, SystemAllocator); + m_schema = nullptr; + } - m_schema = azcreate(BestFitExternalMapSchema, (schemaDesc), SystemAllocator); - if (m_schema == nullptr) + AllocatorDebugConfig BestFitExternalMapAllocator::GetDebugConfig() { - isReady = false; + return AllocatorDebugConfig() + .ExcludeFromDebugging(!m_desc.m_allocationRecords) + .StackRecordLevels(m_desc.m_stackRecordLevels) + .MarksUnallocatedMemory(false) + .UsesMemoryGuards(false); } - return isReady; -} + //========================================================================= + // Allocate + // [1/28/2011] + //========================================================================= + BestFitExternalMapAllocator::pointer_type BestFitExternalMapAllocator::Allocate( + size_type byteSize, + size_type alignment, + int flags, + [[maybe_unused]] const char* name, + [[maybe_unused]] const char* fileName, + [[maybe_unused]] int lineNum, + unsigned int suppressStackRecord) + { + (void)suppressStackRecord; -//========================================================================= -// Destroy -// [1/28/2011] -//========================================================================= -void -BestFitExternalMapAllocator::Destroy() -{ - azdestroy(m_schema, SystemAllocator); - m_schema = nullptr; -} + AZ_Assert(byteSize > 0, "You can not allocate 0 bytes!"); + AZ_Assert((alignment & (alignment - 1)) == 0, "Alignment must be power of 2!"); + byteSize = MemorySizeAdjustedUp(byteSize); -AllocatorDebugConfig BestFitExternalMapAllocator::GetDebugConfig() -{ - return AllocatorDebugConfig() - .ExcludeFromDebugging(!m_desc.m_allocationRecords) - .StackRecordLevels(m_desc.m_stackRecordLevels) - .MarksUnallocatedMemory(false) - .UsesMemoryGuards(false); -} - -//========================================================================= -// Allocate -// [1/28/2011] -//========================================================================= -BestFitExternalMapAllocator::pointer_type BestFitExternalMapAllocator::Allocate( - size_type byteSize, - size_type alignment, - int flags, - [[maybe_unused]] const char* name, - [[maybe_unused]] const char* fileName, - [[maybe_unused]] int lineNum, - unsigned int suppressStackRecord) -{ - (void)suppressStackRecord; + BestFitExternalMapAllocator::pointer_type address = m_schema->Allocate(byteSize, alignment, flags); + AZ_Assert( + address != nullptr, "BestFitExternalMapAllocator: Failed to allocate %d bytes aligned on %d (flags: 0x%08x) %s : %s (%d)!", + byteSize, alignment, flags, name ? name : "(no name)", fileName ? fileName : "(no file name)", lineNum); + AZ_MEMORY_PROFILE(ProfileAllocation(address, byteSize, alignment, name, fileName, lineNum, suppressStackRecord + 1)); - AZ_Assert(byteSize > 0, "You can not allocate 0 bytes!"); - AZ_Assert((alignment & (alignment - 1)) == 0, "Alignment must be power of 2!"); - byteSize = MemorySizeAdjustedUp(byteSize); + return address; + } - BestFitExternalMapAllocator::pointer_type address = m_schema->Allocate(byteSize, alignment, flags); - AZ_Assert(address != nullptr, "BestFitExternalMapAllocator: Failed to allocate %d bytes aligned on %d (flags: 0x%08x) %s : %s (%d)!", byteSize, alignment, flags, name ? name : "(no name)", fileName ? fileName : "(no file name)", lineNum); - AZ_MEMORY_PROFILE(ProfileAllocation(address, byteSize, alignment, name, fileName, lineNum, suppressStackRecord + 1)); + //========================================================================= + // DeAllocate + // [1/28/2011] + //========================================================================= + void BestFitExternalMapAllocator::DeAllocate(pointer_type ptr, size_type byteSize, size_type alignment) + { + byteSize = MemorySizeAdjustedUp(byteSize); + AZ_MEMORY_PROFILE(ProfileDeallocation(ptr, byteSize, alignment, nullptr)); - return address; -} + (void)byteSize; + (void)alignment; + m_schema->DeAllocate(ptr); + } -//========================================================================= -// DeAllocate -// [1/28/2011] -//========================================================================= -void -BestFitExternalMapAllocator::DeAllocate(pointer_type ptr, size_type byteSize, size_type alignment) -{ - byteSize = MemorySizeAdjustedUp(byteSize); - AZ_MEMORY_PROFILE(ProfileDeallocation(ptr, byteSize, alignment, nullptr)); - - (void)byteSize; - (void)alignment; - m_schema->DeAllocate(ptr); -} - -//========================================================================= -// Resize -// [1/28/2011] -//========================================================================= -BestFitExternalMapAllocator::size_type -BestFitExternalMapAllocator::Resize(pointer_type ptr, size_type newSize) -{ - (void)ptr; - (void)newSize; - /* todo */ - return 0; -} - -//========================================================================= -// ReAllocate -// [9/13/2011] -//========================================================================= -BestFitExternalMapAllocator::pointer_type -BestFitExternalMapAllocator::ReAllocate(pointer_type ptr, size_type newSize, size_type newAlignment) -{ - (void)ptr; - (void)newSize; - (void)newAlignment; - AZ_Assert(false, "Not supported!"); - return nullptr; -} - -//========================================================================= -// AllocationSize -// [1/28/2011] -//========================================================================= -BestFitExternalMapAllocator::size_type -BestFitExternalMapAllocator::AllocationSize(pointer_type ptr) -{ - return MemorySizeAdjustedDown(m_schema->AllocationSize(ptr)); -} - -//========================================================================= -// NumAllocatedBytes -// [1/28/2011] -//========================================================================= -BestFitExternalMapAllocator::size_type -BestFitExternalMapAllocator::NumAllocatedBytes() const -{ - return m_schema->NumAllocatedBytes(); -} - -//========================================================================= -// Capacity -// [1/28/2011] -//========================================================================= -BestFitExternalMapAllocator::size_type -BestFitExternalMapAllocator::Capacity() const -{ - return m_schema->Capacity(); -} - -//========================================================================= -// GetMaxAllocationSize -// [1/28/2011] -//========================================================================= -BestFitExternalMapAllocator::size_type -BestFitExternalMapAllocator::GetMaxAllocationSize() const -{ - return m_schema->GetMaxAllocationSize(); -} + //========================================================================= + // Resize + // [1/28/2011] + //========================================================================= + BestFitExternalMapAllocator::size_type BestFitExternalMapAllocator::Resize(pointer_type ptr, size_type newSize) + { + (void)ptr; + (void)newSize; + /* todo */ + return 0; + } -auto BestFitExternalMapAllocator::GetMaxContiguousAllocationSize() const -> size_type -{ - return m_schema->GetMaxContiguousAllocationSize(); -} - -//========================================================================= -// GetSubAllocator -// [1/28/2011] -//========================================================================= -IAllocatorAllocate* -BestFitExternalMapAllocator::GetSubAllocator() -{ - return m_schema->GetSubAllocator(); -} + //========================================================================= + // ReAllocate + // [9/13/2011] + //========================================================================= + BestFitExternalMapAllocator::pointer_type BestFitExternalMapAllocator::ReAllocate( + pointer_type ptr, size_type newSize, size_type newAlignment) + { + (void)ptr; + (void)newSize; + (void)newAlignment; + AZ_Assert(false, "Not supported!"); + return nullptr; + } + + //========================================================================= + // AllocationSize + // [1/28/2011] + //========================================================================= + BestFitExternalMapAllocator::size_type BestFitExternalMapAllocator::AllocationSize(pointer_type ptr) + { + return MemorySizeAdjustedDown(m_schema->AllocationSize(ptr)); + } + + //========================================================================= + // NumAllocatedBytes + // [1/28/2011] + //========================================================================= + BestFitExternalMapAllocator::size_type BestFitExternalMapAllocator::NumAllocatedBytes() const + { + return m_schema->NumAllocatedBytes(); + } + + //========================================================================= + // Capacity + // [1/28/2011] + //========================================================================= + BestFitExternalMapAllocator::size_type BestFitExternalMapAllocator::Capacity() const + { + return m_schema->Capacity(); + } + + //========================================================================= + // GetMaxAllocationSize + // [1/28/2011] + //========================================================================= + BestFitExternalMapAllocator::size_type BestFitExternalMapAllocator::GetMaxAllocationSize() const + { + return m_schema->GetMaxAllocationSize(); + } + + auto BestFitExternalMapAllocator::GetMaxContiguousAllocationSize() const -> size_type + { + return m_schema->GetMaxContiguousAllocationSize(); + } + + //========================================================================= + // GetSubAllocator + // [1/28/2011] + //========================================================================= + IAllocatorAllocate* BestFitExternalMapAllocator::GetSubAllocator() + { + return m_schema->GetSubAllocator(); + } + +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapAllocator.h b/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapAllocator.h index 17425625b7..90e2056d65 100644 --- a/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapAllocator.h +++ b/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapAllocator.h @@ -5,8 +5,7 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef AZ_BEST_FIT_EXT_MAP_ALLOCATOR_H -#define AZ_BEST_FIT_EXT_MAP_ALLOCATOR_H +#pragma once #include @@ -76,7 +75,3 @@ namespace AZ }; } -#endif // AZ_BEST_FIT_EXT_MAP_ALLOCATOR_H -#pragma once - - diff --git a/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapSchema.cpp b/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapSchema.cpp index 715ecd221e..841f36f58a 100644 --- a/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapSchema.cpp +++ b/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapSchema.cpp @@ -9,194 +9,199 @@ #include #include -using namespace AZ; - -//========================================================================= -// BestFitExternalMapSchema -// [1/28/2011] -//========================================================================= -BestFitExternalMapSchema::BestFitExternalMapSchema(const Descriptor& desc) - : m_desc(desc) - , m_used(0) - , m_freeChunksMap(FreeMapType::key_compare(), AZStdIAllocator(desc.m_mapAllocator != nullptr ? desc.m_mapAllocator : &AllocatorInstance::Get())) - , m_allocChunksMap(AllocMapType::hasher(), AllocMapType::key_eq(), AZStdIAllocator(desc.m_mapAllocator != nullptr ? desc.m_mapAllocator : &AllocatorInstance::Get())) +namespace AZ { - if (m_desc.m_mapAllocator == nullptr) + //========================================================================= + // BestFitExternalMapSchema + // [1/28/2011] + //========================================================================= + BestFitExternalMapSchema::BestFitExternalMapSchema(const Descriptor& desc) + : m_desc(desc) + , m_used(0) + , m_freeChunksMap( + FreeMapType::key_compare(), + AZStdIAllocator(desc.m_mapAllocator != nullptr ? desc.m_mapAllocator : &AllocatorInstance::Get())) + , m_allocChunksMap( + AllocMapType::hasher(), + AllocMapType::key_eq(), + AZStdIAllocator(desc.m_mapAllocator != nullptr ? desc.m_mapAllocator : &AllocatorInstance::Get())) { - m_desc.m_mapAllocator = &AllocatorInstance::Get(); // used as our sub allocator + if (m_desc.m_mapAllocator == nullptr) + { + m_desc.m_mapAllocator = &AllocatorInstance::Get(); // used as our sub allocator + } + AZ_Assert(m_desc.m_memoryBlockByteSize > 0, "You must provide memory block size!"); + AZ_Assert(m_desc.m_memoryBlock != nullptr, "You must provide memory block allocated as you with!"); + // if( m_desc.m_memoryBlock == NULL) there is no point to automate this cause we need to flag this memory special, otherwise there + // is no point to use this allocator at all + // m_desc.m_memoryBlock = azmalloc(SystemAllocator,m_desc.m_memoryBlockByteSize,16); + m_freeChunksMap.insert(AZStd::make_pair(m_desc.m_memoryBlockByteSize, reinterpret_cast(m_desc.m_memoryBlock))); } - AZ_Assert(m_desc.m_memoryBlockByteSize > 0, "You must provide memory block size!"); - AZ_Assert(m_desc.m_memoryBlock != nullptr, "You must provide memory block allocated as you with!"); - //if( m_desc.m_memoryBlock == NULL) there is no point to automate this cause we need to flag this memory special, otherwise there is no point to use this allocator at all - // m_desc.m_memoryBlock = azmalloc(SystemAllocator,m_desc.m_memoryBlockByteSize,16); - m_freeChunksMap.insert(AZStd::make_pair(m_desc.m_memoryBlockByteSize, reinterpret_cast(m_desc.m_memoryBlock))); -} -//========================================================================= -// Allocate -// [1/28/2011] -//========================================================================= -BestFitExternalMapSchema::pointer_type -BestFitExternalMapSchema::Allocate(size_type byteSize, size_type alignment, int flags) -{ - (void)flags; - char* address = nullptr; - AZ_Assert(alignment > 0 && (alignment & (alignment - 1)) == 0, "Alignment must be >0 and power of 2!"); - for (int i = 0; i < 2; ++i) // max 2 attempts to allocate + //========================================================================= + // Allocate + // [1/28/2011] + //========================================================================= + BestFitExternalMapSchema::pointer_type BestFitExternalMapSchema::Allocate(size_type byteSize, size_type alignment, int flags) { - FreeMapType::iterator iter = m_freeChunksMap.find(byteSize); - size_t blockSize = 0; - char* blockAddress = nullptr; - size_t preAllocBlockSize = 0; - while (iter != m_freeChunksMap.end()) + (void)flags; + char* address = nullptr; + AZ_Assert(alignment > 0 && (alignment & (alignment - 1)) == 0, "Alignment must be >0 and power of 2!"); + for (int i = 0; i < 2; ++i) // max 2 attempts to allocate { - blockSize = iter->first; - blockAddress = iter->second; - char* alignedAddr = PointerAlignUp(blockAddress, alignment); - preAllocBlockSize = alignedAddr - blockAddress; - if (preAllocBlockSize + byteSize <= blockSize) + FreeMapType::iterator iter = m_freeChunksMap.find(byteSize); + size_t blockSize = 0; + char* blockAddress = nullptr; + size_t preAllocBlockSize = 0; + while (iter != m_freeChunksMap.end()) { - m_freeChunksMap.erase(iter); // we have our allocation - m_used += byteSize; - address = alignedAddr; - m_allocChunksMap.insert(AZStd::make_pair(address, byteSize)); - break; + blockSize = iter->first; + blockAddress = iter->second; + char* alignedAddr = PointerAlignUp(blockAddress, alignment); + preAllocBlockSize = alignedAddr - blockAddress; + if (preAllocBlockSize + byteSize <= blockSize) + { + m_freeChunksMap.erase(iter); // we have our allocation + m_used += byteSize; + address = alignedAddr; + m_allocChunksMap.insert(AZStd::make_pair(address, byteSize)); + break; + } + ++iter; } - ++iter; - } - if (address != nullptr) - { - // split blocks - if (preAllocBlockSize) // if we have a block before the alignment + if (address != nullptr) { - m_freeChunksMap.insert(AZStd::make_pair(preAllocBlockSize, blockAddress)); + // split blocks + if (preAllocBlockSize) // if we have a block before the alignment + { + m_freeChunksMap.insert(AZStd::make_pair(preAllocBlockSize, blockAddress)); + } + size_t postAllocBlockSize = blockSize - preAllocBlockSize - byteSize; + if (postAllocBlockSize) + { + m_freeChunksMap.insert(AZStd::make_pair(postAllocBlockSize, address + byteSize)); + } + + break; } - size_t postAllocBlockSize = blockSize - preAllocBlockSize - byteSize; - if (postAllocBlockSize) + else { - m_freeChunksMap.insert(AZStd::make_pair(postAllocBlockSize, address + byteSize)); + GarbageCollect(); } + } + return address; + } - break; + //========================================================================= + // DeAllocate + // [1/28/2011] + //========================================================================= + void BestFitExternalMapSchema::DeAllocate(pointer_type ptr) + { + if (ptr == nullptr) + { + return; } - else + AllocMapType::iterator iter = m_allocChunksMap.find(reinterpret_cast(ptr)); + if (iter != m_allocChunksMap.end()) { - GarbageCollect(); + m_used -= iter->second; + m_freeChunksMap.insert(AZStd::make_pair(iter->second, iter->first)); + m_allocChunksMap.erase(iter); } } - return address; -} -//========================================================================= -// DeAllocate -// [1/28/2011] -//========================================================================= -void -BestFitExternalMapSchema::DeAllocate(pointer_type ptr) -{ - if (ptr == nullptr) + //========================================================================= + // AllocationSize + // [1/28/2011] + //========================================================================= + BestFitExternalMapSchema::size_type BestFitExternalMapSchema::AllocationSize(pointer_type ptr) { - return; - } - AllocMapType::iterator iter = m_allocChunksMap.find(reinterpret_cast(ptr)); - if (iter != m_allocChunksMap.end()) - { - m_used -= iter->second; - m_freeChunksMap.insert(AZStd::make_pair(iter->second, iter->first)); - m_allocChunksMap.erase(iter); + AllocMapType::iterator iter = m_allocChunksMap.find(reinterpret_cast(ptr)); + if (iter != m_allocChunksMap.end()) + { + return iter->second; + } + return 0; } -} -//========================================================================= -// AllocationSize -// [1/28/2011] -//========================================================================= -BestFitExternalMapSchema::size_type -BestFitExternalMapSchema::AllocationSize(pointer_type ptr) -{ - AllocMapType::iterator iter = m_allocChunksMap.find(reinterpret_cast(ptr)); - if (iter != m_allocChunksMap.end()) + //========================================================================= + // GetMaxAllocationSize + // [1/28/2011] + //========================================================================= + BestFitExternalMapSchema::size_type BestFitExternalMapSchema::GetMaxAllocationSize() const { - return iter->second; + if (!m_freeChunksMap.empty()) + { + return m_freeChunksMap.rbegin()->first; + } + return 0; } - return 0; -} -//========================================================================= -// GetMaxAllocationSize -// [1/28/2011] -//========================================================================= -BestFitExternalMapSchema::size_type -BestFitExternalMapSchema::GetMaxAllocationSize() const -{ - if (!m_freeChunksMap.empty()) + auto BestFitExternalMapSchema::GetMaxContiguousAllocationSize() const -> size_type { - return m_freeChunksMap.rbegin()->first; + // Return the maximum size of any single allocation + return AZ_CORE_MAX_ALLOCATOR_SIZE; } - return 0; -} -auto BestFitExternalMapSchema::GetMaxContiguousAllocationSize() const -> size_type -{ - // Return the maximum size of any single allocation - return AZ_CORE_MAX_ALLOCATOR_SIZE; -} - -//========================================================================= -// GarbageCollect -// [1/28/2011] -//========================================================================= -void -BestFitExternalMapSchema::GarbageCollect() -{ - for (FreeMapType::iterator curBlock = m_freeChunksMap.begin(); curBlock != m_freeChunksMap.end(); ) + //========================================================================= + // GarbageCollect + // [1/28/2011] + //========================================================================= + void BestFitExternalMapSchema::GarbageCollect() { - char* curStart = curBlock->second; - char* curEnd = curStart + curBlock->first; - bool isMerge = false; - for (FreeMapType::iterator nextBlock = curBlock++; nextBlock != m_freeChunksMap.end(); ) + for (FreeMapType::iterator curBlock = m_freeChunksMap.begin(); curBlock != m_freeChunksMap.end();) { - char* nextStart = nextBlock->second; - char* nextEnd = nextStart + nextBlock->first; - if (curStart == nextEnd) + char* curStart = curBlock->second; + char* curEnd = curStart + curBlock->first; + bool isMerge = false; + for (FreeMapType::iterator nextBlock = curBlock++; nextBlock != m_freeChunksMap.end();) { - // merge - size_t newBlockSize = curBlock->first + nextBlock->first; - char* newBlockAddress = nextStart; - m_freeChunksMap.erase(nextBlock); - FreeMapType::iterator toErase = curBlock; - ++curBlock; - m_freeChunksMap.erase(toErase); - FreeMapType::iterator newBlock = m_freeChunksMap.insert(AZStd::make_pair(newBlockSize, newBlockAddress)).first; - if (curBlock != m_freeChunksMap.end() && newBlockSize < curBlock->first) // if the newBlock in before the next in the list, update next in the list to current + char* nextStart = nextBlock->second; + char* nextEnd = nextStart + nextBlock->first; + if (curStart == nextEnd) { - curBlock = newBlock; + // merge + size_t newBlockSize = curBlock->first + nextBlock->first; + char* newBlockAddress = nextStart; + m_freeChunksMap.erase(nextBlock); + FreeMapType::iterator toErase = curBlock; + ++curBlock; + m_freeChunksMap.erase(toErase); + FreeMapType::iterator newBlock = m_freeChunksMap.insert(AZStd::make_pair(newBlockSize, newBlockAddress)).first; + // if the newBlock in before the next in the list, update next in the list to current + if (curBlock != m_freeChunksMap.end() && newBlockSize < curBlock->first) + { + curBlock = newBlock; + } + isMerge = true; + break; } - isMerge = true; - break; + else if (curEnd == nextStart) + { + // merge + size_t newBlockSize = curBlock->first + nextBlock->first; + char* newBlockAddress = curStart; + m_freeChunksMap.erase(nextBlock); + FreeMapType::iterator toErase = curBlock; + ++curBlock; + m_freeChunksMap.erase(toErase); + FreeMapType::iterator newBlock = m_freeChunksMap.insert(AZStd::make_pair(newBlockSize, newBlockAddress)).first; + // if the newBlock in before the next in the list, update next in the list to current + if (curBlock != m_freeChunksMap.end() && newBlockSize < curBlock->first) + { + curBlock = newBlock; + } + isMerge = true; + break; + } + ++nextBlock; } - else if (curEnd == nextStart) + if (!isMerge) { - // merge - size_t newBlockSize = curBlock->first + nextBlock->first; - char* newBlockAddress = curStart; - m_freeChunksMap.erase(nextBlock); - FreeMapType::iterator toErase = curBlock; ++curBlock; - m_freeChunksMap.erase(toErase); - FreeMapType::iterator newBlock = m_freeChunksMap.insert(AZStd::make_pair(newBlockSize, newBlockAddress)).first; - if (curBlock != m_freeChunksMap.end() && newBlockSize < curBlock->first) // if the newBlock in before the next in the list, update next in the list to current - { - curBlock = newBlock; - } - isMerge = true; - break; } - ++nextBlock; - } - if (!isMerge) - { - ++curBlock; } } -} + +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapSchema.h b/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapSchema.h index eaab614593..0055a86ee2 100644 --- a/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapSchema.h +++ b/Code/Framework/AzCore/AzCore/Memory/BestFitExternalMapSchema.h @@ -5,8 +5,7 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef AZ_BEST_FIT_EXT_MAP_ALLOCATION_SCHEME_H -#define AZ_BEST_FIT_EXT_MAP_ALLOCATION_SCHEME_H +#pragma once #include #include @@ -77,8 +76,3 @@ namespace AZ AllocMapType m_allocChunksMap; }; } - -#endif // AZ_BEST_FIT_EXT_MAP_ALLOCATION_SCHEME_H -#pragma once - - diff --git a/Code/Framework/AzCore/AzCore/Memory/HeapSchema.cpp b/Code/Framework/AzCore/AzCore/Memory/HeapSchema.cpp index aceafa1b28..1f0fc59a97 100644 --- a/Code/Framework/AzCore/AzCore/Memory/HeapSchema.cpp +++ b/Code/Framework/AzCore/AzCore/Memory/HeapSchema.cpp @@ -115,6 +115,7 @@ namespace AZ m_ownMemoryBlock[i] = false; } + AZ_Assert(m_desc.m_numMemoryBlocks > 0, "At least one memory block is required"); for (int i = 0; i < m_desc.m_numMemoryBlocks; ++i) { if (m_desc.m_memoryBlocks[i] == nullptr) // Allocate memory block if requested! @@ -131,17 +132,6 @@ namespace AZ m_capacity += m_desc.m_memoryBlocksByteSize[i]; } - - if (m_desc.m_numMemoryBlocks == 0) - { - // Create default memory space if we can to serve for default allocations - m_memSpaces[0] = AZDLMalloc::create_mspace(0, m_desc.m_isMultithreadAlloc); - if (m_memSpaces[0]) - { - AZDLMalloc::mspace_az_set_expandable(m_memSpaces[0], true); - m_capacity = Platform::GetHeapCapacity(); - } - } } HeapSchema::~HeapSchema() diff --git a/Code/Framework/AzCore/AzCore/Memory/HeapSchema.h b/Code/Framework/AzCore/AzCore/Memory/HeapSchema.h index f72ae31057..3a7716a127 100644 --- a/Code/Framework/AzCore/AzCore/Memory/HeapSchema.h +++ b/Code/Framework/AzCore/AzCore/Memory/HeapSchema.h @@ -32,17 +32,11 @@ namespace AZ */ struct Descriptor { - Descriptor() - : m_numMemoryBlocks(0) - , m_isMultithreadAlloc(true) - {} - - static const int m_memoryBlockAlignment = 64 * 1024; static const int m_maxNumBlocks = 5; - int m_numMemoryBlocks; ///< Number of memory blocks to use. - void* m_memoryBlocks[m_maxNumBlocks]; ///< Pointers to provided memory blocks or NULL if you want the system to allocate them for you with the System Allocator. - size_t m_memoryBlocksByteSize[m_maxNumBlocks]; ///< Sizes of different memory blocks, if m_memoryBlock is 0 the block will be allocated for you with the System Allocator. - bool m_isMultithreadAlloc; ///< Set to true to enable multi threading safe allocation. + int m_numMemoryBlocks = 1; ///< Number of memory blocks to use. + void* m_memoryBlocks[m_maxNumBlocks] = {}; ///< Pointers to provided memory blocks or NULL if you want the system to allocate them for you with the System Allocator. + size_t m_memoryBlocksByteSize[m_maxNumBlocks] = {4 * 1024}; ///< Sizes of different memory blocks, if m_memoryBlock is 0 the block will be allocated for you with the System Allocator. + bool m_isMultithreadAlloc = true; ///< Set to true to enable multi threading safe allocation. }; HeapSchema(const Descriptor& desc); diff --git a/Code/Framework/AzCore/AzCore/Memory/PoolSchema.cpp b/Code/Framework/AzCore/AzCore/Memory/PoolSchema.cpp index 9167864450..c57cfea222 100644 --- a/Code/Framework/AzCore/AzCore/Memory/PoolSchema.cpp +++ b/Code/Framework/AzCore/AzCore/Memory/PoolSchema.cpp @@ -27,8 +27,8 @@ namespace AZ ////////////////////////////////////////////////////////////////////////// // Pool Allocation algorithm /** - * Pool Allocation algorithm implementation. Used in both PoolAllocator and ThreadPoolAllocator. - */ + * Pool Allocation algorithm implementation. Used in both PoolAllocator and ThreadPoolAllocator. + */ template class PoolAllocation { @@ -41,20 +41,20 @@ namespace AZ PoolAllocation(Allocator* alloc, size_t pageSize, size_t minAllocationSize, size_t maxAllocationSize); virtual ~PoolAllocation(); - void* Allocate(size_t byteSize, size_t alignment); - void DeAllocate(void* ptr); - size_t AllocationSize(void* ptr); + void* Allocate(size_t byteSize, size_t alignment); + void DeAllocate(void* ptr); + size_t AllocationSize(void* ptr); // if isForceFreeAllPages is true we will free all pages even if they have allocations in them. - void GarbageCollect(bool isForceFreeAllPages = false); - - Allocator* m_allocator; - size_t m_pageSize; - size_t m_minAllocationShift; - size_t m_minAllocationSize; - size_t m_maxAllocationSize; - size_t m_numBuckets; - BucketType* m_buckets; - size_t m_numBytesAllocated; + void GarbageCollect(bool isForceFreeAllPages = false); + + Allocator* m_allocator; + size_t m_pageSize; + size_t m_minAllocationShift; + size_t m_minAllocationSize; + size_t m_maxAllocationSize; + size_t m_numBuckets; + BucketType* m_buckets; + size_t m_numBytesAllocated; }; /** @@ -68,23 +68,22 @@ namespace AZ PoolSchemaImpl(const PoolSchema::Descriptor& desc); ~PoolSchemaImpl(); - PoolSchema::pointer_type Allocate(PoolSchema::size_type byteSize, PoolSchema::size_type alignment, int flags = 0); - void DeAllocate(PoolSchema::pointer_type ptr); - PoolSchema::size_type AllocationSize(PoolSchema::pointer_type ptr); + PoolSchema::pointer_type Allocate(PoolSchema::size_type byteSize, PoolSchema::size_type alignment, int flags = 0); + void DeAllocate(PoolSchema::pointer_type ptr); + PoolSchema::size_type AllocationSize(PoolSchema::pointer_type ptr); /** - * We allocate memory for pools in pages. Page is a information struct - * located at the end of the allocated page. When it's in the at the end - * we can usually hide it's size in the free bytes left from the pagesize/poolsize. - * \note IMPORTANT pages are aligned on the page size, this way can find quickly which - * pool the pointer belongs to. - */ - struct Page - : public AZStd::intrusive_list_node + * We allocate memory for pools in pages. Page is a information struct + * located at the end of the allocated page. When it's in the at the end + * we can usually hide it's size in the free bytes left from the pagesize/poolsize. + * \note IMPORTANT pages are aligned on the page size, this way can find quickly which + * pool the pointer belongs to. + */ + struct Page : public AZStd::intrusive_list_node { - struct FakeNode - : public AZStd::intrusive_slist_node - {}; + struct FakeNode : public AZStd::intrusive_slist_node + { + }; void SetupFreeList(size_t elementSize, size_t pageDataBlockSize); @@ -99,22 +98,22 @@ namespace AZ }; /** - * A bucket has a list of pages used with the specific pool size. - */ + * A bucket has a list of pages used with the specific pool size. + */ struct Bucket { using PageListType = AZStd::intrusive_list>; - PageListType m_pages; + PageListType m_pages; }; // Functions used by PoolAllocation template AZ_INLINE Page* PopFreePage(); - AZ_INLINE void PushFreePage(Page* page); - void GarbageCollect(); - inline bool IsInStaticBlock(Page* page) + AZ_INLINE void PushFreePage(Page* page); + void GarbageCollect(); + inline bool IsInStaticBlock(Page* page) { const char* staticBlockStart = reinterpret_cast(m_staticDataBlock); - const char* staticBlockEnd = staticBlockStart + m_numStaticPages*m_pageSize; + const char* staticBlockEnd = staticBlockStart + m_numStaticPages * m_pageSize; const char* pageAddress = reinterpret_cast(page); // all pages are the same size so we either in or out, no need to check the pageAddressEnd if (pageAddress >= staticBlockStart && pageAddress < staticBlockEnd) @@ -126,21 +125,22 @@ namespace AZ return false; } } - inline Page* ConstructPage(size_t elementSize) + inline Page* ConstructPage(size_t elementSize) { AZ_Assert(m_isDynamic, "We run out of static pages (%d) and this is a static allocator!", m_numStaticPages); // We store the page struct at the end of the block char* memBlock; - memBlock = reinterpret_cast(m_pageAllocator->Allocate(m_pageSize, m_pageSize, 0, "AZSystem::PoolSchemaImpl::ConstructPage", __FILE__, __LINE__)); + memBlock = reinterpret_cast( + m_pageAllocator->Allocate(m_pageSize, m_pageSize, 0, "AZSystem::PoolSchemaImpl::ConstructPage", __FILE__, __LINE__)); size_t pageDataSize = m_pageSize - sizeof(Page); - Page* page = new(memBlock+pageDataSize)Page(); + Page* page = new (memBlock + pageDataSize) Page(); page->SetupFreeList(elementSize, pageDataSize); page->m_elementSize = static_cast(elementSize); page->m_maxNumElements = static_cast(pageDataSize / elementSize); return page; } - inline void FreePage(Page* page) + inline void FreePage(Page* page) { // TODO: It's optional if we want to check the guard value for corruption, since we are not going // to use this memory. Yet it might be useful to catch bugs. @@ -150,9 +150,9 @@ namespace AZ m_pageAllocator->DeAllocate(memBlock); } - inline Page* PageFromAddress(void* address) + inline Page* PageFromAddress(void* address) { - char* memBlock = reinterpret_cast(reinterpret_cast(address) & ~(m_pageSize-1)); + char* memBlock = reinterpret_cast(reinterpret_cast(address) & ~(m_pageSize - 1)); memBlock += m_pageSize - sizeof(Page); Page* page = reinterpret_cast(memBlock); if (!page->m_magic.Validate()) @@ -163,18 +163,18 @@ namespace AZ } using AllocatorType = PoolAllocation; - IAllocatorAllocate* m_pageAllocator; - AllocatorType m_allocator; - void* m_staticDataBlock; - unsigned int m_numStaticPages; - bool m_isDynamic; - size_t m_pageSize; - Bucket::PageListType m_freePages; + IAllocatorAllocate* m_pageAllocator; + AllocatorType m_allocator; + void* m_staticDataBlock; + unsigned int m_numStaticPages; + bool m_isDynamic; + size_t m_pageSize; + Bucket::PageListType m_freePages; }; /** - * Thread safe pool allocator. - */ + * Thread safe pool allocator. + */ class ThreadPoolSchemaImpl { public: @@ -183,18 +183,20 @@ namespace AZ /** * Specialized \ref PoolAllocator::Page page for lock free allocator. */ - struct Page - : public AZStd::intrusive_list_node + struct Page : public AZStd::intrusive_list_node { Page(ThreadPoolData* threadData) - : m_threadData(threadData) {} + : m_threadData(threadData) + { + } - struct FakeNode - : public AZStd::intrusive_slist_node - {}; + struct FakeNode : public AZStd::intrusive_slist_node + { + }; // Fake Lock Free node used when we delete an element from another thread. - struct FakeNodeLF - : public AZStd::lock_free_intrusive_stack_node{}; + struct FakeNodeLF : public AZStd::lock_free_intrusive_stack_node + { + }; void SetupFreeList(size_t elementSize, size_t pageDataBlockSize); @@ -202,8 +204,8 @@ namespace AZ using FreeListType = AZStd::intrusive_slist>; FreeListType m_freeList; - AZStd::lock_free_intrusive_stack_node m_lfStack; ///< Lock Free stack node - struct ThreadPoolData* m_threadData; ///< The thread data that own's the page. + AZStd::lock_free_intrusive_stack_node m_lfStack; ///< Lock Free stack node + struct ThreadPoolData* m_threadData; ///< The thread data that own's the page. u32 m_bin; Debug::Magic32 m_magic; u32 m_elementSize; @@ -211,31 +213,34 @@ namespace AZ }; /** - * A bucket has a list of pages used with the specific pool size. - */ + * A bucket has a list of pages used with the specific pool size. + */ struct Bucket { using PageListType = AZStd::intrusive_list>; - PageListType m_pages; + PageListType m_pages; }; - ThreadPoolSchemaImpl(const ThreadPoolSchema::Descriptor& desc, ThreadPoolSchema::GetThreadPoolData threadPoolGetter, ThreadPoolSchema::SetThreadPoolData threadPoolSetter); + ThreadPoolSchemaImpl( + const ThreadPoolSchema::Descriptor& desc, + ThreadPoolSchema::GetThreadPoolData threadPoolGetter, + ThreadPoolSchema::SetThreadPoolData threadPoolSetter); ~ThreadPoolSchemaImpl(); - ThreadPoolSchema::pointer_type Allocate(ThreadPoolSchema::size_type byteSize, ThreadPoolSchema::size_type alignment, int flags = 0); - void DeAllocate(ThreadPoolSchema::pointer_type ptr); - ThreadPoolSchema::size_type AllocationSize(ThreadPoolSchema::pointer_type ptr); + ThreadPoolSchema::pointer_type Allocate(ThreadPoolSchema::size_type byteSize, ThreadPoolSchema::size_type alignment, int flags = 0); + void DeAllocate(ThreadPoolSchema::pointer_type ptr); + ThreadPoolSchema::size_type AllocationSize(ThreadPoolSchema::pointer_type ptr); /// Return unused memory to the OS. Don't call this too often because you will force unnecessary allocations. - void GarbageCollect(); + void GarbageCollect(); ////////////////////////////////////////////////////////////////////////// // Functions used by PoolAllocation template AZ_INLINE Page* PopFreePage(); - AZ_INLINE void PushFreePage(Page* page); - inline bool IsInStaticBlock(Page* page) + AZ_INLINE void PushFreePage(Page* page); + inline bool IsInStaticBlock(Page* page) { const char* staticBlockStart = reinterpret_cast(m_staticDataBlock); - const char* staticBlockEnd = staticBlockStart + m_numStaticPages*m_pageSize; + const char* staticBlockEnd = staticBlockStart + m_numStaticPages * m_pageSize; const char* pageAddress = reinterpret_cast(page); // all pages are the same size so we either in or out, no need to check the pageAddressEnd if (pageAddress > staticBlockStart && pageAddress < staticBlockEnd) @@ -247,33 +252,34 @@ namespace AZ return false; } } - inline Page* ConstructPage(size_t elementSize) + inline Page* ConstructPage(size_t elementSize) { AZ_Assert(m_isDynamic, "We run out of static pages (%d) and this is a static allocator!", m_numStaticPages); // We store the page struct at the end of the block char* memBlock; - memBlock = reinterpret_cast(m_pageAllocator->Allocate(m_pageSize, m_pageSize, 0, "AZSystem::ThreadPoolSchema::ConstructPage", __FILE__, __LINE__)); + memBlock = reinterpret_cast( + m_pageAllocator->Allocate(m_pageSize, m_pageSize, 0, "AZSystem::ThreadPoolSchema::ConstructPage", __FILE__, __LINE__)); size_t pageDataSize = m_pageSize - sizeof(Page); - Page* page = new(memBlock+pageDataSize)Page(m_threadPoolGetter()); + Page* page = new (memBlock + pageDataSize) Page(m_threadPoolGetter()); page->SetupFreeList(elementSize, pageDataSize); page->m_elementSize = static_cast(elementSize); page->m_maxNumElements = static_cast(pageDataSize / elementSize); return page; } - inline void FreePage(Page* page) + inline void FreePage(Page* page) { // TODO: It's optional if we want to check the guard value for corruption, since we are not going // to use this memory. Yet it might be useful to catch bugs. // We store the page struct at the end of the block char* memBlock = reinterpret_cast(page) - m_pageSize + sizeof(Page); - page->~Page(); // destroy the page + page->~Page(); // destroy the page m_pageAllocator->DeAllocate(memBlock); } - inline Page* PageFromAddress(void* address) + inline Page* PageFromAddress(void* address) { - char* memBlock = reinterpret_cast(reinterpret_cast(address) & ~static_cast(m_pageSize-1)); + char* memBlock = reinterpret_cast(reinterpret_cast(address) & ~static_cast(m_pageSize - 1)); memBlock += m_pageSize - sizeof(Page); Page* page = reinterpret_cast(memBlock); if (!page->m_magic.Validate()) @@ -292,18 +298,18 @@ namespace AZ // Fox X64 we push/pop pages using the m_mutex to sync. Pages are using FreePagesType = Bucket::PageListType; - FreePagesType m_freePages; - AZStd::vector m_threads; ///< Array with all separate thread data. Used to traverse end free elements. - - IAllocatorAllocate* m_pageAllocator; - void* m_staticDataBlock; - size_t m_numStaticPages; - size_t m_pageSize; - size_t m_minAllocationSize; - size_t m_maxAllocationSize; - bool m_isDynamic; + FreePagesType m_freePages; + AZStd::vector m_threads; ///< Array with all separate thread data. Used to traverse end free elements. + + IAllocatorAllocate* m_pageAllocator; + void* m_staticDataBlock; + size_t m_numStaticPages; + size_t m_pageSize; + size_t m_minAllocationSize; + size_t m_maxAllocationSize; + bool m_isDynamic; // TODO rbbaklov Changed to recursive_mutex from mutex for Linux support. - AZStd::recursive_mutex m_mutex; + AZStd::recursive_mutex m_mutex; }; struct ThreadPoolData @@ -315,1090 +321,1088 @@ namespace AZ using AllocatorType = PoolAllocation; /** - * Stack with freed elements from other threads. We don't need stamped stack since the ABA problem can not - * happen here. We push from many threads and pop from only one (we don't push from it). - */ - using FreedElementsStack = AZStd::lock_free_intrusive_stack>; + * Stack with freed elements from other threads. We don't need stamped stack since the ABA problem can not + * happen here. We push from many threads and pop from only one (we don't push from it). + */ + using FreedElementsStack = AZStd::lock_free_intrusive_stack< + ThreadPoolSchemaImpl::Page::FakeNodeLF, + AZStd::lock_free_intrusive_stack_base_hook>; - AllocatorType m_allocator; - FreedElementsStack m_freedElements; + AllocatorType m_allocator; + FreedElementsStack m_freedElements; }; -} - -using namespace AZ; - -//========================================================================= -// PoolAllocation -// [9/09/2009] -//========================================================================= -template -PoolAllocation::PoolAllocation(Allocator* alloc, size_t pageSize, size_t minAllocationSize, size_t maxAllocationSize) - : m_allocator(alloc) - , m_pageSize(pageSize) - , m_numBytesAllocated(0) -{ - AZ_Assert(alloc->m_pageAllocator, "We need the page allocator setup!"); - AZ_Assert(pageSize >= maxAllocationSize * 4, "We need to fit at least 4 objects in a pool! Increase your page size! Page %d MaxAllocationSize %d",pageSize,maxAllocationSize); - AZ_Assert(minAllocationSize == maxAllocationSize || ((minAllocationSize)&(minAllocationSize - 1)) == 0, "Min allocation should be either equal to max allocation size or power of two"); - - m_minAllocationSize = AZ::GetMax(minAllocationSize, size_t(8)); - m_maxAllocationSize = AZ::GetMax(maxAllocationSize, minAllocationSize); +} // namespace AZ - m_minAllocationShift = 0; - for (size_t i = 1; i < sizeof(unsigned int)*8; i++) +namespace AZ +{ + //========================================================================= + // PoolAllocation + // [9/09/2009] + //========================================================================= + template + PoolAllocation::PoolAllocation(Allocator* alloc, size_t pageSize, size_t minAllocationSize, size_t maxAllocationSize) + : m_allocator(alloc) + , m_pageSize(pageSize) + , m_numBytesAllocated(0) { - if (m_minAllocationSize >> i == 0) + AZ_Assert(alloc->m_pageAllocator, "We need the page allocator setup!"); + AZ_Assert( + pageSize >= maxAllocationSize * 4, + "We need to fit at least 4 objects in a pool! Increase your page size! Page %d MaxAllocationSize %d", pageSize, + maxAllocationSize); + AZ_Assert( + minAllocationSize == maxAllocationSize || ((minAllocationSize) & (minAllocationSize - 1)) == 0, + "Min allocation should be either equal to max allocation size or power of two"); + + m_minAllocationSize = AZ::GetMax(minAllocationSize, size_t(8)); + m_maxAllocationSize = AZ::GetMax(maxAllocationSize, minAllocationSize); + + m_minAllocationShift = 0; + for (size_t i = 1; i < sizeof(unsigned int) * 8; i++) { - m_minAllocationShift = i-1; - break; + if (m_minAllocationSize >> i == 0) + { + m_minAllocationShift = i - 1; + break; + } + } + + AZ_Assert( + m_maxAllocationSize % m_minAllocationSize == 0, + "You need to be able to divide m_maxAllocationSize (%d) / m_minAllocationSize (%d) without fraction!", m_maxAllocationSize, + m_minAllocationSize); + m_numBuckets = m_maxAllocationSize / m_minAllocationSize; + AZ_Assert(m_numBuckets <= 0xffff, "You can't have more than 65535 number of buckets! We need to increase the index size!"); + m_buckets = reinterpret_cast( + alloc->m_pageAllocator->Allocate(sizeof(BucketType) * m_numBuckets, AZStd::alignment_of::value)); + for (size_t i = 0; i < m_numBuckets; ++i) + { + new (m_buckets + i) BucketType(); } } - AZ_Assert(m_maxAllocationSize % m_minAllocationSize == 0, "You need to be able to divide m_maxAllocationSize (%d) / m_minAllocationSize (%d) without fraction!", m_maxAllocationSize, m_minAllocationSize); - m_numBuckets = m_maxAllocationSize / m_minAllocationSize; - AZ_Assert(m_numBuckets <= 0xffff, "You can't have more than 65535 number of buckets! We need to increase the index size!"); - m_buckets = reinterpret_cast(alloc->m_pageAllocator->Allocate(sizeof(BucketType)*m_numBuckets, AZStd::alignment_of::value)); - for (size_t i = 0; i < m_numBuckets; ++i) + //========================================================================= + // ~PoolAllocation + // [9/09/2009] + //========================================================================= + template + PoolAllocation::~PoolAllocation() { - new(m_buckets + i)BucketType(); + GarbageCollect(true); + + for (size_t i = 0; i < m_numBuckets; ++i) + { + m_buckets[i].~BucketType(); + } + m_allocator->m_pageAllocator->DeAllocate(m_buckets, sizeof(BucketType) * m_numBuckets); } -} - -//========================================================================= -// ~PoolAllocation -// [9/09/2009] -//========================================================================= -template -PoolAllocation::~PoolAllocation() -{ - GarbageCollect(true); - for (size_t i = 0; i < m_numBuckets; ++i) + //========================================================================= + // Allocate + // [9/09/2009] + //========================================================================= + template + AZ_INLINE void* PoolAllocation::Allocate(size_t byteSize, size_t alignment) { - m_buckets[i].~BucketType(); - } - m_allocator->m_pageAllocator->DeAllocate(m_buckets, sizeof(BucketType) * m_numBuckets); -} - -//========================================================================= -// Allocate -// [9/09/2009] -//========================================================================= -template -AZ_INLINE void* -PoolAllocation::Allocate(size_t byteSize, size_t alignment) -{ - AZ_Assert(byteSize>0, "You can not allocate 0 bytes!"); - AZ_Assert(alignment>0&&(alignment&(alignment-1))==0, "Alignment must be >0 and power of 2!"); + AZ_Assert(byteSize > 0, "You can not allocate 0 bytes!"); + AZ_Assert(alignment > 0 && (alignment & (alignment - 1)) == 0, "Alignment must be >0 and power of 2!"); - // pad the size to the min allocation size. - byteSize = AZ::SizeAlignUp(byteSize, m_minAllocationSize); - byteSize = AZ::SizeAlignUp(byteSize, alignment); + // pad the size to the min allocation size. + byteSize = AZ::SizeAlignUp(byteSize, m_minAllocationSize); + byteSize = AZ::SizeAlignUp(byteSize, alignment); - if (byteSize > m_maxAllocationSize) - { - AZ_Assert(false, "Allocation size (%d) is too big (max: %d) for pools!", byteSize, m_maxAllocationSize); - return nullptr; + if (byteSize > m_maxAllocationSize) + { + AZ_Assert(false, "Allocation size (%d) is too big (max: %d) for pools!", byteSize, m_maxAllocationSize); + return nullptr; + } + + u32 bucketIndex = static_cast((byteSize >> m_minAllocationShift) - 1); + BucketType& bucket = m_buckets[bucketIndex]; + PageType* page = nullptr; + if (!bucket.m_pages.empty()) + { + page = &bucket.m_pages.front(); + + // check if we have free slot in the page + if (page->m_freeList.empty()) + { + page = nullptr; + } + else if (page->m_freeList.size() == 1) + { + // if we have only 1 free slot this allocation will + // fill the page, so put in on the back + bucket.m_pages.pop_front(); + bucket.m_pages.push_back(*page); + } + } + if (!page) + { + page = m_allocator->PopFreePage(); + if (page) + { + // We have any pages available on free page stack. + if (page->m_bin != bucketIndex) // if this page was used the same bucket we are ready to roll. + { + size_t elementSize = byteSize; + size_t pageDataSize = m_pageSize - sizeof(PageType); + page->SetupFreeList(elementSize, pageDataSize); + page->m_bin = bucketIndex; + page->m_elementSize = static_cast(elementSize); + page->m_maxNumElements = static_cast(pageDataSize / elementSize); + } + } + else + { + // We need to align each page on it's size, this way we can quickly find which page the pointer belongs to. + page = m_allocator->ConstructPage(byteSize); + page->m_bin = bucketIndex; + } + bucket.m_pages.push_front(*page); + } + + // The data address and the fake node address are shared. + void* address = &page->m_freeList.front(); + page->m_freeList.pop_front(); + + m_numBytesAllocated += byteSize; + + return address; } - u32 bucketIndex = static_cast((byteSize >> m_minAllocationShift)-1); - BucketType& bucket = m_buckets[bucketIndex]; - PageType* page = nullptr; - if (!bucket.m_pages.empty()) + //========================================================================= + // DeAllocate + // [9/09/2009] + //========================================================================= + template + AZ_INLINE void PoolAllocation::DeAllocate(void* ptr) { - page = &bucket.m_pages.front(); + PageType* page = m_allocator->PageFromAddress(ptr); + if (page == nullptr) + { + AZ_Error("Memory", false, "Address 0x%08x is not in the ThreadPool!", ptr); + return; + } - // check if we have free slot in the page - if (page->m_freeList.empty()) + // (pageSize - info struct at the end) / (element size) + size_t maxElementsPerBucket = page->m_maxNumElements; + + size_t numFreeNodes = page->m_freeList.size(); + typename PageType::FakeNode* node = new (ptr) typename PageType::FakeNode(); + page->m_freeList.push_front(*node); + + if (numFreeNodes == 0) { - page = nullptr; + // if the page was full before sort at the front + BucketType& bucket = m_buckets[page->m_bin]; + bucket.m_pages.erase(*page); + bucket.m_pages.push_front(*page); } - else if (page->m_freeList.size()==1) + else if (numFreeNodes == maxElementsPerBucket - 1) { - // if we have only 1 free slot this allocation will - // fill the page, so put in on the back - bucket.m_pages.pop_front(); - bucket.m_pages.push_back(*page); + // push to the list of free pages + BucketType& bucket = m_buckets[page->m_bin]; + PageType* frontPage = &bucket.m_pages.front(); + if (frontPage != page) + { + bucket.m_pages.erase(*page); + // check if the front page is full if so push the free page to the front otherwise push + // push it on the free pages list so it can be reused by other bins. + if (frontPage->m_freeList.empty()) + { + bucket.m_pages.push_front(*page); + } + else + { + m_allocator->PushFreePage(page); + } + } + else if (frontPage->m_next != nullptr) + { + // if the next page has free slots free the current page + if (frontPage->m_next->m_freeList.size() < maxElementsPerBucket) + { + bucket.m_pages.erase(*page); + m_allocator->PushFreePage(page); + } + } } + + m_numBytesAllocated -= page->m_elementSize; } - if (!page) + + //========================================================================= + // AllocationSize + // [11/22/2010] + //========================================================================= + template + AZ_INLINE size_t PoolAllocation::AllocationSize(void* ptr) { - page = m_allocator->PopFreePage(); + PageType* page = m_allocator->PageFromAddress(ptr); + size_t elementSize; if (page) { - // We have any pages available on free page stack. - if (page->m_bin != bucketIndex) // if this page was used the same bucket we are ready to roll. + elementSize = page->m_elementSize; + } + else + { + elementSize = 0; + } + + return elementSize; + } + + //========================================================================= + // GarbageCollect + // [3/1/2012] + //========================================================================= + template + AZ_INLINE void PoolAllocation::GarbageCollect(bool isForceFreeAllPages) + { + // Free empty pages in the buckets (or better be empty) + for (unsigned int i = 0; i < (unsigned int)m_numBuckets; ++i) + { + // (pageSize - info struct at the end) / (element size) + size_t maxElementsPerBucket = (m_pageSize - sizeof(PageType)) / ((i + 1) << m_minAllocationShift); + + typename BucketType::PageListType& pages = m_buckets[i].m_pages; + while (!pages.empty()) { - size_t elementSize = byteSize; - size_t pageDataSize = m_pageSize - sizeof(PageType); - page->SetupFreeList(elementSize, pageDataSize); - page->m_bin = bucketIndex; - page->m_elementSize = static_cast(elementSize); - page->m_maxNumElements = static_cast(pageDataSize / elementSize); + PageType& page = pages.front(); + pages.pop_front(); + if (page.m_freeList.size() == maxElementsPerBucket || isForceFreeAllPages) + { + if (!m_allocator->IsInStaticBlock(&page)) + { + m_allocator->FreePage(&page); + } + else + { + m_allocator->PushFreePage(&page); + } + } } } - else + } + + ////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////// + // PollAllocator + ////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////// + + //========================================================================= + // PoolSchema + // [9/15/2009] + //========================================================================= + PoolSchema::PoolSchema(const Descriptor& desc) + : m_impl(nullptr) + { + (void)desc; // ignored here, applied in Create() + } + + //========================================================================= + // ~PoolSchema + // [9/15/2009] + //========================================================================= + PoolSchema::~PoolSchema() + { + AZ_Assert(m_impl == nullptr, "You did not destroy the pool schema!"); + delete m_impl; + } + + //========================================================================= + // Create + // [9/15/2009] + //========================================================================= + bool PoolSchema::Create(const Descriptor& desc) + { + AZ_Assert(m_impl == nullptr, "PoolSchema already created!"); + if (m_impl == nullptr) { - // We need to align each page on it's size, this way we can quickly find which page the pointer belongs to. - page = m_allocator->ConstructPage(byteSize); - page->m_bin = bucketIndex; + m_impl = aznew PoolSchemaImpl(desc); } - bucket.m_pages.push_front(*page); + return (m_impl != nullptr); } - // The data address and the fake node address are shared. - void* address = &page->m_freeList.front(); - page->m_freeList.pop_front(); + //========================================================================= + // ~Destroy + // [9/15/2009] + //========================================================================= + bool PoolSchema::Destroy() + { + delete m_impl; + m_impl = nullptr; + return true; + } - m_numBytesAllocated += byteSize; + //========================================================================= + // Allocate + // [9/15/2009] + //========================================================================= + PoolSchema::pointer_type PoolSchema::Allocate( + size_type byteSize, + size_type alignment, + int flags, + const char* name, + const char* fileName, + int lineNum, + unsigned int suppressStackRecord) + { + (void)flags; + (void)name; + (void)fileName; + (void)lineNum; + (void)suppressStackRecord; + return m_impl->Allocate(byteSize, alignment); + } - return address; -} + //========================================================================= + // DeAllocate + // [9/15/2009] + //========================================================================= + void PoolSchema::DeAllocate(pointer_type ptr, size_type byteSize, size_type alignment) + { + (void)byteSize; + (void)alignment; + m_impl->DeAllocate(ptr); + } -//========================================================================= -// DeAllocate -// [9/09/2009] -//========================================================================= -template -AZ_INLINE void -PoolAllocation::DeAllocate(void* ptr) -{ - PageType* page = m_allocator->PageFromAddress(ptr); - if (page==nullptr) + //========================================================================= + // Resize + // [10/14/2018] + //========================================================================= + PoolSchema::size_type PoolSchema::Resize(pointer_type ptr, size_type newSize) { - AZ_Error("Memory", false, "Address 0x%08x is not in the ThreadPool!", ptr); - return; + (void)ptr; + (void)newSize; + return 0; // unsupported } - // (pageSize - info struct at the end) / (element size) - size_t maxElementsPerBucket = page->m_maxNumElements; + //========================================================================= + // ReAllocate + // [10/14/2018] + //========================================================================= + PoolSchema::pointer_type PoolSchema::ReAllocate(pointer_type ptr, size_type newSize, size_type newAlignment) + { + (void)ptr; + (void)newSize; + (void)newAlignment; + AZ_Assert(false, "unsupported"); - size_t numFreeNodes = page->m_freeList.size(); - typename PageType::FakeNode* node = new(ptr) typename PageType::FakeNode(); - page->m_freeList.push_front(*node); + return ptr; + } - if (numFreeNodes==0) + //========================================================================= + // AllocationSize + // [11/22/2010] + //========================================================================= + PoolSchema::size_type PoolSchema::AllocationSize(pointer_type ptr) { - // if the page was full before sort at the front - BucketType& bucket = m_buckets[page->m_bin]; - bucket.m_pages.erase(*page); - bucket.m_pages.push_front(*page); + return m_impl->AllocationSize(ptr); } - else if (numFreeNodes == maxElementsPerBucket-1) + + //========================================================================= + // DeAllocate + // [9/15/2009] + //========================================================================= + void PoolSchema::GarbageCollect() { - // push to the list of free pages - BucketType& bucket = m_buckets[page->m_bin]; - PageType* frontPage = &bucket.m_pages.front(); - if (frontPage != page) + // External requests for garbage collection may come from any thread, and the + // garbage collection operation isn't threadsafe, which can lead to crashes. + // + // Due to the low memory consumption of this allocator in practice on Dragonfly + // (~3kb) it makes sense to not bother with garbage collection and leave it to + // occur exclusively in the destruction of the allocator. + // + // TODO: A better solution needs to be found for integrating back into mainline + // Open 3D Engine. + // m_impl->GarbageCollect(); + } + + auto PoolSchema::GetMaxContiguousAllocationSize() const -> size_type + { + return m_impl->m_allocator.m_maxAllocationSize; + } + + //========================================================================= + // NumAllocatedBytes + // [11/1/2010] + //========================================================================= + PoolSchema::size_type PoolSchema::NumAllocatedBytes() const + { + return m_impl->m_allocator.m_numBytesAllocated; + } + + //========================================================================= + // Capacity + // [11/1/2010] + //========================================================================= + PoolSchema::size_type PoolSchema::Capacity() const + { + return m_impl->m_numStaticPages * m_impl->m_pageSize; + } + + //========================================================================= + // GetPageAllocator + // [11/17/2010] + //========================================================================= + IAllocatorAllocate* PoolSchema::GetSubAllocator() + { + return m_impl->m_pageAllocator; + } + + ////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////// + // PollAllocator Implementation + ////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////// + + //========================================================================= + // PoolSchemaImpl + // [9/15/2009] + //========================================================================= + PoolSchemaImpl::PoolSchemaImpl(const PoolSchema::Descriptor& desc) + : m_pageAllocator(desc.m_pageAllocator ? desc.m_pageAllocator : &AllocatorInstance::Get()) + , m_allocator(this, desc.m_pageSize, desc.m_minAllocationSize, desc.m_maxAllocationSize) + , m_staticDataBlock(nullptr) + , m_numStaticPages(desc.m_numStaticPages) + , m_isDynamic(desc.m_isDynamic) + , m_pageSize(desc.m_pageSize) + { + if (m_numStaticPages) { - bucket.m_pages.erase(*page); - // check if the front page is full if so push the free page to the front otherwise push - // push it on the free pages list so it can be reused by other bins. - if (frontPage->m_freeList.empty()) - { - bucket.m_pages.push_front(*page); - } - else + // We store the page struct at the end of the block + char* memBlock = reinterpret_cast(m_pageAllocator->Allocate( + m_pageSize * m_numStaticPages, m_pageSize, 0, "AZSystem::PoolAllocation::Page static array", __FILE__, __LINE__)); + m_staticDataBlock = memBlock; + size_t pageDataSize = m_pageSize - sizeof(Page); + for (unsigned int i = 0; i < m_numStaticPages; ++i) { - m_allocator->PushFreePage(page); + Page* page = new (memBlock + pageDataSize) Page(); + page->m_bin = 0xffffffff; + page->m_elementSize = 0; + page->m_maxNumElements = 0; + PushFreePage(page); + memBlock += m_pageSize; } } - else if (frontPage->m_next != nullptr) + } + + //========================================================================= + // ~PoolSchemaImpl + // [9/15/2009] + //========================================================================= + PoolSchemaImpl::~PoolSchemaImpl() + { + // Force free all pages + m_allocator.GarbageCollect(true); + + // Free all unused memory + GarbageCollect(); + + if (m_staticDataBlock) { - // if the next page has free slots free the current page - if (frontPage->m_next->m_freeList.size() < maxElementsPerBucket) + while (!m_freePages.empty()) { - bucket.m_pages.erase(*page); - m_allocator->PushFreePage(page); + Page* page = &m_freePages.front(); + (void)page; + m_freePages.pop_front(); + AZ_Assert(IsInStaticBlock(page), "All dynamic pages should be deleted by now!"); + }; + + char* memBlock = reinterpret_cast(m_staticDataBlock); + size_t pageDataSize = m_pageSize - sizeof(Page); + for (unsigned int i = 0; i < m_numStaticPages; ++i) + { + Page* page = reinterpret_cast(memBlock + pageDataSize); + page->~Page(); + memBlock += m_pageSize; } + m_pageAllocator->DeAllocate(m_staticDataBlock); } } - m_numBytesAllocated -= page->m_elementSize; -} + //========================================================================= + // Allocate + // [9/15/2009] + //========================================================================= + PoolSchema::pointer_type PoolSchemaImpl::Allocate(PoolSchema::size_type byteSize, PoolSchema::size_type alignment, int flags) + { + // AZ_Warning("Memory",m_ownerThread==AZStd::this_thread::get_id(),"You can't allocation from a different context/thread, use + // ThreadPoolAllocator!"); + (void)flags; + void* address = m_allocator.Allocate(byteSize, alignment); + return address; + } -//========================================================================= -// AllocationSize -// [11/22/2010] -//========================================================================= -template -AZ_INLINE size_t -PoolAllocation::AllocationSize(void* ptr) -{ - PageType* page = m_allocator->PageFromAddress(ptr); - size_t elementSize; - if (page) + //========================================================================= + // DeAllocate + // [9/15/2009] + //========================================================================= + void PoolSchemaImpl::DeAllocate(PoolSchema::pointer_type ptr) { - elementSize = page->m_elementSize; + // AZ_Warning("Memory",m_ownerThread==AZStd::this_thread::get_id(),"You can't deallocate from a different context/thread, use + // ThreadPoolAllocator!"); + m_allocator.DeAllocate(ptr); } - else + + //========================================================================= + // AllocationSize + // [11/22/2010] + //========================================================================= + PoolSchema::size_type PoolSchemaImpl::AllocationSize(PoolSchema::pointer_type ptr) { - elementSize = 0; + // AZ_Warning("Memory",m_ownerThread==AZStd::this_thread::get_id(),"You can't use PoolAllocator from a different context/thread, use + // ThreadPoolAllocator!"); + return m_allocator.AllocationSize(ptr); } - return elementSize; -} + //========================================================================= + // Pop + // [9/15/2009] + //========================================================================= + AZ_FORCE_INLINE PoolSchemaImpl::Page* PoolSchemaImpl::PopFreePage() + { + Page* page = nullptr; + if (!m_freePages.empty()) + { + page = &m_freePages.front(); + m_freePages.pop_front(); + } + return page; + } -//========================================================================= -// GarbageCollect -// [3/1/2012] -//========================================================================= -template -AZ_INLINE void -PoolAllocation::GarbageCollect(bool isForceFreeAllPages) -{ - // Free empty pages in the buckets (or better be empty) - for (unsigned int i = 0; i < (unsigned int)m_numBuckets; ++i) + //========================================================================= + // Push + // [9/15/2009] + //========================================================================= + AZ_INLINE void PoolSchemaImpl::PushFreePage(Page* page) { - // (pageSize - info struct at the end) / (element size) - size_t maxElementsPerBucket = (m_pageSize - sizeof(PageType)) / ((i+1) << m_minAllocationShift); + m_freePages.push_front(*page); + } - typename BucketType::PageListType& pages = m_buckets[i].m_pages; - while (!pages.empty()) + //========================================================================= + // PurgePages + // [9/11/2009] + //========================================================================= + void PoolSchemaImpl::GarbageCollect() + { + // if( m_ownerThread == AZStd::this_thread::get_id() ) { - PageType& page = pages.front(); - pages.pop_front(); - if (page.m_freeList.size()==maxElementsPerBucket || isForceFreeAllPages) + if (m_isDynamic) { - if (!m_allocator->IsInStaticBlock(&page)) + m_allocator.GarbageCollect(); + + Bucket::PageListType staticPages; + while (!m_freePages.empty()) { - m_allocator->FreePage(&page); + Page* page = &m_freePages.front(); + m_freePages.pop_front(); + if (IsInStaticBlock(page)) + { + staticPages.push_front(*page); + } + else + { + FreePage(page); + } } - else + + while (!staticPages.empty()) { - m_allocator->PushFreePage(&page); + Page* page = &staticPages.front(); + staticPages.pop_front(); + m_freePages.push_front(*page); } } } } -} - -////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////// -// PollAllocator -////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////// - -//========================================================================= -// PoolSchema -// [9/15/2009] -//========================================================================= -PoolSchema::PoolSchema(const Descriptor& desc) - : m_impl(nullptr) -{ - (void)desc; // ignored here, applied in Create() -} - -//========================================================================= -// ~PoolSchema -// [9/15/2009] -//========================================================================= -PoolSchema::~PoolSchema() -{ - AZ_Assert(m_impl==nullptr, "You did not destroy the pool schema!"); - delete m_impl; -} - -//========================================================================= -// Create -// [9/15/2009] -//========================================================================= -bool PoolSchema::Create(const Descriptor& desc) -{ - AZ_Assert(m_impl==nullptr, "PoolSchema already created!"); - if (m_impl == nullptr) - { - m_impl = aznew PoolSchemaImpl(desc); - } - return (m_impl!=nullptr); -} - -//========================================================================= -// ~Destroy -// [9/15/2009] -//========================================================================= -bool PoolSchema::Destroy() -{ - delete m_impl; - m_impl = nullptr; - return true; -} - -//========================================================================= -// Allocate -// [9/15/2009] -//========================================================================= -PoolSchema::pointer_type -PoolSchema::Allocate(size_type byteSize, size_type alignment, int flags, const char* name, const char* fileName, int lineNum, unsigned int suppressStackRecord) -{ - (void)flags; - (void)name; - (void)fileName; - (void)lineNum; - (void)suppressStackRecord; - return m_impl->Allocate(byteSize, alignment); -} - -//========================================================================= -// DeAllocate -// [9/15/2009] -//========================================================================= -void -PoolSchema::DeAllocate(pointer_type ptr, size_type byteSize, size_type alignment) -{ - (void)byteSize; - (void)alignment; - m_impl->DeAllocate(ptr); -} - -//========================================================================= -// Resize -// [10/14/2018] -//========================================================================= -PoolSchema::size_type -PoolSchema::Resize(pointer_type ptr, size_type newSize) -{ - (void)ptr; - (void)newSize; - return 0; // unsupported -} - -//========================================================================= -// ReAllocate -// [10/14/2018] -//========================================================================= -PoolSchema::pointer_type -PoolSchema::ReAllocate(pointer_type ptr, size_type newSize, size_type newAlignment) -{ - (void)ptr; - (void)newSize; - (void)newAlignment; - AZ_Assert(false, "unsupported"); - - return ptr; -} - -//========================================================================= -// AllocationSize -// [11/22/2010] -//========================================================================= -PoolSchema::size_type -PoolSchema::AllocationSize(pointer_type ptr) -{ - return m_impl->AllocationSize(ptr); -} - -//========================================================================= -// DeAllocate -// [9/15/2009] -//========================================================================= -void -PoolSchema::GarbageCollect() -{ - // External requests for garbage collection may come from any thread, and the - // garbage collection operation isn't threadsafe, which can lead to crashes. - // - // Due to the low memory consumption of this allocator in practice on Dragonfly - // (~3kb) it makes sense to not bother with garbage collection and leave it to - // occur exclusively in the destruction of the allocator. - // - // TODO: A better solution needs to be found for integrating back into mainline - // Open 3D Engine. - //m_impl->GarbageCollect(); -} - -auto PoolSchema::GetMaxContiguousAllocationSize() const -> size_type -{ - return m_impl->m_allocator.m_maxAllocationSize; -} - -//========================================================================= -// NumAllocatedBytes -// [11/1/2010] -//========================================================================= -PoolSchema::size_type -PoolSchema::NumAllocatedBytes() const -{ - return m_impl->m_allocator.m_numBytesAllocated; -} - -//========================================================================= -// Capacity -// [11/1/2010] -//========================================================================= -PoolSchema::size_type -PoolSchema::Capacity() const -{ - return m_impl->m_numStaticPages * m_impl->m_pageSize; -} - -//========================================================================= -// GetPageAllocator -// [11/17/2010] -//========================================================================= -IAllocatorAllocate* -PoolSchema::GetSubAllocator() -{ - return m_impl->m_pageAllocator; -} - - -////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////// -// PollAllocator Implementation -////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////// - -//========================================================================= -// PoolSchemaImpl -// [9/15/2009] -//========================================================================= -PoolSchemaImpl::PoolSchemaImpl(const PoolSchema::Descriptor& desc) - : m_pageAllocator(desc.m_pageAllocator ? desc.m_pageAllocator : &AllocatorInstance::Get()) - , m_allocator(this, desc.m_pageSize, desc.m_minAllocationSize, desc.m_maxAllocationSize) - , m_staticDataBlock(nullptr) - , m_numStaticPages(desc.m_numStaticPages) - , m_isDynamic(desc.m_isDynamic) - , m_pageSize(desc.m_pageSize) -{ - if (m_numStaticPages) + + //========================================================================= + // SetupFreeList + // [9/09/2009] + //========================================================================= + AZ_FORCE_INLINE void PoolSchemaImpl::Page::SetupFreeList(size_t elementSize, size_t pageDataBlockSize) { - // We store the page struct at the end of the block - char* memBlock = reinterpret_cast(m_pageAllocator->Allocate(m_pageSize*m_numStaticPages, m_pageSize, 0, "AZSystem::PoolAllocation::Page static array", __FILE__, __LINE__)); - m_staticDataBlock = memBlock; - size_t pageDataSize = m_pageSize - sizeof(Page); - for (unsigned int i = 0; i < m_numStaticPages; ++i) + char* pageData = reinterpret_cast(this) - pageDataBlockSize; + m_freeList.clear(); + // setup free list + size_t numElements = pageDataBlockSize / elementSize; + for (unsigned int i = 0; i < numElements; ++i) { - Page* page = new(memBlock+pageDataSize)Page(); - page->m_bin = 0xffffffff; - page->m_elementSize = 0; - page->m_maxNumElements = 0; - PushFreePage(page); - memBlock += m_pageSize; + char* address = pageData + i * elementSize; + Page::FakeNode* node = new (address) Page::FakeNode(); + m_freeList.push_back(*node); } } -} -//========================================================================= -// ~PoolSchemaImpl -// [9/15/2009] -//========================================================================= -PoolSchemaImpl::~PoolSchemaImpl() -{ - // Force free all pages - m_allocator.GarbageCollect(true); + ////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////// + // ThreadPoolSchema + ////////////////////////////////////////////////////////////////////////// + ////////////////////////////////////////////////////////////////////////// - // Free all unused memory - GarbageCollect(); + //========================================================================= + // ThreadPoolSchema + // [9/15/2009] + //========================================================================= + ThreadPoolSchema::ThreadPoolSchema(GetThreadPoolData getThreadPoolData, SetThreadPoolData setThreadPoolData) + : m_impl(nullptr) + , m_threadPoolGetter(getThreadPoolData) + , m_threadPoolSetter(setThreadPoolData) + { + } - if (m_staticDataBlock) + //========================================================================= + // ~ThreadPoolSchema + // [9/15/2009] + //========================================================================= + ThreadPoolSchema::~ThreadPoolSchema() { - while (!m_freePages.empty()) - { - Page* page = &m_freePages.front(); - (void)page; - m_freePages.pop_front(); - AZ_Assert(IsInStaticBlock(page), "All dynamic pages should be deleted by now!"); - } - ; + AZ_Assert(m_impl == nullptr, "You did not destroy the thread pool schema!"); + delete m_impl; + } - char* memBlock = reinterpret_cast(m_staticDataBlock); - size_t pageDataSize = m_pageSize - sizeof(Page); - for (unsigned int i = 0; i < m_numStaticPages; ++i) + //========================================================================= + // Create + // [9/15/2009] + //========================================================================= + bool ThreadPoolSchema::Create(const Descriptor& desc) + { + AZ_Assert(m_impl == nullptr, "PoolSchema already created!"); + if (m_impl == nullptr) { - Page* page = reinterpret_cast(memBlock+pageDataSize); - page->~Page(); - memBlock += m_pageSize; + m_impl = aznew ThreadPoolSchemaImpl(desc, m_threadPoolGetter, m_threadPoolSetter); } - m_pageAllocator->DeAllocate(m_staticDataBlock); + return (m_impl != nullptr); } -} - -//========================================================================= -// Allocate -// [9/15/2009] -//========================================================================= -PoolSchema::pointer_type -PoolSchemaImpl::Allocate(PoolSchema::size_type byteSize, PoolSchema::size_type alignment, int flags) -{ - //AZ_Warning("Memory",m_ownerThread==AZStd::this_thread::get_id(),"You can't allocation from a different context/thread, use ThreadPoolAllocator!"); - (void)flags; - void* address = m_allocator.Allocate(byteSize, alignment); - return address; -} - -//========================================================================= -// DeAllocate -// [9/15/2009] -//========================================================================= -void -PoolSchemaImpl::DeAllocate(PoolSchema::pointer_type ptr) -{ - //AZ_Warning("Memory",m_ownerThread==AZStd::this_thread::get_id(),"You can't deallocate from a different context/thread, use ThreadPoolAllocator!"); - m_allocator.DeAllocate(ptr); -} - -//========================================================================= -// AllocationSize -// [11/22/2010] -//========================================================================= -PoolSchema::size_type -PoolSchemaImpl::AllocationSize(PoolSchema::pointer_type ptr) -{ - //AZ_Warning("Memory",m_ownerThread==AZStd::this_thread::get_id(),"You can't use PoolAllocator from a different context/thread, use ThreadPoolAllocator!"); - return m_allocator.AllocationSize(ptr); -} - -//========================================================================= -// Pop -// [9/15/2009] -//========================================================================= -AZ_FORCE_INLINE PoolSchemaImpl::Page* -PoolSchemaImpl::PopFreePage() -{ - Page* page = nullptr; - if (!m_freePages.empty()) + + //========================================================================= + // Destroy + // [9/15/2009] + //========================================================================= + bool ThreadPoolSchema::Destroy() { - page = &m_freePages.front(); - m_freePages.pop_front(); + delete m_impl; + m_impl = nullptr; + return true; } - return page; -} - -//========================================================================= -// Push -// [9/15/2009] -//========================================================================= -AZ_INLINE void -PoolSchemaImpl::PushFreePage(Page* page) -{ - m_freePages.push_front(*page); -} - -//========================================================================= -// PurgePages -// [9/11/2009] -//========================================================================= -void -PoolSchemaImpl::GarbageCollect() -{ - //if( m_ownerThread == AZStd::this_thread::get_id() ) + //========================================================================= + // Allocate + // [9/15/2009] + //========================================================================= + ThreadPoolSchema::pointer_type ThreadPoolSchema::Allocate( + size_type byteSize, + size_type alignment, + int flags, + const char* name, + const char* fileName, + int lineNum, + unsigned int suppressStackRecord) { - if (m_isDynamic) - { - m_allocator.GarbageCollect(); + (void)flags; + (void)name; + (void)fileName; + (void)lineNum; + (void)suppressStackRecord; + return m_impl->Allocate(byteSize, alignment); + } - Bucket::PageListType staticPages; - while (!m_freePages.empty()) - { - Page* page = &m_freePages.front(); - m_freePages.pop_front(); - if (IsInStaticBlock(page)) - { - staticPages.push_front(*page); - } - else - { - FreePage(page); - } - } + //========================================================================= + // DeAllocate + // [9/15/2009] + //========================================================================= + void ThreadPoolSchema::DeAllocate(pointer_type ptr, size_type byteSize, size_type alignment) + { + (void)byteSize; + (void)alignment; + m_impl->DeAllocate(ptr); + } - while (!staticPages.empty()) - { - Page* page = &staticPages.front(); - staticPages.pop_front(); - m_freePages.push_front(*page); - } - } + //========================================================================= + // Resize + // [10/14/2018] + //========================================================================= + ThreadPoolSchema::size_type ThreadPoolSchema::Resize(pointer_type ptr, size_type newSize) + { + (void)ptr; + (void)newSize; + return 0; // unsupported } -} - -//========================================================================= -// SetupFreeList -// [9/09/2009] -//========================================================================= -AZ_FORCE_INLINE void -PoolSchemaImpl::Page::SetupFreeList(size_t elementSize, size_t pageDataBlockSize) -{ - char* pageData = reinterpret_cast(this) - pageDataBlockSize; - m_freeList.clear(); - // setup free list - size_t numElements = pageDataBlockSize / elementSize; - for (unsigned int i = 0; i < numElements; ++i) + + //========================================================================= + // ReAllocate + // [10/14/2018] + //========================================================================= + ThreadPoolSchema::pointer_type ThreadPoolSchema::ReAllocate(pointer_type ptr, size_type newSize, size_type newAlignment) { - char* address = pageData+i*elementSize; - Page::FakeNode* node = new(address) Page::FakeNode(); - m_freeList.push_back(*node); + (void)ptr; + (void)newSize; + (void)newAlignment; + AZ_Assert(false, "unsupported"); + + return ptr; } -} - -////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////// -// ThreadPoolSchema -////////////////////////////////////////////////////////////////////////// -////////////////////////////////////////////////////////////////////////// - -//========================================================================= -// ThreadPoolSchema -// [9/15/2009] -//========================================================================= -ThreadPoolSchema::ThreadPoolSchema(GetThreadPoolData getThreadPoolData, SetThreadPoolData setThreadPoolData) - : m_impl(nullptr) - , m_threadPoolGetter(getThreadPoolData) - , m_threadPoolSetter(setThreadPoolData) -{ -} -//========================================================================= -// ~ThreadPoolSchema -// [9/15/2009] -//========================================================================= -ThreadPoolSchema::~ThreadPoolSchema() -{ - AZ_Assert(m_impl==nullptr, "You did not destroy the thread pool schema!"); - delete m_impl; -} - -//========================================================================= -// Create -// [9/15/2009] -//========================================================================= -bool ThreadPoolSchema::Create(const Descriptor& desc) -{ - AZ_Assert(m_impl==nullptr, "PoolSchema already created!"); - if (m_impl == nullptr) + //========================================================================= + // AllocationSize + // [11/22/2010] + //========================================================================= + ThreadPoolSchema::size_type ThreadPoolSchema::AllocationSize(pointer_type ptr) { - m_impl = aznew ThreadPoolSchemaImpl(desc, m_threadPoolGetter, m_threadPoolSetter); + return m_impl->AllocationSize(ptr); } - return (m_impl!=nullptr); -} - -//========================================================================= -// Destroy -// [9/15/2009] -//========================================================================= -bool ThreadPoolSchema::Destroy() -{ - delete m_impl; - m_impl = nullptr; - return true; -} -//========================================================================= -// Allocate -// [9/15/2009] -//========================================================================= -ThreadPoolSchema::pointer_type -ThreadPoolSchema::Allocate(size_type byteSize, size_type alignment, int flags, const char* name, const char* fileName, int lineNum, unsigned int suppressStackRecord) -{ - (void)flags; - (void)name; - (void)fileName; - (void)lineNum; - (void)suppressStackRecord; - return m_impl->Allocate(byteSize, alignment); -} - -//========================================================================= -// DeAllocate -// [9/15/2009] -//========================================================================= -void -ThreadPoolSchema::DeAllocate(pointer_type ptr, size_type byteSize, size_type alignment) -{ - (void)byteSize; - (void)alignment; - m_impl->DeAllocate(ptr); -} - -//========================================================================= -// Resize -// [10/14/2018] -//========================================================================= -ThreadPoolSchema::size_type -ThreadPoolSchema::Resize(pointer_type ptr, size_type newSize) -{ - (void)ptr; - (void)newSize; - return 0; // unsupported -} - -//========================================================================= -// ReAllocate -// [10/14/2018] -//========================================================================= -ThreadPoolSchema::pointer_type -ThreadPoolSchema::ReAllocate(pointer_type ptr, size_type newSize, size_type newAlignment) -{ - (void)ptr; - (void)newSize; - (void)newAlignment; - AZ_Assert(false, "unsupported"); - - return ptr; -} - -//========================================================================= -// AllocationSize -// [11/22/2010] -//========================================================================= -ThreadPoolSchema::size_type -ThreadPoolSchema::AllocationSize(pointer_type ptr) -{ - return m_impl->AllocationSize(ptr); -} - -//========================================================================= -// DeAllocate -// [9/15/2009] -//========================================================================= -void -ThreadPoolSchema::GarbageCollect() -{ - m_impl->GarbageCollect(); -} -auto ThreadPoolSchema::GetMaxContiguousAllocationSize() const -> size_type -{ - return m_impl->m_maxAllocationSize; -} - -//========================================================================= -// NumAllocatedBytes -// [11/1/2010] -//========================================================================= -ThreadPoolSchema::size_type -ThreadPoolSchema::NumAllocatedBytes() const -{ - size_type bytesAllocated = 0; + //========================================================================= + // DeAllocate + // [9/15/2009] + //========================================================================= + void ThreadPoolSchema::GarbageCollect() { - AZStd::lock_guard lock(m_impl->m_mutex); - for (size_t i = 0; i < m_impl->m_threads.size(); ++i) - { - bytesAllocated += m_impl->m_threads[i]->m_allocator.m_numBytesAllocated; - } + m_impl->GarbageCollect(); } - return bytesAllocated; -} - -//========================================================================= -// Capacity -// [11/1/2010] -//========================================================================= -ThreadPoolSchema::size_type -ThreadPoolSchema::Capacity() const -{ - return m_impl->m_numStaticPages * m_impl->m_pageSize; -} - -//========================================================================= -// GetPageAllocator -// [11/17/2010] -//========================================================================= -IAllocatorAllocate* -ThreadPoolSchema::GetSubAllocator() -{ - return m_impl->m_pageAllocator; -} - - -//========================================================================= -// ThreadPoolSchemaImpl -// [9/15/2009] -//========================================================================= -ThreadPoolSchemaImpl::ThreadPoolSchemaImpl(const ThreadPoolSchema::Descriptor& desc, ThreadPoolSchema::GetThreadPoolData threadPoolGetter, ThreadPoolSchema::SetThreadPoolData threadPoolSetter) - : m_threadPoolGetter(threadPoolGetter) - , m_threadPoolSetter(threadPoolSetter) - , m_pageAllocator(desc.m_pageAllocator) - , m_staticDataBlock(nullptr) - , m_numStaticPages(desc.m_numStaticPages) - , m_pageSize(desc.m_pageSize) - , m_minAllocationSize(desc.m_minAllocationSize) - , m_maxAllocationSize(desc.m_maxAllocationSize) - , m_isDynamic(desc.m_isDynamic) -{ -# if AZ_TRAIT_OS_HAS_CRITICAL_SECTION_SPIN_COUNT - // In memory allocation case (usually tools) we might have high contention, - // using spin lock will improve performance. - SetCriticalSectionSpinCount(m_mutex.native_handle(), 4000); -# endif - if (m_pageAllocator == nullptr) + auto ThreadPoolSchema::GetMaxContiguousAllocationSize() const -> size_type { - m_pageAllocator = &AllocatorInstance::Get(); // use the SystemAllocator if no page allocator is provided + return m_impl->m_maxAllocationSize; } - if (m_numStaticPages) + + //========================================================================= + // NumAllocatedBytes + // [11/1/2010] + //========================================================================= + ThreadPoolSchema::size_type ThreadPoolSchema::NumAllocatedBytes() const { - // We store the page struct at the end of the block - char* memBlock = reinterpret_cast(m_pageAllocator->Allocate(m_pageSize*m_numStaticPages, m_pageSize, 0, "AZSystem::ThreadPoolSchemaImpl::Page static array", __FILE__, __LINE__)); - m_staticDataBlock = memBlock; - size_t pageDataSize = m_pageSize - sizeof(Page); - for (unsigned int i = 0; i < m_numStaticPages; ++i) + size_type bytesAllocated = 0; { - Page* page = new(memBlock+pageDataSize)Page(m_threadPoolGetter()); - page->m_bin = 0xffffffff; - PushFreePage(page); - memBlock += m_pageSize; + AZStd::lock_guard lock(m_impl->m_mutex); + for (size_t i = 0; i < m_impl->m_threads.size(); ++i) + { + bytesAllocated += m_impl->m_threads[i]->m_allocator.m_numBytesAllocated; + } } + return bytesAllocated; } -} -//========================================================================= -// ~ThreadPoolSchemaImpl -// [9/15/2009] -//========================================================================= -ThreadPoolSchemaImpl::~ThreadPoolSchemaImpl() -{ - // clean up all the thread data. - // IMPORTANT: We assume/rely that all threads (except the calling one) are or will - // destroyed before you create another instance of the pool allocation. - // This should generally be ok since the all allocators are singletons. + //========================================================================= + // Capacity + // [11/1/2010] + //========================================================================= + ThreadPoolSchema::size_type ThreadPoolSchema::Capacity() const { - AZStd::lock_guard lock(m_mutex); - if (!m_threads.empty()) + return m_impl->m_numStaticPages * m_impl->m_pageSize; + } + + //========================================================================= + // GetPageAllocator + // [11/17/2010] + //========================================================================= + IAllocatorAllocate* ThreadPoolSchema::GetSubAllocator() + { + return m_impl->m_pageAllocator; + } + + //========================================================================= + // ThreadPoolSchemaImpl + // [9/15/2009] + //========================================================================= + ThreadPoolSchemaImpl::ThreadPoolSchemaImpl( + const ThreadPoolSchema::Descriptor& desc, + ThreadPoolSchema::GetThreadPoolData threadPoolGetter, + ThreadPoolSchema::SetThreadPoolData threadPoolSetter) + : m_threadPoolGetter(threadPoolGetter) + , m_threadPoolSetter(threadPoolSetter) + , m_pageAllocator(desc.m_pageAllocator) + , m_staticDataBlock(nullptr) + , m_numStaticPages(desc.m_numStaticPages) + , m_pageSize(desc.m_pageSize) + , m_minAllocationSize(desc.m_minAllocationSize) + , m_maxAllocationSize(desc.m_maxAllocationSize) + , m_isDynamic(desc.m_isDynamic) + { +#if AZ_TRAIT_OS_HAS_CRITICAL_SECTION_SPIN_COUNT + // In memory allocation case (usually tools) we might have high contention, + // using spin lock will improve performance. + SetCriticalSectionSpinCount(m_mutex.native_handle(), 4000); +#endif + + if (m_pageAllocator == nullptr) { - for (size_t i = 0; i < m_threads.size(); ++i) + m_pageAllocator = &AllocatorInstance::Get(); // use the SystemAllocator if no page allocator is provided + } + if (m_numStaticPages) + { + // We store the page struct at the end of the block + char* memBlock = reinterpret_cast(m_pageAllocator->Allocate( + m_pageSize * m_numStaticPages, m_pageSize, 0, "AZSystem::ThreadPoolSchemaImpl::Page static array", __FILE__, __LINE__)); + m_staticDataBlock = memBlock; + size_t pageDataSize = m_pageSize - sizeof(Page); + for (unsigned int i = 0; i < m_numStaticPages; ++i) { - if (m_threads[i]) - { - // Force free all pages - delete m_threads[i]; - } + Page* page = new (memBlock + pageDataSize) Page(m_threadPoolGetter()); + page->m_bin = 0xffffffff; + PushFreePage(page); + memBlock += m_pageSize; } - - /// reset the variable for the owner thread. - m_threadPoolSetter(nullptr); } } - GarbageCollect(); - - if (m_staticDataBlock) + //========================================================================= + // ~ThreadPoolSchemaImpl + // [9/15/2009] + //========================================================================= + ThreadPoolSchemaImpl::~ThreadPoolSchemaImpl() { - Page* page; + // clean up all the thread data. + // IMPORTANT: We assume/rely that all threads (except the calling one) are or will + // destroyed before you create another instance of the pool allocation. + // This should generally be ok since the all allocators are singletons. { AZStd::lock_guard lock(m_mutex); - while (!m_freePages.empty()) + if (!m_threads.empty()) { - page = &m_freePages.front(); - m_freePages.pop_front(); - AZ_Assert(IsInStaticBlock(page), "All dynamic pages should be free by now!"); + for (size_t i = 0; i < m_threads.size(); ++i) + { + if (m_threads[i]) + { + // Force free all pages + delete m_threads[i]; + } + } + + /// reset the variable for the owner thread. + m_threadPoolSetter(nullptr); } } - char* memBlock = reinterpret_cast(m_staticDataBlock); - size_t pageDataSize = m_pageSize - sizeof(Page); - for (unsigned int i = 0; i < m_numStaticPages; ++i) + GarbageCollect(); + + if (m_staticDataBlock) { - page = reinterpret_cast(memBlock+pageDataSize); - page->~Page(); - memBlock += m_pageSize; + Page* page; + { + AZStd::lock_guard lock(m_mutex); + while (!m_freePages.empty()) + { + page = &m_freePages.front(); + m_freePages.pop_front(); + AZ_Assert(IsInStaticBlock(page), "All dynamic pages should be free by now!"); + } + } + + char* memBlock = reinterpret_cast(m_staticDataBlock); + size_t pageDataSize = m_pageSize - sizeof(Page); + for (unsigned int i = 0; i < m_numStaticPages; ++i) + { + page = reinterpret_cast(memBlock + pageDataSize); + page->~Page(); + memBlock += m_pageSize; + } + m_pageAllocator->DeAllocate(m_staticDataBlock); } - m_pageAllocator->DeAllocate(m_staticDataBlock); } -} - -//========================================================================= -// Allocate -// [9/15/2009] -//========================================================================= -ThreadPoolSchema::pointer_type -ThreadPoolSchemaImpl::Allocate(ThreadPoolSchema::size_type byteSize, ThreadPoolSchema::size_type alignment, int flags) -{ - (void)flags; - - ThreadPoolData* threadData = m_threadPoolGetter(); - if (threadData == nullptr) + //========================================================================= + // Allocate + // [9/15/2009] + //========================================================================= + ThreadPoolSchema::pointer_type ThreadPoolSchemaImpl::Allocate( + ThreadPoolSchema::size_type byteSize, ThreadPoolSchema::size_type alignment, int flags) { - threadData = aznew ThreadPoolData(this, m_pageSize, m_minAllocationSize, m_maxAllocationSize); - m_threadPoolSetter(threadData); + (void)flags; + + ThreadPoolData* threadData = m_threadPoolGetter(); + + if (threadData == nullptr) { - AZStd::lock_guard lock(m_mutex); - m_threads.push_back(threadData); + threadData = aznew ThreadPoolData(this, m_pageSize, m_minAllocationSize, m_maxAllocationSize); + m_threadPoolSetter(threadData); + { + AZStd::lock_guard lock(m_mutex); + m_threads.push_back(threadData); + } } - } - else - { - // deallocate elements if they were freed from other threads - Page::FakeNodeLF* fakeLFNode; - while ((fakeLFNode = threadData->m_freedElements.pop())!=nullptr) + else { - threadData->m_allocator.DeAllocate(fakeLFNode); + // deallocate elements if they were freed from other threads + Page::FakeNodeLF* fakeLFNode; + while ((fakeLFNode = threadData->m_freedElements.pop()) != nullptr) + { + threadData->m_allocator.DeAllocate(fakeLFNode); + } } - } - return threadData->m_allocator.Allocate(byteSize, alignment); -} - -//========================================================================= -// DeAllocate -// [9/15/2009] -//========================================================================= -void -ThreadPoolSchemaImpl::DeAllocate(ThreadPoolSchema::pointer_type ptr) -{ - Page* page = PageFromAddress(ptr); - if (page==nullptr) - { - AZ_Error("Memory", false, "Address 0x%08x is not in the ThreadPool!", ptr); - return; + return threadData->m_allocator.Allocate(byteSize, alignment); } - AZ_Assert(page->m_threadData!=nullptr, ("We must have valid page thread data for the page!")); - ThreadPoolData* threadData = m_threadPoolGetter(); - if (threadData == page->m_threadData) - { - // we can free here - threadData->m_allocator.DeAllocate(ptr); - } - else + + //========================================================================= + // DeAllocate + // [9/15/2009] + //========================================================================= + void ThreadPoolSchemaImpl::DeAllocate(ThreadPoolSchema::pointer_type ptr) { - // push this element to be deleted from it's own thread! - // cast the pointer to a fake lock free node - Page::FakeNodeLF* fakeLFNode = reinterpret_cast(ptr); + Page* page = PageFromAddress(ptr); + if (page == nullptr) + { + AZ_Error("Memory", false, "Address 0x%08x is not in the ThreadPool!", ptr); + return; + } + AZ_Assert(page->m_threadData != nullptr, ("We must have valid page thread data for the page!")); + ThreadPoolData* threadData = m_threadPoolGetter(); + if (threadData == page->m_threadData) + { + // we can free here + threadData->m_allocator.DeAllocate(ptr); + } + else + { + // push this element to be deleted from it's own thread! + // cast the pointer to a fake lock free node + Page::FakeNodeLF* fakeLFNode = reinterpret_cast(ptr); #ifdef AZ_DEBUG_BUILD - // we need to reset the fakeLFNode because we share the memory. - // otherwise we will assert the node is in the list - fakeLFNode->m_next = 0; + // we need to reset the fakeLFNode because we share the memory. + // otherwise we will assert the node is in the list + fakeLFNode->m_next = 0; #endif - page->m_threadData->m_freedElements.push(*fakeLFNode); + page->m_threadData->m_freedElements.push(*fakeLFNode); + } } -} - -//========================================================================= -// AllocationSize -// [11/22/2010] -//========================================================================= -ThreadPoolSchema::size_type -ThreadPoolSchemaImpl::AllocationSize(ThreadPoolSchema::pointer_type ptr) -{ - Page* page = PageFromAddress(ptr); - if (page==nullptr) + + //========================================================================= + // AllocationSize + // [11/22/2010] + //========================================================================= + ThreadPoolSchema::size_type ThreadPoolSchemaImpl::AllocationSize(ThreadPoolSchema::pointer_type ptr) { - return 0; + Page* page = PageFromAddress(ptr); + if (page == nullptr) + { + return 0; + } + AZ_Assert(page->m_threadData != nullptr, ("We must have valid page thread data for the page!")); + return page->m_threadData->m_allocator.AllocationSize(ptr); } - AZ_Assert(page->m_threadData!=nullptr, ("We must have valid page thread data for the page!")); - return page->m_threadData->m_allocator.AllocationSize(ptr); -} - -//========================================================================= -// PopFreePage -// [9/15/2009] -//========================================================================= -AZ_INLINE ThreadPoolSchemaImpl::Page* -ThreadPoolSchemaImpl::PopFreePage() -{ - Page* page; + + //========================================================================= + // PopFreePage + // [9/15/2009] + //========================================================================= + AZ_INLINE ThreadPoolSchemaImpl::Page* ThreadPoolSchemaImpl::PopFreePage() { - AZStd::lock_guard lock(m_mutex); - if (m_freePages.empty()) + Page* page; { - page = nullptr; + AZStd::lock_guard lock(m_mutex); + if (m_freePages.empty()) + { + page = nullptr; + } + else + { + page = &m_freePages.front(); + m_freePages.pop_front(); + } } - else + if (page) { - page = &m_freePages.front(); - m_freePages.pop_front(); +#ifdef AZ_DEBUG_BUILD + AZ_Assert(page->m_threadData == 0, "If we stored the free page properly we should have null here!"); +#endif + // store the current thread data, used when we free elements + page->m_threadData = m_threadPoolGetter(); } + return page; } - if (page) + + //========================================================================= + // PushFreePage + // [9/15/2009] + //========================================================================= + AZ_INLINE void ThreadPoolSchemaImpl::PushFreePage(Page* page) { -# ifdef AZ_DEBUG_BUILD - AZ_Assert(page->m_threadData == 0, "If we stored the free page properly we should have null here!"); -# endif - // store the current thread data, used when we free elements - page->m_threadData = m_threadPoolGetter(); - } - return page; -} - -//========================================================================= -// PushFreePage -// [9/15/2009] -//========================================================================= -AZ_INLINE void -ThreadPoolSchemaImpl::PushFreePage(Page* page) -{ #ifdef AZ_DEBUG_BUILD - page->m_threadData = 0; + page->m_threadData = 0; #endif - { - AZStd::lock_guard lock(m_mutex); - m_freePages.push_front(*page); - } -} - -//========================================================================= -// GarbageCollect -// [9/15/2009] -//========================================================================= -void -ThreadPoolSchemaImpl::GarbageCollect() -{ - if (!m_isDynamic) - { - return; // we have the memory statically allocated, can't collect garbage. + { + AZStd::lock_guard lock(m_mutex); + m_freePages.push_front(*page); + } } - FreePagesType staticPages; - AZStd::lock_guard lock(m_mutex); - while (!m_freePages.empty()) + //========================================================================= + // GarbageCollect + // [9/15/2009] + //========================================================================= + void ThreadPoolSchemaImpl::GarbageCollect() { - Page* page = &m_freePages.front(); - m_freePages.pop_front(); - if (IsInStaticBlock(page)) + if (!m_isDynamic) { - staticPages.push_front(*page); + return; // we have the memory statically allocated, can't collect garbage. } - else + + FreePagesType staticPages; + AZStd::lock_guard lock(m_mutex); + while (!m_freePages.empty()) + { + Page* page = &m_freePages.front(); + m_freePages.pop_front(); + if (IsInStaticBlock(page)) + { + staticPages.push_front(*page); + } + else + { + FreePage(page); + } + } + while (!staticPages.empty()) { - FreePage(page); + Page* page = &staticPages.front(); + staticPages.pop_front(); + m_freePages.push_front(*page); } } - while (!staticPages.empty()) + + //========================================================================= + // SetupFreeList + // [9/15/2009] + //========================================================================= + inline void ThreadPoolSchemaImpl::Page::SetupFreeList(size_t elementSize, size_t pageDataBlockSize) { - Page* page = &staticPages.front(); - staticPages.pop_front(); - m_freePages.push_front(*page); + char* pageData = reinterpret_cast(this) - pageDataBlockSize; + m_freeList.clear(); + // setup free list + size_t numElements = pageDataBlockSize / elementSize; + for (size_t i = 0; i < numElements; ++i) + { + char* address = pageData + i * elementSize; + Page::FakeNode* node = new (address) Page::FakeNode(); + m_freeList.push_back(*node); + } } -} - -//========================================================================= -// SetupFreeList -// [9/15/2009] -//========================================================================= -inline void -ThreadPoolSchemaImpl::Page::SetupFreeList(size_t elementSize, size_t pageDataBlockSize) -{ - char* pageData = reinterpret_cast(this) - pageDataBlockSize; - m_freeList.clear(); - // setup free list - size_t numElements = pageDataBlockSize / elementSize; - for (size_t i = 0; i < numElements; ++i) + + //========================================================================= + // ThreadPoolData::ThreadPoolData + // [9/15/2009] + //========================================================================= + ThreadPoolData::ThreadPoolData(ThreadPoolSchemaImpl* alloc, size_t pageSize, size_t minAllocationSize, size_t maxAllocationSize) + : m_allocator(alloc, pageSize, minAllocationSize, maxAllocationSize) { - char* address = pageData+i*elementSize; - Page::FakeNode* node = new(address) Page::FakeNode(); - m_freeList.push_back(*node); } -} - -//========================================================================= -// ThreadPoolData::ThreadPoolData -// [9/15/2009] -//========================================================================= -ThreadPoolData::ThreadPoolData(ThreadPoolSchemaImpl* alloc, size_t pageSize, size_t minAllocationSize, size_t maxAllocationSize) - : m_allocator(alloc, pageSize, minAllocationSize, maxAllocationSize) -{} - -//========================================================================= -// ThreadPoolData::~ThreadPoolData -// [9/15/2009] -//========================================================================= -ThreadPoolData::~ThreadPoolData() -{ - // deallocate elements if they were freed from other threads - ThreadPoolSchemaImpl::Page::FakeNodeLF* fakeLFNode; - while ((fakeLFNode = m_freedElements.pop())!=nullptr) + + //========================================================================= + // ThreadPoolData::~ThreadPoolData + // [9/15/2009] + //========================================================================= + ThreadPoolData::~ThreadPoolData() { - m_allocator.DeAllocate(fakeLFNode); + // deallocate elements if they were freed from other threads + ThreadPoolSchemaImpl::Page::FakeNodeLF* fakeLFNode; + while ((fakeLFNode = m_freedElements.pop()) != nullptr) + { + m_allocator.DeAllocate(fakeLFNode); + } } -} + +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Memory/PoolSchema.h b/Code/Framework/AzCore/AzCore/Memory/PoolSchema.h index cfc5e3ea07..ef38dcf24f 100644 --- a/Code/Framework/AzCore/AzCore/Memory/PoolSchema.h +++ b/Code/Framework/AzCore/AzCore/Memory/PoolSchema.h @@ -5,8 +5,7 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef AZ_POOL_ALLOCATION_SCHEME_H -#define AZ_POOL_ALLOCATION_SCHEME_H +#pragma once #include @@ -164,8 +163,3 @@ namespace AZ template AZ_THREAD_LOCAL ThreadPoolData* ThreadPoolSchemaHelper::m_threadData = 0; } - -#endif // AZ_POOL_ALLOCATION_SCHEME_H -#pragma once - - diff --git a/Code/Framework/AzCore/AzCore/Memory/SystemAllocator.cpp b/Code/Framework/AzCore/AzCore/Memory/SystemAllocator.cpp index ddcc046b8e..41099f7a38 100644 --- a/Code/Framework/AzCore/AzCore/Memory/SystemAllocator.cpp +++ b/Code/Framework/AzCore/AzCore/Memory/SystemAllocator.cpp @@ -18,299 +18,289 @@ #define AZCORE_SYSTEM_ALLOCATOR_HPHA 1 #define AZCORE_SYSTEM_ALLOCATOR_MALLOC 2 -#define AZCORE_SYSTEM_ALLOCATOR_HEAP 3 #if !defined(AZCORE_SYSTEM_ALLOCATOR) - // define the default - #define AZCORE_SYSTEM_ALLOCATOR AZCORE_SYSTEM_ALLOCATOR_HPHA +// define the default +#define AZCORE_SYSTEM_ALLOCATOR AZCORE_SYSTEM_ALLOCATOR_HPHA #endif #if AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HPHA #include #elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_MALLOC #include -#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HEAP - #include #else #error "Invalid allocator selected for SystemAllocator" #endif - -using namespace AZ; - -////////////////////////////////////////////////////////////////////////// -// Globals - we use global storage for the first memory schema, since we can't use dynamic memory! -static bool g_isSystemSchemaUsed = false; +namespace AZ +{ + ////////////////////////////////////////////////////////////////////////// + // Globals - we use global storage for the first memory schema, since we can't use dynamic memory! + static bool g_isSystemSchemaUsed = false; #if AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HPHA static AZStd::aligned_storage::value>::type g_systemSchema; #elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_MALLOC static AZStd::aligned_storage::value>::type g_systemSchema; -#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HEAP - static AZStd::aligned_storage::value>::type g_systemSchema; #endif -////////////////////////////////////////////////////////////////////////// - -//========================================================================= -// SystemAllocator -// [9/2/2009] -//========================================================================= -SystemAllocator::SystemAllocator() - : AllocatorBase(this, "SystemAllocator", "Fundamental generic memory allocator") - , m_isCustom(false) - , m_allocator(nullptr) - , m_ownsOSAllocator(false) -{ -} - -//========================================================================= -// ~SystemAllocator -//========================================================================= -SystemAllocator::~SystemAllocator() -{ - if (IsReady()) + ////////////////////////////////////////////////////////////////////////// + + //========================================================================= + // SystemAllocator + // [9/2/2009] + //========================================================================= + SystemAllocator::SystemAllocator() + : AllocatorBase(this, "SystemAllocator", "Fundamental generic memory allocator") + , m_isCustom(false) + , m_allocator(nullptr) + , m_ownsOSAllocator(false) { - Destroy(); } -} - -//========================================================================= -// ~Create -// [9/2/2009] -//========================================================================= -bool -SystemAllocator::Create(const Descriptor& desc) -{ - AZ_Assert(IsReady() == false, "System allocator was already created!"); - if (IsReady()) - { - return false; - } - - m_desc = desc; - if (!AllocatorInstance::IsReady()) + //========================================================================= + // ~SystemAllocator + //========================================================================= + SystemAllocator::~SystemAllocator() { - m_ownsOSAllocator = true; - AllocatorInstance::Create(); - } - bool isReady = false; - if (desc.m_custom) - { - m_isCustom = true; - m_allocator = desc.m_custom; - isReady = true; + if (IsReady()) + { + Destroy(); + } } - else + + //========================================================================= + // ~Create + // [9/2/2009] + //========================================================================= + bool SystemAllocator::Create(const Descriptor& desc) { - m_isCustom = false; -#if AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HPHA - HphaSchema::Descriptor heapDesc; - heapDesc.m_pageSize = desc.m_heap.m_pageSize; - heapDesc.m_poolPageSize = desc.m_heap.m_poolPageSize; - AZ_Assert(desc.m_heap.m_numFixedMemoryBlocks <= 1, "We support max1 memory block at the moment!"); - if (desc.m_heap.m_numFixedMemoryBlocks > 0) + AZ_Assert(IsReady() == false, "System allocator was already created!"); + if (IsReady()) { - heapDesc.m_fixedMemoryBlock = desc.m_heap.m_fixedMemoryBlocks[0]; - heapDesc.m_fixedMemoryBlockByteSize = desc.m_heap.m_fixedMemoryBlocksByteSize[0]; + return false; } - heapDesc.m_subAllocator = desc.m_heap.m_subAllocator; - heapDesc.m_isPoolAllocations = desc.m_heap.m_isPoolAllocations; - // Fix SystemAllocator from growing in small chunks - heapDesc.m_systemChunkSize = desc.m_heap.m_systemChunkSize; -#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_MALLOC - MallocSchema::Descriptor heapDesc; -#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HEAP - HeapSchema::Descriptor heapDesc; - memcpy(heapDesc.m_memoryBlocks, desc.m_heap.m_memoryBlocks, sizeof(heapDesc.m_memoryBlocks)); - memcpy(heapDesc.m_memoryBlocksByteSize, desc.m_heap.m_memoryBlocksByteSize, sizeof(heapDesc.m_memoryBlocksByteSize)); - heapDesc.m_numMemoryBlocks = desc.m_heap.m_numMemoryBlocks; -#endif - if (&AllocatorInstance::Get() == this) // if we are the system allocator - { - AZ_Assert(!g_isSystemSchemaUsed, "AZ::SystemAllocator MUST be created first! It's the source of all allocations!"); -#if AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HPHA - m_allocator = new(&g_systemSchema)HphaSchema(heapDesc); -#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_MALLOC - m_allocator = new(&g_systemSchema)MallocSchema(heapDesc); -#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HEAP - m_allocator = new(&g_systemSchema)HeapSchema(heapDesc); -#endif - g_isSystemSchemaUsed = true; + m_desc = desc; + + if (!AllocatorInstance::IsReady()) + { + m_ownsOSAllocator = true; + AllocatorInstance::Create(); + } + bool isReady = false; + if (desc.m_custom) + { + m_isCustom = true; + m_allocator = desc.m_custom; isReady = true; } else { - // this class should be inheriting from SystemAllocator - AZ_Assert(AllocatorInstance::IsReady(), "System allocator must be created before any other allocator! They allocate from it."); - + m_isCustom = false; #if AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HPHA - m_allocator = azcreate(HphaSchema, (heapDesc), SystemAllocator); + HphaSchema::Descriptor heapDesc; + heapDesc.m_pageSize = desc.m_heap.m_pageSize; + heapDesc.m_poolPageSize = desc.m_heap.m_poolPageSize; + AZ_Assert(desc.m_heap.m_numFixedMemoryBlocks <= 1, "We support max1 memory block at the moment!"); + if (desc.m_heap.m_numFixedMemoryBlocks > 0) + { + heapDesc.m_fixedMemoryBlock = desc.m_heap.m_fixedMemoryBlocks[0]; + heapDesc.m_fixedMemoryBlockByteSize = desc.m_heap.m_fixedMemoryBlocksByteSize[0]; + } + heapDesc.m_subAllocator = desc.m_heap.m_subAllocator; + heapDesc.m_isPoolAllocations = desc.m_heap.m_isPoolAllocations; + // Fix SystemAllocator from growing in small chunks + heapDesc.m_systemChunkSize = desc.m_heap.m_systemChunkSize; #elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_MALLOC - m_allocator = azcreate(MallocSchema, (heapDesc), SystemAllocator); -#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HEAP - m_allocator = azcreate(HeapSchema, (heapDesc), SystemAllocator); + MallocSchema::Descriptor heapDesc; #endif - if (m_allocator == nullptr) + if (&AllocatorInstance::Get() == this) // if we are the system allocator { - isReady = false; + AZ_Assert(!g_isSystemSchemaUsed, "AZ::SystemAllocator MUST be created first! It's the source of all allocations!"); + +#if AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HPHA + m_allocator = new (&g_systemSchema) HphaSchema(heapDesc); +#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_MALLOC + m_allocator = new (&g_systemSchema) MallocSchema(heapDesc); +#endif + g_isSystemSchemaUsed = true; + isReady = true; } else { - isReady = true; + // this class should be inheriting from SystemAllocator + AZ_Assert( + AllocatorInstance::IsReady(), + "System allocator must be created before any other allocator! They allocate from it."); + +#if AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HPHA + m_allocator = azcreate(HphaSchema, (heapDesc), SystemAllocator); +#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_MALLOC + m_allocator = azcreate(MallocSchema, (heapDesc), SystemAllocator); +#endif + if (m_allocator == nullptr) + { + isReady = false; + } + else + { + isReady = true; + } } } - } - return isReady; -} - -//========================================================================= -// Allocate -// [9/2/2009] -//========================================================================= -void -SystemAllocator::Destroy() -{ - if (g_isSystemSchemaUsed) - { - int dummy; - (void)dummy; + return isReady; } - if (!m_isCustom) + //========================================================================= + // Allocate + // [9/2/2009] + //========================================================================= + void SystemAllocator::Destroy() { - if ((void*)m_allocator == (void*)&g_systemSchema) + if (g_isSystemSchemaUsed) + { + int dummy; + (void)dummy; + } + + if (!m_isCustom) { + if ((void*)m_allocator == (void*)&g_systemSchema) + { #if AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HPHA - static_cast(m_allocator)->~HphaSchema(); + static_cast(m_allocator)->~HphaSchema(); #elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_MALLOC - static_cast(m_allocator)->~MallocSchema(); -#elif AZCORE_SYSTEM_ALLOCATOR == AZCORE_SYSTEM_ALLOCATOR_HEAP - static_cast(m_allocator)->~HeapSchema(); + static_cast(m_allocator)->~MallocSchema(); #endif - g_isSystemSchemaUsed = false; + g_isSystemSchemaUsed = false; + } + else + { + azdestroy(m_allocator); + } } - else + + if (m_ownsOSAllocator) { - azdestroy(m_allocator); + AllocatorInstance::Destroy(); + m_ownsOSAllocator = false; } } - if (m_ownsOSAllocator) + AllocatorDebugConfig SystemAllocator::GetDebugConfig() { - AllocatorInstance::Destroy(); - m_ownsOSAllocator = false; + return AllocatorDebugConfig() + .StackRecordLevels(m_desc.m_stackRecordLevels) + .UsesMemoryGuards(!m_isCustom) + .MarksUnallocatedMemory(!m_isCustom) + .ExcludeFromDebugging(!m_desc.m_allocationRecords); } -} -AllocatorDebugConfig SystemAllocator::GetDebugConfig() -{ - return AllocatorDebugConfig() - .StackRecordLevels(m_desc.m_stackRecordLevels) - .UsesMemoryGuards(!m_isCustom) - .MarksUnallocatedMemory(!m_isCustom) - .ExcludeFromDebugging(!m_desc.m_allocationRecords); -} - -IAllocatorAllocate* SystemAllocator::GetSchema() -{ - return m_allocator; -} - -//========================================================================= -// Allocate -// [9/2/2009] -//========================================================================= -SystemAllocator::pointer_type -SystemAllocator::Allocate(size_type byteSize, size_type alignment, int flags, const char* name, const char* fileName, int lineNum, unsigned int suppressStackRecord) -{ - if (byteSize == 0) + IAllocatorAllocate* SystemAllocator::GetSchema() { - return nullptr; + return m_allocator; } - AZ_Assert(byteSize > 0, "You can not allocate 0 bytes!"); - AZ_Assert((alignment & (alignment - 1)) == 0, "Alignment must be power of 2!"); - - byteSize = MemorySizeAdjustedUp(byteSize); - SystemAllocator::pointer_type address = m_allocator->Allocate(byteSize, alignment, flags, name, fileName, lineNum, suppressStackRecord + 1); - if (address == nullptr) + //========================================================================= + // Allocate + // [9/2/2009] + //========================================================================= + SystemAllocator::pointer_type SystemAllocator::Allocate( + size_type byteSize, + size_type alignment, + int flags, + const char* name, + const char* fileName, + int lineNum, + unsigned int suppressStackRecord) { - // Free all memory we can and try again! - AllocatorManager::Instance().GarbageCollect(); + if (byteSize == 0) + { + return nullptr; + } + AZ_Assert(byteSize > 0, "You can not allocate 0 bytes!"); + AZ_Assert((alignment & (alignment - 1)) == 0, "Alignment must be power of 2!"); + + byteSize = MemorySizeAdjustedUp(byteSize); + SystemAllocator::pointer_type address = + m_allocator->Allocate(byteSize, alignment, flags, name, fileName, lineNum, suppressStackRecord + 1); - address = m_allocator->Allocate(byteSize, alignment, flags, name, fileName, lineNum, suppressStackRecord + 1); + if (address == nullptr) + { + // Free all memory we can and try again! + AllocatorManager::Instance().GarbageCollect(); + + address = m_allocator->Allocate(byteSize, alignment, flags, name, fileName, lineNum, suppressStackRecord + 1); + } + + if (address == nullptr) + { + byteSize = MemorySizeAdjustedDown(byteSize); // restore original size + } + + AZ_Assert( + address != nullptr, "SystemAllocator: Failed to allocate %d bytes aligned on %d (flags: 0x%08x) %s : %s (%d)!", byteSize, + alignment, flags, name ? name : "(no name)", fileName ? fileName : "(no file name)", lineNum); + + AZ_PROFILE_MEMORY_ALLOC_EX(MemoryReserved, fileName, lineNum, address, byteSize, name); + AZ_MEMORY_PROFILE(ProfileAllocation(address, byteSize, alignment, name, fileName, lineNum, suppressStackRecord + 1)); + + return address; } - if (address == nullptr) + //========================================================================= + // DeAllocate + // [9/2/2009] + //========================================================================= + void SystemAllocator::DeAllocate(pointer_type ptr, size_type byteSize, size_type alignment) { - byteSize = MemorySizeAdjustedDown(byteSize); // restore original size + byteSize = MemorySizeAdjustedUp(byteSize); + AZ_PROFILE_MEMORY_FREE(MemoryReserved, ptr); + AZ_MEMORY_PROFILE(ProfileDeallocation(ptr, byteSize, alignment, nullptr)); + m_allocator->DeAllocate(ptr, byteSize, alignment); } - AZ_Assert(address != nullptr, "SystemAllocator: Failed to allocate %d bytes aligned on %d (flags: 0x%08x) %s : %s (%d)!", byteSize, alignment, flags, name ? name : "(no name)", fileName ? fileName : "(no file name)", lineNum); + //========================================================================= + // ReAllocate + // [9/13/2011] + //========================================================================= + SystemAllocator::pointer_type SystemAllocator::ReAllocate(pointer_type ptr, size_type newSize, size_type newAlignment) + { + newSize = MemorySizeAdjustedUp(newSize); + + AZ_MEMORY_PROFILE(ProfileReallocationBegin(ptr, newSize)); + AZ_PROFILE_MEMORY_FREE(MemoryReserved, ptr); + pointer_type newAddress = m_allocator->ReAllocate(ptr, newSize, newAlignment); + AZ_PROFILE_MEMORY_ALLOC(MemoryReserved, newAddress, newSize, "SystemAllocator realloc"); + AZ_MEMORY_PROFILE(ProfileReallocationEnd(ptr, newAddress, newSize, newAlignment)); - AZ_PROFILE_MEMORY_ALLOC_EX(MemoryReserved, fileName, lineNum, address, byteSize, name); - AZ_MEMORY_PROFILE(ProfileAllocation(address, byteSize, alignment, name, fileName, lineNum, suppressStackRecord + 1)); + return newAddress; + } - return address; -} + //========================================================================= + // Resize + // [8/12/2011] + //========================================================================= + SystemAllocator::size_type SystemAllocator::Resize(pointer_type ptr, size_type newSize) + { + newSize = MemorySizeAdjustedUp(newSize); + size_type resizedSize = m_allocator->Resize(ptr, newSize); -//========================================================================= -// DeAllocate -// [9/2/2009] -//========================================================================= -void -SystemAllocator::DeAllocate(pointer_type ptr, size_type byteSize, size_type alignment) -{ - byteSize = MemorySizeAdjustedUp(byteSize); - AZ_PROFILE_MEMORY_FREE(MemoryReserved, ptr); - AZ_MEMORY_PROFILE(ProfileDeallocation(ptr, byteSize, alignment, nullptr)); - m_allocator->DeAllocate(ptr, byteSize, alignment); -} - -//========================================================================= -// ReAllocate -// [9/13/2011] -//========================================================================= -SystemAllocator::pointer_type -SystemAllocator::ReAllocate(pointer_type ptr, size_type newSize, size_type newAlignment) -{ - newSize = MemorySizeAdjustedUp(newSize); - - AZ_MEMORY_PROFILE(ProfileReallocationBegin(ptr, newSize)); - AZ_PROFILE_MEMORY_FREE(MemoryReserved, ptr); - pointer_type newAddress = m_allocator->ReAllocate(ptr, newSize, newAlignment); - AZ_PROFILE_MEMORY_ALLOC(MemoryReserved, newAddress, newSize, "SystemAllocator realloc"); - AZ_MEMORY_PROFILE(ProfileReallocationEnd(ptr, newAddress, newSize, newAlignment)); - - return newAddress; -} - -//========================================================================= -// Resize -// [8/12/2011] -//========================================================================= -SystemAllocator::size_type -SystemAllocator::Resize(pointer_type ptr, size_type newSize) -{ - newSize = MemorySizeAdjustedUp(newSize); - size_type resizedSize = m_allocator->Resize(ptr, newSize); + AZ_MEMORY_PROFILE(ProfileResize(ptr, resizedSize)); - AZ_MEMORY_PROFILE(ProfileResize(ptr, resizedSize)); + return MemorySizeAdjustedDown(resizedSize); + } - return MemorySizeAdjustedDown(resizedSize); -} + //========================================================================= + // + // [8/12/2011] + //========================================================================= + SystemAllocator::size_type SystemAllocator::AllocationSize(pointer_type ptr) + { + size_type allocSize = MemorySizeAdjustedDown(m_allocator->AllocationSize(ptr)); -//========================================================================= -// -// [8/12/2011] -//========================================================================= -SystemAllocator::size_type -SystemAllocator::AllocationSize(pointer_type ptr) -{ - size_type allocSize = MemorySizeAdjustedDown(m_allocator->AllocationSize(ptr)); + return allocSize; + } - return allocSize; -} +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Memory/SystemAllocator.h b/Code/Framework/AzCore/AzCore/Memory/SystemAllocator.h index c02ada5843..c730b8dde6 100644 --- a/Code/Framework/AzCore/AzCore/Memory/SystemAllocator.h +++ b/Code/Framework/AzCore/AzCore/Memory/SystemAllocator.h @@ -5,8 +5,7 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef AZCORE_SYS_ALLOCATOR_H -#define AZCORE_SYS_ALLOCATOR_H +#pragma once #include @@ -120,7 +119,5 @@ namespace AZ }; } -#endif // AZCORE_SYS_ALLOCATOR_H -#pragma once diff --git a/Code/Framework/AzCore/AzCore/PlatformDef.h b/Code/Framework/AzCore/AzCore/PlatformDef.h index 8d28d27959..7f00f7e90e 100644 --- a/Code/Framework/AzCore/AzCore/PlatformDef.h +++ b/Code/Framework/AzCore/AzCore/PlatformDef.h @@ -149,3 +149,79 @@ #if !defined(AZ_COMMAND_LINE_LEN) # define AZ_COMMAND_LINE_LEN 2048 #endif + +#include +#include +#include +#include +#include + +// First check if the feature if is_constant_evaluated is available via the feature test macro +// https://en.cppreference.com/w/User:D41D8CD98F/feature_testing_macros#C.2B.2B20 +#if __cpp_lib_is_constant_evaluated + #define az_builtin_is_constant_evaluated() std::is_constant_evaluated() +#endif + +// Next check if there is a __builtin_is_constant_evaluated that can be used +// This works on MSVC 19.28+ toolsets when using C++17, as well as +// clang 9.0.0+ when using C++17. +// Finally it works on gcc 9.0+ when using C++17 +#if !defined(az_builtin_is_constant_evaluated) + #if defined(__has_builtin) + #if __has_builtin(__builtin_is_constant_evaluated) + #define az_builtin_is_constant_evaluated() __builtin_is_constant_evaluated() + #define az_has_builtin_is_constant_evaluated() true + #endif + #elif AZ_COMPILER_MSVC >= 1928 + #define az_builtin_is_constant_evaluated() __builtin_is_constant_evaluated() + #define az_has_builtin_is_constant_evaluated() true + #elif AZ_COMPILER_GCC + #define az_builtin_is_constant_evaluated() __builtin_is_constant_evaluated() + #define az_has_builtin_is_constant_evaluated() true + #endif +#endif + +// In this case no support for the determining whether an operation is occuring +// at compile time is supported so assume that evaluation is always occuring at compile time +// in order to make sure the "safe" operation is being performed +#if !defined(az_builtin_is_constant_evaluated) + namespace AZ::Internal + { + constexpr bool builtin_is_constant_evaluated() + { + return true; + } + } + #define az_builtin_is_constant_evaluated() AZ::Internal::builtin_is_constant_evaluated() + #define az_has_builtin_is_constant_evaluated() false +#endif + +// define builtin functions used by char_traits class for efficient compile time and runtime +// operations +#if defined(__has_builtin) + #if __has_builtin(__builtin_memcpy) + #define az_has_builtin_memcpy true + #endif + #if __has_builtin(__builtin_wmemcpy) + #define az_has_builtin_wmemcpy true + #endif + #if __has_builtin(__builtin_memmove) + #define az_has_builtin_memmove true + #endif + #if __has_builtin(__builtin_wmemmove) + #define az_has_builtin_wmemmove true + #endif +#endif + +#if !defined(az_has_builtin_memcpy) + #define az_has_builtin_memcpy false +#endif +#if !defined(az_has_builtin_wmemcpy) + #define az_has_builtin_wmemcpy false +#endif +#if !defined(az_has_builtin_memmove) + #define az_has_builtin_memmove false +#endif +#if !defined(az_has_builtin_wmemmove) + #define az_has_builtin_wmemmove false +#endif diff --git a/Code/Framework/AzCore/AzCore/Script/ScriptContext.cpp b/Code/Framework/AzCore/AzCore/Script/ScriptContext.cpp index 841387f14d..64822684da 100644 --- a/Code/Framework/AzCore/AzCore/Script/ScriptContext.cpp +++ b/Code/Framework/AzCore/AzCore/Script/ScriptContext.cpp @@ -1424,7 +1424,8 @@ namespace AZ } } -using namespace AZ; +namespace AZ +{ #ifndef AZ_USE_CUSTOM_SCRIPT_BIND @@ -2254,6 +2255,7 @@ LUA_API const Node* lua_getDummyNode() } #endif // AZ_USE_CUSTOM_SCRIPT_BIND +} // namespace AZ ////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////// @@ -5825,7 +5827,6 @@ LUA_API const Node* lua_getDummyNode() AllocatorWrapper m_luaAllocator; AZStd::thread::id m_ownerThreadId; // Check if Lua methods (including EBus handlers) are called from background threads. }; - } // namespace AZ ScriptContext::ScriptContext(ScriptContextId id, IAllocatorAllocate* allocator, lua_State* nativeContext) { @@ -6116,5 +6117,6 @@ LUA_API const Node* lua_getDummyNode() { return m_impl->ConstructScriptProperty(sdc, valueIndex, name, restrictToPropertyArrays); } +} // namespace AZ #undef AZ_DBG_NAME_FIXER diff --git a/Code/Framework/AzCore/AzCore/Script/ScriptContext.h b/Code/Framework/AzCore/AzCore/Script/ScriptContext.h index bb63a9368d..5a7fca704f 100644 --- a/Code/Framework/AzCore/AzCore/Script/ScriptContext.h +++ b/Code/Framework/AzCore/AzCore/Script/ScriptContext.h @@ -5,8 +5,7 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef AZCORE_SCRIPT_CONTEXT_H -#define AZCORE_SCRIPT_CONTEXT_H +#pragma once #include #include @@ -1032,4 +1031,3 @@ namespace AZ } } // namespace AZ -#endif // AZCORE_SCRIPT_CONTEXT_H diff --git a/Code/Framework/AzCore/AzCore/Script/ScriptContextDebug.cpp b/Code/Framework/AzCore/AzCore/Script/ScriptContextDebug.cpp index 81ede7a5d3..698c5a0043 100644 --- a/Code/Framework/AzCore/AzCore/Script/ScriptContextDebug.cpp +++ b/Code/Framework/AzCore/AzCore/Script/ScriptContextDebug.cpp @@ -25,10 +25,8 @@ extern "C" { namespace AZ { + void LuaHook(lua_State* l, lua_Debug* ar); -} - -using namespace AZ; /** * A temp class that will override the current script context error handler and store the error (without any messages) @@ -599,7 +597,7 @@ static ScriptContextDebug::BreakpointId MakeBreakpointId(const char* sourceName, // LuaHook // [6/28/2012] //========================================================================= -void AZ::LuaHook(lua_State* l, lua_Debug* ar) +void LuaHook(lua_State* l, lua_Debug* ar) { // Read contexts lua_rawgeti(l, LUA_REGISTRYINDEX, AZ_LUA_SCRIPT_CONTEXT_REF); @@ -1543,4 +1541,6 @@ ScriptContextDebug::SetValue(const DebugValue& sourceValue) return true; } +} // namespace AZ + #endif // #if !defined(AZCORE_EXCLUDE_LUA) diff --git a/Code/Framework/AzCore/AzCore/Script/ScriptContextDebug.h b/Code/Framework/AzCore/AzCore/Script/ScriptContextDebug.h index a8f0ba643c..a1d73352c4 100644 --- a/Code/Framework/AzCore/AzCore/Script/ScriptContextDebug.h +++ b/Code/Framework/AzCore/AzCore/Script/ScriptContextDebug.h @@ -5,8 +5,7 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef AZCORE_SCRIPT_CONTEXT_DEBUG_H -#define AZCORE_SCRIPT_CONTEXT_DEBUG_H +#pragma once #include #include @@ -213,6 +212,3 @@ namespace AZ ScriptContext& m_context; }; } - -#endif // AZCORE_SCRIPT_CONTEXT_DEBUG_H -#pragma once diff --git a/Code/Framework/AzCore/AzCore/Script/ScriptSystemComponent.cpp b/Code/Framework/AzCore/AzCore/Script/ScriptSystemComponent.cpp index 4b71c57682..32081afce7 100644 --- a/Code/Framework/AzCore/AzCore/Script/ScriptSystemComponent.cpp +++ b/Code/Framework/AzCore/AzCore/Script/ScriptSystemComponent.cpp @@ -31,7 +31,8 @@ #include #include -using namespace AZ; +namespace AZ +{ /** * Script lifecycle: @@ -44,8 +45,7 @@ using namespace AZ; * If the script was loaded by a ScriptComponent, Load will be called once reload is complete. */ -namespace -{ +namespace LocalTU_ScriptSystemComponent { // Called when a module has already been loaded static int LuaRequireLoadedModule(lua_State* l) { @@ -54,8 +54,10 @@ namespace return 1; } + } + //========================================================================= // ScriptSystemComponent // [5/29/2012] @@ -479,7 +481,7 @@ int ScriptSystemComponent::DefaultRequireHook(lua_State* lua, ScriptContext* con scriptIt->second.m_scriptNames.emplace(module); // Push the value to a closure that will just return it lua_rawgeti(lua, LUA_REGISTRYINDEX, scriptIt->second.m_tableReference); - lua_pushcclosure(lua, LuaRequireLoadedModule, 1); + lua_pushcclosure(lua, LocalTU_ScriptSystemComponent::LuaRequireLoadedModule, 1); // If asset reference already populated, just return now. Otherwise, capture reference if (scriptIt->second.m_scriptAsset.GetId().IsValid()) @@ -519,7 +521,7 @@ int ScriptSystemComponent::DefaultRequireHook(lua_State* lua, ScriptContext* con } // Push function returning the result - lua_pushcclosure(lua, LuaRequireLoadedModule, 1); + lua_pushcclosure(lua, LocalTU_ScriptSystemComponent::LuaRequireLoadedModule, 1); // Set asset reference on the loaded script scriptIt = container->m_loadedScripts.find(scriptId.m_guid); @@ -565,7 +567,7 @@ int ScriptSystemComponent::InMemoryRequireHook(lua_State* lua, ScriptContext* co scriptIt->second.m_scriptNames.emplace(module); // Push the value to a closure that will just return it lua_rawgeti(lua, LUA_REGISTRYINDEX, scriptIt->second.m_tableReference); - lua_pushcclosure(lua, LuaRequireLoadedModule, 1); + lua_pushcclosure(lua, LocalTU_ScriptSystemComponent::LuaRequireLoadedModule, 1); // If asset reference already populated, just return now. Otherwise, capture reference if (scriptIt->second.m_scriptAsset.GetId().IsValid()) @@ -591,7 +593,7 @@ int ScriptSystemComponent::InMemoryRequireHook(lua_State* lua, ScriptContext* co } // Push function returning the result - lua_pushcclosure(lua, LuaRequireLoadedModule, 1); + lua_pushcclosure(lua, LocalTU_ScriptSystemComponent::LuaRequireLoadedModule, 1); // Set asset reference on the loaded script scriptIt = container->m_loadedScripts.find(scriptId.m_guid); @@ -996,4 +998,5 @@ void ScriptSystemComponent::Reflect(ReflectContext* reflection) } } +} // namespace AZ #endif // #if !defined(AZCORE_EXCLUDE_LUA) diff --git a/Code/Framework/AzCore/AzCore/Script/ScriptSystemComponent.h b/Code/Framework/AzCore/AzCore/Script/ScriptSystemComponent.h index eb2e968a95..a7b1245546 100644 --- a/Code/Framework/AzCore/AzCore/Script/ScriptSystemComponent.h +++ b/Code/Framework/AzCore/AzCore/Script/ScriptSystemComponent.h @@ -5,8 +5,7 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef AZCORE_SCRIPT_SYSTEM_COMPONENT_H -#define AZCORE_SCRIPT_SYSTEM_COMPONENT_H +#pragma once #include #include @@ -182,6 +181,3 @@ namespace AZ void OnAssetReloaded(Data::Asset asset) override; }; } - -#endif // AZCORE_SCRIPT_SYSTEM_COMPONENT_H -#pragma once diff --git a/Code/Framework/AzCore/AzCore/Serialization/Json/JsonSerializer.cpp b/Code/Framework/AzCore/AzCore/Serialization/Json/JsonSerializer.cpp index 8b6c1d154c..46cc0443da 100644 --- a/Code/Framework/AzCore/AzCore/Serialization/Json/JsonSerializer.cpp +++ b/Code/Framework/AzCore/AzCore/Serialization/Json/JsonSerializer.cpp @@ -150,7 +150,7 @@ namespace AZ { // Not using InsertTypeId here to avoid needing to create the temporary value and swap it in that call. node.AddMember(rapidjson::StringRef(JsonSerialization::TypeIdFieldIdentifier), - StoreTypeName(classData, context), context.GetJsonAllocator()); + StoreTypeName(classData, classData.m_typeId, context), context.GetJsonAllocator()); result = ResultCode(Tasks::WriteValue, Outcomes::Success); } return result.Combine(StoreClass(node, object, defaultObject, classData, context)); @@ -531,7 +531,7 @@ namespace AZ return ResolvePointerResult::ContinueProcessing; } - rapidjson::Value JsonSerializer::StoreTypeName(const SerializeContext::ClassData& classData, JsonSerializerContext& context) + rapidjson::Value JsonSerializer::StoreTypeName(const SerializeContext::ClassData& classData, const Uuid& typeId, JsonSerializerContext& context) { rapidjson::Value result; AZStd::vector ids = context.GetSerializeContext()->FindClassId(Crc32(classData.m_name)); @@ -544,7 +544,7 @@ namespace AZ // Only write the Uuid for the class if there are multiple classes sharing the same name. // In this case it wouldn't be enough to determine which class needs to be used. The // class name is still added as a comment for be friendlier for users to read. - AZStd::string fullName = classData.m_typeId.ToString(); + AZStd::string fullName = typeId.ToString(); fullName += ' '; fullName += classData.m_name; result.SetString(fullName.c_str(), aznumeric_caster(fullName.size()), context.GetJsonAllocator()); @@ -560,7 +560,7 @@ namespace AZ const SerializeContext::ClassData* data = context.GetSerializeContext()->FindClassData(typeId); if (data) { - output = JsonSerializer::StoreTypeName(*data, context); + output = JsonSerializer::StoreTypeName(*data, typeId, context); return context.Report(Tasks::WriteValue, Outcomes::Success, "Type id successfully stored to json value."); } else @@ -580,7 +580,7 @@ namespace AZ { rapidjson::Value insertedObject(rapidjson::kObjectType); insertedObject.AddMember( - rapidjson::StringRef(JsonSerialization::TypeIdFieldIdentifier), StoreTypeName(classData, context), + rapidjson::StringRef(JsonSerialization::TypeIdFieldIdentifier), StoreTypeName(classData, classData.m_typeId, context), context.GetJsonAllocator()); for (auto& element : output.GetObject()) diff --git a/Code/Framework/AzCore/AzCore/Serialization/Json/JsonSerializer.h b/Code/Framework/AzCore/AzCore/Serialization/Json/JsonSerializer.h index 22dd768ec5..0b72fca529 100644 --- a/Code/Framework/AzCore/AzCore/Serialization/Json/JsonSerializer.h +++ b/Code/Framework/AzCore/AzCore/Serialization/Json/JsonSerializer.h @@ -79,7 +79,7 @@ namespace AZ const void*& object, const void*& defaultObject, AZStd::any& defaultObjectStorage, const SerializeContext::ClassData*& elementClassData, const AZ::IRttiHelper& rtti, JsonSerializerContext& context); - static rapidjson::Value StoreTypeName(const SerializeContext::ClassData& classData, JsonSerializerContext& context); + static rapidjson::Value StoreTypeName(const SerializeContext::ClassData& classData, const Uuid& typeId, JsonSerializerContext& context); static JsonSerializationResult::ResultCode StoreTypeName(rapidjson::Value& output, const Uuid& typeId, JsonSerializerContext& context); diff --git a/Code/Framework/AzCore/AzCore/Serialization/Json/PathSerializer.cpp b/Code/Framework/AzCore/AzCore/Serialization/Json/PathSerializer.cpp new file mode 100644 index 0000000000..7c057730e8 --- /dev/null +++ b/Code/Framework/AzCore/AzCore/Serialization/Json/PathSerializer.cpp @@ -0,0 +1,127 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include +#include +#include +#include +#include +#include + +namespace AZ::JsonPathSerializerInternal +{ + template + static JsonSerializationResult::Result Load(PathType* pathValue, const rapidjson::Value& inputValue, + JsonDeserializerContext& context) + { + namespace JSR = JsonSerializationResult; // Used remove name conflicts in AzCore in uber builds. + + AZ_Assert(pathValue, "Expected a valid pointer to load from json value."); + + switch (inputValue.GetType()) + { + case rapidjson::kArrayType: + case rapidjson::kObjectType: + case rapidjson::kFalseType: + case rapidjson::kTrueType: + case rapidjson::kNumberType: + [[fallthrough]]; + case rapidjson::kNullType: + return context.Report(JSR::Tasks::ReadField, JSR::Outcomes::Unsupported, + "Unsupported type. String values can't be read from arrays, objects or null."); + case rapidjson::kStringType: + { + size_t pathLength = inputValue.GetStringLength(); + if (pathLength <= pathValue->Native().max_size()) + { + *pathValue = PathType(AZStd::string_view(inputValue.GetString(), pathLength)).LexicallyNormal(); + return context.Report(JSR::Tasks::ReadField, JSR::Outcomes::Success, "Successfully read path."); + } + using UuidString = AZStd::fixed_string; + using ErrorString = AZStd::fixed_string<256>; + return context.Report(JsonSerializationResult::Tasks::ReadField, JSR::Outcomes::Invalid, + ErrorString::format("Json string value is too large to fit within path type %s. It needs to be less than %zu code points", + azrtti_typeid().template ToString().c_str(), pathValue->Native().max_size())); + } + default: + return context.Report(JSR::Tasks::ReadField, JSR::Outcomes::Unknown, "Unknown json type encountered for string value."); + } + } + template + static JsonSerializationResult::Result StoreWithDefault(rapidjson::Value& outputValue, const PathType* pathValue, + const PathType* defaultPathValue, JsonSerializerContext& context) + { + namespace JSR = JsonSerializationResult; // Removes name conflicts in AzCore in uber builds. + + if (context.ShouldKeepDefaults() || defaultPathValue == nullptr || *pathValue != *defaultPathValue) + { + auto posixPathString = pathValue->AsPosix(); + outputValue.SetString(posixPathString.c_str(), aznumeric_caster(posixPathString.size()), context.GetJsonAllocator()); + return context.Report(JSR::Tasks::WriteValue, JSR::Outcomes::Success, "Path successfully stored."); + } + + return context.Report(JSR::Tasks::WriteValue, JSR::Outcomes::DefaultsUsed, "Default Path used."); + } +} + +namespace AZ +{ + AZ_CLASS_ALLOCATOR_IMPL(JsonPathSerializer, SystemAllocator, 0); + + JsonSerializationResult::Result JsonPathSerializer::Load(void* outputValue, const Uuid& outputValueTypeId, + const rapidjson::Value& inputValue, JsonDeserializerContext& context) + { + if (outputValueTypeId == azrtti_typeid()) + { + return JsonPathSerializerInternal::Load(reinterpret_cast(outputValue), inputValue, + context); + } + else if (outputValueTypeId == azrtti_typeid()) + { + return JsonPathSerializerInternal::Load(reinterpret_cast(outputValue), inputValue, + context); + } + + using UuidString = AZStd::fixed_string; + auto errorTypeIdString = outputValueTypeId.ToString(); + AZ_Assert(false, "Unable to serialize json string" + " to a path of type %s", errorTypeIdString.c_str()); + + using ErrorString = AZStd::fixed_string<256>; + return context.Report(JsonSerializationResult::Tasks::ReadField, JsonSerializationResult::Outcomes::TypeMismatch, + ErrorString::format("Output value type ID %s is not a valid Path type", errorTypeIdString.c_str())); + } + + JsonSerializationResult::Result JsonPathSerializer::Store(rapidjson::Value& outputValue, const void* inputValue, + const void* defaultValue, const Uuid& valueTypeId, JsonSerializerContext& context) + { + if (valueTypeId == azrtti_typeid()) + { + return JsonPathSerializerInternal::StoreWithDefault(outputValue, + reinterpret_cast(inputValue), + reinterpret_cast(defaultValue), context); + } + else if (valueTypeId == azrtti_typeid()) + { + return JsonPathSerializerInternal::StoreWithDefault(outputValue, + reinterpret_cast(inputValue), + reinterpret_cast(defaultValue), context); + } + + using UuidString = AZStd::fixed_string; + auto errorTypeIdString = valueTypeId.ToString(); + AZ_Assert(false, "Unable to serialize path type %s to a json string", + errorTypeIdString.c_str()); + + using ErrorString = AZStd::fixed_string<256>; + return context.Report(JsonSerializationResult::Tasks::WriteValue, JsonSerializationResult::Outcomes::TypeMismatch, + ErrorString::format("Input value type ID %s is not a valid Path type", errorTypeIdString.c_str())); + } + +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Serialization/Json/PathSerializer.h b/Code/Framework/AzCore/AzCore/Serialization/Json/PathSerializer.h new file mode 100644 index 0000000000..609a489ec4 --- /dev/null +++ b/Code/Framework/AzCore/AzCore/Serialization/Json/PathSerializer.h @@ -0,0 +1,26 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include + +namespace AZ +{ + class JsonPathSerializer + : public BaseJsonSerializer + { + public: + AZ_RTTI(JsonPathSerializer, "{F6FBA901-07E0-4F03-A0B6-72A9A6CE1E96}", BaseJsonSerializer); + AZ_CLASS_ALLOCATOR_DECL; + JsonSerializationResult::Result Load(void* outputValue, const Uuid& outputValueTypeId, const rapidjson::Value& inputValue, + JsonDeserializerContext& context) override; + JsonSerializationResult::Result Store(rapidjson::Value& outputValue, const void* inputValue, const void* defaultValue, + const Uuid& valueTypeId, JsonSerializerContext& context) override; + }; +} // namespace AZ diff --git a/Code/Framework/AzCore/AzCore/Serialization/Json/RegistrationContext.h b/Code/Framework/AzCore/AzCore/Serialization/Json/RegistrationContext.h index dd10e2bff6..202efd3749 100644 --- a/Code/Framework/AzCore/AzCore/Serialization/Json/RegistrationContext.h +++ b/Code/Framework/AzCore/AzCore/Serialization/Json/RegistrationContext.h @@ -45,9 +45,8 @@ namespace AZ } else { - SerializerMap::const_iterator serializerIter = m_jsonSerializers.find(typeId); - AZ_Assert(serializerIter != m_jsonSerializers.end(), "Attempting to unregister a serializer that has not been registered yet with typeid %s", typeId.ToString().c_str()); - m_jsonSerializers.erase(serializerIter); + [[maybe_unused]] size_t erased = m_jsonSerializers.erase(typeId); + AZ_Assert(erased == 1, "Attempting to unregister a serializer that has not been registered yet with typeid %s", typeId.ToString().c_str()); return SerializerBuilder(this, m_jsonSerializers.end()); } } diff --git a/Code/Framework/AzCore/AzCore/Time/TimeSystem.cpp b/Code/Framework/AzCore/AzCore/Time/TimeSystem.cpp index f8e254d32d..7ba306fbe6 100644 --- a/Code/Framework/AzCore/AzCore/Time/TimeSystem.cpp +++ b/Code/Framework/AzCore/AzCore/Time/TimeSystem.cpp @@ -23,11 +23,11 @@ namespace AZ } } - void cvar_t_simulationTickDeltaOverride_Changed(const float& value) + void cvar_t_simulationTickDeltaOverride_Changed(const int64_t& value) { if (auto* timeSystem = AZ::Interface::Get()) { - timeSystem->SetSimulationTickDeltaOverride(AZ::SecondsToTimeMs(value)); + timeSystem->SetSimulationTickDeltaOverride(static_cast(value)); } } @@ -44,8 +44,8 @@ namespace AZ AZ_CVAR(float, t_simulationTickScale, 1.0f, cvar_t_simulationTickScale_Changed, AZ::ConsoleFunctorFlags::Null, "A scalar amount to adjust time passage by, 1.0 == realtime, 0.5 == half realtime, 2.0 == doubletime"); - AZ_CVAR(float, t_simulationTickDeltaOverride, 0.0f, cvar_t_simulationTickDeltaOverride_Changed, AZ::ConsoleFunctorFlags::Null, - "If > 0, overrides the simulation tick delta time with the provided value (Seconds) and ignores any t_simulationTickScale value."); + AZ_CVAR(int64_t, t_simulationTickDeltaOverride, 0, cvar_t_simulationTickDeltaOverride_Changed, AZ::ConsoleFunctorFlags::Null, + "If > 0, overrides the simulation tick delta time with the provided value (Milliseconds) and ignores any t_simulationTickScale value."); AZ_CVAR(int, t_simulationTickRate, 0, cvar_t_simulationTickRate_Changed, AZ::ConsoleFunctorFlags::Null, "The minimum rate to force the game simulation tick to run. 0 for as fast as possible. 30 = ~33ms, 60 = ~16ms"); @@ -176,7 +176,7 @@ namespace AZ if (timeUs != m_simulationTickDeltaOverride) { m_simulationTickDeltaOverride = timeUs; - t_simulationTickDeltaOverride = AZ::TimeUsToSeconds(timeUs); //update the cvar + t_simulationTickDeltaOverride = static_cast (timeMs); // update the cvar } } diff --git a/Code/Framework/AzCore/AzCore/UnitTest/TestTypes.h b/Code/Framework/AzCore/AzCore/UnitTest/TestTypes.h index afa6898944..0b1d7caefe 100644 --- a/Code/Framework/AzCore/AzCore/UnitTest/TestTypes.h +++ b/Code/Framework/AzCore/AzCore/UnitTest/TestTypes.h @@ -71,18 +71,35 @@ namespace UnitTest }; /** - * RAII wrapper of AllocatorBase. - * The benefit of using this wrapper instead of AllocatorsTestFixture is that SetUp/TearDown of the allocator is managed - * on construction/destruction, allowing member variables of derived classes to exist as value (and do heap allocation). - */ - class ScopedAllocatorSetupFixture + * RAII wrapper of AllocatorBase. + * The benefit of using this wrapper instead of AllocatorsTestFixture is that SetUp/TearDown of the allocator is managed + * on construction/destruction, allowing member variables of derived classes to exist as value (and do heap allocation). + */ + class ScopedAllocatorFixture : AllocatorsBase + { + public: + ScopedAllocatorFixture() + { + SetupAllocator(); + } + explicit ScopedAllocatorFixture(const AZ::SystemAllocator::Descriptor& allocatorDesc) + { + SetupAllocator(allocatorDesc); + } + ~ScopedAllocatorFixture() override + { + TeardownAllocator(); + } + }; + + // Like ScopedAllocatorFixture, but includes the Test base class + class ScopedAllocatorSetupFixture : public ::testing::Test - , AllocatorsBase + , public ScopedAllocatorFixture { public: - ScopedAllocatorSetupFixture() { SetupAllocator(); } - explicit ScopedAllocatorSetupFixture(const AZ::SystemAllocator::Descriptor& allocatorDesc) { SetupAllocator(allocatorDesc); } - ~ScopedAllocatorSetupFixture() { TeardownAllocator(); } + ScopedAllocatorSetupFixture() = default; + explicit ScopedAllocatorSetupFixture(const AZ::SystemAllocator::Descriptor& allocatorDesc) : ScopedAllocatorFixture(allocatorDesc){} }; /** @@ -114,6 +131,7 @@ namespace UnitTest using AllocatorsFixture = AllocatorsTestFixture; #if defined(HAVE_BENCHMARK) + /** * Helper class to handle the boiler plate of setting up a benchmark fixture that uses the system allocators * If you wish to do additional setup and tear down be sure to call the base class SetUp first and TearDown @@ -218,7 +236,7 @@ namespace UnitTest static constexpr bool sHasPadding = size < alignment; AZStd::enable_if mPadding; }; - + template int CreationCounter::s_count = 0; template diff --git a/Code/Framework/AzCore/AzCore/azcore_files.cmake b/Code/Framework/AzCore/AzCore/azcore_files.cmake index e8001f7215..d25a28aa24 100644 --- a/Code/Framework/AzCore/AzCore/azcore_files.cmake +++ b/Code/Framework/AzCore/AzCore/azcore_files.cmake @@ -117,6 +117,10 @@ set(FILES DOM/DomBackend.h DOM/DomUtils.cpp DOM/DomUtils.h + DOM/DomValue.cpp + DOM/DomValue.h + DOM/DomValueWriter.cpp + DOM/DomValueWriter.h DOM/DomVisitor.cpp DOM/DomVisitor.h DOM/Backends/JSON/JsonBackend.h @@ -533,6 +537,8 @@ set(FILES Serialization/Json/JsonUtils.cpp Serialization/Json/MapSerializer.h Serialization/Json/MapSerializer.cpp + Serialization/Json/PathSerializer.h + Serialization/Json/PathSerializer.cpp Serialization/Json/RegistrationContext.h Serialization/Json/RegistrationContext.cpp Serialization/Json/SmartPointerSerializer.h diff --git a/Code/Framework/AzCore/AzCore/std/allocator_stateless.cpp b/Code/Framework/AzCore/AzCore/std/allocator_stateless.cpp index 5806cc485c..baf650a560 100644 --- a/Code/Framework/AzCore/AzCore/std/allocator_stateless.cpp +++ b/Code/Framework/AzCore/AzCore/std/allocator_stateless.cpp @@ -11,17 +11,17 @@ namespace AZStd { - stateless_allocator::stateless_allocator(const char* name) - : m_name(name) {} + stateless_allocator::stateless_allocator() = default; + stateless_allocator::stateless_allocator(const char*) + {} const char* stateless_allocator::get_name() const { - return m_name; + return "AZStd::stateless_allocator"; } - void stateless_allocator::set_name(const char* name) + void stateless_allocator::set_name(const char*) { - m_name = name; } auto stateless_allocator::allocate(size_type byteSize) -> pointer_type diff --git a/Code/Framework/AzCore/AzCore/std/allocator_stateless.h b/Code/Framework/AzCore/AzCore/std/allocator_stateless.h index b73c680c32..6b78aca53d 100644 --- a/Code/Framework/AzCore/AzCore/std/allocator_stateless.h +++ b/Code/Framework/AzCore/AzCore/std/allocator_stateless.h @@ -26,7 +26,8 @@ namespace AZStd using difference_type = ptrdiff_t; using allow_memory_leaks = AZStd::true_type; - stateless_allocator(const char* name = "AZStd::stateless_allocator"); + stateless_allocator(); + explicit stateless_allocator(const char*); // Stateless allocator does not store a name stateless_allocator(const stateless_allocator& rhs) = default; stateless_allocator& operator=(const stateless_allocator& rhs) = default; @@ -51,9 +52,6 @@ namespace AZStd bool is_lock_free(); bool is_stale_read_allowed(); bool is_delayed_recycling(); - - private: - const char* m_name; }; bool operator==(const stateless_allocator& left, const stateless_allocator& right); diff --git a/Code/Framework/AzCore/AzCore/std/azstd_files.cmake b/Code/Framework/AzCore/AzCore/std/azstd_files.cmake index 2746489f8c..d516a56295 100644 --- a/Code/Framework/AzCore/AzCore/std/azstd_files.cmake +++ b/Code/Framework/AzCore/AzCore/std/azstd_files.cmake @@ -64,6 +64,8 @@ set(FILES containers/rbtree.h containers/ring_buffer.h containers/set.h + containers/span.h + containers/span.inl containers/stack.h containers/unordered_map.h containers/unordered_set.h diff --git a/Code/Framework/AzCore/AzCore/std/containers/compressed_pair.h b/Code/Framework/AzCore/AzCore/std/containers/compressed_pair.h index 066ec7be5e..c79ddf11ee 100644 --- a/Code/Framework/AzCore/AzCore/std/containers/compressed_pair.h +++ b/Code/Framework/AzCore/AzCore/std/containers/compressed_pair.h @@ -8,6 +8,7 @@ #pragma once #include +#include #include /* Microsoft C++ ABI puts 1 byte of padding between each empty base class when multiple inheritance is being used @@ -20,7 +21,7 @@ #if defined(AZ_COMPILER_MSVC) #define AZSTD_COMPRESSED_PAIR_EMPTY_BASE_OPTIMIZATION __declspec(empty_bases) #else -#define AZSTD_COMPRESSED_PAIR_EMPTY_BASE_OPTIMIZATION +#define AZSTD_COMPRESSED_PAIR_EMPTY_BASE_OPTIMIZATION #endif namespace AZStd @@ -97,16 +98,14 @@ namespace AZStd using second_base_value_type = typename second_base_type::value_type; public: - // First template argument is a placeholder argument of void as MSVC examines the types - // of a templated function to determine if they are the same template - // Due to the "template compressed_pair(skip_element_tag, T&&)" - // constructor below, the default constructor template types needs to be distinguished from it - template ::value - && AZStd::is_default_constructible::value>> + // First template argument is used to perform a substitution into AZStd::enable_if_t + // so that SFINAE can trigger + template + && AZStd::is_default_constructible_v, Unused>> constexpr compressed_pair(); - template , compressed_pair>::value, bool> = true> + template , compressed_pair>, bool> = true> constexpr explicit compressed_pair(T&& firstElement); template diff --git a/Code/Framework/AzCore/AzCore/std/containers/compressed_pair.inl b/Code/Framework/AzCore/AzCore/std/containers/compressed_pair.inl index 9fb5eb87fb..8e585a1467 100644 --- a/Code/Framework/AzCore/AzCore/std/containers/compressed_pair.inl +++ b/Code/Framework/AzCore/AzCore/std/containers/compressed_pair.inl @@ -75,7 +75,7 @@ namespace AZStd } template - template , compressed_pair>::value, bool>> + template , compressed_pair>, bool>> inline constexpr compressed_pair::compressed_pair(T&& firstElement) : first_base_type{ AZStd::forward(firstElement) } , second_base_type{} @@ -117,7 +117,7 @@ namespace AZStd { return static_cast(*this).get(); } - + template inline constexpr auto compressed_pair::second() -> second_base_value_type& { diff --git a/Code/Framework/AzCore/AzCore/std/containers/span.h b/Code/Framework/AzCore/AzCore/std/containers/span.h new file mode 100644 index 0000000000..5bb51bf481 --- /dev/null +++ b/Code/Framework/AzCore/AzCore/std/containers/span.h @@ -0,0 +1,137 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ +#pragma once + +#include +#include +#include + +namespace AZStd +{ + /** + * First pass partial implementation of span copied over from array_view. It + * returns non-const iterator/pointers. first(), last(), and subspan() + * are yet to be implemented. It does not maintain storage for the data, + * but just holds pointers to mark the beginning and end of the array. + * It can be conveniently constructed from a variety of other container + * types like array, vector, and fixed_vector. + * + * Example: + * Given "void Func(AZStd::span a) {...}" you can call... + * - Func({1,2,3}); + * - AZStd::array a = {1,2,3}; + * Func(a); + * - AZStd::vector v = {1,2,3}; + * Func(v); + * - AZStd::fixed_vector fv = {1,2,3}; + * Func(fv); + * + * Since the span does not copy and store any data, it is only valid as long as the data used to create it is valid. + */ + template + class span final + { + public: + using value_type = Element; + + using pointer = value_type*; + using const_pointer = const value_type*; + + using reference = value_type&; + using const_reference = const value_type&; + + using size_type = AZStd::size_t; + using difference_type = AZStd::ptrdiff_t; + + using iterator = value_type*; + using const_iterator = const value_type*; + using reverse_iterator = AZStd::reverse_iterator; + using const_reverse_iterator = AZStd::reverse_iterator; + + constexpr span(); + + ~span() = default; + + constexpr span(pointer s, size_type length); + + constexpr span(pointer first, pointer last); + + // We explicitly delete this constructor because it's too easy to accidentally + // create a span to just the first element instead of an entire array. + constexpr span(const_pointer s) = delete; + + template + constexpr span(AZStd::array& data); + + constexpr span(AZStd::vector& data); + + template + constexpr span(AZStd::fixed_vector& data); + + template + constexpr span(const AZStd::array& data); + + constexpr span(const AZStd::vector& data); + + template + constexpr span(const AZStd::fixed_vector& data); + + constexpr span(const span&) = default; + + constexpr span(span&& other); + + constexpr span& operator=(const span& other) = default; + + constexpr span& operator=(span&& other); + + constexpr size_type size() const; + + constexpr bool empty() const; + + constexpr pointer data(); + constexpr const_pointer data() const; + + constexpr const_reference operator[](size_type index) const; + constexpr reference operator[](size_type index); + + constexpr void erase(); + + constexpr iterator begin(); + constexpr iterator end(); + constexpr const_iterator begin() const; + constexpr const_iterator end() const; + + constexpr const_iterator cbegin() const; + constexpr const_iterator cend() const; + + constexpr reverse_iterator rbegin(); + constexpr reverse_iterator rend(); + constexpr const_reverse_iterator rbegin() const; + constexpr const_reverse_iterator rend() const; + + constexpr const_reverse_iterator crbegin() const; + constexpr const_reverse_iterator crend() const; + + friend bool operator==(span lhs, span rhs) + { + return lhs.m_begin == rhs.m_begin && lhs.m_end == rhs.m_end; + } + + friend bool operator!=(span lhs, span rhs) { return !(lhs == rhs); } + friend bool operator< (span lhs, span rhs) { return lhs.m_begin < rhs.m_begin || lhs.m_begin == rhs.m_begin && lhs.m_end < rhs.m_end; } + friend bool operator> (span lhs, span rhs) { return lhs.m_begin > rhs.m_begin || lhs.m_begin == rhs.m_begin && lhs.m_end > rhs.m_end; } + friend bool operator<=(span lhs, span rhs) { return lhs == rhs || lhs < rhs; } + friend bool operator>=(span lhs, span rhs) { return lhs == rhs || lhs > rhs; } + + private: + pointer m_begin; + pointer m_end; + }; +} // namespace AZStd + +#include diff --git a/Code/Framework/AzCore/AzCore/std/containers/span.inl b/Code/Framework/AzCore/AzCore/std/containers/span.inl new file mode 100644 index 0000000000..01bab9a5a4 --- /dev/null +++ b/Code/Framework/AzCore/AzCore/std/containers/span.inl @@ -0,0 +1,150 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ +#pragma once + +namespace AZStd +{ + template + inline constexpr span::span() + : m_begin(nullptr) + , m_end(nullptr) + { } + + template + inline constexpr span::span(pointer s, size_type length) + : m_begin(s) + , m_end(m_begin + length) + { + if (length == 0) erase(); + } + + template + inline constexpr span::span(pointer first, pointer last) + : m_begin(first) + , m_end(last) + { } + + template + template + inline constexpr span::span(AZStd::array& data) + : m_begin(data.data()) + , m_end(m_begin + data.size()) + { } + + template + inline constexpr span::span(AZStd::vector& data) + : m_begin(data.data()) + , m_end(m_begin + data.size()) + { } + + template + template + inline constexpr span::span(AZStd::fixed_vector& data) + : m_begin(data.data()) + , m_end(m_begin + data.size()) + { } + + template + template + inline constexpr span::span(const AZStd::array& data) + : m_begin(data.data()) + , m_end(m_begin + data.size()) + { } + + template + inline constexpr span::span(const AZStd::vector& data) + : m_begin(data.data()) + , m_end(m_begin + data.size()) + { } + + template + template + inline constexpr span::span(const AZStd::fixed_vector& data) + : m_begin(data.data()) + , m_end(m_begin + data.size()) + { } + + template + inline constexpr span::span(span&& other) + : span(other.m_begin, other.m_end) + { +#if AZ_DEBUG_BUILD // Clearing the original pointers isn't necessary, but is good for debugging + other.m_begin = nullptr; + other.m_end = nullptr; +#endif + } + + template + inline constexpr AZStd::size_t span::size() const { return m_end - m_begin; } + + template + inline constexpr bool span::empty() const { return m_end == m_begin; } + + template + inline constexpr Element* span::data() { return m_begin; } + + template + inline constexpr const Element* span::data() const { return m_begin; } + + template + inline constexpr span& span::operator=(span&& other) + { + m_begin = other.m_begin; + m_end = other.m_end; +#if AZ_DEBUG_BUILD // Clearing the original pointers isn't necessary, but is good for debugging + other.m_begin = nullptr; + other.m_end = nullptr; +#endif + return *this; + } + + template + inline constexpr const Element& span::operator[](AZStd::size_t index) const + { + AZ_Assert(index < size(), "index value is out of range"); + return m_begin[index]; + } + + template + inline constexpr Element& span::operator[](AZStd::size_t index) + { + AZ_Assert(index < size(), "index value is out of range"); + return m_begin[index]; + } + + template + inline constexpr void span::erase() { m_begin = m_end = nullptr; } + + template + inline constexpr Element* span::begin() { return m_begin; } + template + inline constexpr Element* span::end() { return m_end; } + template + inline constexpr const Element* span::begin() const { return m_begin; } + template + inline constexpr const Element* span::end() const { return m_end; } + + template + inline constexpr const Element* span::cbegin() const { return m_begin; } + template + inline constexpr const Element* span::cend() const { return m_end; } + + template + inline constexpr AZStd::reverse_iterator span::rbegin() { return AZStd::reverse_iterator(m_end); } + template + inline constexpr AZStd::reverse_iterator span::rend() { return AZStd::reverse_iterator(m_begin); } + template + inline constexpr AZStd::reverse_iterator span::rbegin() const { return AZStd::reverse_iterator(m_end); } + template + inline constexpr AZStd::reverse_iterator span::rend() const { return AZStd::reverse_iterator(m_begin); } + + template + inline constexpr AZStd::reverse_iterator span::crbegin() const { return AZStd::reverse_iterator(cend()); } + template + inline constexpr AZStd::reverse_iterator span::crend() const { return AZStd::reverse_iterator(cbegin()); } +} // namespace AZStd diff --git a/Code/Framework/AzCore/AzCore/std/string/fixed_string.h b/Code/Framework/AzCore/AzCore/std/string/fixed_string.h index a8e0f96988..ea841bc4ca 100644 --- a/Code/Framework/AzCore/AzCore/std/string/fixed_string.h +++ b/Code/Framework/AzCore/AzCore/std/string/fixed_string.h @@ -343,26 +343,6 @@ namespace AZStd static decltype(auto) format(const wchar_t* format, ...); protected: - template - constexpr auto append_iter(InputIt first, InputIt last) - -> enable_if_t && !is_convertible_v, basic_fixed_string&>; - - template - constexpr auto construct_iter(InputIt first, InputIt last) - -> enable_if_t && !is_convertible_v>; - - template - constexpr auto assign_iter(InputIt first, InputIt last) - -> enable_if_t && !is_convertible_v, basic_fixed_string&>; - - template - constexpr auto insert_iter(const_iterator insertPos, InputIt first, InputIt last) - -> enable_if_t && !is_convertible_v, iterator>; - - template - constexpr auto replace_iter(const_iterator first, const_iterator last, InputIt first2, InputIt last2) - -> enable_if_t && !is_convertible_v, basic_fixed_string&>; - constexpr auto fits_in_capacity(size_type newSize) -> bool; inline static constexpr size_type Capacity = MaxElementCount; // current storage reserved for string not including null-terminator diff --git a/Code/Framework/AzCore/AzCore/std/string/fixed_string.inl b/Code/Framework/AzCore/AzCore/std/string/fixed_string.inl index 8b973d3b2c..a1c95b7ba2 100644 --- a/Code/Framework/AzCore/AzCore/std/string/fixed_string.inl +++ b/Code/Framework/AzCore/AzCore/std/string/fixed_string.inl @@ -62,14 +62,7 @@ namespace AZStd template inline constexpr basic_fixed_string::basic_fixed_string(InputIt first, InputIt last) { // construct from [first, last) - if (first == last) - { - Traits::assign(m_buffer[0], Element()); // terminate - } - else - { - construct_iter(first, last); - } + assign(first, last); } // #7 @@ -98,8 +91,7 @@ namespace AZStd template inline constexpr basic_fixed_string::basic_fixed_string(const T& convertibleToView) { - AZStd::basic_string_view view = convertibleToView; - assign(view.begin(), view.end()); + assign(convertibleToView); } // #11 @@ -313,15 +305,7 @@ namespace AZStd if (count > 0 && fits_in_capacity(num)) { pointer data = m_buffer; - // make room and append new stuff using assign - if (count == 1) - { - Traits::assign(*(data + m_size), ch); - } - else - { - Traits::assign(data + m_size, count, ch); - } + Traits::assign(data + m_size, count, ch); m_size = static_cast(num); Traits::assign(data[num], Element()); // terminate } @@ -332,13 +316,47 @@ namespace AZStd template inline constexpr auto basic_fixed_string::append(InputIt first, InputIt last) -> enable_if_t && !is_convertible_v, basic_fixed_string&> - { // append [first, last) - return append_iter(first, last); + { + if constexpr (Internal::satisfies_contiguous_iterator_concept_v + && is_same_v::value_type, value_type>) + { + return append(AZStd::to_address(first), AZStd::distance(first, last)); + } + else if constexpr (Internal::is_forward_iterator_v) + { + // Input Iterator pointer type doesn't match the const_pointer type + // So the elements need to be appended one by one into the buffer + size_type newSize = m_size + AZStd::distance(first, last); + if (fits_in_capacity(newSize)) + { + for (size_t updateIndex = m_size; first != last; ++first, ++updateIndex) + { + Traits::assign(m_buffer[updateIndex], static_cast(*first)); + } + m_size = static_cast(newSize); + Traits::assign(m_buffer[newSize], Element()); // terminate + } + return *this; + } + else + { + // input iterator that aren't forward iterators can only be used in a single pass + // algorithm. Therefore AZStd::distance can't be used + // So the input is copied into a local string and then delegated + // to use the (const_pointer, size_type) overload + basic_fixed_string inputCopy; + for (; first != last; ++first) + { + inputCopy.push_back(static_cast(*first)); + } + + return append(inputCopy.c_str(), inputCopy.size()); + } } template inline constexpr auto basic_fixed_string::append(AZStd::initializer_list ilist) -> basic_fixed_string& - { // append [first, last) - return append_iter(ilist.begin(), ilist.end()); + { + return append(ilist.begin(), ilist.size()); } template @@ -420,18 +438,10 @@ namespace AZStd inline constexpr auto basic_fixed_string::assign(size_type count, Element ch) -> basic_fixed_string& { // assign count * ch - AZSTD_CONTAINER_ASSERT(count != npos, "result is too long!"); if (fits_in_capacity(count)) { // make room and assign new stuff pointer data = m_buffer; - if (count == 1) - { - Traits::assign(*(data), ch); - } - else - { - Traits::assign(data, count, ch); - } + Traits::assign(data, count, ch); m_size = static_cast(count); Traits::assign(data[count], Element()); // terminate } @@ -443,12 +453,46 @@ namespace AZStd inline constexpr auto basic_fixed_string::assign(InputIt first, InputIt last) -> enable_if_t && !is_convertible_v, basic_fixed_string&> { - return assign_iter(first, last); + if constexpr (Internal::satisfies_contiguous_iterator_concept_v + && is_same_v::value_type, value_type>) + { + return assign(AZStd::to_address(first), AZStd::distance(first, last)); + } + else if constexpr (Internal::is_forward_iterator_v) + { + // Input Iterator pointer type doesn't match the const_pointer type + // So the elements need to be assigned one by one into the buffer + size_type newSize = AZStd::distance(first, last); + if (fits_in_capacity(newSize)) + { + for (size_t updateIndex = 0; first != last; ++first, ++updateIndex) + { + Traits::assign(m_buffer[updateIndex], static_cast(*first)); + } + m_size = static_cast(newSize); + Traits::assign(m_buffer[newSize], Element()); // terminate + } + return *this; + } + else + { + // input iterator that aren't forward iterators can only be used in a single pass + // algorithm. Therefore AZStd::distance can't be used + // So the input is copied into a local string and then delegated + // to use the (const_pointer, size_type) overload + basic_fixed_string inputCopy; + for (; first != last; ++first) + { + inputCopy.push_back(static_cast(*first)); + } + + return assign(inputCopy.c_str(), inputCopy.size()); + } } template inline constexpr auto basic_fixed_string::assign(AZStd::initializer_list ilist) -> basic_fixed_string& { - return assign_iter(ilist.begin(), ilist.end()); + return assign(ilist.begin(), ilist.size()); } template @@ -536,14 +580,7 @@ namespace AZStd pointer data = m_buffer; // make room and insert new stuff Traits::copy_backward(data + offset + count, data + offset, m_size - offset); // empty out hole - if (count == 1) - { - Traits::assign(*(data + offset), ch); - } - else - { - Traits::assign(data + offset, count, ch); - } + Traits::assign(data + offset, count, ch); m_size = static_cast(num); Traits::assign(data[num], Element()); // terminate } @@ -582,14 +619,51 @@ namespace AZStd inline constexpr auto basic_fixed_string::insert(const_iterator insertPos, InputIt first, InputIt last)-> enable_if_t && !is_convertible_v, iterator> { // insert [_First, _Last) at _Where - return insert_iter(insertPos, first, last); + size_type insertOffset = AZStd::distance(cbegin(), insertPos); + if constexpr (Internal::satisfies_contiguous_iterator_concept_v + && is_same_v::value_type, value_type>) + { + insert(insertOffset, AZStd::to_address(first), AZStd::distance(first, last)); + } + else if constexpr (Internal::is_forward_iterator_v) + { + // Input Iterator pointer type doesn't match the const_pointer type + // So the elements need to be inserted one by one into the buffer + size_type count = AZStd::distance(first, last); + size_type newSize = m_size + count; + if (fits_in_capacity(newSize)) + { + Traits::copy_backward(m_buffer + insertOffset + count, m_buffer + insertOffset, m_size - insertOffset); // empty out hole + for (size_t updateIndex = insertOffset; first != last; ++first, ++updateIndex) + { + Traits::assign(m_buffer[updateIndex], static_cast(*first)); + } + m_size = static_cast(newSize); + Traits::assign(m_buffer[newSize], Element()); // terminate + } + } + else + { + // input iterator that aren't forward iterators can only be used in a single pass + // algorithm. Therefore AZStd::distance can't be used + // So the input is copied into a local string and then delegated + // to use the (const_pointer, size_type) overload + basic_fixed_string inputCopy; + for (; first != last; ++first) + { + inputCopy.push_back(static_cast(*first)); + } + + insert(insertOffset, inputCopy.c_str(), inputCopy.size()); + } + return begin() + insertOffset; } template inline constexpr auto basic_fixed_string::insert(const_iterator insertPos, AZStd::initializer_list ilist) -> iterator { // insert [_First, _Last) at _Where - return insert_iter(insertPos, ilist.begin(), ilist.end()); + return insert(insertPos, ilist.begin(), ilist.end()); } template @@ -604,7 +678,7 @@ namespace AZStd { // move elements down pointer data = m_buffer; - Traits::copy(data + offset, data + offset + count, m_size - offset - count); + Traits::move(data + offset, data + offset + count, m_size - offset - count); m_size = static_cast(m_size - count); Traits::assign(data[m_size], Element()); // terminate } @@ -643,7 +717,7 @@ namespace AZStd const basic_fixed_string& rhs) -> basic_fixed_string& { // replace [offset, offset + count) with rhs - return replace(offset, count, rhs, size_type(0), npos); + return replace(offset, count, rhs.c_str(), rhs.size()); } template @@ -651,56 +725,7 @@ namespace AZStd const basic_fixed_string& rhs, size_type rhsOffset, size_type rhsCount) -> basic_fixed_string& { // replace [offset, offset + count) with rhs [rhsOffset, rhsOffset + rhsCount) - AZSTD_CONTAINER_ASSERT(m_size >= offset && rhs.m_size >= rhsOffset, "Invalid offsets"); - if (m_size - offset < count) - { - count = m_size - offset; // trim count to size - } - size_type num = rhs.m_size - rhsOffset; - if (num < rhsCount) - { - rhsCount = num; // trim rhsCount to size - } - AZSTD_CONTAINER_ASSERT(npos - rhsCount > m_size - count, "Result is too long"); - - size_type nm = m_size - count - offset; // length of preserved tail - size_type newSize = m_size + rhsCount - count; - if (fits_in_capacity(newSize)) - { - pointer data = m_buffer; - const_pointer rhsData = rhs.m_buffer; - - if (this != &rhs) - { // no overlap, just move down and copy in new stuff - Traits::copy_backward(data + offset + rhsCount, data + offset + count, nm); // empty hole - Traits::copy(data + offset, rhsData + rhsOffset, rhsCount); // fill hole - } - else if (rhsCount <= count) - { // hole doesn't get larger, just copy in substring - Traits::copy(data + offset, data + rhsOffset, rhsCount); // fill hole - Traits::copy_backward(data + offset + rhsCount, data + offset + count, nm); // move tail down - } - else if (rhsOffset <= offset) - { // hole gets larger, substring begins before hole - Traits::copy_backward(data + offset + rhsCount, data + offset + count, nm); // move tail down - Traits::copy(data + offset, data + rhsOffset, rhsCount); // fill hole - } - else if (offset + count <= rhsOffset) - { // hole gets larger, substring begins after hole - Traits::copy_backward(data + offset + rhsCount, data + offset + count, nm); // move tail down - Traits::copy(data + offset, data + (rhsOffset + rhsCount - count), rhsCount); // fill hole - } - else - { // hole gets larger, substring begins in hole - Traits::copy(data + offset, data + rhsOffset, count); // fill old hole - Traits::copy_backward(data + offset + rhsCount, data + offset + count, nm); // move tail down - Traits::copy(data + offset + count, data + rhsOffset + rhsCount, rhsCount - count); // fill rest of new hole - } - - m_size = static_cast(newSize); - Traits::assign(data[newSize], Element()); // terminate - } - return *this; + return replace(offset, count, rhs.c_str() + rhsOffset, AZStd::min(rhsCount, rhs.size() - rhsOffset)); } template template @@ -720,35 +745,83 @@ namespace AZStd pointer data = m_buffer; // replace [offset, offset + count) with [ptr, ptr + ptrCount) AZSTD_CONTAINER_ASSERT(m_size >= offset, "Invalid offset"); - if (m_size - offset < count) - { - count = m_size - offset; // trim _N0 to size - } - AZSTD_CONTAINER_ASSERT(npos - ptrCount > m_size - count, "Result too long"); + // Make sure count is within is no larger than the distance from the offset + // to the end of this string + count = AZStd::min(count, m_size - offset); - size_type nm = m_size - count - offset; - if (ptrCount < count) - { - Traits::copy(data + offset + ptrCount, data + offset + count, nm); // smaller hole, move tail up - } - size_type num = m_size + ptrCount - count; - if ((0 != ptrCount || 0 != count) && fits_in_capacity(num)) + size_type newSize = m_size + ptrCount - count; + if (fits_in_capacity(newSize)) { - data = m_buffer; - // make room and rearrange - if (count < ptrCount) + // The code assumes that compile time evaluation will not need to deal with overlapping input + size_type charsAfterCountToMove = m_size - count - offset; + if (az_builtin_is_constant_evaluated() || !((ptr >= data + offset && ptr < data + offset + count) + || (ptr + ptrCount > data + offset && ptr + ptrCount <= data + offset + count))) { - Traits::copy_backward(data + offset + ptrCount, data + offset + count, nm); // move tail down + // Ex1. this = "ABCDEFG", offset = 1, count = 4 + // Input string is "CDE" + // First the text post offset + count is moved to right after the input string will be copied + // "ABCDFG" + // ^^^ + // Next the input string is copied into the buffer + // "ACDEFG" + // + // Ex2. this = "ABCDEFG", offset = 1, count = 2 + // Input string is "CDE" + // Performing the same two steps above, the string transform as follows + // "ABCDEFG" -> "ABCDDEFG" -> "ACDEDEFG" + // ^^^ + if (count != ptrCount) + { + Traits::move(data + offset + ptrCount, data + offset + count, charsAfterCountToMove); + } + if (ptrCount > 0) + { + // Copy bytes up to the minimum of this string count and input string count + Traits::copy(data + offset, ptr, ptrCount); + } } - - if (ptrCount > 0) + else { - Traits::copy(data + offset, ptr, ptrCount); // fill hole + // Overlap checks for fixed_string only needs to check between this string + // [offset, offset + count) due to fixed_string never moving memory + // + // Ex. this = "ABCDEFG", offset = 1, count=4 + // substring is "CDE" + // The text from offset 1 for 4 chars "BCDE": should be replaced with "CDE" + // making a whole for the bytes results in output = "ABCDFG" + // Afterwards output = "ACDEFG" + // The input string overlaps with this string in this case + // So the string is copied piecewise + if (ptrCount <= count) + { // hole doesn't get larger, just copy in substring + Traits::move(data + offset, ptr, ptrCount); // fill hole + Traits::copy(data + offset + ptrCount, data + offset + count, charsAfterCountToMove); // move tail down + } + else + { + if (ptr <= data + offset) + { // hole gets larger, substring begins before hole + Traits::copy_backward(data + offset + ptrCount, data + offset + count, charsAfterCountToMove); // move tail down + Traits::copy(data + offset, ptr, ptrCount); // fill hole + } + else if (data + offset + count <= ptr) + { // hole gets larger, substring begins after hole + Traits::copy_backward(data + offset + ptrCount, data + offset + count, charsAfterCountToMove); // move tail down + Traits::copy(data + offset, ptr + (ptrCount - count), ptrCount); // fill hole + } + else + { // hole gets larger, substring begins in hole + Traits::copy(data + offset, ptr, count); // fill old hole + Traits::copy_backward(data + offset + ptrCount, data + offset + count, charsAfterCountToMove); // move tail down + Traits::copy(data + offset + count, ptr + ptrCount, ptrCount - count); // fill rest of new hole + } + } } - - m_size = static_cast(num); - Traits::assign(data[num], Element()); // terminate } + + m_size = static_cast(newSize); + Traits::assign(data[newSize], Element()); // terminate + return *this; } @@ -793,14 +866,7 @@ namespace AZStd { Traits::copy_backward(data + offset + num, data + offset + count, nm); // move tail down } - if (count == 1) - { - Traits::assign(*(data + offset), ch); - } - else - { - Traits::assign(data + offset, num, ch); - } + Traits::assign(data + offset, num, ch); m_size = static_cast(numToGrow); Traits::assign(data[numToGrow], Element()); // terminate } @@ -851,15 +917,54 @@ namespace AZStd template template inline constexpr auto basic_fixed_string::replace(const_iterator first, const_iterator last, - InputIt first2, InputIt last2) -> enable_if_t && !is_convertible_v, basic_fixed_string&> - { // replace [first, last) with [first2,last2) - return replace_iter(first, last, first2, last2); + InputIt replaceFirst, InputIt replaceLast) -> enable_if_t && !is_convertible_v, basic_fixed_string&> + { // replace [first, last) with [replaceFirst,replaceLast) + if constexpr (Internal::satisfies_contiguous_iterator_concept_v + && is_same_v::value_type, value_type>) + { + return replace(first, last, AZStd::to_address(replaceFirst), AZStd::distance(replaceFirst, replaceLast)); + } + else if constexpr (Internal::is_forward_iterator_v) + { + // Input Iterator pointer type doesn't match the const_pointer type + // So the elements need to be appended one by one into the buffer + + size_type insertOffset = AZStd::distance(cbegin(), first); + size_type postInsertOffset = AZStd::distance(cbegin(), last); + size_type count = AZStd::distance(replaceFirst, replaceLast); + size_type newSize = m_size + count - AZStd::distance(first, last); + if (fits_in_capacity(newSize)) + { + Traits::move(first + count, last, m_size - postInsertOffset); // empty out hole + for (size_t updateIndex = insertOffset; replaceFirst != replaceLast; ++replaceFirst, ++updateIndex) + { + Traits::assign(m_buffer[updateIndex], static_cast(*replaceFirst)); + } + m_size = static_cast(newSize); + Traits::assign(m_buffer[newSize], Element()); // terminate + } + return *this; + } + else + { + // input iterator that aren't forward iterators can only be used in a single pass + // algorithm. Therefore AZStd::distance can't be used + // So the input is copied into a local string and then delegated + // to use the (const_pointer, size_type) overload + basic_fixed_string inputCopy; + for (; replaceFirst != replaceLast; ++replaceFirst) + { + inputCopy.push_back(static_cast(*replaceFirst)); + } + + return replace(first, last, inputCopy.c_str(), inputCopy.size()); + } } template inline constexpr auto basic_fixed_string::replace(const_iterator first, const_iterator last, AZStd::initializer_list ilist) -> basic_fixed_string& - { // replace [first, last) with [first2,last2) - return replace_iter(first, last, ilist.begin(), ilist.end()); + { + return replace(first, last, ilist.begin(), ilist.end()); } template @@ -1411,54 +1516,6 @@ namespace AZStd return result; } - template - template - inline constexpr auto basic_fixed_string::construct_iter(InputIt first, InputIt last) - -> enable_if_t && !is_convertible_v> - { - // initialize from [first, last), input iterators - for (; first != last; ++first) - { - append((size_type)1, (Element)* first); - } - } - - template - template - inline constexpr auto basic_fixed_string::append_iter(InputIt first, InputIt last) - -> enable_if_t && !is_convertible_v, basic_fixed_string&> - { // append [first, last), input iterators - return replace(end(), end(), first, last); - } - - template - template - inline constexpr auto basic_fixed_string::assign_iter(InputIt first, InputIt last) - -> enable_if_t && !is_convertible_v, basic_fixed_string&> - { - return replace(begin(), end(), first, last); - } - - template - template - inline constexpr auto basic_fixed_string::insert_iter(const_iterator insertPos, InputIt first, - InputIt last) -> enable_if_t && !is_convertible_v, iterator> - { // insert [first, last) at insertPos, input iterators - difference_type offset = insertPos - cbegin(); - replace(insertPos, insertPos, first, last); - return iterator(m_buffer + offset); - } - - template - template - inline constexpr auto basic_fixed_string::replace_iter(const_iterator first, const_iterator last, - InputIt first2, InputIt last2) -> enable_if_t && !is_convertible_v, basic_fixed_string&> - { // replace [first, last) with [first2, last2), input iterators - basic_fixed_string rhs(first2, last2); - replace(first, last, rhs); - return *this; - } - template inline constexpr auto basic_fixed_string::fits_in_capacity(size_type newSize)-> bool { @@ -1703,7 +1760,8 @@ namespace AZStd template struct hash> { - inline constexpr size_t operator()(const basic_fixed_string& value) const + using is_transparent = void; + inline constexpr size_t operator()(const basic_string_view& value) const { return hash_string(value.begin(), value.length()); } diff --git a/Code/Framework/AzCore/AzCore/std/string/string.h b/Code/Framework/AzCore/AzCore/std/string/string.h index e107c4657d..56afd16226 100644 --- a/Code/Framework/AzCore/AzCore/std/string/string.h +++ b/Code/Framework/AzCore/AzCore/std/string/string.h @@ -5,24 +5,43 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef AZSTD_STRING_H -#define AZSTD_STRING_H +#pragma once #include #include #include #include +#include #include #include #include #include #include -#include #include #include +namespace AZStd::StringInternal +{ + template + struct Padding + { + AZ::u8 m_padding[ElementSize - 1]; + }; + + template + struct Padding + {}; +} + +#if defined(HAVE_BENCHMARK) +namespace Benchmark +{ + class StringBenchmarkFixture; +} +#endif + namespace AZStd { /** @@ -35,130 +54,95 @@ namespace AZStd : public Debug::checked_container_base #endif { - typedef basic_string this_type; + using this_type = basic_string; public: - typedef Element* pointer; - typedef const Element* const_pointer; + using pointer = Element*; + using const_pointer = const Element*; - typedef Element& reference; - typedef const Element& const_reference; - typedef typename Allocator::difference_type difference_type; - typedef typename Allocator::size_type size_type; + using reference = Element&; + using const_reference = const Element&; + using difference_type = typename Allocator::difference_type; + using size_type = typename Allocator::size_type; - typedef pointer iterator_impl; - typedef const_pointer const_iterator_impl; + using iterator_impl = pointer; + using const_iterator_impl = const_pointer; #ifdef AZSTD_HAS_CHECKED_ITERATORS - typedef Debug::checked_randomaccess_iterator iterator; - typedef Debug::checked_randomaccess_iterator const_iterator; + using iterator = Debug::checked_randomaccess_iterator; + using const_iterator = Debug::checked_randomaccess_iterator; #else - typedef iterator_impl iterator; - typedef const_iterator_impl const_iterator; + using iterator = iterator_impl; + using const_iterator = const_iterator_impl; #endif - typedef AZStd::reverse_iterator reverse_iterator; - typedef AZStd::reverse_iterator const_reverse_iterator; - typedef Element value_type; - typedef Traits traits_type; - typedef Allocator allocator_type; + using reverse_iterator = AZStd::reverse_iterator; + using const_reverse_iterator = AZStd::reverse_iterator; + using value_type = Element; + using traits_type = Traits; + using allocator_type = Allocator; // AZSTD extension. /** * \brief Allocation node type. Common for all AZStd containers. * In vectors case we allocate always "sizeof(node_type)*capacity" block. */ - typedef value_type node_type; + using node_type = value_type; - static const size_type npos = size_type(-1); + inline static constexpr size_type npos = size_type(-1); inline basic_string(const Allocator& alloc = Allocator()) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) - , m_allocator(alloc) + : m_storage{ skip_element_tag{}, alloc } { - Traits::assign(m_buffer[0], Element()); + Traits::assign(m_storage.first().GetData()[0], Element()); } inline basic_string(const_pointer ptr, size_type count, const Allocator& alloc = Allocator()) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) - , m_allocator(alloc) + : m_storage{ skip_element_tag{}, alloc } { // construct from [ptr, ptr + count) assign(ptr, count); } inline basic_string(const_pointer ptr, const Allocator& alloc = Allocator()) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) - , m_allocator(alloc) + : m_storage{ skip_element_tag{}, alloc } { // construct from [ptr, ) assign(ptr); } inline basic_string(size_type count, Element ch, const Allocator& alloc = Allocator()) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) - , m_allocator(alloc) + : m_storage{ skip_element_tag{}, alloc } { // construct from count * ch assign(count, ch); } - template - inline basic_string(InputIterator first, InputIterator last, const Allocator& alloc = Allocator()) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) - , m_allocator(alloc) + template && !is_convertible_v>> + inline basic_string(InputIt first, InputIt last, const Allocator& alloc = Allocator()) + : m_storage{ skip_element_tag{}, alloc } { // construct from [first, last) - if (first == last) - { - Traits::assign(m_buffer[0], Element()); // terminate - } - else - { - construct_iter(first, last, is_integral()); - } + assign(first, last); } inline basic_string(const_pointer first, const_pointer last) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) { // construct from [first, last), const pointers - assign(&*first, last - first); + assign(first, last - first); } - //inline basic_string(const_iterator _First, const_iterator _Last) - // : m_size(0) - // , m_capacity(SSO_BUF_SIZE-1) - //{ // construct from [_First, _Last), const_iterators - // if (first != last) - // assign(&*first, last - first); - //} - inline basic_string(const this_type& rhs) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) - , m_allocator(rhs.m_allocator) + : m_storage{ skip_element_tag{}, rhs.m_storage.second() } { assign(rhs, 0, npos); } inline basic_string(this_type&& rhs) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) - , m_allocator(AZStd::move(rhs.m_allocator)) + : m_storage{ skip_element_tag{}, AZStd::move(rhs.m_storage.second()) } { assign(AZStd::forward(rhs)); } inline basic_string(const this_type& rhs, size_type rhsOffset, size_type count = npos) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) { // construct from rhs [rhsOffset, rhsOffset + count) assign(rhs, rhsOffset, count); } inline basic_string(const this_type& rhs, size_type rhsOffset, size_type count, const Allocator& alloc) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) - , m_allocator(alloc) + : m_storage{ skip_element_tag{}, alloc } { // construct from rhs [rhsOffset, rhsOffset + count) with allocator assign(rhs, rhsOffset, count); } @@ -174,7 +158,7 @@ namespace AZStd inline ~basic_string() { // destroy the string - deallocate_memory(m_data, 0, typename allocator_type::allow_memory_leaks()); + deallocate_memory(m_storage.first().GetData(), 0, typename allocator_type::allow_memory_leaks()); } operator AZStd::basic_string_view() const @@ -182,12 +166,12 @@ namespace AZStd return AZStd::basic_string_view(data(), size()); } - inline iterator begin() { return iterator(AZSTD_CHECKED_ITERATOR(iterator_impl, SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer)); } - inline const_iterator begin() const { return const_iterator(AZSTD_CHECKED_ITERATOR(const_iterator_impl, SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer)); } - inline const_iterator cbegin() const { return const_iterator(AZSTD_CHECKED_ITERATOR(const_iterator_impl, SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer)); } - inline iterator end() { return iterator(AZSTD_CHECKED_ITERATOR(iterator_impl, (SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer) + m_size)); } - inline const_iterator end() const { return const_iterator(AZSTD_CHECKED_ITERATOR(const_iterator_impl, (SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer) + m_size)); } - inline const_iterator cend() const { return const_iterator(AZSTD_CHECKED_ITERATOR(const_iterator_impl, (SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer) + m_size)); } + inline iterator begin() { return iterator(AZSTD_CHECKED_ITERATOR(iterator_impl, m_storage.first().GetData())); } + inline const_iterator begin() const { return const_iterator(AZSTD_CHECKED_ITERATOR(const_iterator_impl, m_storage.first().GetData())); } + inline const_iterator cbegin() const { return const_iterator(AZSTD_CHECKED_ITERATOR(const_iterator_impl, m_storage.first().GetData())); } + inline iterator end() { return iterator(AZSTD_CHECKED_ITERATOR(iterator_impl, (m_storage.first().GetData()) + m_storage.first().GetSize())); } + inline const_iterator end() const { return const_iterator(AZSTD_CHECKED_ITERATOR(const_iterator_impl, (m_storage.first().GetData()) + m_storage.first().GetSize())); } + inline const_iterator cend() const { return const_iterator(AZSTD_CHECKED_ITERATOR(const_iterator_impl, (m_storage.first().GetData()) + m_storage.first().GetSize())); } inline reverse_iterator rbegin() { return reverse_iterator(end()); } inline const_reverse_iterator rbegin() const { return const_reverse_iterator(end()); } inline const_reverse_iterator crbegin() const { return const_reverse_iterator(end()); } @@ -196,7 +180,7 @@ namespace AZStd inline const_reverse_iterator crend() const { return const_reverse_iterator(begin()); } inline this_type& operator=(const this_type& rhs) { return assign(rhs); } - inline this_type& operator=(this_type&& rhs) { return assign(AZStd::forward(rhs)); } + inline this_type& operator=(this_type&& rhs) { return assign(AZStd::move(rhs)); } inline this_type& operator=(AZStd::basic_string_view view) { return assign(view); } inline this_type& operator=(const_pointer ptr) { return assign(ptr); } inline this_type& operator=(Element ch) { return assign(1, ch); } @@ -208,21 +192,18 @@ namespace AZStd this_type& append(const this_type& rhs, size_type rhsOffset, size_type count) { // append rhs [rhsOffset, rhsOffset + count) AZSTD_CONTAINER_ASSERT(rhs.size() >= rhsOffset, "Invalid offset!"); - size_type num = rhs.m_size - rhsOffset; - if (num < count) - { - count = num; // trim count to size - } - AZSTD_CONTAINER_ASSERT(npos - m_size > count && m_size + count >= m_size, "result is too long!"); - num = m_size + count; - if (count > 0 && grow(num)) + count = AZStd::min(count, rhs.size() - rhsOffset); + + size_type oldSize = size(); + size_type newSize = oldSize + count; + if (count > 0 && grow(newSize)) { - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; + pointer data = m_storage.first().GetData(); + const_pointer rhsData = rhs.data(); // make room and append new stuff - Traits::copy(data + m_size /*, m_capacity - m_size*/, rhsData + rhsOffset, count); - m_size = num; - Traits::assign(data[num], Element()); // terminate + Traits::copy(data + oldSize, rhsData + rhsOffset, count); + m_storage.first().SetSize(newSize); + Traits::assign(data[newSize], Element()); // terminate } return *this; } @@ -230,20 +211,21 @@ namespace AZStd this_type& append(const_pointer ptr, size_type count) { // append [ptr, ptr + count) - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - if (ptr != 0 && ptr >= data && (data + m_size) > ptr) + pointer data = m_storage.first().GetData(); + if (ptr != nullptr && ptr >= data && (data + size()) > ptr) { return append(*this, ptr - data, count); // substring } - AZSTD_CONTAINER_ASSERT(npos - m_size > count && m_size + count >= m_size, "result is too long!"); - size_type num = m_size + count; - if (count > 0 && grow(num)) + AZSTD_CONTAINER_ASSERT(npos - size() > count && size() + count >= size(), "result is too long!"); + size_type oldSize = size(); + size_type newSize = oldSize + count; + if (count > 0 && grow(newSize)) { // make room and append new stuff - data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - Traits::copy(data + m_size /*, m_capacity - m_size*/, ptr, count); - m_size = num; - Traits::assign(data[num], Element()); // terminate + data = m_storage.first().GetData(); + Traits::copy(data + oldSize , ptr, count); + m_storage.first().SetSize(newSize); + Traits::assign(data[newSize], Element()); // terminate } return *this; } @@ -252,30 +234,60 @@ namespace AZStd this_type& append(size_type count, Element ch) { // append count * ch - AZSTD_CONTAINER_ASSERT(npos - m_size > count, "result is too long"); - size_type num = m_size + count; + AZSTD_CONTAINER_ASSERT(npos - size() > count, "result is too long"); + size_type num = size() + count; if (count > 0 && grow(num)) { - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); // make room and append new stuff using assign - if (count == 1) - { - Traits::assign(*(data + m_size), ch); - } - else - { - Traits::assign(data + m_size, count, ch); - } - m_size = num; + Traits::assign(data + size(), count, ch); + m_storage.first().SetSize(num); Traits::assign(data[num], Element()); // terminate } return *this; } - template - inline this_type& append(InputIterator first, InputIterator last) + template + inline auto append(InputIt first, InputIt last) + -> enable_if_t && !is_convertible_v, this_type&> { // append [first, last) - return append_iter(first, last, AZStd::is_integral()); + if constexpr (Internal::satisfies_contiguous_iterator_concept_v + && is_same_v::value_type, value_type>) + { + return append(AZStd::to_address(first), AZStd::distance(first, last)); + } + else if constexpr (Internal::is_forward_iterator_v) + { + // Input Iterator pointer type doesn't match the const_pointer type + // So the elements need to be appended one by one into the buffer + size_type oldSize = size(); + size_type newSize = oldSize + AZStd::distance(first, last); + if (grow(newSize)) + { + pointer buffer = data(); + for (size_t updateIndex = oldSize; first != last; ++first, ++updateIndex) + { + Traits::assign(buffer[updateIndex], static_cast(*first)); + } + m_storage.first().SetSize(newSize); + Traits::assign(buffer[newSize], Element()); // terminate + } + return *this; + } + else + { + // input iterator that aren't forward iterators can only be used in a single pass + // algorithm. Therefore AZStd::distance can't be used + // So the input is copied into a local string and then delegated + // to use the (const_pointer, size_type) overload + basic_string inputCopy; + for (; first != last; ++first) + { + inputCopy.push_back(static_cast(*first)); + } + + return append(inputCopy.c_str(), inputCopy.size()); + } } inline this_type& append(const_pointer first, const_pointer last) @@ -283,11 +295,6 @@ namespace AZStd return replace(end(), end(), first, last); } - //inline this_type& append(const_iterator first, const_iterator last) - //{ // append [first, last), const_iterators - // return replace(end(), end(), first, last); - //} - inline this_type& assign(const this_type& rhs) { return assign(rhs, 0, npos); @@ -302,27 +309,34 @@ namespace AZStd { if (this != &rhs) { - if (SSO_BUF_SIZE <= m_capacity) + deallocate_memory(m_storage.first().GetData(), 0, typename allocator_type::allow_memory_leaks()); + + m_storage.first().SetCapacity(rhs.capacity()); + + pointer data = m_storage.first().GetData(); + pointer rhsData = rhs.data(); + // Memmove the right hand side string data if it is using the short string optimization + // Otherwise set the pointer to the right hand side + if (rhs.m_storage.first().ShortStringOptimizationActive()) { - deallocate_memory(m_data, 0, typename allocator_type::allow_memory_leaks()); + Traits::move(data, rhsData, rhs.size() + 1); // string + null-terminator } + else + { + m_storage.first().SetData(rhsData); + } + m_storage.first().SetSize(rhs.size()); + m_storage.second() = rhs.m_storage.second(); - Traits::move(m_buffer, rhs.m_buffer, sizeof(m_buffer)); - m_size = rhs.m_size; - m_capacity = rhs.m_capacity; - m_allocator = rhs.m_allocator; - - rhs.m_data = nullptr; - rhs.m_size = 0; - rhs.m_capacity = SSO_BUF_SIZE - 1; + rhs.leak_and_reset(); } return *this; } this_type& assign(const this_type& rhs, size_type rhsOffset, size_type count) { // assign rhs [rhsOffset, rhsOffset + count) - AZSTD_CONTAINER_ASSERT(rhs.m_size >= rhsOffset, "Invalid offset"); - size_type num = rhs.m_size - rhsOffset; + AZSTD_CONTAINER_ASSERT(rhs.size() >= rhsOffset, "Invalid offset"); + size_type num = rhs.size() - rhsOffset; if (count < num) { num = count; // trim num to size @@ -334,10 +348,10 @@ namespace AZStd } else if (grow(num)) { // make room and assign new stuff - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - Traits::copy(data /*, m_capacity*/, rhsData + rhsOffset, num); - m_size = num; + pointer data = m_storage.first().GetData(); + const_pointer rhsData = rhs.data(); + Traits::copy(data, rhsData + rhsOffset, num); + m_storage.first().SetSize(num); Traits::assign(data[num], Element()); // terminate } return *this; @@ -345,20 +359,20 @@ namespace AZStd this_type& assign(const_pointer ptr, size_type count) { // assign [ptr, ptr + count) - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - if (ptr != 0 && ptr >= data && (data + m_size) > ptr) + pointer data = m_storage.first().GetData(); + if (ptr != nullptr && ptr >= data && (data + size()) > ptr) { return assign(*this, ptr - data, count); // substring } if (grow(count)) { // make room and assign new stuff - data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + data = m_storage.first().GetData(); if (count > 0) { Traits::copy(data, ptr, count); } - m_size = count; + m_storage.first().SetSize(count); Traits::assign(data[count], Element()); // terminate } return *this; @@ -367,109 +381,132 @@ namespace AZStd this_type& assign(size_type count, Element ch) { // assign count * ch - AZSTD_CONTAINER_ASSERT(count != npos, "result is too long!"); if (grow(count)) { // make room and assign new stuff - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - if (count == 1) + pointer data = m_storage.first().GetData(); + Traits::assign(data, count, ch); + m_storage.first().SetSize(count); + Traits::assign(data[count], Element()); // terminate + } + return *this; + } + + template + auto assign(InputIt first, InputIt last) + -> enable_if_t && !is_convertible_v, this_type&> + { + if constexpr (Internal::satisfies_contiguous_iterator_concept_v + && is_same_v::value_type, value_type>) + { + return assign(AZStd::to_address(first), AZStd::distance(first, last)); + } + else if constexpr (Internal::is_forward_iterator_v) + { + // forward iterator pointer type doesn't match the const_pointer type + // So the elements need to be assigned one by one into the buffer + size_type newSize = AZStd::distance(first, last); + if (grow(newSize)) { - Traits::assign(*(data), ch); + pointer buffer = data(); + for (size_t updateIndex = 0; first != last; ++first, ++updateIndex) + { + Traits::assign(buffer[updateIndex], static_cast(*first)); + } + m_storage.first().SetSize(newSize); + Traits::assign(buffer[newSize], Element()); // terminate } - else + return *this; + } + else + { + // input iterator that aren't forward iterators can only be used in a single pass + // algorithm. Therefore AZStd::distance can't be used + // So the input is copied into a local string and then delegated + // to use the (const_pointer, size_type) overload + basic_string inputCopy; + for (; first != last; ++first) { - Traits::assign(data, count, ch); + inputCopy.push_back(static_cast(*first)); } - m_size = count; - Traits::assign(data[count], Element()); // terminate + + return assign(inputCopy.c_str(), inputCopy.size()); } - return *this; } - - template - inline this_type& assign(InputIterator first, InputIterator last) { return assign_iter(first, last, AZStd::is_integral()); } - inline this_type& assign(const_pointer first, const_pointer last) { return replace(begin(), end(), first, last); } - inline this_type& insert(size_type offset, const this_type& rhs) { return insert(offset, rhs, 0, npos); } + inline this_type& insert(size_type offset, const this_type& rhs) { return insert(offset, rhs, 0, npos); } this_type& insert(size_type offset, const this_type& rhs, size_type rhsOffset, size_type count) { // insert rhs [rhsOffset, rhsOffset + count) at offset - AZSTD_CONTAINER_ASSERT(m_size >= offset && rhs.m_size >= rhsOffset, "Invalid offset(s)"); - size_type num = rhs.m_size - rhsOffset; + AZSTD_CONTAINER_ASSERT(size() >= offset && rhs.size() >= rhsOffset, "Invalid offset(s)"); + size_type num = rhs.size() - rhsOffset; if (num < count) { count = num; // trim _Count to size } - AZSTD_CONTAINER_ASSERT(npos - m_size > count, "Result is too long"); - num = m_size + count; + AZSTD_CONTAINER_ASSERT(npos - size() > count, "Result is too long"); + num = size() + count; if (count > 0 && grow(num)) { - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); // make room and insert new stuff - Traits::move(data + offset + count /*, m_capacity - offset - count*/, data + offset, m_size - offset); // empty out hole + Traits::move(data + offset + count, data + offset, size() - offset); // empty out hole if (this == &rhs) { - Traits::move(data + offset /*, m_capacity - offset*/, data + (offset < rhsOffset ? rhsOffset + count : rhsOffset), count); // substring + Traits::move(data + offset, data + (offset < rhsOffset ? rhsOffset + count : rhsOffset), count); // substring } else { - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - Traits::copy(data + offset /*, m_capacity - offset*/, rhsData + rhsOffset, count); // fill hole + const_pointer rhsData = rhs.data(); + Traits::copy(data + offset, rhsData + rhsOffset, count); // fill hole } - m_size = num; + m_storage.first().SetSize(num); Traits::assign(data[num], Element()); // terminate } return (*this); } - this_type& insert(size_type offset, const_pointer ptr, size_type count) + this_type& insert(size_type offset, const_pointer ptr, size_type count) { // insert [ptr, ptr + count) at offset - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - if (ptr != 0 && ptr >= data && (data + m_size) > ptr) + pointer data = m_storage.first().GetData(); + if (ptr != nullptr && ptr >= data && (data + size()) > ptr) { - return insert(offset, *this, ptr - data, count); // substring + return insert(offset, *this, ptr - data, count); // substring } - AZSTD_CONTAINER_ASSERT(m_size >= offset, "Invalid offset"); - AZSTD_CONTAINER_ASSERT(npos - m_size > count, "Result is too long"); - size_type num = m_size + count; + AZSTD_CONTAINER_ASSERT(size() >= offset, "Invalid offset"); + AZSTD_CONTAINER_ASSERT(npos - size() > count, "Result is too long"); + size_type num = size() + count; if (count > 0 && grow(num)) { // make room and insert new stuff - data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - Traits::move(data + offset + count /*, m_capacity - offset - count*/, data + offset, m_size - offset); // empty out hole - Traits::copy(data + offset /*, m_capacity - offset*/, ptr, count); // fill hole - m_size = num; + data = m_storage.first().GetData(); + Traits::move(data + offset + count, data + offset, size() - offset); // empty out hole + Traits::copy(data + offset, ptr, count); // fill hole + m_storage.first().SetSize(num); Traits::assign(data[num], Element()); // terminate } return *this; } - inline this_type& insert(size_type offset, const_pointer ptr) { return insert(offset, ptr, Traits::length(ptr)); } + inline this_type& insert(size_type offset, const_pointer ptr) { return insert(offset, ptr, Traits::length(ptr)); } this_type& insert(size_type offset, size_type count, Element ch) { // insert count * ch at offset - AZSTD_CONTAINER_ASSERT(m_size >= offset, "Invalid offset"); - AZSTD_CONTAINER_ASSERT(npos - m_size > count, "Result is too long"); - size_type num = m_size + count; + AZSTD_CONTAINER_ASSERT(size() >= offset, "Invalid offset"); + AZSTD_CONTAINER_ASSERT(npos - size() > count, "Result is too long"); + size_type num = size() + count; if (count > 0 && grow(num)) { - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); // make room and insert new stuff - Traits::move(data + offset + count /*, m_capacity - offset - count*/, data + offset, m_size - offset); // empty out hole - if (count == 1) - { - Traits::assign(*(data + offset), ch); - } - else - { - Traits::assign(data + offset, count, ch); - } - m_size = num; + Traits::move(data + offset + count, data + offset, size() - offset); // empty out hole + Traits::assign(data + offset, count, ch); + m_storage.first().SetSize(num); Traits::assign(data[num], Element()); // terminate } return *this; } - inline iterator insert(const_iterator insertPos) { return insert(insertPos, Element()); } + inline iterator insert(const_iterator insertPos) { return insert(insertPos, Element()); } iterator insert(const_iterator insertPos, Element ch) { @@ -479,54 +516,89 @@ namespace AZStd const_pointer insertPosPtr = insertPos; #endif - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + const_pointer data = m_storage.first().GetData(); size_type offset = insertPosPtr - data; insert(offset, 1, ch); return iterator(AZSTD_CHECKED_ITERATOR(iterator_impl, data + offset)); } - void insert(const_iterator insertPos, size_type count, Element ch) + iterator insert(const_iterator insertPos, size_type count, Element ch) { // insert count * elem at insertPos #ifdef AZSTD_HAS_CHECKED_ITERATORS const_pointer insertPosPtr = insertPos.get_iterator(); #else const_pointer insertPosPtr = insertPos; #endif - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); size_type offset = insertPosPtr - data; insert(offset, count, ch); + return begin() + offset; } - template - inline void insert(const_iterator insertPos, InputIterator first, InputIterator last) + template + auto insert(const_iterator insertPos, InputIt first, InputIt last) + -> enable_if_t && !is_convertible_v, iterator> { // insert [_First, _Last) at _Where - insert_iter(insertPos, first, last, is_integral()); - } + size_type insertOffset = AZStd::distance(cbegin(), insertPos); + if constexpr (Internal::satisfies_contiguous_iterator_concept_v + && is_same_v::value_type, value_type>) + { + insert(insertOffset, AZStd::to_address(first), AZStd::distance(first, last)); + } + else if constexpr (Internal::is_forward_iterator_v) + { + // Input Iterator pointer type doesn't match the const_pointer type + // So the elements need to be inserted one by one into the buffer + size_type count = AZStd::distance(first, last); + size_type oldSize = size(); + size_type newSize = oldSize + count; + if (grow(newSize)) + { + pointer buffer = m_storage.first().GetData(); + Traits::copy_backward(buffer + insertOffset + count, buffer + insertOffset, oldSize - insertOffset); // empty out hole + for (size_t updateIndex = insertOffset; first != last; ++first, ++updateIndex) + { + Traits::assign(buffer[updateIndex], static_cast(*first)); + } + m_storage.first().SetSize(newSize); + Traits::assign(buffer[newSize], Element()); // terminate + } + } + else + { + // input iterator that aren't forward iterators can only be used in a single pass + // algorithm. Therefore AZStd::distance can't be used + // So the input is copied into a local string and then delegated + // to use the (const_pointer, size_type) overload + basic_string inputCopy; + for (; first != last; ++first) + { + inputCopy.push_back(static_cast(*first)); + } - inline void insert(const_iterator insertPos, const_pointer first, const_pointer last) - { // insert [first, last) at insertPos, const pointers - replace(insertPos, insertPos, first, last); + insert(insertOffset, inputCopy.c_str(), inputCopy.size()); + } + return begin() + insertOffset; } - this_type& erase(size_type offset = 0, size_type count = npos) { // erase elements [offset, offset + count) - AZSTD_CONTAINER_ASSERT(m_size >= offset, "Invalid offset"); - if (m_size - offset < count) + AZSTD_CONTAINER_ASSERT(size() >= offset, "Invalid offset"); + if (size() - offset < count) { - count = m_size - offset; // trim count + count = size() - offset; // trim count } if (count > 0) { // move elements down - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); #ifdef AZSTD_HAS_CHECKED_ITERATORS orphan_range(data + offset, data + offset + count); #endif - Traits::move(data + offset /*, m_capacity - offset*/, data + offset + count, m_size - offset - count); - m_size = m_size - count; - Traits::assign(data[m_size], Element()); // terminate - } + Traits::move(data + offset, data + offset + count, size() - offset - count); + m_storage.first().SetSize(size() - count); + Traits::assign(data[size()], Element()); // terminate + } return *this; } @@ -538,10 +610,10 @@ namespace AZStd const_pointer erasePtr = erasePos; #endif // erase element at insertPos - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + const_pointer data = m_storage.first().GetData(); size_type count = erasePtr - data; erase(count, 1); - data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + data = m_storage.first().GetData(); return iterator(AZSTD_CHECKED_ITERATOR(iterator_impl, data + count)); } @@ -554,159 +626,152 @@ namespace AZStd const_pointer firstPtr = first; const_pointer lastPtr = last; #endif - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); size_type count = firstPtr - data; erase(count, lastPtr - firstPtr); - data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + data = m_storage.first().GetData(); return iterator(AZSTD_CHECKED_ITERATOR(iterator_impl, data + count)); } - inline void clear() { erase(begin(), end()); } - inline this_type& replace(size_type offset, size_type count, const this_type& rhs) + inline void clear() { erase(begin(), end()); } + this_type& replace(size_type offset, size_type count, const this_type& rhs) { - // replace [offset, offset + count) with rhs - return replace(offset, count, rhs, 0, npos); + return replace(offset, count, rhs.c_str(), rhs.size()); } this_type& replace(size_type offset, size_type count, const this_type& rhs, size_type rhsOffset, size_type rhsCount) { - // replace [offset, offset + count) with rhs [rhsOffset, rhsOffset + rhsCount) - AZSTD_CONTAINER_ASSERT(m_size >= offset && rhs.m_size >= rhsOffset, "Invalid offsets"); - if (m_size - offset < count) - { - count = m_size - offset; // trim count to size - } - size_type num = rhs.m_size - rhsOffset; - if (num < rhsCount) - { - rhsCount = num; // trim rhsCount to size - } - AZSTD_CONTAINER_ASSERT(npos - rhsCount > m_size - count, "Result is too long"); - - size_type nm = m_size - count - offset; // length of preserved tail - size_type newSize = m_size + rhsCount - count; - if (m_size < newSize) - { - grow(newSize); - } - - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - -#ifdef AZSTD_HAS_CHECKED_ITERATORS - orphan_range(data + offset, data + offset + count); -#endif - if (this != &rhs) - { // no overlap, just move down and copy in new stuff - Traits::move(data + offset + rhsCount /*, m_capacity - offset - rhsCount*/, data + offset + count, nm); // empty hole - Traits::copy(data + offset /*, m_capacity - offset*/, rhsData + rhsOffset, rhsCount); // fill hole - } - else if (rhsCount <= count) - { // hole doesn't get larger, just copy in substring - Traits::move(data + offset /*, m_capacity - offset*/, data + rhsOffset, rhsCount); // fill hole - Traits::move(data + offset + rhsCount /*, m_capacity - offset - rhsCount*/, data + offset + count, nm); // move tail down - } - else if (rhsOffset <= offset) - { // hole gets larger, substring begins before hole - Traits::move(data + offset + rhsCount /*, m_capacity - offset - rhsCount*/, data + offset + count, nm); // move tail down - Traits::move(data + offset /*, m_capacity - offset*/, data + rhsOffset, rhsCount); // fill hole - } - else if (offset + count <= rhsOffset) - { // hole gets larger, substring begins after hole - Traits::move(data + offset + rhsCount /*, m_capacity - offset - rhsCount*/, data + offset + count, nm); // move tail down - Traits::move(data + offset /*, m_capacity - offset*/, data + (rhsOffset + rhsCount - count), rhsCount); // fill hole - } - else - { // hole gets larger, substring begins in hole - Traits::move(data + offset /*, m_capacity - offset*/, data + rhsOffset, count); // fill old hole - Traits::move(data + offset + rhsCount /*, m_capacity - offset - rhsCount*/, data + offset + count, nm); // move tail down - Traits::move(data + offset + count /*, m_capacity - offset - count*/, data + rhsOffset + rhsCount, rhsCount - count); // fill rest of new hole - } - - m_size = newSize; - Traits::assign(data[newSize], Element()); // terminate - return (*this); + return replace(offset, count, rhs.c_str() + rhsOffset, AZStd::min(rhsCount, rhs.size() - rhsOffset)); } this_type& replace(size_type offset, size_type count, const_pointer ptr, size_type ptrCount) { - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; // replace [offset, offset + count) with [ptr, ptr + ptrCount) - if (ptr != 0 && ptr >= data && (data + m_size) > ptr) - { - return (replace(offset, count, *this, ptr - data, ptrCount)); // substring, replace carefully - } - AZSTD_CONTAINER_ASSERT(m_size >= offset, "Invalid offset"); - if (m_size - offset < count) - { - count = m_size - offset; // trim _N0 to size + AZSTD_CONTAINER_ASSERT(size() >= offset, "Invalid offset"); + // Make sure count is within is no larger than the distance from the offset + // to the end of this string + count = AZStd::min(count, size() - offset); + + size_type newSize = size() + ptrCount - count; + size_type charsAfterCountToMove = size() - count - offset; + pointer inputStringCopy{}; + + if (pointer thisBuffer = m_storage.first().GetData(); + (ptr >= thisBuffer && ptr < thisBuffer + size()) + || (ptr + ptrCount > thisBuffer && ptr + ptrCount <= thisBuffer + size())) + { + // Overlap checks for tring needs if the input pointer is anywhere within the string + // even if it is outside of the range of [offset, offset + count) as a growing + // the string buffer could cause a realloc to occur + if (!fits_in_capacity(newSize)) + { + // If the input string is a sub-string and it would cause + // this string to need to re-allocated as it doesn't fit in the capacity + // Then the input string is needs to be copied into a local buffer + inputStringCopy = reinterpret_cast(get_allocator().allocate(ptrCount * sizeof(value_type), alignof(value_type))); + Traits::copy(inputStringCopy, ptr, ptrCount); + // Updated the input string pointer to point to the local buffer + ptr = inputStringCopy; + // Now this string buffer can now be safely resized and the non-overlapping string logic below can be used + } + else + { + // overlapping string in-place logic + // Ex. this = "ABCDEFG", offset = 1, count=4 + // substring is "CDE" + // The text from offset 1 for 4 chars "BCDE": should be replaced with "CDE" + // making a whole for the bytes results in output = "ABCDFG" + // Afterwards output = "ACDEFG" + // The input string overlaps with this string in this case + // So the string is copied piecewise + if (ptrCount <= count) + { // hole doesn't get larger, just copy in substring + Traits::move(thisBuffer + offset, ptr, ptrCount); // fill hole + Traits::copy(thisBuffer + offset + ptrCount, thisBuffer + offset + count, charsAfterCountToMove); // move tail down + } + else + { + if (ptr <= thisBuffer + offset) + { // hole gets larger, substring begins before hole + Traits::copy_backward(thisBuffer + offset + ptrCount, thisBuffer + offset + count, charsAfterCountToMove); // move tail down + Traits::copy(thisBuffer + offset, ptr, ptrCount); // fill hole + } + else if (thisBuffer + offset + count <= ptr) + { // hole gets larger, substring begins after hole + Traits::copy_backward(thisBuffer + offset + ptrCount, thisBuffer + offset + count, charsAfterCountToMove); // move tail down + Traits::copy(thisBuffer + offset, ptr + (ptrCount - count), ptrCount); // fill hole + } + else + { // hole gets larger, substring begins in hole + Traits::copy(thisBuffer + offset, ptr, count); // fill old hole + Traits::copy_backward(thisBuffer + offset + ptrCount, thisBuffer + offset + count, charsAfterCountToMove); // move tail down + Traits::copy(thisBuffer + offset + count, ptr + ptrCount, ptrCount - count); // fill rest of new hole + } + } + m_storage.first().SetSize(newSize); + Traits::assign(thisBuffer[newSize], Element()); // terminate + return *this; + } } - AZSTD_CONTAINER_ASSERT(npos - ptrCount > m_size - count, "Result too long"); -#ifdef AZSTD_HAS_CHECKED_ITERATORS - orphan_range(data + offset, data + offset + count); -#endif - size_type nm = m_size - count - offset; - if (ptrCount < count) - { - Traits::move(data + offset + ptrCount, data + offset + count, nm); // smaller hole, move tail up - } - size_type num = m_size + ptrCount - count; - if ((0 < ptrCount || 0 < count) && grow(num)) + // input string doesn't overlap, so this string can be re-allocated safely + if (grow(newSize)) { - data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - // make room and rearrange - if (count < ptrCount) + // Need to regrab the memory address for the storage buffer + // in case the grow re-allocated memory + pointer thisBuffer = m_storage.first().GetData(); + if (count != ptrCount) { - Traits::move(data + offset + ptrCount /*, m_capacity - offset - ptrCount*/, data + offset + count, nm); // move tail down + Traits::move(thisBuffer + offset + ptrCount, thisBuffer + offset + count, charsAfterCountToMove); } if (ptrCount > 0) { - Traits::copy(data + offset /*, m_capacity - offset*/, ptr, ptrCount); // fill hole + // Copy bytes up to the minimum of this string count and input string count + Traits::copy(thisBuffer + offset, ptr, ptrCount); } + // input string doesn't overlap, so this string can be re-allocated safely + m_storage.first().SetSize(newSize); + Traits::assign(thisBuffer[newSize], Element()); // terminate + } - m_size = num; - Traits::assign(data[num], Element()); // terminate + // If a local string was allocated, then de-allocate its memory + if (inputStringCopy != nullptr) + { + get_allocator().deallocate(inputStringCopy, 0, alignof(value_type)); } + return *this; } inline this_type& replace(size_type offset, size_type count, const_pointer ptr) { return replace(offset, count, ptr, Traits::length(ptr)); } this_type& replace(size_type offset, size_type count, size_type num, Element ch) { // replace [offset, offset + count) with num * ch - AZSTD_CONTAINER_ASSERT(m_size > offset, "Invalid offset"); - if (m_size - offset < count) + AZSTD_CONTAINER_ASSERT(size() > offset, "Invalid offset"); + if (size() - offset < count) { - count = m_size - offset; // trim count to size + count = size() - offset; // trim count to size } - AZSTD_CONTAINER_ASSERT(npos - num > m_size - count, "Result is too long"); - size_type nm = m_size - count - offset; + AZSTD_CONTAINER_ASSERT(npos - num > size() - count, "Result is too long"); + size_type nm = size() - count - offset; - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); #ifdef AZSTD_HAS_CHECKED_ITERATORS orphan_range(data + offset, data + offset + count); #endif if (num < count) { - Traits::move(data + offset + num /*, m_capacity - offset - num*/, data + offset + count, nm); // smaller hole, move tail up + Traits::move(data + offset + num, data + offset + count, nm); // smaller hole, move tail up } - size_type numToGrow = m_size + num - count; + size_type numToGrow = size() + num - count; if ((0 < num || 0 < count) && grow(numToGrow)) { // make room and rearrange - data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + data = m_storage.first().GetData(); if (count < num) { - Traits::move(data + offset + num /*, m_capacity - offset - num*/, data + offset + count, nm); // move tail down + Traits::move(data + offset + num, data + offset + count, nm); // move tail down } - if (count == 1) - { - Traits::assign(*(data + offset), ch); - } - else - { - Traits::assign(data + offset, num, ch); - } - m_size = numToGrow; + Traits::assign(data + offset, num, ch); + m_storage.first().SetSize(numToGrow); Traits::assign(data[numToGrow], Element()); // terminate } return *this; @@ -722,7 +787,7 @@ namespace AZStd const_pointer firstPtr = first; const_pointer lastPtr = last; #endif - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); return replace(firstPtr - data, lastPtr - firstPtr, rhs); } @@ -735,7 +800,7 @@ namespace AZStd const_pointer firstPtr = first; const_pointer lastPtr = last; #endif - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); return replace(firstPtr - data, lastPtr - firstPtr, ptr, count); } @@ -748,7 +813,7 @@ namespace AZStd const_pointer firstPtr = first; const_pointer lastPtr = last; #endif - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); return replace(firstPtr - data, lastPtr - firstPtr, ptr); } @@ -761,113 +826,133 @@ namespace AZStd const_pointer firstPtr = first; const_pointer lastPtr = last; #endif - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); return replace(firstPtr - data, lastPtr - firstPtr, count, ch); } - template - inline this_type& replace(const_iterator first, const_iterator last, InputIterator first2, InputIterator last2) - { // replace [first, last) with [first2,last2) - return replace_iter(first, last, first2, last2, is_integral()); - } - - this_type& replace(const_iterator first, const_iterator last, const_pointer first2, const_pointer last2) + template + inline auto replace(const_iterator first, const_iterator last, InputIt replaceFirst, InputIt replaceLast) + -> enable_if_t && !is_convertible_v, this_type&> { -#ifdef AZSTD_HAS_CHECKED_ITERATORS - const_pointer first1 = first.get_iterator(); - const_pointer last1 = last.get_iterator(); -#else - const_pointer first1 = first; - const_pointer last1 = last; -#endif - // replace [first, last) with [first2, last2), const pointers - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - if (first2 == last2) + if constexpr (Internal::satisfies_contiguous_iterator_concept_v + && is_same_v::value_type, value_type>) { - erase(first1 - data, last1 - first1); + return replace(first, last, AZStd::to_address(replaceFirst), AZStd::distance(replaceFirst, replaceLast)); + } + else if constexpr (Internal::is_forward_iterator_v) + { + // Input Iterator pointer type doesn't match the const_pointer type + // So the elements need to be appended one by one into the buffer + + size_type insertOffset = AZStd::distance(cbegin(), first); + size_type postInsertOffset = AZStd::distance(cbegin(), last); + size_type count = AZStd::distance(replaceFirst, replaceLast); + size_type oldSize = size(); + size_type newSize = oldSize + count - AZStd::distance(first, last); + if (grow(newSize)) + { + pointer buffer = data(); + Traits::move(first + count, last, oldSize - postInsertOffset); // empty out hole + for (size_t updateIndex = insertOffset; replaceFirst != replaceLast; ++replaceFirst, ++updateIndex) + { + Traits::assign(buffer[updateIndex], static_cast(*replaceFirst)); + } + m_storage.first().SetSize(newSize); + Traits::assign(buffer[newSize], Element()); // terminate + } + return *this; } else { - replace(first1 - data, last1 - first1, &*first2, last2 - first2); + // input iterator that aren't forward iterators can only be used in a single pass + // algorithm. Therefore AZStd::distance can't be used + // So the input is copied into a local string and then delegated + // to use the (const_pointer, size_type) overload + basic_string inputCopy; + for (; replaceFirst != replaceLast; ++replaceFirst) + { + inputCopy.push_back(static_cast(*replaceFirst)); + } + + return replace(first, last, inputCopy.c_str(), inputCopy.size()); } - return *this; } inline reference at(size_type offset) { // subscript mutable sequence with checking - AZSTD_CONTAINER_ASSERT(m_size > offset, "Invalid offset"); - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + AZSTD_CONTAINER_ASSERT(size() > offset, "Invalid offset"); + pointer data = m_storage.first().GetData(); return data[offset]; } inline const_reference at(size_type offset) const { // subscript nonmutable sequence with checking - AZSTD_CONTAINER_ASSERT(m_size > offset, "Invalid offset"); - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + AZSTD_CONTAINER_ASSERT(size() > offset, "Invalid offset"); + const_pointer data = m_storage.first().GetData(); return data[offset]; } inline reference operator[](size_type offset) { // subscript mutable sequence with checking - AZSTD_CONTAINER_ASSERT(m_size > offset, "Invalid offset"); - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + AZSTD_CONTAINER_ASSERT(size() > offset, "Invalid offset"); + pointer data = m_storage.first().GetData(); return data[offset]; } inline const_reference operator[](size_type offset) const { // subscript nonmutable sequence with checking - AZSTD_CONTAINER_ASSERT(m_size > offset, "Invalid offset"); - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + AZSTD_CONTAINER_ASSERT(size() > offset, "Invalid offset"); + const_pointer data = m_storage.first().GetData(); return data[offset]; } inline reference front() { - AZSTD_CONTAINER_ASSERT(m_size != 0, "AZStd::string::front - string is empty!"); - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + AZSTD_CONTAINER_ASSERT(size() != 0, "AZStd::string::front - string is empty!"); + pointer data = m_storage.first().GetData(); return data[0]; } inline const_reference front() const { - AZSTD_CONTAINER_ASSERT(m_size != 0, "AZStd::string::front - string is empty!"); - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + AZSTD_CONTAINER_ASSERT(size() != 0, "AZStd::string::front - string is empty!"); + const_pointer data = m_storage.first().GetData(); return data[0]; } inline reference back() { - AZSTD_CONTAINER_ASSERT(m_size != 0, "AZStd::string::back - string is empty!"); - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - return data[m_size - 1]; + AZSTD_CONTAINER_ASSERT(size() != 0, "AZStd::string::back - string is empty!"); + pointer data = m_storage.first().GetData(); + return data[size() - 1]; } inline const_reference back() const { - AZSTD_CONTAINER_ASSERT(m_size != 0, "AZStd::string::back - string is empty!"); - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - return data[m_size - 1]; + AZSTD_CONTAINER_ASSERT(size() != 0, "AZStd::string::back - string is empty!"); + const_pointer data = m_storage.first().GetData(); + return data[size() - 1]; } inline void push_back(Element ch) { - const_pointer end = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - end += m_size; + const_pointer end = data(); + end += size(); insert(end, ch); } - inline const_pointer c_str() const { return (SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer); } - inline size_type length() const { return m_size; } - inline size_type size() const { return m_size; } - inline size_type capacity() const { return m_capacity; } + inline const_pointer c_str() const { return (data()); } + inline size_type length() const { return m_storage.first().GetSize(); } + inline size_type size() const { return m_storage.first().GetSize(); } + inline size_type capacity() const { return m_storage.first().GetCapacity(); } inline size_type max_size() const { // return maximum possible length of sequence - return AZStd::allocator_traits::max_size(m_allocator) / sizeof(value_type); + return AZStd::allocator_traits::max_size(m_storage.second()) / sizeof(value_type); } inline void resize(size_type newSize) @@ -877,58 +962,58 @@ namespace AZStd inline void resize_no_construct(size_type newSize) { - if (newSize <= m_size) + if (newSize <= size()) { erase(newSize); } else { reserve(newSize); - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - m_size = newSize; - Traits::assign(data[m_size], Element()); // terminate + pointer data = m_storage.first().GetData(); + m_storage.first().SetSize(newSize); + Traits::assign(data[newSize], Element()); // terminate } } inline void resize(size_type newSize, Element ch) { // determine new length, padding with ch elements as needed - if (newSize <= m_size) + if (newSize <= size()) { erase(newSize); } else { - append(newSize - m_size, ch); + append(newSize - size(), ch); } } void reserve(size_type newCapacity = 0) { // determine new minimum length of allocated storage - if (m_size <= newCapacity && m_capacity != newCapacity) + if (size() <= newCapacity && capacity() != newCapacity) { // change reservation - size_type size = m_size; + size_type curSize = size(); if (grow(newCapacity)) { - m_size = size; - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - Traits::assign(data[size], Element()); // terminate + m_storage.first().SetSize(curSize); + pointer data = m_storage.first().GetData(); + Traits::assign(data[curSize], Element()); // terminate } } } - inline bool empty() const { return (m_size == 0); } - size_type copy(Element* dest /*, size_type destSize */, size_type count, size_type offset = 0) const + inline bool empty() const { return size() == 0; } + size_type copy(Element* dest, size_type count, size_type offset = 0) const { // copy [offset, offset + count) to [dest, dest + count) // assume there is enough space in _Ptr - AZSTD_CONTAINER_ASSERT(m_size >= offset, "Invalid offset"); - if (m_size - offset < count) + AZSTD_CONTAINER_ASSERT(size() >= offset, "Invalid offset"); + if (size() - offset < count) { - count = m_size - offset; + count = size() - offset; } - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - Traits::copy(dest /*, destSize*/, data + offset, count); + const_pointer data = m_storage.first().GetData(); + Traits::copy(dest, data + offset, count); return count; } @@ -939,19 +1024,10 @@ namespace AZStd return; } - if (m_allocator == rhs.m_allocator) + if (m_storage.second() == rhs.m_storage.second()) { - // same allocator, swap control information -#ifdef AZSTD_HAS_CHECKED_ITERATORS - swap_all(rhs); -#endif - Element temp[SSO_BUF_SIZE]; - ::memcpy(temp, rhs.m_buffer, sizeof(m_buffer)); - ::memcpy(rhs.m_buffer, m_buffer, sizeof(m_buffer)); - ::memcpy(m_buffer, temp, sizeof(m_buffer)); - - AZStd::swap(m_size, rhs.m_size); - AZStd::swap(m_capacity, rhs.m_capacity); + // same allocator, swap storage + m_storage.first().swap(rhs.m_storage.first()); } else { @@ -980,174 +1056,76 @@ namespace AZStd inline size_type find(const this_type& rhs, size_type offset = 0) const { - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - return find(rhsData, offset, rhs.m_size); + const_pointer rhsData = rhs.data(); + return find(rhsData, offset, rhs.size()); } size_type find(const_pointer ptr, size_type offset, size_type count) const { - AZ_Assert(ptr != NULL, "Invalid input!"); - - // look for [ptr, ptr + count) beginning at or after offset - if (count == 0 && offset <= m_size) - { - return offset; // null string always matches (if inside string) - } - size_type nm; - if (offset < m_size && count <= (nm = m_size - offset)) - { // room for match, look for it - const_pointer uptr, vptr; - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - for (nm -= count - 1, vptr = data + offset; (uptr = Traits::find(vptr, nm, *ptr)) != 0; nm -= uptr - vptr + 1, vptr = uptr + 1) - { - if (Traits::compare(uptr, ptr, count) == 0) - { - return (uptr - data); // found a match - } - } - } - - return (npos); // no match + return StringInternal::find(data(), size(), ptr, offset, count, npos); } inline size_type find(const_pointer ptr, size_type offset = 0) const { return find(ptr, offset, Traits::length(ptr)); } inline size_type find(Element ch, size_type offset = 0) const { return find((const_pointer) & ch, offset, 1); } inline size_type rfind(const this_type& rhs, size_type offset = npos) const { - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - return rfind(rhsData, offset, rhs.m_size); + const_pointer rhsData = rhs.data(); + return rfind(rhsData, offset, rhs.size()); } size_type rfind(const_pointer ptr, size_type offset, size_type count) const - { // look for [ptr, ptr + count) beginning before offset - if (count == 0) - { - return (offset < m_size ? offset : m_size); // null always matches - } - if (count <= m_size) - { // room for match, look for it - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - const_pointer uptr = data + (offset < m_size - count ? offset : m_size - count); - for (;; --uptr) - { - if (Traits::eq(*uptr, *ptr) && Traits::compare(uptr, ptr, count) == 0) - { - return (uptr - data); // found a match - } - else if (uptr == data) - { - break; // at beginning, no more chance for match - } - } - } - - return npos; // no match + { + return StringInternal::rfind(data(), size(), ptr, offset, count, npos); } inline size_type rfind(const_pointer ptr, size_type offset = npos) const { return rfind(ptr, offset, Traits::length(ptr)); } inline size_type rfind(Element ch, size_type offset = npos) const { return rfind((const_pointer) & ch, offset, 1); } inline size_type find_first_of(const this_type& rhs, size_type offset = 0) const { - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - return find_first_of(rhsData, offset, rhs.m_size); + const_pointer rhsData = rhs.data(); + return find_first_of(rhsData, offset, rhs.size()); } size_type find_first_of(const_pointer ptr, size_type offset, size_type count) const - { // look for one of [ptr, ptr + count) at or after offset - if (0 < count && offset < m_size) - { // room for match, look for it - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - const Element* const vptr = data + m_size; - for (const_pointer uptr = data + offset; uptr < vptr; ++uptr) - { - if (Traits::find(ptr, count, *uptr) != 0) - { - return uptr - data; // found a match - } - } - } - return npos; // no match + { + return StringInternal::find_first_of(data(), size(), ptr, offset, count, npos); } inline size_type find_first_of(const_pointer ptr, size_type offset = 0) const { return find_first_of(ptr, offset, Traits::length(ptr)); } inline size_type find_first_of(Element ch, size_type offset = 0) const { return find((const_pointer) & ch, offset, 1); } inline size_type find_last_of(const this_type& rhs, size_type offset = npos) const { - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - return find_last_of(rhsData, offset, rhs.m_size); + const_pointer rhsData = rhs.data(); + return find_last_of(rhsData, offset, rhs.size()); } size_type find_last_of(const_pointer ptr, size_type offset, size_type count) const - { // look for one of [ptr, ptr + count) before offset - if (0 < count && 0 < m_size) - { - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - for (const_pointer uptr = data + (offset < m_size ? offset : m_size - 1);; --uptr) - { - if (Traits::find(ptr, count, *uptr) != 0) - { - return uptr - data; // found a match - } - else if (uptr == data) - { - break; // at beginning, no more chance for match - } - } - } - - return npos; // no match + { + return StringInternal::find_last_of(data(), size(), ptr, offset, count, npos); } inline size_type find_last_of(const_pointer ptr, size_type offset = npos) const { return find_last_of(ptr, offset, Traits::length(ptr)); } inline size_type find_last_of(Element ch, size_type offset = npos) const { return rfind((const_pointer) & ch, offset, 1); } inline size_type find_first_not_of(const this_type& rhs, size_type offset = 0) const { // look for none of rhs at or after offset - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - return find_first_not_of(rhsData, offset, rhs.m_size); + const_pointer rhsData = rhs.data(); + return find_first_not_of(rhsData, offset, rhs.size()); } size_type find_first_not_of(const_pointer ptr, size_type offset, size_type count) const { - // look for none of [ptr, ptr + count) at or after offset - if (offset < m_size) - { // room for match, look for it - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - const Element* const vptr = data + m_size; - for (const_pointer uptr = data + offset; uptr < vptr; ++uptr) - { - if (Traits::find(ptr, count, *uptr) == 0) - { - return uptr - data; - } - } - } - return npos; + return StringInternal::find_first_not_of(data(), size(), ptr, offset, count, npos); } inline size_type find_first_not_of(const_pointer ptr, size_type offset = 0) const { return find_first_not_of(ptr, offset, Traits::length(ptr)); } inline size_type find_first_not_of(Element ch, size_type offset = 0) const { return find_first_not_of((const_pointer) & ch, offset, 1); } inline size_type find_last_not_of(const this_type& rhs, size_type offset = npos) const { // look for none of rhs before offset - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - return find_last_not_of(rhsData, offset, rhs.m_size); + const_pointer rhsData = rhs.data(); + return find_last_not_of(rhsData, offset, rhs.size()); } size_type find_last_not_of(const_pointer ptr, size_type offset, size_type count) const - { // look for none of [ptr, ptr + count) before offset - if (0 < m_size) - { - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - for (const_pointer uptr = data + (offset < m_size ? offset : m_size - 1);; --uptr) - { - if (Traits::find(ptr, count, *uptr) == 0) - { - return uptr - data; - } - else if (uptr == data) - { - break; - } - } - } - return npos; + { + return StringInternal::find_last_not_of(data(), size(), ptr, offset, count, npos); } inline size_type find_last_not_of(const_pointer ptr, size_type offset = npos) const { return find_last_not_of(ptr, offset, Traits::length(ptr)); } @@ -1161,8 +1139,8 @@ namespace AZStd inline int compare(const this_type& rhs) const { - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; - return compare(0, m_size, rhsData, rhs.m_size); + const_pointer rhsData = rhs.data(); + return compare(0, size(), rhsData, rhs.size()); } inline int compare(size_type offset, size_type count, const this_type& rhs) const @@ -1173,26 +1151,26 @@ namespace AZStd int compare(size_type offset, size_type count, const this_type& rhs, size_type rhsOffset, size_type rhsCount) const { // compare [offset, offset + count) with rhs [rhsOffset, rhsOffset + rhsCount) - AZSTD_CONTAINER_ASSERT(rhs.m_size >= rhsOffset, "Invalid offset"); - if (rhs.m_size - rhsOffset < rhsCount) + AZSTD_CONTAINER_ASSERT(rhs.size() >= rhsOffset, "Invalid offset"); + if (rhs.size() - rhsOffset < rhsCount) { - rhsCount = rhs.m_size - rhsOffset; // trim rhsCount to size + rhsCount = rhs.size() - rhsOffset; // trim rhsCount to size } - const_pointer rhsData = SSO_BUF_SIZE <= rhs.m_capacity ? rhs.m_data : rhs.m_buffer; + const_pointer rhsData = rhs.data(); return compare(offset, count, rhsData + rhsOffset, rhsCount); } - inline int compare(const_pointer ptr) const { return compare(0, m_size, ptr, Traits::length(ptr)); } + inline int compare(const_pointer ptr) const { return compare(0, size(), ptr, Traits::length(ptr)); } inline int compare(size_type offset, size_type count, const_pointer ptr) const { return compare(offset, count, ptr, Traits::length(ptr)); } int compare(size_type offset, size_type count, const_pointer ptr, size_type ptrCount) const { // compare [offset, offset + _N0) with [_Ptr, _Ptr + _Count) - AZSTD_CONTAINER_ASSERT(m_size >= offset, "Invalid offset"); - if (m_size - offset < count) + AZSTD_CONTAINER_ASSERT(size() >= offset, "Invalid offset"); + if (size() - offset < count) { - count = m_size - offset; // trim count to size + count = size() - offset; // trim count to size } - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + const_pointer data = m_storage.first().GetData(); size_type ans = Traits::compare(data + offset, ptr, count < ptrCount ? count : ptrCount); return (ans != 0 ? (int)ans : count < ptrCount ? -1 : count == ptrCount ? 0 : +1); } @@ -1231,11 +1209,11 @@ namespace AZStd inline void pop_back() { - if (m_size > 0) + if (!empty()) { - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - --m_size; - Traits::assign(data[m_size], Element()); // terminate + pointer data = m_storage.first().GetData(); + m_storage.first().SetSize(m_storage.first().GetSize() - 1); + Traits::assign(data[size()], Element()); // terminate } } @@ -1245,39 +1223,35 @@ namespace AZStd * @{ */ /// TR1 Extension. Return pointer to the vector data. The vector data is guaranteed to be stored as an array. - inline pointer data() { return (SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer); } - inline const_pointer data() const { return (SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer); } + inline pointer data() { return m_storage.first().GetData(); } + inline const_pointer data() const { return m_storage.first().GetData(); } /// /// The only difference from the standard is that we return the allocator instance, not a copy. - inline allocator_type& get_allocator() { return m_allocator; } - inline const allocator_type& get_allocator() const { return m_allocator; } + inline allocator_type& get_allocator() { return m_storage.second(); } + inline const allocator_type& get_allocator() const { return m_storage.second(); } /// Set the vector allocator. If different than then current all elements will be reallocated. void set_allocator(const allocator_type& allocator) { - if (m_allocator != allocator) + if (m_storage.second() != allocator) { - if (m_size > 0 && SSO_BUF_SIZE <= m_capacity) + if (!empty() && !m_storage.first().ShortStringOptimizationActive()) { allocator_type newAllocator = allocator; - pointer data = m_data; + pointer data = m_storage.first().GetData(); - pointer newData = reinterpret_cast(newAllocator.allocate(sizeof(node_type) * (m_capacity + 1), alignment_of::value)); + pointer newData = reinterpret_cast(newAllocator.allocate(sizeof(node_type) * (capacity() + 1), alignof(node_type))); - Traits::copy(newData, data, m_size + 1); // copy elements and terminator + Traits::copy(newData, data, size() + 1); // copy elements and terminator // Free memory (if needed). deallocate_memory(data, 0, typename allocator_type::allow_memory_leaks()); - m_allocator = newAllocator; - -#ifdef AZSTD_HAS_CHECKED_ITERATORS - orphan_all(); -#endif + m_storage.second() = newAllocator; } else { - m_allocator = allocator; + m_storage.second() = allocator; } } } @@ -1296,12 +1270,12 @@ namespace AZStd #else pointer iterPtr = iter; #endif - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - if (iterPtr < data || iterPtr > (data + m_size)) + const_pointer data = m_storage.first().GetData(); + if (iterPtr < data || iterPtr > (data + size())) { return isf_none; } - else if (iterPtr == (data + m_size)) + else if (iterPtr == (data + size())) { return isf_valid; } @@ -1316,12 +1290,12 @@ namespace AZStd #else const_pointer iterPtr = iter; #endif - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - if (iterPtr < data || iterPtr > (data + m_size)) + const_pointer data = m_storage.first().GetData(); + if (iterPtr < data || iterPtr > (data + size())) { return isf_none; } - else if (iterPtr == (data + m_size)) + else if (iterPtr == (data + size())) { return isf_valid; } @@ -1337,86 +1311,74 @@ namespace AZStd * \note This function is added to the vector for consistency. In the vector case we have only one allocation, and if the allocator allows memory leaks * it can just leave deallocate function empty, which performance wise will be the same. For more complex containers this will make big difference. */ - void leak_and_reset() + void leak_and_reset() { - m_size = 0; - m_capacity = SSO_BUF_SIZE - 1; - Traits::assign(m_buffer[0], Element()); - -#ifdef AZSTD_HAS_CHECKED_ITERATORS - orphan_all(); -#endif + m_storage.first() = {}; } /** * Set the capacity, if necessary it will erase elements at the end of the container to match the new capacity. */ - void set_capacity(size_type numElements) + void set_capacity(size_type numElements) { // sets the new capacity of the vector, can be smaller than size() - if (m_capacity != numElements) + if (capacity() != numElements) { - if (numElements < SSO_BUF_SIZE) + if (numElements < ShortStringData::Capacity) { - if (m_capacity >= SSO_BUF_SIZE) + if (!m_storage.first().ShortStringOptimizationActive()) { // copy any leftovers to small buffer and deallocate - pointer ptr = m_data; - numElements = numElements < m_size ? numElements : m_size; + pointer ptr = m_storage.first().GetData(); + numElements = numElements < size() ? numElements : size(); + m_storage.first().SetCapacity(ShortStringData::Capacity); if (0 < numElements) { - Traits::copy(m_buffer /*, SSO_BUF_SIZE*/, ptr, numElements); + Traits::copy(m_storage.first().GetData(), ptr, numElements); } - deallocate_memory(ptr, 0, typename allocator_type::allow_memory_leaks()); - m_capacity = SSO_BUF_SIZE - 1; + // deallocate_memory functione examines the current + // m_storage short string optimization state was changed to true + // by the SetCapacity call above. Therefore m_storage.second().deallocate + // is used directly + m_storage.second().deallocate(ptr, 0, alignof(node_type)); } - m_size = numElements; - Traits::assign(m_buffer[numElements], Element()); // terminate + m_storage.first().SetSize(numElements); + Traits::assign(m_storage.first().GetData()[numElements], Element()); // terminate } else { size_type expandedSize = 0; - if (m_capacity >= SSO_BUF_SIZE) + if (!m_storage.first().ShortStringOptimizationActive()) { - expandedSize = m_allocator.resize(m_data, sizeof(node_type) * (numElements + 1)); + expandedSize = m_storage.second().resize(m_storage.first().GetData(), sizeof(node_type) * (numElements + 1)); // our memory managers allocate on 8+ bytes boundary and our node type should be less than that in general, otherwise // we need to take care when we compute the size on deallocate. AZ_Assert(expandedSize % sizeof(node_type) == 0, "Expanded size not a multiply of node type. This should not happen"); size_type expandedCapacity = expandedSize / sizeof(node_type); if (expandedCapacity > numElements) { - m_capacity = expandedCapacity - 1; + m_storage.first().SetCapacity(expandedCapacity - 1); return; } } - pointer newData = reinterpret_cast(m_allocator.allocate(sizeof(node_type) * (numElements + 1), alignment_of::value)); - AZSTD_CONTAINER_ASSERT(newData != 0, "AZStd::string allocation failed!"); + pointer newData = reinterpret_cast(m_storage.second().allocate(sizeof(node_type) * (numElements + 1), alignof(node_type))); + AZSTD_CONTAINER_ASSERT(newData != nullptr, "AZStd::string allocation failed!"); - size_type newSize = numElements < m_size ? numElements : m_size; - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + size_type newSize = numElements < m_storage.first().GetSize() ? numElements : m_storage.first().GetSize(); + pointer data = m_storage.first().GetData(); if (newSize > 0) { - Traits::copy(newData /*, newSize + 1*/, data, newSize); // copy existing elements - } - if (m_capacity >= SSO_BUF_SIZE) - { - deallocate_memory(m_data, expandedSize, typename allocator_type::allow_memory_leaks()); + Traits::copy(newData, data, newSize); // copy existing elements } + deallocate_memory(data, expandedSize, typename allocator_type::allow_memory_leaks()); - m_data = newData; - m_capacity = numElements; - m_size = newSize; - Traits::assign(m_data[newSize], Element()); // terminate + Traits::assign(newData[newSize], Element()); // terminate + m_storage.first().SetCapacity(numElements); + m_storage.first().SetData(newData); + m_storage.first().SetSize(newSize); } - -#ifdef AZSTD_HAS_CHECKED_ITERATORS - // when we move data in the buffer we don't really need to make invalid all iterators, but it's - // very important that we are consistent, so people don't have different behavior when they have - // short strings - orphan_all(); -#endif } } @@ -1521,9 +1483,9 @@ namespace AZStd } }; -// Clang supports compile-time check for printf-like signatures -// On MSVC, *only* if /analyze flag is enabled(defines _PREFAST_) we can also do a compile-time check -// For not affecting final release binary size, we don't use the templated version on Release configuration either + // Clang supports compile-time check for printf-like signatures + // On MSVC, *only* if /analyze flag is enabled(defines _PREFAST_) we can also do a compile-time check + // For not affecting final release binary size, we don't use the templated version on Release configuration either #if AZ_COMPILER_CLANG || defined(_PREFAST_) || defined(_RELEASE) # if AZ_COMPILER_CLANG # define FORMAT_FUNC __attribute__((format(printf, 1, 2))) @@ -1597,137 +1559,70 @@ namespace AZStd template inline basic_string(const basic_string& rhs) - : m_size(0) - , m_capacity(SSO_BUF_SIZE - 1) { assign(rhs.c_str()); } template inline this_type& operator=(const basic_string& rhs) { return assign(rhs.c_str()); } template - inline this_type& append(const basic_string& rhs) { return append(rhs.c_str()); } + inline this_type& append(const basic_string& rhs) { return append(rhs.c_str()); } template inline this_type& insert(size_type offset, const basic_string& rhs) { return insert(offset, rhs.c_str()); } template inline this_type& replace(size_type offset, size_type count, const basic_string& rhs) { return replace(offset, count, rhs.c_str()); } template - inline int compare(const basic_string& rhs) { return compare(rhs.c_str()); } + inline int compare(const basic_string& rhs) { return compare(rhs.c_str()); } // @} protected: - enum - { // length of internal buffer, [1, 16] - SSO_BUF_SIZE = 16 / sizeof (Element) < 1 ? 1 : 16 / sizeof(Element) - }; enum { // roundup mask for allocated buffers, [0, 15] - _ALLOC_MASK = sizeof (Element) <= 1 ? 15 : sizeof (Element) <= 2 ? 7 : sizeof (Element) <= 4 ? 3 : sizeof (Element) <= 8 ? 1 : 0 + _ALLOC_MASK = sizeof(Element) <= 1 ? 15 + : sizeof(Element) <= 2 ? 7 + : sizeof(Element) <= 4 ? 3 + : sizeof(Element) <= 8 ? 1 : 0 }; - template - inline this_type& append_iter(InputIterator count, InputIterator ch, const true_type& /* is_integral */) - { // append count * ch - return append((size_type)count, (Element)ch); - } - - template - inline void construct_iter(InputIterator count, InputIterator ch, const true_type& /* is_integral */) - { // initialize from count * ch - assign((size_type)count, (Element)ch); - } - - template - inline void construct_iter(InputIterator first, InputIterator last, const false_type& /*, const input_iterator_tag&*/) - { - // initialize from [first, last), input iterators - // \todo use insert ? - for (; first != last; ++first) - { - append((size_type)1, (Element) * first); - } - } - - - template - inline this_type& append_iter(InputIterator first, InputIterator last, const false_type& /* !is_integral */) - { // append [first, last), input iterators - return replace(end(), end(), first, last); - } - - - template - inline this_type& assign_iter(InputIterator count, InputIterator ch, const true_type&) { return assign((size_type)count, (Element)ch); } - template - inline this_type& assign_iter(InputIterator first, InputIterator last, const false_type&){ return replace(begin(), end(), first, last); } - - template - inline void insert_iter(const_iterator insertPos, InputIterator count, InputIterator ch, const true_type& /* is_integral() */) - { // insert count * ch at insertPos - insert(insertPos, (size_type)count, (Element)ch); - } - - template - inline void insert_iter(const_iterator insertPos, InputIterator first, InputIterator last, const false_type& /* is_integral() */) - { // insert [first, last) at insertPos, input iterators - replace(insertPos, insertPos, first, last); - } - - - template - inline this_type& replace_iter(const_iterator first, const_iterator last, InputIterator count, InputIterator ch, const true_type& /* is_intergral */) - { // replace [first, last) with count * ch - return replace(first, last, (size_type)count, (Element)ch); - } - - template - inline this_type& replace_iter(const_iterator first, const_iterator last, InputIterator first2, InputIterator last2, const false_type& /* !is_intergral */) - { // replace [first, last) with [first2, last2), input iterators - this_type rhs(first2, last2); - replace(first, last, rhs); - return *this; - } - void copy(size_type newSize, size_type oldLength) { size_type newCapacity = newSize | _ALLOC_MASK; - if (newCapacity / 3 < m_capacity / 2) + size_type currentCapacity = capacity(); + if (newCapacity / 3 < currentCapacity / 2) { - newCapacity = m_capacity + m_capacity / 2; // grow exponentially if possible + newCapacity = currentCapacity + currentCapacity / 2; // grow exponentially if possible } - if (newCapacity >= SSO_BUF_SIZE) + if (newCapacity >= ShortStringData::Capacity) { size_type expandedSize = 0; - if (m_capacity >= SSO_BUF_SIZE) + if (!m_storage.first().ShortStringOptimizationActive()) { - expandedSize = m_allocator.resize(m_data, sizeof(node_type) * (newCapacity + 1)); + expandedSize = m_storage.second().resize(m_storage.first().GetData(), sizeof(node_type) * (newCapacity + 1)); // our memory managers allocate on 8+ bytes boundary and our node type should be less than that in general, otherwise // we need to take care when we compute the size on deallocate. - AZ_Assert(expandedSize % sizeof(node_type) == 0, "Expanded size not a multiply of node type. This should not happen"); + AZ_Assert(expandedSize % sizeof(node_type) == 0, "Expanded size not a multiple of node type. This should not happen"); size_type expandedCapacity = expandedSize / sizeof(node_type); if (expandedCapacity > newCapacity) { - m_capacity = expandedCapacity - 1; + m_storage.first().SetCapacity(expandedCapacity - 1); return; } } - pointer newData = reinterpret_cast(m_allocator.allocate(sizeof(node_type) * (newCapacity + 1), alignment_of::value)); - AZSTD_CONTAINER_ASSERT(newData != 0, "AZStd::string allocation failed!"); + pointer newData = reinterpret_cast(m_storage.second().allocate(sizeof(node_type) * (newCapacity + 1), alignof(node_type))); + AZSTD_CONTAINER_ASSERT(newData != nullptr, "AZStd::string allocation failed!"); if (newData) { - const_pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; + pointer data = m_storage.first().GetData(); if (0 < oldLength) { - Traits::copy(newData /*, newSize + 1*/, data, oldLength); // copy existing elements - } - if (m_capacity >= SSO_BUF_SIZE) - { - deallocate_memory(m_data, expandedSize, typename allocator_type::allow_memory_leaks()); + Traits::copy(newData, data, oldLength); // copy existing elements } + deallocate_memory(data, expandedSize, typename allocator_type::allow_memory_leaks()); - m_data = newData; - m_capacity = newCapacity; - Traits::assign(m_data[newSize], Element()); // terminate + Traits::assign(newData[oldLength], Element()); // terminate + m_storage.first().SetCapacity(newCapacity); + m_storage.first().SetSize(oldLength); + m_storage.first().SetData(newData); } } } @@ -1735,40 +1630,209 @@ namespace AZStd bool grow(size_type newSize) { // ensure buffer is big enough, trim to size if _Trim is true - if (m_capacity < newSize) + if (capacity() < newSize) { - copy(newSize, m_size); // reallocate to grow + copy(newSize, size()); // reallocate to grow } else if (newSize == 0) { - pointer data = SSO_BUF_SIZE <= m_capacity ? m_data : m_buffer; - m_size = 0; + pointer data = m_storage.first().GetData(); + m_storage.first().SetSize(0); Traits::assign(data[0], Element()); // terminate } return (0 < newSize); // return true only if more work to do } + bool fits_in_capacity(size_type newSize) + { + return newSize <= capacity(); + } + inline void deallocate_memory(pointer, size_type, const true_type& /* allocator::allow_memory_leaks */) {} inline void deallocate_memory(pointer data, size_type expandedSize, const false_type& /* !allocator::allow_memory_leaks */) { - if (m_capacity >= SSO_BUF_SIZE) + if (!m_storage.first().ShortStringOptimizationActive()) { - size_type byteSize = (expandedSize == 0) ? (sizeof(node_type) * (m_capacity + 1)) : expandedSize; - m_allocator.deallocate(data, byteSize, alignment_of::value); + size_type byteSize = (expandedSize == 0) ? (sizeof(node_type) * (m_storage.first().GetCapacity() + 1)) : expandedSize; + m_storage.second().deallocate(data, byteSize, alignof(node_type)); } } - union //Storage + //! Assuming 64-bit for pointer and size_t size + //! The offset and sizes of each structure are marked below + + //! dynamically allocated data + struct AllocatedStringData { - Element m_buffer[SSO_BUF_SIZE]; //< small buffer used for small string optimization - pointer m_data; //< dynamically allocated data + AllocatedStringData() + { + m_capacity = 0; + m_ssoActive = false; + } + // bit offset: 0, bits: 64 + pointer m_data{}; + + // bit offset: 64, bit: 64 + size_type m_size{}; + + // Use all but the top bit of a size_t for the string capacity + // This allows the short string optimization to be used + // with no additional space at the cost of cutting the max_size in half + // to 2^63-1 + // offset: 128, bits: 63 + size_type m_capacity : AZStd::numeric_limits::digits - 1; + + // bit offset: 191, bits: 1 + size_type m_ssoActive : 1; + + // Total size 192 bits(24 bytes) }; - size_type m_size; // current length of string - size_type m_capacity; // current storage reserved for string - allocator_type m_allocator; + static_assert(sizeof(AllocatedStringData) <= 24, "The AllocatedStringData structure" + " should be an 8-byte pointer, 8 byte size, 63-bit capacity and 1-bit SSO flag for" + " a total of 24 bytes"); + + //! small buffer used for small string optimization + struct ShortStringData + { + //! The size can be stored within 7 bits since the buffer will be no larger + //! than 23 bytes(22 characters + 1 null-terminating character) + inline static constexpr size_type BufferMaxSize = sizeof(AllocatedStringData) - sizeof(AZ::u8); + static_assert(sizeof(Element) < BufferMaxSize, "The size of Element type must be less than the size of " + " the AllocatedStringData struct in order to use it with the basic_string class"); + inline static constexpr size_type BufferCapacityPlusNull = BufferMaxSize / sizeof(Element); + + inline static constexpr size_type Capacity = BufferCapacityPlusNull - 1; + + ShortStringData() + { + // Make sure the short string buffer is null-terminated + m_buffer[0] = Element{}; + m_size = 0; + m_ssoActive = true; + } + + // bit offset: 0, bits: 184 + Element m_buffer[BufferCapacityPlusNull]; + + // Padding to make sure for Element types with a size >1 + // such as wchar_t, that the `m_size` member starts at the bit 164 + // NOTE: Uses the anonymous struct extension + // supported by MSVC, Clang and GCC + // Takes advantage of the empty base optimization + // to have the StringInternal::Padding struct + // take 0 bytes when the Element type is 1-byte type like `char` + // When C++20 support is added, this can be changed to use [[no_unique_address]] + struct + : StringInternal::Padding + { + + // bit offset: 184, bits: 7 + AZ::u8 m_size : AZStd::numeric_limits::digits - 1; + + // bit offset: 191, bits: 1 + AZ::u8 m_ssoActive : 1; + }; + // Total size 192 bits(24 bytes) + }; + + struct PointerAlignedData + { + uintptr_t m_alignedValues[sizeof(ShortStringData) / sizeof(uintptr_t)]; + }; + + static_assert(sizeof(AllocatedStringData) == sizeof(ShortStringData) && "Short string struct must be the same size" + " as the regular allocated string struct"); + + static_assert(sizeof(PointerAlignedData) == sizeof(ShortStringData) && "Pointer aligned struct must be the same size" + " as the short string struct "); + + // The top-bit in the last byte of the AllocatedStringData and ShortStringData is used to determine if the short string optimization is being used + union Storage + { + Storage() {}; + + bool ShortStringOptimizationActive() const + { + return m_shortData.m_ssoActive; + } + const_pointer GetData() const + { + return ShortStringOptimizationActive() ? m_shortData.m_buffer + : reinterpret_cast(m_shortData).m_data; + } + pointer GetData() + { + return ShortStringOptimizationActive() ? m_shortData.m_buffer + : reinterpret_cast(m_shortData).m_data; + } + void SetData(pointer address) + { + if (!ShortStringOptimizationActive()) + { + reinterpret_cast(m_shortData).m_data = address; + } + else + { + AZSTD_CONTAINER_ASSERT(false, "Programming Error: string class is invoking SetData when the Short Optimization" + " is active. Make sure SetCapacity() is invoked" + " before calling this function."); + } + } + size_type GetSize() const + { + return ShortStringOptimizationActive() ? m_shortData.m_size + : reinterpret_cast(m_shortData).m_size; + } + void SetSize(size_type size) + { + if (ShortStringOptimizationActive()) + { + m_shortData.m_size = size; + } + else + { + reinterpret_cast(m_shortData).m_size = size; + } + } + size_type GetCapacity() const + { + return ShortStringOptimizationActive() ? m_shortData.Capacity + : reinterpret_cast(m_shortData).m_capacity; + } + void SetCapacity(size_type capacity) + { + if (capacity <= ShortStringData::Capacity) + { + m_shortData.m_ssoActive = true; + } + else + { + m_shortData.m_ssoActive = false; + reinterpret_cast(m_shortData).m_capacity = capacity; + } + } + void swap(Storage& rhs) + { + // Use pointer sized swaps to swap the string storage + AZStd::aligned_storage_for_t tempStorage; + ::memcpy(&tempStorage, this, sizeof(Storage)); + ::memcpy(this, &rhs, sizeof(Storage)); + ::memcpy(&rhs, &tempStorage, sizeof(Storage)); + } + private: + ShortStringData m_shortData{}; + AllocatedStringData m_allocatedData; + PointerAlignedData m_pointerData; + }; + + AZStd::compressed_pair m_storage; + +#if defined(HAVE_BENCHMARK) + friend class Benchmark::StringBenchmarkFixture; +#endif #ifdef AZSTD_HAS_CHECKED_ITERATORS void orphan_range(pointer first, pointer last) const @@ -1809,18 +1873,7 @@ namespace AZStd }; template - const typename basic_string::size_type basic_string::npos; - - // basic_string implements a performant swap - /*template - class move_operation_category > - { - public: - typedef swap_move_tag move_cat; - };*/ - - template - inline void swap(basic_string& left, basic_string& right) + inline void swap(basic_string& left, basic_string& right) { left.swap(right); } @@ -2018,15 +2071,11 @@ namespace AZStd template struct hash< basic_string< Element, Traits, Allocator> > { - typedef basic_string< Element, Traits, Allocator> argument_type; - typedef AZStd::size_t result_type; - inline result_type operator()(const argument_type& value) const + using is_transparent = void; + inline constexpr size_t operator()(const basic_string_view& value) const { return hash_string(value.begin(), value.length()); } }; } // namespace AZStd - -#endif // AZSTD_STRING_H -#pragma once diff --git a/Code/Framework/AzCore/AzCore/std/string/string_view.h b/Code/Framework/AzCore/AzCore/std/string/string_view.h index 30e61f95ce..841044dd16 100644 --- a/Code/Framework/AzCore/AzCore/std/string/string_view.h +++ b/Code/Framework/AzCore/AzCore/std/string/string_view.h @@ -280,18 +280,36 @@ namespace AZStd static constexpr char_type* assign(char_type* dest, size_t count, char_type ch) noexcept { AZ_Assert(dest, "Invalid input!"); - for (char_type* iter = dest; count; --count, ++iter) + + if constexpr (AZStd::is_same_v) { - assign(*iter, ch); + // Use builtin_memset if available for char type + if (az_builtin_is_constant_evaluated()) + { + for (char_type* iter = dest; count; --count, ++iter) + { + assign(*iter, ch); + } + } + else + { + ::memset(dest, ch, count); + } + } + else + { + for (char_type* iter = dest; count; --count, ++iter) + { + assign(*iter, ch); + } } + return dest; } static constexpr bool eq(char_type left, char_type right) noexcept { return left == right; } static constexpr bool lt(char_type left, char_type right) noexcept { return left < right; } static constexpr int compare(const char_type* s1, const char_type* s2, size_t count) noexcept { - // Regression in VS2017 15.8 and 15.9 where __builtin_memcmp fails in valid checks in constexpr evaluation -#if !defined(AZ_COMPILER_MSVC) || AZ_COMPILER_MSVC < 1915 || AZ_COMPILER_MSVC > 1916 if constexpr (AZStd::is_same_v) { return __builtin_memcmp(s1, s2, count); @@ -301,7 +319,6 @@ namespace AZStd return __builtin_wmemcmp(s1, s2, count); } else -#endif { for (; count; --count, ++s1, ++s2) { @@ -339,10 +356,6 @@ namespace AZStd } static constexpr const char_type* find(const char_type* s, size_t count, const char_type& ch) noexcept { - // There is a bug with the __builtin_char_memchr intrinsic in Visual Studio 2017 15.8.x and 15.9.x - // It reads in one more additional character than the value of count. - // This is probably due to assuming null-termination -#if !defined(AZ_COMPILER_MSVC) || AZ_COMPILER_MSVC < 1915 || AZ_COMPILER_MSVC > 1916 if constexpr (AZStd::is_same_v) { return __builtin_char_memchr(s, ch, count); @@ -353,7 +366,6 @@ namespace AZStd } else -#endif { for (; count; --count, ++s) { @@ -368,64 +380,112 @@ namespace AZStd static constexpr char_type* move(char_type* dest, const char_type* src, size_t count) noexcept { AZ_Assert(dest != nullptr && src != nullptr, "Invalid input!"); - if (count == 0) + if (count == 0 || src == dest) { return dest; } - char_type* result = dest; - // The less than(<), greater than(>) and other variants(<=, >=) - // Cannot be compare pointers within a constexpr due to the potential for undefined behavior - // per the bullet linked in the C++ standard at http://eel.is/c++draft/expr.compound#expr.rel-5 - // Now clang and gcc compilers allow the use of this relation operators in a constexpr, but - // msvc is not so forgiving - // So a workaround of iterating the src pointer, checking for equality with the dest pointer - // is used to check for overlap - auto should_copy_forward = [](const char_type* dest1, const char_type* src2, size_t count2) constexpr -> bool - { - bool dest_less_than_src{ true }; - for(const char_type* src_iter = src2; src_iter != src2 + count2; ++src_iter) + + #if az_has_builtin_memmove + __builtin_memmove(dest, src, count * sizeof(char_type)); + #else + auto NonBuiltinMove = [](char_type* dest1, const char_type* src1, size_t count1) constexpr + -> char_type* + { + if (az_builtin_is_constant_evaluated()) { - if (src_iter == dest1) + // The less than(<), greater than(>) and other variants(<=, >=) + // Cannot be compare pointers within a constexpr due to the potential for undefined behavior + // per the bullet linked in the C++ standard at http://eel.is/c++draft/expr.compound#expr.rel-5 + // Now clang and gcc compilers allow the use of this relation operators in a constexpr, but + // msvc is not so forgiving + // So a workaround of iterating the src pointer, checking for equality with the dest pointer + // is used to check for overlap + auto should_copy_forward = [](const char_type* dest2, const char_type* src2, size_t count2) constexpr -> bool + { + bool dest_less_than_src{ true }; + for (const char_type* src_iter = src2; src_iter != src2 + count2; ++src_iter) + { + if (src_iter == dest2) + { + dest_less_than_src = false; + break; + } + } + return dest_less_than_src; + }; + + if (should_copy_forward(dest1, src1, count1)) { - dest_less_than_src = false; - break; + copy(dest1, src1, count1); + } + else + { + copy_backward(dest1, src1, count1); } } - return dest_less_than_src; - }; + else + { + // Use the faster ::memmove operation at runtime + ::memmove(dest1, src1, count1 * sizeof(char_type)); + } - if (should_copy_forward(dest, src, count)) - { - copy(dest, src, count); - } - else - { - copy_backward(dest, src, count); - } + return dest1; + }; + NonBuiltinMove(dest, src, count); + #endif - return result; + return dest; } static constexpr char_type* copy(char_type* dest, const char_type* src, size_t count) noexcept { AZ_Assert(dest != nullptr && src != nullptr, "Invalid input!"); - char_type* result = dest; - for(; count; --count, ++dest, ++src) + + #if az_has_builtin_memcpy + __builtin_memcpy(dest, src, count * sizeof(char_type)); + #else + auto NonBuiltinCopy = [](char_type* dest1, const char_type* src1, size_t count1) constexpr + -> char_type* { - assign(*dest, *src); - } - return result; + if (az_builtin_is_constant_evaluated()) + { + for (; count1; --count1, ++dest1, ++src1) + { + assign(*dest1, *src1); + } + } + else + { + ::memcpy(dest1, src1, count1 * sizeof(char_type)); + } + return dest1; + }; + NonBuiltinCopy(dest, src, count); + #endif + + return dest; } // Extension for constexpr workarounds: Addresses of a string literal cannot be compared at compile time and MSVC and clang will just refuse to compile the constexpr // Adding a copy_backwards overload that always copies backwards. - static constexpr char_type* copy_backward(char_type* dest, const char_type*src, size_t count) noexcept + static constexpr char_type* copy_backward(char_type* dest, const char_type* src, size_t count) noexcept { char_type* result = dest; - dest += count; - src += count; - for (; count; --count) + #if az_has_builtin_memmove + __builtin_memmove(dest, src, count * sizeof(char_type)); + #else + if (az_builtin_is_constant_evaluated()) + { + dest += count; + src += count; + for (; count; --count) + { + assign(*--dest, *--src); + } + } + else { - assign(*--dest, *--src); + ::memmove(dest, src, count); } + #endif return result; } diff --git a/Code/Framework/AzCore/CMakeLists.txt b/Code/Framework/AzCore/CMakeLists.txt index 96ed838ccc..01f4086a18 100644 --- a/Code/Framework/AzCore/CMakeLists.txt +++ b/Code/Framework/AzCore/CMakeLists.txt @@ -9,8 +9,8 @@ # TODO: would like to be able to build from this path, however, the whole setup is done at the workspace's root # we also dont want to drop cmake output files everywhere. -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) +set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) if(PAL_TRAIT_PROF_PIX_SUPPORTED) set(LY_PIX_ENABLED OFF CACHE BOOL "Enables PIX profiler integration.") @@ -110,15 +110,15 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) AZ::AzTest ) - ly_get_list_relative_pal_filename(pal_test_dir ${CMAKE_CURRENT_LIST_DIR}/Tests/Platform/${PAL_PLATFORM_NAME}) + o3de_pal_dir(pal_tests_dir ${CMAKE_CURRENT_LIST_DIR}/Tests/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME AzCore.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} NAMESPACE AZ FILES_CMAKE Tests/azcoretests_files.cmake - ${pal_test_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake + ${pal_tests_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake PLATFORM_INCLUDE_FILES - ${pal_test_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}.cmake + ${pal_tests_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}.cmake INCLUDE_DIRECTORIES PRIVATE Tests @@ -146,6 +146,11 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) PROPERTY COMPILE_DEFINITIONS VALUES AZCORETEST_DLL_NAME=\"$\" ) + ly_add_target_files( + TARGETS AzCore.Tests + FILES ${CMAKE_CURRENT_SOURCE_DIR}/Tests/Memory/AllocatorBenchmarkRecordings.bin + OUTPUT_SUBDIRECTORY Tests/AzCore/Memory + ) endif() diff --git a/Code/Framework/AzCore/Platform/Common/VisualStudio/AzCore/Natvis/azcore.natvis b/Code/Framework/AzCore/Platform/Common/VisualStudio/AzCore/Natvis/azcore.natvis index 3730b8a4f9..dca82e2439 100644 --- a/Code/Framework/AzCore/Platform/Common/VisualStudio/AzCore/Natvis/azcore.natvis +++ b/Code/Framework/AzCore/Platform/Common/VisualStudio/AzCore/Natvis/azcore.natvis @@ -10,6 +10,13 @@ + + {m_element} + + + {$T1} is empty + + reverse_iterator base() {m_current} @@ -388,35 +395,41 @@ - - {m_buffer,s} - {m_data,s} - m_buffer,s - m_data,s + + {((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_buffer,s} + {((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_data,s} + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_buffer,s + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_data,s - m_size - m_capacity + (size_t)((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_size + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_size + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.Capacity + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_capacity - m_size - m_buffer - m_data + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_size,u + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_size + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_buffer + ((AZStd::compressed_pair_element<AZStd::basic_string<char,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_data - {m_buffer,su} - {m_data,su} - m_buffer,su - m_data,su - - m_size - m_capacity + {((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_buffer,su} + {((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_data,su} + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_buffer,su + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_data,su + + (size_t)((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_size + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_size + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.Capacity + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_capacity - m_size - m_buffer - m_data + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_size,u + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_size + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_shortData.m_buffer + ((AZStd::compressed_pair_element<AZStd::basic_string<wchar_t,$T1,$T2>::Storage,0,0>&)m_storage).m_element.m_allocatedData.m_data diff --git a/Code/Framework/AzCore/Tests/AZStd/String.cpp b/Code/Framework/AzCore/Tests/AZStd/String.cpp index 356310a94d..0f84ad0970 100644 --- a/Code/Framework/AzCore/Tests/AZStd/String.cpp +++ b/Code/Framework/AzCore/Tests/AZStd/String.cpp @@ -8,11 +8,11 @@ #include "UserTypes.h" #include -#include #include #include #include #include +#include #include #include #include @@ -21,13 +21,10 @@ #include // we need this for AZ_TEST_FLOAT compare -#include #include #include #include -using namespace AZStd; - // Because of the SSO (small string optimization) we always shoule have capacity != 0 and data != 0 #define AZ_TEST_VALIDATE_EMPTY_STRING(_String) \ EXPECT_TRUE(_String.validate()); \ @@ -81,8 +78,6 @@ namespace UnitTest va_end(mark); } -#if !AZ_UNIT_TEST_SKIP_STD_STRING_TESTS - TEST(StringC, VSNPrintf) { char buffer32[32]; @@ -168,75 +163,75 @@ namespace UnitTest { const char* sChar = "SSO string"; // 10 characters const char* sCharLong = "This is a long string test that will allocate"; // 45 characters - array aChar = { + AZStd::array aChar = { { 'a', 'b', 'c', 'd', 'e', 'f' } }; // short string (should use SSO) - string str1; + AZStd::string str1; AZ_TEST_VALIDATE_EMPTY_STRING(str1); // short char* - string str2(sChar); + AZStd::string str2(sChar); AZ_TEST_VALIDATE_STRING(str2, 10); - string str2_1(""); + AZStd::string str2_1(""); AZ_TEST_VALIDATE_EMPTY_STRING(str2_1); - string str3(sChar, 5); + AZStd::string str3(sChar, 5); AZ_TEST_VALIDATE_STRING(str3, 5); // long char* - string str4(sCharLong); + AZStd::string str4(sCharLong); AZ_TEST_VALIDATE_STRING(str4, 45); - string str5(sCharLong, 35); + AZStd::string str5(sCharLong, 35); AZ_TEST_VALIDATE_STRING(str5, 35); // element - string str6(13, 'a'); + AZStd::string str6(13, 'a'); AZ_TEST_VALIDATE_STRING(str6, 13); - string str6_1(0, 'a'); + AZStd::string str6_1(0, 'a'); AZ_TEST_VALIDATE_EMPTY_STRING(str6_1); - string str7(aChar.begin(), aChar.end()); + AZStd::string str7(aChar.begin(), aChar.end()); AZ_TEST_VALIDATE_STRING(str7, 6); - string str7_1(aChar.begin(), aChar.begin()); + AZStd::string str7_1(aChar.begin(), aChar.begin()); AZ_TEST_VALIDATE_EMPTY_STRING(str7_1); - string str8(sChar, sChar + 3); + AZStd::string str8(sChar, sChar + 3); AZ_TEST_VALIDATE_STRING(str8, 3); - string str8_1(sChar, sChar); + AZStd::string str8_1(sChar, sChar); AZ_TEST_VALIDATE_EMPTY_STRING(str8_1); // - string str9(str2); + AZStd::string str9(str2); AZ_TEST_VALIDATE_STRING(str9, 10); - string str9_1(str1); + AZStd::string str9_1(str1); AZ_TEST_VALIDATE_EMPTY_STRING(str9_1); - string str10(str2, 4); + AZStd::string str10(str2, 4); AZ_TEST_VALIDATE_STRING(str10, 6); - string str11(str2, 4, 3); + AZStd::string str11(str2, 4, 3); AZ_TEST_VALIDATE_STRING(str11, 3); - string str12(sChar); - string large = sCharLong; + AZStd::string str12(sChar); + AZStd::string large = sCharLong; // move ctor - string strSm = AZStd::move(str12); + AZStd::string strSm = AZStd::move(str12); AZ_TEST_VALIDATE_STRING(strSm, 10); AZ_TEST_VALIDATE_EMPTY_STRING(str12); - string strLg(AZStd::move(large)); + AZStd::string strLg(AZStd::move(large)); AZ_TEST_VALIDATE_STRING(strLg, 45); AZ_TEST_VALIDATE_EMPTY_STRING(large); - string strEmpty(AZStd::move(str1)); + AZStd::string strEmpty(AZStd::move(str1)); AZ_TEST_VALIDATE_EMPTY_STRING(strEmpty); AZ_TEST_VALIDATE_EMPTY_STRING(str1); @@ -369,7 +364,7 @@ namespace UnitTest AZ_TEST_VALIDATE_STRING(str2, 28); AZ_TEST_ASSERT(str2[0] == 'b'); - str2.erase(str2.begin(), next(str2.begin(), 4)); + str2.erase(str2.begin(), AZStd::next(str2.begin(), 4)); AZ_TEST_VALIDATE_STRING(str2, 24); AZ_TEST_ASSERT(str2[0] == 'f'); @@ -400,33 +395,33 @@ namespace UnitTest AZ_TEST_ASSERT(str2[3] == 'g'); AZ_TEST_ASSERT(str2[4] == 'g'); - str2.replace(str2.begin(), next(str2.begin(), str1.length()), str1); + str2.replace(str2.begin(), AZStd::next(str2.begin(), str1.length()), str1); AZ_TEST_VALIDATE_STRING(str2, 24); AZ_TEST_ASSERT(str2[0] == 'a'); AZ_TEST_ASSERT(str2[1] == 'b'); - str2.replace(str2.begin(), next(str2.begin(), 10), sChar); + str2.replace(str2.begin(), AZStd::next(str2.begin(), 10), sChar); AZ_TEST_VALIDATE_STRING(str2, 24); AZ_TEST_ASSERT(str2[0] == 'S'); AZ_TEST_ASSERT(str2[1] == 'S'); - str2.replace(str2.begin(), next(str2.begin(), 3), sChar, 3); + str2.replace(str2.begin(), AZStd::next(str2.begin(), 3), sChar, 3); AZ_TEST_VALIDATE_STRING(str2, 24); AZ_TEST_ASSERT(str2[0] == 'S'); AZ_TEST_ASSERT(str2[1] == 'S'); AZ_TEST_ASSERT(str2[2] == 'O'); - str2.replace(str2.begin(), next(str2.begin(), 2), 2, 'h'); + str2.replace(str2.begin(), AZStd::next(str2.begin(), 2), 2, 'h'); AZ_TEST_VALIDATE_STRING(str2, 24); AZ_TEST_ASSERT(str2[0] == 'h'); AZ_TEST_ASSERT(str2[1] == 'h'); - str2.replace(str2.begin(), next(str2.begin(), 2), aChar.begin(), next(aChar.begin(), 2)); + str2.replace(str2.begin(), AZStd::next(str2.begin(), 2), aChar.begin(), AZStd::next(aChar.begin(), 2)); AZ_TEST_VALIDATE_STRING(str2, 24); AZ_TEST_ASSERT(str2[0] == 'a'); AZ_TEST_ASSERT(str2[1] == 'b'); - str2.replace(str2.begin(), next(str2.begin(), 2), sChar, sChar + 5); + str2.replace(str2.begin(), AZStd::next(str2.begin(), 2), sChar, sChar + 5); AZ_TEST_VALIDATE_STRING(str2, 27); AZ_TEST_ASSERT(str2[0] == 'S'); AZ_TEST_ASSERT(str2[1] == 'S'); @@ -489,7 +484,7 @@ namespace UnitTest AZ_TEST_ASSERT(pos == 2); pos = str1.find('Z'); - AZ_TEST_ASSERT(pos == string::npos); + AZ_TEST_ASSERT(pos == AZStd::string::npos); pos = str1.rfind(str2); AZ_TEST_ASSERT(pos == 12); @@ -510,7 +505,7 @@ namespace UnitTest AZ_TEST_ASSERT(pos == 12); pos = str1.rfind('Z'); - AZ_TEST_ASSERT(pos == string::npos); + AZ_TEST_ASSERT(pos == AZStd::string::npos); pos = str1.find_first_of(str2); AZ_TEST_ASSERT(pos == 2); @@ -535,7 +530,7 @@ namespace UnitTest AZ_TEST_ASSERT(pos == 12); pos = str1.find_first_of('Z'); - AZ_TEST_ASSERT(pos == string::npos); + AZ_TEST_ASSERT(pos == AZStd::string::npos); pos = str1.find_last_of(str2); AZ_TEST_ASSERT(pos == 14); @@ -550,7 +545,7 @@ namespace UnitTest AZ_TEST_ASSERT(pos == 12); pos = str1.find_last_of('Z'); - AZ_TEST_ASSERT(pos == string::npos); + AZ_TEST_ASSERT(pos == AZStd::string::npos); pos = str1.find_first_not_of(str2, 3); AZ_TEST_ASSERT(pos == 5); @@ -559,13 +554,13 @@ namespace UnitTest AZ_TEST_ASSERT(pos == 0); pos = str1.find_last_not_of(sChar); - AZ_TEST_ASSERT(pos == string::npos); + AZ_TEST_ASSERT(pos == AZStd::string::npos); pos = str1.find_last_not_of('Z'); AZ_TEST_ASSERT(pos == 19); - string sub = str1.substr(0, 10); + AZStd::string sub = str1.substr(0, 10); AZ_TEST_VALIDATE_STRING(sub, 10); AZ_TEST_ASSERT(sub[0] == 'S'); AZ_TEST_ASSERT(sub[9] == 'g'); @@ -594,13 +589,13 @@ namespace UnitTest using iteratorType = char; auto testValue = str4; - reverse_iterator rend = testValue.rend(); - reverse_iterator crend1 = testValue.rend(); - reverse_iterator crend2 = testValue.crend(); + AZStd::reverse_iterator rend = testValue.rend(); + AZStd::reverse_iterator crend1 = testValue.rend(); + AZStd::reverse_iterator crend2 = testValue.crend(); - reverse_iterator rbegin = testValue.rbegin(); - reverse_iterator crbegin1 = testValue.rbegin(); - reverse_iterator crbegin2 = testValue.crbegin(); + AZStd::reverse_iterator rbegin = testValue.rbegin(); + AZStd::reverse_iterator crbegin1 = testValue.rbegin(); + AZStd::reverse_iterator crbegin2 = testValue.crbegin(); AZ_TEST_ASSERT(rend == crend1); AZ_TEST_ASSERT(crend1 == crend2); @@ -630,128 +625,128 @@ namespace UnitTest TEST_F(String, Algorithms) { - string str = string::format("%s %d", "BlaBla", 5); + AZStd::string str = AZStd::string::format("%s %d", "BlaBla", 5); AZ_TEST_VALIDATE_STRING(str, 8); - wstring wstr = wstring::format(L"%ls %d", L"BlaBla", 5); + AZStd::wstring wstr = AZStd::wstring::format(L"%ls %d", L"BlaBla", 5); AZ_TEST_VALIDATE_WSTRING(wstr, 8); - to_lower(str.begin(), str.end()); + AZStd::to_lower(str.begin(), str.end()); AZ_TEST_ASSERT(str[0] == 'b'); AZ_TEST_ASSERT(str[3] == 'b'); - to_upper(str.begin(), str.end()); + AZStd::to_upper(str.begin(), str.end()); AZ_TEST_ASSERT(str[1] == 'L'); AZ_TEST_ASSERT(str[2] == 'A'); - string intStr("10"); + AZStd::string intStr("10"); int ival = AZStd::stoi(intStr); AZ_TEST_ASSERT(ival == 10); - wstring wintStr(L"10"); + AZStd::wstring wintStr(L"10"); ival = AZStd::stoi(wintStr); AZ_TEST_ASSERT(ival == 10); - string floatStr("2.32"); + AZStd::string floatStr("2.32"); float fval = AZStd::stof(floatStr); AZ_TEST_ASSERT_FLOAT_CLOSE(fval, 2.32f); - wstring wfloatStr(L"2.32"); + AZStd::wstring wfloatStr(L"2.32"); fval = AZStd::stof(wfloatStr); AZ_TEST_ASSERT_FLOAT_CLOSE(fval, 2.32f); - to_string(intStr, 20); + AZStd::to_string(intStr, 20); AZ_TEST_ASSERT(intStr == "20"); - AZ_TEST_ASSERT(to_string(static_cast(20)) == "20"); - AZ_TEST_ASSERT(to_string(static_cast(20)) == "20"); - AZ_TEST_ASSERT(to_string(static_cast(20)) == "20"); - AZ_TEST_ASSERT(to_string(static_cast(20)) == "20"); - AZ_TEST_ASSERT(to_string(static_cast(20)) == "20"); - AZ_TEST_ASSERT(to_string(static_cast(20)) == "20"); + EXPECT_EQ("20", AZStd::to_string(static_cast(20))); + EXPECT_EQ("20", AZStd::to_string(static_cast(20))); + EXPECT_EQ("20", AZStd::to_string(static_cast(20))); + EXPECT_EQ("20", AZStd::to_string(static_cast(20))); + EXPECT_EQ("20", AZStd::to_string(static_cast(20))); + EXPECT_EQ("20", AZStd::to_string(static_cast(20))); // wstring to string - string str1; - to_string(str1, wstr); + AZStd::string str1; + AZStd::to_string(str1, wstr); AZ_TEST_ASSERT(str1 == "BlaBla 5"); EXPECT_EQ(8, to_string_length(wstr)); - str1 = string::format("%ls", wstr.c_str()); + str1 = AZStd::string::format("%ls", wstr.c_str()); AZ_TEST_ASSERT(str1 == "BlaBla 5"); // string to wstring - wstring wstr1; - to_wstring(wstr1, str); + AZStd::wstring wstr1; + AZStd::to_wstring(wstr1, str); AZ_TEST_ASSERT(wstr1 == L"BLABLA 5"); - wstr1 = wstring::format(L"%hs", str.c_str()); + wstr1 = AZStd::wstring::format(L"%hs", str.c_str()); AZ_TEST_ASSERT(wstr1 == L"BLABLA 5"); // wstring to char buffer char strBuffer[9]; - to_string(strBuffer, 9, wstr1.c_str()); + AZStd::to_string(strBuffer, 9, wstr1.c_str()); AZ_TEST_ASSERT(0 == azstricmp(strBuffer, "BLABLA 5")); EXPECT_EQ(8, to_string_length(wstr1)); // wstring to char with unicode - wstring ws1InfinityEscaped = L"Infinity: \u221E"; // escaped + AZStd::wstring ws1InfinityEscaped = L"Infinity: \u221E"; // escaped EXPECT_EQ(13, to_string_length(ws1InfinityEscaped)); // wchar_t buffer to char buffer wchar_t wstrBuffer[9] = L"BLABLA 5"; memset(strBuffer, 0, AZ_ARRAY_SIZE(strBuffer)); - to_string(strBuffer, 9, wstrBuffer); + AZStd::to_string(strBuffer, 9, wstrBuffer); AZ_TEST_ASSERT(0 == azstricmp(strBuffer, "BLABLA 5")); // string to wchar_t buffer memset(wstrBuffer, 0, AZ_ARRAY_SIZE(wstrBuffer)); - to_wstring(wstrBuffer, 9, str1.c_str()); + AZStd::to_wstring(wstrBuffer, 9, str1.c_str()); AZ_TEST_ASSERT(0 == azwcsicmp(wstrBuffer, L"BlaBla 5")); // char buffer to wchar_t buffer memset(wstrBuffer, L' ', AZ_ARRAY_SIZE(wstrBuffer)); // to check that the null terminator is properly placed - to_wstring(wstrBuffer, 9, strBuffer); + AZStd::to_wstring(wstrBuffer, 9, strBuffer); AZ_TEST_ASSERT(0 == azwcsicmp(wstrBuffer, L"BLABLA 5")); // wchar UTF16/UTF32 to/from Utf8 wstr1 = L"this is a \u20AC \u00A3 test"; // that's a euro and a pound sterling AZStd::to_string(str, wstr1); - wstring wstr2; + AZStd::wstring wstr2; AZStd::to_wstring(wstr2, str); AZ_TEST_ASSERT(wstr1 == wstr2); // tokenize - vector tokens; - tokenize(string("one, two, three"), string(", "), tokens); + AZStd::vector tokens; + AZStd::tokenize(AZStd::string("one, two, three"), AZStd::string(", "), tokens); AZ_TEST_ASSERT(tokens.size() == 3); AZ_TEST_ASSERT(tokens[0] == "one"); AZ_TEST_ASSERT(tokens[1] == "two"); AZ_TEST_ASSERT(tokens[2] == "three"); - tokenize(string("one, ,, two, ,, three"), string(", "), tokens); + AZStd::tokenize(AZStd::string("one, ,, two, ,, three"), AZStd::string(", "), tokens); AZ_TEST_ASSERT(tokens.size() == 3); AZ_TEST_ASSERT(tokens[0] == "one"); AZ_TEST_ASSERT(tokens[1] == "two"); AZ_TEST_ASSERT(tokens[2] == "three"); - tokenize(string("thequickbrownfox"), string("ABC"), tokens); + AZStd::tokenize(AZStd::string("thequickbrownfox"), AZStd::string("ABC"), tokens); AZ_TEST_ASSERT(tokens.size() == 1); AZ_TEST_ASSERT(tokens[0] == "thequickbrownfox"); - tokenize(string(""), string(""), tokens); + AZStd::tokenize(AZStd::string{}, AZStd::string{}, tokens); AZ_TEST_ASSERT(tokens.empty()); - tokenize(string("ABC"), string("ABC"), tokens); + AZStd::tokenize(AZStd::string("ABC"), AZStd::string("ABC"), tokens); AZ_TEST_ASSERT(tokens.empty()); - tokenize(string(" foo bar "), string(" "), tokens); + AZStd::tokenize(AZStd::string(" foo bar "), AZStd::string(" "), tokens); AZ_TEST_ASSERT(tokens.size() == 2); AZ_TEST_ASSERT(tokens[0] == "foo"); AZ_TEST_ASSERT(tokens[1] == "bar"); - tokenize_keep_empty(string(" foo , bar "), string(","), tokens); + AZStd::tokenize_keep_empty(AZStd::string(" foo , bar "), AZStd::string(","), tokens); AZ_TEST_ASSERT(tokens.size() == 2); AZ_TEST_ASSERT(tokens[0] == " foo "); AZ_TEST_ASSERT(tokens[1] == " bar "); // Sort - AZStd::vector toSort; + AZStd::vector toSort; toSort.push_back("z2"); toSort.push_back("z100"); toSort.push_back("z1"); @@ -761,39 +756,39 @@ namespace UnitTest AZ_TEST_ASSERT(toSort[2] == "z2"); // Natural sort - AZ_TEST_ASSERT(alphanum_comp("", "") == 0); - AZ_TEST_ASSERT(alphanum_comp("", "a") < 0); - AZ_TEST_ASSERT(alphanum_comp("a", "") > 0); - AZ_TEST_ASSERT(alphanum_comp("a", "a") == 0); - AZ_TEST_ASSERT(alphanum_comp("", "9") < 0); - AZ_TEST_ASSERT(alphanum_comp("9", "") > 0); - AZ_TEST_ASSERT(alphanum_comp("1", "1") == 0); - AZ_TEST_ASSERT(alphanum_comp("1", "2") < 0); - AZ_TEST_ASSERT(alphanum_comp("3", "2") > 0); - AZ_TEST_ASSERT(alphanum_comp("a1", "a1") == 0); - AZ_TEST_ASSERT(alphanum_comp("a1", "a2") < 0); - AZ_TEST_ASSERT(alphanum_comp("a2", "a1") > 0); - AZ_TEST_ASSERT(alphanum_comp("a1a2", "a1a3") < 0); - AZ_TEST_ASSERT(alphanum_comp("a1a2", "a1a0") > 0); - AZ_TEST_ASSERT(alphanum_comp("134", "122") > 0); - AZ_TEST_ASSERT(alphanum_comp("12a3", "12a3") == 0); - AZ_TEST_ASSERT(alphanum_comp("12a1", "12a0") > 0); - AZ_TEST_ASSERT(alphanum_comp("12a1", "12a2") < 0); - AZ_TEST_ASSERT(alphanum_comp("a", "aa") < 0); - AZ_TEST_ASSERT(alphanum_comp("aaa", "aa") > 0); - AZ_TEST_ASSERT(alphanum_comp("Alpha 2", "Alpha 2") == 0); - AZ_TEST_ASSERT(alphanum_comp("Alpha 2", "Alpha 2A") < 0); - AZ_TEST_ASSERT(alphanum_comp("Alpha 2 B", "Alpha 2") > 0); - string strA("Alpha 2"); - AZ_TEST_ASSERT(alphanum_comp(strA, "Alpha 2") == 0); - AZ_TEST_ASSERT(alphanum_comp(strA, "Alpha 2A") < 0); - AZ_TEST_ASSERT(alphanum_comp("Alpha 2 B", strA) > 0); - AZ_TEST_ASSERT(alphanum_comp(strA, strdup("Alpha 2")) == 0); - AZ_TEST_ASSERT(alphanum_comp(strA, strdup("Alpha 2A")) < 0); - AZ_TEST_ASSERT(alphanum_comp(strdup("Alpha 2 B"), strA) > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("", "") == 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("", "a") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("a", "") > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("a", "a") == 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("", "9") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("9", "") > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("1", "1") == 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("1", "2") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("3", "2") > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("a1", "a1") == 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("a1", "a2") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("a2", "a1") > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("a1a2", "a1a3") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("a1a2", "a1a0") > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("134", "122") > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("12a3", "12a3") == 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("12a1", "12a0") > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("12a1", "12a2") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("a", "aa") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("aaa", "aa") > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("Alpha 2", "Alpha 2") == 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("Alpha 2", "Alpha 2A") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("Alpha 2 B", "Alpha 2") > 0); + AZStd::string strA("Alpha 2"); + AZ_TEST_ASSERT(AZStd::alphanum_comp(strA, "Alpha 2") == 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp(strA, "Alpha 2A") < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp("Alpha 2 B", strA) > 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp(strA, strdup("Alpha 2")) == 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp(strA, strdup("Alpha 2A")) < 0); + AZ_TEST_ASSERT(AZStd::alphanum_comp(strdup("Alpha 2 B"), strA) > 0); // show usage of the comparison functor with a set - using StringSetType = set>; + using StringSetType = AZStd::set>; StringSetType s; s.insert("Xiph Xlater 58"); s.insert("Xiph Xlater 5000"); @@ -879,7 +874,7 @@ namespace UnitTest AZ_TEST_ASSERT(*setIt++ == "Xiph Xlater 10000"); // show usage of comparison functor with a map - using StringIntMapType = map>; + using StringIntMapType = AZStd::map>; StringIntMapType m; m["z1.doc"] = 1; m["z10.doc"] = 2; @@ -931,13 +926,13 @@ namespace UnitTest AZ_TEST_ASSERT((mapIt++)->second == 5); // show usage of comparison functor with an STL algorithm on a vector - vector v; + AZStd::vector v; // vector contents are reversed sorted contents of the old set - AZStd::copy(s.rbegin(), s.rend(), back_inserter(v)); + AZStd::copy(s.rbegin(), s.rend(), AZStd::back_inserter(v)); // now sort the vector with the algorithm - AZStd::sort(v.begin(), v.end(), alphanum_less()); + AZStd::sort(v.begin(), v.end(), AZStd::alphanum_less()); // check values - vector::const_iterator vecIt = v.begin(); + AZStd::vector::const_iterator vecIt = v.begin(); AZ_TEST_ASSERT(*vecIt++ == "10X Radonius"); AZ_TEST_ASSERT(*vecIt++ == "20X Radonius"); AZ_TEST_ASSERT(*vecIt++ == "20X Radonius Prime"); @@ -988,52 +983,52 @@ namespace UnitTest TEST_F(Regex, Regex_IPAddressSubnetPattern_Success) { // Error case for LY-43888 - regex txt_regex("^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(/([0-9]|[1-2][0-9]|3[0-2]))?$"); - string sample_input("10.85.22.92/24"); - bool match = regex_match(sample_input, txt_regex); + AZStd::regex txt_regex("^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(/([0-9]|[1-2][0-9]|3[0-2]))?$"); + AZStd::string sample_input("10.85.22.92/24"); + bool match = AZStd::regex_match(sample_input, txt_regex); AZ_TEST_ASSERT(match); } TEST_F(Regex, MatchConstChar) { //regex - AZ_TEST_ASSERT(regex_match("subject", regex("(sub)(.*)"))); + AZ_TEST_ASSERT(AZStd::regex_match("subject", AZStd::regex("(sub)(.*)"))); } TEST_F(Regex, MatchString) { - string reStr("subject"); - regex re("(sub)(.*)"); - AZ_TEST_ASSERT(regex_match(reStr, re)); - AZ_TEST_ASSERT(regex_match(reStr.begin(), reStr.end(), re)) + AZStd::string reStr("subject"); + AZStd::regex re("(sub)(.*)"); + AZ_TEST_ASSERT(AZStd::regex_match(reStr, re)); + AZ_TEST_ASSERT(AZStd::regex_match(reStr.begin(), reStr.end(), re)) } TEST_F(Regex, CMatch) { - regex re("(sub)(.*)"); - cmatch cm; // same as match_results cm; - regex_match("subject", cm, re); + AZStd::regex re("(sub)(.*)"); + AZStd::cmatch cm; // same as match_results cm; + AZStd::regex_match("subject", cm, re); AZ_TEST_ASSERT(cm.size() == 3); } TEST_F(Regex, SMatch) { - string reStr("subject"); - regex re("(sub)(.*)"); - smatch sm; // same as std::match_results sm; - regex_match(reStr, sm, re); + AZStd::string reStr("subject"); + AZStd::regex re("(sub)(.*)"); + AZStd::smatch sm; // same as std::match_results sm; + AZStd::regex_match(reStr, sm, re); AZ_TEST_ASSERT(sm.size() == 3); - regex_match(reStr.cbegin(), reStr.cend(), sm, re); + AZStd::regex_match(reStr.cbegin(), reStr.cend(), sm, re); AZ_TEST_ASSERT(sm.size() == 3); } TEST_F(Regex, CMatchWithFlags) { - regex re("(sub)(.*)"); - cmatch cm; // same as match_results cm; + AZStd::regex re("(sub)(.*)"); + AZStd::cmatch cm; // same as match_results cm; // using explicit flags: - regex_match("subject", cm, re, regex_constants::match_default); + AZStd::regex_match("subject", cm, re, AZStd::regex_constants::match_default); AZ_TEST_ASSERT(cm[0] == "subject"); AZ_TEST_ASSERT(cm[1] == "sub"); AZ_TEST_ASSERT(cm[2] == "ject"); @@ -1042,18 +1037,18 @@ namespace UnitTest TEST_F(Regex, PatternMatchFiles) { // Simple regular expression matching - string fnames[] = { "foo.txt", "bar.txt", "baz.dat", "zoidberg" }; - regex txt_regex("[a-z]+\\.txt"); + AZStd::string fnames[] = { "foo.txt", "bar.txt", "baz.dat", "zoidberg" }; + AZStd::regex txt_regex("[a-z]+\\.txt"); for (size_t i = 0; i < AZ_ARRAY_SIZE(fnames); ++i) { if (i < 2) { - AZ_TEST_ASSERT(regex_match(fnames[i], txt_regex) == true); + AZ_TEST_ASSERT(AZStd::regex_match(fnames[i], txt_regex) == true); } else { - AZ_TEST_ASSERT(regex_match(fnames[i], txt_regex) == false); + AZ_TEST_ASSERT(AZStd::regex_match(fnames[i], txt_regex) == false); } } } @@ -1061,13 +1056,13 @@ namespace UnitTest TEST_F(Regex, PatternWithSingleCaptureGroup) { // Extraction of a sub-match - string fnames[] = { "foo.txt", "bar.txt", "baz.dat", "zoidberg" }; - regex base_regex("([a-z]+)\\.txt"); - smatch base_match; + AZStd::string fnames[] = { "foo.txt", "bar.txt", "baz.dat", "zoidberg" }; + AZStd::regex base_regex("([a-z]+)\\.txt"); + AZStd::smatch base_match; for (size_t i = 0; i < AZ_ARRAY_SIZE(fnames); ++i) { - if (regex_match(fnames[i], base_match, base_regex)) + if (AZStd::regex_match(fnames[i], base_match, base_regex)) { AZ_TEST_ASSERT(base_match.size() == 2); AZ_TEST_ASSERT(base_match[1] == "foo" || base_match[1] == "bar") @@ -1078,12 +1073,12 @@ namespace UnitTest TEST_F(Regex, PatternWithMultipleCaptureGroups) { // Extraction of several sub-matches - string fnames[] = { "foo.txt", "bar.txt", "baz.dat", "zoidberg" }; - regex pieces_regex("([a-z]+)\\.([a-z]+)"); - smatch pieces_match; + AZStd::string fnames[] = { "foo.txt", "bar.txt", "baz.dat", "zoidberg" }; + AZStd::regex pieces_regex("([a-z]+)\\.([a-z]+)"); + AZStd::smatch pieces_match; for (size_t i = 0; i < AZ_ARRAY_SIZE(fnames); ++i) { - if (regex_match(fnames[i], pieces_match, pieces_regex)) + if (AZStd::regex_match(fnames[i], pieces_match, pieces_regex)) { AZ_TEST_ASSERT(pieces_match.size() == 3); AZ_TEST_ASSERT(pieces_match[0] == "foo.txt" || pieces_match[0] == "bar.txt" || pieces_match[0] == "baz.dat"); @@ -1096,40 +1091,40 @@ namespace UnitTest TEST_F(Regex, WideCharTests) { //wchar_t - AZ_TEST_ASSERT(regex_match(L"subject", wregex(L"(sub)(.*)"))); - wstring reWStr(L"subject"); - wregex reW(L"(sub)(.*)"); - AZ_TEST_ASSERT(regex_match(reWStr, reW)); - AZ_TEST_ASSERT(regex_match(reWStr.begin(), reWStr.end(), reW)) + AZ_TEST_ASSERT(AZStd::regex_match(L"subject", AZStd::wregex(L"(sub)(.*)"))); + AZStd::wstring reWStr(L"subject"); + AZStd::wregex reW(L"(sub)(.*)"); + AZ_TEST_ASSERT(AZStd::regex_match(reWStr, reW)); + AZ_TEST_ASSERT(AZStd::regex_match(reWStr.begin(), reWStr.end(), reW)) } TEST_F(Regex, LongPatterns) { // test construction and destruction of a regex with a pattern long enough to require reallocation of buffers - regex longerThan16(".*\\/Presets\\/GeomCache\\/.*", regex::flag_type::icase | regex::flag_type::ECMAScript); - regex longerThan32(".*\\/Presets\\/GeomCache\\/Whatever\\/Much\\/Test\\/Very\\/Memory\\/.*", regex::flag_type::icase); + AZStd::regex longerThan16(".*\\/Presets\\/GeomCache\\/.*", AZStd::regex::flag_type::icase | AZStd::regex::flag_type::ECMAScript); + AZStd::regex longerThan32(".*\\/Presets\\/GeomCache\\/Whatever\\/Much\\/Test\\/Very\\/Memory\\/.*", AZStd::regex::flag_type::icase); } TEST_F(Regex, SmileyFaceParseRegression) { - regex smiley(":)"); + AZStd::regex smiley(":)"); EXPECT_TRUE(smiley.Empty()); EXPECT_TRUE(smiley.GetError() != nullptr); - EXPECT_FALSE(regex_match("wut", smiley)); - EXPECT_FALSE(regex_match(":)", smiley)); + EXPECT_FALSE(AZStd::regex_match("wut", smiley)); + EXPECT_FALSE(AZStd::regex_match(":)", smiley)); } TEST_F(Regex, ParseFailure) { - regex failed(")))/?!\\$"); + AZStd::regex failed(")))/?!\\$"); EXPECT_FALSE(failed.Valid()); - regex other = AZStd::move(failed); + AZStd::regex other = AZStd::move(failed); EXPECT_FALSE(other.Valid()); - regex other2; + AZStd::regex other2; other2.swap(other); EXPECT_TRUE(other.Empty()); EXPECT_TRUE(other.GetError() == nullptr); @@ -1139,69 +1134,69 @@ namespace UnitTest TEST_F(String, ConstString) { - string_view cstr1; - AZ_TEST_ASSERT(cstr1.data()==nullptr); - AZ_TEST_ASSERT(cstr1.size() == 0); - AZ_TEST_ASSERT(cstr1.length() == 0); - AZ_TEST_ASSERT(cstr1.begin() == cstr1.end()); - AZ_TEST_ASSERT(cstr1 == string_view()); - AZ_TEST_ASSERT(cstr1.empty()); - - string_view cstr2("Test"); - AZ_TEST_ASSERT(cstr2.data() != nullptr); - AZ_TEST_ASSERT(cstr2.size() == 4); - AZ_TEST_ASSERT(cstr2.length() == 4); - AZ_TEST_ASSERT(cstr2.begin() != cstr2.end()); - AZ_TEST_ASSERT(cstr2 != cstr1); - AZ_TEST_ASSERT(cstr2 == string_view("Test")); - AZ_TEST_ASSERT(cstr2 == "Test"); - AZ_TEST_ASSERT(cstr2 != "test"); - AZ_TEST_ASSERT(cstr2[2] == 's'); - AZ_TEST_ASSERT(cstr2.at(2) == 's'); + AZStd::string_view cstr1; + EXPECT_EQ(nullptr, cstr1.data()); + EXPECT_EQ(0, cstr1.size()); + EXPECT_EQ(0, cstr1.length()); + EXPECT_EQ(cstr1.begin(), cstr1.end()); + EXPECT_EQ(cstr1, AZStd::string_view()); + EXPECT_TRUE(cstr1.empty()); + + AZStd::string_view cstr2("Test"); + EXPECT_NE(nullptr, cstr2.data()); + EXPECT_EQ(4, cstr2.size()); + EXPECT_EQ(4, cstr2.length()); + EXPECT_NE(cstr2.begin(), cstr2.end()); + EXPECT_NE(cstr2, cstr1); + EXPECT_EQ(cstr2, AZStd::string_view("Test")); + EXPECT_EQ(cstr2, "Test"); + EXPECT_NE(cstr2, "test"); + EXPECT_EQ(cstr2[2], 's'); + EXPECT_EQ(cstr2.at(2), 's'); AZ_TEST_START_TRACE_SUPPRESSION; - AZ_TEST_ASSERT(cstr2.at(7) == 0); + EXPECT_EQ(0, cstr2.at(7)); AZ_TEST_STOP_TRACE_SUPPRESSION(1); - AZ_TEST_ASSERT(!cstr2.empty()); - AZ_TEST_ASSERT(cstr2.data() == string("Test")); - AZ_TEST_ASSERT((string)cstr2 == string("Test")); + EXPECT_FALSE(cstr2.empty()); + EXPECT_EQ(cstr2.data(), AZStd::string("Test")); + EXPECT_EQ(cstr2, AZStd::string("Test")); - string_view cstr3 = cstr2; - AZ_TEST_ASSERT(cstr3 == cstr2); + AZStd::string_view cstr3 = cstr2; + EXPECT_EQ(cstr3, cstr2); cstr3.swap(cstr1); - AZ_TEST_ASSERT(cstr3 == string_view()); - AZ_TEST_ASSERT(cstr1 == cstr2); + EXPECT_EQ(cstr3, AZStd::string_view()); + EXPECT_EQ(cstr1, cstr2); cstr1 = {}; - AZ_TEST_ASSERT(cstr1 == string_view()); - AZ_TEST_ASSERT(cstr1.size() == 0); - AZ_TEST_ASSERT(cstr1.length() == 0); + EXPECT_EQ(cstr1, AZStd::string_view()); + EXPECT_EQ(0, cstr1.size()); + EXPECT_EQ(0, cstr1.length()); AZStd::string str1("Test"); - AZ_TEST_ASSERT(cstr2 == str1); + EXPECT_EQ(cstr2, str1); cstr1 = str1; - AZ_TEST_ASSERT(cstr1 == cstr2); + EXPECT_EQ(cstr1, cstr2); // check hashing - AZStd::hash h; + AZStd::hash h; AZStd::size_t value = h(cstr1); - AZ_TEST_ASSERT(value != 0); + EXPECT_NE(0, value); // testing empty string AZStd::string emptyString; - string_view cstr4; + AZStd::string_view cstr4; cstr4 = emptyString; - AZ_TEST_ASSERT(cstr4.data() != nullptr); - AZ_TEST_ASSERT(cstr4.size() == 0); - AZ_TEST_ASSERT(cstr4.length() == 0); - AZ_TEST_ASSERT(cstr4.begin() == cstr4.end()); - AZ_TEST_ASSERT(cstr4.empty()); + EXPECT_NE(nullptr, cstr4.data()); + EXPECT_EQ(0, cstr4.size()); + EXPECT_EQ(0, cstr4.length()); + EXPECT_EQ(cstr4.begin(), cstr4.end()); + EXPECT_TRUE(cstr4.empty()); } TEST_F(String, StringViewModifierTest) { - string_view emptyView1; - string_view view2("Needle in Haystack"); + AZStd::string_view emptyView1; + AZStd::string_view view2("Needle in Haystack"); // front EXPECT_EQ('N', view2.front()); @@ -1209,7 +1204,7 @@ namespace UnitTest EXPECT_EQ('k', view2.back()); AZStd::string findStr("Hay"); - string_view view3(findStr); + AZStd::string_view view3(findStr); // copy const size_t destBufferSize = 32; @@ -1223,17 +1218,17 @@ namespace UnitTest AZ_TEST_STOP_TRACE_SUPPRESSION(1); // substr - string_view subView2 = view2.substr(10); + AZStd::string_view subView2 = view2.substr(10); EXPECT_EQ("Haystack", subView2); AZ_TEST_START_TRACE_SUPPRESSION; - [[maybe_unused]] string_view assertSubView = view2.substr(view2.size() + 1); + [[maybe_unused]] AZStd::string_view assertSubView = view2.substr(view2.size() + 1); AZ_TEST_STOP_TRACE_SUPPRESSION(1); // compare AZStd::size_t compareResult = view2.compare(1, view2.size() - 1, dest, copyResult); EXPECT_EQ(0, compareResult); - string_view compareView = "Stackhay in Needle"; + AZStd::string_view compareView = "Stackhay in Needle"; compareResult = compareView.compare(view2); EXPECT_NE(0, compareResult); @@ -1252,7 +1247,7 @@ namespace UnitTest EXPECT_EQ(10, findResult); findResult = compareView.find("Random String"); - EXPECT_EQ(string_view::npos, findResult); + EXPECT_EQ(AZStd::string_view::npos, findResult); findResult = view3.find('y', 2); EXPECT_EQ(2, findResult); @@ -1262,13 +1257,13 @@ namespace UnitTest EXPECT_EQ(1, rfindResult); rfindResult = emptyView1.rfind(""); - EXPECT_EQ(string_view::npos, rfindResult); + EXPECT_EQ(AZStd::string_view::npos, rfindResult); rfindResult = view2.rfind("z"); - EXPECT_EQ(string_view::npos, rfindResult); + EXPECT_EQ(AZStd::string_view::npos, rfindResult); // find_first_of - string_view repeatString = "abcdefabcfedghiabcdef"; + AZStd::string_view repeatString = "abcdefabcfedghiabcdef"; AZStd::size_t findFirstOfResult = repeatString.find_first_of('f'); EXPECT_EQ(5, findFirstOfResult); @@ -1281,7 +1276,7 @@ namespace UnitTest AZStd::string notFoundStr = "zzz"; AZStd::string foundStr = "ghi"; findFirstOfResult = repeatString.find_first_of(notFoundStr); - EXPECT_EQ(string_view::npos, findFirstOfResult); + EXPECT_EQ(AZStd::string_view::npos, findFirstOfResult); findFirstOfResult = repeatString.find_first_of(foundStr); EXPECT_EQ(12, findFirstOfResult); @@ -1297,7 +1292,7 @@ namespace UnitTest EXPECT_EQ(3, findLastOfResult); findLastOfResult = repeatString.find_last_of(notFoundStr); - EXPECT_EQ(string_view::npos, findLastOfResult); + EXPECT_EQ(AZStd::string_view::npos, findLastOfResult); findLastOfResult = repeatString.find_last_of(foundStr); EXPECT_EQ(14, findLastOfResult); @@ -1335,12 +1330,12 @@ namespace UnitTest EXPECT_EQ(11, findLastNotOfResult); // remove_prefix - string_view prefixRemovalView = view2; + AZStd::string_view prefixRemovalView = view2; prefixRemovalView.remove_prefix(6); EXPECT_EQ(" in Haystack", prefixRemovalView); // remove_suffix - string_view suffixRemovalView = view2; + AZStd::string_view suffixRemovalView = view2; suffixRemovalView.remove_suffix(8); EXPECT_EQ("Needle in ", suffixRemovalView); @@ -1365,10 +1360,10 @@ namespace UnitTest TEST_F(String, StringViewCmpOperatorTest) { - string_view view1("The quick brown fox jumped over the lazy dog"); - string_view view2("Needle in Haystack"); - string_view emptyBeaverView; - string_view superEmptyBeaverView(""); + AZStd::string_view view1("The quick brown fox jumped over the lazy dog"); + AZStd::string_view view2("Needle in Haystack"); + AZStd::string_view emptyBeaverView; + AZStd::string_view superEmptyBeaverView(""); EXPECT_EQ("", emptyBeaverView); EXPECT_EQ("", superEmptyBeaverView); @@ -1378,13 +1373,13 @@ namespace UnitTest EXPECT_EQ(view2, "Needle in Haystack"); EXPECT_NE(view2, "Needle in Hayqueue"); - string_view compareView(view2); + AZStd::string_view compareView(view2); EXPECT_EQ(view2, compareView); EXPECT_NE(view2, view1); AZStd::string compareStr("Busy Beaver"); - string_view notBeaverView("Lumber Beaver"); - string_view beaverView("Busy Beaver"); + AZStd::string_view notBeaverView("Lumber Beaver"); + AZStd::string_view beaverView("Busy Beaver"); EXPECT_EQ(compareStr, beaverView); EXPECT_NE(compareStr, notBeaverView); @@ -1528,8 +1523,8 @@ namespace UnitTest TYPED_TEST_CASE(BasicStringViewConstexprFixture, StringViewElementTypes); TYPED_TEST(BasicStringViewConstexprFixture, StringView_DefaultConstructorsIsConstexpr) { - constexpr basic_string_view defaultView1; - constexpr basic_string_view defaultView2; + constexpr AZStd::basic_string_view defaultView1; + constexpr AZStd::basic_string_view defaultView2; static_assert(defaultView1 == defaultView2, "string_view constructor should be constexpr"); } @@ -1549,7 +1544,7 @@ namespace UnitTest return {}; }(); - constexpr basic_string_view charTView1(compileTimeString); + constexpr AZStd::basic_string_view charTView1(compileTimeString); static_assert(charTView1.size() == 10, "string_view constructor should be constexpr"); // non-null terminated compile time string constexpr const TypeParam* compileTimeString2 = []() constexpr -> const TypeParam* @@ -1565,7 +1560,7 @@ namespace UnitTest return {}; }(); - constexpr basic_string_view charTViewWithLength(compileTimeString2, 7); + constexpr AZStd::basic_string_view charTViewWithLength(compileTimeString2, 7); static_assert(charTViewWithLength.size() == 7, "string_view constructor should be constexpr"); } @@ -1585,8 +1580,8 @@ namespace UnitTest return {}; }(); - constexpr basic_string_view copyView1(compileTimeString); - constexpr basic_string_view copyView2(copyView1); + constexpr AZStd::basic_string_view copyView1(compileTimeString); + constexpr AZStd::basic_string_view copyView2(copyView1); static_assert(copyView1 == copyView2, "string_view constructor should be constexpr"); } @@ -1606,8 +1601,8 @@ namespace UnitTest return {}; }(); - constexpr basic_string_view assignView1(compileTimeString1); - auto assignment_test_func = [](basic_string_view sourceView) constexpr -> basic_string_view + constexpr AZStd::basic_string_view assignView1(compileTimeString1); + auto assignment_test_func = [](AZStd::basic_string_view sourceView) constexpr -> AZStd::basic_string_view { constexpr const TypeParam* const compileTimeString2 = []() constexpr-> const TypeParam* { @@ -1622,7 +1617,7 @@ namespace UnitTest return {}; }(); - basic_string_view assignView2(compileTimeString2); + AZStd::basic_string_view assignView2(compileTimeString2); assignView2 = sourceView; return assignView2; }; @@ -1646,15 +1641,15 @@ namespace UnitTest return {}; }(); - constexpr basic_string_view iteratorView(compileTimeString1); - constexpr typename basic_string_view::iterator beginIt = iteratorView.begin(); - constexpr typename basic_string_view::const_iterator cbeginIt = iteratorView.cbegin(); - constexpr typename basic_string_view::iterator endIt = iteratorView.end(); - constexpr typename basic_string_view::const_iterator cendIt = iteratorView.cend(); - constexpr typename basic_string_view::reverse_iterator rbeginIt = iteratorView.rbegin(); - constexpr typename basic_string_view::const_reverse_iterator crbeginIt = iteratorView.crbegin(); - constexpr typename basic_string_view::reverse_iterator rendIt = iteratorView.rend(); - constexpr typename basic_string_view::const_reverse_iterator crendIt = iteratorView.crend(); + constexpr AZStd::basic_string_view iteratorView(compileTimeString1); + constexpr typename AZStd::basic_string_view::iterator beginIt = iteratorView.begin(); + constexpr typename AZStd::basic_string_view::const_iterator cbeginIt = iteratorView.cbegin(); + constexpr typename AZStd::basic_string_view::iterator endIt = iteratorView.end(); + constexpr typename AZStd::basic_string_view::const_iterator cendIt = iteratorView.cend(); + constexpr typename AZStd::basic_string_view::reverse_iterator rbeginIt = iteratorView.rbegin(); + constexpr typename AZStd::basic_string_view::const_reverse_iterator crbeginIt = iteratorView.crbegin(); + constexpr typename AZStd::basic_string_view::reverse_iterator rendIt = iteratorView.rend(); + constexpr typename AZStd::basic_string_view::const_reverse_iterator crendIt = iteratorView.crend(); static_assert(beginIt != endIt, "begin and iterators should be different"); static_assert(cbeginIt != cendIt, "begin and iterators should be different"); static_assert(rbeginIt != rendIt, "begin and iterators should be different"); @@ -1679,7 +1674,7 @@ namespace UnitTest return {}; }(); - constexpr basic_string_view elementView1(compileTimeString1); + constexpr AZStd::basic_string_view elementView1(compileTimeString1); static_assert(elementView1[4] == 'o', "character at index 4 in string_view should be 'o'"); static_assert(elementView1.at(5) == 'W', "character at index 5 in string_view should be 'W'"); } @@ -1700,7 +1695,7 @@ namespace UnitTest return {}; }(); - constexpr basic_string_view elementView1(compileTimeString1); + constexpr AZStd::basic_string_view elementView1(compileTimeString1); static_assert(elementView1.front() == 'H', "Fourth character in string_view should be 'H'"); static_assert(elementView1.back() == 'd', "Fifth character in string_view should be 'd'"); } @@ -1734,8 +1729,8 @@ namespace UnitTest return {}; }(); - static constexpr basic_string_view elementView1(compileTimeString1); - static constexpr basic_string_view elementView2(compileTimeString2); + static constexpr AZStd::basic_string_view elementView1(compileTimeString1); + static constexpr AZStd::basic_string_view elementView2(compileTimeString2); static_assert(elementView1.data(), "string_view.data() should be non-nullptr"); static_assert(elementView2.data(), "string_view.data() should be non-nullptr"); } @@ -1756,7 +1751,7 @@ namespace UnitTest return {}; }(); - constexpr basic_string_view sizeView1(compileTimeString1); + constexpr AZStd::basic_string_view sizeView1(compileTimeString1); static_assert(sizeView1.size() == sizeView1.length(), "string_views size and length function should return the same value"); static_assert(!sizeView1.empty(), "string_views should not be empty"); static_assert(sizeView1.max_size() != 0, "string_views max_size should be greater than 0"); @@ -1770,21 +1765,21 @@ namespace UnitTest { return "HelloWorld"; }; - constexpr basic_string_view modifierView("HelloWorld"); + constexpr AZStd::basic_string_view modifierView("HelloWorld"); // A constexpr lambda is used to evaluate non constexpr string_view instances' member functions which // have been marked as constexpr at compile time // The google test function being run is not a constexpr function and therefore will evaulate // non-constexpr string_view variables at runtime. This would cause static_assert to state // that the expression is evaluated at runtime - auto remove_prefix_test_func = [](basic_string_view sourceView) constexpr -> basic_string_view + auto remove_prefix_test_func = [](AZStd::basic_string_view sourceView) constexpr -> AZStd::basic_string_view { - basic_string_view lstripView(sourceView); + AZStd::basic_string_view lstripView(sourceView); lstripView.remove_prefix(5); return lstripView; }; - auto remove_suffix_test_func = [](basic_string_view sourceView) constexpr -> basic_string_view + auto remove_suffix_test_func = [](AZStd::basic_string_view sourceView) constexpr -> AZStd::basic_string_view { - basic_string_view rstripView(sourceView); + AZStd::basic_string_view rstripView(sourceView); rstripView.remove_suffix(5); return rstripView; }; @@ -1801,8 +1796,8 @@ namespace UnitTest return "HelloWorld"; }; constexpr const TypeParam* compileTimeString1 = MakeCompileTimeString1();; - constexpr basic_string_view fullView(compileTimeString1); - auto substr_test_func = [](basic_string_view sourceView) constexpr -> basic_string_view + constexpr AZStd::basic_string_view fullView(compileTimeString1); + auto substr_test_func = [](AZStd::basic_string_view sourceView) constexpr -> AZStd::basic_string_view { return sourceView.substr(3, 5); }; @@ -1818,7 +1813,7 @@ namespace UnitTest return "elloGovernor"; }; constexpr const TypeParam* compileTimeString1 = MakeCompileTimeString1(); - constexpr basic_string_view withView(compileTimeString1); + constexpr AZStd::basic_string_view withView(compileTimeString1); static_assert(withView.starts_with("ello"), "string_view should start with \"ello\""); // Regression in VS2017 15.8 and 15.9 where __builtin_memcmp fails in valid checks #if AZ_COMPILER_MSVC < 1915 && AZ_COMPILER_MSVC > 1916 @@ -1854,9 +1849,9 @@ namespace UnitTest TYPED_TEST(BasicStringViewConstexprFixture, StringView_FindOperationsAreConstexpr) { constexpr const TypeParam* compileTimeString1 = MakeCompileTimeString1; - constexpr basic_string_view quickFoxView(compileTimeString1); + constexpr AZStd::basic_string_view quickFoxView(compileTimeString1); constexpr const TypeParam* searchString = MakeSearchString; - constexpr basic_string_view searchView(searchString); + constexpr AZStd::basic_string_view searchView(searchString); constexpr const TypeParam* testString1 = MakeTestString1; constexpr const TypeParam* testString2 = MakeTestString2; @@ -1893,10 +1888,10 @@ namespace UnitTest static_assert(quickFoxView.find_last_of('o') == 42, "string_view find_last_of should result in index 42"); static_assert(quickFoxView.find_last_of(testString6) == 40, "string_view find_last_of should result in index 40"); static_assert(quickFoxView.find_last_of(testString7, 31) == 29, "string_view find_last_of should result in index 29"); - static_assert(quickFoxView.find_last_of(testString8, basic_string_view::npos, 1) == 7, "string_view find_last_of should result in index 7"); + static_assert(quickFoxView.find_last_of(testString8, AZStd::basic_string_view::npos, 1) == 7, "string_view find_last_of should result in index 7"); // find_first_not_of test - constexpr basic_string_view firstNotOfView(testString9); + constexpr AZStd::basic_string_view firstNotOfView(testString9); static_assert(quickFoxView.find_first_not_of(firstNotOfView) == 4, "string_view find_first_not_of should result in index 0"); static_assert(quickFoxView.find_first_not_of('t') == 1, "string_view find_first_not_of should result in index 1"); static_assert(quickFoxView.find_first_not_of(testString9) == 4, "string_view find_first_not_of should result in index 4"); @@ -1904,12 +1899,12 @@ namespace UnitTest static_assert(quickFoxView.find_first_not_of(testString9, 0, 1) == 1, "string_view find_first_not_of should result in index 1"); // find_last_not_of test - constexpr basic_string_view lastNotOfView(testString10); + constexpr AZStd::basic_string_view lastNotOfView(testString10); static_assert(quickFoxView.find_last_not_of(lastNotOfView) == 39, "string_view find_last_not_of should result in index 39"); static_assert(quickFoxView.find_last_not_of('g') == 42, "string_view find_last_not_of should result in index 42"); static_assert(quickFoxView.find_last_not_of(testString10) == 39, "string_view find_last_not_of should result in index 39"); static_assert(quickFoxView.find_last_not_of(testString10, 27) == 24, "string_view find_last_not_of should result in index 24"); - static_assert(quickFoxView.find_last_not_of(testString10, basic_string_view::npos, 1) == 43, "string_view find_last_not_of should result in index 43"); + static_assert(quickFoxView.find_last_not_of(testString10, AZStd::basic_string_view::npos, 1) == 43, "string_view find_last_not_of should result in index 43"); } TEST_F(String, StringView_CompareIsConstexpr) @@ -1925,8 +1920,8 @@ namespace UnitTest }; constexpr const TypeParam* compileTimeString1 = ThisTestMakeCompileTimeString1(); constexpr const TypeParam* compileTimeString2 = MakeCompileTimeString2(); - constexpr basic_string_view lhsView(compileTimeString1); - constexpr basic_string_view rhsView(compileTimeString2); + constexpr AZStd::basic_string_view lhsView(compileTimeString1); + constexpr AZStd::basic_string_view rhsView(compileTimeString2); static_assert(lhsView.compare(rhsView) > 0, R"("HelloWorld" > "HelloPearl")"); static_assert(lhsView.compare(0, 5, rhsView) < 0, R"("Hello" < HelloPearl")"); static_assert(lhsView.compare(2, 3, rhsView, 2, 3) == 0, R"("llo" == llo")"); @@ -1943,7 +1938,7 @@ namespace UnitTest return "HelloWorld"; }; constexpr const TypeParam* compileTimeString1 = TestMakeCompileTimeString1(); - constexpr basic_string_view compareView(compileTimeString1); + constexpr AZStd::basic_string_view compareView(compileTimeString1); static_assert(compareView == "HelloWorld", "string_view operator== comparison has failed"); static_assert(compareView != "MadWorld", "string_view operator!= comparison has failed"); static_assert(compareView < "JelloWorld", "string_view operator< comparison has failed"); @@ -1954,7 +1949,7 @@ namespace UnitTest TYPED_TEST(BasicStringViewConstexprFixture, StringView_SwapIsConstexpr) { - auto swap_test_func = []() constexpr -> basic_string_view + auto swap_test_func = []() constexpr -> AZStd::basic_string_view { constexpr auto ThisTestMakeCompileTimeString1 = []() constexpr -> const TypeParam* { @@ -1980,8 +1975,8 @@ namespace UnitTest }; constexpr const TypeParam* compileTimeString1 = ThisTestMakeCompileTimeString1(); constexpr const TypeParam* compileTimeString2 = MakeCompileTimeString2(); - basic_string_view lhsView(compileTimeString1); - basic_string_view rhsView(compileTimeString2); + AZStd::basic_string_view lhsView(compileTimeString1); + AZStd::basic_string_view rhsView(compileTimeString2); lhsView.swap(rhsView); return lhsView; }; @@ -2014,13 +2009,14 @@ namespace UnitTest } }; constexpr const TypeParam* compileTimeString1 = ThisTestMakeCompileTimeString1(); - constexpr basic_string_view hashView(compileTimeString1); - constexpr size_t compileHash = AZStd::hash>{}(hashView); + constexpr AZStd::basic_string_view hashView(compileTimeString1); + constexpr size_t compileHash = AZStd::hash>{}(hashView); static_assert(compileHash != 0, "Hash of \"HelloWorld\" should not be 0"); } TEST_F(String, StringView_UserLiteralsSucceed) { + using namespace AZStd::string_view_literals; constexpr auto charView{ "Test"_sv }; constexpr auto wcharView{ L"Super Test"_sv }; static_assert(charView == "Test", "char string literal should be \"Test\""); @@ -2291,21 +2287,21 @@ namespace UnitTest { AZStd::fixed_string<32> filter1; AZStd::string testValue{ "test" }; - EXPECT_FALSE(wildcard_match(filter1, testValue)); + EXPECT_FALSE(AZStd::wildcard_match(filter1, testValue)); } TEST_F(String, WildcardMatch_EmptyFilterWithEmptyValue_Succeeds) { AZStd::fixed_string<32> filter1; AZStd::fixed_string<32> emptyValue; - EXPECT_TRUE(wildcard_match(filter1, emptyValue)); + EXPECT_TRUE(AZStd::wildcard_match(filter1, emptyValue)); } TEST_F(String, WildcardMatch_AsteriskOnlyFilterWithEmptyValue_Succeeds) { const char* filter1{ "*" }; const char* filter2{ "**" }; const char* emptyValue{ "" }; - EXPECT_TRUE(wildcard_match(filter1, emptyValue)); - EXPECT_TRUE(wildcard_match(filter2, emptyValue)); + EXPECT_TRUE(AZStd::wildcard_match(filter1, emptyValue)); + EXPECT_TRUE(AZStd::wildcard_match(filter2, emptyValue)); } TEST_F(String, WildcardMatch_AsteriskQuestionMarkFilterWithEmptyValue_Failes) { @@ -2313,60 +2309,60 @@ namespace UnitTest const char* filter1{ "*?" }; const char* filter2{ "?*" }; const char* emptyValue{ "" }; - EXPECT_FALSE(wildcard_match(filter1, emptyValue)); - EXPECT_FALSE(wildcard_match(filter2, emptyValue)); + EXPECT_FALSE(AZStd::wildcard_match(filter1, emptyValue)); + EXPECT_FALSE(AZStd::wildcard_match(filter2, emptyValue)); } TEST_F(String, WildcardMatch_DotValue_Succeeds) { const char* filter1{ "?" }; const char* dotValue{ "." }; - EXPECT_TRUE(wildcard_match(filter1, dotValue)); + EXPECT_TRUE(AZStd::wildcard_match(filter1, dotValue)); } TEST_F(String, WildcardMatch_DoubleDotValue_Succeeds) { const char* filter1{ "??" }; const char* dotValue{ ".." }; - EXPECT_TRUE(wildcard_match(filter1, dotValue)); + EXPECT_TRUE(AZStd::wildcard_match(filter1, dotValue)); } TEST_F(String, WildcardMatch_GlobFilters_Succeeds) { const char* filter1{ "*" }; const char* filter2{ "*?" }; const char* filter3{ "?*" }; - EXPECT_TRUE(wildcard_match(filter1, "Hello")); - EXPECT_TRUE(wildcard_match(filter1, "?")); - EXPECT_TRUE(wildcard_match(filter1, "*")); - EXPECT_TRUE(wildcard_match(filter1, "Q")); + EXPECT_TRUE(AZStd::wildcard_match(filter1, "Hello")); + EXPECT_TRUE(AZStd::wildcard_match(filter1, "?")); + EXPECT_TRUE(AZStd::wildcard_match(filter1, "*")); + EXPECT_TRUE(AZStd::wildcard_match(filter1, "Q")); - EXPECT_TRUE(wildcard_match(filter2, "Hello")); - EXPECT_TRUE(wildcard_match(filter2, "?")); - EXPECT_TRUE(wildcard_match(filter2, "*")); - EXPECT_TRUE(wildcard_match(filter2, "Q")); + EXPECT_TRUE(AZStd::wildcard_match(filter2, "Hello")); + EXPECT_TRUE(AZStd::wildcard_match(filter2, "?")); + EXPECT_TRUE(AZStd::wildcard_match(filter2, "*")); + EXPECT_TRUE(AZStd::wildcard_match(filter2, "Q")); - EXPECT_TRUE(wildcard_match(filter3, "Hello")); - EXPECT_TRUE(wildcard_match(filter3, "?")); - EXPECT_TRUE(wildcard_match(filter3, "*")); - EXPECT_TRUE(wildcard_match(filter3, "Q")); + EXPECT_TRUE(AZStd::wildcard_match(filter3, "Hello")); + EXPECT_TRUE(AZStd::wildcard_match(filter3, "?")); + EXPECT_TRUE(AZStd::wildcard_match(filter3, "*")); + EXPECT_TRUE(AZStd::wildcard_match(filter3, "Q")); } TEST_F(String, WildcardMatch_NormalString_Succeeds) { constexpr AZStd::string_view jpgFilter{ "**/*.jpg" }; - EXPECT_FALSE(wildcard_match(jpgFilter, "Test.jpg")); - EXPECT_FALSE(wildcard_match(jpgFilter, "Test.jpfg")); - EXPECT_TRUE(wildcard_match(jpgFilter, "Images/Other.jpg")); - EXPECT_FALSE(wildcard_match(jpgFilter, "Pictures/Other.gif")); + EXPECT_FALSE(AZStd::wildcard_match(jpgFilter, "Test.jpg")); + EXPECT_FALSE(AZStd::wildcard_match(jpgFilter, "Test.jpfg")); + EXPECT_TRUE(AZStd::wildcard_match(jpgFilter, "Images/Other.jpg")); + EXPECT_FALSE(AZStd::wildcard_match(jpgFilter, "Pictures/Other.gif")); constexpr AZStd::string_view tempDirFilter{ "temp/*" }; - EXPECT_TRUE(wildcard_match(tempDirFilter, "temp/")); - EXPECT_TRUE(wildcard_match(tempDirFilter, "temp/f")); - EXPECT_FALSE(wildcard_match(tempDirFilter, "tem1/")); + EXPECT_TRUE(AZStd::wildcard_match(tempDirFilter, "temp/")); + EXPECT_TRUE(AZStd::wildcard_match(tempDirFilter, "temp/f")); + EXPECT_FALSE(AZStd::wildcard_match(tempDirFilter, "tem1/")); constexpr AZStd::string_view xmlFilter{ "test.xml" }; - EXPECT_TRUE(wildcard_match(xmlFilter, "Test.xml")); - EXPECT_TRUE(wildcard_match(xmlFilter, "test.xml")); - EXPECT_FALSE(wildcard_match(xmlFilter, "test.xmlschema")); - EXPECT_FALSE(wildcard_match(xmlFilter, "Xtest.xml")); + EXPECT_TRUE(AZStd::wildcard_match(xmlFilter, "Test.xml")); + EXPECT_TRUE(AZStd::wildcard_match(xmlFilter, "test.xml")); + EXPECT_FALSE(AZStd::wildcard_match(xmlFilter, "test.xmlschema")); + EXPECT_FALSE(AZStd::wildcard_match(xmlFilter, "Xtest.xml")); } TEST_F(String, WildcardMatchCase_CanBeCompileTimeEvaluated_Succeeds) @@ -2424,6 +2420,31 @@ namespace UnitTest EXPECT_EQ("oWord", eraseIfTest); } + TEST_F(String, StringWithStatelessAllocator_HasSizeOf_PointerPlus2IntTypes_Compiles) + { + // The expected size of a basic_string with a stateless allocator + // Is the size of the pointer (used for storing the memory address of the string) + // + the size of the string "size" member used to store the size of the string + // + the size of the string "capacity" member used to store the capacity of the string + size_t constexpr ExpectedBasicStringSize = sizeof(void*) + 2 * sizeof(size_t); + using StringStatelessAllocator = AZStd::basic_string, AZStd::stateless_allocator>; + static_assert(ExpectedBasicStringSize == sizeof(StringStatelessAllocator), + "Stateless allocator is counting against the size of the basic_string class" + " A change has made to break the empty base optimization of the basic_string class"); + } + + TEST_F(String, StringWithStatefulAllocator_HasSizeOf_PointerPlus2IntTypesPlusAllocator_Compiles) + { + // The expected size of a basic_string with a stateless allocator + // Is the size of the pointer (used for storing the memory address of the string) + // + the size of the string "size" member used to store the size of the string + // + the size of the string "capacity" member used to store the capacity of the string + size_t constexpr ExpectedBasicStringSize = sizeof(void*) + 2 * sizeof(size_t) + sizeof(AZStd::allocator); + static_assert(ExpectedBasicStringSize == sizeof(AZStd::string), + "Using Stateful allocator with basic_string class should result in a 32-byte string class" + " on 64-bit platforms "); + } + template class ImmutableStringFunctionsFixture : public ScopedAllocatorSetupFixture @@ -2473,5 +2494,296 @@ namespace UnitTest EXPECT_EQ(str, formatted); } -#endif // AZ_UNIT_TEST_SKIP_STD_STRING_TESTS } + +#if defined(HAVE_BENCHMARK) +namespace Benchmark +{ + class StringBenchmarkFixture + : public ::UnitTest::AllocatorsBenchmarkFixture + { + protected: + template + void SwapStringViaMemcpy(AZStd::basic_string& left, + AZStd::basic_string& right) + { + // Test Swapping the storage container for the string class + // Use aligned_storage to prevent constructors from slowing operation + AZStd::aligned_storage_for_t tempStorage; + ::memcpy(&tempStorage, &left.m_storage.first(), sizeof(left.m_storage.first())); + ::memcpy(&left.m_storage.first(), &right.m_storage.first(), sizeof(right.m_storage.first())); + ::memcpy(&right.m_storage.first(), &tempStorage, sizeof(tempStorage)); + } + + + template + void SwapStringViaPointerSizedSwaps(AZStd::basic_string& left, + AZStd::basic_string& right) + { + using String = AZStd::basic_string; + using PointerAlignedData = typename String::PointerAlignedData; + // Use pointer sized swaps to swap the string storage + auto& leftAlignedPointers = reinterpret_cast(left.m_storage.first()); + auto& rightAlignedPointers = reinterpret_cast(right.m_storage.first()); + constexpr size_t alignedPointerCount{ AZStd::size(PointerAlignedData{}.m_alignedValues) }; + for (size_t i = 0; i < alignedPointerCount; ++i) + { + AZStd::swap(leftAlignedPointers.m_alignedValues[i], rightAlignedPointers.m_alignedValues[i]); + } + } + }; + + BENCHMARK_F(StringBenchmarkFixture, BM_StringPointerSwapShortString)(benchmark::State& state) + { + AZStd::string test1{ "foo bar"}; + AZStd::string test2{ "bar foo" }; + for (auto _ : state) + { + SwapStringViaPointerSizedSwaps(test1, test2); + } + } + + BENCHMARK_F(StringBenchmarkFixture, BM_StringPointerSwapLongString)(benchmark::State& state) + { + AZStd::string test1{ "The brown quick wolf jumped over the hyperactive cat" }; + AZStd::string test2{ "The quick brown fox jumped over the lazy dog" }; + for (auto _ : state) + { + SwapStringViaPointerSizedSwaps(test1, test2); + } + } + + BENCHMARK_F(StringBenchmarkFixture, BM_StringMemcpySwapShortString)(benchmark::State& state) + { + AZStd::string test1{ "foo bar" }; + AZStd::string test2{ "bar foo" }; + for (auto _ : state) + { + SwapStringViaMemcpy(test1, test2); + } + } + + BENCHMARK_F(StringBenchmarkFixture, BM_StringMemcpySwapLongString)(benchmark::State& state) + { + AZStd::string test1{ "The brown quick wolf jumped over the hyperactive cat" }; + AZStd::string test2{ "The quick brown fox jumped over the lazy dog" }; + for (auto _ : state) + { + SwapStringViaMemcpy(test1, test2); + } + } + + template + class StringTemplateBenchmarkFixture + : public ::UnitTest::AllocatorsBenchmarkFixture + {}; + + // AZStd::string assign benchmarks + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_StringAssignConstPointer_NullDelimited, AZStd::string)(benchmark::State& state) + { + AZStd::string sourceString(state.range(0), 'a'); + const char* sourceAddress = sourceString.c_str(); + + for (auto _ : state) + { + AZStd::string assignString; + assignString.assign(sourceAddress); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_StringAssignConstPointer_NullDelimited) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_StringAssignConstPointer_WithSize, AZStd::string)(benchmark::State& state) + { + AZStd::string sourceString(state.range(0), 'a'); + const char* sourceAddress = sourceString.c_str(); + const size_t sourceSize = sourceString.size(); + + for (auto _ : state) + { + AZStd::string assignString; + assignString.assign(sourceAddress, sourceSize); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_StringAssignConstPointer_WithSize) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_StringAssignFromIterators, AZStd::string)(benchmark::State& state) + { + AZStd::string sourceString(state.range(0), 'a'); + auto sourceBegin = sourceString.begin(); + auto sourceEnd = sourceString.end(); + + for (auto _ : state) + { + AZStd::string assignString; + assignString.assign(sourceBegin, sourceEnd); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_StringAssignFromIterators) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_StringAssignFromStringView, AZStd::string)(benchmark::State& state) + { + AZStd::string sourceString(state.range(0), 'a'); + AZStd::string_view sourceView(sourceString); + + for (auto _ : state) + { + AZStd::string assignString; + assignString.assign(sourceView); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_StringAssignFromStringView) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_StringAssignFromString_LValue, AZStd::string)(benchmark::State& state) + { + AZStd::string sourceString(state.range(0), 'a'); + + for (auto _ : state) + { + AZStd::string assignString; + assignString.assign(sourceString); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_StringAssignFromString_LValue) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_StringAssignFromString_RValue, AZStd::string)(benchmark::State& state) + { + AZStd::string sourceString(state.range(0), 'a'); + + for (auto _ : state) + { + AZStd::string assignString; + assignString.assign(AZStd::move(sourceString)); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_StringAssignFromString_RValue) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_StringAssignFromSingleCharacter, AZStd::string)(benchmark::State& state) + { + for (auto _ : state) + { + AZStd::string assignString; + assignString.assign(state.range(0), 'a'); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_StringAssignFromSingleCharacter) + ->RangeMultiplier(2)->Range(8, 32); + + // AZStd::fixed_string assign benchmarks + // NOTE: This is a copy-and-paste of above because Google Benchmark doesn't support real templated benchmarks like Googletest + // https://github.com/google/benchmark/issues/541 + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignConstPointer_NullDelimited, AZStd::fixed_string<1024>)(benchmark::State& state) + { + AZStd::fixed_string<1024> sourceString(state.range(0), 'a'); + const char* sourceAddress = sourceString.c_str(); + + for (auto _ : state) + { + AZStd::fixed_string<1024> assignString; + assignString.assign(sourceAddress); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignConstPointer_NullDelimited) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignConstPointer_WithSize, AZStd::fixed_string<1024>)(benchmark::State& state) + { + AZStd::fixed_string<1024> sourceString(state.range(0), 'a'); + const char* sourceAddress = sourceString.c_str(); + const size_t sourceSize = sourceString.size(); + + for (auto _ : state) + { + AZStd::fixed_string<1024> assignString; + assignString.assign(sourceAddress, sourceSize); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignConstPointer_WithSize) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromIterators, AZStd::fixed_string<1024>)(benchmark::State& state) + { + AZStd::fixed_string<1024> sourceString(state.range(0), 'a'); + auto sourceBegin = sourceString.begin(); + auto sourceEnd = sourceString.end(); + + for (auto _ : state) + { + AZStd::fixed_string<1024> assignString; + assignString.assign(sourceBegin, sourceEnd); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromIterators) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromStringView, AZStd::fixed_string<1024>)(benchmark::State& state) + { + AZStd::fixed_string<1024> sourceString(state.range(0), 'a'); + AZStd::string_view sourceView(sourceString); + + for (auto _ : state) + { + AZStd::fixed_string<1024> assignString; + assignString.assign(sourceView); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromStringView) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromString_LValue, AZStd::fixed_string<1024>)(benchmark::State& state) + { + AZStd::fixed_string<1024> sourceString(state.range(0), 'a'); + + for (auto _ : state) + { + AZStd::fixed_string<1024> assignString; + assignString.assign(sourceString); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromString_LValue) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromString_RValue, AZStd::fixed_string<1024>)(benchmark::State& state) + { + AZStd::fixed_string<1024> sourceString(state.range(0), 'a'); + + for (auto _ : state) + { + AZStd::fixed_string<1024> assignString; + assignString.assign(AZStd::move(sourceString)); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromString_RValue) + ->RangeMultiplier(2)->Range(8, 32); + + BENCHMARK_TEMPLATE_DEFINE_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromSingleCharacter, AZStd::fixed_string<1024>)(benchmark::State& state) + { + for (auto _ : state) + { + AZStd::fixed_string<1024> assignString; + assignString.assign(state.range(0), 'a'); + } + } + + BENCHMARK_REGISTER_F(StringTemplateBenchmarkFixture, BM_FixedStringAssignFromSingleCharacter) + ->RangeMultiplier(2)->Range(8, 32); +} +#endif diff --git a/Code/Framework/AzCore/Tests/DOM/DomJsonBenchmarks.cpp b/Code/Framework/AzCore/Tests/DOM/DomJsonBenchmarks.cpp index 0baa4aeb53..8eda110e7b 100644 --- a/Code/Framework/AzCore/Tests/DOM/DomJsonBenchmarks.cpp +++ b/Code/Framework/AzCore/Tests/DOM/DomJsonBenchmarks.cpp @@ -8,9 +8,10 @@ #if defined(HAVE_BENCHMARK) -#include #include #include +#include +#include #include #include #include @@ -25,27 +26,31 @@ namespace Benchmark { UnitTest::AllocatorsBenchmarkFixture::SetUp(st); AZ::NameDictionary::Create(); + AZ::AllocatorInstance::Create(); } void SetUp(::benchmark::State& st) override { UnitTest::AllocatorsBenchmarkFixture::SetUp(st); AZ::NameDictionary::Create(); + AZ::AllocatorInstance::Create(); } void TearDown(::benchmark::State& st) override { + AZ::AllocatorInstance::Destroy(); AZ::NameDictionary::Destroy(); UnitTest::AllocatorsBenchmarkFixture::TearDown(st); } void TearDown(const ::benchmark::State& st) override { + AZ::AllocatorInstance::Destroy(); AZ::NameDictionary::Destroy(); UnitTest::AllocatorsBenchmarkFixture::TearDown(st); } - AZStd::string GenerateDomJsonBenchmarkPayload(int64_t entryCount, int64_t stringTemplateLength) + rapidjson::Document GenerateDomJsonBenchmarkDocument(int64_t entryCount, int64_t stringTemplateLength) { rapidjson::Document document; document.SetObject(); @@ -103,11 +108,28 @@ namespace Benchmark document.SetObject(); document.AddMember("entries", createObject(), document.GetAllocator()); + return document; + } + + AZStd::string GenerateDomJsonBenchmarkPayload(int64_t entryCount, int64_t stringTemplateLength) + { + rapidjson::Document document = GenerateDomJsonBenchmarkDocument(entryCount, stringTemplateLength); + AZStd::string serializedJson; auto result = AZ::JsonSerializationUtils::WriteJsonString(document, serializedJson); AZ_Assert(result.IsSuccess(), "Failed to serialize generated JSON"); return serializedJson; } + + template + void TakeAndDiscardWithoutTimingDtor(T&& value, benchmark::State& state) + { + { + T instance = AZStd::move(value); + state.PauseTiming(); + } + state.ResumeTiming(); + } }; // Helper macro for registering JSON benchmarks @@ -119,7 +141,7 @@ namespace Benchmark ->Args({ 100, 500 }) \ ->Unit(benchmark::kMillisecond); - BENCHMARK_DEFINE_F(DomJsonBenchmark, DomDeserializeToDocumentInPlace)(benchmark::State& state) + BENCHMARK_DEFINE_F(DomJsonBenchmark, AzDomDeserializeToRapidjsonInPlace)(benchmark::State& state) { AZ::Dom::JsonBackend backend; AZStd::string serializedPayload = GenerateDomJsonBenchmarkPayload(state.range(0), state.range(1)); @@ -136,14 +158,38 @@ namespace Benchmark return AZ::Dom::Utils::ReadFromStringInPlace(backend, payloadCopy, visitor); }); - benchmark::DoNotOptimize(result.GetValue()); + TakeAndDiscardWithoutTimingDtor(result.TakeValue(), state); } state.SetBytesProcessed(serializedPayload.size() * state.iterations()); } - BENCHMARK_REGISTER_JSON(DomJsonBenchmark, DomDeserializeToDocumentInPlace) + BENCHMARK_REGISTER_JSON(DomJsonBenchmark, AzDomDeserializeToRapidjsonInPlace) - BENCHMARK_DEFINE_F(DomJsonBenchmark, DomDeserializeToDocument)(benchmark::State& state) + BENCHMARK_DEFINE_F(DomJsonBenchmark, AzDomDeserializeToAzDomValueInPlace)(benchmark::State& state) + { + AZ::Dom::JsonBackend backend; + AZStd::string serializedPayload = GenerateDomJsonBenchmarkPayload(state.range(0), state.range(1)); + + for (auto _ : state) + { + state.PauseTiming(); + AZStd::string payloadCopy = serializedPayload; + state.ResumeTiming(); + + auto result = AZ::Dom::Utils::WriteToValue( + [&](AZ::Dom::Visitor& visitor) + { + return AZ::Dom::Utils::ReadFromStringInPlace(backend, payloadCopy, visitor); + }); + + TakeAndDiscardWithoutTimingDtor(result.TakeValue(), state); + } + + state.SetBytesProcessed(serializedPayload.size() * state.iterations()); + } + BENCHMARK_REGISTER_JSON(DomJsonBenchmark, AzDomDeserializeToAzDomValueInPlace) + + BENCHMARK_DEFINE_F(DomJsonBenchmark, AzDomDeserializeToRapidjson)(benchmark::State& state) { AZ::Dom::JsonBackend backend; AZStd::string serializedPayload = GenerateDomJsonBenchmarkPayload(state.range(0), state.range(1)); @@ -156,14 +202,34 @@ namespace Benchmark return AZ::Dom::Utils::ReadFromString(backend, serializedPayload, AZ::Dom::Lifetime::Temporary, visitor); }); - benchmark::DoNotOptimize(result.GetValue()); + TakeAndDiscardWithoutTimingDtor(result.TakeValue(), state); + } + + state.SetBytesProcessed(serializedPayload.size() * state.iterations()); + } + BENCHMARK_REGISTER_JSON(DomJsonBenchmark, AzDomDeserializeToRapidjson) + + BENCHMARK_DEFINE_F(DomJsonBenchmark, AzDomDeserializeToAzDomValue)(benchmark::State& state) + { + AZ::Dom::JsonBackend backend; + AZStd::string serializedPayload = GenerateDomJsonBenchmarkPayload(state.range(0), state.range(1)); + + for (auto _ : state) + { + auto result = AZ::Dom::Utils::WriteToValue( + [&](AZ::Dom::Visitor& visitor) + { + return AZ::Dom::Utils::ReadFromString(backend, serializedPayload, AZ::Dom::Lifetime::Temporary, visitor); + }); + + TakeAndDiscardWithoutTimingDtor(result.TakeValue(), state); } state.SetBytesProcessed(serializedPayload.size() * state.iterations()); } - BENCHMARK_REGISTER_JSON(DomJsonBenchmark, DomDeserializeToDocument) + BENCHMARK_REGISTER_JSON(DomJsonBenchmark, AzDomDeserializeToAzDomValue) - BENCHMARK_DEFINE_F(DomJsonBenchmark, JsonUtilsDeserializeToDocument)(benchmark::State& state) + BENCHMARK_DEFINE_F(DomJsonBenchmark, RapidjsonDeserializeToRapidjson)(benchmark::State& state) { AZ::Dom::JsonBackend backend; AZStd::string serializedPayload = GenerateDomJsonBenchmarkPayload(state.range(0), state.range(1)); @@ -172,12 +238,78 @@ namespace Benchmark { auto result = AZ::JsonSerializationUtils::ReadJsonString(serializedPayload); - benchmark::DoNotOptimize(result.GetValue()); + TakeAndDiscardWithoutTimingDtor(result.TakeValue(), state); } state.SetBytesProcessed(serializedPayload.size() * state.iterations()); } - BENCHMARK_REGISTER_JSON(DomJsonBenchmark, JsonUtilsDeserializeToDocument) + BENCHMARK_REGISTER_JSON(DomJsonBenchmark, RapidjsonDeserializeToRapidjson) + + BENCHMARK_DEFINE_F(DomJsonBenchmark, RapidjsonMakeComplexObject)(benchmark::State& state) + { + for (auto _ : state) + { + TakeAndDiscardWithoutTimingDtor(GenerateDomJsonBenchmarkPayload(state.range(0), state.range(1)), state); + } + + state.SetItemsProcessed(state.range(0) * state.range(0) * state.iterations()); + } + BENCHMARK_REGISTER_JSON(DomJsonBenchmark, RapidjsonMakeComplexObject) + + BENCHMARK_DEFINE_F(DomJsonBenchmark, RapidjsonLookupMemberByString)(benchmark::State& state) + { + rapidjson::Document document(rapidjson::kObjectType); + AZStd::vector keys; + for (int64_t i = 0; i < state.range(0); ++i) + { + AZStd::string key(AZStd::string::format("key%" PRId64, i)); + keys.push_back(key); + document.AddMember(rapidjson::Value(key.data(), static_cast(key.size()), document.GetAllocator()), rapidjson::Value(i), document.GetAllocator()); + } + + for (auto _ : state) + { + for (const AZStd::string& key : keys) + { + benchmark::DoNotOptimize(document.FindMember(key.data())); + } + } + + state.SetItemsProcessed(state.iterations() * state.range(0)); + } + BENCHMARK_REGISTER_F(DomJsonBenchmark, RapidjsonLookupMemberByString)->Arg(100)->Arg(1000)->Arg(10000)->Unit(benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(DomJsonBenchmark, RapidjsonDeepCopy)(benchmark::State& state) + { + rapidjson::Document original = GenerateDomJsonBenchmarkDocument(state.range(0), state.range(1)); + + for (auto _ : state) + { + rapidjson::Document copy; + copy.CopyFrom(original, copy.GetAllocator(), true); + TakeAndDiscardWithoutTimingDtor(AZStd::move(copy), state); + } + + state.SetItemsProcessed(state.iterations()); + } + + BENCHMARK_REGISTER_JSON(DomJsonBenchmark, RapidjsonDeepCopy) + + BENCHMARK_DEFINE_F(DomJsonBenchmark, RapidjsonCopyAndMutate)(benchmark::State& state) + { + rapidjson::Document original = GenerateDomJsonBenchmarkDocument(state.range(0), state.range(1)); + + for (auto _ : state) + { + rapidjson::Document copy; + copy.CopyFrom(original, copy.GetAllocator(), true); + copy["entries"]["Key0"].PushBack(42, copy.GetAllocator()); + TakeAndDiscardWithoutTimingDtor(AZStd::move(copy), state); + } + + state.SetItemsProcessed(state.iterations()); + } + BENCHMARK_REGISTER_JSON(DomJsonBenchmark, RapidjsonCopyAndMutate) #undef BENCHMARK_REGISTER_JSON } // namespace Benchmark diff --git a/Code/Framework/AzCore/Tests/DOM/DomValueBenchmarks.cpp b/Code/Framework/AzCore/Tests/DOM/DomValueBenchmarks.cpp new file mode 100644 index 0000000000..40b96e148b --- /dev/null +++ b/Code/Framework/AzCore/Tests/DOM/DomValueBenchmarks.cpp @@ -0,0 +1,263 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include +#include +#include +#include + +namespace AZ::Dom::Benchmark +{ + class DomValueBenchmark : public UnitTest::AllocatorsBenchmarkFixture + { + public: + void SetUp(const ::benchmark::State& st) override + { + UnitTest::AllocatorsBenchmarkFixture::SetUp(st); + AZ::NameDictionary::Create(); + AZ::AllocatorInstance::Create(); + } + + void SetUp(::benchmark::State& st) override + { + UnitTest::AllocatorsBenchmarkFixture::SetUp(st); + AZ::NameDictionary::Create(); + AZ::AllocatorInstance::Create(); + } + + void TearDown(::benchmark::State& st) override + { + AZ::AllocatorInstance::Destroy(); + AZ::NameDictionary::Destroy(); + UnitTest::AllocatorsBenchmarkFixture::TearDown(st); + } + + void TearDown(const ::benchmark::State& st) override + { + AZ::AllocatorInstance::Destroy(); + AZ::NameDictionary::Destroy(); + UnitTest::AllocatorsBenchmarkFixture::TearDown(st); + } + + Value GenerateDomBenchmarkPayload(int64_t entryCount, int64_t stringTemplateLength) + { + Value root(Type::Object); + + AZStd::string entryTemplate; + while (entryTemplate.size() < static_cast(stringTemplateLength)) + { + entryTemplate += "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor "; + } + entryTemplate.resize(stringTemplateLength); + AZStd::string buffer; + + auto createString = [&](int n) -> Value + { + return Value(AZStd::string::format("#%i %s", n, entryTemplate.c_str()), true); + }; + + auto createEntry = [&](int n) -> Value + { + Value entry(Type::Object); + entry.AddMember("string", createString(n)); + entry.AddMember("int", Value(n)); + entry.AddMember("double", Value(static_cast(n) * 0.5)); + entry.AddMember("bool", Value(n % 2 == 0)); + entry.AddMember("null", Value(Type::Null)); + return entry; + }; + + auto createArray = [&]() -> Value + { + Value array(Type::Array); + for (int i = 0; i < entryCount; ++i) + { + array.ArrayPushBack(createEntry(i)); + } + return array; + }; + + auto createObject = [&]() -> Value + { + Value object; + object.SetObject(); + for (int i = 0; i < entryCount; ++i) + { + buffer = AZStd::string::format("Key%i", i); + object.AddMember(AZ::Name(buffer), createArray()); + } + return object; + }; + + root["entries"] = createObject(); + + return root; + } + + template + void TakeAndDiscardWithoutTimingDtor(T&& value, benchmark::State& state) + { + { + T instance = AZStd::move(value); + state.PauseTiming(); + } + state.ResumeTiming(); + } + }; + + BENCHMARK_DEFINE_F(DomValueBenchmark, AzDomValueMakeComplexObject)(benchmark::State& state) + { + for (auto _ : state) + { + TakeAndDiscardWithoutTimingDtor(GenerateDomBenchmarkPayload(state.range(0), state.range(1)), state); + } + + state.SetItemsProcessed(state.range(0) * state.range(0) * state.iterations()); + } + BENCHMARK_REGISTER_F(DomValueBenchmark, AzDomValueMakeComplexObject) + ->Args({ 10, 5 }) + ->Args({ 10, 500 }) + ->Args({ 100, 5 }) + ->Args({ 100, 500 }) + ->Unit(benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(DomValueBenchmark, AzDomValueShallowCopy)(benchmark::State& state) + { + Value original = GenerateDomBenchmarkPayload(state.range(0), state.range(1)); + + for (auto _ : state) + { + Value copy = original; + benchmark::DoNotOptimize(copy); + } + + state.SetItemsProcessed(state.iterations()); + } + BENCHMARK_REGISTER_F(DomValueBenchmark, AzDomValueShallowCopy) + ->Args({ 10, 5 }) + ->Args({ 10, 500 }) + ->Args({ 100, 5 }) + ->Args({ 100, 500 }) + ->Unit(benchmark::kNanosecond); + + BENCHMARK_DEFINE_F(DomValueBenchmark, AzDomValueCopyAndMutate)(benchmark::State& state) + { + Value original = GenerateDomBenchmarkPayload(state.range(0), state.range(1)); + + for (auto _ : state) + { + Value copy = original; + copy["entries"]["Key0"].ArrayPushBack(Value(42)); + TakeAndDiscardWithoutTimingDtor(AZStd::move(copy), state); + } + + state.SetItemsProcessed(state.iterations()); + } + BENCHMARK_REGISTER_F(DomValueBenchmark, AzDomValueCopyAndMutate) + ->Args({ 10, 5 }) + ->Args({ 10, 500 }) + ->Args({ 100, 5 }) + ->Args({ 100, 500 }) + ->Unit(benchmark::kNanosecond); + + BENCHMARK_DEFINE_F(DomValueBenchmark, AzDomValueDeepCopy)(benchmark::State& state) + { + Value original = GenerateDomBenchmarkPayload(state.range(0), state.range(1)); + + for (auto _ : state) + { + Value copy = Utils::DeepCopy(original); + TakeAndDiscardWithoutTimingDtor(AZStd::move(copy), state); + } + + state.SetItemsProcessed(state.iterations()); + } + BENCHMARK_REGISTER_F(DomValueBenchmark, AzDomValueDeepCopy) + ->Args({ 10, 5 }) + ->Args({ 10, 500 }) + ->Args({ 100, 5 }) + ->Args({ 100, 500 }) + ->Unit(benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(DomValueBenchmark, LookupMemberByName)(benchmark::State& state) + { + Value value(Type::Object); + AZStd::vector keys; + for (int64_t i = 0; i < state.range(0); ++i) + { + AZ::Name key(AZStd::string::format("key%" PRId64, i)); + keys.push_back(key); + value[key] = i; + } + + for (auto _ : state) + { + for (const AZ::Name& key : keys) + { + benchmark::DoNotOptimize(value[key]); + } + } + + state.SetItemsProcessed(state.iterations() * state.range(0)); + } + BENCHMARK_REGISTER_F(DomValueBenchmark, LookupMemberByName)->Arg(100)->Arg(1000)->Arg(10000)->Unit(benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(DomValueBenchmark, LookupMemberByString)(benchmark::State& state) + { + Value value(Type::Object); + AZStd::vector keys; + for (int64_t i = 0; i < state.range(0); ++i) + { + AZStd::string key(AZStd::string::format("key%" PRId64, i)); + keys.push_back(key); + value[key] = i; + } + + for (auto _ : state) + { + for (const AZStd::string& key : keys) + { + benchmark::DoNotOptimize(value[key]); + } + } + + state.SetItemsProcessed(state.iterations() * state.range(0)); + } + BENCHMARK_REGISTER_F(DomValueBenchmark, LookupMemberByString)->Arg(100)->Arg(1000)->Arg(10000)->Unit(benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(DomValueBenchmark, LookupMemberByStringComparison)(benchmark::State& state) + { + Value value(Type::Object); + AZStd::vector keys; + for (int64_t i = 0; i < state.range(0); ++i) + { + AZStd::string key(AZStd::string::format("key%" PRId64, i)); + keys.push_back(key); + value[key] = i; + } + + for (auto _ : state) + { + for (const AZStd::string& key : keys) + { + const Object::ContainerType& object = value.GetObject(); + benchmark::DoNotOptimize(AZStd::find_if( + object.cbegin(), object.cend(), + [&key](const Object::EntryType& entry) + { + return key == entry.first.GetStringView(); + })); + } + } + + state.SetItemsProcessed(state.iterations() * state.range(0)); + } + BENCHMARK_REGISTER_F(DomValueBenchmark, LookupMemberByStringComparison)->Arg(100)->Arg(1000)->Arg(10000)->Unit(benchmark::kMillisecond); + +} // namespace AZ::Dom::Benchmark diff --git a/Code/Framework/AzCore/Tests/DOM/DomValueTests.cpp b/Code/Framework/AzCore/Tests/DOM/DomValueTests.cpp new file mode 100644 index 0000000000..10e9f29a44 --- /dev/null +++ b/Code/Framework/AzCore/Tests/DOM/DomValueTests.cpp @@ -0,0 +1,392 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +namespace AZ::Dom::Tests +{ + class DomValueTests : public UnitTest::AllocatorsFixture + { + public: + void SetUp() override + { + UnitTest::AllocatorsFixture::SetUp(); + NameDictionary::Create(); + AZ::AllocatorInstance::Create(); + } + + void TearDown() override + { + m_value = Value(); + + AZ::AllocatorInstance::Destroy(); + NameDictionary::Destroy(); + UnitTest::AllocatorsFixture::TearDown(); + } + + void PerformValueChecks() + { + Value shallowCopy = m_value; + EXPECT_EQ(m_value, shallowCopy); + EXPECT_TRUE(Utils::DeepCompareIsEqual(m_value, shallowCopy)); + + Value deepCopy = Utils::DeepCopy(m_value); + EXPECT_TRUE(Utils::DeepCompareIsEqual(m_value, deepCopy)); + } + + Value m_value; + }; + + TEST_F(DomValueTests, EmptyArray) + { + m_value.SetArray(); + + EXPECT_TRUE(m_value.IsArray()); + EXPECT_EQ(m_value.ArraySize(), 0); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, SimpleArray) + { + m_value.SetArray(); + + for (int i = 0; i < 5; ++i) + { + m_value.ArrayPushBack(Value(i)); + EXPECT_EQ(m_value.ArraySize(), i + 1); + EXPECT_EQ(m_value[i].GetInt64(), i); + } + + PerformValueChecks(); + } + + TEST_F(DomValueTests, NestedArrays) + { + Value x(5); + m_value.SetArray(); + for (int j = 0; j < 5; ++j) + { + Value nestedArray(Type::Array); + for (int i = 0; i < 5; ++i) + { + nestedArray.ArrayPushBack(Value(i)); + } + m_value.ArrayPushBack(AZStd::move(nestedArray)); + } + + EXPECT_EQ(m_value.ArraySize(), 5); + for (int i = 0; i < 3; ++i) + { + EXPECT_EQ(m_value[i].ArraySize(), 5); + for (int j = 0; j < 5; ++j) + { + EXPECT_EQ(m_value[i][j].GetInt64(), j); + } + } + + PerformValueChecks(); + } + + TEST_F(DomValueTests, EmptyObject) + { + m_value.SetObject(); + EXPECT_EQ(m_value.MemberCount(), 0); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, SimpleObject) + { + m_value.SetObject(); + for (int i = 0; i < 5; ++i) + { + AZStd::string key = AZStd::string::format("Key%i", i); + m_value.AddMember(key, Value(i)); + EXPECT_EQ(m_value.MemberCount(), i + 1); + EXPECT_EQ(m_value[key].GetInt64(), i); + } + + PerformValueChecks(); + } + + TEST_F(DomValueTests, NestedObjects) + { + m_value.SetObject(); + for (int j = 0; j < 3; ++j) + { + Value nestedObject(Type::Object); + for (int i = 0; i < 5; ++i) + { + nestedObject.AddMember(AZStd::string::format("Key%i", i), Value(i)); + } + m_value.AddMember(AZStd::string::format("Obj%i", j), AZStd::move(nestedObject)); + } + + EXPECT_EQ(m_value.MemberCount(), 3); + for (int j = 0; j < 3; ++j) + { + const Value& nestedObject = m_value[AZStd::string::format("Obj%i", j)]; + EXPECT_EQ(nestedObject.MemberCount(), 5); + for (int i = 0; i < 5; ++i) + { + EXPECT_EQ(nestedObject[AZStd::string::format("Key%i", i)].GetInt64(), i); + } + } + + PerformValueChecks(); + } + + TEST_F(DomValueTests, EmptyNode) + { + m_value.SetNode("Test"); + EXPECT_EQ(m_value.GetNodeName(), AZ::Name("Test")); + EXPECT_EQ(m_value.MemberCount(), 0); + EXPECT_EQ(m_value.ArraySize(), 0); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, SimpleNode) + { + m_value.SetNode("Test"); + + for (int i = 0; i < 10; ++i) + { + m_value.ArrayPushBack(Value(i)); + EXPECT_EQ(m_value.ArraySize(), i + 1); + EXPECT_EQ(m_value[i].GetInt64(), i); + + if (i < 5) + { + AZ::Name key = AZ::Name(AZStd::string::format("TwoTimes%i", i)); + m_value.AddMember(key, Value(i * 2)); + EXPECT_EQ(m_value.MemberCount(), i + 1); + EXPECT_EQ(m_value[key].GetInt64(), i * 2); + } + } + + PerformValueChecks(); + } + + TEST_F(DomValueTests, NestedNodes) + { + m_value.SetNode("TopLevel"); + + const AZ::Name childNodeName("ChildNode"); + + for (int i = 0; i < 5; ++i) + { + Value childNode(Type::Node); + childNode.SetNodeName(childNodeName); + childNode.SetNodeValue(Value(i)); + + childNode.AddMember("foo", Value(i)); + childNode.AddMember("bar", Value("test", false)); + + m_value.ArrayPushBack(childNode); + } + + EXPECT_EQ(m_value.ArraySize(), 5); + for (int i = 0; i < 5; ++i) + { + const Value& childNode = m_value[i]; + EXPECT_EQ(childNode.GetNodeName(), childNodeName); + EXPECT_EQ(childNode.GetNodeValue().GetInt64(), i); + EXPECT_EQ(childNode["foo"].GetInt64(), i); + EXPECT_EQ(childNode["bar"].GetString(), "test"); + } + + PerformValueChecks(); + } + + TEST_F(DomValueTests, Int64) + { + m_value.SetObject(); + m_value["int64_min"] = AZStd::numeric_limits::min(); + m_value["int64_max"] = AZStd::numeric_limits::max(); + + EXPECT_EQ(m_value["int64_min"].GetType(), Type::Int64); + EXPECT_EQ(m_value["int64_min"].GetInt64(), AZStd::numeric_limits::min()); + EXPECT_EQ(m_value["int64_max"].GetType(), Type::Int64); + EXPECT_EQ(m_value["int64_max"].GetInt64(), AZStd::numeric_limits::max()); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, Uint64) + { + m_value.SetObject(); + m_value["uint64_min"] = AZStd::numeric_limits::min(); + m_value["uint64_max"] = AZStd::numeric_limits::max(); + + EXPECT_EQ(m_value["uint64_min"].GetType(), Type::Uint64); + EXPECT_EQ(m_value["uint64_min"].GetInt64(), AZStd::numeric_limits::min()); + EXPECT_EQ(m_value["uint64_max"].GetType(), Type::Uint64); + EXPECT_EQ(m_value["uint64_max"].GetInt64(), AZStd::numeric_limits::max()); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, Double) + { + m_value.SetObject(); + m_value["double_min"] = AZStd::numeric_limits::min(); + m_value["double_max"] = AZStd::numeric_limits::max(); + + EXPECT_EQ(m_value["double_min"].GetType(), Type::Double); + EXPECT_EQ(m_value["double_min"].GetDouble(), AZStd::numeric_limits::min()); + EXPECT_EQ(m_value["double_max"].GetType(), Type::Double); + EXPECT_EQ(m_value["double_max"].GetDouble(), AZStd::numeric_limits::max()); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, Null) + { + m_value.SetObject(); + m_value["null_value"] = Value(Type::Null); + + EXPECT_EQ(m_value["null_value"].GetType(), Type::Null); + EXPECT_EQ(m_value["null_type"], Value()); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, Bool) + { + m_value.SetObject(); + m_value["true_value"] = true; + m_value["false_value"] = false; + + EXPECT_EQ(m_value["true_value"].GetType(), Type::Bool); + EXPECT_EQ(m_value["true_value"].GetBool(), true); + EXPECT_EQ(m_value["false_value"].GetType(), Type::Bool); + EXPECT_EQ(m_value["false_value"].GetBool(), false); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, String) + { + const char* s1 = "reference string long enough to avoid SSO"; + const char* s2 = "copy string long enough to avoid SSO"; + + m_value.SetObject(); + AZStd::string stringToReference = s1; + m_value["no_copy"] = Value(stringToReference, false); + AZStd::string stringToCopy = s2; + m_value["copy"] = Value(stringToCopy, true); + + EXPECT_EQ(m_value["no_copy"].GetType(), Type::String); + EXPECT_EQ(m_value["no_copy"].GetString(), s1); + stringToReference.at(0) = 'F'; + EXPECT_NE(m_value["no_copy"].GetString(), s1); + + EXPECT_EQ(m_value["copy"].GetType(), Type::String); + EXPECT_EQ(m_value["copy"].GetString(), s2); + stringToCopy.at(0) = 'F'; + EXPECT_EQ(m_value["copy"].GetString(), s2); + + PerformValueChecks(); + } + + TEST_F(DomValueTests, CopyOnWrite_Object) + { + Value v1(Type::Object); + v1["foo"] = 5; + + Value nestedObject(Type::Object); + v1["obj"] = nestedObject; + + Value v2 = v1; + EXPECT_EQ(&v1.GetObject(), &v2.GetObject()); + EXPECT_EQ(&v1.FindMember("obj")->second.GetObject(), &v2.FindMember("obj")->second.GetObject()); + + v2["foo"] = 0; + + EXPECT_NE(&v1.GetObject(), &v2.GetObject()); + EXPECT_EQ(&v1.FindMember("obj")->second.GetObject(), &v2.FindMember("obj")->second.GetObject()); + + v2["obj"]["key"] = true; + + EXPECT_NE(&v1.GetObject(), &v2.GetObject()); + EXPECT_NE(&v1.FindMember("obj")->second.GetObject(), &v2.FindMember("obj")->second.GetObject()); + + v2 = v1; + + EXPECT_EQ(&v1.GetObject(), &v2.GetObject()); + EXPECT_EQ(&v1.FindMember("obj")->second.GetObject(), &v2.FindMember("obj")->second.GetObject()); + } + + TEST_F(DomValueTests, CopyOnWrite_Array) + { + Value v1(Type::Array); + v1.ArrayPushBack(Value(1)); + v1.ArrayPushBack(Value(2)); + + Value nestedArray(Type::Array); + v1.ArrayPushBack(nestedArray); + Value v2 = v1; + + EXPECT_EQ(&v1.GetArray(), &v2.GetArray()); + EXPECT_EQ(&v1.ArrayAt(2).GetArray(), &v2.ArrayAt(2).GetArray()); + + v2[0] = 0; + + EXPECT_NE(&v1.GetArray(), &v2.GetArray()); + EXPECT_EQ(&v1.ArrayAt(2).GetArray(), &v2.ArrayAt(2).GetArray()); + + v2[2].ArrayPushBack(Value(42)); + + EXPECT_NE(&v1.GetArray(), &v2.GetArray()); + EXPECT_NE(&v1.ArrayAt(2).GetArray(), &v2.ArrayAt(2).GetArray()); + + v2 = v1; + + EXPECT_EQ(&v1.GetArray(), &v2.GetArray()); + EXPECT_EQ(&v1.ArrayAt(2).GetArray(), &v2.ArrayAt(2).GetArray()); + } + + TEST_F(DomValueTests, CopyOnWrite_Node) + { + Value v1; + v1.SetNode("TopLevel"); + + v1.ArrayPushBack(Value(1)); + v1.ArrayPushBack(Value(2)); + v1["obj"].SetNode("Nested"); + Value v2 = v1; + + EXPECT_EQ(&v1.GetNode(), &v2.GetNode()); + EXPECT_EQ(&v1["obj"].GetNode(), &v2["obj"].GetNode()); + + v2[0] = 0; + + EXPECT_NE(&v1.GetNode(), &v2.GetNode()); + EXPECT_EQ(&v1["obj"].GetNode(), &v2["obj"].GetNode()); + + v2["obj"].ArrayPushBack(Value(42)); + + EXPECT_NE(&v1.GetNode(), &v2.GetNode()); + EXPECT_NE(&v1["obj"].GetNode(), &v2["obj"].GetNode()); + + v2 = v1; + + EXPECT_EQ(&v1.GetNode(), &v2.GetNode()); + EXPECT_EQ(&v1["obj"].GetNode(), &v2["obj"].GetNode()); + } +} // namespace AZ::Dom::Tests diff --git a/Code/Framework/AzCore/Tests/Math/MathTest.h b/Code/Framework/AzCore/Tests/Math/MathTest.h new file mode 100644 index 0000000000..783c08a553 --- /dev/null +++ b/Code/Framework/AzCore/Tests/Math/MathTest.h @@ -0,0 +1,19 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include + +#if AZ_DEBUG_BUILD + #define AZ_MATH_TEST_START_TRACE_SUPPRESSION AZ_TEST_START_TRACE_SUPPRESSION + #define AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(x) AZ_TEST_STOP_TRACE_SUPPRESSION(x) +#else + #define AZ_MATH_TEST_START_TRACE_SUPPRESSION + #define AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(x) +#endif diff --git a/Code/Framework/AzCore/Tests/Math/PlaneTests.cpp b/Code/Framework/AzCore/Tests/Math/PlaneTests.cpp index 016a7ec6e2..398c1320ed 100644 --- a/Code/Framework/AzCore/Tests/Math/PlaneTests.cpp +++ b/Code/Framework/AzCore/Tests/Math/PlaneTests.cpp @@ -12,6 +12,7 @@ #include #include #include +#include using namespace AZ; @@ -47,7 +48,9 @@ namespace UnitTest TEST(MATH_Plane, TestSet) { Plane pl; + AZ_MATH_TEST_START_TRACE_SUPPRESSION; pl.Set(12.0f, 13.0f, 14.0f, 15.0f); + AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(1); AZ_TEST_ASSERT_FLOAT_CLOSE(pl.GetDistance(), 15.0f); AZ_TEST_ASSERT_FLOAT_CLOSE(pl.GetNormal().GetX(), 12.0f); AZ_TEST_ASSERT_FLOAT_CLOSE(pl.GetNormal().GetY(), 13.0f); @@ -57,7 +60,9 @@ namespace UnitTest TEST(MATH_Plane, TestSetVector3) { Plane pl; + AZ_MATH_TEST_START_TRACE_SUPPRESSION; pl.Set(Vector3(22.0f, 23.0f, 24.0f), 25.0f); + AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(1); AZ_TEST_ASSERT_FLOAT_CLOSE(pl.GetDistance(), 25.0f); AZ_TEST_ASSERT_FLOAT_CLOSE(pl.GetNormal().GetX(), 22.0f); AZ_TEST_ASSERT_FLOAT_CLOSE(pl.GetNormal().GetY(), 23.0f); @@ -177,17 +182,21 @@ namespace UnitTest pl.Set(1.0f, 0.0f, 0.0f, 0.0f); AZ_TEST_ASSERT(pl.IsFinite()); const float infinity = std::numeric_limits::infinity(); + AZ_MATH_TEST_START_TRACE_SUPPRESSION; pl.Set(infinity, infinity, infinity, infinity); + AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(1); AZ_TEST_ASSERT(!pl.IsFinite()); } TEST(MATH_Plane, CreateFromVectorCoefficients_IsEquivalentToCreateFromCoefficients) { + AZ_MATH_TEST_START_TRACE_SUPPRESSION; Plane planeFromCoefficients = Plane::CreateFromCoefficients(1.0, 2.0, 3.0, 4.0); - + AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(1); Vector4 coefficients(1.0, 2.0, 3.0, 4.0); Plane planeFromVectorCoefficients = Plane::CreateFromVectorCoefficients(coefficients); + EXPECT_EQ(planeFromVectorCoefficients, planeFromCoefficients); } } diff --git a/Code/Framework/AzCore/Tests/Math/QuaternionTests.cpp b/Code/Framework/AzCore/Tests/Math/QuaternionTests.cpp index 9ef38d7115..3de60a1fd4 100644 --- a/Code/Framework/AzCore/Tests/Math/QuaternionTests.cpp +++ b/Code/Framework/AzCore/Tests/Math/QuaternionTests.cpp @@ -11,6 +11,7 @@ #include #include #include +#include using namespace AZ; @@ -453,7 +454,7 @@ namespace UnitTest AZ::Quaternion backFromScaledAxisAngle = AZ::Quaternion::CreateFromScaledAxisAngle(scaledAxisAngle); // Compare the original quaternion with the one after the conversion. - EXPECT_TRUE(testQuat.IsClose(backFromScaledAxisAngle, 1e-6f)); + EXPECT_THAT(testQuat, IsCloseTolerance(backFromScaledAxisAngle, 1e-6f)); } TEST_P(QuaternionScaledAxisAngleConversionFixture, AxisAngleQuatRoundtripTests) @@ -467,7 +468,7 @@ namespace UnitTest // Convert the axis-angle back into a quaternion and compare the original quaternion with the one after the conversion. const AZ::Quaternion backFromAxisAngle = AZ::Quaternion::CreateFromAxisAngle(axis, angle); - EXPECT_TRUE(testQuat.IsClose(backFromAxisAngle, 1e-6f)); + EXPECT_THAT(testQuat, IsCloseTolerance(backFromAxisAngle, 1e-6f)); } TEST_P(QuaternionScaledAxisAngleConversionFixture, CompareAxisAngleConversionTests) @@ -506,8 +507,20 @@ namespace UnitTest } const AZ::Quaternion backFromAxisAngle = AZ::Quaternion::CreateFromAxisAngle(axisFromScaledResult, angleFromScaledResult); - EXPECT_TRUE(testQuat.IsClose(backFromAxisAngle, 1e-6f)); + EXPECT_THAT(testQuat, IsCloseTolerance(backFromAxisAngle, 1e-6f)); } INSTANTIATE_TEST_CASE_P(MATH_Quaternion, QuaternionScaledAxisAngleConversionFixture, ::testing::ValuesIn(RotationRepresentationConversionTestQuats)); + + TEST(MATH_Quaternion, ShortestEquivalent) + { + const AZ::Quaternion testQuat = AZ::Quaternion::CreateRotationX(AZ::Constants::HalfPi * 3.0f); + + AZ::Quaternion absQuat = testQuat; + absQuat.ShortestEquivalent(); + EXPECT_THAT(testQuat.GetShortestEquivalent(), IsCloseTolerance(absQuat, 1e-6f)); + + const float angle = absQuat.GetEulerRadians().GetX(); + EXPECT_THAT(angle, testing::FloatEq(-AZ::Constants::HalfPi)); + } } diff --git a/Code/Framework/AzCore/Tests/Memory/AllocatorBenchmarkRecordings.bin b/Code/Framework/AzCore/Tests/Memory/AllocatorBenchmarkRecordings.bin new file mode 100644 index 0000000000..ec5de82e83 --- /dev/null +++ b/Code/Framework/AzCore/Tests/Memory/AllocatorBenchmarkRecordings.bin @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:281ba03e79ecba90b313a0b17bdba87c57d76b504b6e38d579b5eabd995902cc +size 245760 diff --git a/Code/Framework/AzCore/Tests/Memory/AllocatorBenchmarks.cpp b/Code/Framework/AzCore/Tests/Memory/AllocatorBenchmarks.cpp new file mode 100644 index 0000000000..bc477e41dc --- /dev/null +++ b/Code/Framework/AzCore/Tests/Memory/AllocatorBenchmarks.cpp @@ -0,0 +1,591 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#if defined(HAVE_BENCHMARK) + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +namespace Benchmark +{ + namespace Platform + { + size_t GetProcessMemoryUsageBytes(); + size_t GetMemorySize(void* memory); + } + + /// + /// Test allocator wrapper that redirects the calls to the passed TAllocator by using AZ::AllocatorInstance. + /// It also creates/destroys the TAllocator type (to reflect what happens at runtime) + /// + /// Allocator type to wrap + template + class TestAllocatorWrapper + { + public: + static void SetUp() + { + AZ::AllocatorInstance::Create(); + } + + static void TearDown() + { + AZ::AllocatorInstance::Destroy(); + } + + static void* Allocate(size_t byteSize, size_t alignment) + { + return AZ::AllocatorInstance::Get().Allocate(byteSize, alignment); + } + + static void DeAllocate(void* ptr, size_t byteSize = 0) + { + AZ::AllocatorInstance::Get().DeAllocate(ptr, byteSize); + } + + static void* ReAllocate(void* ptr, size_t newSize, size_t newAlignment) + { + return AZ::AllocatorInstance::Get().ReAllocate(ptr, newSize, newAlignment); + } + + static size_t Resize(void* ptr, size_t newSize) + { + return AZ::AllocatorInstance::Get().Resize(ptr, newSize); + } + + static void GarbageCollect() + { + AZ::AllocatorInstance::Get().GarbageCollect(); + } + + static size_t NumAllocatedBytes() + { + return AZ::AllocatorInstance::Get().NumAllocatedBytes() + + AZ::AllocatorInstance::Get().GetUnAllocatedMemory(); + } + + static size_t GetSize(void* ptr) + { + return AZ::AllocatorInstance::Get().AllocationSize(ptr); + } + }; + + /// + /// Basic allocator used as a baseline. This allocator is the most basic allocation possible with the OS (AZ_OS_MALLOC). + /// MallocSchema cannot be used here because it has extra logic that we don't want to use as a baseline. + /// + class RawMallocAllocator {}; + + template<> + class TestAllocatorWrapper + { + public: + TestAllocatorWrapper() + { + s_numAllocatedBytes = 0; + } + + static void SetUp() + { + s_numAllocatedBytes = 0; + } + + static void TearDown() + { + } + + // IAllocatorAllocate + static void* Allocate(size_t byteSize, size_t) + { + s_numAllocatedBytes += byteSize; + // Don't pass an alignment since we wont be able to get the memory size without also passing the alignment + return AZ_OS_MALLOC(byteSize, 1); + } + + static void DeAllocate(void* ptr, size_t = 0) + { + s_numAllocatedBytes -= Platform::GetMemorySize(ptr); + AZ_OS_FREE(ptr); + } + + static void* ReAllocate(void* ptr, size_t newSize, size_t) + { + s_numAllocatedBytes -= Platform::GetMemorySize(ptr); + AZ_OS_FREE(ptr); + + s_numAllocatedBytes += newSize; + return AZ_OS_MALLOC(newSize, 1); + } + + static size_t Resize(void* ptr, size_t newSize) + { + AZ_UNUSED(ptr); + AZ_UNUSED(newSize); + + return 0; + } + + static void GarbageCollect() {} + + static size_t NumAllocatedBytes() + { + return s_numAllocatedBytes; + } + + static size_t GetSize(void* ptr) + { + return Platform::GetMemorySize(ptr); + } + + private: + static size_t s_numAllocatedBytes; + }; + + size_t TestAllocatorWrapper::s_numAllocatedBytes = 0; + + // Some allocator are not fully declared, those we simply setup from the schema + class MallocSchemaAllocator : public AZ::SimpleSchemaAllocator + { + public: + AZ_TYPE_INFO(MallocSchemaAllocator, "{3E68224F-E676-402C-8276-CE4B49C05E89}"); + + MallocSchemaAllocator() + : AZ::SimpleSchemaAllocator("MallocSchemaAllocator", "") + {} + }; + + // We use both this HphaSchemaAllocator and the SystemAllocator configured with Hpha because the SystemAllocator + // has extra things + class HphaSchemaAllocator : public AZ::SimpleSchemaAllocator + { + public: + AZ_TYPE_INFO(HphaSchemaAllocator, "{6563AB4B-A68E-4499-8C98-D61D640D1F7F}"); + + HphaSchemaAllocator() + : AZ::SimpleSchemaAllocator("TestHphaSchemaAllocator", "") + {} + }; + + // For the SystemAllocator we inherit so we have a different stack. The SystemAllocator is used globally so we dont want + // to get that data affecting the benchmark + class TestSystemAllocator : public AZ::SystemAllocator + { + public: + AZ_TYPE_INFO(TestSystemAllocator, "{360D4DAA-D65D-4D5C-A6FA-1A4C5261C35C}"); + + TestSystemAllocator() + : AZ::SystemAllocator() + { + } + }; + + // Allocated bytes reported by the allocator + static const char* s_counterAllocatorMemory = "Allocator_Memory"; + + // Allocated bytes as counted by the benchmark + static const char* s_counterBenchmarkMemory = "Benchmark_Memory"; + + enum AllocationSize + { + SMALL, + BIG, + MIXED, + COUNT + }; + + static const size_t s_kiloByte = 1024; + static const size_t s_megaByte = s_kiloByte * s_kiloByte; + using AllocationSizeArray = AZStd::array; + static const AZStd::array s_allocationSizes = { + /* SMALL */ AllocationSizeArray{ 2, 16, 20, 59, 100, 128, 160, 250, 300, 512 }, + /* BIG */ AllocationSizeArray{ 513, s_kiloByte, 2 * s_kiloByte, 4 * s_kiloByte, 10 * s_kiloByte, 64 * s_kiloByte, 128 * s_kiloByte, 200 * s_kiloByte, s_megaByte, 2 * s_megaByte }, + /* MIXED */ AllocationSizeArray{ 2, s_kiloByte, 59, 4 * s_kiloByte, 128, 200 * s_kiloByte, 250, s_megaByte, 512, 2 * s_megaByte } + }; + + template + class AllocatorBenchmarkFixture + : public ::benchmark::Fixture + { + protected: + using TestAllocatorType = TestAllocatorWrapper; + + virtual void internalSetUp(const ::benchmark::State& state) + { + if (state.thread_index == 0) // Only setup in the first thread + { + TestAllocatorType::SetUp(); + + m_allocations.resize(state.threads); + for (auto& perThreadAllocations : m_allocations) + { + perThreadAllocations.resize(state.range(0), nullptr); + } + } + } + + virtual void internalTearDown(const ::benchmark::State& state) + { + if (state.thread_index == 0) // Only setup in the first thread + { + m_allocations.clear(); + m_allocations.shrink_to_fit(); + + TestAllocatorType::TearDown(); + } + } + + AZStd::vector& GetPerThreadAllocations(size_t threadIndex) + { + return m_allocations[threadIndex]; + } + + public: + void SetUp(const ::benchmark::State& state) override + { + internalSetUp(state); + } + void SetUp(::benchmark::State& state) override + { + internalSetUp(state); + } + + void TearDown(const ::benchmark::State& state) override + { + internalTearDown(state); + } + void TearDown(::benchmark::State& state) override + { + internalTearDown(state); + } + + private: + AZStd::vector> m_allocations; + }; + + template + class AllocationBenchmarkFixture + : public AllocatorBenchmarkFixture + { + using base = AllocatorBenchmarkFixture; + using TestAllocatorType = typename base::TestAllocatorType; + + public: + void Benchmark(benchmark::State& state) + { + for (auto _ : state) + { + state.PauseTiming(); + + AZStd::vector& perThreadAllocations = base::GetPerThreadAllocations(state.thread_index); + const size_t numberOfAllocations = perThreadAllocations.size(); + size_t totalAllocationSize = 0; + for (size_t allocationIndex = 0; allocationIndex < numberOfAllocations; ++allocationIndex) + { + const AllocationSizeArray& allocationArray = s_allocationSizes[TAllocationSize]; + const size_t allocationSize = allocationArray[allocationIndex % allocationArray.size()]; + totalAllocationSize += allocationSize; + + state.ResumeTiming(); + perThreadAllocations[allocationIndex] = TestAllocatorType::Allocate(allocationSize, 0); + state.PauseTiming(); + } + + state.counters[s_counterAllocatorMemory] = benchmark::Counter(static_cast(TestAllocatorType::NumAllocatedBytes()), benchmark::Counter::kDefaults); + state.counters[s_counterBenchmarkMemory] = benchmark::Counter(static_cast(totalAllocationSize), benchmark::Counter::kDefaults); + + for (size_t allocationIndex = 0; allocationIndex < numberOfAllocations; ++allocationIndex) + { + const AllocationSizeArray& allocationArray = s_allocationSizes[TAllocationSize]; + const size_t allocationSize = allocationArray[allocationIndex % allocationArray.size()]; + TestAllocatorType::DeAllocate(perThreadAllocations[allocationIndex], allocationSize); + perThreadAllocations[allocationIndex] = nullptr; + } + TestAllocatorType::GarbageCollect(); + + state.SetItemsProcessed(numberOfAllocations); + } + } + }; + + template + class DeAllocationBenchmarkFixture + : public AllocatorBenchmarkFixture + { + using base = AllocatorBenchmarkFixture; + using TestAllocatorType = typename base::TestAllocatorType; + + public: + void Benchmark(benchmark::State& state) + { + for (auto _ : state) + { + state.PauseTiming(); + AZStd::vector& perThreadAllocations = base::GetPerThreadAllocations(state.thread_index); + + const size_t numberOfAllocations = perThreadAllocations.size(); + size_t totalAllocationSize = 0; + for (size_t allocationIndex = 0; allocationIndex < numberOfAllocations; ++allocationIndex) + { + const AllocationSizeArray& allocationArray = s_allocationSizes[TAllocationSize]; + const size_t allocationSize = allocationArray[allocationIndex % allocationArray.size()]; + totalAllocationSize += allocationSize; + perThreadAllocations[allocationIndex] = TestAllocatorType::Allocate(allocationSize, 0); + } + + for (size_t allocationIndex = 0; allocationIndex < numberOfAllocations; ++allocationIndex) + { + const AllocationSizeArray& allocationArray = s_allocationSizes[TAllocationSize]; + const size_t allocationSize = allocationArray[allocationIndex % allocationArray.size()]; + state.ResumeTiming(); + TestAllocatorType::DeAllocate(perThreadAllocations[allocationIndex], allocationSize); + state.PauseTiming(); + perThreadAllocations[allocationIndex] = nullptr; + } + + state.counters[s_counterAllocatorMemory] = benchmark::Counter(static_cast(TestAllocatorType::NumAllocatedBytes()), benchmark::Counter::kDefaults); + state.counters[s_counterBenchmarkMemory] = benchmark::Counter(static_cast(totalAllocationSize), benchmark::Counter::kDefaults); + + state.SetItemsProcessed(numberOfAllocations); + + TestAllocatorType::GarbageCollect(); + } + } + }; + + template + class RecordedAllocationBenchmarkFixture : public ::benchmark::Fixture + { + using TestAllocatorType = TestAllocatorWrapper; + + virtual void internalSetUp() + { + TestAllocatorType::SetUp(); + } + + void internalTearDown() + { + TestAllocatorType::TearDown(); + } + + #pragma pack(push, 1) + struct alignas(1) AllocatorOperation + { + enum OperationType : size_t + { + ALLOCATE, + DEALLOCATE + }; + OperationType m_type : 1; + size_t m_size : 28; // Can represent up to 256Mb requests + size_t m_alignment : 7; // Can represent up to 128 alignment + size_t m_recordId : 28; // Can represent up to 256M simultaneous requests, we reuse ids + }; + #pragma pack(pop) + static_assert(sizeof(AllocatorOperation) == 8); + + public: + void SetUp(const ::benchmark::State&) override + { + internalSetUp(); + } + void SetUp(::benchmark::State&) override + { + internalSetUp(); + } + + void TearDown(const ::benchmark::State&) override + { + internalTearDown(); + } + void TearDown(::benchmark::State&) override + { + internalTearDown(); + } + + void Benchmark(benchmark::State& state) + { + for (auto _ : state) + { + state.PauseTiming(); + + AZStd::unordered_map pointerRemapping; + constexpr size_t allocationOperationCount = 5 * 1024; + AZStd::array m_operations = {}; + [[maybe_unused]] const size_t operationSize = sizeof(AllocatorOperation); + + size_t totalAllocationSize = 0; + size_t itemsProcessed = 0; + + for (size_t i = 0; i < 100; ++i) // play the recording multiple times to get a good stable sample, this way we can keep a smaller recording + { + AZ::IO::SystemFile file; + AZ::IO::FixedMaxPathString filePath = AZ::Utils::GetExecutableDirectory(); + filePath += "/Tests/AzCore/Memory/AllocatorBenchmarkRecordings.bin"; + if (!file.Open(filePath.c_str(), AZ::IO::SystemFile::OpenMode::SF_OPEN_READ_ONLY)) + { + return; + } + size_t elementsRead = + file.Read(sizeof(AllocatorOperation) * allocationOperationCount, &m_operations) / sizeof(AllocatorOperation); + itemsProcessed += elementsRead; + + while (elementsRead > 0) + { + for (size_t operationIndex = 0; operationIndex < elementsRead; ++operationIndex) + { + const AllocatorOperation& operation = m_operations[operationIndex]; + if (operation.m_type == AllocatorOperation::ALLOCATE) + { + const auto it = pointerRemapping.emplace(operation.m_recordId, nullptr); + if (it.second) // otherwise already allocated + { + state.ResumeTiming(); + void* ptr = TestAllocatorType::Allocate(operation.m_size, operation.m_alignment); + state.PauseTiming(); + totalAllocationSize += operation.m_size; + it.first->second = ptr; + } + else + { + // Doing a resize, dont account for this memory change, this operation is rare and we dont have + // the size of the previous allocation + state.ResumeTiming(); + TestAllocatorType::Resize(it.first->second, operation.m_size); + state.PauseTiming(); + } + } + else // AllocatorOperation::DEALLOCATE: + { + if (operation.m_recordId) + { + const auto ptrIt = pointerRemapping.find(operation.m_recordId); + if (ptrIt != pointerRemapping.end()) + { + totalAllocationSize -= operation.m_size; + state.ResumeTiming(); + TestAllocatorType::DeAllocate( + ptrIt->second, + /*operation.m_size*/ 0); // size is not correct after a resize, a 0 size deals with it + state.PauseTiming(); + pointerRemapping.erase(ptrIt); + } + } + else // deallocate(nullptr) are recorded + { + // Just to account of the call of deallocate(nullptr); + state.ResumeTiming(); + TestAllocatorType::DeAllocate(nullptr, /*operation.m_size*/ 0); + state.PauseTiming(); + } + } + } + + elementsRead = + file.Read(sizeof(AllocatorOperation) * allocationOperationCount, &m_operations) / sizeof(AllocatorOperation); + itemsProcessed += elementsRead; + } + file.Close(); + + // Deallocate the remainder (since we stopped the recording middle-game)(there are leaks as well) + for (const auto& pointerMapping : pointerRemapping) + { + state.ResumeTiming(); + TestAllocatorType::DeAllocate(pointerMapping.second); + state.PauseTiming(); + } + itemsProcessed += pointerRemapping.size(); + pointerRemapping.clear(); + } + + state.counters[s_counterAllocatorMemory] = benchmark::Counter(static_cast(TestAllocatorType::NumAllocatedBytes()), benchmark::Counter::kDefaults); + state.counters[s_counterBenchmarkMemory] = benchmark::Counter(static_cast(totalAllocationSize), benchmark::Counter::kDefaults); + + state.SetItemsProcessed(itemsProcessed); + + TestAllocatorType::GarbageCollect(); + } + } + }; + + // For non-threaded ranges, run 100, 400, 1600 amounts + static void RunRanges(benchmark::internal::Benchmark* b) + { + for (int i = 0; i < 6; i += 2) + { + b->Arg((1 << i) * 100); + } + } + static void RecordedRunRanges(benchmark::internal::Benchmark* b) + { + b->Iterations(1); + } + + // For threaded ranges, run just 200, multi-threaded will already multiply by thread + static void ThreadedRunRanges(benchmark::internal::Benchmark* b) + { + b->Arg(100); + } + + // Test under and over-subscription of threads vs the amount of CPUs available + static const unsigned int MaxThreadRange = 2 * AZStd::thread::hardware_concurrency(); + +#define BM_REGISTER_TEMPLATE(FIXTURE, TESTNAME, ...) \ + BENCHMARK_TEMPLATE_DEFINE_F(FIXTURE, TESTNAME, __VA_ARGS__)(benchmark::State& state) { Benchmark(state); } \ + BENCHMARK_REGISTER_F(FIXTURE, TESTNAME) + + // We test small/big/mixed allocations in single-threaded environments. For multi-threaded environments, we test mixed since + // the multi threaded fixture will run multiple passes (1, 2, 4, ... until 2*hardware_concurrency) +#define BM_REGISTER_SIZE_FIXTURES(FIXTURE, TESTNAME, ALLOCATORTYPE) \ + BM_REGISTER_TEMPLATE(FIXTURE, TESTNAME##_SMALL, ALLOCATORTYPE, SMALL)->Apply(RunRanges); \ + BM_REGISTER_TEMPLATE(FIXTURE, TESTNAME##_BIG, ALLOCATORTYPE, BIG)->Apply(RunRanges); \ + BM_REGISTER_TEMPLATE(FIXTURE, TESTNAME##_MIXED, ALLOCATORTYPE, MIXED)->Apply(RunRanges); \ + BM_REGISTER_TEMPLATE(FIXTURE, TESTNAME##_MIXED_THREADED, ALLOCATORTYPE, MIXED)->ThreadRange(2, MaxThreadRange)->Apply(ThreadedRunRanges); + +#define BM_REGISTER_ALLOCATOR(TESTNAME, ALLOCATORTYPE) \ + namespace BM_##TESTNAME \ + { \ + BM_REGISTER_SIZE_FIXTURES(AllocationBenchmarkFixture, TESTNAME, ALLOCATORTYPE); \ + BM_REGISTER_SIZE_FIXTURES(DeAllocationBenchmarkFixture, TESTNAME, ALLOCATORTYPE); \ + BM_REGISTER_TEMPLATE(RecordedAllocationBenchmarkFixture, TESTNAME, ALLOCATORTYPE)->Apply(RecordedRunRanges); \ + } + + /// Warm up benchmark used to prepare the OS for allocations. Most OS keep allocations for a process somehow + /// reserved. So the first allocations run always get a bigger impact in a process. This warm up allocator runs + /// all the benchmarks and is just used for the the next allocators to report more consistent results. + BM_REGISTER_ALLOCATOR(WarmUpAllocator, RawMallocAllocator); + + BM_REGISTER_ALLOCATOR(RawMallocAllocator, RawMallocAllocator); + BM_REGISTER_ALLOCATOR(MallocSchemaAllocator, MallocSchemaAllocator); + BM_REGISTER_ALLOCATOR(HphaSchemaAllocator, HphaSchemaAllocator); + BM_REGISTER_ALLOCATOR(SystemAllocator, TestSystemAllocator); + + //BM_REGISTER_ALLOCATOR(BestFitExternalMapAllocator, BestFitExternalMapAllocator); // Requires to pre-allocate blocks and cannot work as a general-purpose allocator + //BM_REGISTER_ALLOCATOR(HeapSchemaAllocator, TestHeapSchemaAllocator); // Requires to pre-allocate blocks and cannot work as a general-purpose allocator + //BM_REGISTER_SCHEMA(PoolSchema); // Requires special alignment requests while allocating + +#undef BM_REGISTER_ALLOCATOR +#undef BM_REGISTER_SIZE_FIXTURES +#undef BM_REGISTER_TEMPLATE + +} // Benchmark + +#endif // HAVE_BENCHMARK diff --git a/Code/Framework/AzCore/Tests/Memory/HphaSchema.cpp b/Code/Framework/AzCore/Tests/Memory/HphaSchema.cpp index 85dd79931d..08b84416e6 100644 --- a/Code/Framework/AzCore/Tests/Memory/HphaSchema.cpp +++ b/Code/Framework/AzCore/Tests/Memory/HphaSchema.cpp @@ -10,10 +10,6 @@ #include #include -#if defined(HAVE_BENCHMARK) -#include -#endif // HAVE_BENCHMARK - class HphaSchema_TestAllocator : public AZ::SimpleSchemaAllocator { @@ -112,87 +108,3 @@ namespace UnitTest HphaSchemaTestFixture, ::testing::ValuesIn(s_mixedInstancesParameters)); } - - -#if defined(HAVE_BENCHMARK) -namespace Benchmark -{ - class HphaSchemaBenchmarkFixture - : public ::benchmark::Fixture - { - void internalSetUp() - { - AZ::AllocatorInstance::Create(); - } - - void internalTearDown() - { - AZ::AllocatorInstance::Destroy(); - } - - public: - void SetUp(const benchmark::State&) override - { - internalSetUp(); - } - void SetUp(benchmark::State&) override - { - internalSetUp(); - } - void TearDown(const benchmark::State&) override - { - internalTearDown(); - } - void TearDown(benchmark::State&) override - { - internalTearDown(); - } - - static void BM_Allocations(benchmark::State& state, const AllocationSizeArray& allocationArray) - { - AZStd::vector allocations; - while (state.KeepRunning()) - { - state.PauseTiming(); - const size_t allocationIndex = allocations.size(); - const size_t allocationSize = allocationArray[allocationIndex % allocationArray.size()]; - - state.ResumeTiming(); - void* allocation = AZ::AllocatorInstance::Get().Allocate(allocationSize, 0); - - state.PauseTiming(); - allocations.emplace_back(allocation); - - state.ResumeTiming(); - } - - const size_t numberOfAllocations = allocations.size(); - state.SetItemsProcessed(numberOfAllocations); - - for (size_t allocationIndex = 0; allocationIndex < numberOfAllocations; ++allocationIndex) - { - AZ::AllocatorInstance::Get().DeAllocate(allocations[allocationIndex], allocationArray[allocationIndex % allocationArray.size()]); - } - AZ::AllocatorInstance::Get().GarbageCollect(); - } - }; - - // Small allocations, these are allocations that are going to end up in buckets in the HphaSchema - BENCHMARK_F(HphaSchemaBenchmarkFixture, SmallAllocations)(benchmark::State& state) - { - BM_Allocations(state, s_smallAllocationSizes); - } - - BENCHMARK_F(HphaSchemaBenchmarkFixture, BigAllocations)(benchmark::State& state) - { - BM_Allocations(state, s_bigAllocationSizes); - } - - BENCHMARK_F(HphaSchemaBenchmarkFixture, MixedAllocations)(benchmark::State& state) - { - BM_Allocations(state, s_mixedAllocationSizes); - } - - -} // Benchmark -#endif // HAVE_BENCHMARK diff --git a/Code/Framework/AzCore/Tests/Platform/Android/Tests/Memory/AllocatorBenchmarks_Android.cpp b/Code/Framework/AzCore/Tests/Platform/Android/Tests/Memory/AllocatorBenchmarks_Android.cpp new file mode 100644 index 0000000000..636d5519d8 --- /dev/null +++ b/Code/Framework/AzCore/Tests/Platform/Android/Tests/Memory/AllocatorBenchmarks_Android.cpp @@ -0,0 +1,31 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include + +#include +#include + +namespace Benchmark +{ + namespace Platform + { + size_t GetProcessMemoryUsageBytes() + { + struct rusage rusage; + getrusage(RUSAGE_SELF, &rusage); + return rusage.ru_maxrss * 1024L; + } + + size_t GetMemorySize(void* memory) + { + return memory ? malloc_usable_size(memory) : 0; + } + } +} diff --git a/Code/Framework/AzCore/Tests/Platform/Android/platform_android_files.cmake b/Code/Framework/AzCore/Tests/Platform/Android/platform_android_files.cmake index ed54a84dbf..3ad1bd3185 100644 --- a/Code/Framework/AzCore/Tests/Platform/Android/platform_android_files.cmake +++ b/Code/Framework/AzCore/Tests/Platform/Android/platform_android_files.cmake @@ -8,4 +8,5 @@ set(FILES Tests/UtilsTests_Android.cpp + Tests/Memory/AllocatorBenchmarks_Android.cpp ) diff --git a/Code/Framework/AzCore/Tests/Platform/Linux/Tests/Memory/AllocatorBenchmarks_Linux.cpp b/Code/Framework/AzCore/Tests/Platform/Linux/Tests/Memory/AllocatorBenchmarks_Linux.cpp new file mode 100644 index 0000000000..636d5519d8 --- /dev/null +++ b/Code/Framework/AzCore/Tests/Platform/Linux/Tests/Memory/AllocatorBenchmarks_Linux.cpp @@ -0,0 +1,31 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include + +#include +#include + +namespace Benchmark +{ + namespace Platform + { + size_t GetProcessMemoryUsageBytes() + { + struct rusage rusage; + getrusage(RUSAGE_SELF, &rusage); + return rusage.ru_maxrss * 1024L; + } + + size_t GetMemorySize(void* memory) + { + return memory ? malloc_usable_size(memory) : 0; + } + } +} diff --git a/Code/Framework/AzCore/Tests/Platform/Linux/platform_linux_files.cmake b/Code/Framework/AzCore/Tests/Platform/Linux/platform_linux_files.cmake index 844b621e05..953dbb7791 100644 --- a/Code/Framework/AzCore/Tests/Platform/Linux/platform_linux_files.cmake +++ b/Code/Framework/AzCore/Tests/Platform/Linux/platform_linux_files.cmake @@ -9,4 +9,5 @@ set(FILES Tests/UtilsTests_Linux.cpp ../Common/UnixLike/Tests/UtilsTests_UnixLike.cpp + Tests/Memory/AllocatorBenchmarks_Linux.cpp ) diff --git a/Code/Framework/AzCore/Tests/Platform/Mac/Tests/Memory/AllocatorBenchmarks_Mac.cpp b/Code/Framework/AzCore/Tests/Platform/Mac/Tests/Memory/AllocatorBenchmarks_Mac.cpp new file mode 100644 index 0000000000..932252985a --- /dev/null +++ b/Code/Framework/AzCore/Tests/Platform/Mac/Tests/Memory/AllocatorBenchmarks_Mac.cpp @@ -0,0 +1,31 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include + +#include +#include + +namespace Benchmark +{ + namespace Platform + { + size_t GetProcessMemoryUsageBytes() + { + struct rusage rusage; + getrusage(RUSAGE_SELF, &rusage); + return rusage.ru_maxrss; + } + + size_t GetMemorySize(void* memory) + { + return memory ? malloc_size(memory) : 0; + } + } +} diff --git a/Code/Framework/AzCore/Tests/Platform/Mac/platform_mac_files.cmake b/Code/Framework/AzCore/Tests/Platform/Mac/platform_mac_files.cmake index 93d2daf2b8..14e39d47f4 100644 --- a/Code/Framework/AzCore/Tests/Platform/Mac/platform_mac_files.cmake +++ b/Code/Framework/AzCore/Tests/Platform/Mac/platform_mac_files.cmake @@ -9,4 +9,5 @@ set(FILES ../Common/Apple/Tests/UtilsTests_Apple.cpp ../Common/UnixLike/Tests/UtilsTests_UnixLike.cpp + Tests/Memory/AllocatorBenchmarks_Mac.cpp ) diff --git a/Code/Framework/AzCore/Tests/Platform/Windows/Tests/Memory/AllocatorBenchmarks_Windows.cpp b/Code/Framework/AzCore/Tests/Platform/Windows/Tests/Memory/AllocatorBenchmarks_Windows.cpp new file mode 100644 index 0000000000..e9571a7e5b --- /dev/null +++ b/Code/Framework/AzCore/Tests/Platform/Windows/Tests/Memory/AllocatorBenchmarks_Windows.cpp @@ -0,0 +1,40 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include + +#include +#include + +namespace Benchmark +{ + namespace Platform + { + size_t GetProcessMemoryUsageBytes() + { + EmptyWorkingSet(GetCurrentProcess()); + + size_t memoryUsage = 0; + MEMORY_BASIC_INFORMATION mbi = { 0 }; + unsigned char* pEndRegion = nullptr; + while (sizeof(mbi) == VirtualQuery(pEndRegion, &mbi, sizeof(mbi))) { + pEndRegion += mbi.RegionSize; + if ((mbi.AllocationProtect & PAGE_READWRITE) && (mbi.State & MEM_COMMIT)) { + memoryUsage += mbi.RegionSize; + } + } + return memoryUsage; + } + + size_t GetMemorySize(void* memory) + { + return memory ? _aligned_msize(memory, 1, 0) : 0; + } + } +} diff --git a/Code/Framework/AzCore/Tests/Platform/Windows/platform_windows_files.cmake b/Code/Framework/AzCore/Tests/Platform/Windows/platform_windows_files.cmake index 0a96dad34e..97b12b28e6 100644 --- a/Code/Framework/AzCore/Tests/Platform/Windows/platform_windows_files.cmake +++ b/Code/Framework/AzCore/Tests/Platform/Windows/platform_windows_files.cmake @@ -9,6 +9,7 @@ set(FILES ../Common/WinAPI/Tests/UtilsTests_WinAPI.cpp Tests/IO/Streamer/StorageDriveTests_Windows.cpp + Tests/Memory/AllocatorBenchmarks_Windows.cpp Tests/Memory/OverrunDetectionAllocator_Windows.cpp Tests/Serialization_Windows.cpp ) diff --git a/Code/Framework/AzCore/Tests/ScriptMath.cpp b/Code/Framework/AzCore/Tests/ScriptMath.cpp index 35541c5eec..927ea4a3cd 100644 --- a/Code/Framework/AzCore/Tests/ScriptMath.cpp +++ b/Code/Framework/AzCore/Tests/ScriptMath.cpp @@ -15,6 +15,8 @@ #include #include +#include + using namespace AZ; namespace UnitTest @@ -1409,13 +1411,17 @@ namespace UnitTest script->Execute("AZTestAssertFloatClose(pl:GetNormal().y,-1)"); script->Execute("AZTestAssertFloatClose(pl:GetNormal().z,0)"); + AZ_MATH_TEST_START_TRACE_SUPPRESSION; script->Execute("pl:Set(12, 13, 14, 15)"); + AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(1); script->Execute("AZTestAssertFloatClose(pl:GetDistance(), 15)"); script->Execute("AZTestAssertFloatClose(pl:GetNormal().x, 12)"); script->Execute("AZTestAssertFloatClose(pl:GetNormal().y, 13)"); script->Execute("AZTestAssertFloatClose(pl:GetNormal().z, 14)"); + AZ_MATH_TEST_START_TRACE_SUPPRESSION; script->Execute("pl:Set(Vector3(22, 23, 24), 25)"); + AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(1); script->Execute("AZTestAssertFloatClose(pl:GetDistance(), 25)"); script->Execute("AZTestAssertFloatClose(pl:GetNormal().x, 22)"); script->Execute("AZTestAssertFloatClose(pl:GetNormal().y, 23)"); @@ -1493,7 +1499,9 @@ namespace UnitTest script->Execute("pl:Set(1, 0, 0, 0)"); script->Execute("AZTestAssert(pl:IsFinite())"); + AZ_MATH_TEST_START_TRACE_SUPPRESSION; script->Execute("pl:Set(math.huge, math.huge, math.huge, math.huge)"); + AZ_MATH_TEST_STOP_TRACE_SUPPRESSION(1); script->Execute("AZTestAssert( not pl:IsFinite())"); } diff --git a/Code/Framework/AzCore/Tests/Serialization/Json/JsonRegistrationContextTests.cpp b/Code/Framework/AzCore/Tests/Serialization/Json/JsonRegistrationContextTests.cpp index 9d4af1def5..9b44f10e89 100644 --- a/Code/Framework/AzCore/Tests/Serialization/Json/JsonRegistrationContextTests.cpp +++ b/Code/Framework/AzCore/Tests/Serialization/Json/JsonRegistrationContextTests.cpp @@ -327,17 +327,13 @@ namespace JsonSerializationTests SerializerWithOneType::Unreflect(m_jsonRegistrationContext.get()); } -#if GTEST_HAS_DEATH_TEST - using JsonSerializationDeathTests = JsonRegistrationContextTests; - TEST_F(JsonSerializationDeathTests, DoubleUnregisterSerializer_Asserts) + TEST_F(JsonRegistrationContextTests, DoubleUnregisterSerializer_Asserts) { - ASSERT_DEATH({ - SerializerWithOneType::Reflect(m_jsonRegistrationContext.get()); - SerializerWithOneType::Unreflect(m_jsonRegistrationContext.get()); - SerializerWithOneType::Unreflect(m_jsonRegistrationContext.get()); - }, ".*" - ); + SerializerWithOneType::Reflect(m_jsonRegistrationContext.get()); + SerializerWithOneType::Unreflect(m_jsonRegistrationContext.get()); + AZ_TEST_START_ASSERTTEST; + SerializerWithOneType::Unreflect(m_jsonRegistrationContext.get()); + AZ_TEST_STOP_ASSERTTEST(1); } -#endif // GTEST_HAS_DEATH_TEST } //namespace JsonSerializationTests diff --git a/Code/Framework/AzCore/Tests/Serialization/Json/PathSerializerTests.cpp b/Code/Framework/AzCore/Tests/Serialization/Json/PathSerializerTests.cpp new file mode 100644 index 0000000000..e00a4171a2 --- /dev/null +++ b/Code/Framework/AzCore/Tests/Serialization/Json/PathSerializerTests.cpp @@ -0,0 +1,106 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include +#include +#include +#include + +namespace JsonSerializationTests +{ + template + class PathTestDescription + : public JsonSerializerConformityTestDescriptor + { + public: + using JsonSerializerConformityTestDescriptor::Reflect; + void Reflect(AZStd::unique_ptr& serializeContext) override + { + AZ::IO::PathReflect(serializeContext.get()); + } + void Reflect(AZStd::unique_ptr& jsonContext) override + { + AZ::IO::PathReflect(jsonContext.get()); + } + AZStd::shared_ptr CreateSerializer() override + { + return AZStd::make_shared(); + } + + AZStd::shared_ptr CreateDefaultInstance() override + { + return AZStd::make_shared(); + } + + AZStd::shared_ptr CreateFullySetInstance() override + { + return AZStd::make_shared("O3DE/Relative/Path"); + } + + AZStd::string_view GetJsonForFullySetInstance() override + { + return R"("O3DE/Relative/Path")"; + } + + void ConfigureFeatures(JsonSerializerConformityTestDescriptorFeatures& features) override + { + features.EnableJsonType(rapidjson::kStringType); + features.m_supportsPartialInitialization = false; + features.m_supportsInjection = false; + } + + bool AreEqual(const PathType& lhs, const PathType& rhs) override + { + return lhs == rhs; + } + }; + + using PathConformityTestTypes = ::testing::Types< + PathTestDescription, + PathTestDescription + >; + INSTANTIATE_TYPED_TEST_CASE_P(Path, JsonSerializerConformityTests, PathConformityTestTypes); + + + class PathSerializerTests + : public BaseJsonSerializerFixture + { + public: + AZStd::unique_ptr m_serializer; + + void SetUp() override + { + BaseJsonSerializerFixture::SetUp(); + m_serializer = AZStd::make_unique(); + } + + void TearDown() override + { + m_serializer.reset(); + BaseJsonSerializerFixture::TearDown(); + } + }; + + TEST_F(PathSerializerTests, LoadingIntoFixedMaxPath_GreaterThanMaxPathLength_Fails) + { + AZ::IO::Path testPath; + // Fill a path greater than the AZ::IO::MaxPathLength in write it to Json + testPath.Native().append(AZ::IO::MaxPathLength + 2, 'a'); + + rapidjson::Value loadPathValue; + AZ::JsonSerializationResult::ResultCode resultCode = m_serializer->Store(loadPathValue, + &testPath, nullptr, azrtti_typeid(), *m_jsonSerializationContext); + EXPECT_EQ(AZ::JsonSerializationResult::Outcomes::Success, resultCode.GetOutcome()); + + AZ::IO::FixedMaxPath resultPath; + AZ::JsonSerializationResult::ResultCode result = m_serializer->Load(&resultPath, azrtti_typeid(), + loadPathValue, *m_jsonDeserializationContext); + EXPECT_GE(result.GetOutcome(), AZ::JsonSerializationResult::Outcomes::Invalid); + } +} // namespace JsonSerializationTests diff --git a/Code/Framework/AzCore/Tests/Serialization/Json/TestCases_TypeId.cpp b/Code/Framework/AzCore/Tests/Serialization/Json/TestCases_TypeId.cpp index 60b8f55dce..b7362a5e61 100644 --- a/Code/Framework/AzCore/Tests/Serialization/Json/TestCases_TypeId.cpp +++ b/Code/Framework/AzCore/Tests/Serialization/Json/TestCases_TypeId.cpp @@ -10,6 +10,77 @@ #include #include #include +#include + +namespace AZ +{ + template + struct SerializeGenericTypeInfo> + { + using ThisType = JsonSerializationTests::TemplatedClass; + + class GenericTemplatedClassInfo : public GenericClassInfo + { + public: + GenericTemplatedClassInfo() + : m_classData{ SerializeContext::ClassData::Create( + "TemplatedClass", "{CA4ADF74-66E7-4D16-B4AC-F71278C60EC7}", nullptr, nullptr) } + { + } + + SerializeContext::ClassData* GetClassData() override + { + return &m_classData; + } + + size_t GetNumTemplatedArguments() override + { + return 1; + } + + const Uuid& GetSpecializedTypeId() const override + { + return m_classData.m_typeId; + } + + const Uuid& GetGenericTypeId() const override + { + return m_classData.m_typeId; + } + + const Uuid& GetTemplatedTypeId(size_t element) override + { + (void)element; + return SerializeGenericTypeInfo::GetClassTypeId(); + } + + void Reflect(SerializeContext* serializeContext) override + { + if (serializeContext) + { + serializeContext->RegisterGenericClassInfo( + GetSpecializedTypeId(), this, &AZ::AnyTypeInfoConcept>::CreateAny); + serializeContext->RegisterGenericClassInfo( + azrtti_typeid(), this, + &AZ::AnyTypeInfoConcept::CreateAny); + } + } + + SerializeContext::ClassData m_classData; + }; + + using ClassInfoType = GenericTemplatedClassInfo; + static ClassInfoType* GetGenericInfo() + { + return GetCurrentSerializeContextModule().CreateGenericClassInfo(); + } + + static const Uuid& GetClassTypeId() + { + return GetGenericInfo()->GetClassData()->m_typeId; + } + }; +} // namespace AZ namespace JsonSerializationTests { @@ -286,4 +357,32 @@ namespace JsonSerializationTests EXPECT_EQ(Processing::Halted, result.GetProcessing()); EXPECT_EQ(Outcomes::Unknown, result.GetOutcome()); } + + TEST_F(JsonSerializationTests, StoreTypeId_TemplatedType_StoresUuidWithName) + { + using namespace AZ; + using namespace AZ::JsonSerializationResult; + + m_serializeContext->RegisterGenericType>(); + m_serializeContext->RegisterGenericType>(); + + Uuid input = azrtti_typeid>(); + ResultCode result = JsonSerialization::StoreTypeId( + *m_jsonDocument, m_jsonDocument->GetAllocator(), input, AZStd::string_view{}, *m_serializationSettings); + + EXPECT_EQ(Processing::Completed, result.GetProcessing()); + + AZStd::string expected = + AZStd::string::format(R"("%s TemplatedClass")", azrtti_typeid>().ToString().c_str()); + Expect_DocStrEq(expected.c_str(), false); + + input = azrtti_typeid>(); + result = JsonSerialization::StoreTypeId( + *m_jsonDocument, m_jsonDocument->GetAllocator(), input, AZStd::string_view{}, *m_serializationSettings); + + expected = + AZStd::string::format(R"("%s TemplatedClass")", azrtti_typeid>().ToString().c_str()); + EXPECT_EQ(Processing::Completed, result.GetProcessing()); + Expect_DocStrEq(expected.c_str(), false); + } } // namespace JsonSerializationTests diff --git a/Code/Framework/AzCore/Tests/Time/TimeTests.cpp b/Code/Framework/AzCore/Tests/Time/TimeTests.cpp index 7ba01ec0e0..164e72343b 100644 --- a/Code/Framework/AzCore/Tests/Time/TimeTests.cpp +++ b/Code/Framework/AzCore/Tests/Time/TimeTests.cpp @@ -11,8 +11,7 @@ namespace UnitTest { - class TimeTests - : public AllocatorsFixture + class TimeTests : public AllocatorsFixture { public: void SetUp() override @@ -77,4 +76,4 @@ namespace UnitTest int64_t delta = static_cast(timeMs) - static_cast(timeUsToMs); EXPECT_LT(abs(delta), 1); } -} +} // namespace UnitTest diff --git a/Code/Framework/AzCore/Tests/azcoretests_files.cmake b/Code/Framework/AzCore/Tests/azcoretests_files.cmake index b7fe113bc6..7be3afb4a9 100644 --- a/Code/Framework/AzCore/Tests/azcoretests_files.cmake +++ b/Code/Framework/AzCore/Tests/azcoretests_files.cmake @@ -111,6 +111,7 @@ set(FILES Serialization/Json/MapSerializerTests.cpp Serialization/Json/MathVectorSerializerTests.cpp Serialization/Json/MathMatrixSerializerTests.cpp + Serialization/Json/PathSerializerTests.cpp Serialization/Json/SmartPointerSerializerTests.cpp Serialization/Json/StringSerializerTests.cpp Serialization/Json/TestCases.h @@ -147,6 +148,7 @@ set(FILES Math/Matrix4x4PerformanceTests.cpp Math/Matrix4x4Tests.cpp Math/MatrixUtilsTests.cpp + Math/MathTest.h Math/MathTestData.h Math/ObbPerformanceTests.cpp Math/ObbTests.cpp @@ -169,6 +171,7 @@ set(FILES Math/Vector3Tests.cpp Math/Vector4PerformanceTests.cpp Math/Vector4Tests.cpp + Memory/AllocatorBenchmarks.cpp Memory/AllocatorManager.cpp Memory/HphaSchema.cpp Memory/HphaSchemaErrorDetection.cpp @@ -214,6 +217,8 @@ set(FILES AZStd/VectorAndArray.cpp DOM/DomJsonTests.cpp DOM/DomJsonBenchmarks.cpp + DOM/DomValueTests.cpp + DOM/DomValueBenchmarks.cpp ) # Prevent the following files from being grouped in UNITY builds diff --git a/Code/Framework/AzFramework/AzFramework/Components/CameraBus.h b/Code/Framework/AzFramework/AzFramework/Components/CameraBus.h index e20578e939..964bf664a0 100644 --- a/Code/Framework/AzFramework/AzFramework/Components/CameraBus.h +++ b/Code/Framework/AzFramework/AzFramework/Components/CameraBus.h @@ -129,6 +129,32 @@ namespace Camera GetFrustumHeight() }; } + + //! Unprojects a position in screen space pixel coordinates to world space. + //! With a depth of zero, the position returned will be on the near clip plane of the camera + //! in world space. + //! @param screenPosition The absolute screen position + //! @param depth The depth offset into the world relative to the near clip plane of the camera + //! @return the position in world space + virtual AZ::Vector3 ScreenToWorld(const AZ::Vector2& screenPosition, float depth) = 0; + + //! Unprojects a position in screen space normalized device coordinates to world space. + //! With a depth of zero, the position returned will be on the near clip plane of the camera + //! in world space. + //! @param screenNdcPosition The normalized device coordinates in the range [0,1] + //! @param depth The depth offset into the world relative to the near clip plane of the camera + //! @return the position in world space + virtual AZ::Vector3 ScreenNdcToWorld(const AZ::Vector2& screenNdcPosition, float depth) = 0; + + //! Projects a position in world space to screen space for the given camera. + //! @param worldPosition The world position + //! @return The absolute screen position + virtual AZ::Vector2 WorldToScreen(const AZ::Vector3& worldPosition) = 0; + + //! Projects a position in world space to screen space normalized device coordinates. + //! @param worldPosition The world position + //! @return The normalized device coordinates in the range [0,1] + virtual AZ::Vector2 WorldToScreenNdc(const AZ::Vector3& worldPosition) = 0; }; using CameraRequestBus = AZ::EBus; diff --git a/Code/Framework/AzFramework/AzFramework/FileTag/FileTagComponent.cpp b/Code/Framework/AzFramework/AzFramework/FileTag/FileTagComponent.cpp index 1d09500415..f4831d1f8b 100644 --- a/Code/Framework/AzFramework/AzFramework/FileTag/FileTagComponent.cpp +++ b/Code/Framework/AzFramework/AzFramework/FileTag/FileTagComponent.cpp @@ -97,19 +97,38 @@ namespace AzFramework AZStd::vector registeredAssetPaths; AZ::Data::AssetCatalogRequestBus::BroadcastResult(registeredAssetPaths, &AZ::Data::AssetCatalogRequests::GetRegisteredAssetPaths); - const char* dependencyXmlPattern = "*_dependencies.xml"; + constexpr const char* dependencyXmlPattern = "_dependencies.xml"; for (const AZStd::string& assetPath : registeredAssetPaths) { - if (!AZStd::wildcard_match(dependencyXmlPattern, assetPath.c_str())) + if (assetPath.ends_with(dependencyXmlPattern)) { - continue; + AZ_VerifyError("ExcludeFileComponent", m_excludeFileQueryManager.get()->LoadEngineDependencies(assetPath), + "Failed to add assets referenced from %s to the blocked list", assetPath.c_str()); } + } + } - if (!m_excludeFileQueryManager.get()->LoadEngineDependencies(assetPath)) - { - AZ_Error("ExcludeFileComponent", false, "Failed to add assets referenced from %s to the blocked list", assetPath.c_str()); - } + void ExcludeFileComponent::OnCatalogAssetChanged(const AZ::Data::AssetId& assetId) + { + // Reload any modified "_dependencies.xml" files + AZ::IO::Path assetPath; + auto GetAssetPath = [&assetId, &assetPath](AZ::Data::AssetCatalogRequests* assetCatalogRequests) + { + assetPath = assetCatalogRequests->GetAssetPathById(assetId); + }; + + AZ::Data::AssetCatalogRequestBus::Broadcast(AZStd::move(GetAssetPath)); + constexpr const char* dependencyXmlPattern = "_dependencies.xml"; + if (assetPath.Native().ends_with(dependencyXmlPattern)) + { + AZ_VerifyError("ExcludeFileComponent", m_excludeFileQueryManager.get()->LoadEngineDependencies(assetPath.Native()), + "Failed to add assets referenced from %s to the blocked list", assetPath.c_str()); } } + + void ExcludeFileComponent::OnCatalogAssetAdded(const AZ::Data::AssetId& assetId) + { + OnCatalogAssetChanged(assetId); + } } } diff --git a/Code/Framework/AzFramework/AzFramework/FileTag/FileTagComponent.h b/Code/Framework/AzFramework/AzFramework/FileTag/FileTagComponent.h index d53e4e7a89..1bd0f46aa0 100644 --- a/Code/Framework/AzFramework/AzFramework/FileTag/FileTagComponent.h +++ b/Code/Framework/AzFramework/AzFramework/FileTag/FileTagComponent.h @@ -65,6 +65,8 @@ namespace AzFramework void Deactivate() override; void OnCatalogLoaded(const char* catalogFile) override; + void OnCatalogAssetChanged(const AZ::Data::AssetId& assetId) override; + void OnCatalogAssetAdded(const AZ::Data::AssetId& assetId) override; static void Reflect(AZ::ReflectContext* context); diff --git a/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableEntitiesInterface.h b/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableEntitiesInterface.h index dc9c7b4538..66197ae8fc 100644 --- a/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableEntitiesInterface.h +++ b/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableEntitiesInterface.h @@ -10,6 +10,7 @@ #include #include +#include #include #include #include @@ -164,6 +165,8 @@ namespace AzFramework public: friend class SpawnableEntitiesDefinition; + AZ_CLASS_ALLOCATOR(AzFramework::EntitySpawnTicket, AZ::SystemAllocator, 0); + using Id = uint32_t; EntitySpawnTicket() = default; diff --git a/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableEntitiesManager.cpp b/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableEntitiesManager.cpp index 37570caec7..3406057fca 100644 --- a/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableEntitiesManager.cpp +++ b/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableEntitiesManager.cpp @@ -499,12 +499,8 @@ namespace AzFramework for (auto it = newEntitiesBegin; it != newEntitiesEnd; ++it) { AZ::Entity* clone = (*it); - // The entity component framework doesn't handle entities without TransformComponent safely. - if (!clone->GetComponents().empty()) - { - clone->SetSpawnTicketId(request.m_ticketId); - GameEntityContextRequestBus::Broadcast(&GameEntityContextRequestBus::Events::AddGameEntity, *it); - } + clone->SetSpawnTicketId(request.m_ticketId); + GameEntityContextRequestBus::Broadcast(&GameEntityContextRequestBus::Events::AddGameEntity, clone); } // Let other systems know about newly spawned entities for any post-processing after adding to the scene/game context. @@ -636,12 +632,8 @@ namespace AzFramework for (auto it = ticket.m_spawnedEntities.begin() + spawnedEntitiesInitialCount; it != ticket.m_spawnedEntities.end(); ++it) { AZ::Entity* clone = (*it); - // The entity component framework doesn't handle entities without TransformComponent safely. - if (!clone->GetComponents().empty()) - { - clone->SetSpawnTicketId(request.m_ticketId); - GameEntityContextRequestBus::Broadcast(&GameEntityContextRequestBus::Events::AddGameEntity, *it); - } + clone->SetSpawnTicketId(request.m_ticketId); + GameEntityContextRequestBus::Broadcast(&GameEntityContextRequestBus::Events::AddGameEntity, *it); } if (request.m_completionCallback) @@ -668,7 +660,7 @@ namespace AzFramework { if (entity != nullptr) { - // Setting it to 0 is needed to avoid the infite loop between GameEntityContext and SpawnableEntitiesManager. + // Setting it to 0 is needed to avoid the infinite loop between GameEntityContext and SpawnableEntitiesManager. entity->SetSpawnTicketId(0); GameEntityContextRequestBus::Broadcast( &GameEntityContextRequestBus::Events::DestroyGameEntity, entity->GetId()); @@ -702,7 +694,7 @@ namespace AzFramework { if (*entityIterator != nullptr && (*entityIterator)->GetId() == request.m_entityId) { - // Setting it to 0 is needed to avoid the infite loop between GameEntityContext and SpawnableEntitiesManager. + // Setting it to 0 is needed to avoid the infinite loop between GameEntityContext and SpawnableEntitiesManager. (*entityIterator)->SetSpawnTicketId(0); GameEntityContextRequestBus::Broadcast( &GameEntityContextRequestBus::Events::DestroyGameEntity, (*entityIterator)->GetId()); @@ -949,11 +941,6 @@ namespace AzFramework GameEntityContextRequestBus::Broadcast( &GameEntityContextRequestBus::Events::DestroyGameEntity, entity->GetId()); } - else - { - // Entities without components wouldn't have been send to the GameEntityContext. - delete entity; - } } delete request.m_ticket; diff --git a/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableSystemComponent.cpp b/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableSystemComponent.cpp index 6ca2f3a53a..4ba9c45a98 100644 --- a/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableSystemComponent.cpp +++ b/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableSystemComponent.cpp @@ -8,6 +8,7 @@ #include #include +#include #include #include #include @@ -61,15 +62,6 @@ namespace AzFramework m_entitiesManager.ProcessQueue(SpawnableEntitiesManager::CommandQueuePriority::High); } - void SpawnableSystemComponent::OnCatalogLoaded([[maybe_unused]] const char* catalogFile) - { - if (!m_catalogAvailable) - { - m_catalogAvailable = true; - LoadRootSpawnableFromSettingsRegistry(); - } - } - uint64_t SpawnableSystemComponent::AssignRootSpawnable(AZ::Data::Asset rootSpawnable) { uint32_t generation = 0; @@ -157,20 +149,29 @@ namespace AzFramework // Register with AssetDatabase AZ_Assert(AZ::Data::AssetManager::IsReady(), "Spawnables can't be registered because the Asset Manager is not ready yet."); AZ::Data::AssetManager::Instance().RegisterHandler(&m_assetHandler, AZ::AzTypeInfo::Uuid()); - + // Register with AssetCatalog AZ::Data::AssetCatalogRequestBus::Broadcast( &AZ::Data::AssetCatalogRequestBus::Events::EnableCatalogForAsset, AZ::AzTypeInfo::Uuid()); AZ::Data::AssetCatalogRequestBus::Broadcast( &AZ::Data::AssetCatalogRequestBus::Events::AddExtension, Spawnable::FileExtension); - AssetCatalogEventBus::Handler::BusConnect(); + // Register for the CriticalAssetsCompiled lifecycle event to trigger the loading of the root spawnable + auto settingsRegistry = AZ::SettingsRegistry::Get(); + AZ_Assert(settingsRegistry, "Unable to change root spawnable callback because Settings Registry is not available."); + + auto LifecycleCallback = [this](AZStd::string_view, AZ::SettingsRegistryInterface::Type) + { + LoadRootSpawnableFromSettingsRegistry(); + }; + AZ::ComponentApplicationLifecycle::RegisterHandler(*settingsRegistry, m_criticalAssetsHandler, + AZStd::move(LifecycleCallback), "CriticalAssetsCompiled"); + + RootSpawnableNotificationBus::Handler::BusConnect(); AZ::TickBus::Handler::BusConnect(); - auto registry = AZ::SettingsRegistry::Get(); - AZ_Assert(registry, "Unable to change root spawnable callback because Settings Registry is not available."); - m_registryChangeHandler = registry->RegisterNotifier([this](AZStd::string_view path, AZ::SettingsRegistryInterface::Type /*type*/) + m_registryChangeHandler = settingsRegistry->RegisterNotifier([this](AZStd::string_view path, AZ::SettingsRegistryInterface::Type /*type*/) { if (path.starts_with(RootSpawnableRegistryKey)) { @@ -187,13 +188,14 @@ namespace AzFramework AZ::TickBus::Handler::BusDisconnect(); RootSpawnableNotificationBus::Handler::BusDisconnect(); - AssetCatalogEventBus::Handler::BusDisconnect(); + // Unregister Lifecycle event handler + m_criticalAssetsHandler = {}; - if (m_catalogAvailable) + if (m_rootSpawnableId.IsValid()) { ReleaseRootSpawnable(); - // The SpawnalbleSystemComponent needs to guarantee there's no more processing left to do by the + // The SpawnableSystemComponent needs to guarantee there's no more processing left to do by the // entity manager before it can safely destroy it on shutdown, but also to make sure that are no // more calls to the callback registered to the root spawnable as that accesses this component. m_rootSpawnableContainer.Clear(); @@ -210,8 +212,6 @@ namespace AzFramework void SpawnableSystemComponent::LoadRootSpawnableFromSettingsRegistry() { - AZ_Assert(m_catalogAvailable, "Attempting to load root spawnable while the catalog is not available yet."); - auto registry = AZ::SettingsRegistry::Get(); AZ_Assert(registry, "Unable to check for root spawnable because the Settings Registry is not available."); diff --git a/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableSystemComponent.h b/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableSystemComponent.h index ecd2a9b728..712cd1529d 100644 --- a/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableSystemComponent.h +++ b/Code/Framework/AzFramework/AzFramework/Spawnable/SpawnableSystemComponent.h @@ -12,7 +12,6 @@ #include #include #include -#include #include #include #include @@ -25,7 +24,6 @@ namespace AzFramework : public AZ::Component , public AZ::TickBus::Handler , public AZ::SystemTickBus::Handler - , public AssetCatalogEventBus::Handler , public RootSpawnableInterface::Registrar , public RootSpawnableNotificationBus::Handler { @@ -63,12 +61,6 @@ namespace AzFramework void OnSystemTick() override; - // - // AssetCatalogEventBus - // - - void OnCatalogLoaded(const char* catalogFile) override; - // // RootSpawnableInterface // @@ -97,6 +89,6 @@ namespace AzFramework AZ::SettingsRegistryInterface::NotifyEventHandler m_registryChangeHandler; AZ::Data::AssetId m_rootSpawnableId; - bool m_catalogAvailable{ false }; + AZ::SettingsRegistryInterface::NotifyEventHandler m_criticalAssetsHandler; }; } // namespace AzFramework diff --git a/Code/Framework/AzFramework/AzFramework/Terrain/TerrainDataRequestBus.h b/Code/Framework/AzFramework/AzFramework/Terrain/TerrainDataRequestBus.h index 2572a07494..0d16bf3460 100644 --- a/Code/Framework/AzFramework/AzFramework/Terrain/TerrainDataRequestBus.h +++ b/Code/Framework/AzFramework/AzFramework/Terrain/TerrainDataRequestBus.h @@ -11,12 +11,15 @@ #include #include #include +#include #include namespace AzFramework { namespace Terrain { + typedef AZStd::function SurfacePointRegionFillCallback; + typedef AZStd::function SurfacePointListFillCallback; //! Shared interface for terrain system implementations class TerrainDataRequests @@ -131,6 +134,53 @@ namespace AzFramework Sampler sampleFilter = Sampler::DEFAULT, bool* terrainExistsPtr = nullptr) const = 0; + //! Given a list of XY coordinates, call the provided callback function with surface data corresponding to each + //! XY coordinate in the list. + virtual void ProcessHeightsFromList(const AZStd::span& inPositions, + SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessNormalsFromList(const AZStd::span& inPositions, + SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessSurfaceWeightsFromList(const AZStd::span& inPositions, + SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessSurfacePointsFromList(const AZStd::span& inPositions, + SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessHeightsFromListOfVector2(const AZStd::span& inPositions, + SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessNormalsFromListOfVector2(const AZStd::span& inPositions, + SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessSurfaceWeightsFromListOfVector2(const AZStd::span& inPositions, + SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessSurfacePointsFromListOfVector2(const AZStd::span& inPositions, + SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + + //! Given a region(aabb) and a step size, call the provided callback function with surface data corresponding to the + //! coordinates in the region. + virtual void ProcessHeightsFromRegion(const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessNormalsFromRegion(const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessSurfaceWeightsFromRegion(const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + virtual void ProcessSurfacePointsFromRegion(const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const = 0; + + private: // Private variations of the GetSurfacePoint API exposed to BehaviorContext that returns a value instead of // using an "out" parameter. The "out" parameter is useful for reusing memory allocated in SurfacePoint when diff --git a/Code/Framework/AzFramework/AzFramework/azframework_files.cmake b/Code/Framework/AzFramework/AzFramework/azframework_files.cmake index aac7bd8f14..73608d6a85 100644 --- a/Code/Framework/AzFramework/AzFramework/azframework_files.cmake +++ b/Code/Framework/AzFramework/AzFramework/azframework_files.cmake @@ -270,8 +270,6 @@ set(FILES Physics/WindBus.h Process/ProcessCommunicator.cpp Process/ProcessCommunicator.h - Process/ProcessWatcher.cpp - Process/ProcessWatcher.h Process/ProcessCommon_fwd.h Process/ProcessCommunicator.h Process/ProcessWatcher.cpp diff --git a/Code/Framework/AzFramework/CMakeLists.txt b/Code/Framework/AzFramework/CMakeLists.txt index 9f30d23a19..bd7af2724e 100644 --- a/Code/Framework/AzFramework/CMakeLists.txt +++ b/Code/Framework/AzFramework/CMakeLists.txt @@ -8,8 +8,8 @@ include(AzFramework/feature_options.cmake) -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) +set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) ly_add_target( NAME AzFramework STATIC @@ -44,7 +44,7 @@ ly_add_source_properties( if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) - ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Tests/Platform/${PAL_PLATFORM_NAME}) + o3de_pal_dir(test_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Tests/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME AzFrameworkTestShared STATIC @@ -86,11 +86,11 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) NAMESPACE AZ FILES_CMAKE Tests/frameworktests_files.cmake - ${pal_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake + ${test_pal_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake INCLUDE_DIRECTORIES PRIVATE Tests - ${pal_dir} + ${test_pal_dir} BUILD_DEPENDENCIES PRIVATE AZ::AzFramework @@ -104,7 +104,7 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) NAME AZ::AzFramework.Tests ) - include(${pal_dir}/platform_specific_test_targets.cmake) + include(${test_pal_dir}/platform_specific_test_targets.cmake) endif() diff --git a/Code/Framework/AzFramework/Platform/Common/Default/AzFramework/Process/ProcessWatcher_Default.cpp b/Code/Framework/AzFramework/Platform/Common/Default/AzFramework/Process/ProcessWatcher_Default.cpp index f87c51bdc5..a30ab72420 100644 --- a/Code/Framework/AzFramework/Platform/Common/Default/AzFramework/Process/ProcessWatcher_Default.cpp +++ b/Code/Framework/AzFramework/Platform/Common/Default/AzFramework/Process/ProcessWatcher_Default.cpp @@ -83,4 +83,9 @@ namespace AzFramework { } + + AZStd::string ProcessLauncher::ProcessLaunchInfo::GetCommandLineParametersAsString() const + { + return AZStd::string{}; + } } //namespace AzFramework diff --git a/Code/Framework/AzFramework/Tests/Mocks/Terrain/MockTerrainDataRequestBus.h b/Code/Framework/AzFramework/Tests/Mocks/Terrain/MockTerrainDataRequestBus.h index dbce11d639..f3a6cc07b3 100644 --- a/Code/Framework/AzFramework/Tests/Mocks/Terrain/MockTerrainDataRequestBus.h +++ b/Code/Framework/AzFramework/Tests/Mocks/Terrain/MockTerrainDataRequestBus.h @@ -76,5 +76,29 @@ namespace UnitTest GetSurfacePointFromVector2, void(const AZ::Vector2&, AzFramework::SurfaceData::SurfacePoint&, Sampler, bool*)); MOCK_CONST_METHOD5( GetSurfacePointFromFloats, void(float, float, AzFramework::SurfaceData::SurfacePoint&, Sampler, bool*)); + MOCK_CONST_METHOD3( + ProcessHeightsFromList, void(const AZStd::span&, AzFramework::Terrain::SurfacePointListFillCallback, Sampler)); + MOCK_CONST_METHOD3( + ProcessNormalsFromList, void(const AZStd::span&, AzFramework::Terrain::SurfacePointListFillCallback, Sampler)); + MOCK_CONST_METHOD3( + ProcessSurfaceWeightsFromList, void(const AZStd::span&, AzFramework::Terrain::SurfacePointListFillCallback, Sampler)); + MOCK_CONST_METHOD3( + ProcessSurfacePointsFromList, void(const AZStd::span&, AzFramework::Terrain::SurfacePointListFillCallback, Sampler)); + MOCK_CONST_METHOD3( + ProcessHeightsFromListOfVector2, void(const AZStd::span&, AzFramework::Terrain::SurfacePointListFillCallback, Sampler)); + MOCK_CONST_METHOD3( + ProcessNormalsFromListOfVector2, void(const AZStd::span&, AzFramework::Terrain::SurfacePointListFillCallback, Sampler)); + MOCK_CONST_METHOD3( + ProcessSurfaceWeightsFromListOfVector2, void(const AZStd::span&, AzFramework::Terrain::SurfacePointListFillCallback, Sampler)); + MOCK_CONST_METHOD3( + ProcessSurfacePointsFromListOfVector2, void(const AZStd::span&, AzFramework::Terrain::SurfacePointListFillCallback, Sampler)); + MOCK_CONST_METHOD4( + ProcessHeightsFromRegion, void(const AZ::Aabb&, const AZ::Vector2&, AzFramework::Terrain::SurfacePointRegionFillCallback, Sampler)); + MOCK_CONST_METHOD4( + ProcessNormalsFromRegion, void(const AZ::Aabb&, const AZ::Vector2&, AzFramework::Terrain::SurfacePointRegionFillCallback, Sampler)); + MOCK_CONST_METHOD4( + ProcessSurfaceWeightsFromRegion, void(const AZ::Aabb&, const AZ::Vector2&, AzFramework::Terrain::SurfacePointRegionFillCallback, Sampler)); + MOCK_CONST_METHOD4( + ProcessSurfacePointsFromRegion, void(const AZ::Aabb&, const AZ::Vector2&, AzFramework::Terrain::SurfacePointRegionFillCallback, Sampler)); }; } // namespace UnitTest diff --git a/Code/Framework/AzFramework/Tests/Spawnable/SpawnableEntitiesManagerTests.cpp b/Code/Framework/AzFramework/Tests/Spawnable/SpawnableEntitiesManagerTests.cpp index 0dc00f81dd..50365ff2ff 100644 --- a/Code/Framework/AzFramework/Tests/Spawnable/SpawnableEntitiesManagerTests.cpp +++ b/Code/Framework/AzFramework/Tests/Spawnable/SpawnableEntitiesManagerTests.cpp @@ -77,6 +77,12 @@ namespace UnitTest public: AZ_COMPONENT(TargetSpawnableComponent, "{B4041561-63A7-4E1E-80F1-78C08D497960}"); + TargetSpawnableComponent() = default; + explicit TargetSpawnableComponent(AZ::EntityId parent) + : m_parent(parent) + { + } + void Activate() override {} void Deactivate() override {} @@ -84,14 +90,19 @@ namespace UnitTest { if (auto* serializeContext = azrtti_cast(reflection)) { - serializeContext->Class(); + serializeContext->Class() + ->Field("Parent", &TargetSpawnableComponent::m_parent); } } + + AZ::EntityId m_parent; }; class SpawnableEntitiesManagerTest : public AllocatorsFixture { public: + constexpr static AZ::u64 EntityIdStartId = 40; + void SetUp() override { AllocatorsFixture::SetUp(); @@ -111,7 +122,7 @@ namespace UnitTest m_spawnable = aznew AzFramework::Spawnable( AZ::Data::AssetId::CreateString("{EB2E8A2B-F253-4A90-BBF4-55F2EED786B8}:0"), AZ::Data::AssetData::AssetStatus::Ready); m_spawnableAsset = new AZ::Data::Asset(m_spawnable, AZ::Data::AssetLoadBehavior::Default); - m_ticket = new AzFramework::EntitySpawnTicket(*m_spawnableAsset); + m_ticket = aznew AzFramework::EntitySpawnTicket(*m_spawnableAsset); auto managerInterface = AzFramework::SpawnableEntitiesInterface::Get(); m_manager = azrtti_cast(managerInterface); @@ -147,22 +158,43 @@ namespace UnitTest { auto entry = AZStd::make_unique(); entry->AddComponent(aznew SourceSpawnableComponent()); + entry->SetId(AZ::EntityId(EntityIdStartId + i)); entities.push_back(AZStd::move(entry)); } } - AZ::Data::Asset CreateTargetSpawnable(size_t numElements) + AZ::Data::Asset CreateTargetSpawnable(size_t numElements, bool requiresMatchingEntityIds) { auto target = aznew AzFramework::Spawnable( AZ::Data::AssetId(AZ::Uuid("{716CD8C3-0BA8-4F32-B579-0EC7C967796F}")), AZ::Data::AssetData::AssetStatus::Ready); AzFramework::Spawnable::EntityList& entities = target->GetEntities(); entities.reserve(numElements); - for (size_t i = 0; i < numElements; ++i) + if (requiresMatchingEntityIds) { - auto entry = AZStd::make_unique(); - entry->AddComponent(aznew TargetSpawnableComponent()); - entities.push_back(AZStd::move(entry)); + for (size_t i = 0; i < numElements; ++i) + { + auto entry = AZStd::make_unique(); + if (i != 0) + { + entry->AddComponent(aznew TargetSpawnableComponent(AZ::EntityId(EntityIdStartId + i - 1))); + } + else + { + entry->AddComponent(aznew TargetSpawnableComponent()); + } + entry->SetId(AZ::EntityId(EntityIdStartId + i)); + entities.push_back(AZStd::move(entry)); + } + } + else + { + for (size_t i = 0; i < numElements; ++i) + { + auto entry = AZStd::make_unique(); + entry->AddComponent(aznew TargetSpawnableComponent()); + entities.push_back(AZStd::move(entry)); + } } return AZ::Data::Asset(target, AZ::Data::AssetLoadBehavior::NoLoad); @@ -212,6 +244,38 @@ namespace UnitTest return true; } + static bool DoParentEntityIdsMatch(AzFramework::SpawnableConstEntityContainerView entities) + { + if (entities.empty()) + { + return false; + } + + const AZ::Entity* previous = nullptr; + for (const AZ::Entity* entity : entities) + { + if (entity) + { + if (previous) + { + if (TargetSpawnableComponent* link = entity->FindComponent(); link != nullptr) + { + if (link->m_parent != previous->GetId()) + { + return false; + } + } + previous = entity; + } + } + else + { + return false; + } + } + return true; + } + static bool IsEveryOtherEntityAReplacement(AzFramework::SpawnableConstEntityContainerView entities) { bool onAlternative = true; @@ -516,7 +580,7 @@ namespace UnitTest // Make sure we start with a fresh ticket each time, or else each iteration through this loop would continue to build up // more and more entities. delete m_ticket; - m_ticket = new AzFramework::EntitySpawnTicket(*m_spawnableAsset); + m_ticket = aznew AzFramework::EntitySpawnTicket(*m_spawnableAsset); constexpr size_t NumEntities = 4; FillSpawnable(NumEntities); @@ -599,7 +663,8 @@ namespace UnitTest using namespace AzFramework; static constexpr size_t NumEntities = 4; FillSpawnable(NumEntities); - AZ::Data::Asset target = CreateTargetSpawnable(4); + constexpr bool requiresMatchingEntityIds = true; + AZ::Data::Asset target = CreateTargetSpawnable(4, requiresMatchingEntityIds); InsertEntityAliases<4>( { 0, 1, 2, 3 }, { 0, 1, 2, 3 }, { Spawnable::EntityAliasType::Replace, Spawnable::EntityAliasType::Replace, Spawnable::EntityAliasType::Replace, @@ -608,11 +673,13 @@ namespace UnitTest size_t spawnedEntitiesCount = 0; bool allReplaced = false; - auto callback = [&spawnedEntitiesCount, &allReplaced]( + bool allEntityIdsPatched = false; + auto callback = [&spawnedEntitiesCount, &allReplaced, &allEntityIdsPatched]( AzFramework::EntitySpawnTicket::Id, AzFramework::SpawnableConstEntityContainerView entities) { spawnedEntitiesCount += entities.size(); allReplaced = AreAllEntitiesReplaced(entities); + allEntityIdsPatched = DoParentEntityIdsMatch(entities); }; AzFramework::SpawnAllEntitiesOptionalArgs optionalArgs; optionalArgs.m_completionCallback = AZStd::move(callback); @@ -621,6 +688,7 @@ namespace UnitTest EXPECT_EQ(4, spawnedEntitiesCount); EXPECT_TRUE(allReplaced); + EXPECT_TRUE(allEntityIdsPatched); } TEST_F(SpawnableEntitiesManagerTest, SpawnAllEntities_AllAliasesWithAdditional_SourceAndTargetComponentsMerged) @@ -628,7 +696,8 @@ namespace UnitTest using namespace AzFramework; static constexpr size_t NumEntities = 4; FillSpawnable(NumEntities); - AZ::Data::Asset target = CreateTargetSpawnable(4); + constexpr bool requiresMatchingEntityIds = false; + AZ::Data::Asset target = CreateTargetSpawnable(4, requiresMatchingEntityIds); InsertEntityAliases<4>( { 0, 1, 2, 3 }, { 0, 1, 2, 3 }, { Spawnable::EntityAliasType::Additional, Spawnable::EntityAliasType::Additional, Spawnable::EntityAliasType::Additional, @@ -637,11 +706,13 @@ namespace UnitTest size_t spawnedEntitiesCount = 0; bool allAdded = false; - auto callback = [&spawnedEntitiesCount, &allAdded]( + bool allEntityIdsPatched = false; + auto callback = [&spawnedEntitiesCount, &allAdded, &allEntityIdsPatched]( AzFramework::EntitySpawnTicket::Id, AzFramework::SpawnableConstEntityContainerView entities) { spawnedEntitiesCount += entities.size(); allAdded = IsEveryOtherEntityAReplacement(entities); + allEntityIdsPatched = DoParentEntityIdsMatch(entities); }; AzFramework::SpawnAllEntitiesOptionalArgs optionalArgs; optionalArgs.m_completionCallback = AZStd::move(callback); @@ -650,6 +721,7 @@ namespace UnitTest EXPECT_EQ(8, spawnedEntitiesCount); EXPECT_TRUE(allAdded); + EXPECT_TRUE(allEntityIdsPatched); } TEST_F(SpawnableEntitiesManagerTest, SpawnAllEntities_AllAliasesWithMerge_SourceAndTargetComponentsMerged) @@ -657,7 +729,8 @@ namespace UnitTest using namespace AzFramework; static constexpr size_t NumEntities = 4; FillSpawnable(NumEntities); - AZ::Data::Asset target = CreateTargetSpawnable(4); + constexpr bool requiresMatchingEntityIds = true; + AZ::Data::Asset target = CreateTargetSpawnable(4, requiresMatchingEntityIds); InsertEntityAliases<4>( { 0, 1, 2, 3 }, { 0, 1, 2, 3 }, { Spawnable::EntityAliasType::Merge, Spawnable::EntityAliasType::Merge, Spawnable::EntityAliasType::Merge, @@ -666,11 +739,13 @@ namespace UnitTest size_t spawnedEntitiesCount = 0; bool allMerged = false; - auto callback = [&spawnedEntitiesCount, &allMerged]( + bool allEntityIdsPatched = false; + auto callback = [&spawnedEntitiesCount, &allMerged, &allEntityIdsPatched]( AzFramework::EntitySpawnTicket::Id, AzFramework::SpawnableConstEntityContainerView entities) { spawnedEntitiesCount += entities.size(); allMerged = AreAllMerged(entities); + allEntityIdsPatched = DoParentEntityIdsMatch(entities); }; AzFramework::SpawnAllEntitiesOptionalArgs optionalArgs; optionalArgs.m_completionCallback = AZStd::move(callback); @@ -679,6 +754,7 @@ namespace UnitTest EXPECT_EQ(4, spawnedEntitiesCount); EXPECT_TRUE(allMerged); + EXPECT_TRUE(allEntityIdsPatched); } // @@ -1095,7 +1171,8 @@ namespace UnitTest using namespace AzFramework; static constexpr size_t NumEntities = 4; FillSpawnable(NumEntities); - AZ::Data::Asset target = CreateTargetSpawnable(4); + constexpr bool requiresMatchingEntityIds = true; + AZ::Data::Asset target = CreateTargetSpawnable(4, requiresMatchingEntityIds); InsertEntityAliases<4>( { 0, 1, 2, 3 }, { 0, 1, 2, 3 }, { Spawnable::EntityAliasType::Replace, Spawnable::EntityAliasType::Replace, Spawnable::EntityAliasType::Replace, @@ -1106,11 +1183,13 @@ namespace UnitTest size_t spawnedEntitiesCount = 0; bool allReplaced = false; - auto callback = [&spawnedEntitiesCount, &allReplaced]( + bool allEntityIdsPatched = false; + auto callback = [&spawnedEntitiesCount, &allReplaced, &allEntityIdsPatched]( AzFramework::EntitySpawnTicket::Id, AzFramework::SpawnableConstEntityContainerView entities) { spawnedEntitiesCount += entities.size(); allReplaced = AreAllEntitiesReplaced(entities); + allEntityIdsPatched = DoParentEntityIdsMatch(entities); }; AzFramework::SpawnEntitiesOptionalArgs optionalArgs; optionalArgs.m_completionCallback = AZStd::move(callback); @@ -1119,6 +1198,7 @@ namespace UnitTest EXPECT_EQ(4, spawnedEntitiesCount); EXPECT_TRUE(allReplaced); + EXPECT_TRUE(allEntityIdsPatched); } TEST_F(SpawnableEntitiesManagerTest, SpawnEntities_AllAliasesWithAdditional_SourceAndTargetComponentsMerged) @@ -1126,7 +1206,8 @@ namespace UnitTest using namespace AzFramework; static constexpr size_t NumEntities = 4; FillSpawnable(NumEntities); - AZ::Data::Asset target = CreateTargetSpawnable(4); + constexpr bool requiresMatchingEntityIds = false; + AZ::Data::Asset target = CreateTargetSpawnable(4, requiresMatchingEntityIds); InsertEntityAliases<4>( { 0, 1, 2, 3 }, { 0, 1, 2, 3 }, { Spawnable::EntityAliasType::Additional, Spawnable::EntityAliasType::Additional, Spawnable::EntityAliasType::Additional, @@ -1137,12 +1218,14 @@ namespace UnitTest size_t spawnedEntitiesCount = 0; bool allAdded = false; + bool allEntityIdsPatched = false; auto callback = - [&spawnedEntitiesCount, &allAdded]( + [&spawnedEntitiesCount, &allAdded, &allEntityIdsPatched]( AzFramework::EntitySpawnTicket::Id, AzFramework::SpawnableConstEntityContainerView entities) { spawnedEntitiesCount += entities.size(); allAdded = IsEveryOtherEntityAReplacement(entities); + allEntityIdsPatched = DoParentEntityIdsMatch(entities); }; AzFramework::SpawnEntitiesOptionalArgs optionalArgs; optionalArgs.m_completionCallback = AZStd::move(callback); @@ -1151,6 +1234,7 @@ namespace UnitTest EXPECT_EQ(8, spawnedEntitiesCount); EXPECT_TRUE(allAdded); + EXPECT_TRUE(allEntityIdsPatched); } TEST_F(SpawnableEntitiesManagerTest, SpawnEntities_AllAliasesWithMerge_SourceAndTargetComponentsMerged) @@ -1158,7 +1242,8 @@ namespace UnitTest using namespace AzFramework; static constexpr size_t NumEntities = 4; FillSpawnable(NumEntities); - AZ::Data::Asset target = CreateTargetSpawnable(4); + constexpr bool requiresMatchingEntityIds = true; + AZ::Data::Asset target = CreateTargetSpawnable(4, requiresMatchingEntityIds); InsertEntityAliases<4>( { 0, 1, 2, 3 }, { 0, 1, 2, 3 }, { Spawnable::EntityAliasType::Merge, Spawnable::EntityAliasType::Merge, Spawnable::EntityAliasType::Merge, @@ -1169,11 +1254,13 @@ namespace UnitTest size_t spawnedEntitiesCount = 0; bool allMerged = false; - auto callback = [&spawnedEntitiesCount, &allMerged]( + bool allEntityIdsPatched = false; + auto callback = [&spawnedEntitiesCount, &allMerged, &allEntityIdsPatched]( AzFramework::EntitySpawnTicket::Id, AzFramework::SpawnableConstEntityContainerView entities) { spawnedEntitiesCount += entities.size(); allMerged = AreAllMerged(entities); + allEntityIdsPatched = DoParentEntityIdsMatch(entities); }; AzFramework::SpawnEntitiesOptionalArgs optionalArgs; optionalArgs.m_completionCallback = AZStd::move(callback); @@ -1182,6 +1269,7 @@ namespace UnitTest EXPECT_EQ(4, spawnedEntitiesCount); EXPECT_TRUE(allMerged); + EXPECT_TRUE(allEntityIdsPatched); } // @@ -1302,6 +1390,36 @@ namespace UnitTest // ClaimEntities // + TEST_F(SpawnableEntitiesManagerTest, ClaimEntities_Call_AllEntitiesWereClaimedAndNotDeleted) + { + static constexpr size_t NumEntities = 4; + FillSpawnable(NumEntities); + + AZStd::vector claimedEntities; + auto callback = [&claimedEntities](AzFramework::EntitySpawnTicket::Id, AzFramework::SpawnableEntityContainerView container) + { + for (AZ::Entity* entity : container) + { + claimedEntities.push_back(entity); + } + }; + + { + AzFramework::EntitySpawnTicket ticket(*m_spawnableAsset); + m_manager->SpawnAllEntities(ticket); + m_manager->ClaimEntities(ticket, AZStd::move(callback)); + m_manager->ProcessQueue(AzFramework::SpawnableEntitiesManager::CommandQueuePriority::Regular); + } + + EXPECT_EQ(NumEntities, claimedEntities.size()); + + // If these calls fail it means that the ticket has still deleted the entities, so they weren't properly claimed. + for (AZ::Entity* entity : claimedEntities) + { + delete entity; + } + } + TEST_F(SpawnableEntitiesManagerTest, ClaimEntities_DeleteTicketBeforeCall_NoCrash) { auto callback = [](AzFramework::EntitySpawnTicket::Id, AzFramework::SpawnableEntityContainerView) {}; diff --git a/Code/Framework/AzNetworking/CMakeLists.txt b/Code/Framework/AzNetworking/CMakeLists.txt index a0a3871201..ba2eecd023 100644 --- a/Code/Framework/AzNetworking/CMakeLists.txt +++ b/Code/Framework/AzNetworking/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) +set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) ly_add_target( NAME AzNetworking STATIC diff --git a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/ElidingLabel.cpp b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/ElidingLabel.cpp index 8ef69c4b56..8daa183b80 100644 --- a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/ElidingLabel.cpp +++ b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/ElidingLabel.cpp @@ -12,6 +12,8 @@ #include #include #include +#include +#include namespace AzQtComponents { @@ -35,6 +37,7 @@ namespace AzQtComponents m_text = text; m_metricsLabel->setText(m_text); + m_elidedText.clear(); elide(); updateGeometry(); @@ -65,7 +68,62 @@ namespace AzQtComponents void ElidingLabel::elide() { ensurePolished(); - m_elidedText = fontMetrics().elidedText(m_text, m_elideMode, TextRect().width()); + + if (Qt::mightBeRichText(m_text)) + { + // If RichText tags are elided using fontMetrics.elidedText(), they will break. + // A TextDocument is used to produce elided text that takes this into account. + const QString ellipsis("..."); + const int maxLineWidth = TextRect().width(); + + QTextDocument doc; + doc.setHtml(m_text); + doc.setDefaultFont(font()); + doc.setDocumentMargin(0.0); + + // Turn off wrapping so the document uses a single line. + QTextOption option = doc.defaultTextOption(); + option.setWrapMode(QTextOption::WrapMode::NoWrap); + doc.setDefaultTextOption(option); + doc.adjustSize(); + + if (doc.size().width() <= maxLineWidth) + { + m_elidedText = m_text; + } + else + { + QTextCursor textCursor(&doc); + textCursor.movePosition(QTextCursor::End); + + int ellipsisWidth = 0; + + // At the moment only ElideRight and ElideNone are ever used. This will need expanding if other elision modes are used. + if (m_elideMode == Qt::ElideRight) + { + ellipsisWidth = fontMetrics().horizontalAdvance(ellipsis); + } + + // Move the cursor back until the text fits or the start of the text is reached. + while (doc.size().width() + ellipsisWidth > maxLineWidth && !textCursor.atStart()) + { + textCursor.deletePreviousChar(); + doc.adjustSize(); + } + + if (m_elideMode == Qt::ElideRight) + { + textCursor.insertText(ellipsis); + } + + m_elidedText = doc.toHtml(); + } + } + else + { + m_elidedText = fontMetrics().elidedText(m_text, m_elideMode, TextRect().width()); + } + QLabel::setText(m_elidedText); if (m_elidedText != m_text) diff --git a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/Slider.cpp b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/Slider.cpp index 14ac2010bc..f50b9c36ec 100644 --- a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/Slider.cpp +++ b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/Slider.cpp @@ -870,8 +870,7 @@ void SliderDouble::setCurveMidpoint(double midpoint) QString SliderDouble::hoverValueText(int sliderValue) const { - // maybe format this, max number of digits? - QString valueText = locale().toString(calculateRealSliderValue(sliderValue), 'f', m_decimals); + QString valueText = toString(calculateRealSliderValue(sliderValue), m_decimals, locale(), false, true); return QStringLiteral("%1").arg(valueText); } diff --git a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SliderCombo.cpp b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SliderCombo.cpp index 7b818459d6..9d289e5d44 100644 --- a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SliderCombo.cpp +++ b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SliderCombo.cpp @@ -14,6 +14,7 @@ #include #include +#include namespace AzQtComponents { @@ -243,7 +244,7 @@ SliderDoubleCombo::SliderDoubleCombo(QWidget* parent) InitialiseSliderCombo(this, layout, m_spinbox, m_slider); - connect(m_slider, &SliderDouble::valueChanged, this, &SliderDoubleCombo::setValue); + connect(m_slider, &SliderDouble::valueChanged, this, &SliderDoubleCombo::setValueSlider); connect(m_spinbox, QOverload::of(&DoubleSpinBox::valueChanged), this, &SliderDoubleCombo::setValue); connect(m_slider, &SliderDouble::sliderReleased, this, &SliderDoubleCombo::editingFinished); connect(m_spinbox, &DoubleSpinBox::editingFinished, this, &SliderDoubleCombo::editingFinished); @@ -254,20 +255,43 @@ SliderDoubleCombo::~SliderDoubleCombo() { } -void SliderDoubleCombo::setValue(double value) +bool m_fromSlider{ false }; + +void SliderDoubleCombo::setValueSlider(double value) { const bool doEmit = m_value != value; m_value = value; - updateSpinBox(); updateSlider(); if (doEmit) { + // We don't want to update the slider from setValue as this + // causes rounding errors in the tooltip hint. + m_fromSlider = true; + QTimer::singleShot( 10, []() { m_fromSlider = false; }); + Q_EMIT valueChanged(); } } +void SliderDoubleCombo::setValue(double value) +{ + const bool doEmit = m_value != value; + m_value = value; + + updateSpinBox(); + if (!m_fromSlider) + { + updateSlider(); + + if (doEmit) + { + Q_EMIT valueChanged(); + } + } +} + SliderDouble* SliderDoubleCombo::slider() const { return m_slider; diff --git a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SliderCombo.h b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SliderCombo.h index 2646162af4..be6c86b520 100644 --- a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SliderCombo.h +++ b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SliderCombo.h @@ -151,6 +151,8 @@ namespace AzQtComponents //! Sets the current value. void setValue(double value); + //! Sets the current value. + void setValueSlider(double value); //! Return the current value. Q_REQUIRED_RESULT double value() const; diff --git a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SpinBox.cpp b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SpinBox.cpp index 8ace8d0f40..e9f484ee11 100644 --- a/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SpinBox.cpp +++ b/Code/Framework/AzQtComponents/AzQtComponents/Components/Widgets/SpinBox.cpp @@ -1460,7 +1460,7 @@ QString DoubleSpinBox::stringValue(double value, bool truncated) const numDecimals = 0; } - return toString(value, numDecimals, locale(), isGroupSeparatorShown()); + return toString(value, numDecimals, locale(), isGroupSeparatorShown(), true); } void DoubleSpinBox::updateToolTip(double value) diff --git a/Code/Framework/AzQtComponents/AzQtComponents/Tests/AzQtComponentTests.cpp b/Code/Framework/AzQtComponents/AzQtComponents/Tests/AzQtComponentTests.cpp index 3c911c8acc..d87b238250 100644 --- a/Code/Framework/AzQtComponents/AzQtComponents/Tests/AzQtComponentTests.cpp +++ b/Code/Framework/AzQtComponents/AzQtComponents/Tests/AzQtComponentTests.cpp @@ -9,6 +9,8 @@ #include #include #include +#include +#include // Environments subclass from AZ::Test::ITestEnvironment class AzQtComponentsTestEnvironment : public AZ::Test::ITestEnvironment @@ -34,3 +36,17 @@ protected: }; AZ_UNIT_TEST_HOOK(new AzQtComponentsTestEnvironment); + +TEST(AzQtComponents, ToStringReturnsTruncatedString) +{ + double testVal = 1.2399999; + QString result = AzQtComponents::toString(testVal, 3, QLocale(), false, false); + EXPECT_TRUE(result == "1.239"); +} + +TEST(AzQtComponents, ToStringReturnsRoundedString) +{ + double testVal = 1.2399999; + QString result = AzQtComponents::toString(testVal, 3, QLocale(), false, true); + EXPECT_TRUE(result == "1.24"); +} diff --git a/Code/Framework/AzQtComponents/AzQtComponents/Utilities/Conversions.cpp b/Code/Framework/AzQtComponents/AzQtComponents/Utilities/Conversions.cpp index bef41bb487..542bfaf7c8 100644 --- a/Code/Framework/AzQtComponents/AzQtComponents/Utilities/Conversions.cpp +++ b/Code/Framework/AzQtComponents/AzQtComponents/Utilities/Conversions.cpp @@ -39,15 +39,23 @@ namespace AzQtComponents return AZ::Color(static_cast(rgb.redF()), static_cast(rgb.greenF()), static_cast(rgb.blueF()), static_cast(rgb.alphaF())); } - QString toString(double value, int numDecimals, const QLocale& locale, bool showGroupSeparator) + QString toString(double value, int numDecimals, const QLocale& locale, bool showGroupSeparator, bool round) { const QChar decimalPoint = locale.decimalPoint(); const QChar zeroDigit = locale.zeroDigit(); const int numToStringDecimals = AZStd::max(numDecimals, 20); + QString retValue; - // We want to truncate, not round. toString will round, so we add extra decimal places to the formatting - // so we can remove the last values - QString retValue = locale.toString(value, 'f', (numDecimals > 0) ? numToStringDecimals : 0); + // If we want to truncate, not round, we add extra decimal places to the formatting + // so we can remove the last values otherwise we allow rounding + if (round) + { + retValue = locale.toString(value, 'f', (numDecimals > 0) ? numDecimals : 0); + } + else + { + retValue = locale.toString(value, 'f', (numDecimals > 0) ? numToStringDecimals : 0); + } // Handle special cases when we have decimals in our value if (numDecimals > 0) diff --git a/Code/Framework/AzQtComponents/AzQtComponents/Utilities/Conversions.h b/Code/Framework/AzQtComponents/AzQtComponents/Utilities/Conversions.h index 84e874fc5a..29988545f7 100644 --- a/Code/Framework/AzQtComponents/AzQtComponents/Utilities/Conversions.h +++ b/Code/Framework/AzQtComponents/AzQtComponents/Utilities/Conversions.h @@ -22,7 +22,7 @@ namespace AzQtComponents AZ_QT_COMPONENTS_API AZ::Color fromQColor(const QColor& color); - AZ_QT_COMPONENTS_API QString toString(double value, int numDecimals, const QLocale& locale, bool showGroupSeparator = false); + AZ_QT_COMPONENTS_API QString toString(double value, int numDecimals, const QLocale& locale, bool showGroupSeparator = false, bool round = false); // Maintained for backwards compile compatibility inline QColor ToQColor(const AZ::Color& color) diff --git a/Code/Framework/AzQtComponents/CMakeLists.txt b/Code/Framework/AzQtComponents/CMakeLists.txt index a24b68bcd7..76850e196b 100644 --- a/Code/Framework/AzQtComponents/CMakeLists.txt +++ b/Code/Framework/AzQtComponents/CMakeLists.txt @@ -10,7 +10,7 @@ if(NOT PAL_TRAIT_BUILD_HOST_TOOLS) return() endif() -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME AzQtComponents SHARED diff --git a/Code/Framework/AzTest/AzTest/Platform/Android/platform_android_files.cmake b/Code/Framework/AzTest/AzTest/Platform/Android/platform_android_files.cmake index e0f47c8fa6..83ae97fa20 100644 --- a/Code/Framework/AzTest/AzTest/Platform/Android/platform_android_files.cmake +++ b/Code/Framework/AzTest/AzTest/Platform/Android/platform_android_files.cmake @@ -8,6 +8,7 @@ set(FILES ../Common/UnixLike/AzTest/ColorizedOutput_UnixLike.cpp + ../Common/UnixLike/AzTest/Utils_UnixLike.cpp ScopedAutoTempDirectory_Android.cpp Platform_Android.cpp AzTest_Traits_Platform.h diff --git a/Code/Framework/AzTest/AzTest/Platform/Common/Unimplemented/AzTest/Utils_Unimplemented.cpp b/Code/Framework/AzTest/AzTest/Platform/Common/Unimplemented/AzTest/Utils_Unimplemented.cpp new file mode 100644 index 0000000000..0f91ea1020 --- /dev/null +++ b/Code/Framework/AzTest/AzTest/Platform/Common/Unimplemented/AzTest/Utils_Unimplemented.cpp @@ -0,0 +1,25 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include + +namespace AZ +{ + namespace Test + { + bool SetEnv([[maybe_unused]] const char* envname, [[maybe_unused]] const char* envvalue, [[maybe_unused]] bool overwrite) + { + return false; + } + + bool UnsetEnv([[maybe_unused]] const char* envname) + { + return false; + } + } // namespace Test +} // namespace AZ diff --git a/Code/Framework/AzTest/AzTest/Platform/Common/UnixLike/AzTest/Utils_UnixLike.cpp b/Code/Framework/AzTest/AzTest/Platform/Common/UnixLike/AzTest/Utils_UnixLike.cpp new file mode 100644 index 0000000000..8efdb5d082 --- /dev/null +++ b/Code/Framework/AzTest/AzTest/Platform/Common/UnixLike/AzTest/Utils_UnixLike.cpp @@ -0,0 +1,25 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include + +namespace AZ +{ + namespace Test + { + bool SetEnv(const char* envname, const char* envvalue, bool overwrite) + { + return setenv(envname, envvalue, overwrite) != -1; + } + + bool UnsetEnv(const char* envname) + { + return unsetenv(envname) != -1; + } + } +} diff --git a/Code/Framework/AzTest/AzTest/Platform/Common/WinAPI/AzTest/Utils_WinAPI.cpp b/Code/Framework/AzTest/AzTest/Platform/Common/WinAPI/AzTest/Utils_WinAPI.cpp new file mode 100644 index 0000000000..a06cbf7ffe --- /dev/null +++ b/Code/Framework/AzTest/AzTest/Platform/Common/WinAPI/AzTest/Utils_WinAPI.cpp @@ -0,0 +1,25 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include + +namespace AZ +{ + namespace Test + { + bool SetEnv(const char* envname, const char* envvalue, [[maybe_unused]] bool overwrite) + { + return _putenv_s(envname, envvalue); + } + + bool UnsetEnv(const char* envname) + { + return SetEnv(envname, "", 1); + } + } +} diff --git a/Code/Framework/AzTest/AzTest/Platform/Linux/platform_linux_files.cmake b/Code/Framework/AzTest/AzTest/Platform/Linux/platform_linux_files.cmake index 68ca9332c7..9c6692b409 100644 --- a/Code/Framework/AzTest/AzTest/Platform/Linux/platform_linux_files.cmake +++ b/Code/Framework/AzTest/AzTest/Platform/Linux/platform_linux_files.cmake @@ -9,6 +9,7 @@ set(FILES ../Common/UnixLike/AzTest/ColorizedOutput_UnixLike.cpp ../Common/UnixLike/AzTest/ScopedAutoTempDirectory_UnixLike.cpp + ../Common/UnixLike/AzTest/Utils_UnixLike.cpp Platform_Linux.cpp AzTest_Traits_Platform.h AzTest_Traits_Linux.h diff --git a/Code/Framework/AzTest/AzTest/Platform/Mac/AzTest_Traits_Mac.h b/Code/Framework/AzTest/AzTest/Platform/Mac/AzTest_Traits_Mac.h index 4915fb9cab..23ea87cd1c 100644 --- a/Code/Framework/AzTest/AzTest/Platform/Mac/AzTest_Traits_Mac.h +++ b/Code/Framework/AzTest/AzTest/Platform/Mac/AzTest_Traits_Mac.h @@ -16,9 +16,12 @@ #define AZ_TRAIT_DISABLE_ASSET_JOB_PARALLEL_TESTS true #define AZ_TRAIT_DISABLE_ASSET_MANAGER_FLOOD_TEST true #define AZ_TRAIT_DISABLE_ASSETCONTAINERDISABLETEST true +#define AZ_TRAIT_DISABLE_FAILED_DLL_TESTS true +#define AZ_TRAIT_DISABLE_FAILED_MODULE_TESTS true +#define AZ_TRAIT_DISABLE_FAILED_EMOTION_FX_TESTS true // Golden perline gradiant values for random seed 7878 for this platform -#define AZ_TRAIT_UNIT_TEST_PERLINE_GRADIANT_GOLDEN_VALUES_7878 0.5000f, 0.5456f, 0.5138f, 0.4801f, \ - 0.4174f, 0.4942f, 0.5493f, 0.5431f, \ - 0.4984f, 0.5204f, 0.5526f, 0.5840f, \ - 0.5251f, 0.5029f, 0.6153f, 0.5802f, +#define AZ_TRAIT_UNIT_TEST_PERLINE_GRADIANT_GOLDEN_VALUES_7878 0.5000f, 0.5276f, 0.5341f, 0.4801f, \ + 0.5220f, 0.5162f, 0.4828f, 0.5431f, \ + 0.4799f, 0.4486f, 0.5054f, 0.4129f, \ + 0.6023f, 0.5029f, 0.4529f, 0.4428f, diff --git a/Code/Framework/AzTest/AzTest/Platform/Mac/platform_mac_files.cmake b/Code/Framework/AzTest/AzTest/Platform/Mac/platform_mac_files.cmake index 3cbe35792c..cb641e2113 100644 --- a/Code/Framework/AzTest/AzTest/Platform/Mac/platform_mac_files.cmake +++ b/Code/Framework/AzTest/AzTest/Platform/Mac/platform_mac_files.cmake @@ -9,6 +9,7 @@ set(FILES ../Common/UnixLike/AzTest/ColorizedOutput_UnixLike.cpp ../Common/UnixLike/AzTest/ScopedAutoTempDirectory_UnixLike.cpp + ../Common/UnixLike/AzTest/Utils_UnixLike.cpp Platform_Mac.cpp AzTest_Traits_Platform.h AzTest_Traits_Mac.h diff --git a/Code/Framework/AzTest/AzTest/Platform/Windows/ScopedAutoTempDirectory_Windows.cpp b/Code/Framework/AzTest/AzTest/Platform/Windows/ScopedAutoTempDirectory_Windows.cpp index fcda5d351a..b5314eda14 100644 --- a/Code/Framework/AzTest/AzTest/Platform/Windows/ScopedAutoTempDirectory_Windows.cpp +++ b/Code/Framework/AzTest/AzTest/Platform/Windows/ScopedAutoTempDirectory_Windows.cpp @@ -8,57 +8,41 @@ #include +#include #include #include #include -#include +#include -namespace AZ +namespace AZ::Test { - namespace Test + ScopedAutoTempDirectory::ScopedAutoTempDirectory() { - ScopedAutoTempDirectory::ScopedAutoTempDirectory() - { - constexpr const DWORD bufferSize = static_cast(AZ::IO::MaxPathLength); + using UuidString = AZStd::fixed_string; + constexpr DWORD bufferSize = static_cast(AZ::IO::MaxPathLength); - char tempDir[bufferSize] = {0}; - GetTempPathA(bufferSize, tempDir); + wchar_t tempDirW[AZ::IO::MaxPathLength]{}; + GetTempPathW(bufferSize, tempDirW); - char workingTempPathBuffer[bufferSize] = {'\0'}; + AZ::IO::FixedMaxPath tempDirectoryRoot; + AZStd::to_string(tempDirectoryRoot.Native(), tempDirW); - int maxAttempts = 2000; // Prevent an infinite loop by setting an arbitrary maximum attempts at finding an available temp folder name - while (maxAttempts > 0) + constexpr int MaxAttempts = 255; + for (int i = 0; i < MaxAttempts; ++i) + { + AZ::IO::FixedMaxPath testPath = tempDirectoryRoot / + AZ::IO::FixedMaxPathString::format("UnitTest-%s", + AZ::Uuid::CreateRandom().ToString().c_str()); + // Try to create the temp directory if it doesn't exist + if (!AZ::IO::SystemFile::Exists(testPath.c_str()) && AZ::IO::SystemFile::CreateDir(testPath.c_str())) { - // Use the system's tick count to base the folder name - ULONGLONG currentTick = GetTickCount64(); - azsnprintf(workingTempPathBuffer, bufferSize, "%sUnitTest-%X", tempDir, aznumeric_cast(currentTick)); - - // Check if the requested directory name is available and re-generate if it already exists - bool exists = AZ::IO::SystemFile::Exists(workingTempPathBuffer); - if (exists) - { - Sleep(1); - maxAttempts--; - continue; - } + azstrncpy(AZStd::data(m_tempDirectory), AZStd::size(m_tempDirectory), + testPath.c_str(), testPath.Native().size()); break; } - - AZ_Error("AzTest", maxAttempts > 0, "Unable to determine a temp directory"); - - if (maxAttempts > 0) - { - // Create the temp directory and track it for deletion - bool tempDirectoryCreated = AZ::IO::SystemFile::CreateDir(workingTempPathBuffer); - if (tempDirectoryCreated) - { - azstrncpy(m_tempDirectory, AZ::IO::MaxPathLength, workingTempPathBuffer, AZ::IO::MaxPathLength); - } - else - { - AZ_Error("AzTest", false, "Unable to create temp directory %s", workingTempPathBuffer); - } - } } - } // Test -} // AZ + + AZ_Error("AzTest", m_tempDirectory[0] != '\0', "Unable to create temp path within directory %s after %d attempts", + tempDirectoryRoot.c_str(), MaxAttempts); + } +} // AZ::Test diff --git a/Code/Framework/AzTest/AzTest/Platform/Windows/platform_windows_files.cmake b/Code/Framework/AzTest/AzTest/Platform/Windows/platform_windows_files.cmake index 656b28a373..4730b383a2 100644 --- a/Code/Framework/AzTest/AzTest/Platform/Windows/platform_windows_files.cmake +++ b/Code/Framework/AzTest/AzTest/Platform/Windows/platform_windows_files.cmake @@ -8,6 +8,7 @@ set(FILES ../Common/WinAPI/AzTest/ColorizedOutput_WinAPI.cpp + ../Common/WinAPI/AzTest/Utils_WinAPI.cpp Platform_Windows.cpp ScopedAutoTempDirectory_Windows.cpp AzTest_Traits_Platform.h diff --git a/Code/Framework/AzTest/AzTest/Platform/iOS/platform_ios_files.cmake b/Code/Framework/AzTest/AzTest/Platform/iOS/platform_ios_files.cmake index 64bbc27bc1..81875f71e5 100644 --- a/Code/Framework/AzTest/AzTest/Platform/iOS/platform_ios_files.cmake +++ b/Code/Framework/AzTest/AzTest/Platform/iOS/platform_ios_files.cmake @@ -9,6 +9,7 @@ set(FILES ../Common/UnixLike/AzTest/ColorizedOutput_UnixLike.cpp ../Common/Unimplemented/AzTest/ScopedAutoTempDirectory_Unimplemented.cpp + ../Common/UnixLike/AzTest/Utils_UnixLike.cpp Platform_iOS.cpp AzTest_Traits_Platform.h AzTest_Traits_iOS.h diff --git a/Code/Framework/AzTest/AzTest/Utils.h b/Code/Framework/AzTest/AzTest/Utils.h index 2778e163b3..e3b45e97f2 100644 --- a/Code/Framework/AzTest/AzTest/Utils.h +++ b/Code/Framework/AzTest/AzTest/Utils.h @@ -55,6 +55,19 @@ namespace AZ // Returns the path to the engine's root by cdup from the current execution path until engine.txt is found AZStd::string GetEngineRootPath(); + //! Create or modify environment variable. + //! @param envname The environment variable name + //! @param envvalue The environment variable name + //! @param overwrite If name does exist in the environment, then its value is changed to value if overwrite is nonzero; + //! if overwrite is zero, then the value of name is not changed + //! @returns Return true if successful, otherwise false + bool SetEnv(const char* envname, const char* envvalue, bool overwrite); + + //! Remove environment variable. + //! @param envname The environment variable name + //! @returns Return true if successful, otherwise false + bool UnsetEnv(const char* envname); + //! Provides a scoped object that will create a temporary operating-system specific folder on creation, and delete it and //! its contents on destruction. This class is only available on host platforms (Windows, Mac, and Linux) class ScopedAutoTempDirectory diff --git a/Code/Framework/AzTest/CMakeLists.txt b/Code/Framework/AzTest/CMakeLists.txt index 95e444a1e9..2edc80f893 100644 --- a/Code/Framework/AzTest/CMakeLists.txt +++ b/Code/Framework/AzTest/CMakeLists.txt @@ -7,18 +7,18 @@ # if(NOT LY_MONOLITHIC_GAME) - ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/AzTest/Platform/${PAL_PLATFORM_NAME}) + o3de_pal_dir(pal_aztest_dir ${CMAKE_CURRENT_LIST_DIR}/AzTest/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME AzTest STATIC NAMESPACE AZ FILES_CMAKE AzTest/aztest_files.cmake - ${pal_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake + ${pal_aztest_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake INCLUDE_DIRECTORIES PUBLIC . - ${pal_dir} + ${pal_aztest_dir} BUILD_DEPENDENCIES PUBLIC 3rdParty::googletest::GMock @@ -26,6 +26,6 @@ if(NOT LY_MONOLITHIC_GAME) 3rdParty::GoogleBenchmark AZ::AzCore PLATFORM_INCLUDE_FILES - ${pal_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}.cmake + ${pal_aztest_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}.cmake ) endif() diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserFilterModel.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserFilterModel.cpp index c6772ea2d7..21229e5570 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserFilterModel.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserFilterModel.cpp @@ -68,6 +68,11 @@ namespace AzToolsFramework } } + QSharedPointer AssetBrowserFilterModel::GetStringFilter() const + { + return m_stringFilter; + } + bool AssetBrowserFilterModel::filterAcceptsRow(int source_row, const QModelIndex& source_parent) const { //get the source idx, if invalid early out diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserFilterModel.h b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserFilterModel.h index 5d3ad0e1b0..cafe694ad6 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserFilterModel.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserFilterModel.h @@ -48,7 +48,7 @@ namespace AzToolsFramework // AssetBrowserComponentNotificationBus ////////////////////////////////////////////////////////////////////////// void OnAssetBrowserComponentReady() override; - + QSharedPointer GetStringFilter() const; Q_SIGNALS: void filterChanged(); ////////////////////////////////////////////////////////////////////////// @@ -70,7 +70,7 @@ namespace AzToolsFramework //Asset source name match filter FilterConstType m_filter; AZ_PUSH_DISABLE_WARNING(4251, "-Wunknown-warning-option") // 4251: class '...' needs to have dll-interface to be used by clients of class '...' - QWeakPointer m_stringFilter; + QSharedPointer m_stringFilter; QWeakPointer m_assetTypeFilter; QCollator m_collator; // cache the collator as its somewhat expensive to constantly create and destroy one. AZ_POP_DISABLE_WARNING diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserModel.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserModel.cpp index f0e1520aab..fd05543097 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserModel.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserModel.cpp @@ -13,6 +13,7 @@ #include #include #include +#include #include AZ_PUSH_DISABLE_WARNING(4251, "-Wunknown-warning-option") // 'QRegularExpression::d': class 'QExplicitlySharedDataPointer' needs to have dll-interface to be used by clients of class 'QRegularExpression' @@ -268,6 +269,21 @@ namespace AzToolsFramework m_rootEntry = rootEntry; } + AssetBrowserFilterModel* AssetBrowserModel::GetFilterModel() + { + return m_filterModel; + } + + const AssetBrowserFilterModel* AssetBrowserModel::GetFilterModel() const + { + return m_filterModel; + } + + void AssetBrowser::AssetBrowserModel::SetFilterModel(AssetBrowserFilterModel* filterModel) + { + m_filterModel = filterModel; + } + QModelIndex AssetBrowserModel::parent(const QModelIndex& child) const { if (!child.isValid()) diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserModel.h b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserModel.h index c46b73417c..2905844a23 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserModel.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/AssetBrowserModel.h @@ -35,6 +35,7 @@ namespace AzToolsFramework class AssetBrowserEntry; class RootAssetBrowserEntry; class AssetEntryChangeset; + class AssetBrowserFilterModel; class AssetBrowserModel : public QAbstractItemModel @@ -75,7 +76,7 @@ namespace AzToolsFramework void EndAddEntry(AssetBrowserEntry* parent) override; void BeginRemoveEntry(AssetBrowserEntry* entry) override; void EndRemoveEntry() override; - + ////////////////////////////////////////////////////////////////////////// // TickBus ////////////////////////////////////////////////////////////////////////// @@ -84,10 +85,16 @@ namespace AzToolsFramework AZStd::shared_ptr GetRootEntry() const; void SetRootEntry(AZStd::shared_ptr rootEntry); + AssetBrowserFilterModel* GetFilterModel(); + const AssetBrowserFilterModel* GetFilterModel() const; + void SetFilterModel(AssetBrowserFilterModel* filterModel); + static void SourceIndexesToAssetIds(const QModelIndexList& indexes, AZStd::vector& assetIds); static void SourceIndexesToAssetDatabaseEntries(const QModelIndexList& indexes, AZStd::vector& entries); private: + //Non owning pointer + AssetBrowserFilterModel* m_filterModel = nullptr; AZStd::shared_ptr m_rootEntry; bool m_loaded; bool m_addingEntry; diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Search/Filter.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Search/Filter.cpp index d617638632..4ec26d4c3d 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Search/Filter.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Search/Filter.cpp @@ -229,6 +229,11 @@ namespace AzToolsFramework Q_EMIT updatedSignal(); } + QString StringFilter::GetFilterString() const + { + return m_filterString; + } + QString StringFilter::GetNameInternal() const { return m_filterString; diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Search/Filter.h b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Search/Filter.h index 94f47e0599..1d93d4d0cf 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Search/Filter.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Search/Filter.h @@ -106,6 +106,7 @@ namespace AzToolsFramework ~StringFilter() override = default; void SetFilterString(const QString& filterString); + QString GetFilterString() const; protected: QString GetNameInternal() const override; diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/AssetBrowserTableView.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/AssetBrowserTableView.cpp index feab9a9e5a..a913009da0 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/AssetBrowserTableView.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/AssetBrowserTableView.cpp @@ -66,6 +66,7 @@ namespace AzToolsFramework m_tableModel = qobject_cast(model); AZ_Assert(m_tableModel, "Expecting AssetBrowserTableModel"); m_sourceFilterModel = qobject_cast(m_tableModel->sourceModel()); + m_delegate->Init(); AzQtComponents::TableView::setModel(model); connect(m_tableModel, &AssetBrowserTableModel::layoutChanged, this, &AssetBrowserTableView::layoutChangedSlot); @@ -144,7 +145,10 @@ namespace AzToolsFramework { emit ClearStringFilter(); emit ClearTypeFilter(); - m_sourceFilterModel->FilterUpdatedSlotImmediate(); + if (m_sourceFilterModel) + { + m_sourceFilterModel->FilterUpdatedSlotImmediate(); + } } void AssetBrowserTableView::Update() diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/EntryDelegate.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/EntryDelegate.cpp index 8b58791e68..8e69d5f788 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/EntryDelegate.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/EntryDelegate.cpp @@ -9,12 +9,16 @@ #include #include #include +#include #include #include #include #include +#include #include +#include + AZ_PUSH_DISABLE_WARNING(4251 4800, "-Wunknown-warning-option") // 4251: class 'QScopedPointer' needs to have dll-interface to be used by clients of class 'QBrush' // 4800: 'uint': forcing value to bool 'true' or 'false' (performance warning) #include @@ -160,13 +164,20 @@ namespace AzToolsFramework LoadBranchPixMaps(); } + void SearchEntryDelegate::Init() + { + AssetBrowserModel* assetBrowserModel; + AssetBrowserComponentRequestBus::BroadcastResult(assetBrowserModel, &AssetBrowserComponentRequests::GetAssetBrowserModel); + AZ_Assert(assetBrowserModel, "Failed to get filebrowser model"); + m_assetBrowserFilerModel = assetBrowserModel->GetFilterModel(); + } + void SearchEntryDelegate::paint(QPainter* painter, const QStyleOptionViewItem& option, const QModelIndex& index) const { auto data = index.data(AssetBrowserModel::Roles::EntryRole); if (data.canConvert()) { bool isEnabled = (option.state & QStyle::State_Enabled) != 0; - bool isSelected = (option.state & QStyle::State_Selected) != 0; QStyle* style = option.widget ? option.widget->style() : QApplication::style(); @@ -265,13 +276,21 @@ namespace AzToolsFramework remainingRect.adjust(thumbX, 0, 0, 0); // bump it to the right by the size of the thumbnail remainingRect.adjust(EntrySpacingLeftPixels, 0, 0, 0); // bump it to the right by the spacing. } + QString displayString = index.column() == aznumeric_cast(AssetBrowserEntry::Column::Name) ? qvariant_cast(entry->data(aznumeric_cast(AssetBrowserEntry::Column::Name))) : qvariant_cast(entry->data(aznumeric_cast(AssetBrowserEntry::Column::Path))); - style->drawItemText( - painter, remainingRect, option.displayAlignment, actualPalette, isEnabled, displayString, - isSelected ? QPalette::HighlightedText : QPalette::Text); + QStyleOptionViewItem optionV4{ option }; + initStyleOption(&optionV4, index); + optionV4.state &= ~(QStyle::State_HasFocus | QStyle::State_Selected); + + if (m_assetBrowserFilerModel && m_assetBrowserFilerModel->GetStringFilter() + && !m_assetBrowserFilerModel->GetStringFilter()->GetFilterString().isEmpty()) + { + displayString = RichTextHighlighter::HighlightText(displayString, m_assetBrowserFilerModel->GetStringFilter()->GetFilterString()); + } + RichTextHighlighter::PaintHighlightedRichText(displayString, painter, optionV4, remainingRect); } } diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/EntryDelegate.h b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/EntryDelegate.h index ac68c19248..7c7d919f2d 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/EntryDelegate.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/AssetBrowser/Views/EntryDelegate.h @@ -70,7 +70,7 @@ namespace AzToolsFramework Q_OBJECT public: explicit SearchEntryDelegate(QWidget* parent = nullptr); - + void Init(); void paint(QPainter* painter, const QStyleOptionViewItem& option, const QModelIndex& index) const override; private: @@ -78,6 +78,7 @@ namespace AzToolsFramework void DrawBranchPixMap(EntryBranchType branchType, QPainter* painter, const QPoint& point, const QSize& size) const; private: + AssetBrowserFilterModel* m_assetBrowserFilerModel; QMap m_branchIcons; }; } // namespace AssetBrowser diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Editor/RichTextHighlighter.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Editor/RichTextHighlighter.cpp new file mode 100644 index 0000000000..8b28298c3d --- /dev/null +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Editor/RichTextHighlighter.cpp @@ -0,0 +1,55 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include "RichTextHighlighter.h" + +namespace AzToolsFramework +{ + + QString RichTextHighlighter::HighlightText(const QString& displayString, const QString& matchingSubstring) + { + QString highlightedString = displayString; + int highlightTextIndex = 0; + do + { + highlightTextIndex = highlightedString.lastIndexOf(matchingSubstring, highlightTextIndex - 1, Qt::CaseInsensitive); + if (highlightTextIndex >= 0) + { + const QString backgroundColor{ "#707070" }; + highlightedString.insert(static_cast(highlightTextIndex + matchingSubstring.length()), ""); + highlightedString.insert(highlightTextIndex, ""); + } + } while (highlightTextIndex > 0); + + return highlightedString; + } + + void RichTextHighlighter::PaintHighlightedRichText(const QString& highlightedString,QPainter* painter, QStyleOptionViewItem option, QRect availableRect) + { + painter->save(); + painter->setRenderHint(QPainter::Antialiasing); + + // Now we setup a Text Document so it can draw the rich text + QTextDocument textDoc; + textDoc.setDefaultFont(option.font); + if (option.state & QStyle::State_Enabled) + { + textDoc.setDefaultStyleSheet("body {color: white}"); + } + else + { + textDoc.setDefaultStyleSheet("body {color: #7C7C7C}"); + } + textDoc.setHtml("" + highlightedString + ""); + painter->translate(availableRect.topLeft()); + textDoc.setTextWidth(availableRect.width()); + textDoc.drawContents(painter, QRectF(0, 0, availableRect.width(), availableRect.height())); + + painter->restore(); + } +} // namespace AzToolsFramework diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Editor/RichTextHighlighter.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Editor/RichTextHighlighter.h new file mode 100644 index 0000000000..b5c1859497 --- /dev/null +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Editor/RichTextHighlighter.h @@ -0,0 +1,36 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include +#include +#include + +AZ_PUSH_DISABLE_WARNING(4251 4800,"-Wunknown-warning-option") // 4251: class 'QScopedPointer' needs to have dll-interface to be used + // by clients of class 'QBrush' 4800: 'uint': forcing value to bool 'true' or 'false' (performance warning) +#include +AZ_POP_DISABLE_WARNING + +namespace AzToolsFramework +{ + //! @class RichTextHighlighter + //! @brief Highlights a given string given a matching substring. + class RichTextHighlighter + { + public: + AZ_CLASS_ALLOCATOR(RichTextHighlighter, AZ::SystemAllocator, 0); + RichTextHighlighter() = delete; + + static QString HighlightText(const QString& displayString, const QString& matchingSubstring); + static void PaintHighlightedRichText(const QString& highlightedString,QPainter* painter, QStyleOptionViewItem option, QRect availableRect); + + }; +} // namespace AzToolsFramework diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.cpp index 90657132ca..470ca8b9ea 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/EditorEntityContextComponent.cpp @@ -226,7 +226,15 @@ namespace AzToolsFramework AZ::EntityId EditorEntityContextComponent::CreateNewEditorEntity(const char* name) { AZ::Entity* entity = CreateEntity(name); - FinalizeEditorEntity(entity); + AZ_Assert(entity != nullptr, "Entity with name %s couldn't be created.", name); + if (m_isLegacySliceService) + { + FinalizeEditorEntity(entity); + } + else + { + EditorEntityContextNotificationBus::Broadcast(&EditorEntityContextNotification::OnEditorEntityCreated, entity->GetId()); + } return entity->GetId(); } @@ -253,8 +261,16 @@ namespace AzToolsFramework return AZ::EntityId(); } entity = aznew AZ::Entity(entityId, name); + AZ_Assert(entity != nullptr, "Entity with name %s couldn't be created.", name); AddEntity(entity); - FinalizeEditorEntity(entity); + if (m_isLegacySliceService) + { + FinalizeEditorEntity(entity); + } + else + { + EditorEntityContextNotificationBus::Broadcast(&EditorEntityContextNotification::OnEditorEntityCreated, entity->GetId()); + } return entity->GetId(); } diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/PrefabEditorEntityOwnershipService.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/PrefabEditorEntityOwnershipService.cpp index b91a0aac93..4a1198fdfe 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/PrefabEditorEntityOwnershipService.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Entity/PrefabEditorEntityOwnershipService.cpp @@ -349,8 +349,12 @@ namespace AzToolsFramework instanceToParentUnder = *m_rootInstance; } - AZStd::unique_ptr instantiatedPrefabInstance = - m_prefabSystemComponent->InstantiatePrefab(filePath, instanceToParentUnder); + AZStd::unique_ptr instantiatedPrefabInstance = m_prefabSystemComponent->InstantiatePrefab( + filePath, instanceToParentUnder, + [this](const EntityList& entities) + { + HandleEntitiesAdded(entities); + }); if (instantiatedPrefabInstance) { @@ -415,8 +419,8 @@ namespace AzToolsFramework { // Construct the runtime entities and products bool readyToCreateRootSpawnable = m_playInEditorData.m_assetsCache.IsActivated(); - if (!readyToCreateRootSpawnable && - !m_playInEditorData.m_assetsCache.Activate(Prefab::PrefabConversionUtils::PlayInEditor)) + if (!readyToCreateRootSpawnable && !m_playInEditorData.m_assetsCache.Activate(Prefab::PrefabConversionUtils::PlayInEditor)) + { AZ_Error("Prefab", false, "Failed to create a prefab processing stack from key '%.*s'.", AZ_STRING_ARG(Prefab::PrefabConversionUtils::PlayInEditor)); return; diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Manipulators/ManipulatorSnapping.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Manipulators/ManipulatorSnapping.cpp index 5bea383630..3b2f78ef2d 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Manipulators/ManipulatorSnapping.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Manipulators/ManipulatorSnapping.cpp @@ -184,6 +184,10 @@ namespace AzToolsFramework const float halfGridSquareCount = float(gridSquareCount) * 0.5f; const float halfGridSize = halfGridSquareCount * squareSize; const float fadeLineLength = cl_viewportFadeLineDistanceScale * squareSize; + + // ensure AuxGeomDraw::OpacityType::Translucent render state is set + debugDisplay.SetAlpha(0.5f); + for (size_t lineIndex = 0; lineIndex <= gridSquareCount; ++lineIndex) { const float lineOffset = -halfGridSize + (lineIndex * squareSize); diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Instance/Instance.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Instance/Instance.cpp index 490a151925..03d62dff0a 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Instance/Instance.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Instance/Instance.cpp @@ -142,14 +142,14 @@ namespace AzToolsFramework return m_templateSourcePath; } - void Instance::SetTemplateSourcePath(AZ::IO::PathView sourcePath) + void Instance::SetTemplateSourcePath(AZ::IO::Path sourcePath) { - m_templateSourcePath = sourcePath; + m_templateSourcePath = AZStd::move(sourcePath); } - void Instance::SetContainerEntityName(AZStd::string_view containerName) + void Instance::SetContainerEntityName(AZStd::string containerName) { - m_containerEntity->SetName(containerName); + m_containerEntity->SetName(AZStd::move(containerName)); } bool Instance::AddEntity(AZ::Entity& entity) @@ -608,6 +608,31 @@ namespace AzToolsFramework } AZ::EntityId Instance::GetEntityIdFromAliasPath(AliasPathView relativeAliasPath) const + { + return GetInstanceAndEntityIdFromAliasPath(relativeAliasPath).second; + } + + AZStd::pair Instance::GetInstanceAndEntityIdFromAliasPath(AliasPathView relativeAliasPath) + { + Instance* instance = this; + AliasPathView path = relativeAliasPath.ParentPath(); + for (auto it : path) + { + InstanceOptionalReference child = instance->FindNestedInstance(it.Native()); + if (child.has_value()) + { + instance = &(child->get()); + } + else + { + return AZStd::pair(nullptr, AZ::EntityId()); + } + } + + return AZStd::pair(instance, instance->GetEntityId(relativeAliasPath.Filename().Native())); + } + + AZStd::pair Instance::GetInstanceAndEntityIdFromAliasPath(AliasPathView relativeAliasPath) const { const Instance* instance = this; AliasPathView path = relativeAliasPath.ParentPath(); @@ -620,11 +645,11 @@ namespace AzToolsFramework } else { - return AZ::EntityId(); + return AZStd::pair(nullptr, AZ::EntityId()); } } - return instance->GetEntityId(relativeAliasPath.Filename().Native()); + return AZStd::pair(instance, instance->GetEntityId(relativeAliasPath.Filename().Native())); } AZStd::vector Instance::GetNestedInstanceAliases(TemplateId templateId) const diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Instance/Instance.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Instance/Instance.h index 25971093cd..b63eca309a 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Instance/Instance.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Instance/Instance.h @@ -80,8 +80,8 @@ namespace AzToolsFramework void SetTemplateId(TemplateId templateId); const AZ::IO::Path& GetTemplateSourcePath() const; - void SetTemplateSourcePath(AZ::IO::PathView sourcePath); - void SetContainerEntityName(AZStd::string_view containerName); + void SetTemplateSourcePath(AZ::IO::Path sourcePath); + void SetContainerEntityName(AZStd::string containerName); bool AddEntity(AZ::Entity& entity); bool AddEntity(AZStd::unique_ptr&& entity); @@ -169,6 +169,13 @@ namespace AzToolsFramework * @return entityId, invalid ID if not found */ AZ::EntityId GetEntityIdFromAliasPath(AliasPathView relativeAliasPath) const; + /** + * Retrieves the instance pointer and entity id from an alias path that's relative to this instance. + * + * @return A pair with the Instance and entity id. The Instance is set to null and entityId is set to invalid if not found. + */ + AZStd::pair GetInstanceAndEntityIdFromAliasPath(AliasPathView relativeAliasPath); + AZStd::pair GetInstanceAndEntityIdFromAliasPath(AliasPathView relativeAliasPath) const; /** diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponent.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponent.cpp index 9936e466c3..98e0144f22 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponent.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponent.cpp @@ -277,7 +277,7 @@ namespace AzToolsFramework } AZStd::unique_ptr PrefabSystemComponent::InstantiatePrefab( - AZ::IO::PathView filePath, InstanceOptionalReference parent) + AZ::IO::PathView filePath, InstanceOptionalReference parent, const InstantiatedEntitiesCallback& instantiatedEntitiesCallback) { // Retrieve the template id for the source prefab filepath Prefab::TemplateId templateId = GetTemplateIdFromFilePath(filePath); @@ -297,11 +297,11 @@ namespace AzToolsFramework return nullptr; } - return InstantiatePrefab(templateId, parent); + return InstantiatePrefab(templateId, parent, instantiatedEntitiesCallback); } AZStd::unique_ptr PrefabSystemComponent::InstantiatePrefab( - TemplateId templateId, InstanceOptionalReference parent) + TemplateId templateId, InstanceOptionalReference parent, const InstantiatedEntitiesCallback& instantiatedEntitiesCallback) { TemplateReference instantiatingTemplate = FindTemplate(templateId); @@ -324,8 +324,10 @@ namespace AzToolsFramework return nullptr; } - AzToolsFramework::EditorEntityContextRequestBus::Broadcast( - &AzToolsFramework::EditorEntityContextRequests::HandleEntitiesAdded, newEntities); + if (instantiatedEntitiesCallback) + { + instantiatedEntitiesCallback(newEntities); + } return newInstance; } diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponent.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponent.h index d71065f8fc..b547e9bdd2 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponent.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponent.h @@ -124,19 +124,25 @@ namespace AzToolsFramework * Generates a new Prefab Instance based on the Template whose source is stored in filepath. * @param filePath The path to the prefab source file containing the template being instantiated. * @param parent Reference of the target instance the instantiated instance will be placed under. + * @param instantiatedEntitiesCallback An optional callback that can be used to modify the instantiated entities. * @return A unique_ptr to the newly instantiated instance. Null if operation failed. */ AZStd::unique_ptr InstantiatePrefab( - AZ::IO::PathView filePath, InstanceOptionalReference parent = AZStd::nullopt) override; + AZ::IO::PathView filePath, + InstanceOptionalReference parent = AZStd::nullopt, + const InstantiatedEntitiesCallback& instantiatedEntitiesCallback = {}) override; /** * Generates a new Prefab Instance based on the Template referenced by templateId. * @param templateId The id of the template being instantiated. * @param parent Reference of the target instance the instantiated instance will be placed under. + * @param instantiatedEntitiesCallback An optional callback that can be used to modify the instantiated entities. * @return A unique_ptr to the newly instantiated instance. Null if operation failed. */ AZStd::unique_ptr InstantiatePrefab( - TemplateId templateId, InstanceOptionalReference parent = AZStd::nullopt) override; + TemplateId templateId, + InstanceOptionalReference parent = AZStd::nullopt, + const InstantiatedEntitiesCallback& instantiatedEntitiesCallback = {}) override; /** * Add a new Link into Prefab System Component and create a unique id for it. diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponentInterface.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponentInterface.h index ce75930cb6..d39e868ef4 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponentInterface.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabSystemComponentInterface.h @@ -27,6 +27,9 @@ namespace AzToolsFramework class PrefabSystemComponentInterface { public: + + using InstantiatedEntitiesCallback = AZStd::function&)>; + AZ_RTTI(PrefabSystemComponentInterface, "{8E95A029-67F9-4F74-895F-DDBFE29516A0}"); virtual TemplateReference FindTemplate(TemplateId id) = 0; @@ -70,9 +73,13 @@ namespace AzToolsFramework virtual void PropagateTemplateChanges(TemplateId templateId, InstanceOptionalConstReference instanceToExclude = AZStd::nullopt) = 0; virtual AZStd::unique_ptr InstantiatePrefab( - AZ::IO::PathView filePath, InstanceOptionalReference parent = AZStd::nullopt) = 0; + AZ::IO::PathView filePath, + InstanceOptionalReference parent = AZStd::nullopt, + const InstantiatedEntitiesCallback& instantiatedEntitiesCallback = {}) = 0; virtual AZStd::unique_ptr InstantiatePrefab( - TemplateId templateId, InstanceOptionalReference parent = AZStd::nullopt) = 0; + TemplateId templateId, + InstanceOptionalReference parent = AZStd::nullopt, + const InstantiatedEntitiesCallback& instantiatedEntitiesCallback = {}) = 0; virtual AZStd::unique_ptr CreatePrefab(const AZStd::vector& entities, AZStd::vector>&& instancesToConsume, AZ::IO::PathView filePath, AZStd::unique_ptr containerEntity = nullptr, InstanceOptionalReference parent = AZStd::nullopt, diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EditorInfoRemover.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EditorInfoRemover.cpp index dfba1d54ba..9488b68ee8 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EditorInfoRemover.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EditorInfoRemover.cpp @@ -37,13 +37,13 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils } prefabProcessorContext.ListPrefabs( - [this, &serializeContext, &prefabProcessorContext]([[maybe_unused]] AZStd::string_view prefabName, PrefabDom& prefab) + [this, &serializeContext, &prefabProcessorContext](PrefabDocument& prefab) { auto result = RemoveEditorInfo(prefab, serializeContext, prefabProcessorContext); if (!result) { AZ_Error( - "Prefab", false, "Converting to runtime Prefab '%.*s' failed, Error: %s .", AZ_STRING_ARG(prefabName), + "Prefab", false, "Converting to runtime Prefab '%s' failed, Error: %s .", prefab.GetName().c_str(), result.GetError().c_str()); return; } @@ -58,10 +58,9 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils } } - void EditorInfoRemover::GetEntitiesFromInstance( - AZStd::unique_ptr& instance, EntityList& hierarchyEntities) + void EditorInfoRemover::GetEntitiesFromInstance(AzToolsFramework::Prefab::Instance& instance, EntityList& hierarchyEntities) { - instance->GetAllEntitiesInHierarchy( + instance.GetAllEntitiesInHierarchy( [&hierarchyEntities](const AZStd::unique_ptr& entity) { hierarchyEntities.emplace_back(entity.get()); @@ -498,7 +497,7 @@ exportComponent, prefabProcessorContext); } EditorInfoRemover::RemoveEditorInfoResult EditorInfoRemover::RemoveEditorInfo( - PrefabDom& prefab, + PrefabDocument& prefab, AZ::SerializeContext* serializeContext, PrefabProcessorContext& prefabProcessorContext) { @@ -510,28 +509,10 @@ exportComponent, prefabProcessorContext); m_componentRequirementsValidator.SetPlatformTags(prefabProcessorContext.GetPlatformTags()); - // convert Prefab DOM into Prefab Instance. - AZStd::unique_ptr instance(aznew Instance()); - if (!Prefab::PrefabDomUtils::LoadInstanceFromPrefabDom(*instance, prefab, - Prefab::PrefabDomUtils::LoadFlags::AssignRandomEntityId)) - { - PrefabDomValueReference sourceReference = PrefabDomUtils::FindPrefabDomValue(prefab, PrefabDomUtils::SourceName); - - AZStd::string errorMessage("Failed to Load Prefab Instance from given Prefab Dom during Removal of Editor Info."); - if (sourceReference.has_value() && - sourceReference->get().IsString() && - sourceReference->get().GetStringLength() != 0) - { - AZStd::string_view source(sourceReference->get().GetString(), sourceReference->get().GetStringLength()); - errorMessage += AZStd::string::format("Prefab Source: %.*s", AZ_STRING_ARG(source)); - } - - return AZ::Failure(errorMessage); - } - // grab all nested entities from the Instance as source entities. + Instance& sourceInstance = prefab.GetInstance(); EntityList sourceEntities; - GetEntitiesFromInstance(instance, sourceEntities); + GetEntitiesFromInstance(sourceInstance, sourceEntities); EntityList exportEntities; @@ -597,7 +578,7 @@ exportComponent, prefabProcessorContext); exportEntitiesMap.emplace(entity->GetId(), entity); } ); - instance->RemoveNestedEntities( + sourceInstance.RemoveNestedEntities( [&exportEntitiesMap](const AZStd::unique_ptr& entity) { return exportEntitiesMap.find(entity->GetId()) == exportEntitiesMap.end(); @@ -605,7 +586,7 @@ exportComponent, prefabProcessorContext); ); // replace entities of instance with exported ones. - instance->GetAllEntitiesInHierarchy( + sourceInstance.GetAllEntitiesInHierarchy( [&exportEntitiesMap](AZStd::unique_ptr& entity) { auto entityId = entity->GetId(); @@ -614,16 +595,6 @@ exportComponent, prefabProcessorContext); } ); - // save the final result in the target Prefab DOM. - PrefabDom filteredPrefab; - if (!PrefabDomUtils::StoreInstanceInPrefabDom(*instance, filteredPrefab)) - { - return AZ::Failure(AZStd::string::format( - "Saving exported Prefab Instance within a Prefab Dom failed.") - ); - } - prefab.Swap(filteredPrefab); - return AZ::Success(); } } // namespace AzToolsFramework::Prefab::PrefabConversionUtils diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EditorInfoRemover.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EditorInfoRemover.h index dc10952733..dbad58d2f5 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EditorInfoRemover.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EditorInfoRemover.h @@ -43,7 +43,7 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils using RemoveEditorInfoResult = AZ::Outcome; RemoveEditorInfoResult RemoveEditorInfo( - PrefabDom& prefab, + PrefabDocument& prefab, AZ::SerializeContext* serializeContext, PrefabProcessorContext& prefabProcessorContext); @@ -51,8 +51,7 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils protected: using EntityList = AZStd::vector; - static void GetEntitiesFromInstance( - AZStd::unique_ptr& instance, EntityList& hierarchyEntities); + static void GetEntitiesFromInstance(AzToolsFramework::Prefab::Instance& instance, EntityList& hierarchyEntities); static bool ReadComponentAttribute( AZ::Component* component, diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EntityAliasTypes.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EntityAliasTypes.h new file mode 100644 index 0000000000..9ab1f9bbd1 --- /dev/null +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/EntityAliasTypes.h @@ -0,0 +1,69 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include +#include +#include +#include + +namespace AzToolsFramework::Prefab::PrefabConversionUtils +{ + enum class EntityAliasType : uint8_t + { + Disable, //!< No alias is added. + OptionalReplace, //!< At runtime the entity might be replaced. If the alias is disabled the original entity will be spawned. + //!< The original entity will be left in the spawnable and a copy is returned. + Replace, //!< At runtime the entity will be replaced. If the alias is disabled nothing will be spawned. The original + //!< entity is returned and a blank entity is left. + Additional, //!< At runtime the alias entity will be added as an additional but unrelated entity with a new entity id. + //!< An empty entity will be returned. + Merge //!< At runtime the components in both entities will be merged. An empty entity will be returned. The added + //!< components may no conflict with the entities already in the root entity. + }; + + enum class EntityAliasSpawnableLoadBehavior : uint8_t + { + NoLoad, //!< Don't load the spawnable referenced in the entity alias. Loading will be up to the caller. + QueueLoad, //!< Queue the spawnable referenced in the entity alias for loading. This will be an async load because asset + //!< handlers aren't allowed to start a blocking load as this can lead to deadlocks. This option will allow + //!< to disable loading the referenced spawnable through the event fired from the spawnables asset handler. + DependentLoad //!< The spawnable referenced in the entity alias is made a dependency of the spawnable that holds the entity + //!< alias. This will cause the spawnable to be automatically loaded along with the owning spawnable. + }; + + struct EntityAliasSpawnableLink + { + EntityAliasSpawnableLink(AzFramework::Spawnable& spawnable, AZ::EntityId index); + + AzFramework::Spawnable& m_spawnable; + AZ::EntityId m_index; + }; + + struct EntityAliasPrefabLink + { + EntityAliasPrefabLink(AZStd::string prefabName, AzToolsFramework::Prefab::AliasPath alias); + + AZStd::string m_prefabName; + AzToolsFramework::Prefab::AliasPath m_alias; + }; + + struct EntityAliasStore + { + using LinkStore = AZStd::variant; + + LinkStore m_source; + LinkStore m_target; + uint32_t m_tag; + AzFramework::Spawnable::EntityAliasType m_aliasType; + EntityAliasSpawnableLoadBehavior m_loadBehavior; + }; +} // namespace AzToolsFramework::Prefab::PrefabConversionUtils diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/InMemorySpawnableAssetContainer.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/InMemorySpawnableAssetContainer.cpp index 553ad8ece4..dc5cd299b8 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/InMemorySpawnableAssetContainer.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/InMemorySpawnableAssetContainer.cpp @@ -112,9 +112,9 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils // Use a random uuid as this is only a temporary source. PrefabConversionUtils::PrefabProcessorContext context(AZ::Uuid::CreateRandom()); - PrefabDom copy; - copy.CopyFrom(templateReference->get().GetPrefabDom(), copy.GetAllocator(), false); - context.AddPrefab(spawnableName, AZStd::move(copy)); + PrefabDocument document(spawnableName); + document.SetPrefabDom(templateReference->get().GetPrefabDom()); + context.AddPrefab(AZStd::move(document)); m_converter.ProcessPrefab(context); if (!context.HasCompletedSuccessfully() || context.GetProcessedObjects().empty()) diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabCatchmentProcessor.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabCatchmentProcessor.cpp index 7a54950c47..a5ca034c36 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabCatchmentProcessor.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabCatchmentProcessor.cpp @@ -25,9 +25,9 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils { AZ::DataStream::StreamType serializationFormat = m_serializationFormat == SerializationFormats::Binary ? AZ::DataStream::StreamType::ST_BINARY : AZ::DataStream::StreamType::ST_XML; - context.ListPrefabs([&context, serializationFormat](AZStd::string_view prefabName, PrefabDom& prefab) + context.ListPrefabs([&context, serializationFormat](PrefabDocument& prefab) { - ProcessPrefab(context, prefabName, prefab, serializationFormat); + ProcessPrefab(context, prefab, serializationFormat); }); } @@ -45,12 +45,12 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils } } - void PrefabCatchmentProcessor::ProcessPrefab(PrefabProcessorContext& context, AZStd::string_view prefabName, PrefabDom& prefab, + void PrefabCatchmentProcessor::ProcessPrefab(PrefabProcessorContext& context, PrefabDocument& prefab, AZ::DataStream::StreamType serializationFormat) { using namespace AzToolsFramework::Prefab::SpawnableUtils; - AZStd::string uniqueName = prefabName; + AZStd::string uniqueName = prefab.GetName(); uniqueName += AzFramework::Spawnable::DotFileExtension; auto serializer = [serializationFormat](AZStd::vector& output, const ProcessedObjectStore& object) -> bool @@ -64,45 +64,35 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils AZStd::move(uniqueName), context.GetSourceUuid(), AZStd::move(serializer)); AZ_Assert(spawnable, "Failed to create a new spawnable."); - Instance instance; - if (Prefab::PrefabDomUtils::LoadInstanceFromPrefabDom( - instance, prefab, object.GetReferencedAssets(), - Prefab::PrefabDomUtils::LoadFlags::AssignRandomEntityId)) // Always assign random entity ids because the spawnable is - // going to be used to create clones of the entities. - { - // Resolve entity aliases that store PrefabDOM information to use the spawnable instead. This is done before the entities are - // moved from the instance as they'd otherwise can't be found. - context.ResolveSpawnableEntityAliases(prefabName, *spawnable, instance); + object.GetReferencedAssets() = prefab.GetReferencedAssets(); + Instance& instance = prefab.GetInstance(); + // Resolve entity aliases that store PrefabDOM information to use the spawnable instead. This is done before the entities are + // moved from the instance as they'd otherwise can't be found. + context.ResolveSpawnableEntityAliases(prefab.GetName(), *spawnable, instance); - AzFramework::Spawnable::EntityList& entities = spawnable->GetEntities(); - instance.DetachAllEntitiesInHierarchy( - [&entities, &context](AZStd::unique_ptr entity) + AzFramework::Spawnable::EntityList& entities = spawnable->GetEntities(); + instance.DetachAllEntitiesInHierarchy( + [&entities, &context](AZStd::unique_ptr entity) + { + if (entity) { - if (entity) + entity->InvalidateDependencies(); + AZ::Entity::DependencySortOutcome evaluation = entity->EvaluateDependenciesGetDetails(); + if (evaluation.IsSuccess()) + { + entities.emplace_back(AZStd::move(entity)); + } + else { - entity->InvalidateDependencies(); - AZ::Entity::DependencySortOutcome evaluation = entity->EvaluateDependenciesGetDetails(); - if (evaluation.IsSuccess()) - { - entities.emplace_back(AZStd::move(entity)); - } - else - { - AZ_Error( - "Prefabs", false, "Entity '%s' %s cannot be activated for the following reason: %s", - entity->GetName().c_str(), entity->GetId().ToString().c_str(), evaluation.GetError().m_message.c_str()); - context.ErrorEncountered(); - } + AZ_Error( + "Prefabs", false, "Entity '%s' %s cannot be activated for the following reason: %s", + entity->GetName().c_str(), entity->GetId().ToString().c_str(), evaluation.GetError().m_message.c_str()); + context.ErrorEncountered(); } - }); + } + }); - SpawnableUtils::SortEntitiesByTransformHierarchy(*spawnable); - context.GetProcessedObjects().push_back(AZStd::move(object)); - } - else - { - AZ_Error("Prefabs", false, "Failed to convert prefab '%.*s' to a spawnable.", AZ_STRING_ARG(prefabName)); - context.ErrorEncountered(); - } + SpawnableUtils::SortEntitiesByTransformHierarchy(*spawnable); + context.GetProcessedObjects().push_back(AZStd::move(object)); } } // namespace AzToolsFramework::Prefab::PrefabConversionUtils diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabCatchmentProcessor.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabCatchmentProcessor.h index 253321f8e7..39a94c86b8 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabCatchmentProcessor.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabCatchmentProcessor.h @@ -40,8 +40,7 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils static void Reflect(AZ::ReflectContext* context); protected: - static void ProcessPrefab(PrefabProcessorContext& context, AZStd::string_view prefabName, PrefabDom& prefab, - AZ::DataStream::StreamType serializationFormat); + static void ProcessPrefab(PrefabProcessorContext& context, PrefabDocument& prefab, AZ::DataStream::StreamType serializationFormat); SerializationFormats m_serializationFormat{ SerializationFormats::Binary }; }; diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.cpp new file mode 100644 index 0000000000..230c2226cd --- /dev/null +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.cpp @@ -0,0 +1,161 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include +#include + +namespace AzToolsFramework::Prefab::PrefabConversionUtils +{ + PrefabDocument::PrefabDocument(AZStd::string name) + : m_name(AZStd::move(name)) + , m_instance(AZStd::make_unique()) + { + m_instance->SetTemplateSourcePath(AZ::IO::Path("InMemory") / m_name); + } + + bool PrefabDocument::SetPrefabDom(const PrefabDom& prefab) + { + if (ConstructInstanceFromPrefabDom(prefab)) + { + constexpr bool copyConstStrings = true; + m_dom.CopyFrom(prefab, m_dom.GetAllocator(), copyConstStrings); + return true; + } + else + { + return false; + } + } + + bool PrefabDocument::SetPrefabDom(PrefabDom&& prefab) + { + if (ConstructInstanceFromPrefabDom(prefab)) + { + m_dom = AZStd::move(prefab); + return true; + } + else + { + return false; + } + } + + const AZStd::string& PrefabDocument::GetName() const + { + return m_name; + } + + const PrefabDom& PrefabDocument::GetDom() const + { + if (m_isDirty) + { + m_isDirty = !PrefabDomUtils::StoreInstanceInPrefabDom(*m_instance, m_dom); + } + return m_dom; + } + + PrefabDom&& PrefabDocument::TakeDom() + { + if (m_isDirty) + { + [[maybe_unused]] bool storedSuccessfully = PrefabDomUtils::StoreInstanceInPrefabDom(*m_instance, m_dom); + AZ_Assert(storedSuccessfully, "Failed to store Instance '%s' to PrefabDom.", m_name.c_str()); + m_isDirty = false; + } + // After the PrefabDom is moved an empty PrefabDom is left behind. This should be reflected in the Instance, + // so reset it so it's empty as well. + m_instance->Reset(); + m_instance->SetTemplateSourcePath(AZ::IO::Path("InMemory") / m_name); + return AZStd::move(m_dom); + } + + void PrefabDocument::ListEntitiesWithComponentType( + AZ::TypeId componentType, const AZStd::function& callback) const + { + m_instance->GetAllEntitiesInHierarchyConst( + [this, &componentType, &callback](const AZ::Entity& entity) -> bool + { + if (entity.FindComponent(componentType)) + { + return callback(m_instance->GetAliasPathRelativeToInstance(entity.GetId())); + } + else + { + return true; + } + }); + } + + AZ::Entity* PrefabDocument::CreateEntityAlias( + PrefabDocument& source, + AzToolsFramework::Prefab::AliasPathView entity, + AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasType aliasType, + AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasSpawnableLoadBehavior loadBehavior, + uint32_t tag, + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context) + { + auto&& [sourceInstance, entityId] = source.m_instance->GetInstanceAndEntityIdFromAliasPath(entity); + if (sourceInstance != nullptr && entityId.IsValid()) + { + return SpawnableUtils::CreateEntityAlias( + source.m_name, *sourceInstance, m_name, *m_instance, entityId, aliasType, loadBehavior, tag, context); + } + else + { + return nullptr; + } + } + + AzToolsFramework::Prefab::Instance& PrefabDocument::GetInstance() + { + // Assume that changes will be made to the instance. + m_isDirty = true; + return *m_instance; + } + + const AzToolsFramework::Prefab::Instance& PrefabDocument::GetInstance() const + { + return *m_instance; + } + + AZStd::vector>& PrefabDocument::GetReferencedAssets() + { + return m_referencedAssets; + } + + const AZStd::vector>& PrefabDocument::GetReferencedAssets() const + { + return m_referencedAssets; + } + + bool PrefabDocument::ConstructInstanceFromPrefabDom(const PrefabDom& prefab) + { + using namespace AzToolsFramework::Prefab; + + m_instance->Reset(); + if (PrefabDomUtils::LoadInstanceFromPrefabDom(*m_instance, prefab, m_referencedAssets, PrefabDomUtils::LoadFlags::AssignRandomEntityId)) + { + return true; + } + else + { +#ifdef AZ_ENABLE_TRACING + AZStd::string_view sourceName = m_name; + PrefabDomValueConstReference sourceReference = PrefabDomUtils::FindPrefabDomValue(prefab, PrefabDomUtils::SourceName); + if (sourceReference.has_value() && sourceReference->get().IsString() && sourceReference->get().GetStringLength() != 0) + { + sourceName = AZStd::string_view(sourceReference->get().GetString(), sourceReference->get().GetStringLength()); + } + AZ_Error( + "PrefabDocument", false, "Failed to construct Prefab instance from given PrefabDOM '%.*s'.", AZ_STRING_ARG(sourceName)); +#endif + return false; + } + } +} // namespace AzToolsFramework::Prefab::PrefabConversionUtils diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.h new file mode 100644 index 0000000000..661dba5edf --- /dev/null +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.h @@ -0,0 +1,70 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include +#include +#include +#include +#include + +namespace AzToolsFramework::Prefab::PrefabConversionUtils +{ + class PrefabProcessorContext; + + class PrefabDocument final + { + public: + explicit PrefabDocument(AZStd::string name); + PrefabDocument(const PrefabDocument&) = delete; + PrefabDocument(PrefabDocument&&) = default; + + PrefabDocument& operator=(const PrefabDocument&) = delete; + PrefabDocument& operator=(PrefabDocument&&) = default; + + bool SetPrefabDom(const PrefabDom& prefab); + bool SetPrefabDom(PrefabDom&& prefab); + + const AZStd::string& GetName() const; + const PrefabDom& GetDom() const; + PrefabDom&& TakeDom(); + + template + void ListEntitiesWithComponentType(const AZStd::function& callback) const; + void ListEntitiesWithComponentType( + AZ::TypeId componentType, const AZStd::function& callback) const; + AZ::Entity* CreateEntityAlias( + PrefabDocument& source, + AzToolsFramework::Prefab::AliasPathView entity, + AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasType aliasType, + AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasSpawnableLoadBehavior loadBehavior, + uint32_t tag, + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context); + + // Where possible, prefer functions directly on the PrefabDocument Instead of using the Instance. + AzToolsFramework::Prefab::Instance& GetInstance(); + const AzToolsFramework::Prefab::Instance& GetInstance() const; + + AZStd::vector>& GetReferencedAssets(); + const AZStd::vector>& GetReferencedAssets() const; + + private: + bool ConstructInstanceFromPrefabDom(const PrefabDom& prefab); + + mutable PrefabDom m_dom; + AZStd::unique_ptr m_instance; + AZStd::string m_name; + AZStd::vector> m_referencedAssets; + mutable bool m_isDirty{ false }; + }; +} // namespace AzToolsFramework::Prefab::PrefabConversionUtils + +#include diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.inl b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.inl new file mode 100644 index 0000000000..37b1f1c127 --- /dev/null +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabDocument.inl @@ -0,0 +1,16 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +namespace AzToolsFramework::Prefab::PrefabConversionUtils +{ + template + void PrefabDocument::ListEntitiesWithComponentType(const AZStd::function& callback) const + { + ListEntitiesWithComponentType(azrtti_typeid(), callback); + } +} // namespace AzToolsFramework::Prefab::PrefabConversionUtils diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabProcessorContext.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabProcessorContext.cpp index efef0f53de..12625712b7 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabProcessorContext.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabProcessorContext.cpp @@ -7,8 +7,10 @@ */ #include +#include #include #include +#include #include #include @@ -30,27 +32,42 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils : m_sourceUuid(sourceUuid) {} - bool PrefabProcessorContext::AddPrefab(AZStd::string prefabName, PrefabDom prefab) + bool PrefabProcessorContext::AddPrefab(PrefabDocument&& document) { - auto result = m_prefabs.emplace(AZStd::move(prefabName), AZStd::move(prefab)); - return result.second; + AZStd::string name = document.GetName(); + if (!m_prefabNames.contains(name)) + { + m_prefabNames.emplace(AZStd::move(name)); + // If currently iterating add to pending queue to avoid invalidating the container that's being iterated over. + PrefabContainer& container = m_isIterating ? m_pendingPrefabAdditions : m_prefabs; + container.push_back(AZStd::move(document)); + return true; + } + return false; } - void PrefabProcessorContext::ListPrefabs(const AZStd::function& callback) + void PrefabProcessorContext::ListPrefabs(const AZStd::function& callback) { + // Enable iterating state so the prefab container doesn't get invalided. Enabling this flag will cause new prefabs + // to be stored in a temporary buffer that can be moved into the regular prefab container after iterating. m_isIterating = true; - for (auto& it : m_prefabs) + for (PrefabDocument& document : m_prefabs) { - callback(it.first, it.second); + callback(document); } + m_isIterating = false; + m_prefabs.insert( + m_prefabs.end(), AZStd::make_move_iterator(m_pendingPrefabAdditions.begin()), + AZStd::make_move_iterator(m_pendingPrefabAdditions.end())); + m_pendingPrefabAdditions.clear(); } - void PrefabProcessorContext::ListPrefabs(const AZStd::function& callback) const + void PrefabProcessorContext::ListPrefabs(const AZStd::function& callback) const { - for (const auto& it : m_prefabs) + for (const PrefabDocument& document : m_prefabs) { - callback(it.first, it.second); + callback(document); } } @@ -132,6 +149,7 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils { using namespace AzToolsFramework::Prefab; + // Resolve prefab links into spawnable links for the provided spawnable. for (EntityAliasStore& entityAlias : m_entityAliases) { auto sourcePrefab = AZStd::get_if(&entityAlias.m_source); @@ -224,11 +242,35 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils it = aliasVisitors.emplace(source->m_spawnable.GetId(), AZStd::move(visitor)).first; } it->second.AddAlias( - AZ::Data::Asset(&target->m_spawnable, loadBehavior), alias.m_tag, sourceIndex, targetIndex, + AZ::Data::Asset(target->m_spawnable.GetId(), azrtti_typeid()), alias.m_tag, + sourceIndex, targetIndex, alias.m_aliasType, alias.m_loadBehavior == EntityAliasSpawnableLoadBehavior::QueueLoad); // Register the dependency between the two spawnables. RegisterProductAssetDependency(source->m_spawnable.GetId(), target->m_spawnable.GetId(), loadBehavior); + + // Patch up all entity ids so the alias points to the same entity id if needed. + switch (alias.m_aliasType) + { + case AzFramework::Spawnable::EntityAliasType::Original: + continue; + case AzFramework::Spawnable::EntityAliasType::Disable: + continue; + case AzFramework::Spawnable::EntityAliasType::Replace: + break; // Requires entity id for alias in source and target spawnable matches. + case AzFramework::Spawnable::EntityAliasType::Additional: + continue; + case AzFramework::Spawnable::EntityAliasType::Merge: + break; // Requires entity id for alias in source and target spawnable matches. + default: + continue; + } + + auto entityIdMapper = [source, target](const AZ::EntityId& originalId, bool /*isEntityId*/) -> AZ::EntityId + { + return originalId == target->m_index ? source->m_index : originalId; + }; + AZ::EntityUtils::ReplaceEntityIdsAndEntityRefs(&target->m_spawnable, entityIdMapper); } } diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabProcessorContext.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabProcessorContext.h index d35a09a574..d07761271b 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabProcessorContext.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/PrefabProcessorContext.h @@ -21,60 +21,12 @@ #include #include #include +#include +#include #include namespace AzToolsFramework::Prefab::PrefabConversionUtils { - enum class EntityAliasType : uint8_t - { - Disable, //!< No alias is added. - OptionalReplace, //!< At runtime the entity might be replaced. If the alias is disabled the original entity will be spawned. - //!< The original entity will be left in the spawnable and a copy is returned. - Replace, //!< At runtime the entity will be replaced. If the alias is disabled nothing will be spawned. The original - //!< entity is returned and a blank entity is left. - Additional, //!< At runtime the alias entity will be added as an additional but unrelated entity with a new entity id. - //!< An empty entity will be returned. - Merge //!< At runtime the components in both entities will be merged. An empty entity will be returned. The added - //!< components may no conflict with the entities already in the root entity. - }; - - enum class EntityAliasSpawnableLoadBehavior : uint8_t - { - NoLoad, //!< Don't load the spawnable referenced in the entity alias. Loading will be up to the caller. - QueueLoad, //!< Queue the spawnable referenced in the entity alias for loading. This will be an async load because asset - //!< handlers aren't allowed to start a blocking load as this can lead to deadlocks. This option will allow - //!< to disable loading the referenced spawnable through the event fired from the spawnables asset handler. - DependentLoad //!< The spawnable referenced in the entity alias is made a dependency of the spawnable that holds the entity - //!< alias. This will cause the spawnable to be automatically loaded along with the owning spawnable. - }; - - struct EntityAliasSpawnableLink - { - EntityAliasSpawnableLink(AzFramework::Spawnable& spawnable, AZ::EntityId index); - - AzFramework::Spawnable& m_spawnable; - AZ::EntityId m_index; - }; - - struct EntityAliasPrefabLink - { - EntityAliasPrefabLink(AZStd::string prefabName, AzToolsFramework::Prefab::AliasPath alias); - - AZStd::string m_prefabName; - AzToolsFramework::Prefab::AliasPath m_alias; - }; - - struct EntityAliasStore - { - using LinkStore = AZStd::variant; - - LinkStore m_source; - LinkStore m_target; - uint32_t m_tag; - AzFramework::Spawnable::EntityAliasType m_aliasType; - EntityAliasSpawnableLoadBehavior m_loadBehavior; - }; - struct AssetDependencyInfo { AZ::Data::AssetId m_assetId; @@ -93,9 +45,9 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils explicit PrefabProcessorContext(const AZ::Uuid& sourceUuid); virtual ~PrefabProcessorContext() = default; - virtual bool AddPrefab(AZStd::string prefabName, PrefabDom prefab); - virtual void ListPrefabs(const AZStd::function& callback); - virtual void ListPrefabs(const AZStd::function& callback) const; + virtual bool AddPrefab(PrefabDocument&& document); + virtual void ListPrefabs(const AZStd::function& callback); + virtual void ListPrefabs(const AZStd::function& callback) const; virtual bool HasPrefabs() const; virtual bool RegisterSpawnableProductAssetDependency( @@ -128,12 +80,15 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils virtual void ErrorEncountered(); protected: - using NamedPrefabContainer = AZStd::unordered_map; + using PrefabNames = AZStd::unordered_set; + using PrefabContainer = AZStd::vector; using SpawnableEntityAliasStore = AZStd::vector; AZ::Data::AssetLoadBehavior ToAssetLoadBehavior(EntityAliasSpawnableLoadBehavior loadBehavior) const; - NamedPrefabContainer m_prefabs; + PrefabContainer m_prefabs; + PrefabContainer m_pendingPrefabAdditions; + PrefabNames m_prefabNames; SpawnableEntityAliasStore m_entityAliases; ProcessedObjectStoreContainer m_products; ProductAssetDependencyContainer m_registeredProductAssetDependencies; diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/SpawnableUtils.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/SpawnableUtils.cpp index 5e552aad3f..4f007f509e 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/SpawnableUtils.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/SpawnableUtils.cpp @@ -16,10 +16,12 @@ #include #include #include +#include #include #include #include #include +#include namespace AzToolsFramework::Prefab::SpawnableUtils { @@ -52,14 +54,32 @@ namespace AzToolsFramework::Prefab::SpawnableUtils return result; } + const AZ::Entity* FindEntity(AZ::EntityId entityId, const AzToolsFramework::Prefab::Instance& source) + { + const AZ::Entity* result = nullptr; + source.GetConstEntities( + [&result, entityId](const AZ::Entity& entity) + { + if (entity.GetId() != entityId) + { + return true; + } + else + { + result = &entity; + return false; + } + }); + return result; + } + AZ::Entity* FindEntity(AZ::EntityId entityId, AzFramework::Spawnable& source) { uint32_t index = AzToolsFramework::Prefab::SpawnableUtils::FindEntityIndex(entityId, source); return index != InvalidEntityIndex ? source.GetEntities()[index].get() : nullptr; } - template - AZStd::unique_ptr CloneEntity(AZ::EntityId entityId, T& source) + AZStd::unique_ptr CloneEntity(AZ::EntityId entityId, AzToolsFramework::Prefab::Instance& source) { AZ::Entity* target = Internal::FindEntity(entityId, source); AZ_Assert( @@ -74,41 +94,30 @@ namespace AzToolsFramework::Prefab::SpawnableUtils return clone; } - AZStd::unique_ptr ReplaceEntityWithPlaceholder(AZ::EntityId entityId, AzToolsFramework::Prefab::Instance& source) + AZStd::unique_ptr ReplaceEntityWithPlaceholder( + AZ::EntityId entityId, + [[maybe_unused]] AZStd::string_view sourcePrefabName, + AzToolsFramework::Prefab::Instance& source) { auto&& [instance, alias] = source.FindInstanceAndAlias(entityId); AZ_Assert( - instance, "SpawnbleUtils were unable to locate entity alias with id %zu in Instance '%s' for replacing.", - aznumeric_cast(entityId), source.GetTemplateSourcePath().c_str()); + instance, "SpawnbleUtils were unable to locate entity alias with id %zu in Instance '%.*s' for replacing.", + aznumeric_cast(entityId), AZ_STRING_ARG(sourcePrefabName)); EntityOptionalReference entityData = instance->GetEntity(alias); AZ_Assert( - entityData.has_value(), "SpawnbleUtils were unable to locate entity '%.*s' in Instance '%s' for replacing.", - AZ_STRING_ARG(alias), source.GetTemplateSourcePath().c_str()); - auto placeholder = AZStd::make_unique(entityData->get().GetId(), entityData->get().GetName()); + entityData.has_value(), "SpawnbleUtils were unable to locate entity '%.*s' in Instance '%.*s' for replacing.", + AZ_STRING_ARG(alias), AZ_STRING_ARG(sourcePrefabName)); + // A new entity id can be used for the placeholder as `ReplaceEntity` will swap the entity ids. + auto placeholder = AZStd::make_unique(AZ::Entity::MakeId(), entityData->get().GetName()); return instance->ReplaceEntity(AZStd::move(placeholder), alias); } - AZStd::unique_ptr ReplaceEntityWithPlaceholder(AZ::EntityId entityId, AzFramework::Spawnable& source) - { - uint32_t index = AzToolsFramework::Prefab::SpawnableUtils::FindEntityIndex(entityId, source); - AZ_Assert( - index != InvalidEntityIndex, "SpawnbleUtils were unable to locate entity alias with id %zu in Spawnable for replacing.", - aznumeric_cast(entityId)); - - AZStd::unique_ptr original = AZStd::move(source.GetEntities()[index]); - AZ_Assert( - original, "SpawnbleUtils were unable to locate entity with id %zu in Spawnable for replacing.", - aznumeric_cast(entityId)); - - source.GetEntities()[index] = AZStd::make_unique(original->GetId(), original->GetName()); - - return original; - } - - template AZStd::pair, AzFramework::Spawnable::EntityAliasType> ApplyAlias( - Source& source, AZ::EntityId entityId, AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasType aliasType) + AZStd::string_view sourcePrefabName, + AzToolsFramework::Prefab::Instance& source, + AZ::EntityId entityId, + AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasType aliasType) { namespace PCU = AzToolsFramework::Prefab::PrefabConversionUtils; using ResultPair = AZStd::pair, AzFramework::Spawnable::EntityAliasType>; @@ -121,12 +130,13 @@ namespace AzToolsFramework::Prefab::SpawnableUtils case PCU::EntityAliasType::OptionalReplace: return ResultPair(CloneEntity(entityId, source), AzFramework::Spawnable::EntityAliasType::Replace); case PCU::EntityAliasType::Replace: - return ResultPair(ReplaceEntityWithPlaceholder(entityId, source), AzFramework::Spawnable::EntityAliasType::Replace); + return ResultPair( + ReplaceEntityWithPlaceholder(entityId, sourcePrefabName, source), + AzFramework::Spawnable::EntityAliasType::Replace); case PCU::EntityAliasType::Additional: - ResultPair(AZStd::make_unique(AZ::Entity::MakeId()), AzFramework::Spawnable::EntityAliasType::Additional); + return ResultPair(AZStd::make_unique(), AzFramework::Spawnable::EntityAliasType::Additional); case PCU::EntityAliasType::Merge: - // Use the same entity id as the original entity so at runtime the entity ids can be verified to match. - ResultPair(AZStd::make_unique(entityId), AzFramework::Spawnable::EntityAliasType::Merge); + return ResultPair(AZStd::make_unique(), AzFramework::Spawnable::EntityAliasType::Merge); default: AZ_Assert( false, "Invalid PrefabProcessorContext::EntityAliasType type (%i) provided.", aznumeric_cast(aliasType)); @@ -182,7 +192,8 @@ namespace AzToolsFramework::Prefab::SpawnableUtils AliasPath alias = source.GetAliasPathRelativeToInstance(entityId); if (!alias.empty()) { - auto&& [replacement, storedAliasType] = Internal::ApplyAlias(source, entityId, aliasType); + auto&& [replacement, storedAliasType] = + Internal::ApplyAlias(sourcePrefabName, source, entityId, aliasType); if (replacement) { AZ::Entity* result = replacement.get(); @@ -212,84 +223,6 @@ namespace AzToolsFramework::Prefab::SpawnableUtils } } - AZ::Entity* CreateEntityAlias( - AZStd::string sourcePrefabName, - AzToolsFramework::Prefab::Instance& source, - AzFramework::Spawnable& target, - AZ::EntityId entityId, - AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasType aliasType, - AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasSpawnableLoadBehavior loadBehavior, - uint32_t tag, - AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context) - { - using namespace AzToolsFramework::Prefab::PrefabConversionUtils; - - AliasPath alias = source.GetAliasPathRelativeToInstance(entityId); - if (!alias.empty()) - { - auto&& [replacement, storedAliasType] = Internal::ApplyAlias(source, entityId, aliasType); - if (replacement) - { - AZ::Entity* result = replacement.get(); - target.GetEntities().push_back(AZStd::move(replacement)); - - EntityAliasStore store; - store.m_aliasType = storedAliasType; - store.m_source.emplace(AZStd::move(sourcePrefabName), AZStd::move(alias)); - store.m_target.emplace(target, result->GetId()); - store.m_tag = tag; - store.m_loadBehavior = loadBehavior; - context.RegisterSpawnableEntityAlias(AZStd::move(store)); - - return result; - } - else - { - AZ_Assert(false, "A replacement for entity with id %zu could not be created.", static_cast(entityId)); - return nullptr; - } - } - else - { - AZ_Assert(false, "Entity with id %llu was not found in the source prefab.", static_cast(entityId)); - return nullptr; - } - } - - AZ::Entity* CreateEntityAlias( - AzFramework::Spawnable& source, - AzFramework::Spawnable& target, - AZ::EntityId entityId, - AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasType aliasType, - AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasSpawnableLoadBehavior loadBehavior, - uint32_t tag, - AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context) - { - using namespace AzToolsFramework::Prefab::PrefabConversionUtils; - - auto&& [replacement, storedAliasType] = Internal::ApplyAlias(source, entityId, aliasType); - if (replacement) - { - AZ::Entity* result = replacement.get(); - target.GetEntities().push_back(AZStd::move(replacement)); - - EntityAliasStore store; - store.m_aliasType = storedAliasType; - store.m_source.emplace(source, entityId); - store.m_target.emplace(target, result->GetId()); - store.m_tag = tag; - store.m_loadBehavior = loadBehavior; - context.RegisterSpawnableEntityAlias(AZStd::move(store)); - - return result; - } - else - { - AZ_Assert(false, "A replacement for entity with id %zu could not be created.", static_cast(entityId)); - return nullptr; - } - } - uint32_t FindEntityIndex(AZ::EntityId entity, const AzFramework::Spawnable& spawnable) { auto begin = spawnable.GetEntities().begin(); diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/SpawnableUtils.h b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/SpawnableUtils.h index ea8a49857e..53d007c0c1 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/SpawnableUtils.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/Spawnable/SpawnableUtils.h @@ -12,7 +12,7 @@ #include #include #include -#include +#include namespace AZ { @@ -24,6 +24,11 @@ namespace AzToolsFramework::Prefab class Instance; } +namespace AzToolsFramework::Prefab::PrefabConversionUtils +{ + class PrefabProcessorContext; +} + namespace AzToolsFramework::Prefab::SpawnableUtils { static constexpr uint32_t InvalidEntityIndex = AZStd::numeric_limits::max(); @@ -41,24 +46,7 @@ namespace AzToolsFramework::Prefab::SpawnableUtils AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasSpawnableLoadBehavior loadBehavior, uint32_t tag, AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context); - AZ::Entity* CreateEntityAlias( - AZStd::string sourcePrefabName, - AzToolsFramework::Prefab::Instance& source, - AzFramework::Spawnable& target, - AZ::EntityId entityId, - AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasType aliasType, - AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasSpawnableLoadBehavior loadBehavior, - uint32_t tag, - AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context); - AZ::Entity* CreateEntityAlias( - AzFramework::Spawnable& source, - AzFramework::Spawnable& target, - AZ::EntityId entityId, - AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasType aliasType, - AzToolsFramework::Prefab::PrefabConversionUtils::EntityAliasSpawnableLoadBehavior loadBehavior, - uint32_t tag, - AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context); - + uint32_t FindEntityIndex(AZ::EntityId entity, const AzFramework::Spawnable& spawnable); void SortEntitiesByTransformHierarchy(AzFramework::Spawnable& spawnable); diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Slice/SliceUtilities.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Slice/SliceUtilities.cpp index c13f7dd848..93b1fce5b4 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Slice/SliceUtilities.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Slice/SliceUtilities.cpp @@ -2666,19 +2666,15 @@ namespace AzToolsFramework if (!isPathSafeForAssets) { // Put an error in the console, so the log files have info about this error, or the user can look up the error after dismissing it. - AZStd::string errorMessage = "You can save slices only to your game project folder or the Gems folder. Update the location and try again.\n\n" - "You can also review and update your save locations in the AssetProcessorPlatformConfig.ini file."; + AZStd::string errorMessage = "You can save slices only to your game project folder or the Gems folder. Update the location and try again.\n\n"; AZ_Error("Slice", false, errorMessage.c_str()); - QString learnMoreLink(QObject::tr("")); - QString learnMoreDescription(QObject::tr(" Learn more").arg(learnMoreLink)); - // Display a pop-up, the logs are easy to miss. This will make sure a user who encounters this error immediately knows their slice save has failed. QMessageBox msgBox(activeWindow); msgBox.setIcon(QMessageBox::Icon::Warning); msgBox.setTextFormat(Qt::RichText); msgBox.setWindowTitle(QObject::tr("Invalid save location")); - msgBox.setText(QString("%1 %2").arg(QObject::tr(errorMessage.c_str())).arg(learnMoreDescription)); + msgBox.setText(QString("%1").arg(QObject::tr(errorMessage.c_str()))); msgBox.setStandardButtons(QMessageBox::Cancel | QMessageBox::Retry); msgBox.setDefaultButton(QMessageBox::Retry); const int response = msgBox.exec(); @@ -2689,7 +2685,16 @@ namespace AzToolsFramework // so set the suggested save path to a known valid location. if (assetSafeFolders.size() > 0) { - retrySavePath = assetSafeFolders[0]; + QStringList strList = slicePath.split("/"); + if (strList.size() > 0) + { + retrySavePath = assetSafeFolders[0] + ("/" + strList[strList.size() - 1]).toUtf8().data(); + } + else + { + retrySavePath = assetSafeFolders[0]; + } + } return SliceSaveResult::Retry; case QMessageBox::Cancel: diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Logging/LogPanel_Panel.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Logging/LogPanel_Panel.cpp index ef8bf42713..a9449645c7 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Logging/LogPanel_Panel.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Logging/LogPanel_Panel.cpp @@ -840,8 +840,6 @@ namespace AzToolsFramework richLabel->setTextFormat(Qt::RichText); } - richLabel->setText(data); - richLabel->setGeometry(options.rect); richLabel->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::LinksAccessibleByMouse); richLabel->setPalette(options.palette); diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Outliner/EntityOutlinerListModel.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Outliner/EntityOutlinerListModel.cpp index 056f16c52f..e0060e2b42 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Outliner/EntityOutlinerListModel.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Outliner/EntityOutlinerListModel.cpp @@ -66,6 +66,7 @@ #include #include #include +#include //////////////////////////////////////////////////////////////////////////// // EntityOutlinerListModel @@ -259,17 +260,7 @@ namespace AzToolsFramework if (s_paintingName && !m_filterString.empty()) { // highlight characters in filter - int highlightTextIndex = 0; - do - { - highlightTextIndex = label.lastIndexOf(QString(m_filterString.c_str()), highlightTextIndex - 1, Qt::CaseInsensitive); - if (highlightTextIndex >= 0) - { - const QString BACKGROUND_COLOR{ "#707070" }; - label.insert(highlightTextIndex + static_cast(m_filterString.length()), ""); - label.insert(highlightTextIndex, ""); - } - } while(highlightTextIndex > 0); + label = AzToolsFramework::RichTextHighlighter::HighlightText(label, m_filterString.c_str()); } return label; } @@ -2375,23 +2366,8 @@ namespace AzToolsFramework optionV4.text.clear(); optionV4.widget->style()->drawControl(QStyle::CE_ItemViewItem, &optionV4, painter); - // Now we setup a Text Document so it can draw the rich text - QTextDocument textDoc; - textDoc.setDefaultFont(optionV4.font); - if (option.state & QStyle::State_Enabled) - { - textDoc.setDefaultStyleSheet("body {color: white}"); - } - else - { - textDoc.setDefaultStyleSheet("body {color: #7C7C7C}"); - } - textDoc.setHtml("" + entityNameRichText + ""); - painter->translate(textRect.topLeft()); - textDoc.setTextWidth(textRect.width()); - textDoc.drawContents(painter, QRectF(0, 0, textRect.width(), textRect.height())); + AzToolsFramework::RichTextHighlighter::PaintHighlightedRichText(entityNameRichText, painter, optionV4, textRect); - painter->restore(); EntityOutlinerListModel::s_paintingName = false; } diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Outliner/EntityOutlinerWidget.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Outliner/EntityOutlinerWidget.cpp index baf75eb978..c499d0f92f 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Outliner/EntityOutlinerWidget.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/Outliner/EntityOutlinerWidget.cpp @@ -1117,6 +1117,8 @@ namespace AzToolsFramework m_listModel->SearchStringChanged(filterString); m_proxyModel->UpdateFilter(); + + m_gui->m_objectTree->expandAll(); } void EntityOutlinerWidget::OnFilterChanged(const AzQtComponents::SearchTypeFilterList& activeTypeFilters) diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyIntCtrlCommon.h b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyIntCtrlCommon.h index bb7d03367b..ed428eeac5 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyIntCtrlCommon.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyIntCtrlCommon.h @@ -14,6 +14,7 @@ #include #include #include +#include namespace AzToolsFramework { @@ -92,25 +93,11 @@ namespace AzToolsFramework { toolTipString += "\n"; } - toolTipString += "["; - if (propertyControl->minimum() <= aznumeric_cast(QtWidgetLimits::Min())) - { - toolTipString += "-" + QObject::tr(PropertyQTConstant_InfinityString); - } - else - { - toolTipString += QString::number(propertyControl->minimum()); - } - toolTipString += ", "; - if (propertyControl->maximum() >= aznumeric_cast(QtWidgetLimits::Max())) - { - toolTipString += QObject::tr(PropertyQTConstant_InfinityString); - } - else - { - toolTipString += QString::number(propertyControl->maximum()); - } - toolTipString += "]"; + + const QString minString = QLocale().toString(propertyControl->minimum()); + const QString maxString = QLocale().toString(propertyControl->maximum()); + toolTipString += QString("[%1, %2]").arg(minString).arg(maxString); + return true; } return false; @@ -128,16 +115,11 @@ namespace AzToolsFramework { toolTipString += "\n"; } - toolTipString += "[" + QString::number(propertyControl->minimum()) + ", "; - if (propertyControl->maximum() >= aznumeric_cast(QtWidgetLimits::Max())) - { - toolTipString += QObject::tr(PropertyQTConstant_InfinityString); - } - else - { - toolTipString += QString::number(propertyControl->maximum()); - } - toolTipString += "]"; + + const QString minString = QLocale().toString(propertyControl->minimum()); + const QString maxString = QLocale().toString(propertyControl->maximum()); + toolTipString += QString("[%1, %2]").arg(minString).arg(maxString); + return true; } return false; @@ -196,7 +178,7 @@ namespace AzToolsFramework } else { - AZ_WarningOnce("AzToolsFramework", false, "Property %s: 'Min' attribute from property '%s' into widget", debugName); + AZ_WarningOnce("AzToolsFramework", false, "Failed to read 'Min' attribute from property '%s' into widget", debugName); } } else if (attrib == AZ::Edit::Attributes::Max) diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyRowWidget.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyRowWidget.cpp index bb2d2851ca..e895456151 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyRowWidget.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/UI/PropertyEditor/PropertyRowWidget.cpp @@ -421,6 +421,7 @@ namespace AzToolsFramework { QString label{ text }; m_nameLabel->setText(label); + m_nameLabel->setOpenExternalLinks(true); m_nameLabel->setVisible(!label.isEmpty()); // setting the stretches to 0 in case of an empty label really hides the label (i.e. even the reserved space) m_mainLayout->setStretch(0, label.isEmpty() ? 0 : LabelColumnStretch); diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/UnitTest/AzToolsFrameworkTestHelpers.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/UnitTest/AzToolsFrameworkTestHelpers.cpp index 4f952a3edc..7f877facb6 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/UnitTest/AzToolsFrameworkTestHelpers.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/UnitTest/AzToolsFrameworkTestHelpers.cpp @@ -30,8 +30,7 @@ namespace UnitTest void MousePressAndMove( QWidget* widget, const QPoint& initialPositionWidget, const QPoint& mouseDelta, const Qt::MouseButton mouseButton) { - QPoint position = widget->mapToGlobal(initialPositionWidget); - QTest::mousePress(widget, mouseButton, Qt::NoModifier, position); + QTest::mousePress(widget, mouseButton, Qt::NoModifier, initialPositionWidget); MouseMove(widget, initialPositionWidget, mouseDelta, mouseButton); } @@ -45,14 +44,15 @@ namespace UnitTest // - https://lists.qt-project.org/pipermail/development/2019-July/036873.html void MouseMove(QWidget* widget, const QPoint& initialPositionWidget, const QPoint& mouseDelta, const Qt::MouseButton mouseButton) { - QPoint nextPosition = widget->mapToGlobal(initialPositionWidget + mouseDelta); + const QPoint nextLocalPosition = initialPositionWidget + mouseDelta; + const QPoint nextGlobalPosition = widget->mapToGlobal(nextLocalPosition); // ^1 To ensure a mouse move event is fired we must call the test mouse move function // and also send a mouse move event that matches. Each on their own do not appear to // work - please see the links above for more context. - QTest::mouseMove(widget, nextPosition); + QTest::mouseMove(widget, nextLocalPosition); QMouseEvent mouseMoveEvent( - QEvent::MouseMove, QPointF(nextPosition), QPointF(nextPosition), Qt::NoButton, mouseButton, Qt::NoModifier); + QEvent::MouseMove, QPointF(nextLocalPosition), QPointF(nextGlobalPosition), Qt::NoButton, mouseButton, Qt::NoModifier); QApplication::sendEvent(widget, &mouseMoveEvent); } @@ -157,6 +157,23 @@ namespace UnitTest return QWidget::event(event); } + MouseMoveDetector::MouseMoveDetector(QWidget* parent) + : QObject(parent) + { + } + + bool MouseMoveDetector::eventFilter(QObject* watched, QEvent* event) + { + if (const auto eventType = event->type(); eventType == QEvent::Type::MouseMove) + { + auto mouseEvent = static_cast(event); + m_mouseGlobalPosition = mouseEvent->globalPos(); + m_mouseLocalPosition = mouseEvent->pos(); + } + + return QObject::eventFilter(watched, event); + } + void TestEditorActions::Connect() { using AzToolsFramework::GetEntityContextId; @@ -571,3 +588,5 @@ namespace UnitTest sliceAssets.clear(); } } // namespace UnitTest + +#include diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/UnitTest/AzToolsFrameworkTestHelpers.h b/Code/Framework/AzToolsFramework/AzToolsFramework/UnitTest/AzToolsFrameworkTestHelpers.h index 79a87391b4..2c60ca914c 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/UnitTest/AzToolsFrameworkTestHelpers.h +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/UnitTest/AzToolsFrameworkTestHelpers.h @@ -111,10 +111,29 @@ namespace UnitTest { Q_OBJECT public: - FocusInteractionWidget(QWidget* parent = nullptr) : QWidget(parent) {} + FocusInteractionWidget(QWidget* parent = nullptr) + : QWidget(parent) + { + } + bool event(QEvent* event) override; }; + /// Records mouse move events and stores the local and global position of the cursor. + /// @note To use, install as an event filter for the widget being interacted with + /// e.g. m_testWidget->installEventFilter(&m_mouseMoveDetector); + class MouseMoveDetector : public QObject + { + Q_OBJECT + public: + MouseMoveDetector(QWidget* parent = nullptr); + + bool eventFilter([[maybe_unused]] QObject* watched, QEvent* event) override; + + QPoint m_mouseGlobalPosition; + QPoint m_mouseLocalPosition; + }; + /// Stores actions registered for either normal mode (regular viewport) editing and /// component mode editing. class TestEditorActions diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_files.cmake b/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_files.cmake index 2c25cc9222..0d7bf05211 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_files.cmake +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/aztoolsframework_files.cmake @@ -123,6 +123,8 @@ set(FILES ContainerEntity/ContainerEntitySystemComponent.h Editor/EditorContextMenuBus.h Editor/EditorSettingsAPIBus.h + Editor/RichTextHighlighter.h + Editor/RichTextHighlighter.cpp Entity/EditorEntityStartStatus.h Entity/EditorEntityAPIBus.h Entity/EditorEntityContextComponent.cpp @@ -723,6 +725,7 @@ set(FILES Prefab/Spawnable/EditorOnlyEntityHandler/UiEditorOnlyEntityHandler.cpp Prefab/Spawnable/EditorOnlyEntityHandler/WorldEditorOnlyEntityHandler.h Prefab/Spawnable/EditorOnlyEntityHandler/WorldEditorOnlyEntityHandler.cpp + Prefab/Spawnable/EntityAliasTypes.h Prefab/Spawnable/InMemorySpawnableAssetContainer.h Prefab/Spawnable/InMemorySpawnableAssetContainer.cpp Prefab/Spawnable/PrefabCatchmentProcessor.h @@ -730,6 +733,9 @@ set(FILES Prefab/Spawnable/PrefabConversionPipeline.h Prefab/Spawnable/PrefabConversionPipeline.cpp Prefab/Spawnable/PrefabConverterStackProfileNames.h + Prefab/Spawnable/PrefabDocument.h + Prefab/Spawnable/PrefabDocument.inl + Prefab/Spawnable/PrefabDocument.cpp Prefab/Spawnable/ProcesedObjectStore.h Prefab/Spawnable/ProcesedObjectStore.cpp Prefab/Spawnable/PrefabProcessor.h diff --git a/Code/Framework/AzToolsFramework/Tests/AzToolsFrameworkTestHelpersTest.cpp b/Code/Framework/AzToolsFramework/Tests/AzToolsFrameworkTestHelpersTest.cpp new file mode 100644 index 0000000000..2a1254f2e9 --- /dev/null +++ b/Code/Framework/AzToolsFramework/Tests/AzToolsFrameworkTestHelpersTest.cpp @@ -0,0 +1,88 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include + +#include +#include + +namespace UnitTest +{ + class AzToolsFrameworkTestHelpersFixture : public AllocatorsTestFixture + { + public: + void SetUp() override + { + AllocatorsTestFixture::SetUp(); + + m_rootWidget = AZStd::make_unique(); + m_rootWidget->setFixedSize(0, 0); + m_rootWidget->setMouseTracking(true); + m_rootWidget->move(0, 0); // explicitly set the widget to be in the upper left corner + + m_mouseMoveDetector = AZStd::make_unique(); + m_rootWidget->installEventFilter(m_mouseMoveDetector.get()); + } + + void TearDown() override + { + m_rootWidget->removeEventFilter(m_mouseMoveDetector.get()); + m_rootWidget.reset(); + m_mouseMoveDetector.reset(); + + AllocatorsTestFixture::TearDown(); + } + + AZStd::unique_ptr m_rootWidget; + AZStd::unique_ptr m_mouseMoveDetector; + }; + + struct MouseMoveParams + { + QSize m_widgetSize; + QPoint m_widgetPosition; + QPoint m_localCursorPosition; + QPoint m_cursorDelta; + }; + + class MouseMoveAzToolsFrameworkTestHelperFixture + : public AzToolsFrameworkTestHelpersFixture + , public ::testing::WithParamInterface + { + }; + + TEST_P(MouseMoveAzToolsFrameworkTestHelperFixture, MouseMoveCorrectlyTransformsCursorPositionInGlobalAndLocalSpace) + { + // given + const MouseMoveParams mouseMoveParams = GetParam(); + m_rootWidget->move(mouseMoveParams.m_widgetPosition); + m_rootWidget->setFixedSize(mouseMoveParams.m_widgetSize); + + // when + MouseMove(m_rootWidget.get(), mouseMoveParams.m_localCursorPosition, mouseMoveParams.m_cursorDelta); + + // then + const QPoint mouseLocalPosition = m_mouseMoveDetector->m_mouseLocalPosition; + const QPoint mouseLocalPositionFromGlobal = m_rootWidget->mapFromGlobal(m_mouseMoveDetector->m_mouseGlobalPosition); + const QPoint expectedPosition = mouseMoveParams.m_localCursorPosition + mouseMoveParams.m_cursorDelta; + + using ::testing::Eq; + EXPECT_THAT(mouseLocalPosition.x(), Eq(expectedPosition.x())); + EXPECT_THAT(mouseLocalPosition.y(), Eq(expectedPosition.y())); + EXPECT_THAT(mouseLocalPositionFromGlobal.x(), Eq(expectedPosition.x())); + EXPECT_THAT(mouseLocalPositionFromGlobal.y(), Eq(expectedPosition.y())); + } + + INSTANTIATE_TEST_CASE_P( + All, + MouseMoveAzToolsFrameworkTestHelperFixture, + testing::Values( + MouseMoveParams{ QSize(100, 100), QPoint(0, 0), QPoint(0, 0), QPoint(10, 10) }, + MouseMoveParams{ QSize(100, 100), QPoint(100, 100), QPoint(0, 0), QPoint(10, 10) }, + MouseMoveParams{ QSize(100, 100), QPoint(20, 20), QPoint(50, 50), QPoint(20, 20) })); +} // namespace UnitTest diff --git a/Code/Framework/AzToolsFramework/Tests/Prefab/Benchmark/Spawnable/SpawnAllEntitiesBenchmarks.cpp b/Code/Framework/AzToolsFramework/Tests/Prefab/Benchmark/Spawnable/SpawnAllEntitiesBenchmarks.cpp index ecbbe10c39..ba0c3a4838 100644 --- a/Code/Framework/AzToolsFramework/Tests/Prefab/Benchmark/Spawnable/SpawnAllEntitiesBenchmarks.cpp +++ b/Code/Framework/AzToolsFramework/Tests/Prefab/Benchmark/Spawnable/SpawnAllEntitiesBenchmarks.cpp @@ -25,7 +25,7 @@ namespace Benchmark for (auto _ : state) { state.PauseTiming(); - m_spawnTicket = new AzFramework::EntitySpawnTicket(m_spawnableAsset); + m_spawnTicket = aznew AzFramework::EntitySpawnTicket(m_spawnableAsset); state.ResumeTiming(); for (uint64_t spwanableCounter = 0; spwanableCounter < spawnAllEntitiesCallCount; spwanableCounter++) @@ -62,7 +62,7 @@ namespace Benchmark for (auto _ : state) { state.PauseTiming(); - m_spawnTicket = new AzFramework::EntitySpawnTicket(m_spawnableAsset); + m_spawnTicket = aznew AzFramework::EntitySpawnTicket(m_spawnableAsset); state.ResumeTiming(); AzFramework::SpawnableEntitiesInterface::Get()->SpawnAllEntities(*m_spawnTicket); @@ -93,15 +93,16 @@ namespace Benchmark SetUpSpawnableAsset(entityCountInSpawnable); + auto spawner = AzFramework::SpawnableEntitiesInterface::Get(); for (auto _ : state) { state.PauseTiming(); - m_spawnTicket = new AzFramework::EntitySpawnTicket(m_spawnableAsset); + m_spawnTicket = aznew AzFramework::EntitySpawnTicket(m_spawnableAsset); state.ResumeTiming(); for (uint64_t spawnCallCounter = 0; spawnCallCounter < spawnCallCount; spawnCallCounter++) { - AzFramework::SpawnableEntitiesInterface::Get()->SpawnAllEntities(*m_spawnTicket); + spawner->SpawnAllEntities(*m_spawnTicket); } m_rootSpawnableInterface->ProcessSpawnableQueue(); diff --git a/Code/Framework/AzToolsFramework/Tests/Prefab/PrefabUndoLinkTests.cpp b/Code/Framework/AzToolsFramework/Tests/Prefab/PrefabUndoLinkTests.cpp index 8fafe1f177..442894c101 100644 --- a/Code/Framework/AzToolsFramework/Tests/Prefab/PrefabUndoLinkTests.cpp +++ b/Code/Framework/AzToolsFramework/Tests/Prefab/PrefabUndoLinkTests.cpp @@ -170,7 +170,14 @@ namespace UnitTest m_instanceUpdateExecutorInterface->UpdateTemplateInstancesInQueue(); //instantiate a new nested instance - nestedInstance = m_prefabSystemComponent->InstantiatePrefab(nestedTemplateId); + nestedInstance = m_prefabSystemComponent->InstantiatePrefab( + nestedTemplateId, AZStd::nullopt, + [](const AzToolsFramework::EntityList& entities) + { + AzToolsFramework::EditorEntityContextRequestBus::Broadcast( + &AzToolsFramework::EditorEntityContextRequests::HandleEntitiesAdded, entities); + }); + nestedContainerEntityId = nestedInstance->GetContainerEntityId(); AZ::ComponentApplicationBus::BroadcastResult(nestedContainerEntity, &AZ::ComponentApplicationBus::Events::FindEntity, nestedContainerEntityId); ASSERT_TRUE(nestedContainerEntity); @@ -198,7 +205,13 @@ namespace UnitTest LinkId linkId = undoInstanceLinkNode.GetLinkId(); - rootInstance = m_prefabSystemComponent->InstantiatePrefab(rootTemplateId); + rootInstance = m_prefabSystemComponent->InstantiatePrefab( + rootTemplateId, AZStd::nullopt, + [](const AzToolsFramework::EntityList& entities) + { + AzToolsFramework::EditorEntityContextRequestBus::Broadcast( + &AzToolsFramework::EditorEntityContextRequests::HandleEntitiesAdded, entities); + }); aliases = rootInstance->GetNestedInstanceAliases(nestedTemplateId); //verify the link was created @@ -228,7 +241,13 @@ namespace UnitTest m_instanceUpdateExecutorInterface->UpdateTemplateInstancesInQueue(); //verify the update worked - rootInstance = m_prefabSystemComponent->InstantiatePrefab(rootTemplateId); + rootInstance = m_prefabSystemComponent->InstantiatePrefab( + rootTemplateId, AZStd::nullopt, + [](const AzToolsFramework::EntityList& entities) + { + AzToolsFramework::EditorEntityContextRequestBus::Broadcast( + &AzToolsFramework::EditorEntityContextRequests::HandleEntitiesAdded, entities); + }); aliases = rootInstance->GetNestedInstanceAliases(nestedTemplateId); nestedInstanceRef = rootInstance->FindNestedInstance(aliases[0]); nestedContainerEntityId = nestedInstanceRef->get().GetContainerEntityId(); @@ -244,7 +263,13 @@ namespace UnitTest m_instanceUpdateExecutorInterface->UpdateTemplateInstancesInQueue(); //verify the undo update worked - rootInstance = m_prefabSystemComponent->InstantiatePrefab(rootTemplateId); + rootInstance = m_prefabSystemComponent->InstantiatePrefab( + rootTemplateId, AZStd::nullopt, + [](const AzToolsFramework::EntityList& entities) + { + AzToolsFramework::EditorEntityContextRequestBus::Broadcast( + &AzToolsFramework::EditorEntityContextRequests::HandleEntitiesAdded, entities); + }); aliases = rootInstance->GetNestedInstanceAliases(nestedTemplateId); nestedInstanceRef = rootInstance->FindNestedInstance(aliases[0]); nestedContainerEntityId = nestedInstanceRef->get().GetContainerEntityId(); @@ -259,7 +284,13 @@ namespace UnitTest undoLinkUpdateNode.Redo(); m_instanceUpdateExecutorInterface->UpdateTemplateInstancesInQueue(); - rootInstance = m_prefabSystemComponent->InstantiatePrefab(rootTemplateId); + rootInstance = m_prefabSystemComponent->InstantiatePrefab( + rootTemplateId, AZStd::nullopt, + [](const AzToolsFramework::EntityList& entities) + { + AzToolsFramework::EditorEntityContextRequestBus::Broadcast( + &AzToolsFramework::EditorEntityContextRequests::HandleEntitiesAdded, entities); + }); aliases = rootInstance->GetNestedInstanceAliases(nestedTemplateId); nestedInstanceRef = rootInstance->FindNestedInstance(aliases[0]); nestedContainerEntityId = nestedInstanceRef->get().GetContainerEntityId(); @@ -287,7 +318,13 @@ namespace UnitTest m_instanceUpdateExecutorInterface->UpdateTemplateInstancesInQueue(); //verify the update worked - rootInstance = m_prefabSystemComponent->InstantiatePrefab(rootTemplateId); + rootInstance = m_prefabSystemComponent->InstantiatePrefab( + rootTemplateId, AZStd::nullopt, + [](const AzToolsFramework::EntityList& entities) + { + AzToolsFramework::EditorEntityContextRequestBus::Broadcast( + &AzToolsFramework::EditorEntityContextRequests::HandleEntitiesAdded, entities); + }); aliases = rootInstance->GetNestedInstanceAliases(nestedTemplateId); nestedInstanceRef = rootInstance->FindNestedInstance(aliases[0]); nestedContainerEntityId = nestedInstanceRef->get().GetContainerEntityId(); diff --git a/Code/Framework/AzToolsFramework/Tests/Prefab/PrefabUndoTests.cpp b/Code/Framework/AzToolsFramework/Tests/Prefab/PrefabUndoTests.cpp index 5c68b30e8f..cfba41696c 100644 --- a/Code/Framework/AzToolsFramework/Tests/Prefab/PrefabUndoTests.cpp +++ b/Code/Framework/AzToolsFramework/Tests/Prefab/PrefabUndoTests.cpp @@ -79,7 +79,14 @@ namespace UnitTest // verify template updated correctly //instantiate second instance for checking if propogation works - AZStd::unique_ptr secondInstance = m_prefabSystemComponent->InstantiatePrefab(templateId); + AZStd::unique_ptr secondInstance = m_prefabSystemComponent->InstantiatePrefab( + templateId, AZStd::nullopt, + [](const AzToolsFramework::EntityList& entities) + { + AzToolsFramework::EditorEntityContextRequestBus::Broadcast( + &AzToolsFramework::EditorEntityContextRequests::HandleEntitiesAdded, entities); + }); + ASSERT_TRUE(secondInstance); ValidateInstanceEntitiesActive(*secondInstance); diff --git a/Code/Framework/AzToolsFramework/Tests/Prefab/SpawnableRemoveEditorInfoTestFixture.cpp b/Code/Framework/AzToolsFramework/Tests/Prefab/SpawnableRemoveEditorInfoTestFixture.cpp index b8ce3c7c42..0d75227e38 100644 --- a/Code/Framework/AzToolsFramework/Tests/Prefab/SpawnableRemoveEditorInfoTestFixture.cpp +++ b/Code/Framework/AzToolsFramework/Tests/Prefab/SpawnableRemoveEditorInfoTestFixture.cpp @@ -9,6 +9,7 @@ #include #include +#include #include #include #include @@ -201,15 +202,14 @@ namespace UnitTest { ConvertSourceEntitiesToPrefab(); + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabDocument prefab("Test"); + prefab.SetPrefabDom(m_prefabDom); const bool actualResult = - m_editorInfoRemover.RemoveEditorInfo(m_prefabDom, m_serializeContext, m_prefabProcessorContext).IsSuccess(); + m_editorInfoRemover.RemoveEditorInfo(prefab, m_serializeContext, m_prefabProcessorContext).IsSuccess(); EXPECT_EQ(expectedResult, actualResult); - AZStd::unique_ptr convertedInstance(aznew Instance()); - ASSERT_TRUE(AzToolsFramework::Prefab::PrefabDomUtils::LoadInstanceFromPrefabDom(*convertedInstance, m_prefabDom)); - - convertedInstance->DetachAllEntitiesInHierarchy( + prefab.GetInstance().DetachAllEntitiesInHierarchy( [this](AZStd::unique_ptr entity) { m_runtimeEntities.emplace_back(entity.release()); diff --git a/Code/Framework/AzToolsFramework/Tests/PropertyIntCtrlCommonTests.h b/Code/Framework/AzToolsFramework/Tests/PropertyIntCtrlCommonTests.h index 712eeb99b7..b73e9e0a26 100644 --- a/Code/Framework/AzToolsFramework/Tests/PropertyIntCtrlCommonTests.h +++ b/Code/Framework/AzToolsFramework/Tests/PropertyIntCtrlCommonTests.h @@ -83,18 +83,6 @@ namespace UnitTest widget->setMaximum(widget->maximum() - 1); } - static std::string GetToolTipStringAtLimits() - { - if constexpr (std::is_signed::value) - { - return "[-INF, INF]"; - } - else - { - return "[0, INF]"; - } - } - void PropertyCtrlHandlersCreated() { using ::testing::Ne; @@ -125,11 +113,13 @@ namespace UnitTest auto& widget = m_widget; auto& handler = m_handler; QString tooltip; - std::string expected; // Retrieve the tooltip string for this widget auto success = handler->ModifyTooltip(widget, tooltip); - expected = GetToolTipStringAtLimits(); + + const QString minString = QLocale().toString(widget->minimum()); + const QString maxString = QLocale().toString(widget->maximum()); + const AZStd::string expected = AZStd::string::format("[%s, %s]", minString.toStdString().c_str(), maxString.toStdString().c_str()); // Expect the operation to be successful and a valid limit tooltip string generated EXPECT_TRUE(success); @@ -142,18 +132,21 @@ namespace UnitTest auto& widget = m_widget; auto& handler = m_handler; QString tooltip; - std::stringstream expected; // That is not at the extremeties of the type range limit SetWidgetRangeToNonExtremeties(widget); // Retrieve the tooltip string for this widget auto success = handler->ModifyTooltip(widget, tooltip); - expected << "[" << widget->minimum() << ", " << widget->maximum() << "]"; + + const QString minString = QLocale().toString(widget->minimum()); + const QString maxString = QLocale().toString(widget->maximum()); + + const AZStd::string expected = AZStd::string::format("[%s, %s]", minString.toStdString().c_str(), maxString.toStdString().c_str()); // Expect the operation to be successful and a valid less than limit tooltip string generated EXPECT_TRUE(success); - EXPECT_STREQ(tooltip.toStdString().c_str(), expected.str().c_str()); + EXPECT_STREQ(tooltip.toStdString().c_str(), expected.c_str()); } void EmitWidgetValueChanged() diff --git a/Code/Framework/AzToolsFramework/Tests/SpinBoxTests.cpp b/Code/Framework/AzToolsFramework/Tests/SpinBoxTests.cpp index 2d524cbcf4..f885240fde 100644 --- a/Code/Framework/AzToolsFramework/Tests/SpinBoxTests.cpp +++ b/Code/Framework/AzToolsFramework/Tests/SpinBoxTests.cpp @@ -275,7 +275,7 @@ namespace UnitTest QString testString = "0" + QString(testLocale.decimalPoint()) + "9999999"; QString value = setupTruncationTest(testString); - testString = "0" + QString(testLocale.decimalPoint()) + "999"; + testString = "1" + QString(testLocale.decimalPoint()) + "0"; EXPECT_TRUE(value == testString); } @@ -295,19 +295,19 @@ namespace UnitTest QString testString = "0" + QString(testLocale.decimalPoint()) + "12395"; QString value = setupTruncationTest(testString); - testString = "0" + QString(testLocale.decimalPoint()) + "123"; + testString = "0" + QString(testLocale.decimalPoint()) + "124"; EXPECT_TRUE(value == testString); testString = "0" + QString(testLocale.decimalPoint()) + "94496"; value = setupTruncationTest(testString); - testString = "0" + QString(testLocale.decimalPoint()) + "944"; + testString = "0" + QString(testLocale.decimalPoint()) + "945"; EXPECT_TRUE(value == testString); testString = "0" + QString(testLocale.decimalPoint()) + "0009999"; value = setupTruncationTest(testString); - testString = "0" + QString(testLocale.decimalPoint()) + "0"; + testString = "0" + QString(testLocale.decimalPoint()) + "001"; EXPECT_TRUE(value == testString); } diff --git a/Code/Framework/AzToolsFramework/Tests/UI/AssetBrowserTests.cpp b/Code/Framework/AzToolsFramework/Tests/UI/AssetBrowserTests.cpp index ae5ea5f0ae..5173e40c63 100644 --- a/Code/Framework/AzToolsFramework/Tests/UI/AssetBrowserTests.cpp +++ b/Code/Framework/AzToolsFramework/Tests/UI/AssetBrowserTests.cpp @@ -74,10 +74,6 @@ namespace UnitTest AZStd::unique_ptr m_filterModel; AZStd::unique_ptr m_tableModel; - AZStd::unique_ptr m_modelTesterAssetBrowser; - AZStd::unique_ptr m_modelTesterFilterModel; - AZStd::unique_ptr m_modelTesterTableModel; - QVector m_folderIds = { 13, 14, 15 }; QVector m_sourceIDs = { 1, 2, 3, 4, 5 }; QVector m_productIDs = { 1, 2, 3, 4, 5 }; @@ -96,9 +92,6 @@ namespace UnitTest m_filterModel->setSourceModel(m_assetBrowserComponent->GetAssetBrowserModel()); m_tableModel->setSourceModel(m_filterModel.get()); - m_modelTesterAssetBrowser = AZStd::make_unique(m_assetBrowserComponent->GetAssetBrowserModel()); - m_modelTesterFilterModel = AZStd::make_unique(m_filterModel.get()); - m_modelTesterTableModel = AZStd::make_unique(m_tableModel.get()); m_searchWidget = AZStd::make_unique(); // Setup String filters @@ -110,10 +103,6 @@ namespace UnitTest void AssetBrowserTest::TearDownEditorFixtureImpl() { - m_modelTesterAssetBrowser.reset(); - m_modelTesterFilterModel.reset(); - m_modelTesterTableModel.reset(); - m_tableModel.reset(); m_filterModel.reset(); m_assetBrowserComponent->Deactivate(); diff --git a/Code/Framework/AzToolsFramework/Tests/aztoolsframeworktests_files.cmake b/Code/Framework/AzToolsFramework/Tests/aztoolsframeworktests_files.cmake index 9a1f61ab56..2631a84325 100644 --- a/Code/Framework/AzToolsFramework/Tests/aztoolsframeworktests_files.cmake +++ b/Code/Framework/AzToolsFramework/Tests/aztoolsframeworktests_files.cmake @@ -12,6 +12,7 @@ set(FILES AssetFileInfoListComparison.cpp AssetSeedManager.cpp AssetSystemMocks.h + AzToolsFrameworkTestHelpersTest.cpp BoundsTestComponent.cpp BoundsTestComponent.h ComponentAdapterTests.cpp diff --git a/Code/Framework/GridMate/CMakeLists.txt b/Code/Framework/GridMate/CMakeLists.txt index 0da878081d..07c2f8b4a8 100644 --- a/Code/Framework/GridMate/CMakeLists.txt +++ b/Code/Framework/GridMate/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) +set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) ly_add_target( NAME GridMate STATIC @@ -41,7 +41,7 @@ ly_add_source_properties( ################################################################################ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) - ly_get_list_relative_pal_filename(pal_test_dir ${CMAKE_CURRENT_LIST_DIR}/Tests/Platform/${PAL_PLATFORM_NAME}) + o3de_pal_dir(pal_test_dir ${CMAKE_CURRENT_LIST_DIR}/Tests/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME GridMate.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} NAMESPACE AZ diff --git a/Code/LauncherUnified/CMakeLists.txt b/Code/LauncherUnified/CMakeLists.txt index 845c2cd6c7..8097570462 100644 --- a/Code/LauncherUnified/CMakeLists.txt +++ b/Code/LauncherUnified/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/LauncherUnified_traits_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/Code/LauncherUnified/Launcher.cpp b/Code/LauncherUnified/Launcher.cpp index ed01a67f39..9dfd6213c4 100644 --- a/Code/LauncherUnified/Launcher.cpp +++ b/Code/LauncherUnified/Launcher.cpp @@ -229,33 +229,65 @@ namespace O3DELauncher void CreateRemoteFileIO(); - bool ConnectToAssetProcessor() + // This function make sure the launcher has signaled the "CriticalAssetsCompiled" + // lifecycle event as well as to load the "assetcatalog.xml" file if it exists + void CompileCriticalAssets() { - bool connectedToAssetProcessor{}; - // When the AssetProcessor is already launched it should take less than a second to perform a connection - // but when the AssetProcessor needs to be launch it could take up to 15 seconds to have the AssetProcessor initialize - // and able to negotiate a connection when running a debug build - // and to negotiate a connection - // Setting the connectTimeout to 3 seconds if not set within the settings registry - - AzFramework::AssetSystem::ConnectionSettings connectionSettings; - AzFramework::AssetSystem::ReadConnectionSettingsFromSettingsRegistry(connectionSettings); - - connectionSettings.m_launchAssetProcessorOnFailedConnection = true; - connectionSettings.m_connectionIdentifier = AzFramework::AssetSystem::ConnectionIdentifiers::Game; - connectionSettings.m_loggingCallback = []([[maybe_unused]] AZStd::string_view logData) + if (auto settingsRegistry = AZ::SettingsRegistry::Get(); settingsRegistry != nullptr) { - AZ_TracePrintf("Launcher", "%.*s", aznumeric_cast(logData.size()), logData.data()); - }; - - AzFramework::AssetSystemRequestBus::BroadcastResult(connectedToAssetProcessor, &AzFramework::AssetSystemRequestBus::Events::EstablishAssetProcessorConnection, connectionSettings); + AZ::ComponentApplicationLifecycle::SignalEvent(*settingsRegistry, "CriticalAssetsCompiled", R"({})"); + // Reload the assetcatalog.xml at this point again + // Start Monitoring Asset changes over the network and load the AssetCatalog + auto LoadCatalog = [settingsRegistry](AZ::Data::AssetCatalogRequests* assetCatalogRequests) + { + if (AZ::IO::FixedMaxPath assetCatalogPath; + settingsRegistry->Get(assetCatalogPath.Native(), AZ::SettingsRegistryMergeUtils::FilePathKey_CacheRootFolder)) + { + assetCatalogPath /= "assetcatalog.xml"; + assetCatalogRequests->LoadCatalog(assetCatalogPath.c_str()); + } + }; + AZ::Data::AssetCatalogRequestBus::Broadcast(AZStd::move(LoadCatalog)); + } + } - if (connectedToAssetProcessor) + // If the connect option is false, this function will return true + // to make sure the Launcher passes the connected to AP check + // If REMOTE_ASSET_PROCESSOR is not defined, then the launcher doesn't need + // to connect to the AssetProcessor and therefore this function returns true + bool ConnectToAssetProcessor([[maybe_unused]] bool connect) + { + bool connectedToAssetProcessor = true; +#if defined(REMOTE_ASSET_PROCESSOR) + if (connect) { - AZ_TracePrintf("Launcher", "Connected to Asset Processor\n"); - CreateRemoteFileIO(); + // When the AssetProcessor is already launched it should take less than a second to perform a connection + // but when the AssetProcessor needs to be launch it could take up to 15 seconds to have the AssetProcessor initialize + // and able to negotiate a connection when running a debug build + // and to negotiate a connection + // Setting the connectTimeout to 3 seconds if not set within the settings registry + + AzFramework::AssetSystem::ConnectionSettings connectionSettings; + AzFramework::AssetSystem::ReadConnectionSettingsFromSettingsRegistry(connectionSettings); + + connectionSettings.m_launchAssetProcessorOnFailedConnection = true; + connectionSettings.m_connectionIdentifier = AzFramework::AssetSystem::ConnectionIdentifiers::Game; + connectionSettings.m_loggingCallback = []([[maybe_unused]] AZStd::string_view logData) + { + AZ_TracePrintf("Launcher", "%.*s", aznumeric_cast(logData.size()), logData.data()); + }; + + AzFramework::AssetSystemRequestBus::BroadcastResult(connectedToAssetProcessor, &AzFramework::AssetSystemRequestBus::Events::EstablishAssetProcessorConnection, connectionSettings); + + if (connectedToAssetProcessor) + { + AZ_TracePrintf("Launcher", "Connected to Asset Processor\n"); + CreateRemoteFileIO(); + } } +#endif + CompileCriticalAssets(); return connectedToAssetProcessor; } @@ -403,25 +435,21 @@ namespace O3DELauncher gameApplication.Start({}, gameApplicationStartupParams); -#if defined(REMOTE_ASSET_PROCESSOR) - bool allowedEngineConnection = !systemInitParams.bToolMode && !systemInitParams.bTestMode && bg_ConnectToAssetProcessor; //connect to the asset processor using the bootstrap values - if (allowedEngineConnection) + const bool allowedEngineConnection = !systemInitParams.bToolMode && !systemInitParams.bTestMode && bg_ConnectToAssetProcessor; + if (!ConnectToAssetProcessor(allowedEngineConnection)) { - if (!ConnectToAssetProcessor()) + AZ::s64 waitForConnect{}; + AZ::SettingsRegistryMergeUtils::PlatformGet(*settingsRegistry, waitForConnect, + AZ::SettingsRegistryMergeUtils::BootstrapSettingsRootKey, "wait_for_connect"); + if (waitForConnect != 0) { - AZ::s64 waitForConnect{}; - AZ::SettingsRegistryMergeUtils::PlatformGet(*settingsRegistry, waitForConnect, - AZ::SettingsRegistryMergeUtils::BootstrapSettingsRootKey, "wait_for_connect"); - if (waitForConnect != 0) - { - AZ_Error("Launcher", false, "Failed to connect to AssetProcessor."); - return ReturnCode::ErrAssetProccessor; - } + AZ_Error("Launcher", false, "Failed to connect to AssetProcessor."); + return ReturnCode::ErrAssetProccessor; } } -#endif + AZ_Assert(AZ::AllocatorInstance::IsReady(), "System allocator was not created or creation failed."); //Initialize the Debug trace instance to create necessary environment variables AZ::Debug::Trace::Instance().Init(); diff --git a/Code/LauncherUnified/launcher_generator.cmake b/Code/LauncherUnified/launcher_generator.cmake index 550a67bc49..70bcf776af 100644 --- a/Code/LauncherUnified/launcher_generator.cmake +++ b/Code/LauncherUnified/launcher_generator.cmake @@ -201,7 +201,7 @@ function(ly_delayed_generate_static_modules_inl) foreach(game_gem_dependency ${all_game_gem_dependencies}) # Sometimes, a gem's Client variant may be an interface library - # which dependes on multiple gem targets. The interface libraries + # which depends on multiple gem targets. The interface libraries # should be skipped; the real dependencies of the interface will be processed if(TARGET ${game_gem_dependency}) get_target_property(target_type ${game_gem_dependency} TYPE) diff --git a/Code/Legacy/CryCommon/CMakeLists.txt b/Code/Legacy/CryCommon/CMakeLists.txt index 1556c6a099..629f26d217 100644 --- a/Code/Legacy/CryCommon/CMakeLists.txt +++ b/Code/Legacy/CryCommon/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME CryCommon STATIC diff --git a/Code/Legacy/CryCommon/IMovieSystem.h b/Code/Legacy/CryCommon/IMovieSystem.h index 79c000bfca..a55d764afa 100644 --- a/Code/Legacy/CryCommon/IMovieSystem.h +++ b/Code/Legacy/CryCommon/IMovieSystem.h @@ -13,7 +13,6 @@ #include #include #include -#include #include #include @@ -184,7 +183,7 @@ public: private: AnimParamType m_type; - AZStd::basic_string, AZStd::stateless_allocator> m_name; + AZStd::string m_name; }; namespace AZStd @@ -620,7 +619,7 @@ public: , valueType(_valueType) , flags(_flags) {}; - AZStd::basic_string, AZStd::stateless_allocator> name; // parameter name. + AZStd::string name; // parameter name. CAnimParamType paramType; // parameter id. AnimValueType valueType; // value type, defines type of track to use for animating this parameter. ESupportedParamFlags flags; // combination of flags from ESupportedParamFlags. diff --git a/Code/Legacy/CrySystem/CMakeLists.txt b/Code/Legacy/CrySystem/CMakeLists.txt index ebfc866f4a..3153205b69 100644 --- a/Code/Legacy/CrySystem/CMakeLists.txt +++ b/Code/Legacy/CrySystem/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) add_subdirectory(XML) diff --git a/Code/Legacy/CrySystem/RemoteConsole/RemoteConsole.h b/Code/Legacy/CrySystem/RemoteConsole/RemoteConsole.h index 23edafa736..f075dd2c17 100644 --- a/Code/Legacy/CrySystem/RemoteConsole/RemoteConsole.h +++ b/Code/Legacy/CrySystem/RemoteConsole/RemoteConsole.h @@ -15,7 +15,7 @@ #include #include -#if !defined(RELEASE) || defined(RELEASE_LOGGING) || defined(ENABLE_PROFILING_CODE) +#if (!defined(RELEASE) || defined(RELEASE_LOGGING) || defined(ENABLE_PROFILING_CODE)) && !defined(AZ_LEGACY_CRYSYSTEM_TRAIT_REMOTE_CONSOLE_UNSUPPORTED) #define USE_REMOTE_CONSOLE struct SRemoteServer; diff --git a/Code/Legacy/CrySystem/RemoteConsole/RemoteConsole_none.inl b/Code/Legacy/CrySystem/RemoteConsole/RemoteConsole_none.inl index faf928a377..ae96fc112a 100644 --- a/Code/Legacy/CrySystem/RemoteConsole/RemoteConsole_none.inl +++ b/Code/Legacy/CrySystem/RemoteConsole/RemoteConsole_none.inl @@ -41,17 +41,17 @@ void CRemoteConsole::Stop() } ///////////////////////////////////////////////////////////////////////////////////////////// -void CRemoteConsole::AddLogMessage(const char* log) +void CRemoteConsole::AddLogMessage(const char*) { } ///////////////////////////////////////////////////////////////////////////////////////////// -void CRemoteConsole::AddLogWarning(const char* log) +void CRemoteConsole::AddLogWarning(const char*) { } ///////////////////////////////////////////////////////////////////////////////////////////// -void CRemoteConsole::AddLogError(const char* log) +void CRemoteConsole::AddLogError(const char*) { } @@ -61,11 +61,11 @@ void CRemoteConsole::Update() } ///////////////////////////////////////////////////////////////////////////////////////////// -void CRemoteConsole::RegisterListener(IRemoteConsoleListener* pListener, const char* name) +void CRemoteConsole::RegisterListener(IRemoteConsoleListener*, const char*) { } ///////////////////////////////////////////////////////////////////////////////////////////// -void CRemoteConsole::UnregisterListener(IRemoteConsoleListener* pListener) +void CRemoteConsole::UnregisterListener(IRemoteConsoleListener*) { } diff --git a/Code/Tools/AWSNativeSDKInit/CMakeLists.txt b/Code/Tools/AWSNativeSDKInit/CMakeLists.txt index 57ee31d30d..04f61eb924 100644 --- a/Code/Tools/AWSNativeSDKInit/CMakeLists.txt +++ b/Code/Tools/AWSNativeSDKInit/CMakeLists.txt @@ -6,14 +6,14 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/source/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME AWSNativeSDKInit STATIC NAMESPACE AZ FILES_CMAKE aws_native_sdk_init_files.cmake - ${pal_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake + ${pal_source_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake INCLUDE_DIRECTORIES PUBLIC include diff --git a/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSLogSystemInterface.h b/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSLogSystemInterface.h index 4982d3efbd..901e37cd7b 100644 --- a/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSLogSystemInterface.h +++ b/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSLogSystemInterface.h @@ -10,7 +10,7 @@ #if defined(PLATFORM_SUPPORTS_AWS_NATIVE_SDK) -#include +#include AZ_PUSH_DISABLE_WARNING(4251 4996, "-Wunknown-warning-option") #include diff --git a/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSMemoryInterface.h b/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSMemoryInterface.h index 805088563f..26126057e2 100644 --- a/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSMemoryInterface.h +++ b/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSMemoryInterface.h @@ -8,6 +8,7 @@ #pragma once +#include #if defined(PLATFORM_SUPPORTS_AWS_NATIVE_SDK) #include #else diff --git a/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSNativeSDKInit.h b/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSNativeSDKInit.h index 32bf02a247..f50d7002eb 100644 --- a/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSNativeSDKInit.h +++ b/Code/Tools/AWSNativeSDKInit/include/AWSNativeSDKInit/AWSNativeSDKInit.h @@ -13,7 +13,7 @@ #include #if defined(PLATFORM_SUPPORTS_AWS_NATIVE_SDK) - +#include // The AWS Native SDK AWSAllocator triggers a warning due to accessing members of std::allocator directly. // AWSAllocator.h(70): warning C4996: 'std::allocator::pointer': warning STL4010: Various members of std::allocator are deprecated in C++17. // Use std::allocator_traits instead of accessing these members directly. diff --git a/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderApplication.cpp b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderApplication.cpp index da2edcc51f..074138b324 100644 --- a/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderApplication.cpp +++ b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderApplication.cpp @@ -37,6 +37,7 @@ #include #include #include +#include namespace AssetBuilder { @@ -165,6 +166,7 @@ void AssetBuilderApplication::StartCommon(AZ::Entity* systemEntity) AssetBuilderSDK::InitializeSerializationContext(); AssetBuilderSDK::InitializeBehaviorContext(); + AssetBuilder::InitializeSerializationContext(); // the asset builder app never writes source files, only assets, so there is no need to do any kind of asset upgrading AZ::Data::AssetManager::Instance().SetAssetInfoUpgradingEnabled(false); diff --git a/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderComponent.cpp b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderComponent.cpp index 78244ab02c..21b8c31cf4 100644 --- a/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderComponent.cpp +++ b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderComponent.cpp @@ -34,6 +34,7 @@ #include #include #include +#include // Command-line parameter options: static const char* const s_paramHelp = "help"; // Print help information. @@ -51,10 +52,10 @@ static const char* const s_paramDebugCreate = "debug_create"; // Debug mode for static const char* const s_paramDebugProcess = "debug_process"; // Debug mode for the process job of the specified file. static const char* const s_paramPlatformTags = "tags"; // Additional list of tags to add platform tag list. static const char* const s_paramPlatform = "platform"; // Platform to use +static const char* const s_paramRegisterBuilders = "register"; // Indicates the AP is starting up and requesting a list of registered builders // Task modes: static const char* const s_taskResident = "resident"; // stays up and running indefinitely, accepting jobs via network connection -static const char* const s_taskRegisterBuilder = "register"; // outputs all the builder descriptors static const char* const s_taskCreateJob = "create"; // runs a builders createJobs function static const char* const s_taskProcessJob = "process"; // runs processJob function static const char* const s_taskDebug = "debug"; // runs a one shot job in a fake environment for a specified file. @@ -204,6 +205,40 @@ void AssetBuilderComponent::Reflect(AZ::ReflectContext* context) } } +bool AssetBuilderComponent::DoHelloPing() +{ + using namespace AssetBuilder; + + BuilderHelloRequest request; + BuilderHelloResponse response; + + AZStd::string id; + + if (!GetParameter(s_paramId, id)) + { + return false; + } + + request.m_uuid = AZ::Uuid::CreateString(id.c_str()); + + AZ_TracePrintf( + "AssetBuilderComponent", "RunInResidentMode: Pinging asset processor with the builder UUID %s\n", + request.m_uuid.ToString().c_str()); + + bool result = AzFramework::AssetSystem::SendRequest(request, response); + + AZ_Error("AssetBuilder", result, "Failed to send hello request to Asset Processor"); + // This error is only shown if we successfully got a response AND the response explicitly indicates the AP rejected the builder + AZ_Error("AssetBuilder", !result || response.m_accepted, "Asset Processor rejected connection request"); + + if (result) + { + AZ_TracePrintf("AssetBuilder", "Builder ID: %s\n", response.m_uuid.ToString().c_str()); + } + + return result; +} + bool AssetBuilderComponent::Run() { AZ_TracePrintf("AssetBuilderComponent", "Run: Parsing command line.\n"); @@ -217,8 +252,8 @@ bool AssetBuilderComponent::Run() } AZStd::string task; - AZStd::string debugFile; + if (GetParameter(s_paramDebug, debugFile, false)) { task = s_taskDebug; @@ -256,11 +291,13 @@ bool AssetBuilderComponent::Run() AZ_TracePrintf("AssetBuilderComponent", "Run: Connecting back to Asset Processor...\n"); bool connectedToAssetProcessor = ConnectToAssetProcessor(); //AP connection is required to access the asset catalog - AZ_Error("AssetBuilder", connectedToAssetProcessor, "Failed to establish a network connection to the AssetProcessor. Use -help for options.");; + AZ_Error("AssetBuilder", connectedToAssetProcessor, "Failed to establish a network connection to the AssetProcessor. Use -help for options."); + + bool registerBuilders = commandLine->GetNumSwitchValues(s_paramRegisterBuilders) > 0; IBuilderApplication* builderApplication = AZ::Interface::Get(); - if(!builderApplication) + if (!builderApplication) { AZ_Error("AssetBuilder", false, "Failed to retreive IBuilderApplication interface"); return false; @@ -274,7 +311,7 @@ bool AssetBuilderComponent::Run() { if (task == s_taskResident) { - result = RunInResidentMode(); + result = RunInResidentMode(registerBuilders); } else if (task == s_taskDebug) { @@ -370,43 +407,46 @@ bool AssetBuilderComponent::ConnectToAssetProcessor() ////////////////////////////////////////////////////////////////////////// -bool AssetBuilderComponent::RunInResidentMode() +bool AssetBuilderComponent::SendRegisteredBuildersToAp() { - using namespace AssetBuilderSDK; - using namespace AZStd::placeholders; - - AZ_TracePrintf("AssetBuilderComponent", "RunInResidentMode: Starting resident mode (waiting for commands to arrive)\n"); + AssetBuilder::BuilderRegistrationRequest registrationRequest; - AZStd::string port, id, builderFolder; - - if (!GetParameter(s_paramId, id) - || !GetParameter(s_paramModule, builderFolder)) + for (const auto& [uuid, desc] : m_assetBuilderDescMap) { - return false; + AssetBuilder::BuilderRegistration registration; + + registration.m_name = desc->m_name; + registration.m_analysisFingerprint = desc->m_analysisFingerprint; + registration.m_flags = desc->m_flags; + registration.m_flagsByJobKey = desc->m_flagsByJobKey; + registration.m_version = desc->m_version; + registration.m_busId = desc->m_busId; + registration.m_patterns = desc->m_patterns; + registration.m_productsToKeepOnFailure = desc->m_productsToKeepOnFailure; + + registrationRequest.m_builders.push_back(AZStd::move(registration)); } - if (!LoadBuilders(builderFolder)) - { - return false; - } + bool result = SendRequest(registrationRequest); - AzFramework::SocketConnection::GetInstance()->AddMessageHandler(CreateJobsNetRequest::MessageType(), AZStd::bind(&AssetBuilderComponent::CreateJobsResidentHandler, this, _1, _2, _3, _4)); - AzFramework::SocketConnection::GetInstance()->AddMessageHandler(ProcessJobNetRequest::MessageType(), AZStd::bind(&AssetBuilderComponent::ProcessJobResidentHandler, this, _1, _2, _3, _4)); + AZ_Error("AssetBuilder", result, "Failed to send builder registration request to Asset Processor"); - BuilderHelloRequest request; - BuilderHelloResponse response; + return result; +} - request.m_uuid = AZ::Uuid::CreateString(id.c_str()); +bool AssetBuilderComponent::RunInResidentMode(bool sendRegistration) +{ + using namespace AssetBuilder; + using namespace AZStd::placeholders; - AZ_TracePrintf("AssetBuilderComponent", "RunInResidentMode: Pinging asset processor with the builder UUID %s\n", request.m_uuid.ToString().c_str()); + AZ_TracePrintf("AssetBuilderComponent", "RunInResidentMode: Starting resident mode (waiting for commands to arrive)\n"); - bool result = AzFramework::AssetSystem::SendRequest(request, response); + AzFramework::SocketConnection::GetInstance()->AddMessageHandler(CreateJobsNetRequest::MessageType(), AZStd::bind(&AssetBuilderComponent::CreateJobsResidentHandler, this, _1, _2, _3, _4)); + AzFramework::SocketConnection::GetInstance()->AddMessageHandler(ProcessJobNetRequest::MessageType(), AZStd::bind(&AssetBuilderComponent::ProcessJobResidentHandler, this, _1, _2, _3, _4)); - AZ_Error("AssetBuilder", result, "Failed to send hello request to Asset Processor"); - // This error is only shown if we successfully got a response AND the response explicitly indicates the AP rejected the builder - AZ_Error("AssetBuilder", !result || response.m_accepted, "Asset Processor rejected connection request"); + bool result = DoHelloPing() && ((sendRegistration && SendRegisteredBuildersToAp()) || !sendRegistration); - if (result && response.m_accepted) + if (result) { m_running = true; @@ -415,7 +455,6 @@ bool AssetBuilderComponent::RunInResidentMode() AzFramework::EngineConnectionEvents::Bus::Handler::BusConnect(); // Listen for disconnects - AZ_TracePrintf("AssetBuilder", "Builder ID: %s\n", response.m_uuid.ToString().c_str()); AZ_TracePrintf("AssetBuilder", "Resident mode ready\n"); m_mainEvent.acquire(); AZ_TracePrintf("AssetBuilder", "Shutting down\n"); @@ -736,11 +775,7 @@ bool AssetBuilderComponent::RunOneShotTask(const AZStd::string& task) AZ::StringFunc::Path::Normalize(inputFilePath); AZ::StringFunc::Path::Normalize(outputFilePath); - if (task == s_taskRegisterBuilder) - { - return HandleRegisterBuilder(inputFilePath, outputFilePath); - } - else if (task == s_taskCreateJob) + if (task == s_taskCreateJob) { auto func = [this](const AssetBuilderSDK::CreateJobsRequest& request, AssetBuilderSDK::CreateJobsResponse& response) { @@ -896,7 +931,7 @@ void AssetBuilderComponent::JobThread() { case JobType::Create: { - using namespace AssetBuilderSDK; + using namespace AssetBuilder; auto* netRequest = azrtti_cast(job->m_netRequest.get()); auto* netResponse = azrtti_cast(job->m_netResponse.get()); @@ -922,7 +957,7 @@ void AssetBuilderComponent::JobThread() } case JobType::Process: { - using namespace AssetBuilderSDK; + using namespace AssetBuilder; AZ_TracePrintf("AssetBuilder", "Running processJob task\n"); @@ -981,14 +1016,14 @@ void AssetBuilderComponent::JobThread() void AssetBuilderComponent::CreateJobsResidentHandler(AZ::u32 /*typeId*/, AZ::u32 serial, const void* data, AZ::u32 dataLength) { - using namespace AssetBuilderSDK; + using namespace AssetBuilder; ResidentJobHandler(serial, data, dataLength, JobType::Create); } void AssetBuilderComponent::ProcessJobResidentHandler(AZ::u32 /*typeId*/, AZ::u32 serial, const void* data, AZ::u32 dataLength) { - using namespace AssetBuilderSDK; + using namespace AssetBuilder; ResidentJobHandler(serial, data, dataLength, JobType::Process); } @@ -1018,18 +1053,6 @@ bool AssetBuilderComponent::HandleTask(const AZStd::string& inputFilePath, const return true; } -bool AssetBuilderComponent::HandleRegisterBuilder(const AZStd::string& /*inputFilePath*/, const AZStd::string& outputFilePath) const -{ - AssetBuilderSDK::RegisterBuilderResponse response; - - for (const auto& pair : m_assetBuilderDescMap) - { - response.m_assetBuilderDescList.push_back(*pair.second); - } - - return AZ::Utils::SaveObjectToFile(outputFilePath, AZ::DataStream::ST_XML, &response); -} - void AssetBuilderComponent::UpdateResultCode(const AssetBuilderSDK::ProcessJobRequest& request, AssetBuilderSDK::ProcessJobResponse& response) const { if (request.m_jobDescription.m_failOnError) diff --git a/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderComponent.h b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderComponent.h index 2014be41aa..2172e9093e 100644 --- a/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderComponent.h +++ b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderComponent.h @@ -46,6 +46,7 @@ class AssetBuilderComponent public: AZ_COMPONENT(AssetBuilderComponent, "{04332899-5d73-4d41-86b7-b1017d349673}") static void Reflect(AZ::ReflectContext* context); + bool DoHelloPing(); AssetBuilderComponent() = default; ~AssetBuilderComponent() override = default; @@ -64,7 +65,7 @@ public: void RegisterBuilderInformation(const AssetBuilderSDK::AssetBuilderDesc& builderDesc) override; void RegisterComponentDescriptor(AZ::ComponentDescriptor* descriptor) override; - + //EngineConnectionEvents Handler void Disconnected(AzFramework::SocketConnection* connection) override; @@ -98,12 +99,13 @@ protected: static const char* GetLibraryExtension(); bool ConnectToAssetProcessor(); + bool SendRegisteredBuildersToAp(); bool LoadBuilders(const AZStd::string& builderFolder); bool LoadBuilder(const AZStd::string& filePath); void UnloadBuilders(); //! Hooks up net job request handling and keeps the AssetBuilder running indefinitely - bool RunInResidentMode(); + bool RunInResidentMode(bool sendRegistration); bool RunDebugTask(AZStd::string&& debugFile, bool runCreateJobs, bool runProcessJob); bool RunOneShotTask(const AZStd::string& task); @@ -120,9 +122,6 @@ protected: void ProcessJob(const AssetBuilderSDK::ProcessJobFunction& job, const AssetBuilderSDK::ProcessJobRequest& request, AssetBuilderSDK::ProcessJobResponse& outResponse); - //! Handles a builder registration request - bool HandleRegisterBuilder(const AZStd::string& inputFilePath, const AZStd::string& outputFilePath) const; - //! If needed looks at collected data and updates the result code from the job accordingly. void UpdateResultCode(const AssetBuilderSDK::ProcessJobRequest& request, AssetBuilderSDK::ProcessJobResponse& response) const; @@ -141,7 +140,7 @@ protected: //! Currently loading builder AssetBuilder::ExternalModuleAssetBuilderInfo* m_currentAssetBuilder = nullptr; - + //! Thread for running a job, so we don't block the network thread while doing work AZStd::thread_desc m_jobThreadDesc; AZStd::thread m_jobThread; @@ -153,7 +152,7 @@ protected: AZStd::binary_semaphore m_mainEvent; //! Use to signal a new job is ready to be processed AZStd::binary_semaphore m_jobEvent; - + //! Lock for m_queuedJob AZStd::mutex m_jobMutex; diff --git a/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderStatic.cpp b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderStatic.cpp new file mode 100644 index 0000000000..6a67fbe425 --- /dev/null +++ b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderStatic.cpp @@ -0,0 +1,182 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include + +namespace AssetBuilder +{ + void Reflect(AZ::ReflectContext* context) + { + BuilderRegistrationRequest::Reflect(context); + + BuilderHelloRequest::Reflect(context); + BuilderHelloResponse::Reflect(context); + CreateJobsNetRequest::Reflect(context); + CreateJobsNetResponse::Reflect(context); + ProcessJobNetRequest::Reflect(context); + ProcessJobNetResponse::Reflect(context); + } + + void InitializeSerializationContext() + { + AZ::SerializeContext* serializeContext = nullptr; + + AZ::ComponentApplicationBus::BroadcastResult(serializeContext, &AZ::ComponentApplicationBus::Events::GetSerializeContext); + AZ_Assert(serializeContext, "Unable to retrieve serialize context."); + + Reflect(serializeContext); + } + + void BuilderHelloRequest::Reflect(AZ::ReflectContext* context) + { + auto serialize = azrtti_cast(context); + if (serialize) + { + serialize->Class()->Version(1)->Field("UUID", &BuilderHelloRequest::m_uuid); + } + } + + unsigned int BuilderHelloRequest::MessageType() + { + static unsigned int messageType = AZ_CRC("AssetBuilderSDK::BuilderHelloRequest", 0x213a7248); + + return messageType; + } + + unsigned int BuilderHelloRequest::GetMessageType() const + { + return MessageType(); + } + + void BuilderHelloResponse::Reflect(AZ::ReflectContext* context) + { + auto serialize = azrtti_cast(context); + if (serialize) + { + serialize->Class() + ->Version(1) + ->Field("Accepted", &BuilderHelloResponse::m_accepted) + ->Field("UUID", &BuilderHelloResponse::m_uuid); + } + } + + unsigned int BuilderHelloResponse::GetMessageType() const + { + return BuilderHelloRequest::MessageType(); + } + + ////////////////////////////////////////////////////////////////////////// + + void CreateJobsNetRequest::Reflect(AZ::ReflectContext* context) + { + auto serialize = azrtti_cast(context); + if (serialize) + { + serialize->Class()->Version(1)->Field("Request", &CreateJobsNetRequest::m_request); + } + } + + unsigned int CreateJobsNetRequest::MessageType() + { + static unsigned int messageType = AZ_CRC("AssetBuilderSDK::CreateJobsNetRequest", 0xc48209c0); + + return messageType; + } + + unsigned int CreateJobsNetRequest::GetMessageType() const + { + return MessageType(); + } + + void CreateJobsNetResponse::Reflect(AZ::ReflectContext* context) + { + auto serialize = azrtti_cast(context); + if (serialize) + { + serialize->Class()->Version(1)->Field("Response", &CreateJobsNetResponse::m_response); + } + } + + unsigned int CreateJobsNetResponse::GetMessageType() const + { + return CreateJobsNetRequest::MessageType(); + } + + void ProcessJobNetRequest::Reflect(AZ::ReflectContext* context) + { + auto serialize = azrtti_cast(context); + if (serialize) + { + serialize->Class()->Version(1)->Field("Request", &ProcessJobNetRequest::m_request); + } + } + + unsigned int ProcessJobNetRequest::MessageType() + { + static unsigned int messageType = AZ_CRC("AssetBuilderSDK::ProcessJobNetRequest", 0x479f340f); + + return messageType; + } + + unsigned int ProcessJobNetRequest::GetMessageType() const + { + return MessageType(); + } + + void ProcessJobNetResponse::Reflect(AZ::ReflectContext* context) + { + auto serialize = azrtti_cast(context); + if (serialize) + { + serialize->Class()->Version(1)->Field("Response", &ProcessJobNetResponse::m_response); + } + } + + unsigned int ProcessJobNetResponse::GetMessageType() const + { + return ProcessJobNetRequest::MessageType(); + } + + //--------------------------------------------------------------------- + void BuilderRegistration::Reflect(AZ::ReflectContext* context) + { + auto serialize = azrtti_cast(context); + if (serialize) + { + serialize->Class() + ->Version(1) + ->Field("Name", &BuilderRegistration::m_name) + ->Field("Patterns", &BuilderRegistration::m_patterns) + ->Field("BusId", &BuilderRegistration::m_busId) + ->Field("Version", &BuilderRegistration::m_version) + ->Field("AnalysisFingerprint", &BuilderRegistration::m_analysisFingerprint) + ->Field("Flags", &BuilderRegistration::m_flags) + ->Field("FlagsByJobKey", &BuilderRegistration::m_flagsByJobKey) + ->Field("ProductsToKeepOnFailure", &BuilderRegistration::m_productsToKeepOnFailure); + } + } + + void BuilderRegistrationRequest::Reflect(AZ::ReflectContext* context) + { + BuilderRegistration::Reflect(context); + + auto serialize = azrtti_cast(context); + if (serialize) + { + serialize->Class()->Version(1)->Field( + "Builders", &BuilderRegistrationRequest::m_builders); + } + } + + unsigned int BuilderRegistrationRequest::GetMessageType() const + { + return BuilderRegistrationRequest::MessageType; + } + +} // namespace AssetBuilder diff --git a/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderStatic.h b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderStatic.h new file mode 100644 index 0000000000..41b6531116 --- /dev/null +++ b/Code/Tools/AssetProcessor/AssetBuilder/AssetBuilderStatic.h @@ -0,0 +1,140 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include + +namespace AssetBuilder +{ + void Reflect(AZ::ReflectContext* context); + + void InitializeSerializationContext(); + + //! BuilderHelloRequest is sent by an AssetBuilder that is attempting to connect to the AssetProcessor to register itself as a worker + class BuilderHelloRequest : public AzFramework::AssetSystem::BaseAssetProcessorMessage + { + public: + AZ_CLASS_ALLOCATOR(BuilderHelloRequest, AZ::OSAllocator, 0); + AZ_RTTI(BuilderHelloRequest, "{5fab5962-a1d8-42a5-bf7a-fb1a8c5a9588}", BaseAssetProcessorMessage); + + static void Reflect(AZ::ReflectContext* context); + static unsigned int MessageType(); + + unsigned int GetMessageType() const override; + + //! Unique ID assigned to this builder to identify it + AZ::Uuid m_uuid = AZ::Uuid::CreateNull(); + }; + + //! BuilderHelloResponse contains the AssetProcessor's response to a builder connection attempt, indicating if it is accepted and the ID + //! that it was assigned + class BuilderHelloResponse : public AzFramework::AssetSystem::BaseAssetProcessorMessage + { + public: + AZ_CLASS_ALLOCATOR(BuilderHelloResponse, AZ::OSAllocator, 0); + AZ_RTTI(BuilderHelloResponse, "{5f3d7c11-6639-4c6f-980a-32be546903c2}", BaseAssetProcessorMessage); + + static void Reflect(AZ::ReflectContext* context); + + unsigned int GetMessageType() const override; + + //! Indicates if the builder was accepted by the AP + bool m_accepted = false; + + //! Unique ID assigned to the builder. If the builder isn't a local process, this is the ID assigned by the AP + AZ::Uuid m_uuid = AZ::Uuid::CreateNull(); + }; + + class CreateJobsNetRequest : public AzFramework::AssetSystem::BaseAssetProcessorMessage + { + public: + AZ_CLASS_ALLOCATOR(CreateJobsNetRequest, AZ::OSAllocator, 0); + AZ_RTTI(CreateJobsNetRequest, "{97fa717d-3a09-4d21-95c6-b2eafd773f1c}", BaseAssetProcessorMessage); + + static void Reflect(AZ::ReflectContext* context); + static unsigned int MessageType(); + + unsigned int GetMessageType() const override; + + AssetBuilderSDK::CreateJobsRequest m_request; + }; + + class CreateJobsNetResponse : public AzFramework::AssetSystem::BaseAssetProcessorMessage + { + public: + AZ_CLASS_ALLOCATOR(CreateJobsNetResponse, AZ::OSAllocator, 0); + AZ_RTTI(CreateJobsNetResponse, "{b2c7c2d3-b60e-4b27-b699-43e0ba991c33}", BaseAssetProcessorMessage); + + static void Reflect(AZ::ReflectContext* context); + + unsigned int GetMessageType() const override; + + AssetBuilderSDK::CreateJobsResponse m_response; + }; + + class ProcessJobNetRequest : public AzFramework::AssetSystem::BaseAssetProcessorMessage + { + public: + AZ_CLASS_ALLOCATOR(ProcessJobNetRequest, AZ::OSAllocator, 0); + AZ_RTTI(ProcessJobNetRequest, "{05288de1-020b-48db-b9de-715f17284efa}", BaseAssetProcessorMessage); + + static void Reflect(AZ::ReflectContext* context); + static unsigned int MessageType(); + + unsigned int GetMessageType() const override; + + AssetBuilderSDK::ProcessJobRequest m_request; + }; + + class ProcessJobNetResponse : public AzFramework::AssetSystem::BaseAssetProcessorMessage + { + public: + AZ_CLASS_ALLOCATOR(ProcessJobNetResponse, AZ::OSAllocator, 0); + AZ_RTTI(ProcessJobNetResponse, "{26ddf882-246c-4cfb-912f-9b8e389df4f6}", BaseAssetProcessorMessage); + + static void Reflect(AZ::ReflectContext* context); + + unsigned int GetMessageType() const override; + + AssetBuilderSDK::ProcessJobResponse m_response; + }; + + ////////////////////////////////////////////////////////////////////////// + struct BuilderRegistration + { + AZ_CLASS_ALLOCATOR(BuilderRegistration, AZ::OSAllocator, 0); + AZ_TYPE_INFO(BuilderRegistration, "{36E785C3-5046-4568-870A-336C8249E453}"); + + static void Reflect(AZ::ReflectContext* context); + + AZStd::string m_name; + AZStd::vector m_patterns; + AZ::Uuid m_busId; + int m_version = 0; + AZStd::string m_analysisFingerprint; + AZ::u8 m_flags = 0; + AZStd::unordered_map m_flagsByJobKey; + AZStd::unordered_map> m_productsToKeepOnFailure; + }; + + class BuilderRegistrationRequest : public AzFramework::AssetSystem::BaseAssetProcessorMessage + { + public: + AZ_CLASS_ALLOCATOR(BuilderRegistrationRequest, AZ::OSAllocator, 0); + AZ_RTTI(BuilderRegistrationRequest, "{FA9CF2D5-C847-47F3-979D-6C3AE061715C}", BaseAssetProcessorMessage); + static void Reflect(AZ::ReflectContext* context); + static constexpr unsigned int MessageType = AZ_CRC_CE("AssetSystem::BuilderRegistrationRequest"); + + BuilderRegistrationRequest() = default; + unsigned int GetMessageType() const override; + + AZStd::vector m_builders; + }; +} // namespace AssetBuilder diff --git a/Code/Tools/AssetProcessor/AssetBuilder/CMakeLists.txt b/Code/Tools/AssetProcessor/AssetBuilder/CMakeLists.txt index 6baa99d43b..f23e749169 100644 --- a/Code/Tools/AssetProcessor/AssetBuilder/CMakeLists.txt +++ b/Code/Tools/AssetProcessor/AssetBuilder/CMakeLists.txt @@ -6,6 +6,22 @@ # # +ly_add_target( + NAME AssetBuilder.Static STATIC + NAMESPACE AZ + FILES_CMAKE + asset_builder_static_files.cmake + INCLUDE_DIRECTORIES + PUBLIC + . + BUILD_DEPENDENCIES + PUBLIC + AZ::AzCore + AZ::AzFramework + AZ::AzToolsFramework + AZ::AssetBuilderSDK +) + ly_add_target( NAME AssetBuilder EXECUTABLE NAMESPACE AZ @@ -17,6 +33,7 @@ ly_add_target( . BUILD_DEPENDENCIES PRIVATE + AssetBuilder.Static 3rdParty::Qt::Core 3rdParty::Qt::Gui 3rdParty::Qt::Network diff --git a/Code/Tools/AssetProcessor/AssetBuilder/asset_builder_static_files.cmake b/Code/Tools/AssetProcessor/AssetBuilder/asset_builder_static_files.cmake new file mode 100644 index 0000000000..48de742704 --- /dev/null +++ b/Code/Tools/AssetProcessor/AssetBuilder/asset_builder_static_files.cmake @@ -0,0 +1,12 @@ +# +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# +# + +set(FILES + AssetBuilderStatic.h + AssetBuilderStatic.cpp +) diff --git a/Code/Tools/AssetProcessor/AssetBuilderSDK/AssetBuilderSDK/AssetBuilderSDK.cpp b/Code/Tools/AssetProcessor/AssetBuilderSDK/AssetBuilderSDK/AssetBuilderSDK.cpp index b5323dd419..43126dd673 100644 --- a/Code/Tools/AssetProcessor/AssetBuilderSDK/AssetBuilderSDK/AssetBuilderSDK.cpp +++ b/Code/Tools/AssetProcessor/AssetBuilderSDK/AssetBuilderSDK/AssetBuilderSDK.cpp @@ -1172,19 +1172,10 @@ namespace AssetBuilderSDK JobProduct::Reflect(context); AssetBuilderDesc::Reflect(context); - RegisterBuilderRequest::Reflect(context); - RegisterBuilderResponse::Reflect(context); CreateJobsRequest::Reflect(context); CreateJobsResponse::Reflect(context); ProcessJobRequest::Reflect(context); ProcessJobResponse::Reflect(context); - - BuilderHelloRequest::Reflect(context); - BuilderHelloResponse::Reflect(context); - CreateJobsNetRequest::Reflect(context); - CreateJobsNetResponse::Reflect(context); - ProcessJobNetRequest::Reflect(context); - ProcessJobNetResponse::Reflect(context); } void InitializeSerializationContext() @@ -1263,24 +1254,6 @@ namespace AssetBuilderSDK } } - void RegisterBuilderRequest::Reflect(AZ::ReflectContext* context) - { - if (AZ::SerializeContext* serializeContext = azrtti_cast(context)) - { - serializeContext->Class()-> - Version(1)-> - Field("FilePath", &RegisterBuilderRequest::m_filePath); - } - - if (AZ::BehaviorContext* behaviorContext = azrtti_cast(context)) - { - behaviorContext->Class("RegisterBuilderRequest") - ->Attribute(AZ::Script::Attributes::Scope, AZ::Script::Attributes::ScopeFlags::Automation) - ->Attribute(AZ::Script::Attributes::Module, "asset.builder") - ->Property("filePath", BehaviorValueProperty(&RegisterBuilderRequest::m_filePath)); - } - } - void AssetBuilderDesc::Reflect(AZ::ReflectContext* context) { if (AZ::SerializeContext* serializeContext = azrtti_cast(context)) @@ -1313,25 +1286,6 @@ namespace AssetBuilderSDK } } - void RegisterBuilderResponse::Reflect(AZ::ReflectContext* context) - { - if (AZ::SerializeContext* serializeContext = azrtti_cast(context)) - { - serializeContext->Class() - ->Version(1) - ->Field("Asset Builder Desc List", &RegisterBuilderResponse::m_assetBuilderDescList); - } - - if (AZ::BehaviorContext* behaviorContext = azrtti_cast(context)) - { - behaviorContext->Class("RegisterBuilderResponse") - ->Attribute(AZ::Script::Attributes::Scope, AZ::Script::Attributes::ScopeFlags::Automation) - ->Attribute(AZ::Script::Attributes::Module, "asset.builder") - ->Constructor() - ->Property("assetBuilderDescList", BehaviorValueProperty(&RegisterBuilderResponse::m_assetBuilderDescList)); - } - } - bool CreateJobsResponse::Succeeded() const { return m_result == CreateJobsResultCode::Success; @@ -1362,128 +1316,6 @@ namespace AssetBuilderSDK } } - void BuilderHelloRequest::Reflect(AZ::ReflectContext* context) - { - auto serialize = azrtti_cast(context); - if (serialize) - { - serialize->Class() - ->Version(1) - ->Field("UUID", &BuilderHelloRequest::m_uuid); - } - } - - unsigned int BuilderHelloRequest::MessageType() - { - static unsigned int messageType = AZ_CRC("AssetBuilderSDK::BuilderHelloRequest", 0x213a7248); - - return messageType; - } - - unsigned int BuilderHelloRequest::GetMessageType() const - { - return MessageType(); - } - - void BuilderHelloResponse::Reflect(AZ::ReflectContext* context) - { - auto serialize = azrtti_cast(context); - if (serialize) - { - serialize->Class() - ->Version(1) - ->Field("Accepted", &BuilderHelloResponse::m_accepted) - ->Field("UUID", &BuilderHelloResponse::m_uuid); - } - } - - unsigned int BuilderHelloResponse::GetMessageType() const - { - return BuilderHelloRequest::MessageType(); - } - - ////////////////////////////////////////////////////////////////////////// - - void CreateJobsNetRequest::Reflect(AZ::ReflectContext* context) - { - auto serialize = azrtti_cast(context); - if (serialize) - { - serialize->Class() - ->Version(1) - ->Field("Request", &CreateJobsNetRequest::m_request); - } - } - - unsigned int CreateJobsNetRequest::MessageType() - { - static unsigned int messageType = AZ_CRC("AssetBuilderSDK::CreateJobsNetRequest", 0xc48209c0); - - return messageType; - } - - unsigned int CreateJobsNetRequest::GetMessageType() const - { - return MessageType(); - } - - void CreateJobsNetResponse::Reflect(AZ::ReflectContext* context) - { - auto serialize = azrtti_cast(context); - if (serialize) - { - serialize->Class() - ->Version(1) - ->Field("Response", &CreateJobsNetResponse::m_response); - } - } - - unsigned int CreateJobsNetResponse::GetMessageType() const - { - return CreateJobsNetRequest::MessageType(); - } - - - - void ProcessJobNetRequest::Reflect(AZ::ReflectContext* context) - { - auto serialize = azrtti_cast(context); - if (serialize) - { - serialize->Class() - ->Version(1) - ->Field("Request", &ProcessJobNetRequest::m_request); - } - } - - unsigned int ProcessJobNetRequest::MessageType() - { - static unsigned int messageType = AZ_CRC("AssetBuilderSDK::ProcessJobNetRequest", 0x479f340f); - - return messageType; - } - - unsigned int ProcessJobNetRequest::GetMessageType() const - { - return MessageType(); - } - - void ProcessJobNetResponse::Reflect(AZ::ReflectContext* context) - { - auto serialize = azrtti_cast(context); - if (serialize) - { - serialize->Class() - ->Version(1) - ->Field("Response", &ProcessJobNetResponse::m_response); - } - } - - unsigned int ProcessJobNetResponse::GetMessageType() const - { - return ProcessJobNetRequest::MessageType(); - } - JobDependency::JobDependency(const AZStd::string& jobKey, const AZStd::string& platformIdentifier, const JobDependencyType& type, const SourceFileDependency& sourceFile) : m_jobKey(jobKey) , m_platformIdentifier(platformIdentifier) diff --git a/Code/Tools/AssetProcessor/AssetBuilderSDK/AssetBuilderSDK/AssetBuilderSDK.h b/Code/Tools/AssetProcessor/AssetBuilderSDK/AssetBuilderSDK/AssetBuilderSDK.h index f977e15be9..65bf9cc7d4 100644 --- a/Code/Tools/AssetProcessor/AssetBuilderSDK/AssetBuilderSDK/AssetBuilderSDK.h +++ b/Code/Tools/AssetProcessor/AssetBuilderSDK/AssetBuilderSDK/AssetBuilderSDK.h @@ -464,35 +464,6 @@ namespace AssetBuilderSDK AZStd::string m_platformIdentifier; }; - //! RegisterBuilderRequest contains input data that will be sent by the AssetProcessor to the builder during the startup registration phase - struct RegisterBuilderRequest - { - AZ_CLASS_ALLOCATOR(RegisterBuilderRequest, AZ::SystemAllocator, 0); - AZ_TYPE_INFO(RegisterBuilderRequest, "{7C6C5198-4766-42B8-9A1E-48479CE2F5EA}"); - - AZStd::string m_filePath; - - RegisterBuilderRequest() {} - - explicit RegisterBuilderRequest(const AZStd::string& filePath) - : m_filePath(filePath) - { - } - - static void Reflect(AZ::ReflectContext* context); - }; - - //! INTERNAL USE ONLY - RegisterBuilderResponse contains registration data that will be sent by the builder to the AssetProcessor in response to RegisterBuilderRequest - struct RegisterBuilderResponse - { - AZ_CLASS_ALLOCATOR(RegisterBuilderResponse, AZ::SystemAllocator, 0); - AZ_TYPE_INFO(RegisterBuilderResponse, "{0AE5583F-C763-410E-BA7F-78BD90546C01}"); - - AZStd::vector m_assetBuilderDescList; - - static void Reflect(AZ::ReflectContext* context); - }; - /** * This tells you about a platform in your CreateJobsRequest or your ProcessJobRequest */ @@ -756,99 +727,9 @@ namespace AssetBuilderSDK static void Reflect(AZ::ReflectContext* context); }; - //! BuilderHelloRequest is sent by an AssetBuilder that is attempting to connect to the AssetProcessor to register itself as a worker - class BuilderHelloRequest : public AzFramework::AssetSystem::BaseAssetProcessorMessage - { - public: - - AZ_CLASS_ALLOCATOR(BuilderHelloRequest, AZ::OSAllocator, 0); - AZ_RTTI(BuilderHelloRequest, "{5fab5962-a1d8-42a5-bf7a-fb1a8c5a9588}", BaseAssetProcessorMessage); - - static void Reflect(AZ::ReflectContext* context); - static unsigned int MessageType(); - - unsigned int GetMessageType() const override; - - //! Unique ID assigned to this builder to identify it - AZ::Uuid m_uuid = AZ::Uuid::CreateNull(); - }; - - //! BuilderHelloResponse contains the AssetProcessor's response to a builder connection attempt, indicating if it is accepted and the ID that it was assigned - class BuilderHelloResponse : public AzFramework::AssetSystem::BaseAssetProcessorMessage - { - public: - - AZ_CLASS_ALLOCATOR(BuilderHelloResponse, AZ::OSAllocator, 0); - AZ_RTTI(BuilderHelloResponse, "{5f3d7c11-6639-4c6f-980a-32be546903c2}", BaseAssetProcessorMessage); - - static void Reflect(AZ::ReflectContext* context); - - unsigned int GetMessageType() const override; - - //! Indicates if the builder was accepted by the AP - bool m_accepted = false; - - //! Unique ID assigned to the builder. If the builder isn't a local process, this is the ID assigned by the AP - AZ::Uuid m_uuid = AZ::Uuid::CreateNull(); - }; - - class CreateJobsNetRequest : public AzFramework::AssetSystem::BaseAssetProcessorMessage - { - public: + - AZ_CLASS_ALLOCATOR(CreateJobsNetRequest, AZ::OSAllocator, 0); - AZ_RTTI(CreateJobsNetRequest, "{97fa717d-3a09-4d21-95c6-b2eafd773f1c}", BaseAssetProcessorMessage); - - static void Reflect(AZ::ReflectContext* context); - static unsigned int MessageType(); - - unsigned int GetMessageType() const override; - - CreateJobsRequest m_request; - }; - - class CreateJobsNetResponse : public AzFramework::AssetSystem::BaseAssetProcessorMessage - { - public: - - AZ_CLASS_ALLOCATOR(CreateJobsNetResponse, AZ::OSAllocator, 0); - AZ_RTTI(CreateJobsNetResponse, "{b2c7c2d3-b60e-4b27-b699-43e0ba991c33}", BaseAssetProcessorMessage); - - static void Reflect(AZ::ReflectContext* context); - - unsigned int GetMessageType() const override; - - CreateJobsResponse m_response; - }; - - class ProcessJobNetRequest : public AzFramework::AssetSystem::BaseAssetProcessorMessage - { - public: - - AZ_CLASS_ALLOCATOR(ProcessJobNetRequest, AZ::OSAllocator, 0); - AZ_RTTI(ProcessJobNetRequest, "{05288de1-020b-48db-b9de-715f17284efa}", BaseAssetProcessorMessage); - - static void Reflect(AZ::ReflectContext* context); - static unsigned int MessageType(); - - unsigned int GetMessageType() const override; - - ProcessJobRequest m_request; - }; - - class ProcessJobNetResponse : public AzFramework::AssetSystem::BaseAssetProcessorMessage - { - public: - - AZ_CLASS_ALLOCATOR(ProcessJobNetResponse, AZ::OSAllocator, 0); - AZ_RTTI(ProcessJobNetResponse, "{26ddf882-246c-4cfb-912f-9b8e389df4f6}", BaseAssetProcessorMessage); - - static void Reflect(AZ::ReflectContext* context); - - unsigned int GetMessageType() const override; - - ProcessJobResponse m_response; - }; + //! JobCancelListener can be used by builders in their processJob method to listen for job cancellation request. //! The address of this listener is the jobid which can be found in the process job request. @@ -935,44 +816,3 @@ namespace AZ AZ_TYPE_INFO_SPECIALIZE(AssetBuilderSDK::ProductPathDependencyType, "{EF77742B-9627-4072-B431-396AA7183C80}"); AZ_TYPE_INFO_SPECIALIZE(AssetBuilderSDK::SourceFileDependency::SourceFileDependencyType, "{BE9C8805-DB17-4500-944A-EB33FD0BE347}"); } - -//! This macro should be used by every AssetBuilder to register itself, -//! AssetProcessor uses these exported function to identify whether a dll is an Asset Builder or not -//! If you want something highly custom you can do these entry points yourself instead of using the macro. -#define REGISTER_ASSETBUILDER \ - extern void BuilderOnInit(); \ - extern void BuilderDestroy(); \ - extern void BuilderRegisterDescriptors(); \ - extern void BuilderAddComponents(AZ::Entity * entity); \ - extern "C" \ - { \ - AZ_DLL_EXPORT int IsAssetBuilder() \ - { \ - return 0; \ - } \ - \ - AZ_DLL_EXPORT void InitializeModule(AZ::EnvironmentInstance sharedEnvironment) \ - { \ - AZ::Environment::Attach(sharedEnvironment); \ - BuilderOnInit(); \ - } \ - \ - AZ_DLL_EXPORT void UninitializeModule() \ - { \ - BuilderDestroy(); \ - AZ::Environment::Detach(); \ - } \ - \ - AZ_DLL_EXPORT void ModuleRegisterDescriptors() \ - { \ - BuilderRegisterDescriptors(); \ - } \ - \ - AZ_DLL_EXPORT void ModuleAddComponents(AZ::Entity * entity) \ - { \ - BuilderAddComponents(entity); \ - } \ - } -// confusion-reducing note: above end-brace is part of the macro, not a namespace - - diff --git a/Code/Tools/AssetProcessor/AssetBuilderSDK/CMakeLists.txt b/Code/Tools/AssetProcessor/AssetBuilderSDK/CMakeLists.txt index bfbcc35663..f32d55844e 100644 --- a/Code/Tools/AssetProcessor/AssetBuilderSDK/CMakeLists.txt +++ b/Code/Tools/AssetProcessor/AssetBuilderSDK/CMakeLists.txt @@ -11,7 +11,7 @@ ly_get_pal_tool_dirs(pal_tool_dirs ${CMAKE_CURRENT_LIST_DIR}/AssetBuilderSDK/Pla set(pal_files "") foreach(enabled_platform ${LY_PAL_TOOLS_ENABLED}) string(TOLOWER ${enabled_platform} enabled_platform_lowercase) - ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/AssetBuilderSDK/Platform/${enabled_platform}) + o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/AssetBuilderSDK/Platform/${enabled_platform} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) list(APPEND pal_files ${pal_dir}/assetbuildersdk_${enabled_platform_lowercase}_files.cmake) endforeach() diff --git a/Code/Tools/AssetProcessor/CMakeLists.txt b/Code/Tools/AssetProcessor/CMakeLists.txt index 431a167163..a47ced43be 100644 --- a/Code/Tools/AssetProcessor/CMakeLists.txt +++ b/Code/Tools/AssetProcessor/CMakeLists.txt @@ -42,6 +42,7 @@ ly_add_target( AZ::AzQtComponents AZ::AzToolsFramework AZ::AssetBuilderSDK + AZ::AssetBuilder.Static ${additional_dependencies} RUNTIME_DEPENDENCIES AZ::AssetBuilder @@ -52,7 +53,7 @@ get_property(asset_builders GLOBAL PROPERTY LY_ASSET_BUILDERS) string (REPLACE ";" "," asset_builders "${asset_builders}") ly_add_source_properties( SOURCES native/utilities/ApplicationManager.cpp - PROPERTY COMPILE_DEFINITIONS + PROPERTY COMPILE_DEFINITIONS VALUES LY_ASSET_BUILDERS="${asset_builders}" ) @@ -147,9 +148,9 @@ endif() # Tests ################################################################################ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) - + ly_add_target( - NAME AssetProcessor.Tests EXECUTABLE + NAME AssetProcessor.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} NAMESPACE AZ AUTOMOC AUTORCC @@ -167,12 +168,12 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) ) ly_add_source_properties( SOURCES native/tests/assetBuilderSDK/assetBuilderSDKTest.cpp - PROPERTY COMPILE_DEFINITIONS + PROPERTY COMPILE_DEFINITIONS VALUES ${LY_PAL_TOOLS_DEFINES} ) ly_add_source_properties( SOURCES native/unittests/AssetProcessorManagerUnitTests.cpp - PROPERTY COMPILE_DEFINITIONS + PROPERTY COMPILE_DEFINITIONS VALUES LY_CMAKE_BINARY_DIR="${CMAKE_BINARY_DIR}" ) @@ -266,7 +267,10 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) ly_add_googletest( NAME AZ::AssetProcessor.Tests - TEST_COMMAND $ --unittest --gtest_filter=-*.SUITE_sandbox* + ) + ly_add_googlebenchmark( + NAME AZ::AssetProcessor.Benchmarks + TARGET AZ::AssetProcessor.Tests ) endif() diff --git a/Code/Tools/AssetProcessor/Platform/Linux/assetprocessor_linux_files.cmake b/Code/Tools/AssetProcessor/Platform/Linux/assetprocessor_linux_files.cmake index 25f5c41445..b21393bcaa 100644 --- a/Code/Tools/AssetProcessor/Platform/Linux/assetprocessor_linux_files.cmake +++ b/Code/Tools/AssetProcessor/Platform/Linux/assetprocessor_linux_files.cmake @@ -8,4 +8,6 @@ set(FILES native/FileWatcher/FileWatcher_linux.cpp + native/FileWatcher/FileWatcher_linux.h + native/FileWatcher/FileWatcher_platform.h ) diff --git a/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_linux.cpp b/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_linux.cpp index b7f7affd6d..4ca41c0cb9 100644 --- a/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_linux.cpp +++ b/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_linux.cpp @@ -5,7 +5,10 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ + +#include #include +#include #include #include @@ -15,155 +18,127 @@ #include -static constexpr int s_handleToFolderMapLockTimeout = 1000; // 1 sec timeout for obtaining the handle to folder map lock -static constexpr size_t s_iNotifyMaxEntries = 1024 * 16; // Control the maximum number of entries (from inotify) that can be read at one time -static constexpr size_t s_iNotifyEventSize = sizeof(struct inotify_event); -static constexpr size_t s_iNotifyReadBufferSize = s_iNotifyMaxEntries * s_iNotifyEventSize; +static constexpr size_t s_inotifyMaxEntries = 1024 * 16; // Control the maximum number of entries (from inotify) that can be read at one time +static constexpr size_t s_inotifyEventSize = sizeof(struct inotify_event); +static constexpr size_t s_inotifyReadBufferSize = s_inotifyMaxEntries * s_inotifyEventSize; -struct FolderRootWatch::PlatformImplementation +bool FileWatcher::PlatformImplementation::Initialize() { - PlatformImplementation() = default; + if (m_inotifyHandle < 0) + { + // The CLOEXEC flag prevents the inotify watchers from copying on fork/exec + m_inotifyHandle = inotify_init1(IN_CLOEXEC); - int m_iNotifyHandle = -1; - QMutex m_handleToFolderMapLock; - QHash m_handleToFolderMap; + [[maybe_unused]] const auto err = errno; + [[maybe_unused]] AZStd::fixed_string<255> errorString; + AZ_Warning("FileWatcher", (m_inotifyHandle >= 0), "Unable to initialize inotify, file monitoring will not be available: %s\n", strerror_r(err, errorString.data(), errorString.capacity())); + } + return (m_inotifyHandle >= 0); +} - bool Initialize() +void FileWatcher::PlatformImplementation::Finalize() +{ + if (m_inotifyHandle < 0) { - if (m_iNotifyHandle < 0) - { - // The CLOEXEC flag prevents the inotify watchers from copying on fork/exec - m_iNotifyHandle = inotify_init1(IN_CLOEXEC); - } - return (m_iNotifyHandle >= 0); + return; } - void Finalize() { - if (m_iNotifyHandle >= 0) + QMutexLocker lock{&m_handleToFolderMapLock}; + for (const auto& watchHandle : m_handleToFolderMap.keys()) { - if (!m_handleToFolderMapLock.tryLock(s_handleToFolderMapLockTimeout)) - { - AZ_Error("FileWatcher", false, "Unable to obtain inotify handle lock on thread"); - return; - } - - QHashIterator iter(m_handleToFolderMap); - while (iter.hasNext()) - { - iter.next(); - int watchHandle = iter.key(); - inotify_rm_watch(m_iNotifyHandle, watchHandle); - } - m_handleToFolderMap.clear(); - m_handleToFolderMapLock.unlock(); - - ::close(m_iNotifyHandle); - m_iNotifyHandle = -1; + inotify_rm_watch(m_inotifyHandle, watchHandle); } + m_handleToFolderMap.clear(); } - void AddWatchFolder(QString folder) + ::close(m_inotifyHandle); + m_inotifyHandle = -1; +} + +void FileWatcher::PlatformImplementation::AddWatchFolder(QString folder, bool recursive) +{ + if (m_inotifyHandle < 0) { - if (m_iNotifyHandle >= 0) - { - // Clean up the path before accepting it as a watch folder - QString cleanPath = QDir::cleanPath(folder); - - // Add the folder to watch and track it - int watchHandle = inotify_add_watch(m_iNotifyHandle, - cleanPath.toUtf8().constData(), - IN_CREATE | IN_CLOSE_WRITE | IN_DELETE | IN_DELETE_SELF | IN_MODIFY | IN_MOVE); - - if (!m_handleToFolderMapLock.tryLock(s_handleToFolderMapLockTimeout)) - { - AZ_Error("FileWatcher", false, "Unable to obtain inotify handle lock on thread"); - return; - } - m_handleToFolderMap[watchHandle] = cleanPath; - m_handleToFolderMapLock.unlock(); + return; + } - // Add all the subfolders to watch and track them - QDirIterator dirIter(folder, QDirIterator::Subdirectories | QDirIterator::FollowSymlinks); + // Clean up the path before accepting it as a watch folder + QString cleanPath = QDir::cleanPath(folder); - while (dirIter.hasNext()) - { - QString dirName = dirIter.next(); - if (dirName.endsWith("/.") || dirName.endsWith("/..")) - { - continue; - } - - int watchHandle = inotify_add_watch(m_iNotifyHandle, - dirName.toUtf8().constData(), - IN_CREATE | IN_CLOSE_WRITE | IN_DELETE | IN_DELETE_SELF | IN_MODIFY | IN_MOVE); + // Add the folder to watch and track it + int watchHandle = inotify_add_watch(m_inotifyHandle, + cleanPath.toUtf8().constData(), + IN_CREATE | IN_CLOSE_WRITE | IN_DELETE | IN_DELETE_SELF | IN_MODIFY | IN_MOVE); - if (!m_handleToFolderMapLock.tryLock(s_handleToFolderMapLockTimeout)) - { - AZ_Error("FileWatcher", false, "Unable to obtain inotify handle lock on thread"); - return; - } - m_handleToFolderMap[watchHandle] = dirName; - m_handleToFolderMapLock.unlock(); - } - } + if (watchHandle < 0) + { + [[maybe_unused]] const auto err = errno; + [[maybe_unused]] AZStd::fixed_string<255> errorString; + AZ_Warning("FileWatcher", false, "inotify_add_watch failed for path %s: %s", cleanPath.toUtf8().constData(), strerror_r(err, errorString.data(), errorString.capacity())); + return; } - - void RemoveWatchFolder(int watchHandle) { - if (m_iNotifyHandle >= 0) - { - if (!m_handleToFolderMapLock.tryLock(s_handleToFolderMapLockTimeout)) - { - AZ_Error("FileWatcher", false, "Unable to obtain inotify handle lock on thread"); - return; - } + QMutexLocker lock{&m_handleToFolderMapLock}; + m_handleToFolderMap[watchHandle] = cleanPath; + } - QHash::iterator handleToRemove = m_handleToFolderMap.find(watchHandle); - if (handleToRemove != m_handleToFolderMap.end()) - { - inotify_rm_watch(m_iNotifyHandle, watchHandle); - m_handleToFolderMap.erase(handleToRemove); - } + // Add all the contents (files and directories) to watch and track them + QDirIterator dirIter(folder, QDir::NoDotAndDotDot | QDir::Dirs | QDir::Files, (recursive ? QDirIterator::Subdirectories : QDirIterator::NoIteratorFlags) | QDirIterator::FollowSymlinks); - m_handleToFolderMapLock.unlock(); + while (dirIter.hasNext()) + { + QString dirName = dirIter.next(); + + watchHandle = inotify_add_watch(m_inotifyHandle, + dirName.toUtf8().constData(), + IN_CREATE | IN_CLOSE_WRITE | IN_DELETE | IN_DELETE_SELF | IN_MODIFY | IN_MOVE); + if (watchHandle < 0) + { + [[maybe_unused]] const auto err = errno; + [[maybe_unused]] AZStd::fixed_string<255> errorString; + AZ_Warning("FileWatcher", false, "inotify_add_watch failed for path %s: %s", dirName.toUtf8().constData(), strerror_r(err, errorString.data(), errorString.capacity())); + return; } + + QMutexLocker lock{&m_handleToFolderMapLock}; + m_handleToFolderMap[watchHandle] = dirName; } -}; - -////////////////////////////////////////////////////////////////////////////// -/// FolderWatchRoot -FolderRootWatch::FolderRootWatch(const QString rootFolder) - : m_root(rootFolder) - , m_shutdownThreadSignal(false) - , m_fileWatcher(nullptr) - , m_platformImpl(new PlatformImplementation()) -{ } -FolderRootWatch::~FolderRootWatch() +void FileWatcher::PlatformImplementation::RemoveWatchFolder(int watchHandle) { - // Destructor is required in here since this file contains the definition of struct PlatformImplementation - Stop(); + if (m_inotifyHandle < 0) + { + return; + } - delete m_platformImpl; + QMutexLocker lock{&m_handleToFolderMapLock}; + if (m_handleToFolderMap.remove(watchHandle)) + { + inotify_rm_watch(m_inotifyHandle, watchHandle); + } } -bool FolderRootWatch::Start() +bool FileWatcher::PlatformStart() { // inotify will be used by linux to monitor file changes within directories under the root folder if (!m_platformImpl->Initialize()) { return false; } - m_platformImpl->AddWatchFolder(m_root); + for (const auto& [directory, recursive] : m_folderWatchRoots) + { + if (QDir(directory).exists()) + { + m_platformImpl->AddWatchFolder(directory, recursive); + } + } - m_shutdownThreadSignal = false; - m_thread = std::thread([this]() { WatchFolderLoop(); }); return true; } -void FolderRootWatch::Stop() +void FileWatcher::PlatformStop() { m_shutdownThreadSignal = true; @@ -172,64 +147,78 @@ void FolderRootWatch::Stop() if (m_thread.joinable()) { m_thread.join(); // wait for the thread to finish - m_thread = std::thread(); //destroy } } -void FolderRootWatch::WatchFolderLoop() +void FileWatcher::WatchFolderLoop() { - char eventBuffer[s_iNotifyReadBufferSize]; + char eventBuffer[s_inotifyReadBufferSize]; while (!m_shutdownThreadSignal) { - ssize_t bytesRead = ::read(m_platformImpl->m_iNotifyHandle, eventBuffer, s_iNotifyReadBufferSize); + ssize_t bytesRead = ::read(m_platformImpl->m_inotifyHandle, eventBuffer, s_inotifyReadBufferSize); if (bytesRead < 0) { // Break out of the loop when the notify handle was closed (outside of this thread) break; } - else if (bytesRead > 0) + if (!bytesRead) + { + continue; + } + for (size_t index=0; index(&eventBuffer[index]); + + if (event->mask & (IN_CREATE | IN_DELETE | IN_MODIFY | IN_MOVE)) { - struct inotify_event *event = ( struct inotify_event * ) &eventBuffer[ index ]; + const QString pathStr = QDir(m_platformImpl->m_handleToFolderMap[event->wd]).absoluteFilePath(event->name); - if (event->mask & (IN_CREATE | IN_DELETE | IN_MODIFY | IN_MOVE )) + if (event->mask & (IN_CREATE | IN_MOVED_TO)) { - QString pathStr = QString("%1%2%3").arg(m_platformImpl->m_handleToFolderMap[event->wd], QDir::separator(), event->name); - - if (event->mask & (IN_CREATE | IN_MOVED_TO)) + if (event->mask & IN_ISDIR) { - if ( event->mask & IN_ISDIR ) + // New Directory, see if it should be added to the watched directories + // It is only added if it is a child of a recursively watched directory + const auto found = AZStd::find_if(begin(m_folderWatchRoots), end(m_folderWatchRoots), [this, event](const WatchRoot& watchRoot) { - // New Directory, add it to the watch - m_platformImpl->AddWatchFolder(pathStr); - } - else + return watchRoot.m_directory == m_platformImpl->m_handleToFolderMap[event->wd]; + }); + + // If the path is not in m_folderWatchRoots, it must + // be a new subdirectory of a subdirectory of some + // other root that is being watched recursively. + // Maintain the recursive nature of that root. + const bool shouldAddFolder = (found == end(m_folderWatchRoots)) ? true : found->m_recursive; + + if (shouldAddFolder) { - ProcessNewFileEvent(pathStr); + m_platformImpl->AddWatchFolder(pathStr, true); } } - else if (event->mask & (IN_DELETE | IN_MOVED_FROM)) + else { - if (event->mask & IN_ISDIR) - { - // Directory Deleted, remove it from the watch - m_platformImpl->RemoveWatchFolder(event->wd); - } - else - { - ProcessDeleteFileEvent(pathStr); - } + rawFileAdded(pathStr, {}); + } + } + else if (event->mask & (IN_DELETE | IN_MOVED_FROM)) + { + if (event->mask & IN_ISDIR) + { + // Directory Deleted, remove it from the watch + m_platformImpl->RemoveWatchFolder(event->wd); } - else if ((event->mask & IN_MODIFY) && ((event->mask & IN_ISDIR) != IN_ISDIR)) + else { - ProcessModifyFileEvent(pathStr); + rawFileRemoved(pathStr, {}); } } - index += s_iNotifyEventSize + event->len; + else if ((event->mask & IN_MODIFY) && ((event->mask & IN_ISDIR) != IN_ISDIR)) + { + rawFileModified(pathStr, {}); + } } + index += s_inotifyEventSize + event->len; } } } - diff --git a/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_linux.h b/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_linux.h new file mode 100644 index 0000000000..a6fead401c --- /dev/null +++ b/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_linux.h @@ -0,0 +1,26 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include + +class FileWatcher::PlatformImplementation +{ +public: + bool Initialize(); + void Finalize(); + void AddWatchFolder(QString folder, bool recursive); + void RemoveWatchFolder(int watchHandle); + + int m_inotifyHandle = -1; + QMutex m_handleToFolderMapLock; + QHash m_handleToFolderMap; +}; diff --git a/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_platform.h b/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_platform.h new file mode 100644 index 0000000000..e3cb91d73a --- /dev/null +++ b/Code/Tools/AssetProcessor/Platform/Linux/native/FileWatcher/FileWatcher_platform.h @@ -0,0 +1,11 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include diff --git a/Code/Tools/AssetProcessor/Platform/Mac/assetprocessor_mac_files.cmake b/Code/Tools/AssetProcessor/Platform/Mac/assetprocessor_mac_files.cmake index 0f20ef2f38..476bcde500 100644 --- a/Code/Tools/AssetProcessor/Platform/Mac/assetprocessor_mac_files.cmake +++ b/Code/Tools/AssetProcessor/Platform/Mac/assetprocessor_mac_files.cmake @@ -8,4 +8,6 @@ set(FILES native/FileWatcher/FileWatcher_macos.cpp + native/FileWatcher/FileWatcher_mac.h + native/FileWatcher/FileWatcher_platform.h ) diff --git a/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_mac.h b/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_mac.h new file mode 100644 index 0000000000..ade2497c4d --- /dev/null +++ b/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_mac.h @@ -0,0 +1,20 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include + +#include + +class FileWatcher::PlatformImplementation +{ +public: + FSEventStreamRef m_stream = nullptr; + CFRunLoopRef m_runLoop = nullptr; +}; diff --git a/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_macos.cpp b/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_macos.cpp index 1dd6e65a15..47b344ff81 100644 --- a/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_macos.cpp +++ b/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_macos.cpp @@ -6,47 +6,23 @@ * */ #include +#include #include #include -#include void FileEventStreamCallback(ConstFSEventStreamRef streamRef, void *clientCallBackInfo, size_t numEvents, void *eventPaths, const FSEventStreamEventFlags eventFlags[], const FSEventStreamEventId eventIds[]); -struct FolderRootWatch::PlatformImplementation -{ - PlatformImplementation() : m_stream(nullptr), m_runLoop(nullptr) { } - - FSEventStreamRef m_stream; - CFRunLoopRef m_runLoop; - QString m_renameFileDirectory; -}; - -////////////////////////////////////////////////////////////////////////////// -/// FolderWatchRoot -FolderRootWatch::FolderRootWatch(const QString rootFolder) - : m_root(rootFolder) - , m_shutdownThreadSignal(false) - , m_fileWatcher(nullptr) - , m_platformImpl(new PlatformImplementation()) -{ -} - -FolderRootWatch::~FolderRootWatch() -{ - // Destructor is required in here since this file contains the definition of struct PlatformImplementation - Stop(); - - delete m_platformImpl; -} - -bool FolderRootWatch::Start() +bool FileWatcher::PlatformStart() { m_shutdownThreadSignal = false; - CFStringRef rootPath = CFStringCreateWithCString(kCFAllocatorDefault, m_root.toStdString().data(), kCFStringEncodingMacRoman); - CFArrayRef pathsToWatch = CFArrayCreate(NULL, (const void **)&rootPath, 1, NULL); + CFMutableArrayRef pathsToWatch = CFArrayCreateMutable(nullptr, this->m_folderWatchRoots.size(), nullptr); + for (const auto& root : this->m_folderWatchRoots) + { + CFArrayAppendValue(pathsToWatch, root.m_directory.toCFString()); + } // The larger this number, the larger the delay between the kernel knowing a file changed // and us actually consuming the event. It is very important for asset processor to deal with @@ -60,11 +36,12 @@ bool FolderRootWatch::Start() // Set ourselves as the value for the context info field so that in the callback // we get passed into it and the callback can call our public API to handle // the file change events - FSEventStreamContext streamContext; - ::memset(&streamContext, 0, sizeof(streamContext)); - streamContext.info = this; + FSEventStreamContext streamContext{ + /*.version =*/ 0, + /*.info =*/ this, + }; - m_platformImpl->m_stream = FSEventStreamCreate(NULL, + m_platformImpl->m_stream = FSEventStreamCreate(nullptr, FileEventStreamCallback, &streamContext, pathsToWatch, @@ -72,24 +49,25 @@ bool FolderRootWatch::Start() timeBetweenKernelUpdateAndNotification, kFSEventStreamCreateFlagFileEvents); - AZ_Error("FileWatcher", (m_platformImpl->m_stream != nullptr), "FSEventStreamCreate returned a nullptr. No file events will be reported for %s", m_root.toStdString().c_str()); - - m_thread = std::thread(std::bind(&FolderRootWatch::WatchFolderLoop, this)); + AZ_Error("FileWatcher", (m_platformImpl->m_stream != nullptr), "FSEventStreamCreate returned a nullptr. No file events will be reported."); + const CFIndex pathCount = CFArrayGetCount(pathsToWatch); + for(CFIndex i = 0; i < pathCount; ++i) + { + CFRelease(CFArrayGetValueAtIndex(pathsToWatch, i)); + } CFRelease(pathsToWatch); - CFRelease(rootPath); - return (m_platformImpl->m_stream != nullptr); + return m_platformImpl->m_stream != nullptr; } -void FolderRootWatch::Stop() +void FileWatcher::PlatformStop() { m_shutdownThreadSignal = true; if (m_thread.joinable()) { m_thread.join(); // wait for the thread to finish - m_thread = std::thread(); //destroy } FSEventStreamStop(m_platformImpl->m_stream); @@ -97,7 +75,7 @@ void FolderRootWatch::Stop() FSEventStreamRelease(m_platformImpl->m_stream); } -void FolderRootWatch::WatchFolderLoop() +void FileWatcher::WatchFolderLoop() { // Use a half second timeout interval so that we can check if // m_shutdownThreadSignal has been changed while we were running the RunLoop @@ -117,14 +95,14 @@ void FolderRootWatch::WatchFolderLoop() void FileEventStreamCallback(ConstFSEventStreamRef streamRef, void *clientCallBackInfo, size_t numEvents, void *eventPaths, const FSEventStreamEventFlags eventFlags[], const FSEventStreamEventId eventIds[]) { - FolderRootWatch* watcher = reinterpret_cast(clientCallBackInfo); + auto* watcher = reinterpret_cast(clientCallBackInfo); const char** filePaths = reinterpret_cast(eventPaths); for (int i = 0; i < numEvents; ++i) { - QFileInfo fileInfo(QDir::cleanPath(filePaths[i])); - QString fileAndPath = fileInfo.absoluteFilePath(); + const QFileInfo fileInfo(QDir::cleanPath(filePaths[i])); + const QString fileAndPath = fileInfo.absoluteFilePath(); if (!fileInfo.isHidden()) { @@ -133,38 +111,38 @@ void FileEventStreamCallback(ConstFSEventStreamRef streamRef, void *clientCallBa // so check for all of them if (eventFlags[i] & kFSEventStreamEventFlagItemCreated) { - watcher->ProcessNewFileEvent(fileAndPath); + watcher->rawFileAdded(fileAndPath, {}); } if (eventFlags[i] & kFSEventStreamEventFlagItemModified) { - watcher->ProcessModifyFileEvent(fileAndPath); + watcher->rawFileModified(fileAndPath, {}); } if (eventFlags[i] & kFSEventStreamEventFlagItemRemoved) { - watcher->ProcessDeleteFileEvent(fileAndPath); + watcher->rawFileRemoved(fileAndPath, {}); } if (eventFlags[i] & kFSEventStreamEventFlagItemRenamed) { if (fileInfo.exists()) { - watcher->ProcessNewFileEvent(fileAndPath); + watcher->rawFileAdded(fileAndPath, {}); // macOS does not send out an event for the directory being // modified when a file has been renamed but the FileWatcher // API expects it so send out the modification event ourselves. - watcher->ProcessModifyFileEvent(fileInfo.absolutePath()); + watcher->rawFileModified(fileInfo.absolutePath(), {}); } else { - watcher->ProcessDeleteFileEvent(fileAndPath); + watcher->rawFileRemoved(fileAndPath, {}); // macOS does not send out an event for the directory being // modified when a file has been renamed but the FileWatcher // API expects it so send out the modification event ourselves. - watcher->ProcessModifyFileEvent(fileInfo.absolutePath()); + watcher->rawFileModified(fileInfo.absolutePath(), {}); } } } diff --git a/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_platform.h b/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_platform.h new file mode 100644 index 0000000000..58b60354e7 --- /dev/null +++ b/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_platform.h @@ -0,0 +1,11 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include diff --git a/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_win.cpp b/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_win.cpp deleted file mode 100644 index a6b0841f05..0000000000 --- a/Code/Tools/AssetProcessor/Platform/Mac/native/FileWatcher/FileWatcher_win.cpp +++ /dev/null @@ -1,130 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include - -#include - -struct FolderRootWatch::PlatformImplementation -{ - PlatformImplementation() : m_directoryHandle(nullptr), m_ioHandle(nullptr) { } - HANDLE m_directoryHandle; - HANDLE m_ioHandle; -}; - -////////////////////////////////////////////////////////////////////////////// -/// FolderWatchRoot -FolderRootWatch::FolderRootWatch(const QString rootFolder) - : m_root(rootFolder) - , m_shutdownThreadSignal(false) - , m_fileWatcher(nullptr) - , m_platformImpl(new PlatformImplementation()) -{ -} - -FolderRootWatch::~FolderRootWatch() -{ - // Destructor is required in here since this file contains the definition of struct PlatformImplementation - Stop(); - - delete m_platformImpl; -} - -bool FolderRootWatch::Start() -{ - m_platformImpl->m_directoryHandle = ::CreateFileW(m_root.toStdWString().data(), FILE_LIST_DIRECTORY, FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, nullptr, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS | FILE_FLAG_OVERLAPPED, nullptr); - - if (m_platformImpl->m_directoryHandle != INVALID_HANDLE_VALUE) - { - m_platformImpl->m_ioHandle = ::CreateIoCompletionPort(m_platformImpl->m_directoryHandle, nullptr, 1, 0); - if (m_platformImpl->m_ioHandle != INVALID_HANDLE_VALUE) - { - m_shutdownThreadSignal = false; - m_thread = std::thread(std::bind(&FolderRootWatch::WatchFolderLoop, this)); - return true; - } - } - return false; -} - -void FolderRootWatch::Stop() -{ - m_shutdownThreadSignal = true; - CloseHandle(m_platformImpl->m_ioHandle); - m_platformImpl->m_ioHandle = nullptr; - - if (m_thread.joinable()) - { - m_thread.join(); // wait for the thread to finish - m_thread = std::thread(); //destroy - } - CloseHandle(m_platformImpl->m_directoryHandle); - m_platformImpl->m_directoryHandle = nullptr; -} - -void FolderRootWatch::WatchFolderLoop() -{ - FILE_NOTIFY_INFORMATION aFileNotifyInformationList[50000]; - QString path; - OVERLAPPED aOverlapped; - LPOVERLAPPED pOverlapped; - DWORD dwByteCount; - ULONG_PTR ulKey; - - while (!m_shutdownThreadSignal) - { - ::memset(aFileNotifyInformationList, 0, sizeof(aFileNotifyInformationList)); - ::memset(&aOverlapped, 0, sizeof(aOverlapped)); - - if (::ReadDirectoryChangesW(m_platformImpl->m_directoryHandle, aFileNotifyInformationList, sizeof(aFileNotifyInformationList), true, FILE_NOTIFY_CHANGE_LAST_WRITE | FILE_NOTIFY_CHANGE_DIR_NAME | FILE_NOTIFY_CHANGE_ATTRIBUTES | FILE_NOTIFY_CHANGE_FILE_NAME, nullptr, &aOverlapped, nullptr)) - { - //wait for up to a second for I/O to signal - dwByteCount = 0; - if (::GetQueuedCompletionStatus(m_platformImpl->m_ioHandle, &dwByteCount, &ulKey, &pOverlapped, INFINITE)) - { - //if we are signaled to shutdown bypass - if (!m_shutdownThreadSignal && ulKey) - { - if (dwByteCount) - { - int offset = 0; - FILE_NOTIFY_INFORMATION* pFileNotifyInformation = aFileNotifyInformationList; - do - { - pFileNotifyInformation = (FILE_NOTIFY_INFORMATION*)((char*)pFileNotifyInformation + offset); - - path.clear(); - path.append(m_root); - path.append(QString::fromWCharArray(pFileNotifyInformation->FileName, pFileNotifyInformation->FileNameLength / 2)); - - QString file = QDir::toNativeSeparators(QDir::cleanPath(path)); - - switch (pFileNotifyInformation->Action) - { - case FILE_ACTION_ADDED: - case FILE_ACTION_RENAMED_NEW_NAME: - ProcessNewFileEvent(file); - break; - case FILE_ACTION_REMOVED: - case FILE_ACTION_RENAMED_OLD_NAME: - ProcessDeleteFileEvent(file); - break; - case FILE_ACTION_MODIFIED: - ProcessModifyFileEvent(file); - break; - } - - offset = pFileNotifyInformation->NextEntryOffset; - } while (offset); - } - } - } - } - } -} - diff --git a/Code/Tools/AssetProcessor/Platform/Windows/assetprocessor_windows_files.cmake b/Code/Tools/AssetProcessor/Platform/Windows/assetprocessor_windows_files.cmake index 5d1f4d1eed..96dd7434c1 100644 --- a/Code/Tools/AssetProcessor/Platform/Windows/assetprocessor_windows_files.cmake +++ b/Code/Tools/AssetProcessor/Platform/Windows/assetprocessor_windows_files.cmake @@ -7,6 +7,8 @@ # set(FILES - native/FileWatcher/FileWatcher_win.cpp + native/FileWatcher/FileWatcher_platform.h + native/FileWatcher/FileWatcher_windows.cpp + native/FileWatcher/FileWatcher_windows.h native/resource.h ) diff --git a/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_platform.h b/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_platform.h new file mode 100644 index 0000000000..5fe5f05f87 --- /dev/null +++ b/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_platform.h @@ -0,0 +1,11 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include diff --git a/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_win.cpp b/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_win.cpp deleted file mode 100644 index a6b0841f05..0000000000 --- a/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_win.cpp +++ /dev/null @@ -1,130 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include - -#include - -struct FolderRootWatch::PlatformImplementation -{ - PlatformImplementation() : m_directoryHandle(nullptr), m_ioHandle(nullptr) { } - HANDLE m_directoryHandle; - HANDLE m_ioHandle; -}; - -////////////////////////////////////////////////////////////////////////////// -/// FolderWatchRoot -FolderRootWatch::FolderRootWatch(const QString rootFolder) - : m_root(rootFolder) - , m_shutdownThreadSignal(false) - , m_fileWatcher(nullptr) - , m_platformImpl(new PlatformImplementation()) -{ -} - -FolderRootWatch::~FolderRootWatch() -{ - // Destructor is required in here since this file contains the definition of struct PlatformImplementation - Stop(); - - delete m_platformImpl; -} - -bool FolderRootWatch::Start() -{ - m_platformImpl->m_directoryHandle = ::CreateFileW(m_root.toStdWString().data(), FILE_LIST_DIRECTORY, FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, nullptr, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS | FILE_FLAG_OVERLAPPED, nullptr); - - if (m_platformImpl->m_directoryHandle != INVALID_HANDLE_VALUE) - { - m_platformImpl->m_ioHandle = ::CreateIoCompletionPort(m_platformImpl->m_directoryHandle, nullptr, 1, 0); - if (m_platformImpl->m_ioHandle != INVALID_HANDLE_VALUE) - { - m_shutdownThreadSignal = false; - m_thread = std::thread(std::bind(&FolderRootWatch::WatchFolderLoop, this)); - return true; - } - } - return false; -} - -void FolderRootWatch::Stop() -{ - m_shutdownThreadSignal = true; - CloseHandle(m_platformImpl->m_ioHandle); - m_platformImpl->m_ioHandle = nullptr; - - if (m_thread.joinable()) - { - m_thread.join(); // wait for the thread to finish - m_thread = std::thread(); //destroy - } - CloseHandle(m_platformImpl->m_directoryHandle); - m_platformImpl->m_directoryHandle = nullptr; -} - -void FolderRootWatch::WatchFolderLoop() -{ - FILE_NOTIFY_INFORMATION aFileNotifyInformationList[50000]; - QString path; - OVERLAPPED aOverlapped; - LPOVERLAPPED pOverlapped; - DWORD dwByteCount; - ULONG_PTR ulKey; - - while (!m_shutdownThreadSignal) - { - ::memset(aFileNotifyInformationList, 0, sizeof(aFileNotifyInformationList)); - ::memset(&aOverlapped, 0, sizeof(aOverlapped)); - - if (::ReadDirectoryChangesW(m_platformImpl->m_directoryHandle, aFileNotifyInformationList, sizeof(aFileNotifyInformationList), true, FILE_NOTIFY_CHANGE_LAST_WRITE | FILE_NOTIFY_CHANGE_DIR_NAME | FILE_NOTIFY_CHANGE_ATTRIBUTES | FILE_NOTIFY_CHANGE_FILE_NAME, nullptr, &aOverlapped, nullptr)) - { - //wait for up to a second for I/O to signal - dwByteCount = 0; - if (::GetQueuedCompletionStatus(m_platformImpl->m_ioHandle, &dwByteCount, &ulKey, &pOverlapped, INFINITE)) - { - //if we are signaled to shutdown bypass - if (!m_shutdownThreadSignal && ulKey) - { - if (dwByteCount) - { - int offset = 0; - FILE_NOTIFY_INFORMATION* pFileNotifyInformation = aFileNotifyInformationList; - do - { - pFileNotifyInformation = (FILE_NOTIFY_INFORMATION*)((char*)pFileNotifyInformation + offset); - - path.clear(); - path.append(m_root); - path.append(QString::fromWCharArray(pFileNotifyInformation->FileName, pFileNotifyInformation->FileNameLength / 2)); - - QString file = QDir::toNativeSeparators(QDir::cleanPath(path)); - - switch (pFileNotifyInformation->Action) - { - case FILE_ACTION_ADDED: - case FILE_ACTION_RENAMED_NEW_NAME: - ProcessNewFileEvent(file); - break; - case FILE_ACTION_REMOVED: - case FILE_ACTION_RENAMED_OLD_NAME: - ProcessDeleteFileEvent(file); - break; - case FILE_ACTION_MODIFIED: - ProcessModifyFileEvent(file); - break; - } - - offset = pFileNotifyInformation->NextEntryOffset; - } while (offset); - } - } - } - } - } -} - diff --git a/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_windows.cpp b/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_windows.cpp new file mode 100644 index 0000000000..b7d1d4c74c --- /dev/null +++ b/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_windows.cpp @@ -0,0 +1,153 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include +#include +#include +#include + +bool FileWatcher::PlatformStart() +{ + m_shutdownThreadSignal = false; + + bool allSucceeded = true; + for (const auto& [directory, recursive] : m_folderWatchRoots) + { + if (QDir(directory).exists()) + { + allSucceeded &= m_platformImpl->AddWatchFolder(directory, recursive); + } + } + return allSucceeded; +} + +bool FileWatcher::PlatformImplementation::AddWatchFolder(QString root, bool recursive) +{ + HandleUniquePtr directoryHandle{::CreateFileW( + root.toStdWString().data(), + FILE_LIST_DIRECTORY, + FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, + nullptr, + OPEN_EXISTING, + FILE_FLAG_BACKUP_SEMANTICS | FILE_FLAG_OVERLAPPED, + nullptr + )}; + + if (directoryHandle.get() == INVALID_HANDLE_VALUE) + { + AZ_Warning("FileWatcher", false, "Failed to start watching %s", root.toUtf8().constData()); + return false; + } + + // Associate this file handle with our existing io completion port handle + if (!::CreateIoCompletionPort(directoryHandle.get(), m_ioHandle.get(), /*CompletionKey =*/ static_cast(PlatformImplementation::EventType::FileRead), 1)) + { + return false; + } + + auto id = AZStd::make_unique(); + auto* idp = id.get(); + const auto& [folderWatch, inserted] = m_folderRootWatches.emplace(AZStd::piecewise_construct, AZStd::forward_as_tuple(idp), + AZStd::forward_as_tuple(AZStd::move(id), AZStd::move(directoryHandle), root, recursive)); + + if (!inserted) + { + return false; + } + + return folderWatch->second.ReadChanges(); +} + +bool FileWatcher::PlatformImplementation::FolderRootWatch::ReadChanges() +{ + // Register to get directory change notifications for our directory handle + return ::ReadDirectoryChangesW( + m_directoryHandle.get(), + &m_fileNotifyInformationList, + sizeof(m_fileNotifyInformationList), + m_recursive, + FILE_NOTIFY_CHANGE_LAST_WRITE | FILE_NOTIFY_CHANGE_DIR_NAME | FILE_NOTIFY_CHANGE_ATTRIBUTES | FILE_NOTIFY_CHANGE_FILE_NAME, + nullptr, + m_overlapped.get(), + nullptr + ); +} + +void FileWatcher::PlatformStop() +{ + m_shutdownThreadSignal = true; + + // Send a special signal to the child thread, that is blocked in a GetQueuedCompletionStatus call, with a completion + // key set to Shutdown. The child thread will stop its processing when it receives this value for the completion key + PostQueuedCompletionStatus(m_platformImpl->m_ioHandle.get(), 0, /*CompletionKey =*/ static_cast(PlatformImplementation::EventType::Shutdown), nullptr); + if (m_thread.joinable()) + { + m_thread.join(); // wait for the thread to finish + } +} + +void FileWatcher::WatchFolderLoop() +{ + LPOVERLAPPED directoryId = nullptr; + ULONG_PTR completionKey = 0; + + while (!m_shutdownThreadSignal) + { + DWORD dwByteCount = 0; + if (::GetQueuedCompletionStatus(m_platformImpl->m_ioHandle.get(), &dwByteCount, &completionKey, &directoryId, INFINITE)) + { + if (m_shutdownThreadSignal || completionKey == static_cast(PlatformImplementation::EventType::Shutdown)) + { + break; + } + if (dwByteCount == 0) + { + continue; + } + + const auto foundFolderRoot = m_platformImpl->m_folderRootWatches.find(directoryId); + if (foundFolderRoot == end(m_platformImpl->m_folderRootWatches)) + { + continue; + } + + PlatformImplementation::FolderRootWatch& folderRoot = foundFolderRoot->second; + + // Initialize offset to 1 to ensure that the first iteration is always processed + DWORD offset = 1; + for ( + const FILE_NOTIFY_INFORMATION* pFileNotifyInformation = reinterpret_cast(&folderRoot.m_fileNotifyInformationList); + offset; + pFileNotifyInformation = reinterpret_cast(reinterpret_cast(pFileNotifyInformation) + offset) + ){ + const QString file = QDir::toNativeSeparators(QDir(folderRoot.m_directoryRoot) + .filePath(QString::fromWCharArray(pFileNotifyInformation->FileName, pFileNotifyInformation->FileNameLength / 2))); + + switch (pFileNotifyInformation->Action) + { + case FILE_ACTION_ADDED: + case FILE_ACTION_RENAMED_NEW_NAME: + rawFileAdded(file, {}); + break; + case FILE_ACTION_REMOVED: + case FILE_ACTION_RENAMED_OLD_NAME: + rawFileRemoved(file, {}); + break; + case FILE_ACTION_MODIFIED: + rawFileModified(file, {}); + break; + } + + offset = pFileNotifyInformation->NextEntryOffset; + } + + folderRoot.ReadChanges(); + } + } +} diff --git a/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_windows.h b/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_windows.h new file mode 100644 index 0000000000..28092961f5 --- /dev/null +++ b/Code/Tools/AssetProcessor/Platform/Windows/native/FileWatcher/FileWatcher_windows.h @@ -0,0 +1,65 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include +#include + +#include +#include + +struct HandleDeleter +{ + void operator()(HANDLE handle) + { + if (handle && handle != INVALID_HANDLE_VALUE) + { + CloseHandle(handle); + } + } +}; + +using HandleUniquePtr = AZStd::unique_ptr, HandleDeleter>; + +class FileWatcher::PlatformImplementation +{ +public: + bool AddWatchFolder(QString folder, bool recursive); + + struct FolderRootWatch + { + FolderRootWatch(AZStd::unique_ptr&& overlapped, HandleUniquePtr&& directoryHandle, QString root, bool recursive) + : m_overlapped(AZStd::move(overlapped)) + , m_directoryHandle(AZStd::move(directoryHandle)) + , m_directoryRoot(AZStd::move(root)) + , m_recursive(recursive) + { + } + + bool ReadChanges(); + + AZStd::unique_ptr m_overlapped; // Identifies this root watch + HandleUniquePtr m_directoryHandle; + QString m_directoryRoot; + bool m_recursive; + AZStd::aligned_storage_t<64 * 1024, sizeof(DWORD)> m_fileNotifyInformationList{}; + }; + + enum class EventType + { + FileRead, + Shutdown + }; + + AZStd::unordered_map m_folderRootWatches; + + HandleUniquePtr m_ioHandle{CreateIoCompletionPort(INVALID_HANDLE_VALUE, nullptr, /*CompletionKey =*/ static_cast(EventType::FileRead), 1)}; +}; diff --git a/Code/Tools/AssetProcessor/assetprocessor_static_files.cmake b/Code/Tools/AssetProcessor/assetprocessor_static_files.cmake index 400a3f7ba5..6dda9af682 100644 --- a/Code/Tools/AssetProcessor/assetprocessor_static_files.cmake +++ b/Code/Tools/AssetProcessor/assetprocessor_static_files.cmake @@ -44,7 +44,6 @@ set(FILES native/FileProcessor/FileProcessor.h native/FileWatcher/FileWatcher.cpp native/FileWatcher/FileWatcher.h - native/FileWatcher/FileWatcherAPI.h native/InternalBuilders/SettingsRegistryBuilder.cpp native/InternalBuilders/SettingsRegistryBuilder.h native/resourcecompiler/JobsModel.cpp @@ -63,13 +62,6 @@ set(FILES native/resourcecompiler/RCJobSortFilterProxyModel.h native/resourcecompiler/RCQueueSortModel.cpp native/resourcecompiler/RCQueueSortModel.h - native/shadercompiler/shadercompilerjob.cpp - native/shadercompiler/shadercompilerjob.h - native/shadercompiler/shadercompilerManager.cpp - native/shadercompiler/shadercompilerManager.h - native/shadercompiler/shadercompilerMessages.h - native/shadercompiler/shadercompilerModel.cpp - native/shadercompiler/shadercompilerModel.h native/utilities/ApplicationManagerAPI.h native/utilities/ApplicationManager.cpp native/utilities/ApplicationManager.h diff --git a/Code/Tools/AssetProcessor/assetprocessor_test_files.cmake b/Code/Tools/AssetProcessor/assetprocessor_test_files.cmake index 3a336ce97b..a7a46ad62c 100644 --- a/Code/Tools/AssetProcessor/assetprocessor_test_files.cmake +++ b/Code/Tools/AssetProcessor/assetprocessor_test_files.cmake @@ -48,6 +48,7 @@ set(FILES native/tests/InternalBuilders/SettingsRegistryBuilderTests.cpp native/tests/MissingDependencyScannerTests.cpp native/tests/SourceFileRelocatorTests.cpp + native/tests/PathDependencyManagerTests.cpp native/tests/AssetProcessorMessagesTests.cpp native/unittests/AssetProcessingStateDataUnitTests.cpp native/unittests/AssetProcessingStateDataUnitTests.h @@ -67,8 +68,6 @@ set(FILES native/unittests/PlatformConfigurationUnitTests.h native/unittests/RCcontrollerUnitTests.cpp native/unittests/RCcontrollerUnitTests.h - native/unittests/ShaderCompilerUnitTests.cpp - native/unittests/ShaderCompilerUnitTests.h native/unittests/UnitTestRunner.cpp native/unittests/UnitTestRunner.h native/unittests/UtilitiesUnitTests.cpp diff --git a/Code/Tools/AssetProcessor/native/AssetDatabase/AssetDatabase.cpp b/Code/Tools/AssetProcessor/native/AssetDatabase/AssetDatabase.cpp index cf33e559ac..5edf4e1d53 100644 --- a/Code/Tools/AssetProcessor/native/AssetDatabase/AssetDatabase.cpp +++ b/Code/Tools/AssetProcessor/native/AssetDatabase/AssetDatabase.cpp @@ -172,7 +172,7 @@ namespace AssetProcessor static const char* CREATEINDEX_BUILDERGUID_SOURCE_SOURCEDEPENDENCY_STATEMENT = "CREATE INDEX IF NOT EXISTS BuilderGuid_Source_SourceDependency ON SourceDependency (BuilderGuid, Source);"; static const char* CREATEINDEX_TYPEOFDEPENDENCY_SOURCEDEPENDENCY = "AssetProcessor::CreateIndexTypeOfDependency_SourceDependency"; - static const char* CREATEINDEX_TYPEOFDEPENDENCY_SOURCEDEPENDENCY_STATEMENT = + static const char* CREATEINDEX_TYPEOFDEPENDENCY_SOURCEDEPENDENCY_STATEMENT = "CREATE INDEX IF NOT EXISTS TypeOfDependency_SourceDependency ON SourceDependency (TypeOfDependency);"; static const char* CREATEINDEX_SCANFOLDERS_SOURCES_SCANFOLDER = "AssetProcesser::CreateIndexScanFoldersSourcesScanFolder"; @@ -611,7 +611,7 @@ namespace AssetProcessor SqlParam(":missingDependencyString"), SqlParam(":lastScanTime"), SqlParam(":scanTimeSecondsSinceEpoch")); - + static const auto s_DeleteMissingProductDependencyByProductIdQuery = MakeSqlQuery( DELETE_MISSING_PRODUCT_DEPENDENCY_BY_PRODUCTID, @@ -643,7 +643,7 @@ namespace AssetProcessor SqlParam(":analysisFingerprint")); static const char* INSERT_COLUMN_ANALYSISFINGERPRINT = "AssetProcessor::AddColumnAnalysisFingerprint"; - static const char* INSERT_COLUMN_ANALYSISFINGERPRINT_STATEMENT = + static const char* INSERT_COLUMN_ANALYSISFINGERPRINT_STATEMENT = "ALTER TABLE Sources " "ADD AnalysisFingerprint TEXT NOT NULL collate nocase default('');"; @@ -653,7 +653,7 @@ namespace AssetProcessor "ADD TypeOfDependency INTEGER NOT NULL DEFAULT 0;"; static const char* INSERT_COLUMN_FILE_MODTIME = "AssetProcessor::AddFiles_ModTime"; - static const char* INSERT_COLUMN_FILE_MODTIME_STATEMENT = + static const char* INSERT_COLUMN_FILE_MODTIME_STATEMENT = "ALTER TABLE Files " "ADD ModTime INTEGER NOT NULL DEFAULT 0;"; @@ -673,7 +673,7 @@ namespace AssetProcessor "ADD UnresolvedDependencyType INTEGER NOT NULL DEFAULT 0;"; static const char* INSERT_COLUMN_PRODUCTDEPENDENCY_PLATFORM = "AssetProcessor::AddProductDependency_Platform"; - static const char* INSERT_COLUMN_PRODUCTDEPENDENCY_PLATFORM_STATEMENT = + static const char* INSERT_COLUMN_PRODUCTDEPENDENCY_PLATFORM_STATEMENT = "ALTER TABLE ProductDependencies " "ADD Platform TEXT NOT NULL collate nocase default('');"; @@ -721,7 +721,7 @@ namespace AssetProcessor SqlParam(":isfolder"), SqlParam(":modtime"), SqlParam(":hash")); - + static const char* UPDATE_FILE = "AssetProcessor::UpdateFile"; static const char* UPDATE_FILE_STATEMENT = "UPDATE Files SET " @@ -961,7 +961,7 @@ namespace AssetProcessor AZ_TracePrintf(AssetProcessor::ConsoleChannel, "Upgraded Asset Database to version %i (AddedTypeOfDependencyIndex)\n", foundVersion) } } - + if (foundVersion == AssetDatabase::DatabaseVersion::AddedTypeOfDependencyIndex) { if (m_databaseConnection->ExecuteOneOffStatement(INSERT_COLUMN_PRODUCTDEPENDENCY_PLATFORM)) @@ -1178,7 +1178,7 @@ namespace AssetProcessor AddStatement(m_databaseConnection, s_InsertJobQuery); AddStatement(m_databaseConnection, s_UpdateJobQuery); AddStatement(m_databaseConnection, s_DeleteJobQuery); - + // --------------------------------------------------------------------------------------------- // Builder Info Table // --------------------------------------------------------------------------------------------- @@ -1207,7 +1207,7 @@ namespace AssetProcessor m_databaseConnection->AddStatement(CREATE_SOURCE_DEPENDENCY_TABLE, CREATE_SOURCE_DEPENDENCY_TABLE_STATEMENT); m_databaseConnection->AddStatement(INSERT_COLUMN_SOURCEDEPENDENCY_TYPEOFDEPENDENCY, INSERT_COLUMN_SOURCEDEPENDENCY_TYPEOFDEPENDENCY_STATEMENT); m_databaseConnection->AddStatement(INSERT_COLUMNS_SOURCEDEPENDENCY_FROM_ASSETID, INSERT_COLUMNS_SOURCEDEPENDENCY_FROM_ASSETID_STATEMENT); - + m_createStatements.push_back(CREATE_SOURCE_DEPENDENCY_TABLE); AddStatement(m_databaseConnection, s_InsertSourceDependencyQuery); @@ -1242,7 +1242,7 @@ namespace AssetProcessor AddStatement(m_databaseConnection, s_InsertProductDependencyQuery); AddStatement(m_databaseConnection, s_UpdateProductDependencyQuery); AddStatement(m_databaseConnection, s_DeleteProductDependencyByProductIdQuery); - + // --------------------------------------------------------------------------------------------- // Missing Product Dependency table // --------------------------------------------------------------------------------------------- @@ -1253,7 +1253,7 @@ namespace AssetProcessor AddStatement(m_databaseConnection, s_InsertMissingProductDependencyQuery); AddStatement(m_databaseConnection, s_UpdateMissingProductDependencyQuery); AddStatement(m_databaseConnection, s_DeleteMissingProductDependencyByProductIdQuery); - + // --------------------------------------------------------------------------------------------- // Files table // --------------------------------------------------------------------------------------------- @@ -1344,7 +1344,7 @@ namespace AssetProcessor bool AssetDatabaseConnection::GetScanFolderByScanFolderID(AZ::s64 scanfolderID, ScanFolderDatabaseEntry& entry) { bool found = false; - QueryScanFolderByScanFolderID( scanfolderID, + QueryScanFolderByScanFolderID( scanfolderID, [&](ScanFolderDatabaseEntry& scanFolderEntry) { entry = scanFolderEntry; @@ -1357,7 +1357,7 @@ namespace AssetProcessor bool AssetDatabaseConnection::GetScanFolderBySourceID(AZ::s64 sourceID, ScanFolderDatabaseEntry& entry) { bool found = false; - QueryScanFolderBySourceID( sourceID, + QueryScanFolderBySourceID( sourceID, [&](ScanFolderDatabaseEntry& scanFolderEntry) { entry = scanFolderEntry; @@ -1370,7 +1370,7 @@ namespace AssetProcessor bool AssetDatabaseConnection::GetScanFolderByJobID(AZ::s64 jobID, ScanFolderDatabaseEntry& entry) { bool found = false; - QueryScanFolderByJobID( jobID, + QueryScanFolderByJobID( jobID, [&](ScanFolderDatabaseEntry& scanFolderEntry) { entry = scanFolderEntry; @@ -1383,7 +1383,7 @@ namespace AssetProcessor bool AssetDatabaseConnection::GetScanFolderByProductID(AZ::s64 productID, ScanFolderDatabaseEntry& entry) { bool found = false; - QueryScanFolderByProductID( productID, + QueryScanFolderByProductID( productID, [&](ScanFolderDatabaseEntry& scanFolderEntry) { entry = scanFolderEntry; @@ -2105,7 +2105,7 @@ namespace AssetProcessor bool AssetDatabaseConnection::GetProductsLikeProductName(QString likeProductName, LikeType likeType, ProductDatabaseEntryContainer& container, AZ::Uuid builderGuid, QString jobKey, QString platform, JobStatus status) { bool found = false; - + if (likeProductName.isEmpty()) { return false; @@ -2198,7 +2198,7 @@ namespace AssetProcessor bool AssetDatabaseConnection::GetProductByJobIDSubId(AZ::s64 jobID, AZ::u32 subID, AzToolsFramework::AssetDatabase::ProductDatabaseEntry& result) { bool found = false; - QueryProductByJobIDSubID(jobID, subID, + QueryProductByJobIDSubID(jobID, subID, [&](ProductDatabaseEntry& resultFromDB) { found = true; @@ -2312,13 +2312,19 @@ namespace AssetProcessor { return false; } - - bool succeeded = true; + + ScopedTransaction transaction(m_databaseConnection); + for (auto& entry : container) { - succeeded &= SetProduct(entry); + if(!SetProduct(entry)) + { + return false; + } } - return succeeded; + + transaction.Commit(); + return true; } //! Clear the products for a given source. This removes the entry entirely, not just sets it to empty. @@ -2407,7 +2413,7 @@ namespace AssetProcessor if(!platform.isEmpty()) { AZStd::string platformStr = platform.toUtf8().constData(); - + if (!s_DeleteProductsBySourceidPlatformQuery.BindAndStep(*m_databaseConnection, sourceID, platformStr.c_str())) { return false; @@ -2521,7 +2527,7 @@ namespace AssetProcessor { succeeded = succeeded && RemoveSourceFileDependency(entry); } - + if (succeeded) { transaction.Commit(); @@ -2577,7 +2583,7 @@ namespace AssetProcessor } bool AssetDatabaseConnection::GetDependsOnSourceBySource( - const char* source, + const char* source, AzToolsFramework::AssetDatabase::SourceFileDependencyEntry::TypeOfDependency typeOfDependency, AzToolsFramework::AssetDatabase::SourceFileDependencyEntryContainer& container) { @@ -2596,7 +2602,7 @@ namespace AssetProcessor bool AssetDatabaseConnection::GetSourceFileDependencyBySourceDependencyId(AZ::s64 sourceDependencyId, SourceFileDependencyEntry& sourceDependencyEntry) { bool found = false; - QuerySourceDependencyBySourceDependencyId(sourceDependencyId, + QuerySourceDependencyBySourceDependencyId(sourceDependencyId, [&](SourceFileDependencyEntry& entry) { found = true; @@ -2624,7 +2630,7 @@ namespace AssetProcessor return false; } - + if (creatingNew) { AZ::s64 rowID = m_databaseConnection->GetLastRowID(); @@ -2958,9 +2964,25 @@ namespace AssetProcessor for(auto& entry : container) { - if(!SetProductDependency(entry)) + if(entry.m_productDependencyID == InvalidEntryId) { - return false; + if (!s_InsertProductDependencyQuery.BindAndStep( + *m_databaseConnection, entry.m_productPK, entry.m_dependencySourceGuid, entry.m_dependencySubID, + entry.m_dependencyFlags.to_ullong(), entry.m_platform.c_str(), entry.m_unresolvedPath.c_str(), + entry.m_dependencyType, entry.m_fromAssetId)) + { + return false; + } + } + else + { + if(!s_UpdateProductDependencyQuery.BindAndStep( + *m_databaseConnection, entry.m_productPK, entry.m_dependencySourceGuid, entry.m_dependencySubID, + entry.m_dependencyFlags.to_ullong(), entry.m_platform.c_str(), entry.m_unresolvedPath.c_str(), + entry.m_productDependencyID, entry.m_dependencyType, entry.m_fromAssetId)) + { + return false; + } } } @@ -2989,7 +3011,7 @@ namespace AssetProcessor } // now insert the new ones since we know there's no collisions: - + for (auto& entry : container) { @@ -3109,7 +3131,7 @@ namespace AssetProcessor } Statement* statement = autoFinal.Get(); - + if (statement->Step() == Statement::SqlError) { AZ_Warning(LOG_NAME, false, "Failed to write the new source into the database. %s", entry.m_fileName.c_str()); @@ -3126,7 +3148,7 @@ namespace AssetProcessor return UpdateFile(entry, entryAlreadyExists); } - bool AssetDatabaseConnection::UpdateFile(FileDatabaseEntry& entry, bool& entryAlreadyExists) + bool AssetDatabaseConnection::UpdateFile(FileDatabaseEntry& entry, bool& entryAlreadyExists) { entryAlreadyExists = false; diff --git a/Code/Tools/AssetProcessor/native/AssetManager/AssetCatalog.cpp b/Code/Tools/AssetProcessor/native/AssetManager/AssetCatalog.cpp index d7cdd30be8..bda5eb7842 100644 --- a/Code/Tools/AssetProcessor/native/AssetManager/AssetCatalog.cpp +++ b/Code/Tools/AssetProcessor/native/AssetManager/AssetCatalog.cpp @@ -480,12 +480,12 @@ namespace AssetProcessor AZ::Data::AssetId assetId(combined.m_sourceGuid, combined.m_subID); // relative file path is gotten by removing the platform and game from the product name - QString relativeProductPath = AssetUtilities::StripAssetPlatform(combined.m_productName); + AZStd::string_view relativeProductPath = AssetUtilities::StripAssetPlatformNoCopy(combined.m_productName); QString fullProductPath = m_cacheRoot.absoluteFilePath(combined.m_productName.c_str()); AZ::Data::AssetInfo info; info.m_assetType = combined.m_assetType; - info.m_relativePath = relativeProductPath.toUtf8().data(); + info.m_relativePath = relativeProductPath; info.m_assetId = assetId; info.m_sizeBytes = AZ::IO::SystemFile::Length(fullProductPath.toUtf8().constData()); diff --git a/Code/Tools/AssetProcessor/native/AssetManager/PathDependencyManager.cpp b/Code/Tools/AssetProcessor/native/AssetManager/PathDependencyManager.cpp index dc10dc2237..6dddfd62d3 100644 --- a/Code/Tools/AssetProcessor/native/AssetManager/PathDependencyManager.cpp +++ b/Code/Tools/AssetProcessor/native/AssetManager/PathDependencyManager.cpp @@ -9,18 +9,24 @@ #include "PathDependencyManager.h" #include #include +#include #include #include #include +#include namespace AssetProcessor { void SanitizeForDatabase(AZStd::string& str) { - // Not calling normalize because wildcards should be preserved. AZStd::to_lower(str.begin(), str.end()); - AZStd::replace(str.begin(), str.end(), AZ_WRONG_DATABASE_SEPARATOR, AZ_CORRECT_DATABASE_SEPARATOR); - AzFramework::StringFunc::Replace(str, AZ_DOUBLE_CORRECT_DATABASE_SEPARATOR, AZ_CORRECT_DATABASE_SEPARATOR_STRING); + + // Not calling normalize because wildcards should be preserved. + if (AZ::StringFunc::Contains(str, AZ_WRONG_DATABASE_SEPARATOR, true)) + { + AZStd::replace(str.begin(), str.end(), AZ_WRONG_DATABASE_SEPARATOR, AZ_CORRECT_DATABASE_SEPARATOR); + AzFramework::StringFunc::Replace(str, AZ_DOUBLE_CORRECT_DATABASE_SEPARATOR, AZ_CORRECT_DATABASE_SEPARATOR_STRING); + } } PathDependencyManager::PathDependencyManager(AZStd::shared_ptr stateData, PlatformConfiguration* platformConfig) @@ -29,7 +35,97 @@ namespace AssetProcessor } - void PathDependencyManager::SaveUnresolvedDependenciesToDatabase(AssetBuilderSDK::ProductPathDependencySet& unresolvedDependencies, const AzToolsFramework::AssetDatabase::ProductDatabaseEntry& productEntry, const AZStd::string& platform) + void PathDependencyManager::QueueSourceForDependencyResolution(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry) + { + m_queuedForResolve.push_back(sourceEntry); + } + + void PathDependencyManager::ProcessQueuedDependencyResolves() + { + if (m_queuedForResolve.empty()) + { + return; + } + + auto queuedForResolve = m_queuedForResolve; + m_queuedForResolve.clear(); + + // Grab every product from the database and map to Source PK -> [products] + AZStd::unordered_map> productMap; + m_stateData->QueryCombined([&productMap](const AzToolsFramework::AssetDatabase::CombinedDatabaseEntry& entry) + { + productMap[entry.m_sourcePK].push_back(entry); + return true; + }); + + // Build up a list of all the paths we need to search for: products + 2 variations of the source path + AZStd::vector searches; + + for (const auto& entry : queuedForResolve) + { + // Search for each product + for (const auto& productEntry : productMap[entry.m_sourceID]) + { + const AZStd::string& productName = productEntry.m_productName; + + // strip path of the / + AZStd::string_view result = AssetUtilities::StripAssetPlatformNoCopy(productName); + searches.emplace_back(result, false, &entry, &productEntry); + } + + // Search for the source path + AZStd::string sourceNameWithScanFolder = + ToScanFolderPrefixedPath(aznumeric_cast(entry.m_scanFolderPK), entry.m_sourceName.c_str()); + AZStd::string sanitizedSourceName = entry.m_sourceName; + + SanitizeForDatabase(sourceNameWithScanFolder); + SanitizeForDatabase(sanitizedSourceName); + + searches.emplace_back(sourceNameWithScanFolder, true, &entry, nullptr); + searches.emplace_back(sanitizedSourceName, true, &entry, nullptr); + } + + AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntryContainer unresolvedDependencies; + m_stateData->GetUnresolvedProductDependencies(unresolvedDependencies); + + AZStd::recursive_mutex mapMutex; + // Map of Map of Product Dependency>> + AZStd::unordered_map>> sourceIdToMatchedSearchDependencies; + + // For every search path we created, we're going to see if it matches up against any of the unresolved dependencies + AZ::parallel_for_each( + searches.begin(), searches.end(), + [&sourceIdToMatchedSearchDependencies, &mapMutex, &unresolvedDependencies](const SearchEntry& search) + { + AZStd::unordered_set matches; + for (const auto& entry: unresolvedDependencies) + { + AZ::IO::PathView searchPath(search.m_path); + + if(((entry.m_dependencyType == AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntry::ProductDep_SourceFile && search.m_isSourcePath) + || (entry.m_dependencyType == AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntry::ProductDep_ProductFile && !search.m_isSourcePath)) + && searchPath.Match(entry.m_unresolvedPath)) + { + matches.insert(entry); + } + } + + if (!matches.empty()) + { + AZStd::scoped_lock lock(mapMutex); + auto& productDependencyDatabaseEntries = sourceIdToMatchedSearchDependencies[search.m_sourceEntry->m_sourceID][&search]; + productDependencyDatabaseEntries.insert(matches.begin(), matches.end()); + } + }); + + for (const auto& entry : queuedForResolve) + { + RetryDeferredDependencies(entry, sourceIdToMatchedSearchDependencies[entry.m_sourceID], productMap[entry.m_sourceID]); + } + } + + void PathDependencyManager::SaveUnresolvedDependenciesToDatabase(AssetBuilderSDK::ProductPathDependencySet& unresolvedDependencies, + const AzToolsFramework::AssetDatabase::ProductDatabaseEntry& productEntry, const AZStd::string& platform) { using namespace AzToolsFramework::AssetDatabase; @@ -206,9 +302,9 @@ namespace AssetProcessor } void PathDependencyManager::SaveResolvedDependencies(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry, const MapSet& exclusionMaps, const AZStd::string& sourceNameWithScanFolder, - const AZStd::vector& dependencyEntries, + const AZStd::unordered_set& dependencyEntries, AZStd::string_view matchedPath, bool isSourceDependency, const AzToolsFramework::AssetDatabase::ProductDatabaseEntryContainer& matchedProducts, - AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntryContainer& dependencyContainer) const + AZStd::vector& dependencyContainer) const { for (const auto& productDependencyDatabaseEntry : dependencyEntries) { @@ -267,8 +363,7 @@ namespace AssetProcessor } // All checks passed, this is a valid dependency we need to save to the db - dependencyContainer.push_back(); - auto& entry = dependencyContainer.back(); + AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntry entry; entry.m_productDependencyID = dependencyId; entry.m_productPK = productDependencyDatabaseEntry.m_productPK; @@ -276,62 +371,30 @@ namespace AssetProcessor entry.m_dependencySubID = matchedProduct.m_subID; entry.m_platform = productDependencyDatabaseEntry.m_platform; + dependencyContainer.push_back(AZStd::move(entry)); + // If there's more than 1 product, reset the ID so further products create new db entries dependencyId = AzToolsFramework::AssetDatabase::InvalidEntryId; } } } - void PathDependencyManager::RetryDeferredDependencies(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry) + void PathDependencyManager::RetryDeferredDependencies(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry, + const AZStd::unordered_map>& matches, + const AZStd::vector& products) { MapSet exclusionMaps = PopulateExclusionMaps(); - // Gather a list of all the products this source file produced - AzToolsFramework::AssetDatabase::ProductDatabaseEntryContainer products; - if (!m_stateData->GetProductsBySourceName(sourceEntry.m_sourceName.c_str(), products)) - { - AZ_TracePrintf(AssetProcessor::ConsoleChannel, "Source %s did not have any products. Skipping dependency processing.\n", sourceEntry.m_sourceName.c_str()); - return; - } - - AZStd::unordered_map> map; - - // Build up a list of all the paths we need to search for: products + 2 variations of the source path - AZStd::vector searchPaths; - - for (const auto& productEntry : products) - { - const AZStd::string& productName = productEntry.m_productName; - - // strip path of the / - AZStd::string strippedPath = AssetUtilities::StripAssetPlatform(productName).toUtf8().constData(); - SanitizeForDatabase(strippedPath); - - searchPaths.push_back(strippedPath); - } - AZStd::string sourceNameWithScanFolder = ToScanFolderPrefixedPath(aznumeric_cast(sourceEntry.m_scanFolderPK), sourceEntry.m_sourceName.c_str()); - AZStd::string sanitizedSourceName = sourceEntry.m_sourceName; - SanitizeForDatabase(sourceNameWithScanFolder); - SanitizeForDatabase(sanitizedSourceName); - - searchPaths.push_back(sourceNameWithScanFolder); - searchPaths.push_back(sanitizedSourceName); - - m_stateData->QueryProductDependenciesUnresolvedAdvanced(searchPaths, [&map](AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntry& entry, const AZStd::string& matchedPath) - { - map[matchedPath].push_back(AZStd::move(entry)); - return true; - }); - AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntryContainer dependencyContainer; + AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntryContainer dependencyVector; // Go through all the matched dependencies - for (const auto& pair : map) + for (const auto& pair : matches) { - AZStd::string_view matchedPath = pair.first; - const bool isSourceDependency = matchedPath == sanitizedSourceName || matchedPath == sourceNameWithScanFolder; + const SearchEntry* searchEntry = pair.first; + const bool isSourceDependency = searchEntry->m_isSourcePath; AzToolsFramework::AssetDatabase::ProductDatabaseEntryContainer matchedProducts; @@ -342,34 +405,24 @@ namespace AssetProcessor } else { - for (const auto& productEntry : products) - { - const AZStd::string& productName = productEntry.m_productName; - - // strip path of the leading asset platform / - AZStd::string strippedPath = AssetUtilities::StripAssetPlatform(productName).toUtf8().constData(); - SanitizeForDatabase(strippedPath); - - if (strippedPath == matchedPath) - { - matchedProducts.push_back(productEntry); - } - } + matchedProducts.push_back(*searchEntry->m_productEntry); } // Go through each dependency we're resolving and create a db entry for each product that resolved it (wildcard/source dependencies will generally create more than 1) - SaveResolvedDependencies(sourceEntry, exclusionMaps, sourceNameWithScanFolder, pair.second, matchedPath, isSourceDependency, matchedProducts, dependencyContainer); + SaveResolvedDependencies( + sourceEntry, exclusionMaps, sourceNameWithScanFolder, pair.second, searchEntry->m_path, isSourceDependency, matchedProducts, + dependencyVector); } - // Save everything to the db - if (!m_stateData->UpdateProductDependencies(dependencyContainer)) + // Save everything to the db, this will update matched non-wildcard dependencies and add new records for wildcard matches + if (!m_stateData->UpdateProductDependencies(dependencyVector)) { AZ_Error("PathDependencyManager", false, "Failed to update product dependencies"); } else { // Send a notification for each dependency that has been resolved - NotifyResolvedDependencies(dependencyContainer); + NotifyResolvedDependencies(dependencyVector); } } @@ -460,7 +513,7 @@ namespace AssetProcessor if (isExactDependency) { // Search for products in the cache platform folder - // Example: If a path dependency is "test1.asset" in AutomatedTesting on PC, this would search + // Example: If a path dependency is "test1.asset" in AutomatedTesting on PC, this would search // "AutomatedTesting/Cache/pc/test1.asset" m_stateData->GetProductsByProductName(productNameWithPlatform, productInfoContainer); diff --git a/Code/Tools/AssetProcessor/native/AssetManager/PathDependencyManager.h b/Code/Tools/AssetProcessor/native/AssetManager/PathDependencyManager.h index 3a207ec6a9..763ee2cd74 100644 --- a/Code/Tools/AssetProcessor/native/AssetManager/PathDependencyManager.h +++ b/Code/Tools/AssetProcessor/native/AssetManager/PathDependencyManager.h @@ -39,9 +39,27 @@ namespace AssetProcessor PathDependencyManager(AZStd::shared_ptr stateData, PlatformConfiguration* platformConfig); + void QueueSourceForDependencyResolution(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry); + + void ProcessQueuedDependencyResolves(); + + struct SearchEntry + { + SearchEntry(AZStd::string path, bool isSourcePath, const AzToolsFramework::AssetDatabase::SourceDatabaseEntry* sourceEntry, const AzToolsFramework::AssetDatabase::ProductDatabaseEntry* productEntry) + : m_path(std::move(path)), + m_isSourcePath(isSourcePath), + m_sourceEntry(sourceEntry), + m_productEntry(productEntry) {} + + AZStd::string m_path; + bool m_isSourcePath; + const AzToolsFramework::AssetDatabase::SourceDatabaseEntry* m_sourceEntry = nullptr; + const AzToolsFramework::AssetDatabase::ProductDatabaseEntry* m_productEntry = nullptr; + }; + /// This function is responsible for looking up existing, unresolved dependencies that the current asset satisfies. /// These can be dependencies on either the source asset or one of the product assets - void RetryDeferredDependencies(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry); + void RetryDeferredDependencies(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry, const AZStd::unordered_map>& matches, const AZStd::vector& products); /// This function is responsible for taking the path dependencies output by the current asset and trying to resolve them to AssetIds /// This does not look for dependencies that the current asset satisfies. @@ -66,7 +84,7 @@ namespace AssetProcessor MapSet PopulateExclusionMaps() const; void NotifyResolvedDependencies(const AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntryContainer& dependencyContainer) const; - void SaveResolvedDependencies(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry, const MapSet& exclusionMaps, const AZStd::string& sourceNameWithScanFolder, const AZStd::vector& dependencyEntries, AZStd::string_view matchedPath, bool isSourceDependency, const AzToolsFramework::AssetDatabase::ProductDatabaseEntryContainer& matchedProducts, AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntryContainer& dependencyContainer) const; + void SaveResolvedDependencies(const AzToolsFramework::AssetDatabase::SourceDatabaseEntry& sourceEntry, const MapSet& exclusionMaps, const AZStd::string& sourceNameWithScanFolder, const AZStd::unordered_set& dependencyEntries, AZStd::string_view matchedPath, bool isSourceDependency, const AzToolsFramework::AssetDatabase::ProductDatabaseEntryContainer& matchedProducts, AZStd::vector& dependencyContainer) const; static DependencyProductMap& SelectMap(MapSet& mapSet, bool wildcard, AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntry::DependencyType type); /// Returns false if a path contains wildcards, true otherwise @@ -93,5 +111,6 @@ namespace AssetProcessor AZStd::shared_ptr m_stateData; PlatformConfiguration* m_platformConfig{}; DependencyResolvedCallback m_dependencyResolvedCallback{}; + AZStd::vector m_queuedForResolve; }; } // namespace AssetProcessor diff --git a/Code/Tools/AssetProcessor/native/AssetManager/assetProcessorManager.cpp b/Code/Tools/AssetProcessor/native/AssetManager/assetProcessorManager.cpp index 8867f2379f..beb82dfcab 100644 --- a/Code/Tools/AssetProcessor/native/AssetManager/assetProcessorManager.cpp +++ b/Code/Tools/AssetProcessor/native/AssetManager/assetProcessorManager.cpp @@ -48,7 +48,7 @@ namespace AssetProcessor // note that this is not the first time we're opening the database - the main thread also opens it before this happens, // which allows it to upgrade it and check it for errors. If we get here, it means the database is already good to go. - m_stateData->OpenDatabase(); + m_stateData->OpenDatabase(); MigrateScanFolders(); @@ -70,7 +70,7 @@ namespace AssetProcessor m_excludedFolderCache = AZStd::make_unique(m_platformConfig); PopulateJobStateCache(); - + AssetProcessor::ProcessingJobInfoBus::Handler::BusConnect(); } @@ -126,7 +126,7 @@ namespace AssetProcessor { // capture scanning stats: AssetProcessor::StatsCapture::BeginCaptureStat("AssetScanning"); - + // Ensure that the source file list is populated before a scan begins m_sourceFilesInDatabase.clear(); m_fileModTimes.clear(); @@ -155,11 +155,11 @@ namespace AssetProcessor QString scanFolderPath; QString relativeToScanFolderPath = QString::fromUtf8(entry.m_fileName.c_str()); - + for (int i = 0; i < m_platformConfig->GetScanFolderCount(); ++i) { const auto& scanFolderInfo = m_platformConfig->GetScanFolderAt(i); - + if (scanFolderInfo.ScanFolderID() == entry.m_scanFolderPK) { scanFolderPath = scanFolderInfo.ScanPath(); @@ -181,7 +181,7 @@ namespace AssetProcessor { m_isCurrentlyScanning = false; AssetProcessor::StatsCapture::EndCaptureStat("AssetScanning"); - + // we cannot invoke this immediately - the scanner might be done, but we aren't actually ready until we've processed all remaining messages: QMetaObject::invokeMethod(this, "CheckMissingFiles", Qt::QueuedConnection); } @@ -216,7 +216,7 @@ namespace AssetProcessor else { QString statKey = QString("ProcessJob,%1,%2,%3").arg(jobEntry.m_databaseSourceName).arg(jobEntry.m_jobKey).arg(jobEntry.m_platformInfo.m_identifier.c_str()); - + if (status == JobStatus::InProgress) { //update to in progress status @@ -232,7 +232,7 @@ namespace AssetProcessor // without going thru the RC. // as such, all the code in this block should be crafted to work regardless of whether its double called. AssetProcessor::StatsCapture::EndCaptureStat(statKey.toUtf8().constData()); - + m_jobRunKeyToJobInfoMap.erase(jobEntry.m_jobRunKey); Q_EMIT SourceFinished(sourceUUID, legacySourceUUID); Q_EMIT JobComplete(jobEntry, status); @@ -308,7 +308,7 @@ namespace AssetProcessor //! A network request came in, Given a Job Run Key (from the above Job Request), asking for the actual log for that job. GetAbsoluteAssetDatabaseLocationResponse AssetProcessorManager::ProcessGetAbsoluteAssetDatabaseLocationRequest(MessageData messageData) - { + { GetAbsoluteAssetDatabaseLocationResponse response; AzToolsFramework::AssetDatabase::AssetDatabaseRequestsBus::Broadcast(&AzToolsFramework::AssetDatabase::AssetDatabaseRequests::GetAssetDatabaseLocation, response.m_absoluteAssetDatabaseLocation); @@ -525,7 +525,7 @@ namespace AssetProcessor { foundOne = true; return true; - }, + }, AZ::Uuid::CreateNull(), nullptr, platform.toUtf8().constData(), @@ -750,7 +750,7 @@ namespace AssetProcessor } OnJobStatusChanged(jobEntry, JobStatus::Failed); - + // note that we always print out the failed job status here in both batch and GUI mode. AZ_TracePrintf(AssetProcessor::ConsoleChannel, "Failed %s, (%s)... \n", jobEntry.m_pathRelativeToWatchFolder.toUtf8().constData(), @@ -868,7 +868,7 @@ namespace AssetProcessor && AzFramework::StringFunc::Equal(job.m_platform.c_str(), itProcessedAsset->m_entry.m_platformInfo.m_identifier.c_str())) { // If we are here it implies that for the same source file we have another job that outputs the same product. - // This is usually the case when two builders process the same source file and outputs the same product file. + // This is usually the case when two builders process the same source file and outputs the same product file. remove = true; AZStd::string consoleMsg = AZStd::string::format("Failing Job (source : %s , jobkey %s) because another job (source : %s , jobkey : %s ) outputted the same product %s.\n", itProcessedAsset->m_entry.m_pathRelativeToWatchFolder.toUtf8().constData(), itProcessedAsset->m_entry.m_jobKey.toUtf8().data(), source.m_sourceName.c_str(), job.m_jobKey.c_str(), newProductName.toUtf8().constData()); @@ -1128,7 +1128,7 @@ namespace AssetProcessor QString fullProductPath = m_cacheRootDir.absoluteFilePath(productName); // Strip the from the front of a relative product path - QString relativeProductPath = AssetUtilities::StripAssetPlatform(priorProduct.m_productName); + AZStd::string_view relativeProductPath = AssetUtilities::StripAssetPlatformNoCopy(priorProduct.m_productName); AZ::Data::AssetId assetId(source.m_sourceGuid, priorProduct.m_subID); @@ -1137,7 +1137,7 @@ namespace AssetProcessor AZ::Data::AssetId legacyAssetId(priorProduct.m_legacyGuid, 0); AZ::Data::AssetId legacySourceAssetId(AssetUtilities::CreateSafeSourceUUIDFromName(source.m_sourceName.c_str(), false), priorProduct.m_subID); - AssetNotificationMessage message(relativeProductPath.toUtf8().constData(), AssetNotificationMessage::AssetRemoved, priorProduct.m_assetType, processedAsset.m_entry.m_platformInfo.m_identifier.c_str()); + AssetNotificationMessage message(relativeProductPath, AssetNotificationMessage::AssetRemoved, priorProduct.m_assetType, processedAsset.m_entry.m_platformInfo.m_identifier.c_str()); message.m_assetId = assetId; if (legacyAssetId != assetId) @@ -1271,7 +1271,7 @@ namespace AssetProcessor [&](AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntry& dependencyEntry) { return dependencyEntry.m_dependencySubID == pair.first.m_subID - && dependencyEntry.m_dependencySourceGuid == source.m_sourceGuid; + && dependencyEntry.m_dependencySourceGuid == source.m_sourceGuid; }); if (conflictItr != dependencySet.end()) @@ -1312,14 +1312,14 @@ namespace AssetProcessor // relative file path is gotten by removing the platform and game from the product name // Strip the from the front of a relative product path - QString relativeProductPath = AssetUtilities::StripAssetPlatform(productName.toUtf8().constData()); + AZStd::string relativeProductPath = AssetUtilities::StripAssetPlatform(productName.toUtf8().constData()).toUtf8().constData(); - AssetNotificationMessage message(relativeProductPath.toUtf8().constData(), AssetNotificationMessage::AssetChanged, newProduct.m_assetType, processedAsset.m_entry.m_platformInfo.m_identifier.c_str()); + AssetNotificationMessage message(relativeProductPath, AssetNotificationMessage::AssetChanged, newProduct.m_assetType, processedAsset.m_entry.m_platformInfo.m_identifier.c_str()); AZ::Data::AssetId assetId(source.m_sourceGuid, newProduct.m_subID); AZ::Data::AssetId legacyAssetId(newProduct.m_legacyGuid, 0); AZ::Data::AssetId legacySourceAssetId(AssetUtilities::CreateSafeSourceUUIDFromName(source.m_sourceName.c_str(), false), newProduct.m_subID); - message.m_data = relativeProductPath.toUtf8().data(); + message.m_data = relativeProductPath; message.m_sizeBytes = QFileInfo(fullProductPath).size(); message.m_assetId = assetId; @@ -1350,7 +1350,7 @@ namespace AssetProcessor } Q_EMIT AssetMessage( message); - + AddKnownFoldersRecursivelyForFile(fullProductPath, m_cacheRootDir.absolutePath()); } @@ -1497,7 +1497,7 @@ namespace AssetProcessor // Record the modtime for the metadata file so we don't re-analyze this change again next time AP starts up QFileInfo metadataFileInfo(originalName); auto* scanFolder = m_platformConfig->GetScanFolderForFile(originalName); - + if (scanFolder) { QString databaseName; @@ -1534,7 +1534,7 @@ namespace AssetProcessor for (const QString& absolutePath : absoluteSourcePathList) { // we need to check if its already in the "active files" (things that we are looking over) - // or if its in the "currently being examined" list. The latter is likely to be the smaller list, + // or if its in the "currently being examined" list. The latter is likely to be the smaller list, // so we check it first. Both of those are absolute paths, so we convert to absolute path before // searching those lists: if (m_filesToExamine.find(absolutePath) != m_filesToExamine.end()) @@ -1633,9 +1633,6 @@ namespace AssetProcessor } } - // Strip the from the front of a relative product path - QString relativePath = AssetUtilities::StripAssetPlatform(relativeProductFile.toUtf8().constData()); - //set the fingerprint on the job that made this product for (auto& job : jobs) { @@ -1678,7 +1675,7 @@ namespace AssetProcessor } QString fullProductPath = m_cacheRootDir.absoluteFilePath(product.m_productName.c_str()); - QString relativeProductPath(AssetUtilities::StripAssetPlatform(product.m_productName)); + AZStd::string_view relativeProductPath = AssetUtilities::StripAssetPlatformNoCopy(product.m_productName); QFileInfo productFileInfo(fullProductPath); if (productFileInfo.exists()) { @@ -1725,7 +1722,7 @@ namespace AssetProcessor AZ::Data::AssetId legacyAssetId(product.m_legacyGuid, 0); AZ::Data::AssetId legacySourceAssetId(AssetUtilities::CreateSafeSourceUUIDFromName(source.m_sourceName.c_str(), false), product.m_subID); - AssetNotificationMessage message(relativeProductPath.toUtf8().constData(), AssetNotificationMessage::AssetRemoved, product.m_assetType, job.m_platform.c_str()); + AssetNotificationMessage message(relativeProductPath, AssetNotificationMessage::AssetRemoved, product.m_assetType, job.m_platform.c_str()); message.m_assetId = assetId; if (legacyAssetId != assetId) @@ -1759,7 +1756,7 @@ namespace AssetProcessor // and no overrides exist for it. // we must delete its products. using namespace AzToolsFramework::AssetDatabase; - + // If we fail to delete a product, the deletion event gets requeued // To avoid retrying forever, we keep track of the time of the first deletion failure and only retry // if less than this amount of time has passed. @@ -1832,7 +1829,7 @@ namespace AssetProcessor { return; } - + // Check if this file causes any file types to be re-evaluated CheckMetaDataRealFiles(normalizedPath); @@ -2046,7 +2043,7 @@ namespace AssetProcessor AZ_TracePrintf(AssetProcessor::DebugChannel, "Non-processed file: %s\n", databaseSourceFile.toUtf8().constData()); ++m_numSourcesNotHandledByAnyBuilder; - + // Record the modtime for the file so we know we've already processed it QString absolutePath = QDir(scanFolder->ScanPath()).absoluteFilePath(normalizedPath); @@ -2114,7 +2111,7 @@ namespace AssetProcessor // Check whether another job emitted this job as a job dependency and if true, queue the dependent job source file also JobDesc jobDesc(jobDetails.m_jobEntry.m_databaseSourceName.toUtf8().data(), jobDetails.m_jobEntry.m_jobKey.toUtf8().data(), jobDetails.m_jobEntry.m_platformInfo.m_identifier); - + shouldProcessAsset = true; QFileInfo file(jobDetails.m_jobEntry.GetAbsoluteSourcePath()); QDateTime dateTime(file.lastModified()); @@ -2347,7 +2344,7 @@ namespace AssetProcessor } QString canonicalRootDir = AssetUtilities::NormalizeFilePath(m_cacheRootDir.canonicalPath()); - + FileExamineContainer swapped; m_filesToExamine.swap(swapped); // makes it okay to call CheckSource(...) @@ -2470,7 +2467,7 @@ namespace AssetProcessor AZ_TracePrintf(AssetProcessor::DebugChannel, "ProcessFilesToExamineQueue: Unable to find the relative path.\n"); continue; } - + const ScanFolderInfo* scanFolderInfo = m_platformConfig->GetScanFolderForFile(normalizedPath); relativePathToFile = databasePathToFile; @@ -2494,9 +2491,9 @@ namespace AssetProcessor QString::fromUtf8(jobInfo.m_watchFolder.c_str()), relativePathToFile, databasePathToFile, - jobInfo.m_builderGuid, - *platformFromInfo, - jobInfo.m_jobKey.c_str(), 0, GenerateNewJobRunKey(), + jobInfo.m_builderGuid, + *platformFromInfo, + jobInfo.m_jobKey.c_str(), 0, GenerateNewJobRunKey(), AZ::Uuid::CreateNull()); job.m_autoFail = true; @@ -2597,7 +2594,7 @@ namespace AssetProcessor { // on the other hand, if we found a file it means that a deleted file revealed a file that // was previously overridden by it. - // Because the deleted file may have "revealed" a file with different case, + // Because the deleted file may have "revealed" a file with different case, // we have to actually correct its case here. This is rare, so it should be reasonable // to call the expensive function to discover correct case. QString pathRelativeToScanFolder; @@ -2674,6 +2671,7 @@ namespace AssetProcessor AZ_TracePrintf(ConsoleChannel, "Builder optimization: %i / %i files required full analysis, %i sources found but not processed by anyone\n", m_numSourcesNeedingFullAnalysis, m_numTotalSourcesFound, m_numSourcesNotHandledByAnyBuilder); } + m_pathDependencyManager->ProcessQueuedDependencyResolves(); QTimer::singleShot(20, this, SLOT(RemoveEmptyFolders())); } else @@ -2739,7 +2737,7 @@ namespace AssetProcessor } // over here we also want to invalidate the metafiles on disk map if it COULD Be a metafile - // note that there is no reason to do an expensive exacting computation here, it will be + // note that there is no reason to do an expensive exacting computation here, it will be // done later and cached when m_cachedMetaFilesExistMap is set to false, we just need to // know if its POSSIBLE that its a metafile, cheaply. // if its a metafile match, then invalidate the metafile table. @@ -2752,7 +2750,7 @@ namespace AssetProcessor m_metaFilesWhichActuallyExistOnDisk.clear(); // invalidate the map, force a recompuation later. } } - + } m_AssetProcessorIsBusy = true; @@ -2927,7 +2925,7 @@ namespace AssetProcessor } AZ::u64 fileHash = AssetUtilities::GetFileHash(fileInfo.m_filePath.toUtf8().constData()); - + if(fileHash != databaseHashValue) { // File contents have changed @@ -3149,7 +3147,7 @@ namespace AssetProcessor { AddMetadataFilesForFingerprinting(kvp.first.c_str(), job.m_fingerprintFiles); } - + // Check the current builder jobs with the previous ones in the database: job.m_jobEntry.m_computedFingerprint = AssetUtilities::GenerateFingerprint(job); JobIndentifier jobIndentifier(JobDesc(job.m_jobEntry.m_databaseSourceName.toUtf8().data(), job.m_jobEntry.m_jobKey.toUtf8().data(), job.m_jobEntry.m_platformInfo.m_identifier), job.m_jobEntry.m_builderGuid); @@ -3208,7 +3206,7 @@ namespace AssetProcessor { // If the database knows about the job than it implies that AP has processed it sucessfully at least once // and therefore the dependent job should not cause the job which depends on it to be processed again. - // If however we find a dependent job which is not known to AP then we know this job needs to be processed + // If however we find a dependent job which is not known to AP then we know this job needs to be processed // after all the dependent jobs have completed at least once. AzToolsFramework::AssetDatabase::JobDatabaseEntryContainer jobs; @@ -3238,7 +3236,7 @@ namespace AssetProcessor } else if(sourceFileDependency.m_sourceDependencyType != AssetBuilderSDK::SourceFileDependency::SourceFileDependencyType::Wildcards) { - AZ_TracePrintf(AssetProcessor::ConsoleChannel, "UpdateJobDependency: Failed to find builder dependency for %s job (%s, %s, %s)\n", + AZ_TracePrintf(AssetProcessor::ConsoleChannel, "UpdateJobDependency: Failed to find builder dependency for %s job (%s, %s, %s)\n", job.m_jobEntry.GetAbsoluteSourcePath().toUtf8().constData(), jobDependencyInternal->m_jobDependency.m_sourceFile.m_sourceFileDependencyPath.c_str(), jobDependencyInternal->m_jobDependency.m_jobKey.c_str(), @@ -3262,7 +3260,7 @@ namespace AssetProcessor ++jobDependencySlot; } - // sorting job dependencies as they can effect the fingerprint of the job + // sorting job dependencies as they can effect the fingerprint of the job AZStd::sort(job.m_jobDependencyList.begin(), job.m_jobDependencyList.end(), [](const AssetProcessor::JobDependencyInternal& lhs, const AssetProcessor::JobDependencyInternal& rhs) { @@ -3289,7 +3287,7 @@ namespace AssetProcessor for (const JobDependencyInternal& jobDependencyInternal : job.m_jobDependencyList) { // Loop over all the builderUuid and check whether the corresponding entry exists in the jobsFingerprint map. - // If an entry exists, it implies than we have already send the job over to the RCController + // If an entry exists, it implies than we have already send the job over to the RCController for (auto builderIter = jobDependencyInternal.m_builderUuidList.begin(); builderIter != jobDependencyInternal.m_builderUuidList.end(); ++builderIter) { JobIndentifier jobIdentifier(JobDesc(jobDependencyInternal.m_jobDependency.m_sourceFile.m_sourceFileDependencyPath, @@ -3299,7 +3297,7 @@ namespace AssetProcessor auto jobFound = m_jobFingerprintMap.find(jobIdentifier); if (jobFound == m_jobFingerprintMap.end()) { - // Job cannot be processed, since one of its dependent job hasn't been fingerprinted + // Job cannot be processed, since one of its dependent job hasn't been fingerprinted return false; } } @@ -3317,7 +3315,7 @@ namespace AssetProcessor // and call the CreateJobs function on the builder. // it bundles the results up in a JobToProcessEntry struct, while it is doing this: JobToProcessEntry entry; - + AZ::Uuid sourceUUID = AssetUtilities::CreateSafeSourceUUIDFromName(databasePathToFile.toUtf8().constData()); // first, we put the source UUID in the map so that its present for any other queries: @@ -3375,14 +3373,14 @@ namespace AssetProcessor builderInfo.m_createJobFunction(createJobsRequest, createJobsResponse); AssetProcessor::StatsCapture::EndCaptureStat(statKey.toUtf8().constData()); } - + AssetProcessor::SetThreadLocalJobId(0); bool isBuilderMissingFingerprint = (createJobsResponse.m_result == AssetBuilderSDK::CreateJobsResultCode::Success && !createJobsResponse.m_createJobOutputs.empty() && !createJobsResponse.m_createJobOutputs[0].m_additionalFingerprintInfo.empty() && builderInfo.m_analysisFingerprint.empty()); - + if (createJobsResponse.m_result == AssetBuilderSDK::CreateJobsResultCode::Failed || isBuilderMissingFingerprint) { AZ_TracePrintf(AssetProcessor::ConsoleChannel, "Createjobs Failed: %s.\n", normalizedPath.toUtf8().constData()); @@ -3393,7 +3391,7 @@ namespace AssetProcessor char resolvedBuffer[AZ_MAX_PATH_LEN] = { 0 }; AZ::IO::FileIOBase::GetInstance()->ResolvePath(fullPathToLogFile.c_str(), resolvedBuffer, AZ_MAX_PATH_LEN); - + JobDetails jobdetail; jobdetail.m_jobEntry = JobEntry( scanFolder->ScanPath(), @@ -3486,9 +3484,9 @@ namespace AssetProcessor scanFolder->ScanPath(), actualRelativePath, databasePathToFile, - builderInfo.m_busId, - *infoForPlatform, - jobDescriptor.m_jobKey.c_str(), 0, GenerateNewJobRunKey(), + builderInfo.m_busId, + *infoForPlatform, + jobDescriptor.m_jobKey.c_str(), 0, GenerateNewJobRunKey(), sourceUUID); newJob.m_jobEntry.m_checkExclusiveLock = jobDescriptor.m_checkExclusiveLock; newJob.m_jobParam = AZStd::move(jobDescriptor.m_jobParameters); @@ -3506,7 +3504,7 @@ namespace AssetProcessor newJob.m_jobDependencyList.push_back(JobDependencyInternal(jobDependency)); ++numJobDependencies; } - + // note that until analysis completes, the jobId is not set and neither is the destination pat JobDesc jobDesc(newJob.m_jobEntry.m_databaseSourceName.toUtf8().data(), newJob.m_jobEntry.m_jobKey.toUtf8().data(), newJob.m_jobEntry.m_platformInfo.m_identifier); m_jobDescToBuilderUuidMap[jobDesc].insert(builderInfo.m_busId); @@ -3515,7 +3513,7 @@ namespace AssetProcessor JobIndentifier jobIdentifier(jobDesc, builderInfo.m_busId); { AZStd::lock_guard lock(AssetProcessor::ProcessingJobInfoBus::GetOrCreateContext().m_contextMutex); - m_jobFingerprintMap.erase(jobIdentifier); + m_jobFingerprintMap.erase(jobIdentifier); } entry.m_jobsToAnalyze.push_back(AZStd::move(newJob)); @@ -3578,7 +3576,7 @@ namespace AssetProcessor // instead of a UUID, a path has been provided, prepare and use that. We need to turn it into a database path QString encodedFileData = QString::fromUtf8(sourceDependency.m_sourceFileDependencyPath.c_str()); encodedFileData = AssetUtilities::NormalizeFilePath(encodedFileData); - + if (sourceDependency.m_sourceDependencyType == AssetBuilderSDK::SourceFileDependency::SourceFileDependencyType::Wildcards) { int wildcardIndex = encodedFileData.indexOf("*"); @@ -3653,7 +3651,7 @@ namespace AssetProcessor } // Convert to relative paths - for (auto dependencyItr = resolvedDependencyList.begin(); dependencyItr != resolvedDependencyList.end();) + for (auto dependencyItr = resolvedDependencyList.begin(); dependencyItr != resolvedDependencyList.end();) { QString relativePath, scanFolder; if (m_platformConfig->ConvertToRelativePath(*dependencyItr, relativePath, scanFolder)) @@ -3705,7 +3703,7 @@ namespace AssetProcessor return (!resultDatabaseSourceName.isEmpty()); } - + void AssetProcessorManager::UpdateSourceFileDependenciesDatabase(JobToProcessEntry& entry) { using namespace AzToolsFramework::AssetDatabase; @@ -3738,7 +3736,7 @@ namespace AssetProcessor QString resolvedDatabaseName; if (!ResolveSourceFileDependencyPath(sourceDependency.second, resolvedDatabaseName,resolvedDependencyList)) { - // ResolveDependencyPath should only fail in a data error, otherwise it always outputs something, + // ResolveDependencyPath should only fail in a data error, otherwise it always outputs something, // even if that something starts with the placeholder. continue; } @@ -3759,7 +3757,7 @@ namespace AssetProcessor SourceFileDependencyEntry newDependencyEntry( sourceDependency.first, entry.m_sourceFileInfo.m_databasePath.toUtf8().constData(), - resolvedDatabaseName.toUtf8().constData(), + resolvedDatabaseName.toUtf8().constData(), sourceDependency.second.m_sourceDependencyType == AssetBuilderSDK::SourceFileDependency::SourceFileDependencyType::Wildcards ? SourceFileDependencyEntry::DEP_SourceLikeMatch : SourceFileDependencyEntry::DEP_SourceToSource, !sourceDependency.second.m_sourceFileDependencyUUID.IsNull()); // If the UUID is null, then record that this dependency came from a (resolved) path newDependencies.push_back(AZStd::move(newDependencyEntry)); @@ -3803,7 +3801,7 @@ namespace AssetProcessor } // get all the old dependencies and remove them. This function is comprehensive on all dependencies - // for a given source file so we can just eliminate all of them from that same source file and replace + // for a given source file so we can just eliminate all of them from that same source file and replace // them with all of the new ones for the given source file: AZStd::unordered_set oldDependencies; m_stateData->QueryDependsOnSourceBySourceDependency( @@ -4018,7 +4016,7 @@ namespace AssetProcessor result.m_watchFolder = QString::fromUtf8(scanFolder.m_scanFolder.c_str()); result.m_sourceRelativeToWatchFolder = result.m_sourceDatabaseName; - { + { // this scope exists to restrict the duration of the below lock. AZStd::lock_guard lock(m_sourceUUIDToSourceInfoMapMutex); m_sourceUUIDToSourceInfoMap.insert(AZStd::make_pair(sourceUuid, result)); @@ -4045,9 +4043,9 @@ namespace AssetProcessor auto jobPair = m_jobsToProcess.insert(AZStd::move(jobDetail)); if (!jobPair.second) { - // if we are here it means that this job was already found in the jobs to process list + // if we are here it means that this job was already found in the jobs to process list // and therefore insert failed, we will try to update the iterator manually here. - // Note that if insert fails the original object is not destroyed and therefore we can use move again. + // Note that if insert fails the original object is not destroyed and therefore we can use move again. // we just replaced a job, so we have to decrement its count. UpdateAnalysisTrackerForFile(jobPair.first->m_jobEntry, AnalysisTrackerUpdateType::JobFinished); @@ -4068,7 +4066,7 @@ namespace AssetProcessor QSet absoluteSourceFilePathQueue; QString databasePath; QString scanFolder; - + auto callbackFunction = [this, &absoluteSourceFilePathQueue](SourceFileDependencyEntry& entry) { QString relativeDatabaseName = QString::fromUtf8(entry.m_source.c_str()); @@ -4111,7 +4109,7 @@ namespace AssetProcessor sourceDatabaseEntry.m_sourceName = relativeSourceFilePath.toUtf8().constData(); sourceDatabaseEntry.m_sourceGuid = AssetUtilities::CreateSafeSourceUUIDFromName(sourceDatabaseEntry.m_sourceName.c_str()); - + if (!m_stateData->SetSource(sourceDatabaseEntry)) { AZ_Error(AssetProcessor::ConsoleChannel, false, "Failed to add source to the database!!!"); @@ -4260,7 +4258,7 @@ namespace AssetProcessor { AZ_TracePrintf(DebugChannel, "Builder %s analysis fingerprint changed. Files assigned to it will be re-analyzed.\n", priorBuilderUUID.ToString().c_str()); } - + if (builderIsDirty) { m_anyBuilderChange = true; @@ -4414,7 +4412,7 @@ namespace AssetProcessor source.m_analysisFingerprint.append(builderFP.ToString()); } - m_pathDependencyManager->RetryDeferredDependencies(source); + m_pathDependencyManager->QueueSourceForDependencyResolution(source); m_stateData->SetSource(source); databaseSourceName = source.m_sourceName.c_str(); @@ -4593,7 +4591,7 @@ namespace AssetProcessor { continue; } - + QString firstMatchingFile = m_platformConfig->FindFirstMatchingFile(dep); if (firstMatchingFile.isEmpty()) { @@ -4787,7 +4785,7 @@ namespace AssetProcessor assetIter->m_entry.m_sourceFileUUID); jobdetail.m_autoFail = true; jobdetail.m_critical = true; - jobdetail.m_priority = INT_MAX; // front of the queue. + jobdetail.m_priority = INT_MAX; // front of the queue. jobdetail.m_scanFolder = m_platformConfig->GetScanFolderForFile(assetIter->m_entry.GetAbsoluteSourcePath()); // the new lines make it easier to copy and paste the file names. jobdetail.m_jobParam[AZ_CRC(AutoFailReasonKey)] = autoFailReason; @@ -4859,6 +4857,6 @@ namespace AssetProcessor return filesFound; } - + } // namespace AssetProcessor diff --git a/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcher.cpp b/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcher.cpp index ff9876ebdd..993e7f2760 100644 --- a/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcher.cpp +++ b/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcher.cpp @@ -6,154 +6,119 @@ * */ #include "FileWatcher.h" +#include "AzCore/std/containers/vector.h" #include +#include +#include -////////////////////////////////////////////////////////////////////////////// -/// FolderWatchRoot -void FolderRootWatch::ProcessNewFileEvent(const QString& file) +//! IsSubfolder(folderA, folderB) +//! returns whether folderA is a subfolder of folderB +//! assumptions: absolute paths +static bool IsSubfolder(const QString& folderA, const QString& folderB) { - FileChangeInfo info; - info.m_action = FileAction::FileAction_Added; - info.m_filePath = file; - const bool invoked = QMetaObject::invokeMethod(m_fileWatcher, "AnyFileChange", Qt::QueuedConnection, Q_ARG(FileChangeInfo, info)); - Q_ASSERT(invoked); -} + // lets avoid allocating or messing with memory - this is a MAJOR hotspot as it is called for any file change even in the cache! + if (folderA.length() <= folderB.length()) + { + return false; + } -void FolderRootWatch::ProcessDeleteFileEvent(const QString& file) -{ - FileChangeInfo info; - info.m_action = FileAction::FileAction_Removed; - info.m_filePath = file; - const bool invoked = QMetaObject::invokeMethod(m_fileWatcher, "AnyFileChange", Qt::QueuedConnection, Q_ARG(FileChangeInfo, info)); - Q_ASSERT(invoked); -} + using AZStd::begin; + using AZStd::end; -void FolderRootWatch::ProcessModifyFileEvent(const QString& file) -{ - FileChangeInfo info; - info.m_action = FileAction::FileAction_Modified; - info.m_filePath = file; - const bool invoked = QMetaObject::invokeMethod(m_fileWatcher, "AnyFileChange", Qt::QueuedConnection, Q_ARG(FileChangeInfo, info)); - Q_ASSERT(invoked); + auto isSlash = [](const QChar c) constexpr + { + return c == AZ::IO::WindowsPathSeparator || c == AZ::IO::PosixPathSeparator; + }; + + const auto firstPathSeparator = AZStd::find_if(begin(folderB), end(folderB), [&isSlash](const QChar c) + { + return isSlash(c); + }); + + // Follow the convention used by AZ::IO::Path, and use a case-sensitive comparison on Posix paths + const bool useCaseSensitiveCompare = (firstPathSeparator == end(folderB)) ? true : (*firstPathSeparator == AZ::IO::PosixPathSeparator); + + return AZStd::equal(begin(folderB), end(folderB), begin(folderA), [isSlash, useCaseSensitiveCompare](const QChar charAtB, const QChar charAtA) + { + if (isSlash(charAtA)) + { + return isSlash(charAtB); + } + if (useCaseSensitiveCompare) + { + return charAtA == charAtB; + } + return charAtA.toLower() == charAtB.toLower(); + }); } ////////////////////////////////////////////////////////////////////////// /// FileWatcher FileWatcher::FileWatcher() - : m_nextHandle(0) + : m_platformImpl(AZStd::make_unique()) { - qRegisterMetaType("FileChangeInfo"); + auto makeFilter = [this](auto signal) + { + return [this, signal](QString path) + { + const auto foundWatchRoot = AZStd::find_if(begin(m_folderWatchRoots), end(m_folderWatchRoots), [path](const WatchRoot& watchRoot) + { + return Filter(path, watchRoot); + }); + if (foundWatchRoot == end(m_folderWatchRoots)) + { + return; + } + AZStd::invoke(signal, this, path); + }; + }; + + // The rawFileAdded signals are emitted by the watcher thread. Use a queued + // connection so that the consumers of the notification process the + // notification on the main thread. + connect(this, &FileWatcher::rawFileAdded, this, makeFilter(&FileWatcher::fileAdded), Qt::QueuedConnection); + connect(this, &FileWatcher::rawFileRemoved, this, makeFilter(&FileWatcher::fileRemoved), Qt::QueuedConnection); + connect(this, &FileWatcher::rawFileModified, this, makeFilter(&FileWatcher::fileModified), Qt::QueuedConnection); } FileWatcher::~FileWatcher() { + disconnect(); + StopWatching(); } -int FileWatcher::AddFolderWatch(FolderWatchBase* pFolderWatch) +void FileWatcher::AddFolderWatch(QString directory, bool recursive) { - if (!pFolderWatch) + // Search for an already monitored root that is a parent of `directory`, + // that is already watching subdirectories recursively + const auto found = AZStd::find_if(begin(m_folderWatchRoots), end(m_folderWatchRoots), [directory](const WatchRoot& root) { - return -1; - } - - FolderRootWatch* pFolderRootWatch = nullptr; - - //see if this a sub folder of an already watched root - for (auto rootsIter = m_folderWatchRoots.begin(); !pFolderRootWatch && rootsIter != m_folderWatchRoots.end(); ++rootsIter) - { - if (FolderWatchBase::IsSubfolder(pFolderWatch->m_folder, (*rootsIter)->m_root)) - { - pFolderRootWatch = *rootsIter; - } - } + return root.m_recursive && IsSubfolder(directory, root.m_directory); + }); - bool bCreatedNewRoot = false; - //if its not a sub folder - if (!pFolderRootWatch) + if (found != end(m_folderWatchRoots)) { - //create a new root and start listening for changes - pFolderRootWatch = new FolderRootWatch(pFolderWatch->m_folder); - - //make sure the folder watcher(s) get deleted before this - pFolderRootWatch->setParent(this); - bCreatedNewRoot = true; + // This directory is already watched + return; } - pFolderRootWatch->m_fileWatcher = this; - QObject::connect(this, &FileWatcher::AnyFileChange, pFolderWatch, &FolderWatchBase::OnAnyFileChange); + //create a new root and start listening for changes + m_folderWatchRoots.push_back({directory, recursive}); - if (bCreatedNewRoot) + //since we created a new root, see if the new root is a super folder + //of other roots, if it is then then fold those roots into the new super root + if (recursive) { - if (m_startedWatching) + AZStd::erase_if(m_folderWatchRoots, [directory](const WatchRoot& root) { - pFolderRootWatch->Start(); - } - - //since we created a new root, see if the new root is a super folder - //of other roots, if it is then then fold those roots into the new super root - for (auto rootsIter = m_folderWatchRoots.begin(); rootsIter != m_folderWatchRoots.end(); ) - { - if (FolderWatchBase::IsSubfolder((*rootsIter)->m_root, pFolderWatch->m_folder)) - { - //union the sub folder map over to the new root - pFolderRootWatch->m_subFolderWatchesMap.insert((*rootsIter)->m_subFolderWatchesMap); - - //clear the old root sub folders map so they don't get deleted when we - //delete the old root as they are now pointed to by the new root - (*rootsIter)->m_subFolderWatchesMap.clear(); - - //delete the empty old root, deleting a root will call Stop() - //automatically which kills the thread - delete *rootsIter; - - //remove the old root pointer form the watched list - rootsIter = m_folderWatchRoots.erase(rootsIter); - } - else - { - ++rootsIter; - } - } - - //add the new root to the watched roots - m_folderWatchRoots.push_back(pFolderRootWatch); + return IsSubfolder(root.m_directory, directory); + }); } - - //add to the root - pFolderRootWatch->m_subFolderWatchesMap.insert(m_nextHandle, pFolderWatch); - - m_nextHandle++; - - return m_nextHandle - 1; } -void FileWatcher::RemoveFolderWatch(int handle) +void FileWatcher::ClearFolderWatches() { - for (auto rootsIter = m_folderWatchRoots.begin(); rootsIter != m_folderWatchRoots.end(); ) - { - //find an element by the handle - auto foundIter = (*rootsIter)->m_subFolderWatchesMap.find(handle); - if (foundIter != (*rootsIter)->m_subFolderWatchesMap.end()) - { - //remove the element - (*rootsIter)->m_subFolderWatchesMap.erase(foundIter); - - //we removed a folder watch, if it's empty then there is no reason to keep watching it. - if ((*rootsIter)->m_subFolderWatchesMap.empty()) - { - delete(*rootsIter); - rootsIter = m_folderWatchRoots.erase(rootsIter); - } - else - { - ++rootsIter; - } - } - else - { - ++rootsIter; - } - } + m_folderWatchRoots.clear(); } void FileWatcher::StartWatching() @@ -164,12 +129,18 @@ void FileWatcher::StartWatching() return; } - for (FolderRootWatch* root : m_folderWatchRoots) + if (PlatformStart()) { - root->Start(); + m_thread = AZStd::thread({/*.name=*/ "AssetProcessor FileWatcher thread"}, [this]{ + WatchFolderLoop(); + }); + AZ_TracePrintf(AssetProcessor::ConsoleChannel, "File Change Monitoring started.\n"); + } + else + { + AZ_TracePrintf(AssetProcessor::ConsoleChannel, "File Change Monitoring failed to start.\n"); } - AZ_TracePrintf(AssetProcessor::ConsoleChannel, "File Change Monitoring started.\n"); m_startedWatching = true; } @@ -177,17 +148,35 @@ void FileWatcher::StopWatching() { if (!m_startedWatching) { - AZ_Warning("FileWatcher", false, "StartWatching() called when is not watching for file changes."); + AZ_Warning("FileWatcher", false, "StopWatching() called when is not watching for file changes."); return; } - for (FolderRootWatch* root : m_folderWatchRoots) - { - root->Stop(); - } + PlatformStop(); m_startedWatching = false; } -#include "native/FileWatcher/moc_FileWatcher.cpp" -#include "native/FileWatcher/moc_FileWatcherAPI.cpp" +bool FileWatcher::Filter(QString path, const WatchRoot& watchRoot) +{ + if (!IsSubfolder(path, watchRoot.m_directory)) + { + return false; + } + if (!watchRoot.m_recursive) + { + // filter out subtrees too. + QStringRef subRef = path.rightRef(path.length() - watchRoot.m_directory.length()); + if ((subRef.indexOf('/') != -1) || (subRef.indexOf('\\') != -1)) + { + return false; // filter this out. + } + + // we don't care about subdirs. IsDir is more expensive so we do it after the above filter. + if (QFileInfo(path).isDir()) + { + return false; + } + } + return true; +} diff --git a/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcher.h b/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcher.h index 392f8194a6..b7d8cbe1a4 100644 --- a/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcher.h +++ b/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcher.h @@ -5,62 +5,21 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#ifndef FILEWATCHER_COMPONENT_H -#define FILEWATCHER_COMPONENT_H -////////////////////////////////////////////////////////////////////////// -#if !defined(Q_MOC_RUN) -#include "FileWatcherAPI.h" +#pragma once +#if !defined(Q_MOC_RUN) +#include #include +#include +#include #include #include #include +#include -#include #endif -class FileWatcher; - -////////////////////////////////////////////////////////////////////////// -//! FolderRootWatch -/*! Class used for holding a point in the files system from which file changes are tracked. - * */ -class FolderRootWatch - : public QObject -{ - Q_OBJECT - - friend class FileWatcher; -public: - FolderRootWatch(const QString rootFolder); - virtual ~FolderRootWatch(); - - void ProcessNewFileEvent(const QString& file); - void ProcessDeleteFileEvent(const QString& file); - void ProcessModifyFileEvent(const QString& file); - void ProcessRenameFileEvent(const QString& fileOld, const QString& fileNew); - -public Q_SLOTS: - bool Start(); - void Stop(); - -private: - void WatchFolderLoop(); - -private: - std::thread m_thread; - QString m_root; - QMap m_subFolderWatchesMap; - volatile bool m_shutdownThreadSignal; - FileWatcher* m_fileWatcher; - - // Can't use unique_ptr because this is a QObject and Qt's magic sauce is - // unable to determine the size of the unique_ptr and so fails to compile - struct PlatformImplementation; - PlatformImplementation* m_platformImpl; -}; - ////////////////////////////////////////////////////////////////////////// //! FileWatcher /*! Class that handles creation and deletion of FolderRootWatches based on @@ -73,23 +32,47 @@ class FileWatcher public: FileWatcher(); - virtual ~FileWatcher(); + ~FileWatcher() override; ////////////////////////////////////////////////////////////////////////// - virtual int AddFolderWatch(FolderWatchBase* pFolderWatch); - virtual void RemoveFolderWatch(int handle); + void AddFolderWatch(QString directory, bool recursive = true); + void ClearFolderWatches(); ////////////////////////////////////////////////////////////////////////// - + void StartWatching(); void StopWatching(); Q_SIGNALS: - void AnyFileChange(FileChangeInfo info); + // These signals are emitted when a file under a watched path changes + void fileAdded(QString filePath); + void fileRemoved(QString filePath); + void fileModified(QString filePath); + + // These signals are emitted by the platform implementations when files + // change. Some platforms' file watch APIs do not support non-recursive + // watches, so the signals are filtered before being forwarded to the + // non-"raw" fileAdded/Removed/Modified signals above. + void rawFileAdded(QString filePath, QPrivateSignal); + void rawFileRemoved(QString filePath, QPrivateSignal); + void rawFileModified(QString filePath, QPrivateSignal); private: - int m_nextHandle; - AZStd::vector m_folderWatchRoots; + bool PlatformStart(); + void PlatformStop(); + void WatchFolderLoop(); + + class PlatformImplementation; + friend class PlatformImplementation; + struct WatchRoot + { + QString m_directory; + bool m_recursive; + }; + static bool Filter(QString path, const WatchRoot& watchRoot); + + AZStd::unique_ptr m_platformImpl; + AZStd::vector m_folderWatchRoots; + AZStd::thread m_thread; bool m_startedWatching = false; + AZStd::atomic_bool m_shutdownThreadSignal = false; }; - -#endif//FILEWATCHER_COMPONENT_H diff --git a/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcherAPI.h b/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcherAPI.h deleted file mode 100644 index 155056d477..0000000000 --- a/Code/Tools/AssetProcessor/native/FileWatcher/FileWatcherAPI.h +++ /dev/null @@ -1,222 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef FILEWATCHERAPI_H -#define FILEWATCHERAPI_H - -#include -#include -#include - -////////////////////////////////////////////////////////////////////////// -//! FileAction -/*! Enum for which file changes are tracked. - * */ -enum FileAction -{ - FileAction_None = 0x00, - FileAction_Added = 0x01, - FileAction_Removed = 0x02, - FileAction_Modified = 0x04, - FileAction_Any = 0xFF, -}; -inline FileAction operator | (FileAction a, FileAction b) -{ - return static_cast(static_cast(a) | static_cast(b)); -} -inline FileAction operator & (FileAction a, FileAction b) -{ - return static_cast(static_cast(a) & static_cast(b)); -} - -////////////////////////////////////////////////////////////////////////// -//! FileChangeInfo -/*! Struct for passing along information about file changes. - * */ -struct FileChangeInfo -{ - FileChangeInfo() - : m_action(FileAction::FileAction_None) - {} - FileChangeInfo(const FileChangeInfo& rhs) - : m_action(rhs.m_action) - , m_filePath(rhs.m_filePath) - , m_filePathOld(rhs.m_filePathOld) - { - } - - FileAction m_action; - QString m_filePath; - QString m_filePathOld; -}; - -Q_DECLARE_METATYPE(FileChangeInfo) - -////////////////////////////////////////////////////////////////////////// -//! FolderWatchBase -/*! Class for filtering file changes generated from a root watch. Define your own - *! custom filtering by deriving from this base class and implement your own - *! custom code for what to do when receiving a file change notification. - * */ -class FolderWatchBase - : public QObject -{ - Q_OBJECT - -public: - FolderWatchBase(const QString strFolder, bool bWatchSubtree = true, FileAction fileAction = FileAction::FileAction_Any) - : m_folder(strFolder) - , m_watchSubtree(bWatchSubtree) - , m_fileAction(fileAction) - { - m_folder = QDir::toNativeSeparators(QDir::cleanPath(m_folder) + "/"); - } - - //! IsSubfolder(folderA, folderB) - //! returns whether folderA is a subfolder of folderB - //! assumptions: absolute paths, case insensitive - static bool IsSubfolder(const QString& folderA, const QString& folderB) - { - // lets avoid allocating or messing with memory - this is a MAJOR hotspot as it is called for any file change even in the cache! - int sizeB = folderB.length(); - int sizeA = folderA.length(); - - if (sizeA <= sizeB) - { - return false; - } - - QChar slash1 = QChar('\\'); - QChar slash2 = QChar('/'); - int posA = 0; - - // A is going to be the longer one, so use B: - for (int idx = 0; idx < sizeB; ++idx) - { - QChar charAtA = folderA.at(posA); - QChar charAtB = folderB.at(idx); - - if ((charAtB == slash1) || (charAtB == slash2)) - { - if ((charAtA != slash1) && (charAtA != slash2)) - { - return false; - } - ++posA; - } - else - { - if (charAtA.toLower() != charAtB.toLower()) - { - return false; - } - ++posA; - } - } - return true; - } - - QString m_folder; - bool m_watchSubtree; - FileAction m_fileAction; - -public Q_SLOTS: - void OnAnyFileChange(FileChangeInfo info) - { - //if they set a file action then respect it by rejecting non matching file actions - if (info.m_action & m_fileAction) - { - //is the file is in the folder or subtree (if specified) then call OnFileChange - - if (FolderWatchBase::IsSubfolder(info.m_filePath, m_folder)) - { - OnFileChange(info); - } - } - } - - virtual void OnFileChange(const FileChangeInfo& info) = 0; -}; - -////////////////////////////////////////////////////////////////////////// -//! FolderWatchCallbackEx -/*! Class implements a more complex filtering that can optionally filter for file - *! extension and call different callback for different kinds of file changes - *! generated from a root watch. - *! Notes: - *! - empty extension "" catches all file changes - *! - extension should not include the leading "." - * */ -class FolderWatchCallbackEx - : public FolderWatchBase -{ - Q_OBJECT - -public: - FolderWatchCallbackEx(const QString strFolder, const QString extension, bool bWatchSubtree) - : FolderWatchBase(strFolder, bWatchSubtree) - , m_extension(extension) - { - } - - QString m_extension; - - //on file change call the change callback if passes extension then route - //to specific file action type callback - virtual void OnFileChange(const FileChangeInfo& info) - { - //if they set an extension to watch for only let matching extensions through - QFileInfo fileInfo(info.m_filePath); - - if (!m_watchSubtree) - { - // filter out subtrees too. - QStringRef subRef = info.m_filePath.rightRef(info.m_filePath.length() - m_folder.length()); - if ((subRef.indexOf('/') != -1) || (subRef.indexOf('\\') != -1)) - { - return; // filter this out. - } - - // we don't care about subdirs. IsDir is more expensive so we do it after the above filter. - if (fileInfo.isDir()) - { - return; - } - } - - if (m_extension.isEmpty() || fileInfo.completeSuffix().compare(m_extension, Qt::CaseInsensitive) == 0) - { - if (info.m_action & FileAction::FileAction_Any) - { - Q_EMIT fileChange(info); - } - - if (info.m_action & FileAction::FileAction_Added) - { - Q_EMIT fileAdded(info.m_filePath); - } - - if (info.m_action & FileAction::FileAction_Removed) - { - Q_EMIT fileRemoved(info.m_filePath); - } - - if (info.m_action & FileAction::FileAction_Modified) - { - Q_EMIT fileModified(info.m_filePath); - } - } - } - -Q_SIGNALS: - void fileChange(FileChangeInfo info); - void fileAdded(QString filePath); - void fileRemoved(QString filePath); - void fileModified(QString filePath); -}; - -#endif//FILEWATCHERAPI_H diff --git a/Code/Tools/AssetProcessor/native/assetprocessor.h b/Code/Tools/AssetProcessor/native/assetprocessor.h index 1c13eca200..83eb0464a5 100644 --- a/Code/Tools/AssetProcessor/native/assetprocessor.h +++ b/Code/Tools/AssetProcessor/native/assetprocessor.h @@ -85,7 +85,7 @@ namespace AssetProcessor enum AssetCatalogStatus { - RequiresSaving, + RequiresSaving, UpToDate }; @@ -213,11 +213,11 @@ namespace AssetProcessor bool m_critical = false; int m_priority = -1; - // indicates whether we need to check the server first for the outputs of this job + // indicates whether we need to check the server first for the outputs of this job // before we start processing locally bool m_checkServer = false; - - // Indicates whether this job needs to be processed irrespective of whether its fingerprint got modified or not. + + // Indicates whether this job needs to be processed irrespective of whether its fingerprint got modified or not. bool m_autoProcessJob = false; AssetBuilderSDK::AssetBuilderDesc m_assetBuilderDesc; @@ -251,9 +251,9 @@ namespace AssetProcessor JobDetails() = default; }; - - //! JobDesc struct is used for identifying jobs that need to be processed again - //! because of job dependency declared on them by other jobs + + //! JobDesc struct is used for identifying jobs that need to be processed again + //! because of job dependency declared on them by other jobs struct JobDesc { AZStd::string m_databaseSourceName; @@ -283,7 +283,7 @@ namespace AssetProcessor } }; - //! JobIndentifier is an internal structure that store all the data that can uniquely identify a job + //! JobIndentifier is an internal structure that store all the data that can uniquely identify a job struct JobIndentifier { JobDesc m_jobDesc; diff --git a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerManager.cpp b/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerManager.cpp deleted file mode 100644 index 47b2ca9047..0000000000 --- a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerManager.cpp +++ /dev/null @@ -1,162 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#include "shadercompilerManager.h" -#include "shadercompilerjob.h" - -#include - -#include "native/utilities/assetUtils.h" - -ShaderCompilerManager::ShaderCompilerManager(QObject* parent) - : QObject(parent) - , m_isUnitTesting(false) - , m_numberOfJobsStarted(0) - , m_numberOfJobsEnded(0) - , m_numberOfErrors(0) -{ -} - -ShaderCompilerManager::~ShaderCompilerManager() -{ -} - -void ShaderCompilerManager::process(unsigned int connID, unsigned int type, unsigned int serial, QByteArray payload) -{ - (void)type; - (void)serial; - Q_ASSERT(AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyRequest") == type); - decodeShaderCompilerRequest(connID, payload); -} - -void ShaderCompilerManager::decodeShaderCompilerRequest(unsigned int connID, QByteArray payload) -{ - if (payload.length() < sizeof(unsigned int) + sizeof(unsigned int) + 2 + sizeof(unsigned short)) - { - QString error = "Payload size is too small"; - AZ_Warning(AssetProcessor::ConsoleChannel, false, error.toUtf8().data()); - emit sendErrorMessage(error); - return; - } - - unsigned char* data_end = reinterpret_cast(payload.data() + payload.size()); - unsigned int* requestId = reinterpret_cast(data_end - sizeof(unsigned int)); - unsigned int* serverListSizePtr = reinterpret_cast(data_end - sizeof(unsigned int) - sizeof(unsigned int)); - unsigned short* serverPortPtr = reinterpret_cast(data_end - sizeof(unsigned int) - sizeof(unsigned int) - sizeof(unsigned short)); - - ShaderCompilerRequestMessage msg; - QString error; - - msg.requestId = *requestId; - msg.serverListSize = *serverListSizePtr; - msg.serverPort = *serverPortPtr; - if ((msg.serverListSize <= 0) || (msg.serverListSize > 100000)) - { - error = "Shader Compiler Server List is wrong"; - AZ_Warning(AssetProcessor::ConsoleChannel, false, error.toUtf8().data()); - emit sendErrorMessage(error); - return; - } - if (msg.serverPort == 0) - { - error = "Shader Compiler port is wrong"; - AZ_Warning(AssetProcessor::ConsoleChannel, false, error.toUtf8().data()); - emit sendErrorMessage(error); - return; - } - - char* position_of_first_null = reinterpret_cast(serverPortPtr) - 1;// -1 for null - if ((*position_of_first_null) != '\0') - { - error = "Shader Compiler payload is corrupt,position is not null"; - AZ_Warning(AssetProcessor::ConsoleChannel, false, error.toUtf8().data()); - emit sendErrorMessage(error); - return; - } - char* beginning_of_serverList = position_of_first_null - msg.serverListSize; - char* position_of_second_null = beginning_of_serverList - 1;//-1 for null - - if ((*position_of_second_null) != '\0') - { - error = "Shader Compiler payload is corrupt,position is not null"; - AZ_Warning(AssetProcessor::ConsoleChannel, false, error.toUtf8().data()); - emit sendErrorMessage(error); - return; - } - - unsigned int originalPayloadSize = static_cast(payload.size()) - sizeof(unsigned int) - sizeof(unsigned int) - sizeof(unsigned short) - static_cast(msg.serverListSize) - 2; - msg.serverList = beginning_of_serverList; - msg.originalPayload.insert(0, payload.data(), static_cast(originalPayloadSize)); - ShaderCompilerJob* shaderCompilerJob = new ShaderCompilerJob(); - shaderCompilerJob->initialize(this, msg); - shaderCompilerJob->setIsUnitTesting(m_isUnitTesting); - m_shaderCompilerJobMap[msg.requestId] = connID; - shaderCompilerJob->setAutoDelete(true); - QThreadPool* threadPool = QThreadPool::globalInstance(); - threadPool->start(shaderCompilerJob); -} - -void ShaderCompilerManager::OnShaderCompilerJobComplete(QByteArray payload, unsigned int requestId) -{ - auto iterator = m_shaderCompilerJobMap.find(requestId); - if (iterator != m_shaderCompilerJobMap.end()) - { - sendResponse(iterator.value(), AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyResponse"), 0, payload); - } - else - { - QString error = "Shader Compiler cannot find the connection id"; - AZ_Warning(AssetProcessor::ConsoleChannel, false, error.toUtf8().data()); - emit sendErrorMessage(error); - } -} - -void ShaderCompilerManager::sendResponse(unsigned int connId, unsigned int /*type*/, unsigned int /*serial*/, QByteArray payload) -{ - EBUS_EVENT_ID(connId, AssetProcessor::ConnectionBus, SendRaw, AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyResponse"), 0, payload); -} - -void ShaderCompilerManager::shaderCompilerError(QString errorMessage, QString server, QString timestamp, QString payload) -{ - m_numberOfErrors++; - emit numberOfErrorsChanged(); - emit sendErrorMessageFromShaderJob(errorMessage, server, timestamp, payload); -} - -void ShaderCompilerManager::jobStarted() -{ - m_numberOfJobsStarted++; - emit numberOfJobsStartedChanged(); -} - -void ShaderCompilerManager::jobEnded() -{ - m_numberOfJobsEnded++; - numberOfJobsEndedChanged(); -} - - -void ShaderCompilerManager::setIsUnitTesting(bool isUnitTesting) -{ - m_isUnitTesting = isUnitTesting; -} - -int ShaderCompilerManager::numberOfJobsStarted() -{ - return m_numberOfJobsStarted; -} - -int ShaderCompilerManager::numberOfJobsEnded() -{ - return m_numberOfJobsEnded; -} - -int ShaderCompilerManager::numberOfErrors() -{ - return m_numberOfErrors; -} - diff --git a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerManager.h b/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerManager.h deleted file mode 100644 index cb51ee98f6..0000000000 --- a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerManager.h +++ /dev/null @@ -1,67 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef SHADERCOMPILERMANAGER_H -#define SHADERCOMPILERMANAGER_H - -#if !defined(Q_MOC_RUN) -#include -#include -#include -#include -#endif - -typedef QHash ShaderCompilerJobMap; - -/** - * The Shader Compiler Manager class receive a shader compile request - * and starts a shader compiler job for it - */ -class ShaderCompilerManager - : public QObject -{ - Q_OBJECT - Q_PROPERTY(int numberOfJobsStarted READ numberOfJobsStarted NOTIFY numberOfJobsStartedChanged) - Q_PROPERTY(int numberOfJobsEnded READ numberOfJobsEnded NOTIFY numberOfJobsEndedChanged) - Q_PROPERTY(int numberOfErrors READ numberOfErrors NOTIFY numberOfErrorsChanged) -public: - - explicit ShaderCompilerManager(QObject* parent = 0); - virtual ~ShaderCompilerManager(); - - void process(unsigned int connID, unsigned int type, unsigned int serial, QByteArray payload); - void decodeShaderCompilerRequest(unsigned int connID, QByteArray payload); - void setIsUnitTesting(bool isUnitTesting); - int numberOfJobsStarted(); - int numberOfJobsEnded(); - int numberOfErrors(); - virtual void sendResponse(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload); - -signals: - void sendErrorMessage(QString errorMessage); - void sendErrorMessageFromShaderJob(QString errorMessage, QString server, QString timestamp, QString payload); - void numberOfJobsStartedChanged(); - void numberOfJobsEndedChanged(); - void numberOfErrorsChanged(); - - -public slots: - void OnShaderCompilerJobComplete(QByteArray payload, unsigned int requestId); - void shaderCompilerError(QString errorMessage, QString server, QString timestamp, QString payload); - void jobStarted(); - void jobEnded(); - - -private: - ShaderCompilerJobMap m_shaderCompilerJobMap; - bool m_isUnitTesting; - int m_numberOfJobsStarted; - int m_numberOfJobsEnded; - int m_numberOfErrors; -}; - -#endif // SHADERCOMPILERMANAGER_H diff --git a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerMessages.h b/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerMessages.h deleted file mode 100644 index be90a7b3e5..0000000000 --- a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerMessages.h +++ /dev/null @@ -1,24 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef SHADERCOMPILERMESSAGES_H -#define SHADERCOMPILERMESSAGES_H - -#include -#include - -struct ShaderCompilerRequestMessage -{ - QByteArray originalPayload; - QString serverList; - unsigned short serverPort; - unsigned int serverListSize; - unsigned int requestId; -}; - -#endif //SHADERCOMPILERMESSAGES_H - diff --git a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerModel.cpp b/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerModel.cpp deleted file mode 100644 index 50b5254e79..0000000000 --- a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerModel.cpp +++ /dev/null @@ -1,150 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#include "shadercompilerModel.h" - -namespace -{ - ShaderCompilerModel* s_singleton = nullptr; -} - -ShaderCompilerModel::ShaderCompilerModel(QObject* parent) - : QAbstractItemModel(parent) -{ - Q_ASSERT(s_singleton == nullptr); - s_singleton = this; -} - -ShaderCompilerModel::~ShaderCompilerModel() -{ - s_singleton = nullptr; -} - -ShaderCompilerModel* ShaderCompilerModel::Get() -{ - return s_singleton; -} - -QVariant ShaderCompilerModel::data(const QModelIndex& index, int role) const -{ - if (!index.isValid()) - { - return QVariant(); - } - - int row = index.row(); - - if (row < 0) - { - return QVariant(); - } - if (row >= m_shaderErrorInfoList.count()) - { - return QVariant(); - } - - switch (role) - { - case TimeStampRole: - return m_shaderErrorInfoList[row].m_shaderTimestamp; - case ServerRole: - return m_shaderErrorInfoList[row].m_shaderServerName; - case ErrorRole: - return m_shaderErrorInfoList[row].m_shaderError; - case OriginalRequestRole: - return m_shaderErrorInfoList[row].m_shaderOriginalPayload; - - case Qt::DisplayRole: - switch (index.column()) - { - case ColumnTimeStamp: - return m_shaderErrorInfoList[row].m_shaderTimestamp; - case ColumnServer: - return m_shaderErrorInfoList[row].m_shaderServerName; - case ColumnError: - return m_shaderErrorInfoList[row].m_shaderServerName; - } - } - - return QVariant(); -} - - -Qt::ItemFlags ShaderCompilerModel::flags(const QModelIndex& index) const -{ - (void)index; - return Qt::ItemIsSelectable | Qt::ItemIsEnabled; -} - - -int ShaderCompilerModel::rowCount(const QModelIndex& parent) const -{ - (void)parent; - return m_shaderErrorInfoList.count(); -} - - -QModelIndex ShaderCompilerModel::parent(const QModelIndex&) const -{ - return QModelIndex(); -} - - -QModelIndex ShaderCompilerModel::index(int row, int column, const QModelIndex& parent) const -{ - if (row >= rowCount(parent) || column >= columnCount(parent)) - { - return QModelIndex(); - } - return createIndex(row, column); -} - - -int ShaderCompilerModel::columnCount(const QModelIndex& parent) const -{ - return parent.isValid() ? 0 : Column::Max; -} - - -QVariant ShaderCompilerModel::headerData(int section, Qt::Orientation orientation, int role) const -{ - if (orientation == Qt::Horizontal && role == Qt::DisplayRole) - { - switch (section) - { - case ColumnTimeStamp: - return tr("Time Stamp"); - case ColumnServer: - return tr("Server"); - case ColumnError: - return tr("Error"); - default: - break; - } - } - - return QAbstractItemModel::headerData(section, orientation, role); -} - - -QHash ShaderCompilerModel::roleNames() const -{ - QHash result; - result[TimeStampRole] = "timestamp"; - result[ServerRole] = "server"; - result[ErrorRole] = "error"; - result[OriginalRequestRole] = "originalRequest"; - return result; -} -void ShaderCompilerModel::addShaderErrorInfoEntry(QString errorMessage, QString timestamp, QString payload, QString server) -{ - ShaderCompilerErrorInfo shaderCompileErrorInfo(errorMessage, timestamp, payload, server); - beginInsertRows(QModelIndex(), m_shaderErrorInfoList.size(), m_shaderErrorInfoList.size()); - m_shaderErrorInfoList.append(shaderCompileErrorInfo); - endInsertRows(); -} - diff --git a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerModel.h b/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerModel.h deleted file mode 100644 index 464ca9b5b0..0000000000 --- a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerModel.h +++ /dev/null @@ -1,93 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef SHADERCOMPILERMODEL_H -#define SHADERCOMPILERMODEL_H - -#if !defined(Q_MOC_RUN) -#include -#include -#include -#include -#include -#include -#endif - -class QModelIndex; -class QObject; - -struct ShaderCompilerErrorInfo -{ - QString m_shaderError; - QString m_shaderTimestamp; - QString m_shaderOriginalPayload; - QString m_shaderServerName; - - ShaderCompilerErrorInfo(QString shaderError, QString shaderTimestamp, QString shaderOriginalPayload, QString shaderServerName) - : m_shaderError(shaderError) - , m_shaderTimestamp(shaderTimestamp) - , m_shaderOriginalPayload(shaderOriginalPayload) - , m_shaderServerName(shaderServerName) - { - } -}; - -/** The Shader Compiler model is responsible for capturing error requests - */ -class ShaderCompilerModel - : public QAbstractItemModel -{ - Q_OBJECT -public: - - enum DataRoles - { - TimeStampRole = Qt::UserRole + 1, - ServerRole, - ErrorRole, - OriginalRequestRole, - }; - - enum Column - { - ColumnTimeStamp, - ColumnServer, - ColumnError, - Max - }; - - /// standard Qt constructor - explicit ShaderCompilerModel(QObject* parent = 0); - virtual ~ShaderCompilerModel(); - - // singleton pattern - static ShaderCompilerModel* Get(); - - - /// QAbstractListModel interface - QModelIndex parent(const QModelIndex&) const override; - QModelIndex index(int row, int column, const QModelIndex& parent) const override; - int columnCount(const QModelIndex&) const override; - virtual int rowCount(const QModelIndex& parent) const override; - QVariant headerData(int section, Qt::Orientation orientation, int role) const override; - virtual QVariant data(const QModelIndex& index, int role) const override; - virtual QHash roleNames() const override; - virtual Qt::ItemFlags flags(const QModelIndex& index) const override; - -public slots: - void addShaderErrorInfoEntry(QString errorMessage, QString timestamp, QString payload, QString server); - -private: - - QList m_shaderErrorInfoList; -}; - - -#endif // SHADERCOMPILERMODEL_H - - - diff --git a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerjob.cpp b/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerjob.cpp deleted file mode 100644 index 58f9244616..0000000000 --- a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerjob.cpp +++ /dev/null @@ -1,194 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#include "shadercompilerjob.h" -#include "native/assetprocessor.h" - -#include - -ShaderCompilerJob::ShaderCompilerJob() - : m_isUnitTesting(false) - , m_manager(nullptr) -{ -} - -ShaderCompilerJob::~ShaderCompilerJob() -{ - m_manager = nullptr; -} - -ShaderCompilerRequestMessage ShaderCompilerJob::ShaderCompilerMessage() const -{ - return m_ShaderCompilerMessage; -} - -void ShaderCompilerJob::initialize(QObject* pManager, const ShaderCompilerRequestMessage& ShaderCompilerMessage) -{ - m_manager = pManager; - m_ShaderCompilerMessage = ShaderCompilerMessage; -} - -QString ShaderCompilerJob::getServerAddress() -{ - if (isServerListEmpty()) - { - return QString(); - } - - QString serverAddress; - if (!m_ShaderCompilerMessage.serverList.contains(",")) - { - serverAddress = m_ShaderCompilerMessage.serverList; - m_ShaderCompilerMessage.serverList.clear(); - return serverAddress; - } - - QStringList serverList = m_ShaderCompilerMessage.serverList.split(","); - serverAddress = serverList.takeAt(0); - m_ShaderCompilerMessage.serverList = serverList.join(","); - return serverAddress; -} - -bool ShaderCompilerJob::isServerListEmpty() -{ - return m_ShaderCompilerMessage.serverList.isEmpty(); -} - -bool ShaderCompilerJob::attemptDelivery(QString serverAddress, QByteArray& payload) -{ - QTcpSocket socket; - QString error; - int waitingTime = 8000; // 8 sec timeout for sending. - int jobCompileMaxTime = 1000 * 60; // 60 sec timeout for compilation - if (m_isUnitTesting) - { - waitingTime = 500; - jobCompileMaxTime = 500; - } - - socket.connectToHost(serverAddress, m_ShaderCompilerMessage.serverPort, QIODevice::ReadWrite); - - if (socket.waitForConnected(waitingTime)) - { - qint64 bytesWritten = 0; - qint64 payloadSize = static_cast(m_ShaderCompilerMessage.originalPayload.size()); - // send payload size to server - while (bytesWritten != sizeof(qint64)) - { - qint64 currentWrite = socket.write(reinterpret_cast(&payloadSize) + bytesWritten, - sizeof(qint64) - bytesWritten); - if (currentWrite == -1) - { - //It is important to note that we are only outputting the error to debugchannel only here because - //we are forwarding these error messages upstream to the manager,who will take the appropriate action - error = "Connection Lost:Unable to send data"; - AZ_TracePrintf(AssetProcessor::DebugChannel, error.toUtf8().data()); - QMetaObject::invokeMethod(m_manager, "shaderCompilerError", Qt::QueuedConnection, Q_ARG(QString, error), Q_ARG(QString, QDateTime::currentDateTime().toString()), Q_ARG(QString, QString(m_ShaderCompilerMessage.originalPayload)), Q_ARG(QString, serverAddress)); - return false; - } - socket.flush(); - bytesWritten += currentWrite; - } - bytesWritten = 0; - //send actual payload to server - while (bytesWritten != m_ShaderCompilerMessage.originalPayload.size()) - { - qint64 currentWrite = socket.write(m_ShaderCompilerMessage.originalPayload.data() + bytesWritten, - m_ShaderCompilerMessage.originalPayload.size() - bytesWritten); - if (currentWrite == -1) - { - error = "Connection Lost:Unable to send data"; - AZ_TracePrintf(AssetProcessor::DebugChannel, error.toUtf8().data()); - QMetaObject::invokeMethod(m_manager, "shaderCompilerError", Qt::QueuedConnection, Q_ARG(QString, error), Q_ARG(QString, QDateTime::currentDateTime().toString()), Q_ARG(QString, QString(m_ShaderCompilerMessage.originalPayload)), Q_ARG(QString, serverAddress)); - } - socket.flush(); - bytesWritten += currentWrite; - } - } - else - { - error = "Unable to connect to IP Address " + serverAddress; - AZ_TracePrintf(AssetProcessor::DebugChannel, error.toUtf8().data()); - QMetaObject::invokeMethod(m_manager, "shaderCompilerError", Qt::QueuedConnection, Q_ARG(QString, error), Q_ARG(QString, QDateTime::currentDateTime().toString()), Q_ARG(QString, QString(m_ShaderCompilerMessage.originalPayload)), Q_ARG(QString, serverAddress)); - return false; - } - - unsigned int expectedBytes = sizeof(unsigned int) + sizeof(qint8); - unsigned int bytesReadTotal = 0; - unsigned int messageSize = 0; - bool isMessageSizeKnown = false; - //read the entire payload - while ((bytesReadTotal < expectedBytes + messageSize)) - { - if (socket.bytesAvailable() == 0) - { - if (!socket.waitForReadyRead(jobCompileMaxTime)) - { - error = "Remote IP is taking too long to respond: " + serverAddress; - AZ_TracePrintf(AssetProcessor::DebugChannel, error.toUtf8().data()); - QMetaObject::invokeMethod(m_manager, "shaderCompilerError", Qt::QueuedConnection, Q_ARG(QString, error), Q_ARG(QString, QDateTime::currentDateTime().toString()), Q_ARG(QString, QString(m_ShaderCompilerMessage.originalPayload)), Q_ARG(QString, serverAddress)); - payload.clear(); - return false; - } - } - - qint64 bytesAvailable = socket.bytesAvailable(); - - if (bytesAvailable >= expectedBytes && !isMessageSizeKnown) - { - socket.peek(reinterpret_cast(&messageSize), sizeof(unsigned int)); - payload.resize(expectedBytes + messageSize); - isMessageSizeKnown = true; - } - - if (bytesAvailable > 0) - { - qint64 bytesRead = socket.read(payload.data() + bytesReadTotal, bytesAvailable); - - if (bytesRead <= 0) - { - error = "Connection closed by remote IP Address " + serverAddress; - AZ_TracePrintf(AssetProcessor::DebugChannel, error.toUtf8().data()); - QMetaObject::invokeMethod(m_manager, "shaderCompilerError", Qt::QueuedConnection, Q_ARG(QString, error), Q_ARG(QString, QDateTime::currentDateTime().toString()), Q_ARG(QString, QString(m_ShaderCompilerMessage.originalPayload)), Q_ARG(QString, serverAddress)); - payload.clear(); - return false; - } - - bytesReadTotal = aznumeric_cast(bytesReadTotal + bytesRead); - } - } - - return true; // payload successfully send -} - -void ShaderCompilerJob::run() -{ - QMetaObject::invokeMethod(m_manager, "jobStarted", Qt::QueuedConnection); - QByteArray payload; - //until server list is empty, keep trying - while (!isServerListEmpty()) - { - QString serverAddress = getServerAddress(); - //attempt to send payload - if (attemptDelivery(serverAddress, payload)) - { - break; - } - } - //we are appending request id at the end of every payload, - //therefore in the case of any errors also - //we will be sending atleast four bytes to the game - payload.append(reinterpret_cast(&m_ShaderCompilerMessage.requestId), sizeof(unsigned int)); - QMetaObject::invokeMethod(m_manager, "OnShaderCompilerJobComplete", Qt::QueuedConnection, Q_ARG(QByteArray, payload), Q_ARG(unsigned int, m_ShaderCompilerMessage.requestId)); - QMetaObject::invokeMethod(m_manager, "jobEnded", Qt::QueuedConnection); -} - - -void ShaderCompilerJob::setIsUnitTesting(bool isUnitTesting) -{ - m_isUnitTesting = isUnitTesting; -} diff --git a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerjob.h b/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerjob.h deleted file mode 100644 index 1d72365331..0000000000 --- a/Code/Tools/AssetProcessor/native/shadercompiler/shadercompilerjob.h +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef SHADERCOMPILERJOB_H -#define SHADERCOMPILERJOB_H - -#include -#include "shadercompilerMessages.h" - -class QByteArray; -class QObject; - -/** - * This class is responsible for connecting to the shader compiler server - * and getting back the response to the shader compiler manager - */ -class ShaderCompilerJob - : public QRunnable -{ -public: - - explicit ShaderCompilerJob(); - virtual ~ShaderCompilerJob(); - ShaderCompilerRequestMessage ShaderCompilerMessage() const; - void initialize(QObject* pManager, const ShaderCompilerRequestMessage& ShaderCompilerMessage); - QString getServerAddress(); - bool isServerListEmpty(); - virtual void run() override; - - void setIsUnitTesting(bool isUnitTesting); - - bool attemptDelivery(QString serverAddress, QByteArray& payload); - -private: - ShaderCompilerRequestMessage m_ShaderCompilerMessage; - QObject* m_manager; - bool m_isUnitTesting; -}; - -#endif // SHADERCOMPILERJOB_H diff --git a/Code/Tools/AssetProcessor/native/tests/AssetProcessorTest.cpp b/Code/Tools/AssetProcessor/native/tests/AssetProcessorTest.cpp index 5be9436145..e2b28c1260 100644 --- a/Code/Tools/AssetProcessor/native/tests/AssetProcessorTest.cpp +++ b/Code/Tools/AssetProcessor/native/tests/AssetProcessorTest.cpp @@ -18,8 +18,6 @@ #include -AZ_UNIT_TEST_HOOK(new BaseAssetProcessorTestEnvironment) - namespace AssetProcessor { class UnitTestAppManager : public BatchApplicationManager @@ -35,7 +33,7 @@ namespace AssetProcessor { return false; } - + // tests which use the builder bus plug in their own mock version, so disconnect ours. AssetProcessor::AssetBuilderInfoBus::Handler::BusDisconnect(); @@ -59,7 +57,7 @@ namespace AssetProcessor void SetUp() override { AssetProcessorTest::SetUp(); - + static int numParams = 1; static char processName[] = {"AssetProcessorBatch"}; static char* namePtr = &processName[0]; @@ -147,7 +145,7 @@ namespace AssetProcessor time.start(); actualTest->StartTest(); - + while (!testIsComplete) { QCoreApplication::sendPostedEvents(0, QEvent::DeferredDelete); diff --git a/Code/Tools/AssetProcessor/native/tests/BaseAssetProcessorTest.h b/Code/Tools/AssetProcessor/native/tests/BaseAssetProcessorTest.h index 71d3fa0f6d..be7e78d097 100644 --- a/Code/Tools/AssetProcessor/native/tests/BaseAssetProcessorTest.h +++ b/Code/Tools/AssetProcessor/native/tests/BaseAssetProcessorTest.h @@ -40,12 +40,14 @@ protected: void SetupEnvironment() override { // Setup code + AZ::Environment::Create(nullptr); qInstallMessageHandler(UnitTestMessageHandler); } void TeardownEnvironment() override { qInstallMessageHandler(nullptr); + AZ::Environment::Destroy(); } private: diff --git a/Code/Tools/AssetProcessor/native/tests/PathDependencyManagerTests.cpp b/Code/Tools/AssetProcessor/native/tests/PathDependencyManagerTests.cpp index b20d373307..1d6e92e47e 100644 --- a/Code/Tools/AssetProcessor/native/tests/PathDependencyManagerTests.cpp +++ b/Code/Tools/AssetProcessor/native/tests/PathDependencyManagerTests.cpp @@ -12,13 +12,23 @@ #include "AzToolsFramework/API/AssetDatabaseBus.h" #include "AssetDatabase/AssetDatabase.h" #include +#include +#include +#include +#include namespace UnitTests { class MockDatabaseLocationListener : public AzToolsFramework::AssetDatabase::AssetDatabaseRequests::Bus::Handler { public: - MOCK_METHOD1(GetAssetDatabaseLocation, bool(AZStd::string&)); + bool GetAssetDatabaseLocation(AZStd::string& location) override + { + location = m_databaseLocation; + return true; + } + + AZStd::string m_databaseLocation; }; namespace Util @@ -38,25 +48,45 @@ namespace UnitTests } } - struct PathDependencyDeletionTest - : UnitTest::ScopedAllocatorSetupFixture - , UnitTest::TraceBusRedirector + struct PathDependencyBase + : UnitTest::TraceBusRedirector { - void SetUp() override; - void TearDown() override; + void Init(); + void Destroy(); QTemporaryDir m_tempDir; AZStd::string m_databaseLocation; - ::testing::NiceMock m_databaseLocationListener; + MockDatabaseLocationListener m_databaseLocationListener; AZStd::shared_ptr m_stateData; AZStd::unique_ptr m_platformConfig; + AZStd::unique_ptr m_serializeContext; + AZ::Entity* m_jobManagerEntity{}; + AZ::ComponentDescriptor* m_descriptor{}; }; - void PathDependencyDeletionTest::SetUp() + struct PathDependencyDeletionTest + : UnitTest::ScopedAllocatorSetupFixture + , PathDependencyBase + { + void SetUp() override + { + PathDependencyBase::Init(); + } + + void TearDown() override + { + PathDependencyBase::Destroy(); + } + }; + + void PathDependencyBase::Init() { using namespace ::testing; using namespace AzToolsFramework::AssetDatabase; + ::UnitTest::TestRunner::Instance().m_suppressAsserts = false; + ::UnitTest::TestRunner::Instance().m_suppressErrors = false; + BusConnect(); QDir tempPath(m_tempDir.path()); @@ -68,21 +98,39 @@ namespace UnitTests // ":memory:" databases are one-instance-only, and even if another connection is opened to ":memory:" it would // not share with others created using ":memory:" and get a unique database instead. m_databaseLocation = tempPath.absoluteFilePath("test_database.sqlite").toUtf8().constData(); - - ON_CALL(m_databaseLocationListener, GetAssetDatabaseLocation(_)) - .WillByDefault( - DoAll( // set the 0th argument ref (string) to the database location and return true. - SetArgReferee<0>(m_databaseLocation), - Return(true))); + m_databaseLocationListener.m_databaseLocation = m_databaseLocation; m_stateData = AZStd::shared_ptr(new AssetProcessor::AssetDatabaseConnection()); m_stateData->OpenDatabase(); m_platformConfig = AZStd::make_unique(); + + AZ::AllocatorInstance::Create(); + AZ::AllocatorInstance::Create(); + + m_serializeContext = AZStd::make_unique(); + m_descriptor = AZ::JobManagerComponent::CreateDescriptor(); + m_descriptor->Reflect(m_serializeContext.get()); + + m_jobManagerEntity = aznew AZ::Entity{}; + m_jobManagerEntity->CreateComponent(); + m_jobManagerEntity->Init(); + m_jobManagerEntity->Activate(); } - void PathDependencyDeletionTest::TearDown() + void PathDependencyBase::Destroy() { + m_stateData = nullptr; + m_platformConfig = nullptr; + + m_jobManagerEntity->Deactivate(); + delete m_jobManagerEntity; + + delete m_descriptor; + + AZ::AllocatorInstance::Destroy(); + AZ::AllocatorInstance::Destroy(); + BusDisconnect(); } @@ -91,7 +139,7 @@ namespace UnitTests using namespace AzToolsFramework::AssetDatabase; // Add a product to the db with an unmet dependency - ScanFolderDatabaseEntry scanFolder("folder", "test", "test", ""); + ScanFolderDatabaseEntry scanFolder("folder", "test", "test", 0); m_stateData->SetScanFolder(scanFolder); SourceDatabaseEntry source1, source2; @@ -110,7 +158,8 @@ namespace UnitTests Util::CreateSourceJobAndProduct(m_stateData.get(), scanFolder.m_scanFolderID, source2, job2, product2, "source2.txt", "product2.jpg"); - manager.RetryDeferredDependencies(source2); + manager.QueueSourceForDependencyResolution(source2); + manager.ProcessQueuedDependencyResolves(); } TEST_F(PathDependencyDeletionTest, ExistingSourceWithUnmetDependency_RemovedFromDB_DependentProductCreatedWithoutError) @@ -118,7 +167,7 @@ namespace UnitTests using namespace AzToolsFramework::AssetDatabase; // Add a product to the db with an unmet dependency - ScanFolderDatabaseEntry scanFolder("folder", "test", "test", ""); + ScanFolderDatabaseEntry scanFolder("folder", "test", "test", 0); m_stateData->SetScanFolder(scanFolder); SourceDatabaseEntry source1, source2; @@ -137,7 +186,8 @@ namespace UnitTests Util::CreateSourceJobAndProduct(m_stateData.get(), scanFolder.m_scanFolderID, source2, job2, product2, "source2.txt", "product2.jpg"); - manager.RetryDeferredDependencies(source2); + manager.QueueSourceForDependencyResolution(source2); + manager.ProcessQueuedDependencyResolves(); } TEST_F(PathDependencyDeletionTest, NewSourceWithUnmetDependency_RemovedFromDB_DependentSourceCreatedWithoutError) @@ -147,7 +197,7 @@ namespace UnitTests AssetProcessor::PathDependencyManager manager(m_stateData, m_platformConfig.get()); // Add a product to the db with an unmet dependency - ScanFolderDatabaseEntry scanFolder("folder", "test", "test", ""); + ScanFolderDatabaseEntry scanFolder("folder", "test", "test", 0); m_stateData->SetScanFolder(scanFolder); SourceDatabaseEntry source1, source2; @@ -166,7 +216,8 @@ namespace UnitTests Util::CreateSourceJobAndProduct(m_stateData.get(), scanFolder.m_scanFolderID, source2, job2, product2, "source2.txt", "product2.jpg"); - manager.RetryDeferredDependencies(source2); + manager.QueueSourceForDependencyResolution(source2); + manager.ProcessQueuedDependencyResolves(); } TEST_F(PathDependencyDeletionTest, NewSourceWithUnmetDependency_RemovedFromDB_DependentProductCreatedWithoutError) @@ -176,7 +227,7 @@ namespace UnitTests AssetProcessor::PathDependencyManager manager(m_stateData, m_platformConfig.get()); // Add a product to the db with an unmet dependency - ScanFolderDatabaseEntry scanFolder("folder", "test", "test", ""); + ScanFolderDatabaseEntry scanFolder("folder", "test", "test", 0); m_stateData->SetScanFolder(scanFolder); SourceDatabaseEntry source1, source2; @@ -195,7 +246,8 @@ namespace UnitTests Util::CreateSourceJobAndProduct(m_stateData.get(), scanFolder.m_scanFolderID, source2, job2, product2, "source2.txt", "product2.jpg"); - manager.RetryDeferredDependencies(source2); + manager.QueueSourceForDependencyResolution(source2); + manager.ProcessQueuedDependencyResolves(); } TEST_F(PathDependencyDeletionTest, NewSourceWithUnmetDependency_Wildcard_RemovedFromDB_DependentSourceCreatedWithoutError) @@ -205,7 +257,7 @@ namespace UnitTests AssetProcessor::PathDependencyManager manager(m_stateData, m_platformConfig.get()); // Add a product to the db with an unmet dependency - ScanFolderDatabaseEntry scanFolder("folder", "test", "test", ""); + ScanFolderDatabaseEntry scanFolder("folder", "test", "test", 0); m_stateData->SetScanFolder(scanFolder); SourceDatabaseEntry source1, source2; @@ -224,6 +276,266 @@ namespace UnitTests Util::CreateSourceJobAndProduct(m_stateData.get(), scanFolder.m_scanFolderID, source2, job2, product2, "source2.txt", "product2.jpg"); - manager.RetryDeferredDependencies(source2); + manager.QueueSourceForDependencyResolution(source2); + manager.ProcessQueuedDependencyResolves(); + } + + using PathDependencyTests = PathDependencyDeletionTest; + + TEST_F(PathDependencyTests, SourceAndProductHaveSameName_SourceFileDependency_MatchesSource) + { + using namespace AzToolsFramework::AssetDatabase; + + AssetProcessor::PathDependencyManager manager(m_stateData, m_platformConfig.get()); + + ScanFolderDatabaseEntry scanFolder("folder", "test", "test", 0); + m_stateData->SetScanFolder(scanFolder); + + SourceDatabaseEntry source1, source2; + JobDatabaseEntry job1, job2; + ProductDatabaseEntry product1, product2, product3; + + Util::CreateSourceJobAndProduct( + m_stateData.get(), scanFolder.m_scanFolderID, source1, job1, product1, "source1.txt", "product1.jpg"); + + AssetBuilderSDK::ProductPathDependencySet set; + set.insert(AssetBuilderSDK::ProductPathDependency("*.xml", AssetBuilderSDK::ProductPathDependencyType::SourceFile)); + + manager.SaveUnresolvedDependenciesToDatabase(set, product1, "pc"); + + Util::CreateSourceJobAndProduct( + m_stateData.get(), scanFolder.m_scanFolderID, source2, job2, product2, "source2.xml", "source2.xml"); + + // Create a 2nd product for this source + product3 = ProductDatabaseEntry{ job2.m_jobID, product2.m_subID + 1, "source2.txt", AZ::Data::AssetType::CreateRandom() }; + ASSERT_TRUE(m_stateData->SetProduct(product3)); + + manager.QueueSourceForDependencyResolution(source2); + manager.ProcessQueuedDependencyResolves(); + + ProductDependencyDatabaseEntryContainer productDependencies; + m_stateData->GetProductDependencies(productDependencies); + + EXPECT_EQ(productDependencies.size(), 3); + } + + TEST_F(PathDependencyTests, SourceAndProductHaveSameName_ProductFileDependency_MatchesProduct) + { + using namespace AzToolsFramework::AssetDatabase; + + AssetProcessor::PathDependencyManager manager(m_stateData, m_platformConfig.get()); + + ScanFolderDatabaseEntry scanFolder("folder", "test", "test", 0); + m_stateData->SetScanFolder(scanFolder); + + SourceDatabaseEntry source1, source2; + JobDatabaseEntry job1, job2; + ProductDatabaseEntry product1, product2, product3; + + Util::CreateSourceJobAndProduct( + m_stateData.get(), scanFolder.m_scanFolderID, source1, job1, product1, "source1.txt", "product1.jpg"); + + AssetBuilderSDK::ProductPathDependencySet set; + set.insert(AssetBuilderSDK::ProductPathDependency("*.xml", AssetBuilderSDK::ProductPathDependencyType::ProductFile)); + + manager.SaveUnresolvedDependenciesToDatabase(set, product1, "pc"); + + Util::CreateSourceJobAndProduct( + m_stateData.get(), scanFolder.m_scanFolderID, source2, job2, product2, "source2.xml", "source2.xml"); + + // Create a 2nd product for this source + product3 = ProductDatabaseEntry{job2.m_jobID, product2.m_subID + 1, "source2.txt", AZ::Data::AssetType::CreateRandom()}; + ASSERT_TRUE(m_stateData->SetProduct(product3)); + + manager.QueueSourceForDependencyResolution(source2); + manager.ProcessQueuedDependencyResolves(); + + ProductDependencyDatabaseEntryContainer productDependencies; + m_stateData->GetProductDependencies(productDependencies); + + EXPECT_EQ(productDependencies.size(), 2); } + + struct PathDependencyBenchmarks + : UnitTest::ScopedAllocatorFixture + , PathDependencyBase + { + static inline constexpr int NumTestDependencies = 4; // Must be a multiple of 4 + static inline constexpr int NumTestProducts = 2; // Must be a multiple of 2 + + AzToolsFramework::AssetDatabase::ProductDatabaseEntryContainer m_products; + AzToolsFramework::AssetDatabase::SourceDatabaseEntry m_source1, m_source2, m_source4; + AzToolsFramework::AssetDatabase::JobDatabaseEntry m_job1, m_job2, m_job4; + AzToolsFramework::AssetDatabase::ProductDatabaseEntry m_product1, m_product2, m_product4; + AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntryContainer m_dependencies; + + void SetupTestData() + { + using namespace AzToolsFramework::AssetDatabase; + + ScanFolderDatabaseEntry scanFolder("folder", "test", "test", 0); + ASSERT_TRUE(m_stateData->SetScanFolder(scanFolder)); + + Util::CreateSourceJobAndProduct( + m_stateData.get(), scanFolder.m_scanFolderID, m_source1, m_job1, m_product1, "source1.txt", "product1.jpg"); + + Util::CreateSourceJobAndProduct( + m_stateData.get(), scanFolder.m_scanFolderID, m_source4, m_job4, m_product4, "source4.txt", "product4.jpg"); + + for (int i = 0; i < NumTestDependencies / 2; ++i) + { + m_dependencies.emplace_back( + m_product1.m_productID, AZ::Uuid::CreateNull(), 0, 0, "pc", 0, + AZStd::string::format("folder/folder2/%d_*2.jpg", i).c_str()); + ++i; + m_dependencies.emplace_back( + m_product1.m_productID, AZ::Uuid::CreateNull(), 0, 0, "mac", 0, + AZStd::string::format("folder/folder2/%d_*2.jpg", i).c_str()); + } + + for (int i = 0; i < NumTestDependencies / 2; ++i) + { + m_dependencies.emplace_back( + m_product4.m_productID, AZ::Uuid::CreateNull(), 0, 0, "pc", 0, + AZStd::string::format("folder/folder2/%d_*2.jpg", i).c_str()); + ++i; + m_dependencies.emplace_back( + m_product4.m_productID, AZ::Uuid::CreateNull(), 0, 0, "mac", 0, + AZStd::string::format("folder/folder2/%d_*2.jpg", i).c_str()); + } + + ASSERT_TRUE(m_stateData->SetProductDependencies(m_dependencies)); + + Util::CreateSourceJobAndProduct( + m_stateData.get(), scanFolder.m_scanFolderID, m_source2, m_job2, m_product2, "source2.txt", "product2.jpg"); + + auto job3 = JobDatabaseEntry( + m_source2.m_sourceID, "jobkey", 1111, "mac", AZ::Uuid::CreateRandom(), AzToolsFramework::AssetSystem::JobStatus::Completed, + 4444); + ASSERT_TRUE(m_stateData->SetJob(job3)); + + for (int i = 0; i < NumTestProducts; ++i) + { + m_products.emplace_back( + m_job2.m_jobID, i, AZStd::string::format("pc/folder/folder2/%d_product2.jpg", i).c_str(), + AZ::Data::AssetType::CreateRandom()); + ++i; + m_products.emplace_back( + job3.m_jobID, i, AZStd::string::format("mac/folder/folder2/%d_product2.jpg", i).c_str(), + AZ::Data::AssetType::CreateRandom()); + } + + ASSERT_TRUE(m_stateData->SetProducts(m_products)); + } + + void DoTest() + { + AssetProcessor::PathDependencyManager manager(m_stateData, m_platformConfig.get()); + + manager.QueueSourceForDependencyResolution(m_source2); + manager.ProcessQueuedDependencyResolves(); + } + + void VerifyResult() + { + using namespace AzToolsFramework::AssetDatabase; + + ProductDependencyDatabaseEntryContainer productDependencies; + m_stateData->GetProductDependencies(productDependencies); + + for (int i = 0; i < NumTestDependencies / 2 && i < NumTestProducts; ++i) + { + const auto& product = m_products[i]; + int found = 0; + + for (const auto& unresolvedProductDependency : productDependencies) + { + if (unresolvedProductDependency.m_dependencySourceGuid == m_source2.m_sourceGuid && + unresolvedProductDependency.m_dependencySubID == product.m_subID && + unresolvedProductDependency.m_productPK == m_product1.m_productID) + { + ++found; + } + + if (unresolvedProductDependency.m_dependencySourceGuid == m_source2.m_sourceGuid && + unresolvedProductDependency.m_dependencySubID == product.m_subID && + unresolvedProductDependency.m_productPK == m_product4.m_productID) + { + ++found; + } + + if (found == 2) + break; + } + + EXPECT_TRUE(found == 2) << product.m_productName.c_str() << " was not found"; + } + + EXPECT_EQ(productDependencies.size(), NumTestDependencies * 2); + } + }; + + // For some reason, BENCHMARK_F doesn't seem to call the destructor + // So we'll wrap the class and handle the new/delete ourselves + struct PathDependencyBenchmarksWrapperClass : public ::benchmark::Fixture + { + void SetUp([[maybe_unused]] const benchmark::State& st) override + { + m_benchmarks = new PathDependencyBenchmarks(); + m_benchmarks->Init(); + m_benchmarks->SetupTestData(); + } + + void SetUp([[maybe_unused]] benchmark::State& st) override + { + m_benchmarks = new PathDependencyBenchmarks(); + m_benchmarks->Init(); + m_benchmarks->SetupTestData(); + } + + void TearDown([[maybe_unused]] benchmark::State& st) override + { + m_benchmarks->Destroy(); + delete m_benchmarks; + } + + void TearDown([[maybe_unused]] const benchmark::State& st) override + { + m_benchmarks->Destroy(); + delete m_benchmarks; + } + + PathDependencyBenchmarks* m_benchmarks = {}; + }; + + struct PathDependencyTestValidation + : PathDependencyBenchmarks, ::testing::Test + { + void SetUp() override + { + PathDependencyBase::Init(); + } + void TearDown() override + { + PathDependencyBase::Destroy(); + } + }; + + TEST_F(PathDependencyTestValidation, DeferredWildcardDependencyResolution) + { + SetupTestData(); + DoTest(); + VerifyResult(); + } + + BENCHMARK_F(PathDependencyBenchmarksWrapperClass, BM_DeferredWildcardDependencyResolution)(benchmark::State& state) + { + for (auto _ : state) + { + m_benchmarks->m_stateData->SetProductDependencies(m_benchmarks->m_dependencies); + + m_benchmarks->DoTest(); + } + } + } diff --git a/Code/Tools/AssetProcessor/native/tests/SourceFileRelocatorTests.cpp b/Code/Tools/AssetProcessor/native/tests/SourceFileRelocatorTests.cpp index d7801abb3d..8d52ba23bd 100644 --- a/Code/Tools/AssetProcessor/native/tests/SourceFileRelocatorTests.cpp +++ b/Code/Tools/AssetProcessor/native/tests/SourceFileRelocatorTests.cpp @@ -793,9 +793,9 @@ namespace UnitTests TEST_F(SourceFileRelocatorTest, TestInterface) { - auto* interface = AZ::Interface::Get(); + auto* sourceFileRelocator = AZ::Interface::Get(); - ASSERT_NE(interface, nullptr); + ASSERT_NE(sourceFileRelocator, nullptr); } TEST_F(SourceFileRelocatorTest, Move_Real_Succeeds) diff --git a/Code/Tools/AssetProcessor/native/tests/assetmanager/AssetProcessorManagerTest.cpp b/Code/Tools/AssetProcessor/native/tests/assetmanager/AssetProcessorManagerTest.cpp index 58f76f8da6..0908d0fdb9 100644 --- a/Code/Tools/AssetProcessor/native/tests/assetmanager/AssetProcessorManagerTest.cpp +++ b/Code/Tools/AssetProcessor/native/tests/assetmanager/AssetProcessorManagerTest.cpp @@ -15,6 +15,10 @@ #include #include +#include +#include +#include +#include using namespace AssetProcessor; @@ -26,6 +30,7 @@ public: friend class GTEST_TEST_CLASS_NAME_(MultiplatformPathDependencyTest, AssetProcessed_Impl_MultiplatformDependencies); friend class GTEST_TEST_CLASS_NAME_(MultiplatformPathDependencyTest, AssetProcessed_Impl_MultiplatformDependencies_DeferredResolution); + friend class GTEST_TEST_CLASS_NAME_(MultiplatformPathDependencyTest, SameFilenameForAllPlatforms); friend class GTEST_TEST_CLASS_NAME_(MultiplatformPathDependencyTest, AssetProcessed_Impl_MultiplatformDependencies_SourcePath); @@ -176,8 +181,21 @@ void AssetProcessorManagerTest::SetUp() AssetProcessorTest::SetUp(); + AZ::AllocatorInstance::Create(); + AZ::AllocatorInstance::Create(); + m_data = AZStd::make_unique(); + m_data->m_serializeContext = AZStd::make_unique(); + + m_data->m_descriptor = AZ::JobManagerComponent::CreateDescriptor(); + m_data->m_descriptor->Reflect(m_data->m_serializeContext.get()); + + m_data->m_jobManagerEntity = aznew AZ::Entity{}; + m_data->m_jobManagerEntity->CreateComponent(); + m_data->m_jobManagerEntity->Init(); + m_data->m_jobManagerEntity->Activate(); + m_config.reset(new AssetProcessor::PlatformConfiguration()); m_mockApplicationManager.reset(new AssetProcessor::MockApplicationManager()); @@ -256,6 +274,10 @@ void AssetProcessorManagerTest::SetUp() void AssetProcessorManagerTest::TearDown() { + m_data->m_jobManagerEntity->Deactivate(); + delete m_data->m_jobManagerEntity; + delete m_data->m_descriptor; + m_data = nullptr; QObject::disconnect(m_idleConnection); @@ -271,6 +293,9 @@ void AssetProcessorManagerTest::TearDown() m_qApp.reset(); m_scopeDir.reset(); + AZ::AllocatorInstance::Destroy(); + AZ::AllocatorInstance::Destroy(); + AssetProcessor::AssetProcessorTest::TearDown(); } @@ -1270,7 +1295,8 @@ TEST_F(AbsolutePathProductDependencyTest, AbsolutePathProductDependency_RetryDef AZ::Data::AssetType::CreateNull()); m_assetProcessorManager->m_stateData->SetProduct(matchingProductForDependency); - m_assetProcessorManager->m_pathDependencyManager->RetryDeferredDependencies(matchingSource); + m_assetProcessorManager->m_pathDependencyManager->QueueSourceForDependencyResolution(matchingSource); + m_assetProcessorManager->m_pathDependencyManager->ProcessQueuedDependencyResolves(); // The product dependency ID shouldn't change when it goes from unresolved to resolved. AZStd::vector resolvedProductDependencies; @@ -1405,6 +1431,7 @@ bool PathDependencyTest::ProcessAsset(TestAsset& asset, const OutputAssetSet& ou // tell the APM that the asset has been processed and allow it to bubble through its event queue: m_isIdling = false; m_assetProcessorManager->AssetProcessed(capturedDetails[jobSet].m_jobEntry, processJobResponse); + m_assetProcessorManager->CheckForIdle(); jobSet++; } @@ -2646,6 +2673,44 @@ TEST_F(MultiplatformPathDependencyTest, AssetProcessed_Impl_MultiplatformDepende ASSERT_NE(SearchDependencies(dependencyContainer, asset1.m_products[0]), SearchDependencies(dependencyContainer, asset1.m_products[1])); } +TEST_F(MultiplatformPathDependencyTest, SameFilenameForAllPlatforms) +{ + TestAsset asset2("asset2"); + bool result = ProcessAsset( + asset2, { { ".output" }, { ".output" } }, { { "*1.output", AssetBuilderSDK::ProductPathDependencyType::ProductFile } }, "subfolder1/", + ".txt"); + + ASSERT_TRUE(result); + + TestAsset asset1("asset1"); + result = ProcessAsset(asset1, { { ".output" }, { ".output" } }, {}); + + ASSERT_TRUE(result); + + AssetDatabaseConnection* sharedConnection = m_assetProcessorManager->m_stateData.get(); + ASSERT_TRUE(sharedConnection); + + AzToolsFramework::AssetDatabase::ProductDependencyDatabaseEntryContainer dependencyContainer; + + sharedConnection->GetProductDependencies(dependencyContainer); + int resolvedCount = 0; + int unresolvedCount = 0; + for (const auto& dep : dependencyContainer) + { + if (dep.m_unresolvedPath.empty()) + { + resolvedCount++; + } + else + { + unresolvedCount++; + } + } + ASSERT_EQ(resolvedCount, 2); + ASSERT_EQ(unresolvedCount, 2); + VerifyDependencies(dependencyContainer, { asset1.m_products[0], asset1.m_products[1] }, { "*1.output", "*1.output" }); +} + TEST_F(MultiplatformPathDependencyTest, AssetProcessed_Impl_MultiplatformDependencies_SourcePath) { // One product will be pc, one will be console (order is non-deterministic) @@ -4185,7 +4250,7 @@ TEST_F(LockedFileTest, DeleteFile_LockedProduct_DeleteFails) auto theFile = m_data->m_absolutePath[1].toUtf8(); const char* theFileString = theFile.constData(); auto [sourcePath, productPath] = *m_data->m_productPaths.find(theFileString); - + { QFile file(theFileString); file.remove(); @@ -4257,7 +4322,7 @@ TEST_F(LockedFileTest, DeleteFile_LockedProduct_DeletesWhenReleased) EXPECT_FALSE(QFile::exists(productPath)); EXPECT_EQ(m_data->m_deletedSources.size(), 1); - + EXPECT_GT(m_deleteCounter, 1); // Make sure the AP tried more than once to delete the file m_errorAbsorber->ExpectAsserts(0); } @@ -5364,7 +5429,7 @@ AZStd::vector WildcardSourceDependencyTest::FileAddedTest(const Q void WildcardSourceDependencyTest::SetUp() { AssetProcessorManagerTest::SetUp(); - + QDir tempPath(m_tempDir.path()); // Add a non-recursive scan folder. Only files directly inside of this folder should be picked up, subfolders are ignored @@ -5454,7 +5519,7 @@ TEST_F(WildcardSourceDependencyTest, Relative_Broad) { // Expect all files except for the 2 invalid ones (e and f) AZStd::vector resolvedPaths; - + ASSERT_TRUE(Test("*.foo", resolvedPaths)); ASSERT_THAT(resolvedPaths, ::testing::UnorderedElementsAre("a.foo", "b.foo", "folder/one/c.foo", "folder/one/d.foo", "1a.foo", "1b.foo")); } @@ -5585,7 +5650,7 @@ TEST_F(WildcardSourceDependencyTest, Relative_CacheFolder) { AZStd::vector resolvedPaths; QDir tempPath(m_tempDir.path()); - + ASSERT_TRUE(Test("*cache.foo", resolvedPaths)); ASSERT_THAT(resolvedPaths, ::testing::UnorderedElementsAre()); } @@ -5635,7 +5700,7 @@ TEST_F(WildcardSourceDependencyTest, FilesRemovedAfterInitialCache) ASSERT_EQ(excludedFolders.size(), 3); } - + m_fileStateCache->SignalDeleteEvent(tempPath.absoluteFilePath("subfolder2/redirected/folder/two/ignored")); const auto& excludedFolders = excludedFolderCacheInterface->GetExcludedFolders(); diff --git a/Code/Tools/AssetProcessor/native/tests/assetmanager/AssetProcessorManagerTest.h b/Code/Tools/AssetProcessor/native/tests/assetmanager/AssetProcessorManagerTest.h index 7bbef41f44..c532b08016 100644 --- a/Code/Tools/AssetProcessor/native/tests/assetmanager/AssetProcessorManagerTest.h +++ b/Code/Tools/AssetProcessor/native/tests/assetmanager/AssetProcessorManagerTest.h @@ -23,6 +23,8 @@ #include #include +#include +#include #include #include #include "resourcecompiler/rccontroller.h" @@ -39,7 +41,7 @@ class AssetProcessorManagerTest : public AssetProcessor::AssetProcessorTest { public: - + AssetProcessorManagerTest(); virtual ~AssetProcessorManagerTest() @@ -67,16 +69,19 @@ protected: { AZStd::string m_databaseLocation; ::testing::NiceMock m_databaseLocationListener; + AZ::Entity* m_jobManagerEntity{}; + AZ::ComponentDescriptor* m_descriptor{}; + AZStd::unique_ptr m_serializeContext; }; AZStd::unique_ptr m_data; - + private: int m_argc; char** m_argv; AZStd::unique_ptr m_scopeDir; - AZStd::unique_ptr m_qApp; + AZStd::unique_ptr m_qApp; }; struct AbsolutePathProductDependencyTest diff --git a/Code/Tools/AssetProcessor/native/tests/test_main.cpp b/Code/Tools/AssetProcessor/native/tests/test_main.cpp index e0cdc8cb3c..69f6e9a6c8 100644 --- a/Code/Tools/AssetProcessor/native/tests/test_main.cpp +++ b/Code/Tools/AssetProcessor/native/tests/test_main.cpp @@ -5,76 +5,8 @@ * SPDX-License-Identifier: Apache-2.0 OR MIT * */ -#include "utilities/BatchApplicationManager.h" - #include -#include #include -DECLARE_AZ_UNIT_TEST_MAIN() - -int RunUnitTests(int argc, char* argv[], bool& ranUnitTests) -{ - ranUnitTests = true; - - INVOKE_AZ_UNIT_TEST_MAIN(nullptr); // nullptr turns off default test environment used to catch stray asserts - - // This looks a bit weird, but the macro returns conditionally, so *if* we get here, it means the unit tests didn't run - ranUnitTests = false; - return 0; -} - -int main(int argc, char* argv[]) -{ - qputenv("QT_MAC_DISABLE_FOREGROUND_APPLICATION_TRANSFORM", "1"); - - AZ::Debug::Trace::HandleExceptions(true); - AZ::Test::ApplyGlobalParameters(&argc, argv); - - // If "--unittest" is present on the command line, run unit testing - // and return immediately. Otherwise, continue as normal. - AZ::Test::addTestEnvironment(new BaseAssetProcessorTestEnvironment()); - - bool pauseOnComplete = false; - - if (AZ::Test::ContainsParameter(argc, argv, "--pause-on-completion")) - { - pauseOnComplete = true; - } - - bool ranUnitTests; - int result = RunUnitTests(argc, argv, ranUnitTests); - - if (ranUnitTests) - { - if (pauseOnComplete) - { - system("pause"); - } - - return result; - } - - BatchApplicationManager applicationManager(&argc, &argv); - setvbuf(stdout, NULL, _IONBF, 0); // Disabling output buffering to fix test failures due to incomplete logs - - ApplicationManager::BeforeRunStatus status = applicationManager.BeforeRun(); - - if (status != ApplicationManager::BeforeRunStatus::Status_Success) - { - if (status == ApplicationManager::BeforeRunStatus::Status_Restarting) - { - //AssetProcessor will restart - return 0; - } - else - { - //Initialization failed - return 1; - } - } - - return applicationManager.Run() ? 0 : 1; -} - +AZ_UNIT_TEST_HOOK(new BaseAssetProcessorTestEnvironment) diff --git a/Code/Tools/AssetProcessor/native/ui/AssetTreeItem.cpp b/Code/Tools/AssetProcessor/native/ui/AssetTreeItem.cpp index d8b69a80f5..75823374a0 100644 --- a/Code/Tools/AssetProcessor/native/ui/AssetTreeItem.cpp +++ b/Code/Tools/AssetProcessor/native/ui/AssetTreeItem.cpp @@ -29,14 +29,16 @@ namespace AssetProcessor AssetTreeItem::AssetTreeItem( AZStd::shared_ptr data, QIcon errorIcon, + QIcon folderIcon, + QIcon fileIcon, AssetTreeItem* parentItem) : m_data(data), m_parent(parentItem), - m_errorIcon(errorIcon), // QIcon is implicitily shared. - m_folderIcon(QIcon(QStringLiteral(":/Gallery/Asset_Folder.svg"))), - m_fileIcon(QIcon(QStringLiteral(":/Gallery/Asset_File.svg"))) + m_errorIcon(errorIcon), // QIcon is implicitly shared. + m_folderIcon(folderIcon), + m_fileIcon(fileIcon) { - m_folderIcon.addFile(QStringLiteral(":/Gallery/Asset_Folder.svg"), QSize(), QIcon::Selected); + } AssetTreeItem::~AssetTreeItem() @@ -45,7 +47,7 @@ namespace AssetProcessor AssetTreeItem* AssetTreeItem::CreateChild(AZStd::shared_ptr data) { - m_childItems.emplace_back(new AssetTreeItem(data, m_errorIcon, this)); + m_childItems.emplace_back(new AssetTreeItem(data, m_errorIcon, m_folderIcon, m_fileIcon, this)); return m_childItems.back().get(); } diff --git a/Code/Tools/AssetProcessor/native/ui/AssetTreeItem.h b/Code/Tools/AssetProcessor/native/ui/AssetTreeItem.h index c9bc926c34..f36855adfe 100644 --- a/Code/Tools/AssetProcessor/native/ui/AssetTreeItem.h +++ b/Code/Tools/AssetProcessor/native/ui/AssetTreeItem.h @@ -50,6 +50,8 @@ namespace AssetProcessor explicit AssetTreeItem( AZStd::shared_ptr data, QIcon errorIcon, + QIcon folderIcon, + QIcon fileIcon, AssetTreeItem* parentItem = nullptr); virtual ~AssetTreeItem(); diff --git a/Code/Tools/AssetProcessor/native/ui/AssetTreeModel.cpp b/Code/Tools/AssetProcessor/native/ui/AssetTreeModel.cpp index 8d889343f9..e8540c3d8d 100644 --- a/Code/Tools/AssetProcessor/native/ui/AssetTreeModel.cpp +++ b/Code/Tools/AssetProcessor/native/ui/AssetTreeModel.cpp @@ -16,9 +16,12 @@ namespace AssetProcessor AssetTreeModel::AssetTreeModel(AZStd::shared_ptr sharedDbConnection, QObject *parent) : QAbstractItemModel(parent), - m_sharedDbConnection(sharedDbConnection), - m_errorIcon(QStringLiteral(":/stylesheet/img/logging/error.svg")) + m_sharedDbConnection(sharedDbConnection) + , m_errorIcon(QStringLiteral(":/stylesheet/img/logging/error.svg")) + , m_folderIcon(QIcon(QStringLiteral(":/Gallery/Asset_Folder.svg"))) + , m_fileIcon(QIcon(QStringLiteral(":/Gallery/Asset_File.svg"))) { + m_folderIcon.addFile(QStringLiteral(":/Gallery/Asset_Folder.svg"), QSize(), QIcon::Selected); ApplicationManagerNotifications::Bus::Handler::BusConnect(); AzToolsFramework::AssetDatabase::AssetDatabaseNotificationBus::Handler::BusConnect(); } @@ -40,7 +43,7 @@ namespace AssetProcessor void AssetTreeModel::Reset() { beginResetModel(); - m_root.reset(new AssetTreeItem(AZStd::make_shared("", "", true, AZ::Uuid::CreateNull()), m_errorIcon)); + m_root.reset(new AssetTreeItem(AZStd::make_shared("", "", true, AZ::Uuid::CreateNull()), m_errorIcon, m_folderIcon, m_fileIcon)); ResetModel(); diff --git a/Code/Tools/AssetProcessor/native/ui/AssetTreeModel.h b/Code/Tools/AssetProcessor/native/ui/AssetTreeModel.h index d33bc0bc48..27201c55a3 100644 --- a/Code/Tools/AssetProcessor/native/ui/AssetTreeModel.h +++ b/Code/Tools/AssetProcessor/native/ui/AssetTreeModel.h @@ -54,5 +54,7 @@ namespace AssetProcessor AZStd::shared_ptr m_sharedDbConnection; QIcon m_errorIcon; + QIcon m_folderIcon; + QIcon m_fileIcon; }; } diff --git a/Code/Tools/AssetProcessor/native/ui/MainWindow.cpp b/Code/Tools/AssetProcessor/native/ui/MainWindow.cpp index 70b7ceb009..0837384d95 100644 --- a/Code/Tools/AssetProcessor/native/ui/MainWindow.cpp +++ b/Code/Tools/AssetProcessor/native/ui/MainWindow.cpp @@ -37,7 +37,6 @@ #include "../connection/connection.h" #include "../resourcecompiler/rccontroller.h" #include "../resourcecompiler/RCJobSortFilterProxyModel.h" -#include "../shadercompiler/shadercompilerModel.h" #include @@ -148,7 +147,6 @@ void MainWindow::Activate() ui->buttonList->addTab(QStringLiteral("Jobs")); ui->buttonList->addTab(QStringLiteral("Assets")); ui->buttonList->addTab(QStringLiteral("Logs")); - ui->buttonList->addTab(QStringLiteral("Shaders")); ui->buttonList->addTab(QStringLiteral("Connections")); ui->buttonList->addTab(QStringLiteral("Tools")); @@ -167,7 +165,7 @@ void MainWindow::Activate() ui->connectionTreeView->header()->resizeSection(ConnectionManager::PortColumn, 60); ui->connectionTreeView->header()->resizeSection(ConnectionManager::PlatformColumn, 60); ui->connectionTreeView->header()->resizeSection(ConnectionManager::AutoConnectColumn, 60); - + ui->connectionTreeView->header()->setStretchLastSection(false); connect(ui->connectionTreeView->selectionModel(), &QItemSelectionModel::selectionChanged, this, &MainWindow::OnConnectionSelectionChanged); @@ -191,12 +189,12 @@ void MainWindow::Activate() ui->allowListAllowedListConnectionsListView->setModel(&m_allowedListAddresses); connect(ui->allowedListRejectedConnectionsListView, &QListView::clicked, this, &MainWindow::OnRejectedConnectionsListViewClicked); ui->allowedListRejectedConnectionsListView->setModel(&m_rejectedAddresses); - + connect(ui->allowedListEnableCheckBox, &QCheckBox::toggled, this, &MainWindow::OnAllowedListCheckBoxToggled); - + connect(ui->allowedListAddHostNameToolButton, &QToolButton::clicked, this, &MainWindow::OnAddHostNameAllowedListButtonClicked); connect(ui->allowedListAddIPToolButton, &QPushButton::clicked, this, &MainWindow::OnAddIPAllowedListButtonClicked); - + connect(ui->allowedListToAllowedListToolButton, &QPushButton::clicked, this, &MainWindow::OnToAllowedListButtonClicked); connect(ui->allowedListToRejectedListToolButton, &QToolButton::clicked, this, &MainWindow::OnToRejectedListButtonClicked); @@ -206,7 +204,7 @@ void MainWindow::Activate() QRegExpValidator* hostNameValidator = new QRegExpValidator(validHostName, this); ui->allowedListAddHostNameLineEdit->setValidator(hostNameValidator); - + QRegExpValidator* ipValidator = new QRegExpValidator(validIP, this); ui->allowedListAddIPLineEdit->setValidator(ipValidator); @@ -237,7 +235,7 @@ void MainWindow::Activate() m_logSortFilterProxy->setSourceModel(m_logsModel); m_logSortFilterProxy->setFilterKeyColumn(AzToolsFramework::Logging::LogTableModel::ColumnMessage); m_logSortFilterProxy->setFilterCaseSensitivity(Qt::CaseInsensitive); - + ui->jobLogTableView->setModel(m_logSortFilterProxy); ui->jobLogTableView->setItemDelegate(new AzToolsFramework::Logging::LogTableItemDelegate(ui->jobLogTableView)); ui->jobLogTableView->setExpandOnSelection(); @@ -317,14 +315,6 @@ void MainWindow::Activate() connect(ui->jobFilteredSearchWidget, &AzQtComponents::FilteredSearchWidget::TextFilterChanged, this, writeJobFilterSettings); - //Shader view - ui->shaderTreeView->setModel(m_guiApplicationManager->GetShaderCompilerModel()); - ui->shaderTreeView->header()->resizeSection(ShaderCompilerModel::ColumnTimeStamp, 80); - ui->shaderTreeView->header()->resizeSection(ShaderCompilerModel::ColumnServer, 40); - ui->shaderTreeView->header()->resizeSection(ShaderCompilerModel::ColumnError, 220); - ui->shaderTreeView->header()->setSectionResizeMode(ShaderCompilerModel::ColumnError, QHeaderView::Stretch); - ui->shaderTreeView->header()->setStretchLastSection(false); - // Asset view m_sourceAssetTreeFilterModel = new AssetProcessor::AssetTreeFilterModel(this); m_sourceModel = new AssetProcessor::SourceAssetTreeModel(m_sharedDbConnection, this); @@ -410,7 +400,7 @@ void MainWindow::Activate() bool zeroAnalysisModeFromSettings = settings.value("EnableZeroAnalysis", QVariant(true)).toBool(); settings.endGroup(); - QObject::connect(ui->modtimeSkippingCheckBox, &QCheckBox::stateChanged, this, + QObject::connect(ui->modtimeSkippingCheckBox, &QCheckBox::stateChanged, this, [this](int newCheckState) { bool newOption = newCheckState == Qt::Checked ? true : false; @@ -553,7 +543,7 @@ void MainWindow::OnAddConnection(bool /*checked*/) m_guiApplicationManager->GetConnectionManager()->addUserConnection(); } -void MainWindow::OnAllowedListConnectionsListViewClicked() +void MainWindow::OnAllowedListConnectionsListViewClicked() { ui->allowedListRejectedConnectionsListView->clearSelection(); } @@ -563,7 +553,7 @@ void MainWindow::OnRejectedConnectionsListViewClicked() ui->allowListAllowedListConnectionsListView->clearSelection(); } -void MainWindow::OnAllowedListCheckBoxToggled() +void MainWindow::OnAllowedListCheckBoxToggled() { if (!ui->allowedListEnableCheckBox->isChecked()) { @@ -598,7 +588,7 @@ void MainWindow::OnAllowedListCheckBoxToggled() ui->allowedListToAllowedListToolButton->setEnabled(true); ui->allowedListToRejectedListToolButton->setEnabled(true); } - + m_guiApplicationManager->GetConnectionManager()->AllowedListingEnabled(ui->allowedListEnableCheckBox->isChecked()); } @@ -868,7 +858,7 @@ void MainWindow::OnAssetProcessorStatusChanged(const AssetProcessor::AssetProces text = tr("Working, analyzing jobs remaining %1, processing jobs remaining %2...").arg(m_createJobCount).arg(m_processJobsCount); ui->timerContainerWidget->setVisible(false); ui->productAssetDetailsPanel->SetScanQueueEnabled(false); - + IntervalAssetTabFilterRefresh(); } else @@ -887,7 +877,7 @@ void MainWindow::OnAssetProcessorStatusChanged(const AssetProcessor::AssetProces break; case AssetProcessorStatus::Processing_Jobs: CheckStartProcessTimers(); - m_processJobsCount = entry.m_count; + m_processJobsCount = entry.m_count; if (m_processJobsCount + m_createJobCount > 0) { @@ -993,7 +983,7 @@ void MainWindow::ApplyConfig() ui->jobLogTableView->header()->resizeSection(AzToolsFramework::Logging::LogTableModel::ColumnType, m_config.logTypeColumnWidth); } -MainWindow::LogSortFilterProxy::LogSortFilterProxy(QObject* parentOjbect) : QSortFilterProxyModel(parentOjbect) +MainWindow::LogSortFilterProxy::LogSortFilterProxy(QObject* parentOjbect) : QSortFilterProxyModel(parentOjbect) { } @@ -1312,7 +1302,7 @@ void MainWindow::ShowJobViewContextMenu(const QPoint& pos) ui->sourceAssetDetailsPanel->GoToSource(item->m_elementId.GetInputAssetName().toUtf8().constData()); }); - QString productMenuTitle(tr("View product asset...")); + QString productMenuTitle(tr("View product asset...")); if (item->m_jobState != AzToolsFramework::AssetSystem::JobStatus::Completed) { QString disabledActionTooltip(tr("Only completed jobs are available in the Assets tab.")); @@ -1620,7 +1610,7 @@ void MainWindow::ShowProductAssetContextMenu(const QPoint& pos) { AzQtComponents::ShowFileOnDesktop(pathToProduct.GetValue()); } - + }); QString fileOrFolder(cachedAsset->getChildCount() > 0 ? tr("folder") : tr("file")); diff --git a/Code/Tools/AssetProcessor/native/ui/MainWindow.h b/Code/Tools/AssetProcessor/native/ui/MainWindow.h index 8dc1f3e356..1bec6f982d 100644 --- a/Code/Tools/AssetProcessor/native/ui/MainWindow.h +++ b/Code/Tools/AssetProcessor/native/ui/MainWindow.h @@ -65,7 +65,6 @@ public: Jobs, Assets, Logs, - Shaders, Connections, Tools }; diff --git a/Code/Tools/AssetProcessor/native/ui/MainWindow.ui b/Code/Tools/AssetProcessor/native/ui/MainWindow.ui index d4f341d2b5..9d90beec13 100644 --- a/Code/Tools/AssetProcessor/native/ui/MainWindow.ui +++ b/Code/Tools/AssetProcessor/native/ui/MainWindow.ui @@ -763,59 +763,6 @@ - - - - 0 - - - 0 - - - 0 - - - 0 - - - 0 - - - - - Shaders - - - - - - - - - - - 0 - - - 0 - - - 0 - - - 0 - - - 0 - - - - - - - - - diff --git a/Code/Tools/AssetProcessor/native/unittests/FileWatcherUnitTests.cpp b/Code/Tools/AssetProcessor/native/unittests/FileWatcherUnitTests.cpp index a68b116f3d..2dd911b662 100644 --- a/Code/Tools/AssetProcessor/native/unittests/FileWatcherUnitTests.cpp +++ b/Code/Tools/AssetProcessor/native/unittests/FileWatcherUnitTests.cpp @@ -24,14 +24,12 @@ void FileWatcherUnitTestRunner::StartTest() FileWatcher fileWatcher; - FolderWatchCallbackEx folderWatch(tempPath, "", true); - - fileWatcher.AddFolderWatch(&folderWatch); + fileWatcher.AddFolderWatch(tempPath); fileWatcher.StartWatching(); { // test a single file create/write bool foundFile = false; - auto connection = QObject::connect(&folderWatch, &FolderWatchCallbackEx::fileAdded, this, [&](QString filename) + auto connection = QObject::connect(&fileWatcher, &FileWatcher::fileAdded, this, [&](QString filename) { AZ_TracePrintf(AssetProcessor::DebugChannel, "Single file test Found asset: %s.\n", filename.toUtf8().data()); foundFile = true; @@ -66,7 +64,7 @@ void FileWatcherUnitTestRunner::StartTest() const unsigned long maxFiles = 10000; QSet outstandingFiles; - auto connection = QObject::connect(&folderWatch, &FolderWatchCallbackEx::fileAdded, this, [&](QString filename) + auto connection = QObject::connect(&fileWatcher, &FileWatcher::fileAdded, this, [&](QString filename) { outstandingFiles.remove(filename); }); @@ -122,7 +120,7 @@ void FileWatcherUnitTestRunner::StartTest() { // test deletion bool foundFile = false; - auto connection = QObject::connect(&folderWatch, &FolderWatchCallbackEx::fileRemoved, this, [&](QString filename) + auto connection = QObject::connect(&fileWatcher, &FileWatcher::fileRemoved, this, [&](QString filename) { AZ_TracePrintf(AssetProcessor::DebugChannel, "Deleted asset: %s...\n", filename.toUtf8().data()); foundFile = true; @@ -155,7 +153,7 @@ void FileWatcherUnitTestRunner::StartTest() { bool fileAddCalled = false; QString fileAddName; - auto connectionAdd = QObject::connect(&folderWatch, &FolderWatchCallbackEx::fileAdded, this, [&](QString filename) + auto connectionAdd = QObject::connect(&fileWatcher, &FileWatcher::fileAdded, this, [&](QString filename) { fileAddCalled = true; fileAddName = filename; @@ -163,7 +161,7 @@ void FileWatcherUnitTestRunner::StartTest() bool fileRemoveCalled = false; QString fileRemoveName; - auto connectionRemove = QObject::connect(&folderWatch, &FolderWatchCallbackEx::fileRemoved, this, [&](QString filename) + auto connectionRemove = QObject::connect(&fileWatcher, &FileWatcher::fileRemoved, this, [&](QString filename) { fileRemoveCalled = true; fileRemoveName = filename; @@ -171,7 +169,7 @@ void FileWatcherUnitTestRunner::StartTest() QStringList fileModifiedNames; bool fileModifiedCalled = false; - auto connectionModified = QObject::connect(&folderWatch, &FolderWatchCallbackEx::fileModified, this, [&](QString filename) + auto connectionModified = QObject::connect(&fileWatcher, &FileWatcher::fileModified, this, [&](QString filename) { fileModifiedCalled = true; fileModifiedNames.append(filename); diff --git a/Code/Tools/AssetProcessor/native/unittests/ShaderCompilerUnitTests.cpp b/Code/Tools/AssetProcessor/native/unittests/ShaderCompilerUnitTests.cpp deleted file mode 100644 index f8bab90118..0000000000 --- a/Code/Tools/AssetProcessor/native/unittests/ShaderCompilerUnitTests.cpp +++ /dev/null @@ -1,188 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#include "ShaderCompilerUnitTests.h" -#include "native/connection/connectionManager.h" -#include "native/connection/connection.h" -#include "native/utilities/assetUtils.h" - -#define UNIT_TEST_CONNECT_PORT 12125 - -ShaderCompilerUnitTest::ShaderCompilerUnitTest() -{ - m_connectionManager = ConnectionManager::Get(); - connect(this, SIGNAL(StartUnitTestForGoodShaderCompiler()), this, SLOT(UnitTestForGoodShaderCompiler())); - connect(this, SIGNAL(StartUnitTestForFirstBadShaderCompiler()), this, SLOT(UnitTestForFirstBadShaderCompiler())); - connect(this, SIGNAL(StartUnitTestForSecondBadShaderCompiler()), this, SLOT(UnitTestForSecondBadShaderCompiler())); - connect(this, SIGNAL(StartUnitTestForThirdBadShaderCompiler()), this, SLOT(UnitTestForThirdBadShaderCompiler())); - connect(&m_shaderCompilerManager, SIGNAL(sendErrorMessageFromShaderJob(QString, QString, QString, QString)), this, SLOT(ReceiveShaderCompilerErrorMessage(QString, QString, QString, QString))); - - m_shaderCompilerManager.setIsUnitTesting(true); - m_connectionManager->RegisterService(AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyRequest"), AZStd::bind(&ShaderCompilerManager::process, &m_shaderCompilerManager, AZStd::placeholders::_1, AZStd::placeholders::_2, AZStd::placeholders::_3, AZStd::placeholders::_4)); - ContructPayloadForShaderCompilerServer(m_testPayload); -} - -ShaderCompilerUnitTest::~ShaderCompilerUnitTest() -{ - m_connectionManager->removeConnection(m_connectionId); -} - -void ShaderCompilerUnitTest::ContructPayloadForShaderCompilerServer(QByteArray& payload) -{ - QString testString = "This is a test string"; - QString testServerList = "127.0.0.3,198.51.100.0,127.0.0.1"; // note - 198.51.100.0 is in the 'test' range that will never be assigned to anyone. - unsigned int testServerListLength = static_cast(testServerList.size()); - unsigned short testServerPort = 12348; - unsigned int testRequestId = 1; - qint64 testStringLength = static_cast(testString.size()); - payload.resize(static_cast(testStringLength)); - memcpy(payload.data(), (testString.toStdString().c_str()), testStringLength); - unsigned int payloadSize = payload.size(); - payload.resize(payloadSize + 1 + static_cast(testServerListLength) + 1 + sizeof(unsigned short) + sizeof(unsigned int) + sizeof(unsigned int)); - char* dataStart = payload.data() + payloadSize; - *dataStart = 0;// null - memcpy(payload.data() + payloadSize + 1, (testServerList.toStdString().c_str()), testServerListLength); - dataStart += 1 + testServerListLength; - *dataStart = 0; //null - memcpy(payload.data() + payloadSize + 1 + testServerListLength + 1, reinterpret_cast(&testServerPort), sizeof(unsigned short)); - memcpy(payload.data() + payloadSize + 1 + testServerListLength + 1 + sizeof(unsigned short), reinterpret_cast(&testServerListLength), sizeof(unsigned int)); - memcpy(payload.data() + payloadSize + 1 + testServerListLength + 1 + sizeof(unsigned short) + sizeof(unsigned int), reinterpret_cast(&testRequestId), sizeof(unsigned int)); -} - -void ShaderCompilerUnitTest::StartTest() -{ - m_connectionId = m_connectionManager->addConnection(); - Connection* connection = m_connectionManager->getConnection(m_connectionId); - connection->SetPort(UNIT_TEST_CONNECT_PORT); - connection->SetIpAddress("127.0.0.1"); - connection->SetAutoConnect(true); - UnitTestForGoodShaderCompiler(); -} - -int ShaderCompilerUnitTest::UnitTestPriority() const -{ - return -4; -} - -void ShaderCompilerUnitTest::UnitTestForGoodShaderCompiler() -{ - AZ_TracePrintf("ShaderCompilerUnitTest", " ... Starting test of 'good' shader compiler...\n"); - m_shaderCompilerManager.m_sendResponseCallbackFn = AZStd::bind(&ShaderCompilerUnitTest::VerifyPayloadForGoodShaderCompiler, this , AZStd::placeholders::_1, AZStd::placeholders::_2, AZStd::placeholders::_3, AZStd::placeholders::_4); - m_server.Init("127.0.0.1", 12348); - m_server.setServerStatus(UnitTestShaderCompilerServer::GoodServer); - m_connectionManager->SendMessageToService(m_connectionId, AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyRequest"), 0, m_testPayload); -} - -void ShaderCompilerUnitTest::UnitTestForFirstBadShaderCompiler() -{ - AZ_TracePrintf("ShaderCompilerUnitTest", " ... Starting test of 'bad' shader compiler... (Incomplete Payload)\n"); - m_shaderCompilerManager.m_sendResponseCallbackFn = AZStd::bind(&ShaderCompilerUnitTest::VerifyPayloadForFirstBadShaderCompiler, this, AZStd::placeholders::_1, AZStd::placeholders::_2, AZStd::placeholders::_3, AZStd::placeholders::_4); - m_server.setServerStatus(UnitTestShaderCompilerServer::BadServer_SendsIncompletePayload); - m_connectionManager->SendMessageToService(m_connectionId, AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyRequest"), 0, m_testPayload); -} - -void ShaderCompilerUnitTest::UnitTestForSecondBadShaderCompiler() -{ - AZ_TracePrintf("ShaderCompilerUnitTest", " ... Starting test of 'bad' shader compiler... (Payload followed by disconnection)\n"); - m_shaderCompilerManager.m_sendResponseCallbackFn = AZStd::bind(&ShaderCompilerUnitTest::VerifyPayloadForSecondBadShaderCompiler, this, AZStd::placeholders::_1, AZStd::placeholders::_2, AZStd::placeholders::_3, AZStd::placeholders::_4); - m_server.setServerStatus(UnitTestShaderCompilerServer::BadServer_ReadsPayloadAndDisconnect); - m_connectionManager->SendMessageToService(m_connectionId, AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyRequest"), 0, m_testPayload); -} - -void ShaderCompilerUnitTest::UnitTestForThirdBadShaderCompiler() -{ - AZ_TracePrintf("ShaderCompilerUnitTest", " ... Starting test of 'bad' shader compiler... (Connect but disconnect without data)\n"); - m_shaderCompilerManager.m_sendResponseCallbackFn = AZStd::bind(&ShaderCompilerUnitTest::VerifyPayloadForThirdBadShaderCompiler, this, AZStd::placeholders::_1, AZStd::placeholders::_2, AZStd::placeholders::_3, AZStd::placeholders::_4); - m_server.setServerStatus(UnitTestShaderCompilerServer::BadServer_DisconnectAfterConnect); - m_server.startServer(); - m_connectionManager->SendMessageToService(m_connectionId, AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyRequest"), 0, m_testPayload); -} - -void ShaderCompilerUnitTest::VerifyPayloadForGoodShaderCompiler(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload) -{ - (void) connId; - (void) type; - (void) serial; - m_shaderCompilerManager.m_sendResponseCallbackFn = nullptr; - - unsigned int messageSize; - quint8 status; - QByteArray payloadToCheck; - unsigned int requestId; - memcpy((&messageSize), payload.data(), sizeof(unsigned int)); - memcpy((&status), payload.data() + sizeof(unsigned int), sizeof(unsigned char)); - payloadToCheck.resize(messageSize); - memcpy((payloadToCheck.data()), payload.data() + sizeof(unsigned int) + sizeof(unsigned char), messageSize); - memcpy((&requestId), payload.data() + sizeof(unsigned int) + sizeof(unsigned char) + messageSize, sizeof(unsigned int)); - QString outgoingTestString = "Test string validated"; - if (QString::compare(QString(payloadToCheck), outgoingTestString, Qt::CaseSensitive) != 0) - { - Q_EMIT UnitTestFailed("Unit Test for Good Shader Compiler Failed"); - return; - } - Q_EMIT StartUnitTestForFirstBadShaderCompiler(); -} - -void ShaderCompilerUnitTest::VerifyPayloadForFirstBadShaderCompiler(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload) -{ - (void) connId; - (void) type; - (void) serial; - m_shaderCompilerManager.m_sendResponseCallbackFn = nullptr; - QString error = "Remote IP is taking too long to respond: 127.0.0.1"; - if ((payload.size() != 4) || (QString::compare(m_lastShaderCompilerErrorMessage, error, Qt::CaseSensitive) != 0)) - { - Q_EMIT UnitTestFailed("Unit Test for First Bad Shader Compiler Failed"); - return; - } - m_lastShaderCompilerErrorMessage.clear(); - Q_EMIT StartUnitTestForSecondBadShaderCompiler(); -} - -void ShaderCompilerUnitTest::VerifyPayloadForSecondBadShaderCompiler(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload) -{ - (void) connId; - (void) type; - (void) serial; - m_shaderCompilerManager.m_sendResponseCallbackFn = nullptr; - QString error = "Remote IP is taking too long to respond: 127.0.0.1"; - if ((payload.size() != 4) || (QString::compare(m_lastShaderCompilerErrorMessage, error, Qt::CaseSensitive) != 0)) - { - Q_EMIT UnitTestFailed("Unit Test for Second Bad Shader Compiler Failed"); - return; - } - m_lastShaderCompilerErrorMessage.clear(); - Q_EMIT StartUnitTestForThirdBadShaderCompiler(); -} - -void ShaderCompilerUnitTest::VerifyPayloadForThirdBadShaderCompiler(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload) -{ - (void) connId; - (void) type; - (void) serial; - m_shaderCompilerManager.m_sendResponseCallbackFn = nullptr; - QString error = "Remote IP is taking too long to respond: 127.0.0.1"; - if ((payload.size() != 4) || (QString::compare(m_lastShaderCompilerErrorMessage, error, Qt::CaseSensitive) != 0)) - { - Q_EMIT UnitTestFailed("Unit Test for Third Bad Shader Compiler Failed"); - return; - } - m_lastShaderCompilerErrorMessage.clear(); - Q_EMIT UnitTestPassed(); -} - -void ShaderCompilerUnitTest::ReceiveShaderCompilerErrorMessage(QString error, QString server, QString timestamp, QString payload) -{ - (void) server; - (void) timestamp; - (void) payload; - m_lastShaderCompilerErrorMessage = error; -} - - -REGISTER_UNIT_TEST(ShaderCompilerUnitTest) - diff --git a/Code/Tools/AssetProcessor/native/unittests/ShaderCompilerUnitTests.h b/Code/Tools/AssetProcessor/native/unittests/ShaderCompilerUnitTests.h deleted file mode 100644 index edcff7e949..0000000000 --- a/Code/Tools/AssetProcessor/native/unittests/ShaderCompilerUnitTests.h +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#ifndef SHADERCOMPILERUNITTEST_H -#define SHADERCOMPILERUNITTEST_H - -#if !defined(Q_MOC_RUN) -#include "UnitTestRunner.h" - -#include - -#include "native/shadercompiler/shadercompilerManager.h" -//#include "native/shadercompiler/shadercompilerMessages.h" -#include "native/utilities/UnitTestShaderCompilerServer.h" -#include -#include -#endif - -class ConnectionManager; - -class ShaderCompilerManagerForUnitTest : public ShaderCompilerManager -{ -public: - explicit ShaderCompilerManagerForUnitTest(QObject* parent = 0) : ShaderCompilerManager(parent) {}; - - // for this test, we override sendResponse and make it so that it just calls a callback instead of actually sending it to the connection manager. - void sendResponse(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload) override - { - if (m_sendResponseCallbackFn) - { - m_sendResponseCallbackFn(connId, type, serial, payload); - } - } - AZStd::function m_sendResponseCallbackFn; -}; - -class ShaderCompilerUnitTest - : public UnitTestRun -{ - Q_OBJECT -public: - ShaderCompilerUnitTest(); - ~ShaderCompilerUnitTest(); - virtual void StartTest() override; - virtual int UnitTestPriority() const override; - void ContructPayloadForShaderCompilerServer(QByteArray& payload); - -Q_SIGNALS: - void StartUnitTestForGoodShaderCompiler(); - void StartUnitTestForFirstBadShaderCompiler(); - void StartUnitTestForSecondBadShaderCompiler(); - void StartUnitTestForThirdBadShaderCompiler(); - -public Q_SLOTS: - void UnitTestForGoodShaderCompiler(); - void UnitTestForFirstBadShaderCompiler(); - void UnitTestForSecondBadShaderCompiler(); - void UnitTestForThirdBadShaderCompiler(); - void VerifyPayloadForGoodShaderCompiler(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload); - void VerifyPayloadForFirstBadShaderCompiler(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload); - void VerifyPayloadForSecondBadShaderCompiler(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload); - void VerifyPayloadForThirdBadShaderCompiler(unsigned int connId, unsigned int type, unsigned int serial, QByteArray payload); - void ReceiveShaderCompilerErrorMessage(QString error, QString server, QString timestamp, QString payload); - - -private: - UnitTestShaderCompilerServer m_server; - ShaderCompilerManagerForUnitTest m_shaderCompilerManager; - ConnectionManager* m_connectionManager; - QByteArray m_testPayload; - QString m_lastShaderCompilerErrorMessage; - unsigned int m_connectionId = 0; -}; - -#endif // SHADERCOMPILERUNITTEST_H - - diff --git a/Code/Tools/AssetProcessor/native/utilities/ApplicationManager.cpp b/Code/Tools/AssetProcessor/native/utilities/ApplicationManager.cpp index 7a14f158d6..57884b304f 100644 --- a/Code/Tools/AssetProcessor/native/utilities/ApplicationManager.cpp +++ b/Code/Tools/AssetProcessor/native/utilities/ApplicationManager.cpp @@ -231,44 +231,6 @@ bool ApplicationManager::InitiatedShutdown() const return m_duringShutdown; } -void ApplicationManager::GetExternalBuilderFileList(QStringList& externalBuilderModules) -{ - externalBuilderModules.clear(); - - static const char* builder_folder_name = "Builders"; - - // LY_ASSET_BUILDERS is defined by the CMakeLists.txt. The asset builders add themselves to a variable that - // is populated to allow selective building of those asset builder targets. - // This allows left over Asset builders in the output directory to not be loaded by the AssetProcessor -#if !defined(LY_ASSET_BUILDERS) - #error LY_ASSET_BUILDERS was not defined for ApplicationManager.cpp -#endif - - QDir builderDir = QDir::toNativeSeparators(QString(this->m_frameworkApp.GetExecutableFolder())); - builderDir.cd(QString(builder_folder_name)); - if (builderDir.exists()) - { - AZStd::vector tokens; - AZ::StringFunc::Tokenize(AZStd::string_view(LY_ASSET_BUILDERS), tokens, ','); - AZStd::string builderLibrary; - for (const AZStd::string& token : tokens) - { - QString assetBuilderPath(token.c_str()); - if (builderDir.exists(assetBuilderPath)) - { - externalBuilderModules.push_back(builderDir.absoluteFilePath(assetBuilderPath)); - } - } - } - - if (externalBuilderModules.empty()) - { - AZ_TracePrintf(AssetProcessor::ConsoleChannel, "AssetProcessor was unable to locate any external builders\n"); - } -} - - - QDir ApplicationManager::GetSystemRoot() const { return m_systemRoot; @@ -459,15 +421,6 @@ void ApplicationManager::PopulateApplicationDependencies() m_filesOfInterest.push_back(dir.absoluteFilePath(pathWithPlatformExtension)); } - // Get the external builder modules to add to the files of interest - QStringList builderModuleFileList; - GetExternalBuilderFileList(builderModuleFileList); - for (const QString& builderModuleFile : builderModuleFileList) - { - m_filesOfInterest.push_back(builderModuleFile); - } - - QDir assetRoot; AssetUtilities::ComputeAssetRoot(assetRoot); diff --git a/Code/Tools/AssetProcessor/native/utilities/ApplicationManager.h b/Code/Tools/AssetProcessor/native/utilities/ApplicationManager.h index 91cf2185b7..2ecea4e512 100644 --- a/Code/Tools/AssetProcessor/native/utilities/ApplicationManager.h +++ b/Code/Tools/AssetProcessor/native/utilities/ApplicationManager.h @@ -21,7 +21,6 @@ #include "native/assetprocessor.h" #endif -class FolderWatchCallbackEx; class QCoreApplication; namespace AZ @@ -139,7 +138,7 @@ protected: void RegisterObjectForQuit(QObject* source, bool insertInFront = false); bool NeedRestart() const; void addRunningThread(AssetProcessor::ThreadWorker* thread); - + template void RegisterInternalBuilder(const QString& builderName); @@ -151,9 +150,6 @@ protected: bool m_duringStartup = true; AssetProcessorAZApplication m_frameworkApp; QCoreApplication* m_qApp = nullptr; - - //! Get the list of external builder files for this asset processor - void GetExternalBuilderFileList(QStringList& externalBuilderModules); virtual void Reflect() = 0; virtual const char* GetLogBaseName() = 0; diff --git a/Code/Tools/AssetProcessor/native/utilities/ApplicationManagerBase.cpp b/Code/Tools/AssetProcessor/native/utilities/ApplicationManagerBase.cpp index 499e5fe4f7..36450c4e65 100644 --- a/Code/Tools/AssetProcessor/native/utilities/ApplicationManagerBase.cpp +++ b/Code/Tools/AssetProcessor/native/utilities/ApplicationManagerBase.cpp @@ -25,6 +25,7 @@ #include #include #include +#include #include @@ -32,9 +33,6 @@ #include -//! Amount of time to wait between checking the status of the AssetBuilder process -static const int s_MaximumSleepTimeMS = 10; - //! CreateJobs will wait up to 2 minutes before timing out //! This shouldn't need to be so high but very large slices can take a while to process currently //! This should be reduced down to something more reasonable after slice jobs are sped up @@ -64,6 +62,7 @@ ApplicationManagerBase::~ApplicationManagerBase() AZ::Debug::TraceMessageBus::Handler::BusDisconnect(); AssetProcessor::AssetBuilderRegistrationBus::Handler::BusDisconnect(); AssetBuilderSDK::AssetBuilderBus::Handler::BusDisconnect(); + AssetProcessor::AssetBuilderInfoBus::Handler::BusDisconnect(); if (m_settingsRegistryBuilder) { @@ -192,7 +191,7 @@ void ApplicationManagerBase::InitAssetProcessorManager() { m_assetProcessorManager->SetEnableModtimeSkippingFeature(true); } - + if (commandLine->HasSwitch(Command_enableQueryLogging.m_switch)) { m_assetProcessorManager->SetQueryLogging(true); @@ -206,7 +205,7 @@ void ApplicationManagerBase::InitAssetProcessorManager() { m_dependencyScanPattern = commandLine->GetSwitchValue(Command_dsp.m_switch, 0).c_str(); } - + m_fileDependencyScanPattern = "*"; if (commandLine->HasSwitch(Command_fileDependencyScanPattern.m_switch)) @@ -327,7 +326,7 @@ void ApplicationManagerBase::InitAssetCatalog() AssetProcessor::AssetCatalog* catalog = new AssetCatalog(assetCatalogHelper, m_platformConfiguration); // Using a direct connection so we know the catalog has been updated before continuing on with code might depend on the asset being in the catalog - connect(m_assetProcessorManager, &AssetProcessorManager::AssetMessage, catalog, &AssetCatalog::OnAssetMessage, Qt::DirectConnection); + connect(m_assetProcessorManager, &AssetProcessorManager::AssetMessage, catalog, &AssetCatalog::OnAssetMessage, Qt::DirectConnection); connect(m_assetProcessorManager, &AssetProcessorManager::SourceQueued, catalog, &AssetCatalog::OnSourceQueued); connect(m_assetProcessorManager, &AssetProcessorManager::SourceFinished, catalog, &AssetCatalog::OnSourceFinished); connect(m_assetProcessorManager, &AssetProcessorManager::PathDependencyResolved, catalog, &AssetCatalog::OnDependencyResolved); @@ -379,12 +378,12 @@ void ApplicationManagerBase::InitAssetScanner() QObject::connect(m_assetScanner, &AssetScanner::FilesFound, [this](QSet files) { m_fileStateCache->AddInfoSet(files); }); QObject::connect(m_assetScanner, &AssetScanner::FoldersFound, [this](QSet files) { m_fileStateCache->AddInfoSet(files); }); QObject::connect(m_assetScanner, &AssetScanner::ExcludedFound, [this](QSet files) { m_fileStateCache->AddInfoSet(files); }); - + // file table QObject::connect(m_assetScanner, &AssetScanner::AssetScanningStatusChanged, m_fileProcessor.get(), &FileProcessor::OnAssetScannerStatusChange); QObject::connect(m_assetScanner, &AssetScanner::FilesFound, m_fileProcessor.get(), &FileProcessor::AssessFilesFromScanner); QObject::connect(m_assetScanner, &AssetScanner::FoldersFound, m_fileProcessor.get(), &FileProcessor::AssessFoldersFromScanner); - + } void ApplicationManagerBase::DestroyAssetScanner() @@ -434,63 +433,77 @@ void ApplicationManagerBase::DestroyPlatformConfiguration() void ApplicationManagerBase::InitFileMonitor() { - m_folderWatches.reserve(m_platformConfiguration->GetScanFolderCount()); - m_watchHandles.reserve(m_platformConfiguration->GetScanFolderCount()); for (int folderIdx = 0; folderIdx < m_platformConfiguration->GetScanFolderCount(); ++folderIdx) { const AssetProcessor::ScanFolderInfo& info = m_platformConfiguration->GetScanFolderAt(folderIdx); - - FolderWatchCallbackEx* newFolderWatch = new FolderWatchCallbackEx(info.ScanPath(), "", info.RecurseSubFolders()); - // hook folder watcher to assess files on add/modify - // relevant files will be sent to resource compiler - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileAdded, - m_assetProcessorManager, &AssetProcessor::AssetProcessorManager::AssessAddedFile); - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileModified, - m_assetProcessorManager, &AssetProcessor::AssetProcessorManager::AssessModifiedFile); - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileRemoved, - m_assetProcessorManager, &AssetProcessor::AssetProcessorManager::AssessDeletedFile); - - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileAdded, [this](QString path) { m_fileStateCache->AddFile(path); }); - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileModified, [this](QString path) { m_fileStateCache->UpdateFile(path); }); - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileRemoved, [this](QString path) { m_fileStateCache->RemoveFile(path); }); - - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileAdded, [](QString path) { AZ::Interface::Get()->FileAdded(path); }); - - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileAdded, - m_fileProcessor.get(), &AssetProcessor::FileProcessor::AssessAddedFile); - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileRemoved, - m_fileProcessor.get(), &AssetProcessor::FileProcessor::AssessDeletedFile); - - m_folderWatches.push_back(AZStd::unique_ptr(newFolderWatch)); - m_watchHandles.push_back(m_fileWatcher.AddFolderWatch(newFolderWatch)); + m_fileWatcher.AddFolderWatch(info.ScanPath(), info.RecurseSubFolders()); } - // also hookup monitoring for the cache (output directory) QDir cacheRoot; if (AssetUtilities::ComputeProjectCacheRoot(cacheRoot)) { - FolderWatchCallbackEx* newFolderWatch = new FolderWatchCallbackEx(cacheRoot.absolutePath(), "", true); + m_fileWatcher.AddFolderWatch(cacheRoot.absolutePath(), true); + } - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileAdded, [this](QString path) { m_fileStateCache->AddFile(path); }); - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileModified, [this](QString path) { m_fileStateCache->UpdateFile(path); }); - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileRemoved, [this](QString path) { m_fileStateCache->RemoveFile(path); }); + if (m_platformConfiguration->GetScanFolderCount() || !cacheRoot.path().isEmpty()) + { + const auto cachePath = QDir::toNativeSeparators(cacheRoot.absolutePath()); - // we only care about cache root deletions. - QObject::connect(newFolderWatch, &FolderWatchCallbackEx::fileRemoved, - m_assetProcessorManager, &AssetProcessor::AssetProcessorManager::AssessDeletedFile); + const auto OnFileAdded = [this, cachePath](QString path) + { + const bool isCacheRoot = path.startsWith(cachePath); + if (isCacheRoot) + { + m_fileStateCache->AddFile(path); + } + else + { + m_assetProcessorManager->AssessAddedFile(path); + m_fileStateCache->AddFile(path); + AZ::Interface::Get()->FileAdded(path); + m_fileProcessor->AssetProcessor::FileProcessor::AssessAddedFile(path); + } + }; - m_folderWatches.push_back(AZStd::unique_ptr(newFolderWatch)); - m_watchHandles.push_back(m_fileWatcher.AddFolderWatch(newFolderWatch)); + const auto OnFileModified = [this, cachePath](QString path) + { + const bool isCacheRoot = path.startsWith(cachePath); + if (isCacheRoot) + { + m_assetProcessorManager->AssessModifiedFile(path); + } + else + { + m_assetProcessorManager->AssessModifiedFile(path); + m_fileStateCache->UpdateFile(path); + } + }; + + const auto OnFileRemoved = [this, cachePath](QString path) + { + const bool isCacheRoot = path.startsWith(cachePath); + if (isCacheRoot) + { + m_fileStateCache->RemoveFile(path); + m_assetProcessorManager->AssessDeletedFile(path); + } + else + { + m_assetProcessorManager->AssessDeletedFile(path); + m_fileStateCache->RemoveFile(path); + m_fileProcessor->AssessDeletedFile(path); + } + }; + + connect(&m_fileWatcher, &FileWatcher::fileAdded, OnFileAdded); + connect(&m_fileWatcher, &FileWatcher::fileModified, OnFileModified); + connect(&m_fileWatcher, &FileWatcher::fileRemoved, OnFileRemoved); } } void ApplicationManagerBase::DestroyFileMonitor() { - for (int watchHandle : m_watchHandles) - { - m_fileWatcher.RemoveFolderWatch(watchHandle); - } - m_folderWatches.resize(0); + m_fileWatcher.ClearFolderWatches(); } void ApplicationManagerBase::DestroyApplicationServer() @@ -591,6 +604,51 @@ void ApplicationManagerBase::InitConnectionManager() }, AZStd::placeholders::_1, AZStd::placeholders::_2, AZStd::placeholders::_3, AZStd::placeholders::_4) ); + m_connectionManager->RegisterService( + AssetBuilder::BuilderRegistrationRequest::MessageType, + [this](unsigned int /*connId*/, unsigned int /*type*/, unsigned int /*serial*/, QByteArray payload, QString) + { + AssetBuilder::BuilderRegistrationRequest registrationRequest; + + if (m_builderRegistrationComplete) + { + return; + } + + m_builderRegistrationComplete = true; + + if (AssetProcessor::UnpackMessage(payload, registrationRequest)) + { + for (const auto& builder : registrationRequest.m_builders) + { + AssetBuilderSDK::AssetBuilderDesc desc; + desc.m_name = builder.m_name; + desc.m_patterns = builder.m_patterns; + desc.m_version = builder.m_version; + desc.m_analysisFingerprint = builder.m_analysisFingerprint; + desc.m_flags = builder.m_flags; + desc.m_busId = builder.m_busId; + desc.m_flagsByJobKey = builder.m_flagsByJobKey; + desc.m_productsToKeepOnFailure = builder.m_productsToKeepOnFailure; + + // Builders registered this way are always external builders + desc.m_builderType = AssetBuilderSDK::AssetBuilderDesc::AssetBuilderType::External; + + RegisterBuilderInformation(desc); + } + + QTimer::singleShot( + 0, this, + [this]() + { + if (!PostActivate()) + { + QuitRequested(); + } + }); + } + }); + //You can get Asset Processor Current State using AzFramework::AssetSystem::RequestAssetProcessorStatus; auto GetState = [this](unsigned int connId, unsigned int, unsigned int serial, QByteArray payload, QString) @@ -633,11 +691,11 @@ void ApplicationManagerBase::InitConnectionManager() AssetProcessorPlatformStatusRequest requestMessage; if (AssetProcessor::UnpackMessage(payload, requestMessage)) { - AzToolsFramework::AssetSystemRequestBus::BroadcastResult(responseMessage.m_isPlatformEnabled, + AzToolsFramework::AssetSystemRequestBus::BroadcastResult(responseMessage.m_isPlatformEnabled, &AzToolsFramework::AssetSystemRequestBus::Events::IsAssetPlatformEnabled, requestMessage.m_platform.c_str()); } - AssetProcessor::ConnectionBus::Event(connId, + AssetProcessor::ConnectionBus::Event(connId, &AssetProcessor::ConnectionBus::Events::SendResponse, serial, responseMessage); }); @@ -653,11 +711,11 @@ void ApplicationManagerBase::InitConnectionManager() if (AssetProcessor::UnpackMessage(payload, requestMessage)) { const char* platformIdentifier = requestMessage.m_platform.c_str(); - responseMessage.m_numberOfPendingJobs = + responseMessage.m_numberOfPendingJobs = GetRCController()->NumberOfPendingJobsPerPlatform(platformIdentifier); } - AssetProcessor::ConnectionBus::Event(connId, + AssetProcessor::ConnectionBus::Event(connId, &AssetProcessor::ConnectionBus::Events::SendResponse, serial, responseMessage); }); } @@ -696,7 +754,7 @@ void ApplicationManagerBase::InitAssetRequestHandler(AssetProcessor::AssetReques QObject::connect(GetAssetProcessorManager(), &AssetProcessorManager::SendAssetExistsResponse, m_assetRequestHandler, &AssetRequestHandler::OnRequestAssetExistsResponse); QObject::connect(GetAssetProcessorManager(), &AssetProcessorManager::FenceFileDetected, m_assetRequestHandler, &AssetRequestHandler::OnFenceFileDetected); - + // connect the Asset Request Handler to RC: QObject::connect(m_assetRequestHandler, &AssetRequestHandler::RequestCompileGroup, GetRCController(), &RCController::OnRequestCompileGroup); QObject::connect(m_assetRequestHandler, &AssetRequestHandler::RequestEscalateAssetBySearchTerm, GetRCController(), &RCController::OnEscalateJobsBySearchTerm); @@ -754,8 +812,6 @@ ApplicationManager::BeforeRunStatus ApplicationManagerBase::BeforeRun() qRegisterMetaType("AzFramework::AssetSystem::AssetStatus"); qRegisterMetaType("AssetStatus"); - qRegisterMetaType("FileChangeInfo"); - qRegisterMetaType("AssetScanningStatus"); qRegisterMetaType("NetworkRequestID"); @@ -840,14 +896,6 @@ bool ApplicationManagerBase::Run() return false; } - bool startedSuccessfully = true; - - if (!PostActivate()) - { - QuitRequested(); - startedSuccessfully = false; - } - AZ_Printf(AssetProcessor::ConsoleChannel, "Asset Processor Batch Processing Started.\n"); AZ_Printf(AssetProcessor::ConsoleChannel, "-----------------------------------------\n"); QElapsedTimer allAssetsProcessingTimer; @@ -867,7 +915,7 @@ bool ApplicationManagerBase::Run() RemoveOldTempFolders(); Destroy(); - return (startedSuccessfully && FailedAssetsCount() == 0); + return FailedAssetsCount() == 0; } void ApplicationManagerBase::HandleFileRelocation() const @@ -899,7 +947,7 @@ void ApplicationManagerBase::HandleFileRelocation() const while(!m_sourceControlReady) { // We need to wait for source control to be ready before continuing - + if (printCounter % 10 == 0) { AZ_TracePrintf(AssetProcessor::ConsoleChannel, "Waiting for Source Control connection\n"); @@ -966,18 +1014,18 @@ void ApplicationManagerBase::HandleFileRelocation() const AZ_Printf(AssetProcessor::ConsoleChannel, "SETTING: Preview file move. Run again with --%s to actually make changes\n", ConfirmCommand); } - auto* interface = AZ::Interface::Get(); + auto* relocationInterface = AZ::Interface::Get(); - if(interface) + if(relocationInterface) { - auto result = interface->Move(source, destination, previewOnly, allowBrokenDependencies, !leaveEmptyFolders, updateReferences, excludeMetaDataFiles); + auto result = relocationInterface->Move(source, destination, previewOnly, allowBrokenDependencies, !leaveEmptyFolders, updateReferences, excludeMetaDataFiles); if (result.IsSuccess()) { AssetProcessor::RelocationSuccess success = result.TakeValue(); // The report can be too long for the AZ_Printf buffer, so split it into individual lines - AZStd::string report = interface->BuildReport(success.m_relocationContainer, success.m_updateTasks, true, updateReferences); + AZStd::string report = relocationInterface->BuildReport(success.m_relocationContainer, success.m_updateTasks, true, updateReferences); AZStd::vector lines; AzFramework::StringFunc::Tokenize(report.c_str(), lines, "\n"); @@ -1051,18 +1099,18 @@ void ApplicationManagerBase::HandleFileRelocation() const AZ_Printf(AssetProcessor::ConsoleChannel, "SETTING: Preview file delete. Run again with --%s to actually make changes\n", ConfirmCommand); } - auto* interface = AZ::Interface::Get(); + auto* relocationInterface = AZ::Interface::Get(); - if (interface) + if (relocationInterface) { - auto result = interface->Delete(source, previewOnly, allowBrokenDependencies, !leaveEmptyFolders, excludeMetaDataFiles); + auto result = relocationInterface->Delete(source, previewOnly, allowBrokenDependencies, !leaveEmptyFolders, excludeMetaDataFiles); if (result.IsSuccess()) { AssetProcessor::RelocationSuccess success = result.TakeValue(); // The report can be too long for the AZ_Printf buffer, so split it into individual lines - AZStd::string report = interface->BuildReport(success.m_relocationContainer, success.m_updateTasks, false, updateReferences); + AZStd::string report = relocationInterface->BuildReport(success.m_relocationContainer, success.m_updateTasks, false, updateReferences); AZStd::vector lines; AzFramework::StringFunc::Tokenize(report.c_str(), lines, "\n"); @@ -1129,7 +1177,7 @@ void ApplicationManagerBase::CheckForIdle() TryScanProductDependencies(); TryHandleFileRelocation(); - + // since we are shutting down, we save the registry and then we quit. AZ_Printf(AssetProcessor::ConsoleChannel, "No assets remain in the build queue. Saving the catalog, and then shutting down.\n"); // stop accepting any further idle messages, as we will shut down - don't want this function to repeat! @@ -1173,7 +1221,7 @@ void ApplicationManagerBase::InitBuilderManager() { m_builderManager->ConnectionLost(connId); }); - + } void ApplicationManagerBase::ShutdownBuilderManager() @@ -1207,7 +1255,7 @@ void ApplicationManagerBase::ShutDownAssetDatabase() AzToolsFramework::AssetDatabase::AssetDatabaseRequests::Bus::Handler::BusDisconnect(); } -void ApplicationManagerBase::InitFileProcessor() +void ApplicationManagerBase::InitFileProcessor() { AssetProcessor::ThreadController* fileProcessorHelper = new AssetProcessor::ThreadController(); @@ -1298,22 +1346,13 @@ bool ApplicationManagerBase::Activate() } InitBuilderConfiguration(); - - m_isCurrentlyLoadingGems = true; - if (!ActivateModules()) - { - // ActivateModules reports any errors it encounters. - m_isCurrentlyLoadingGems = false; - return false; - } - - m_isCurrentlyLoadingGems = false; PopulateApplicationDependencies(); InitAssetProcessorManager(); AssetBuilderSDK::InitializeSerializationContext(); AssetBuilderSDK::InitializeBehaviorContext(); - + AssetBuilder::InitializeSerializationContext(); + InitFileStateCache(); InitFileProcessor(); @@ -1341,7 +1380,7 @@ bool ApplicationManagerBase::Activate() RegisterObjectForQuit(m_rcController); m_connectionsToRemoveOnShutdown << QObject::connect( - m_assetProcessorManager, &AssetProcessor::AssetProcessorManager::AssetProcessorManagerIdleState, + m_assetProcessorManager, &AssetProcessor::AssetProcessorManager::AssetProcessorManagerIdleState, this, [this](bool state) { if (state) @@ -1362,7 +1401,7 @@ bool ApplicationManagerBase::Activate() }); m_connectionsToRemoveOnShutdown << QObject::connect( - this, &ApplicationManagerBase::CheckAssetProcessorManagerIdleState, + this, &ApplicationManagerBase::CheckAssetProcessorManagerIdleState, m_assetProcessorManager, &AssetProcessor::AssetProcessorManager::CheckAssetProcessorIdleState); MakeActivationConnections(); @@ -1376,6 +1415,22 @@ bool ApplicationManagerBase::Activate() return false; } } + + AssetProcessor::AssetProcessorStatusEntry entry(AssetProcessor::AssetProcessorStatus::Initializing_Builders, 0, QString()); + Q_EMIT AssetProcessorStatusChanged(entry); + + AZStd::thread_desc desc; + desc.m_name = "Builder Component Registration"; + AZStd::thread builderRegistrationThread( + desc, + []() + { + AssetProcessor::BuilderRef builder; + AssetProcessor::BuilderManagerBus::BroadcastResult(builder, &AssetProcessor::BuilderManagerBus::Events::GetBuilder, true); + }); + + builderRegistrationThread.detach(); + return true; } @@ -1384,11 +1439,6 @@ bool ApplicationManagerBase::PostActivate() m_connectionManager->LoadConnections(); InitializeInternalBuilders(); - if (!InitializeExternalBuilders()) - { - AZ_Error("AssetProcessor", false, "AssetProcessor is closing. Failed to initialize and load all the external builders. Please ensure that Builders_Temp directory is not read-only. Please see log for more information.\n"); - return false; - } Q_EMIT OnBuildersRegistered(); @@ -1401,7 +1451,7 @@ bool ApplicationManagerBase::PostActivate() AZ::SystemTickBus::Broadcast(&AZ::SystemTickEvents::OnSystemTick); }); - // now that everything is up and running, we start scanning. Before this, we don't want file events to start percolating through the + // now that everything is up and running, we start scanning. Before this, we don't want file events to start percolating through the // asset system. GetAssetScanner()->StartScan(); @@ -1425,192 +1475,87 @@ bool ApplicationManagerBase::InitializeInternalBuilders() return result; } -bool ApplicationManagerBase::InitializeExternalBuilders() -{ - AssetProcessor::AssetProcessorStatusEntry entry(AssetProcessor::AssetProcessorStatus::Initializing_Builders); - Q_EMIT AssetProcessorStatusChanged(entry); - QCoreApplication::processEvents(QEventLoop::AllEvents); - - - // Get the list of external build modules (full paths) - QStringList fileList; - GetExternalBuilderFileList(fileList); - - for (const QString& filePath : fileList) - { - if (QLibrary::isLibrary(filePath)) - { - AssetProcessor::ExternalModuleAssetBuilderInfo* externalAssetBuilderInfo = new AssetProcessor::ExternalModuleAssetBuilderInfo(filePath); - AssetProcessor::AssetBuilderType assetBuilderType = externalAssetBuilderInfo->Load(); - AZ_TracePrintf(AssetProcessor::ConsoleChannel, "AssetProcessor is loading library %s\n", filePath.toUtf8().data()); - if (assetBuilderType == AssetProcessor::AssetBuilderType::None) - { - AZ_Warning(AssetProcessor::DebugChannel, false, "Non-builder DLL was found in Builders directory %s, skipping. \n", filePath.toUtf8().data()); - delete externalAssetBuilderInfo; - continue; - } - - if (assetBuilderType == AssetProcessor::AssetBuilderType::Invalid) - { - AZ_Warning(AssetProcessor::DebugChannel, false, "AssetProcessor was not able to load the library: %s\n", filePath.toUtf8().data()); - delete externalAssetBuilderInfo; - return false; - } - - AZ_TracePrintf(AssetProcessor::ConsoleChannel, "Initializing and registering builder %s\n", externalAssetBuilderInfo->GetName().toUtf8().data()); - - m_currentExternalAssetBuilder = externalAssetBuilderInfo; - - externalAssetBuilderInfo->Initialize(); - - m_currentExternalAssetBuilder = nullptr; - - m_externalAssetBuilders.push_back(externalAssetBuilderInfo); - } - } - - // Also init external builders which may be inside of Gems - AzToolsFramework::ToolsApplicationRequestBus::Broadcast( - &AzToolsFramework::ToolsApplicationRequests::CreateAndAddEntityFromComponentTags, - AZStd::vector({ AssetBuilderSDK::ComponentTags::AssetBuilder }), "AssetBuilders Entity"); - - return true; -} - -bool ApplicationManagerBase::WaitForBuilderExit(AzFramework::ProcessWatcher* processWatcher, AssetBuilderSDK::JobCancelListener* jobCancelListener, AZ::u32 processTimeoutLimitInSeconds) +void ApplicationManagerBase::RegisterBuilderInformation(const AssetBuilderSDK::AssetBuilderDesc& builderDesc) { - AZ::u32 exitCode = 0; - bool finishedOK = false; - QElapsedTimer ticker; - ProcessCommunicatorTracePrinter tracer(processWatcher->GetCommunicator(), "AssetBuilder"); - - ticker.start(); - - while (!finishedOK) + if (!builderDesc.IsExternalBuilder()) { - AZStd::this_thread::sleep_for(AZStd::chrono::milliseconds(s_MaximumSleepTimeMS)); - - tracer.Pump(); - - if (ticker.elapsed() > processTimeoutLimitInSeconds * 1000 || (jobCancelListener && jobCancelListener->IsCancelled())) - { - break; - } - - if (!processWatcher->IsProcessRunning(&exitCode)) - { - finishedOK = true; // we either cant wait for it, or it finished. - break; - } - } - - tracer.Pump(); // empty whats left if possible. - - if (processWatcher->IsProcessRunning(&exitCode)) - { - processWatcher->TerminateProcess(1); - } + // Create Job Function validation + AZ_Error( + AssetProcessor::ConsoleChannel, builderDesc.m_createJobFunction, + "Create Job Function (m_createJobFunction) for %s builder is empty.\n", builderDesc.m_name.c_str()); - if (exitCode != 0) - { - AZ_Error(AssetProcessor::ConsoleChannel, false, "AssetBuilder exited with error code %d", exitCode); - return false; - } - else if (jobCancelListener && jobCancelListener->IsCancelled()) - { - AZ_TracePrintf(AssetProcessor::DebugChannel, "AssetBuilder was terminated. There was a request to cancel the job.\n"); - return false; - } - else if (!finishedOK) - { - AZ_Error(AssetProcessor::ConsoleChannel, false, "AssetBuilder failed to terminate within %d seconds", processTimeoutLimitInSeconds); - return false; + // Process Job Function validation + AZ_Error( + AssetProcessor::ConsoleChannel, builderDesc.m_processJobFunction, + "Process Job Function (m_processJobFunction) for %s builder is empty.\n", builderDesc.m_name.c_str()); } - return true; -} - -void ApplicationManagerBase::RegisterBuilderInformation(const AssetBuilderSDK::AssetBuilderDesc& builderDesc) -{ - // Create Job Function validation - AZ_Error(AssetProcessor::ConsoleChannel, - builderDesc.m_createJobFunction, - "Create Job Function (m_createJobFunction) for %s builder is empty.\n", - builderDesc.m_name.c_str()); - - // Process Job Function validation - AZ_Error(AssetProcessor::ConsoleChannel, - builderDesc.m_processJobFunction, - "Process Job Function (m_processJobFunction) for %s builder is empty.\n", - builderDesc.m_name.c_str()); - // Bus ID validation AZ_Error(AssetProcessor::ConsoleChannel, !builderDesc.m_busId.IsNull(), "Bus ID for %s builder is empty.\n", builderDesc.m_name.c_str()); - // This is an external builder registering, we will want to track its builder desc since it can register multiple ones - AZStd::string builderFilePath; - if (m_currentExternalAssetBuilder) - { - m_currentExternalAssetBuilder->RegisterBuilderDesc(builderDesc.m_busId); - builderFilePath = m_currentExternalAssetBuilder->GetModuleFullPath().toUtf8().data(); - } - AssetBuilderSDK::AssetBuilderDesc modifiedBuilderDesc = builderDesc; // Allow for overrides defined in a BuilderConfig.ini file to update our code defined default values AssetProcessor::BuilderConfigurationRequestBus::Broadcast(&AssetProcessor::BuilderConfigurationRequests::UpdateBuilderDescriptor, builderDesc.m_name, modifiedBuilderDesc); if (builderDesc.IsExternalBuilder()) { - // We're going to override the createJob function so we can run it externally in AssetBuilder, rather than having it run inside the AP - modifiedBuilderDesc.m_createJobFunction = [builderFilePath](const AssetBuilderSDK::CreateJobsRequest& request, AssetBuilderSDK::CreateJobsResponse& response) - { - AssetProcessor::BuilderRef builderRef; - AssetProcessor::BuilderManagerBus::BroadcastResult(builderRef, &AssetProcessor::BuilderManagerBusTraits::GetBuilder); + // We're going to override the createJob function so we can run it externally in AssetBuilder, rather than having it run + // inside the AP + modifiedBuilderDesc.m_createJobFunction = + [](const AssetBuilderSDK::CreateJobsRequest& request, AssetBuilderSDK::CreateJobsResponse& response) + { + AssetProcessor::BuilderRef builderRef; + AssetProcessor::BuilderManagerBus::BroadcastResult(builderRef, &AssetProcessor::BuilderManagerBusTraits::GetBuilder, false); - if (builderRef) - { - int retryCount = 0; - AssetProcessor::BuilderRunJobOutcome result; + if (builderRef) + { + int retryCount = 0; + AssetProcessor::BuilderRunJobOutcome result; - do - { - retryCount++; - result = builderRef->RunJob(request, response, s_MaximumCreateJobsTimeSeconds, "create", builderFilePath, nullptr); - } while (result == AssetProcessor::BuilderRunJobOutcome::LostConnection && retryCount <= AssetProcessor::RetriesForJobNetworkError); - } - else + do { - AZ_Error("AssetProcessor", false, "Failed to retrieve a valid builder to process job"); - } - }; + retryCount++; + result = builderRef->RunJob( + request, response, s_MaximumCreateJobsTimeSeconds, "create", "", nullptr); + } while (result == AssetProcessor::BuilderRunJobOutcome::LostConnection && + retryCount <= AssetProcessor::RetriesForJobNetworkError); + } + else + { + AZ_Error("AssetProcessor", false, "Failed to retrieve a valid builder to process job"); + } + }; // Also override the processJob function to run externally - modifiedBuilderDesc.m_processJobFunction = [builderFilePath](const AssetBuilderSDK::ProcessJobRequest& request, AssetBuilderSDK::ProcessJobResponse& response) - { - AssetBuilderSDK::JobCancelListener jobCancelListener(request.m_jobId); + modifiedBuilderDesc.m_processJobFunction = + [](const AssetBuilderSDK::ProcessJobRequest& request, AssetBuilderSDK::ProcessJobResponse& response) + { + AssetBuilderSDK::JobCancelListener jobCancelListener(request.m_jobId); - AssetProcessor::BuilderRef builderRef; - AssetProcessor::BuilderManagerBus::BroadcastResult(builderRef, &AssetProcessor::BuilderManagerBusTraits::GetBuilder); + AssetProcessor::BuilderRef builderRef; + AssetProcessor::BuilderManagerBus::BroadcastResult(builderRef, &AssetProcessor::BuilderManagerBusTraits::GetBuilder, false); - if (builderRef) - { - int retryCount = 0; - AssetProcessor::BuilderRunJobOutcome result; + if (builderRef) + { + int retryCount = 0; + AssetProcessor::BuilderRunJobOutcome result; - do - { - retryCount++; - result = builderRef->RunJob(request, response, s_MaximumProcessJobsTimeSeconds, "process", builderFilePath, &jobCancelListener, request.m_tempDirPath); - } while (result == AssetProcessor::BuilderRunJobOutcome::LostConnection && retryCount <= AssetProcessor::RetriesForJobNetworkError); - } - else + do { - AZ_Error("AssetProcessor", false, "Failed to retrieve a valid builder to process job"); - } - }; + retryCount++; + result = builderRef->RunJob( + request, response, s_MaximumProcessJobsTimeSeconds, "process", "", &jobCancelListener, request.m_tempDirPath); + } while (result == AssetProcessor::BuilderRunJobOutcome::LostConnection && + retryCount <= AssetProcessor::RetriesForJobNetworkError); + } + else + { + AZ_Error("AssetProcessor", false, "Failed to retrieve a valid builder to process job"); + } + }; } if (m_builderDescMap.find(modifiedBuilderDesc.m_busId) != m_builderDescMap.end()) @@ -1768,7 +1713,7 @@ bool ApplicationManagerBase::CheckSufficientDiskSpace(const QString& savePath, q [[maybe_unused]] bool result = AzToolsFramework::ToolsFileUtils::GetFreeDiskSpace(savePath, bytesFree); AZ_Assert(result, "Unable to determine the amount of free space on drive containing path (%s).", savePath.toUtf8().constData()); - + if (bytesFree < requiredSpace + s_ReservedDiskSpaceInBytes) { if (shutdownIfInsufficient) @@ -1806,8 +1751,8 @@ void ApplicationManagerBase::RemoveOldTempFolders() return; } - // We will remove old temp folders if either their modified time is older than the cutoff time or - // if the total number of temp folders have exceeded the maximum number of temp folders. + // We will remove old temp folders if either their modified time is older than the cutoff time or + // if the total number of temp folders have exceeded the maximum number of temp folders. QFileInfoList entries = root.entryInfoList(QDir::Dirs | QDir::NoDotAndDotDot, QDir::Time); // sorting by modification time int folderCount = 0; bool removeFolder = false; @@ -1821,9 +1766,9 @@ void ApplicationManagerBase::RemoveOldTempFolders() // Since we are sorting the folders list from latest to oldest, we will either be in a state where we have to delete all the remaining folders or not // because either we have reached the folder limit or reached the cutoff date limit. - removeFolder = removeFolder || (folderCount++ >= s_MaximumTempFolders) || + removeFolder = removeFolder || (folderCount++ >= s_MaximumTempFolders) || (entry.lastModified() < cutoffTime); - + if (removeFolder) { QDir dir(entry.absoluteFilePath()); @@ -1837,8 +1782,6 @@ void ApplicationManagerBase::ConnectivityStateChanged(const AzToolsFramework::So Q_EMIT SourceControlReady(); } - - void ApplicationManagerBase::OnAssetProcessorManagerIdleState(bool isIdle) { // these can come in during shutdown. diff --git a/Code/Tools/AssetProcessor/native/utilities/ApplicationManagerBase.h b/Code/Tools/AssetProcessor/native/utilities/ApplicationManagerBase.h index 886880df3a..8591228375 100644 --- a/Code/Tools/AssetProcessor/native/utilities/ApplicationManagerBase.h +++ b/Code/Tools/AssetProcessor/native/utilities/ApplicationManagerBase.h @@ -47,7 +47,6 @@ namespace AssetProcessor class ApplicationServer; class ConnectionManager; -class FolderWatchCallbackEx; class ControlRequestHandler; class ApplicationManagerBase @@ -149,7 +148,6 @@ protected: void CreateQtApplication() override; bool InitializeInternalBuilders(); - bool InitializeExternalBuilders(); void InitBuilderManager(); void ShutdownBuilderManager(); bool InitAssetDatabase(); @@ -173,8 +171,6 @@ protected: AssetProcessor::AssetCatalog* GetAssetCatalog() const { return m_assetCatalog; } - static bool WaitForBuilderExit(AzFramework::ProcessWatcher* processWatcher, AssetBuilderSDK::JobCancelListener* jobCancelListener, AZ::u32 processTimeoutLimitInSeconds); - ApplicationServer* m_applicationServer = nullptr; ConnectionManager* m_connectionManager = nullptr; @@ -195,9 +191,7 @@ protected: bool m_sourceControlReady = false; bool m_fullIdle = false; - AZStd::vector > m_folderWatches; FileWatcher m_fileWatcher; - AZStd::vector m_watchHandles; AssetProcessor::PlatformConfiguration* m_platformConfiguration = nullptr; AssetProcessor::AssetProcessorManager* m_assetProcessorManager = nullptr; AssetProcessor::AssetCatalog* m_assetCatalog = nullptr; @@ -218,6 +212,8 @@ protected: AZStd::shared_ptr m_internalBuilder; AZStd::shared_ptr m_settingsRegistryBuilder; + bool m_builderRegistrationComplete = false; + // Builder description map based on the builder id AZStd::unordered_map m_builderDescMap; @@ -231,7 +227,7 @@ protected: AZStd::list m_externalAssetBuilders; AssetProcessor::ExternalModuleAssetBuilderInfo* m_currentExternalAssetBuilder = nullptr; - + QAtomicInt m_connectionsAwaitingAssetCatalogSave = 0; int m_remainingAPMJobs = 0; bool m_assetProcessorManagerIsReady = false; diff --git a/Code/Tools/AssetProcessor/native/utilities/AssetBuilderInfo.h b/Code/Tools/AssetProcessor/native/utilities/AssetBuilderInfo.h index 5ace9e1aaf..20a1d808fd 100644 --- a/Code/Tools/AssetProcessor/native/utilities/AssetBuilderInfo.h +++ b/Code/Tools/AssetProcessor/native/utilities/AssetBuilderInfo.h @@ -23,7 +23,6 @@ #include #include -class FolderWatchCallbackEx; class QCoreApplication; namespace AssetProcessor diff --git a/Code/Tools/AssetProcessor/native/utilities/BuilderManager.cpp b/Code/Tools/AssetProcessor/native/utilities/BuilderManager.cpp index ddaa5aa777..75c84630f5 100644 --- a/Code/Tools/AssetProcessor/native/utilities/BuilderManager.cpp +++ b/Code/Tools/AssetProcessor/native/utilities/BuilderManager.cpp @@ -16,6 +16,7 @@ #include #include #include +#include namespace AssetProcessor { @@ -138,7 +139,7 @@ namespace AssetProcessor } } - bool Builder::Start() + bool Builder::Start(bool doRegistration) { // Get the current BinXXX folder based on the current running AP QString applicationDir = QCoreApplication::instance()->applicationDirPath(); @@ -155,7 +156,7 @@ namespace AssetProcessor return false; } - const AZStd::vector params = BuildParams("resident", buildersFolder.c_str(), UuidString(), "", ""); + const AZStd::vector params = BuildParams("resident", buildersFolder.c_str(), UuidString(), "", "", doRegistration); m_processWatcher = LaunchProcess(fullExePathString.c_str(), params); @@ -179,7 +180,7 @@ namespace AssetProcessor return !m_processWatcher || (m_processWatcher && m_processWatcher->IsProcessRunning(exitCode)); } - AZStd::vector Builder::BuildParams(const char* task, const char* moduleFilePath, const AZStd::string& builderGuid, const AZStd::string& jobDescriptionFile, const AZStd::string& jobResponseFile) const + AZStd::vector Builder::BuildParams(const char* task, const char* moduleFilePath, const AZStd::string& builderGuid, const AZStd::string& jobDescriptionFile, const AZStd::string& jobResponseFile, bool doRegistration) const { QDir projectCacheRoot; AssetUtilities::ComputeProjectCacheRoot(projectCacheRoot); @@ -200,6 +201,11 @@ namespace AssetProcessor params.emplace_back(AZStd::string::format(R"(-engine-path="%s")", enginePath.c_str())); params.emplace_back(AZStd::string::format("-port=%d", portNumber)); + if(doRegistration) + { + params.emplace_back("--register"); + } + if (moduleFilePath && moduleFilePath[0]) { params.emplace_back(AZStd::string::format(R"(-module="%s")", moduleFilePath)); @@ -232,7 +238,7 @@ namespace AssetProcessor { AzFramework::ProcessLauncher::ProcessLaunchInfo processLaunchInfo; processLaunchInfo.m_processExecutableString = fullExePath; - + AZStd::vector commandLineArray{ fullExePath }; commandLineArray.insert(commandLineArray.end(), params.begin(), params.end()); processLaunchInfo.m_commandlineParameters = AZStd::move(commandLineArray); @@ -350,17 +356,19 @@ namespace AssetProcessor BuilderManager::BuilderManager(ConnectionManager* connectionManager) { using namespace AZStd::placeholders; - connectionManager->RegisterService(AssetBuilderSDK::BuilderHelloRequest::MessageType(), AZStd::bind(&BuilderManager::IncomingBuilderPing, this, _1, _2, _3, _4, _5)); + connectionManager->RegisterService(AssetBuilder::BuilderHelloRequest::MessageType(), AZStd::bind(&BuilderManager::IncomingBuilderPing, this, _1, _2, _3, _4, _5)); // Setup a background thread to pump the idle builders so they don't get blocked trying to output to stdout/err - m_pollingThread = AZStd::thread([this]() + AZStd::thread_desc desc; + desc.m_name = "BuilderManager Idle Pump"; + m_pollingThread = AZStd::thread(desc, [this]() + { + while (!m_quitListener.WasQuitRequested()) { - while (!m_quitListener.WasQuitRequested()) - { - PumpIdleBuilders(); - AZStd::this_thread::sleep_for(AZStd::chrono::milliseconds(s_IdleBuilderPumpingDelayMS)); - } - }); + PumpIdleBuilders(); + AZStd::this_thread::sleep_for(AZStd::chrono::milliseconds(s_IdleBuilderPumpingDelayMS)); + } + }); m_quitListener.BusConnect(); BusConnect(); @@ -399,8 +407,8 @@ namespace AssetProcessor void BuilderManager::IncomingBuilderPing(AZ::u32 connId, AZ::u32 /*type*/, AZ::u32 serial, QByteArray payload, QString platform) { - AssetBuilderSDK::BuilderHelloRequest requestPing; - AssetBuilderSDK::BuilderHelloResponse responsePing; + AssetBuilder::BuilderHelloRequest requestPing; + AssetBuilder::BuilderHelloResponse responsePing; if (!AZ::Utils::LoadObjectFromBufferInPlace(payload.data(), payload.length(), requestPing)) { @@ -476,7 +484,7 @@ namespace AssetProcessor return builder; } - BuilderRef BuilderManager::GetBuilder() + BuilderRef BuilderManager::GetBuilder(bool doRegistration) { AZStd::shared_ptr newBuilder; BuilderRef builderRef; @@ -484,27 +492,30 @@ namespace AssetProcessor { AZStd::unique_lock lock(m_buildersMutex); - for (auto itr = m_builders.begin(); itr != m_builders.end(); ) + if (!doRegistration) { - auto& builder = itr->second; - - if (!builder->m_busy) + for (auto itr = m_builders.begin(); itr != m_builders.end();) { - builder->PumpCommunicator(); + auto& builder = itr->second; - if (builder->IsValid()) + if (!builder->m_busy) { - return BuilderRef(builder); + builder->PumpCommunicator(); + + if (builder->IsValid()) + { + return BuilderRef(builder); + } + else + { + itr = m_builders.erase(itr); + } } else { - itr = m_builders.erase(itr); + ++itr; } } - else - { - ++itr; - } } AZ_TracePrintf("BuilderManager", "Starting new builder for job request\n"); @@ -516,7 +527,7 @@ namespace AssetProcessor builderRef = BuilderRef(newBuilder); } - if (!newBuilder->Start()) + if (!newBuilder->Start(doRegistration)) { AZ_Error("BuilderManager", false, "Builder failed to start"); diff --git a/Code/Tools/AssetProcessor/native/utilities/BuilderManager.h b/Code/Tools/AssetProcessor/native/utilities/BuilderManager.h index 1208345a39..64241b106e 100644 --- a/Code/Tools/AssetProcessor/native/utilities/BuilderManager.h +++ b/Code/Tools/AssetProcessor/native/utilities/BuilderManager.h @@ -39,7 +39,7 @@ namespace AssetProcessor virtual ~BuilderManagerBusTraits() = default; //! Returns a builder for doing work - virtual BuilderRef GetBuilder() = 0; + virtual BuilderRef GetBuilder(bool doRegistration) = 0; }; using BuilderManagerBus = AZ::EBus; @@ -98,12 +98,12 @@ namespace AssetProcessor private: //! Starts the builder process and waits for it to connect - bool Start(); + bool Start(bool doRegistration); //! Sets the connection id and signals that the builder has connected void SetConnection(AZ::u32 connId); - AZStd::vector BuildParams(const char* task, const char* moduleFilePath, const AZStd::string& builderGuid, const AZStd::string& jobDescriptionFile, const AZStd::string& jobResponseFile) const; + AZStd::vector BuildParams(const char* task, const char* moduleFilePath, const AZStd::string& builderGuid, const AZStd::string& jobDescriptionFile, const AZStd::string& jobResponseFile, bool doRegistration) const; AZStd::unique_ptr LaunchProcess(const char* fullExePath, const AZStd::vector& params) const; //! Waits for the builder exe to send the job response and pumps stdout/err @@ -169,7 +169,7 @@ namespace AssetProcessor void ConnectionLost(AZ::u32 connId); //BuilderManagerBus - BuilderRef GetBuilder() override; + BuilderRef GetBuilder(bool doRegistration) override; private: diff --git a/Code/Tools/AssetProcessor/native/utilities/BuilderManager.inl b/Code/Tools/AssetProcessor/native/utilities/BuilderManager.inl index 9893f32f6a..039680dfae 100644 --- a/Code/Tools/AssetProcessor/native/utilities/BuilderManager.inl +++ b/Code/Tools/AssetProcessor/native/utilities/BuilderManager.inl @@ -50,7 +50,7 @@ namespace AssetProcessor if (!netResponse.m_response.Succeeded() || s_createRequestFileForSuccessfulJob) { - // we write the request out to disk for failure or debugging + // we write the request out to disk for failure or debugging if (!DebugWriteRequestFile(tempFolderPath.c_str(), request, task, modulePath)) { return BuilderRunJobOutcome::FailedToWriteDebugRequest; @@ -83,7 +83,7 @@ namespace AssetProcessor return false; } - auto params = BuildParams(task.c_str(), modulePath.c_str(), "", jobRequestFile, jobResponseFile); + auto params = BuildParams(task.c_str(), modulePath.c_str(), "", jobRequestFile, jobResponseFile, false); AZStd::string paramString; AZ::StringFunc::Join(paramString, params.begin(), params.end(), " "); diff --git a/Code/Tools/AssetProcessor/native/utilities/GUIApplicationManager.cpp b/Code/Tools/AssetProcessor/native/utilities/GUIApplicationManager.cpp index c3ff22a39e..13a6b0699a 100644 --- a/Code/Tools/AssetProcessor/native/utilities/GUIApplicationManager.cpp +++ b/Code/Tools/AssetProcessor/native/utilities/GUIApplicationManager.cpp @@ -12,8 +12,6 @@ #include "native/resourcecompiler/rccontroller.h" #include "native/FileServer/fileServer.h" #include "native/AssetManager/assetScanner.h" -#include "native/shadercompiler/shadercompilerManager.h" -#include "native/shadercompiler/shadercompilerModel.h" #include #include @@ -55,7 +53,7 @@ namespace { moduleFileInfo.setFile(executableDirectory); } - + QDir binaryDir = moduleFileInfo.absoluteDir(); // strip extension QString applicationBase = moduleFileInfo.completeBaseName(); @@ -70,7 +68,7 @@ namespace binaryDir.remove(tempFile); } } - + } @@ -145,8 +143,6 @@ void GUIApplicationManager::Destroy() DestroyIniConfiguration(); DestroyFileServer(); - DestroyShaderCompilerManager(); - DestroyShaderCompilerModel(); } @@ -192,7 +188,7 @@ bool GUIApplicationManager::Run() wrapper->enableSaveRestoreGeometry(GetOrganizationName(), GetApplicationName(), "MainWindow", restoreOnFirstShow); AzQtComponents::StyleManager::setStyleSheet(m_mainWindow, QStringLiteral("style:AssetProcessor.qss")); - + auto refreshStyleSheets = [styleManager]() { styleManager->Refresh(); @@ -322,19 +318,11 @@ bool GUIApplicationManager::Run() qApp->setQuitOnLastWindowClosed(false); - QTimer::singleShot(0, this, [this]() - { - if (!PostActivate()) - { - QuitRequested(); - m_startedSuccessfully = false; - } - }); - m_duringStartup = false; + m_startedSuccessfully = true; int resultCode = qApp->exec(); // this blocks until the last window is closed. - + if(!InitiatedShutdown()) { // if we are here it implies that AP did not stop the Qt event loop and is shutting down prematurely @@ -427,7 +415,7 @@ bool GUIApplicationManager::OnError(const char* /*window*/, const char* message) return true; } - // If we're the main thread, then consider showing the message box directly. + // If we're the main thread, then consider showing the message box directly. // note that all other threads will PAUSE if they emit a message while the main thread is showing this box // due to the way the trace system EBUS is mutex-protected. Qt::ConnectionType connection = Qt::DirectConnection; @@ -470,7 +458,7 @@ bool GUIApplicationManager::Activate() AssetUtilities::ComputeProjectCacheRoot(projectCacheRoot); m_localUserSettings.Load(projectCacheRoot.filePath("AssetProcessorUserSettings.xml").toUtf8().data(), context); m_localUserSettings.Activate(AZ::UserSettings::CT_LOCAL); - + InitIniConfiguration(); InitFileServer(); @@ -479,9 +467,6 @@ bool GUIApplicationManager::Activate() { return false; } - - InitShaderCompilerModel(); - InitShaderCompilerManager(); return true; } @@ -490,6 +475,7 @@ bool GUIApplicationManager::PostActivate() { if (!ApplicationManagerBase::PostActivate()) { + m_startedSuccessfully = false; return false; } @@ -606,7 +592,7 @@ void GUIApplicationManager::InitConnectionManager() QObject::connect(m_fileServer, SIGNAL(AddRenameRequest(unsigned int, bool)), m_connectionManager, SLOT(AddRenameRequest(unsigned int, bool))); QObject::connect(m_fileServer, SIGNAL(AddFindFileNamesRequest(unsigned int, bool)), m_connectionManager, SLOT(AddFindFileNamesRequest(unsigned int, bool))); QObject::connect(m_fileServer, SIGNAL(UpdateConnectionMetrics()), m_connectionManager, SLOT(UpdateConnectionMetrics())); - + m_connectionManager->RegisterService(ShowAssetProcessorRequest::MessageType, std::bind([this](unsigned int /*connId*/, unsigned int /*type*/, unsigned int /*serial*/, QByteArray /*payload*/) { @@ -661,40 +647,6 @@ void GUIApplicationManager::DestroyFileServer() } } -void GUIApplicationManager::InitShaderCompilerManager() -{ - m_shaderCompilerManager = new ShaderCompilerManager(); - - //Shader compiler stuff - m_connectionManager->RegisterService(AssetUtilities::ComputeCRC32Lowercase("ShaderCompilerProxyRequest"), std::bind(&ShaderCompilerManager::process, m_shaderCompilerManager, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3, std::placeholders::_4)); - QObject::connect(m_shaderCompilerManager, SIGNAL(sendErrorMessageFromShaderJob(QString, QString, QString, QString)), m_shaderCompilerModel, SLOT(addShaderErrorInfoEntry(QString, QString, QString, QString))); - - -} - -void GUIApplicationManager::DestroyShaderCompilerManager() -{ - if (m_shaderCompilerManager) - { - delete m_shaderCompilerManager; - m_shaderCompilerManager = nullptr; - } -} - -void GUIApplicationManager::InitShaderCompilerModel() -{ - m_shaderCompilerModel = new ShaderCompilerModel(); -} - -void GUIApplicationManager::DestroyShaderCompilerModel() -{ - if (m_shaderCompilerModel) - { - delete m_shaderCompilerModel; - m_shaderCompilerModel = nullptr; - } -} - IniConfiguration* GUIApplicationManager::GetIniConfiguration() const { return m_iniConfiguration; @@ -704,14 +656,6 @@ FileServer* GUIApplicationManager::GetFileServer() const { return m_fileServer; } -ShaderCompilerManager* GUIApplicationManager::GetShaderCompilerManager() const -{ - return m_shaderCompilerManager; -} -ShaderCompilerModel* GUIApplicationManager::GetShaderCompilerModel() const -{ - return m_shaderCompilerModel; -} void GUIApplicationManager::ShowTrayIconErrorMessage(QString msg) { diff --git a/Code/Tools/AssetProcessor/native/utilities/GUIApplicationManager.h b/Code/Tools/AssetProcessor/native/utilities/GUIApplicationManager.h index 3cf58231f2..c10d841daf 100644 --- a/Code/Tools/AssetProcessor/native/utilities/GUIApplicationManager.h +++ b/Code/Tools/AssetProcessor/native/utilities/GUIApplicationManager.h @@ -24,8 +24,6 @@ class ConnectionManager; class IniConfiguration; class ApplicationServer; class FileServer; -class ShaderCompilerManager; -class ShaderCompilerModel; namespace AssetProcessor { @@ -47,8 +45,6 @@ public: ApplicationManager::BeforeRunStatus BeforeRun() override; IniConfiguration* GetIniConfiguration() const; FileServer* GetFileServer() const; - ShaderCompilerManager* GetShaderCompilerManager() const; - ShaderCompilerModel* GetShaderCompilerModel() const; bool Run() override; //////////////////////////////////////////////////// @@ -72,10 +68,6 @@ private: void DestroyIniConfiguration(); void InitFileServer(); void DestroyFileServer(); - void InitShaderCompilerManager(); - void DestroyShaderCompilerManager(); - void InitShaderCompilerModel(); - void DestroyShaderCompilerModel(); void Destroy() override; Q_SIGNALS: @@ -99,8 +91,7 @@ private: IniConfiguration* m_iniConfiguration = nullptr; FileServer* m_fileServer = nullptr; - ShaderCompilerManager* m_shaderCompilerManager = nullptr; - ShaderCompilerModel* m_shaderCompilerModel = nullptr; + QFileSystemWatcher m_qtFileWatcher; AZ::UserSettingsProvider m_localUserSettings; bool m_messageBoxIsVisible = false; diff --git a/Code/Tools/AssetProcessor/native/utilities/PlatformConfiguration.cpp b/Code/Tools/AssetProcessor/native/utilities/PlatformConfiguration.cpp index 7543e9ec8b..c62d822171 100644 --- a/Code/Tools/AssetProcessor/native/utilities/PlatformConfiguration.cpp +++ b/Code/Tools/AssetProcessor/native/utilities/PlatformConfiguration.cpp @@ -51,7 +51,7 @@ namespace AssetProcessor case AZ::SettingsRegistryInterface::VisitAction::Begin: { // Only continue traversal if the path is exactly the AssetProcessorSettingsKey (which indicates the start of traversal) - // or if a "Platform *" object and it's children are being traversed + // or if a "Platform *" object and it's children are being traversed if (jsonPath == AssetProcessorSettingsKey) { return AZ::SettingsRegistryInterface::VisitResponse::Continue; @@ -631,7 +631,7 @@ namespace AssetProcessor for (const AssetBuilderSDK::PlatformInfo& platform : m_enabledPlatforms) { AZStd::string_view currentRCParams = assetRecognizer.m_defaultParams; - // The "/Amazon/AssetProcessor/Settings/RC */" entry will be queried + // The "/Amazon/AssetProcessor/Settings/RC */" entry will be queried AZ::IO::Path overrideParamsKey = AZ::IO::Path(AZ::IO::PosixPathSeparator); overrideParamsKey /= path; overrideParamsKey /= platform.m_identifier; @@ -644,7 +644,7 @@ namespace AssetProcessor } else { - // otherwise check for tags associated with the platform + // otherwise check for tags associated with the platform for (const AZStd::string& tag : platform.m_tags) { overrideParamsKey.ReplaceFilename(AZ::IO::PathView(tag)); @@ -1416,6 +1416,8 @@ namespace AssetProcessor return QString(); } + auto* fileStateInterface = AZ::Interface::Get(); + for (int pathIdx = 0; pathIdx < m_scanFolders.size(); ++pathIdx) { AssetProcessor::ScanFolderInfo scanFolderInfo = m_scanFolders[pathIdx]; @@ -1430,7 +1432,7 @@ namespace AssetProcessor QDir rooted(scanFolderInfo.ScanPath()); QString absolutePath = rooted.absoluteFilePath(tempRelativeName); AssetProcessor::FileStateInfo fileStateInfo; - auto* fileStateInterface = AZ::Interface::Get(); + if (fileStateInterface) { if (fileStateInterface->GetFileInfo(absolutePath, &fileStateInfo)) @@ -1499,7 +1501,7 @@ namespace AssetProcessor QRegExp nameMatch{ posixRelativeName, Qt::CaseInsensitive, QRegExp::Wildcard }; AZStd::stack dirs; dirs.push(sourceFolderDir.absolutePath()); - + while (!dirs.empty()) { QString absolutePath = dirs.top(); @@ -1528,7 +1530,7 @@ namespace AssetProcessor continue; } } - + QString pathMatch{ sourceFolderDir.relativeFilePath(dirIterator.filePath()) }; if (nameMatch.exactMatch(pathMatch)) { diff --git a/Code/Tools/AssetProcessor/native/utilities/assetUtils.cpp b/Code/Tools/AssetProcessor/native/utilities/assetUtils.cpp index 6bcd0dec01..a6cbfd8077 100644 --- a/Code/Tools/AssetProcessor/native/utilities/assetUtils.cpp +++ b/Code/Tools/AssetProcessor/native/utilities/assetUtils.cpp @@ -131,7 +131,7 @@ namespace AssetUtilsInternal } } } while (!timer.hasExpired(waitTimeInSeconds * 1000)); //We will keep retrying until the timer has expired the inputted timeout - + // once we're done, regardless of success or failure, we 'unlock' those files for further process. // if we failed, also re-trigger them to rebuild (the bool param at the end of the ebus call) QString normalized = AssetUtilities::NormalizeFilePath(outputFile); @@ -870,23 +870,27 @@ namespace AssetUtilities return true; } - QString StripAssetPlatform(AZStd::string_view relativeProductPath) + AZStd::string_view StripAssetPlatformNoCopy(AZStd::string_view relativeProductPath) { // Skip over the assetPlatform path segment if it is matches one of the platform defaults // Otherwise return the path unchanged - AZStd::string_view strippedProductPath{ relativeProductPath }; - if (AZStd::optional pathSegment = AZ::StringFunc::TokenizeNext(strippedProductPath, AZ_CORRECT_AND_WRONG_FILESYSTEM_SEPARATOR); - pathSegment.has_value()) + + AZStd::string_view originalPath = relativeProductPath; + AZStd::optional firstPathSegment = AZ::StringFunc::TokenizeNext(relativeProductPath, AZ_CORRECT_AND_WRONG_FILESYSTEM_SEPARATOR); + + if (firstPathSegment && AzFramework::PlatformHelper::GetPlatformIdFromName(*firstPathSegment) != AzFramework::PlatformId::Invalid) { - AZ::IO::FixedMaxPathString assetPlatformSegmentLower{ *pathSegment }; - AZStd::to_lower(assetPlatformSegmentLower.begin(), assetPlatformSegmentLower.end()); - if (AzFramework::PlatformHelper::GetPlatformIdFromName(assetPlatformSegmentLower) != AzFramework::PlatformId::Invalid) - { - return QString::fromUtf8(strippedProductPath.data(), aznumeric_cast(strippedProductPath.size())); - } + return relativeProductPath; } - return QString::fromUtf8(relativeProductPath.data(), aznumeric_cast(relativeProductPath.size())); + return originalPath; + } + + QString StripAssetPlatform(AZStd::string_view relativeProductPath) + { + AZStd::string_view result = StripAssetPlatformNoCopy(relativeProductPath); + + return QString::fromUtf8(result.data(), aznumeric_cast(result.size())); } QString NormalizeFilePath(const QString& filePath) diff --git a/Code/Tools/AssetProcessor/native/utilities/assetUtils.h b/Code/Tools/AssetProcessor/native/utilities/assetUtils.h index 46ec5d6145..18cf5422de 100644 --- a/Code/Tools/AssetProcessor/native/utilities/assetUtils.h +++ b/Code/Tools/AssetProcessor/native/utilities/assetUtils.h @@ -145,7 +145,7 @@ namespace AssetUtilities //! Strips the first "asset platform" from the first path segment of a relative product path //! This is meant for removing the asset platform for paths such as "pc/MyAssetFolder/MyAsset.asset" //! Therefore the result here becomes "MyAssetFolder/MyAsset" - //! + //! //! Similarly invoking this function on relative path that begins with the "server" platform //! "server/AssetFolder/Server.asset2" -> "AssetFolder/Server.asset2" //! This function does not strip an asset platform from anywhere, but the first path segment @@ -153,6 +153,10 @@ namespace AssetUtilities //! would return a copy of the relative path QString StripAssetPlatform(AZStd::string_view relativeProductPath); + //! Same as StripAssetPlatform, but does not perform any string copies + //! The return result is only valid for as long as the original input is valid + AZStd::string_view StripAssetPlatformNoCopy(AZStd::string_view relativeProductPath); + //! Converts all slashes to forward slashes, removes double slashes, //! replaces all indirections such as '.' or '..' as appropriate. //! On windows, the drive letter (if present) is converted to uppercase. diff --git a/Code/Tools/AzTestRunner/CMakeLists.txt b/Code/Tools/AzTestRunner/CMakeLists.txt index 5f3bb829a8..2bd74fa1a1 100644 --- a/Code/Tools/AzTestRunner/CMakeLists.txt +++ b/Code/Tools/AzTestRunner/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/platform_traits_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/Code/Tools/CrashHandler/CMakeLists.txt b/Code/Tools/CrashHandler/CMakeLists.txt index 259a7d2891..db50741326 100644 --- a/Code/Tools/CrashHandler/CMakeLists.txt +++ b/Code/Tools/CrashHandler/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/Code/Tools/LuaIDE/CMakeLists.txt b/Code/Tools/LuaIDE/CMakeLists.txt index 98c8d7f04b..58e0fe505a 100644 --- a/Code/Tools/LuaIDE/CMakeLists.txt +++ b/Code/Tools/LuaIDE/CMakeLists.txt @@ -10,6 +10,8 @@ if(NOT PAL_TRAIT_BUILD_HOST_TOOLS) return() endif() +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) + ly_add_target( NAME LuaIDE APPLICATION NAMESPACE AZ @@ -18,7 +20,7 @@ ly_add_target( AUTORCC FILES_CMAKE lua_ide_files.cmake - Platform/${PAL_PLATFORM_NAME}/lua_ide_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake + ${pal_dir}/lua_ide_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake INCLUDE_DIRECTORIES PRIVATE . diff --git a/Code/Tools/LuaIDE/Source/LUA/BreakpointPanel.cpp b/Code/Tools/LuaIDE/Source/LUA/BreakpointPanel.cpp index 56379a3f07..cb8fffffc7 100644 --- a/Code/Tools/LuaIDE/Source/LUA/BreakpointPanel.cpp +++ b/Code/Tools/LuaIDE/Source/LUA/BreakpointPanel.cpp @@ -140,7 +140,7 @@ void DHBreakpointsWidget::CreateBreakpoint(const AZStd::string& debugName, int l QTableWidgetItem* newItem = new QTableWidgetItem(debugName.c_str()); newItem->setFlags(Qt::ItemIsEnabled | Qt::ItemIsSelectable); setItem(newRow, 1, newItem); - newItem = new QTableWidgetItem(QString().setNum(lineNumber + 1)); // +1 offset to match editor numbering + newItem = new QTableWidgetItem(QString().setNum(lineNumber)); newItem->setFlags(Qt::ItemIsEnabled | Qt::ItemIsSelectable); setItem(newRow, 0, newItem); } diff --git a/Code/Tools/LuaIDE/Source/LUA/LUAEditorContext.cpp b/Code/Tools/LuaIDE/Source/LUA/LUAEditorContext.cpp index f36724ee1a..533a89a77c 100644 --- a/Code/Tools/LuaIDE/Source/LUA/LUAEditorContext.cpp +++ b/Code/Tools/LuaIDE/Source/LUA/LUAEditorContext.cpp @@ -1433,7 +1433,8 @@ namespace LUAEditor return; } - AZStd::to_lower(const_cast(assetId).begin(), const_cast(assetId).end()); + AZStd::string assetIdLower(assetId); + AZStd::to_lower(assetIdLower.begin(), assetIdLower.end()); ShowLUAEditorView(); @@ -1446,11 +1447,11 @@ namespace LUAEditor // * we need to load that lua panel with the document's data, initializing it. // are we already tracking it? - auto it = m_documentInfoMap.find(assetId); + auto it = m_documentInfoMap.find(assetIdLower); if (it != m_documentInfoMap.end()) { // tell the view that it needs to focus that document! - mostRecentlyOpenedDocumentView = assetId; + mostRecentlyOpenedDocumentView = assetIdLower; if (m_queuedOpenRecent) { return; @@ -1482,14 +1483,14 @@ namespace LUAEditor // Register the script into the asset catalog AZ::Data::AssetType assetType = AZ::AzTypeInfo::Uuid(); AZ::Data::AssetId catalogAssetId; - EBUS_EVENT_RESULT(catalogAssetId, AZ::Data::AssetCatalogRequestBus, GetAssetIdByPath, assetId.c_str(), assetType, true); + EBUS_EVENT_RESULT(catalogAssetId, AZ::Data::AssetCatalogRequestBus, GetAssetIdByPath, assetIdLower.c_str(), assetType, true); uint64_t modTime = m_fileIO->ModificationTime(assetId.c_str()); DocumentInfo info; - info.m_assetName = assetId; + info.m_assetName = assetIdLower; AzFramework::StringFunc::Path::GetFullFileName(assetId.c_str(), info.m_displayName); - info.m_assetId = assetId; + info.m_assetId = assetIdLower; info.m_bSourceControl_BusyGettingStats = true; info.m_bSourceControl_BusyGettingStats = false; info.m_bSourceControl_CanWrite = true; @@ -1532,7 +1533,7 @@ namespace LUAEditor luaFile.Close(); } - DataLoadDoneCallback(isLoaded, assetId); + DataLoadDoneCallback(isLoaded, assetIdLower); ////////////////////////////////////////////////////////////////////////// if (m_queuedOpenRecent) @@ -1545,7 +1546,7 @@ namespace LUAEditor m_pLUAEditorMainWindow->IgnoreFocusEvents(false); } - mostRecentlyOpenedDocumentView = assetId; + mostRecentlyOpenedDocumentView = assetIdLower; EBUS_QUEUE_FUNCTION(AZ::SystemTickBus, &Context::OpenMostRecentDocumentView, this); } diff --git a/Code/Tools/LuaIDE/Source/LUA/LUAEditorMainWindow.cpp b/Code/Tools/LuaIDE/Source/LUA/LUAEditorMainWindow.cpp index 33d8373487..776e290042 100644 --- a/Code/Tools/LuaIDE/Source/LUA/LUAEditorMainWindow.cpp +++ b/Code/Tools/LuaIDE/Source/LUA/LUAEditorMainWindow.cpp @@ -346,7 +346,11 @@ namespace LUAEditor { auto selectedAsset = selectedAssets.front(); const AZStd::string filePath = selectedAsset->GetFullPath(); - EBUS_EVENT(Context_DocumentManagement::Bus, OnLoadDocument, filePath, true); + auto entryType = selectedAsset->GetEntryType(); + if (entryType == AzToolsFramework::AssetBrowser::AssetBrowserEntry::AssetEntryType::Source) + { + EBUS_EVENT(Context_DocumentManagement::Bus, OnLoadDocument, filePath, true); + } } }); } @@ -372,9 +376,17 @@ namespace LUAEditor StringFilter* stringFilter = new StringFilter(); stringFilter->SetFilterPropagation(AssetTypeFilter::PropagateDirection::Up); - connect(m_gui->m_assetBrowserSearchWidget, &AzQtComponents::FilteredSearchWidget::TextFilterChanged, this, [stringFilter](const QString& newString) + connect(m_gui->m_assetBrowserSearchWidget, &AzQtComponents::FilteredSearchWidget::TextFilterChanged, this, [&, stringFilter](const QString& newString) { stringFilter->SetFilterString(newString); + if (newString.isEmpty()) + { + m_gui->m_assetBrowserTreeView->collapseAll(); + } + else + { + m_gui->m_assetBrowserTreeView->expandAll(); + } }); // Construct the final filter where they are all and'd together @@ -1280,7 +1292,7 @@ namespace LUAEditor // go to that line of the selected file. lineNumber = dlg.getLineNumber(); - currentView->SetCursorPosition(lineNumber - 1, 0); + currentView->SetCursorPosition(lineNumber, 0); } } @@ -2141,24 +2153,7 @@ namespace LUAEditor if (event->type() == QEvent::KeyPress) { QKeyEvent* keyEvent = static_cast(event); - if (keyEvent->key() == Qt::Key_Control) - { - TrackedLUACtrlTabOrder::iterator tabIter = m_CtrlTabOrder.begin(); - while (tabIter != m_CtrlTabOrder.end()) - { - if (*tabIter == m_lastFocusedAssetId) - { - // store the visible top window and make it the list's topmost - m_StoredTabAssetId = m_lastFocusedAssetId; - m_CtrlTabOrder.erase(tabIter); - m_CtrlTabOrder.push_front(m_lastFocusedAssetId); - break; - } - - ++tabIter; - } - } - else if (keyEvent->key() == Qt::Key_C && (keyEvent->modifiers() & Qt::ControlModifier)) + if (keyEvent->key() == Qt::Key_C && (keyEvent->modifiers() & Qt::ControlModifier)) { OnEditMenuCopy(); return true; @@ -2174,32 +2169,6 @@ namespace LUAEditor QKeyEvent* keyEvent = static_cast(event); if (keyEvent->key() == Qt::Key_Control) { - // reconfigure the ctrl+tab stack to set the next document to be the stored guid - // which was recorded when Ctrl was first pressed - TrackedLUACtrlTabOrder::iterator tabIter = m_CtrlTabOrder.begin(); - while (tabIter != m_CtrlTabOrder.end()) - { - if (*tabIter == m_StoredTabAssetId) - { - m_CtrlTabOrder.erase(tabIter); - - tabIter = m_CtrlTabOrder.begin(); - ++tabIter; - if (tabIter != m_CtrlTabOrder.end()) - { - m_CtrlTabOrder.insert(tabIter, m_StoredTabAssetId); - } - else - { - m_CtrlTabOrder.push_back(m_StoredTabAssetId); - } - - break; - } - - ++tabIter; - } - m_StoredTabAssetId = ""; } } @@ -2210,46 +2179,67 @@ namespace LUAEditor void LUAEditorMainWindow::OnTabForwards() { - // pop the first entry and push it to the last spot TrackedLUACtrlTabOrder::iterator tabIter = m_CtrlTabOrder.begin(); - if (tabIter != m_CtrlTabOrder.end()) - { - AZStd::string assetId = *tabIter; - m_CtrlTabOrder.pop_front(); - m_CtrlTabOrder.push_back(assetId); - // then grab the new first entry and pass it on to the widgetry - tabIter = m_CtrlTabOrder.begin(); - - TrackedLUAViewMap::iterator viewInfoIter = m_dOpenLUAView.find(*tabIter); - if (viewInfoIter != m_dOpenLUAView.end()) + while (tabIter != m_CtrlTabOrder.end()) + { + if (*tabIter == m_lastFocusedAssetId) { - viewInfoIter->second.luaDockWidget()->show(); - viewInfoIter->second.luaDockWidget()->raise(); - viewInfoIter->second.luaViewWidget()->setFocus(); + break; } + tabIter++; + } + + if (tabIter == m_CtrlTabOrder.begin()) + { + tabIter = m_CtrlTabOrder.end(); + --tabIter; + } + else + { + --tabIter; + } + + TrackedLUAViewMap::iterator viewInfoIter = m_dOpenLUAView.find(*tabIter); + if (viewInfoIter != m_dOpenLUAView.end()) + { + viewInfoIter->second.luaDockWidget()->show(); + viewInfoIter->second.luaDockWidget()->raise(); + viewInfoIter->second.luaViewWidget()->setFocus(); + m_lastFocusedAssetId = *tabIter; } } void LUAEditorMainWindow::OnTabBackwards() - { - // pop the last entry and push it to the first spot - TrackedLUACtrlTabOrder::iterator tabIter = m_CtrlTabOrder.end(); - --tabIter; - if (tabIter != m_CtrlTabOrder.end()) + { + TrackedLUACtrlTabOrder::iterator tabIter = m_CtrlTabOrder.begin(); + while (tabIter != m_CtrlTabOrder.end()) { - AZStd::string assetId = *tabIter; - m_CtrlTabOrder.pop_back(); - m_CtrlTabOrder.push_front(assetId); - // then grab the new first entry and pass it on to the widgetry - tabIter = m_CtrlTabOrder.begin(); - - TrackedLUAViewMap::iterator viewInfoIter = m_dOpenLUAView.find(*tabIter); - if (viewInfoIter != m_dOpenLUAView.end()) + if (*tabIter == m_lastFocusedAssetId) { - viewInfoIter->second.luaDockWidget()->show(); - viewInfoIter->second.luaDockWidget()->raise(); - viewInfoIter->second.luaViewWidget()->setFocus(); + break; } + tabIter++; + } + + if (tabIter == m_CtrlTabOrder.end()) + { + return; + } + + tabIter++; + if (tabIter == m_CtrlTabOrder.end()) + { + tabIter = m_CtrlTabOrder.begin(); + + } + + TrackedLUAViewMap::iterator viewInfoIter = m_dOpenLUAView.find(*tabIter); + if (viewInfoIter != m_dOpenLUAView.end()) + { + viewInfoIter->second.luaDockWidget()->show(); + viewInfoIter->second.luaDockWidget()->raise(); + viewInfoIter->second.luaViewWidget()->setFocus(); + m_lastFocusedAssetId = *tabIter; } } diff --git a/Code/Tools/LuaIDE/Source/LUA/LUAEditorView.cpp b/Code/Tools/LuaIDE/Source/LUA/LUAEditorView.cpp index 18d12f292c..c83c9a5513 100644 --- a/Code/Tools/LuaIDE/Source/LUA/LUAEditorView.cpp +++ b/Code/Tools/LuaIDE/Source/LUA/LUAEditorView.cpp @@ -964,9 +964,11 @@ namespace LUAEditor int endLine; auto newText = AcumulateSelectedLines(startLine, endLine, callable); - SetSelection(startLine, 0, endLine + 1, 0); + SetSelection(startLine + 1, 0, endLine + 2, 0); + RemoveSelectedText(); + SetCursorPosition(startLine + 1, 0); ReplaceSelectedText(newText); - SetSelection(startLine, 0, endLine + 1, 0); + SetSelection(startLine + 1, 0, endLine + 1, INT_MAX); } void LUAViewWidget::CommentSelectedLines() @@ -1002,21 +1004,30 @@ namespace LUAEditor { int startLine; int endLine; - auto newText = AcumulateSelectedLines(startLine, endLine, [&](QString& newText, QTextBlock& block) + auto currText = AcumulateSelectedLines(startLine, endLine, [&](QString& newText, QTextBlock& block) { newText.append(block.text()); newText.append("\n"); }); + currText.remove(currText.count() - 1, 1); + if (startLine == 0) { return; } - - SetSelection(startLine - 1, INT_MAX, endLine, INT_MAX); + auto upText = GetLineText(startLine -1); + SetSelection(startLine, 0, startLine, INT_MAX); RemoveSelectedText(); - SetCursorPosition(startLine - 1, 0); - ReplaceSelectedText(newText); - SetSelection(startLine - 1, 0, endLine - 1, INT_MAX); + SetSelection(startLine + 1, 0, endLine + 1, INT_MAX); + RemoveSelectedText(); + + SetCursorPosition(startLine , 0); + ReplaceSelectedText(currText); + + SetCursorPosition(endLine + 1, 0); + ReplaceSelectedText(upText); + + SetSelection(startLine, 0, endLine, INT_MAX); } void LUAViewWidget::MoveSelectedLinesDn() @@ -1040,11 +1051,11 @@ namespace LUAEditor newText.prepend("\n"); } - SetSelection(startLine, 0, endLine + 1, 0); + SetSelection(startLine + 1, 0, endLine + 2, 0); RemoveSelectedText(); - SetCursorPosition(startLine + 1, 0); + SetCursorPosition(startLine + 2, 0); ReplaceSelectedText(newText); - SetSelection(startLine + 1, 0, endLine + 1, INT_MAX); + SetSelection(startLine + 2, 0, endLine + 2, INT_MAX); } void LUAViewWidget::SetReadonly(bool readonly) diff --git a/Code/Tools/ProjectManager/Platform/Mac/ProjectManager_Test_Traits_Mac.h b/Code/Tools/ProjectManager/Platform/Mac/ProjectManager_Test_Traits_Mac.h index 8d7fe068c2..3ebe7d8e44 100644 --- a/Code/Tools/ProjectManager/Platform/Mac/ProjectManager_Test_Traits_Mac.h +++ b/Code/Tools/ProjectManager/Platform/Mac/ProjectManager_Test_Traits_Mac.h @@ -8,4 +8,4 @@ #pragma once -#define AZ_TRAIT_DISABLE_FAILED_PROJECT_MANAGER_TESTS false +#define AZ_TRAIT_DISABLE_FAILED_PROJECT_MANAGER_TESTS true diff --git a/Code/Tools/ProjectManager/Platform/Windows/ProjectBuilderWorker_windows.cpp b/Code/Tools/ProjectManager/Platform/Windows/ProjectBuilderWorker_windows.cpp index b6b37b222d..d692e10baa 100644 --- a/Code/Tools/ProjectManager/Platform/Windows/ProjectBuilderWorker_windows.cpp +++ b/Code/Tools/ProjectManager/Platform/Windows/ProjectBuilderWorker_windows.cpp @@ -19,6 +19,7 @@ namespace O3DE::ProjectManager QString targetBuildPath = QDir(m_projectInfo.m_path).filePath(ProjectBuildPathPostfix); return AZ::Success(QStringList{ ProjectCMakeCommand, + "-G", "Visual Studio 16 2019", "-B", targetBuildPath, "-S", m_projectInfo.m_path, QString("-DLY_3RDPARTY_PATH=").append(thirdPartyPath) } ); diff --git a/Code/Tools/ProjectManager/Platform/Windows/ProjectUtils_windows.cpp b/Code/Tools/ProjectManager/Platform/Windows/ProjectUtils_windows.cpp index 38bb867244..89032320cd 100644 --- a/Code/Tools/ProjectManager/Platform/Windows/ProjectUtils_windows.cpp +++ b/Code/Tools/ProjectManager/Platform/Windows/ProjectUtils_windows.cpp @@ -77,7 +77,7 @@ namespace O3DE::ProjectManager if (vsWhereFile.exists() && vsWhereFile.isFile()) { QStringList vsWhereBaseArguments = QStringList{"-version", - "16.9.2", + "[16.9.2,17)", "-latest", "-requires", "Microsoft.VisualStudio.Component.VC.Tools.x86.x64"}; @@ -106,10 +106,8 @@ namespace O3DE::ProjectManager } return AZ::Failure(QObject::tr("Visual Studio 2019 version 16.9.2 or higher not found.

" - "Visual Studio 2019 is required to build this project." - " Install any edition of Visual Studio 2019" - " or update to a newer version before proceeding to the next step." - " While installing configure Visual Studio with these workloads.")); + "A compatible version of Visual Studio is required to build this project.
" + "Refer to the Visual Studio requirements for more information.")); } AZ::Outcome OpenCMakeGUI(const QString& projectPath) diff --git a/Code/Tools/ProjectManager/Source/ProjectsScreen.cpp b/Code/Tools/ProjectManager/Source/ProjectsScreen.cpp index 7e5675918d..15a6f22d85 100644 --- a/Code/Tools/ProjectManager/Source/ProjectsScreen.cpp +++ b/Code/Tools/ProjectManager/Source/ProjectsScreen.cpp @@ -284,13 +284,14 @@ namespace O3DE::ProjectManager { currentButton = projectButtonIter.value(); currentButton->RestoreDefaultState(); - m_projectsFlowLayout->addWidget(currentButton); } } // Check whether project manager has successfully built the project if (currentButton) { + m_projectsFlowLayout->addWidget(currentButton); + bool projectBuiltSuccessfully = false; SettingsInterface::Get()->GetProjectBuiltSuccessfully(projectBuiltSuccessfully, project); @@ -341,6 +342,7 @@ namespace O3DE::ProjectManager } m_stack->setCurrentWidget(m_projectsContent); + m_projectsFlowLayout->update(); } ProjectManagerScreen ProjectsScreen::GetScreenEnum() @@ -399,7 +401,6 @@ namespace O3DE::ProjectManager { if (ProjectUtils::AddProjectDialog(this)) { - ResetProjectsContent(); emit ChangeScreenRequest(ProjectManagerScreen::Projects); } } @@ -490,7 +491,6 @@ namespace O3DE::ProjectManager // Open file dialog and choose location for copied project then register copy with O3DE if (ProjectUtils::CopyProjectDialog(projectInfo.m_path, newProjectInfo, this)) { - ResetProjectsContent(); emit NotifyBuildProject(newProjectInfo); emit ChangeScreenRequest(ProjectManagerScreen::Projects); } @@ -503,7 +503,6 @@ namespace O3DE::ProjectManager // Unregister Project from O3DE and reload projects if (ProjectUtils::UnregisterProject(projectPath)) { - ResetProjectsContent(); emit ChangeScreenRequest(ProjectManagerScreen::Projects); } } diff --git a/Code/Tools/ProjectManager/Source/PythonBindings.cpp b/Code/Tools/ProjectManager/Source/PythonBindings.cpp index 35bdfe0031..7c436a3a70 100644 --- a/Code/Tools/ProjectManager/Source/PythonBindings.cpp +++ b/Code/Tools/ProjectManager/Source/PythonBindings.cpp @@ -1221,7 +1221,7 @@ namespace O3DE::ProjectManager auto result = ExecuteWithLockErrorHandling( [&] { - for (auto repoUri : m_manifest.attr("get_repos")()) + for (auto repoUri : m_manifest.attr("get_manifest_repos")()) { gemRepos.push_back(GetGemRepoInfo(repoUri)); } diff --git a/Code/Tools/PythonBindingsExample/tests/run_python_tests.bat b/Code/Tools/PythonBindingsExample/tests/run_python_tests.bat deleted file mode 100644 index 216f2dd0da..0000000000 --- a/Code/Tools/PythonBindingsExample/tests/run_python_tests.bat +++ /dev/null @@ -1,59 +0,0 @@ -@echo off - -REM -REM Copyright (c) Contributors to the Open 3D Engine Project. -REM For complete copyright and license terms please see the LICENSE at the root of this distribution. -REM -REM SPDX-License-Identifier: Apache-2.0 OR MIT -REM -REM - -PUSHD "%~dp0" - -SET CWD="%~dp0" -SET EXEPATH141="../../../../Bin64vc141/PythonBindingsExample.exe" -SET EXEPATH142="../../../../Bin64vc142/PythonBindingsExample.exe" -SET EXEPATH="" - -IF EXIST %EXEPATH141% ( - SET EXEPATH=%EXEPATH141% -) ELSE ( - IF EXIST %EXEPATH142% ( - SET EXEPATH=%EXEPATH142% - ) ELSE ( - ECHO PythonBindingsExample.exe not found. - ) -) -IF /I %EXEPATH% EQU "" ( - ECHO [FAILED] Could not run tests since a build of PythonBindingsExample.exe is missing - GOTO exit_app -) - -ECHO Testing basics of tool Python bindings in %CWD% - -%EXEPATH% --file test_hello_tool.py -IF %ERRORLEVEL% EQU 0 ( - ECHO [WORKED] test_hello_tool.py -) ELSE ( - ECHO [FAILED] test_hello_tool.py with %ERRORLEVEL% - GOTO exit_app -) - -%EXEPATH% --file test_framework.py --arg entity -IF %ERRORLEVEL% EQU 0 ( - ECHO [WORKED] test_framework.py --arg entity -) ELSE ( - ECHO [FAILED] test_framework.py --arg entity with %ERRORLEVEL% - GOTO exit_app -) - -%EXEPATH% --file test_framework.py --arg math -IF %ERRORLEVEL% EQU 0 ( - ECHO [WORKED] test_framework.py --arg math -) ELSE ( - ECHO [FAILED] test_framework.py --arg math with %ERRORLEVEL% - GOTO exit_app -) - -:exit_app -POPD diff --git a/Code/Tools/RemoteConsole/CMakeLists.txt b/Code/Tools/RemoteConsole/CMakeLists.txt index d2685b2aea..b9a08650b6 100644 --- a/Code/Tools/RemoteConsole/CMakeLists.txt +++ b/Code/Tools/RemoteConsole/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME RemoteConsoleCore STATIC diff --git a/Code/Tools/SceneAPI/SceneCore/DataTypes/Rules/IScriptProcessorRule.h b/Code/Tools/SceneAPI/SceneCore/DataTypes/Rules/IScriptProcessorRule.h index 36be5f61d3..2b2abae561 100644 --- a/Code/Tools/SceneAPI/SceneCore/DataTypes/Rules/IScriptProcessorRule.h +++ b/Code/Tools/SceneAPI/SceneCore/DataTypes/Rules/IScriptProcessorRule.h @@ -17,6 +17,12 @@ namespace AZ { namespace DataTypes { + enum class ScriptProcessorFallbackLogic + { + FailBuild, // this will log error & fail the build + ContinueBuild // this will log the errors but continue the build logic + }; + class IScriptProcessorRule : public IRule { @@ -26,6 +32,8 @@ namespace AZ virtual ~IScriptProcessorRule() override = default; virtual const AZStd::string& GetScriptFilename() const = 0; + + virtual ScriptProcessorFallbackLogic GetScriptProcessorFallbackLogic() const = 0; }; } // DataTypes } // SceneAPI diff --git a/Code/Tools/SceneAPI/SceneData/Behaviors/ScriptProcessorRuleBehavior.cpp b/Code/Tools/SceneAPI/SceneData/Behaviors/ScriptProcessorRuleBehavior.cpp index 8d413b6038..6046bfa620 100644 --- a/Code/Tools/SceneAPI/SceneData/Behaviors/ScriptProcessorRuleBehavior.cpp +++ b/Code/Tools/SceneAPI/SceneData/Behaviors/ScriptProcessorRuleBehavior.cpp @@ -173,10 +173,13 @@ namespace AZ::SceneAPI::Behaviors UnloadPython(); } - bool ScriptProcessorRuleBehavior::LoadPython(const AZ::SceneAPI::Containers::Scene& scene, AZStd::string& scriptPath) + bool ScriptProcessorRuleBehavior::LoadPython(const AZ::SceneAPI::Containers::Scene& scene, AZStd::string& scriptPath, Events::ProcessingResult& fallbackResult) { + using namespace AZ::SceneAPI; + + fallbackResult = Events::ProcessingResult::Failure; int scriptDiscoveryAttempts = 0; - const AZ::SceneAPI::Containers::SceneManifest& manifest = scene.GetManifest(); + const Containers::SceneManifest& manifest = scene.GetManifest(); auto view = Containers::MakeDerivedFilterView(manifest.GetValueStorage()); for (const auto& scriptItem : view) { @@ -188,6 +191,8 @@ namespace AZ::SceneAPI::Behaviors } ++scriptDiscoveryAttempts; + fallbackResult = (scriptItem.GetScriptProcessorFallbackLogic() == DataTypes::ScriptProcessorFallbackLogic::ContinueBuild) ? + Events::ProcessingResult::Ignored : Events::ProcessingResult::Failure; // check for file exist via absolute path if (!IO::FileIOBase::GetInstance()->Exists(scriptFilename.c_str())) @@ -301,7 +306,8 @@ namespace AZ::SceneAPI::Behaviors } }; - if (LoadPython(context.GetScene(), scriptPath)) + [[maybe_unused]] Events::ProcessingResult fallbackResult; + if (LoadPython(context.GetScene(), scriptPath, fallbackResult)) { EditorPythonConsoleNotificationHandler logger; m_editorPythonEventsInterface->ExecuteWithLock(executeCallback); @@ -333,8 +339,9 @@ namespace AZ::SceneAPI::Behaviors return Events::ProcessingResult::Ignored; } + Events::ProcessingResult fallbackResult; AZStd::string scriptPath; - if (LoadPython(scene, scriptPath)) + if (LoadPython(scene, scriptPath, fallbackResult)) { AZStd::string manifestUpdate; auto executeCallback = [&scene, &manifestUpdate, &scriptPath]() @@ -349,6 +356,12 @@ namespace AZ::SceneAPI::Behaviors EditorPythonConsoleNotificationHandler logger; m_editorPythonEventsInterface->ExecuteWithLock(executeCallback); + // if the returned scene manifest is empty then ignore the script update + if (manifestUpdate.empty()) + { + return Events::ProcessingResult::Ignored; + } + EntityUtilityBus::Broadcast(&EntityUtilityBus::Events::ResetEntityContext); AZ::Interface::Get()->RemoveAllTemplates(); @@ -364,6 +377,11 @@ namespace AZ::SceneAPI::Behaviors } return Events::ProcessingResult::Success; } + else + { + // if the manifest was not updated by the script, then return back the fallback result + return fallbackResult; + } } return Events::ProcessingResult::Ignored; } diff --git a/Code/Tools/SceneAPI/SceneData/Behaviors/ScriptProcessorRuleBehavior.h b/Code/Tools/SceneAPI/SceneData/Behaviors/ScriptProcessorRuleBehavior.h index a9ddf88df9..8903a8f257 100644 --- a/Code/Tools/SceneAPI/SceneData/Behaviors/ScriptProcessorRuleBehavior.h +++ b/Code/Tools/SceneAPI/SceneData/Behaviors/ScriptProcessorRuleBehavior.h @@ -54,7 +54,7 @@ namespace AZ::SceneAPI::Behaviors SCENE_DATA_API void GetManifestDependencyPaths(AZStd::vector& paths) override; protected: - bool LoadPython(const AZ::SceneAPI::Containers::Scene& scene, AZStd::string& scriptPath); + bool LoadPython(const AZ::SceneAPI::Containers::Scene& scene, AZStd::string& scriptPath, Events::ProcessingResult& fallbackResult); void UnloadPython(); bool DoPrepareForExport(Events::PreExportEventContext& context); diff --git a/Code/Tools/SceneAPI/SceneData/CMakeLists.txt b/Code/Tools/SceneAPI/SceneData/CMakeLists.txt index 5507ada2b9..0d4ef4a5df 100644 --- a/Code/Tools/SceneAPI/SceneData/CMakeLists.txt +++ b/Code/Tools/SceneAPI/SceneData/CMakeLists.txt @@ -10,7 +10,7 @@ if (NOT PAL_TRAIT_BUILD_HOST_TOOLS) return() endif() -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_add_target( NAME SceneData SHARED diff --git a/Code/Tools/SceneAPI/SceneData/Rules/ScriptProcessorRule.cpp b/Code/Tools/SceneAPI/SceneData/Rules/ScriptProcessorRule.cpp index 5893764eb1..15c8c1b7f3 100644 --- a/Code/Tools/SceneAPI/SceneData/Rules/ScriptProcessorRule.cpp +++ b/Code/Tools/SceneAPI/SceneData/Rules/ScriptProcessorRule.cpp @@ -14,6 +14,9 @@ namespace AZ { + // Enum types must have a TypeId tied to it in order for the reflection to succeed. + AZ_TYPE_INFO_SPECIALIZE(SceneAPI::DataTypes::ScriptProcessorFallbackLogic, "{3DCABF3D-E8EF-43E7-B3C7-373E05825F60}"); + namespace SceneAPI { namespace SceneData @@ -23,13 +26,23 @@ namespace AZ return m_scriptFilename; } + DataTypes::ScriptProcessorFallbackLogic ScriptProcessorRule::GetScriptProcessorFallbackLogic() const + { + return m_fallbackLogic; + } + void ScriptProcessorRule::Reflect(AZ::ReflectContext* context) { AZ::SerializeContext* serializeContext = azrtti_cast(context); if (serializeContext) { - serializeContext->Class()->Version(1) - ->Field("scriptFilename", &ScriptProcessorRule::m_scriptFilename); + serializeContext->Class()->Version(2) + ->Field("scriptFilename", &ScriptProcessorRule::m_scriptFilename) + ->Field("fallbackLogic", &ScriptProcessorRule::m_fallbackLogic); + + serializeContext->Enum() + ->Value("FailBuild", DataTypes::ScriptProcessorFallbackLogic::FailBuild) + ->Value("ContinueBuild", DataTypes::ScriptProcessorFallbackLogic::ContinueBuild); AZ::EditContext* editContext = serializeContext->GetEditContext(); if (editContext) diff --git a/Code/Tools/SceneAPI/SceneData/Rules/ScriptProcessorRule.h b/Code/Tools/SceneAPI/SceneData/Rules/ScriptProcessorRule.h index ad5e1de063..80cb670f9f 100644 --- a/Code/Tools/SceneAPI/SceneData/Rules/ScriptProcessorRule.h +++ b/Code/Tools/SceneAPI/SceneData/Rules/ScriptProcessorRule.h @@ -35,10 +35,13 @@ namespace AZ m_scriptFilename = AZStd::move(scriptFilename); } + DataTypes::ScriptProcessorFallbackLogic GetScriptProcessorFallbackLogic() const override; + static void Reflect(ReflectContext* context); protected: AZStd::string m_scriptFilename; + DataTypes::ScriptProcessorFallbackLogic m_fallbackLogic = DataTypes::ScriptProcessorFallbackLogic::FailBuild; }; } // SceneData } // SceneAPI diff --git a/Code/Tools/SceneAPI/SceneData/Tests/SceneManifest/SceneManifestRuleTests.cpp b/Code/Tools/SceneAPI/SceneData/Tests/SceneManifest/SceneManifestRuleTests.cpp index e0d5cca484..2bbbc1054a 100644 --- a/Code/Tools/SceneAPI/SceneData/Tests/SceneManifest/SceneManifestRuleTests.cpp +++ b/Code/Tools/SceneAPI/SceneData/Tests/SceneManifest/SceneManifestRuleTests.cpp @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include @@ -271,5 +272,79 @@ namespace AZ auto update = scriptProcessorRuleBehavior.UpdateManifest(scene, AssetImportRequest::Update, AssetImportRequest::Generic); EXPECT_EQ(update, ProcessingResult::Ignored); } + + TEST_F(SceneManifest_JSON, ScriptProcessorRule_DefaultFallbackLogic_Works) + { + using namespace AZ::SceneAPI; + + constexpr const char* defaultJson = { R"JSON( + { + "values": [ + { + "$type": "ScriptProcessorRule", + "scriptFilename": "foo.py" + } + ] + })JSON" }; + + auto scene = Containers::Scene("mock"); + auto result = scene.GetManifest().LoadFromString(defaultJson, m_serializeContext.get(), m_jsonRegistrationContext.get()); + EXPECT_TRUE(result.IsSuccess()); + EXPECT_FALSE(scene.GetManifest().IsEmpty()); + ASSERT_EQ(scene.GetManifest().GetEntryCount(), 1); + + auto view = Containers::MakeDerivedFilterView(scene.GetManifest().GetValueStorage()); + EXPECT_EQ(view.begin()->GetScriptProcessorFallbackLogic(), DataTypes::ScriptProcessorFallbackLogic::FailBuild); + } + + TEST_F(SceneManifest_JSON, ScriptProcessorRule_ExplicitFallbackLogic_Works) + { + using namespace AZ::SceneAPI; + + constexpr const char* fallbackLogicJson = { R"JSON( + { + "values": [ + { + "$type": "ScriptProcessorRule", + "scriptFilename": "foo.py", + "fallbackLogic": "FailBuild" + } + ] + })JSON" }; + + auto scene = Containers::Scene("mock"); + auto result = scene.GetManifest().LoadFromString(fallbackLogicJson, m_serializeContext.get(), m_jsonRegistrationContext.get()); + EXPECT_TRUE(result.IsSuccess()); + EXPECT_FALSE(scene.GetManifest().IsEmpty()); + ASSERT_EQ(scene.GetManifest().GetEntryCount(), 1); + + auto view = Containers::MakeDerivedFilterView(scene.GetManifest().GetValueStorage()); + EXPECT_EQ(view.begin()->GetScriptProcessorFallbackLogic(), DataTypes::ScriptProcessorFallbackLogic::FailBuild); + } + + TEST_F(SceneManifest_JSON, ScriptProcessorRule_ContinueBuildFallbackLogic_Works) + { + using namespace AZ::SceneAPI; + + constexpr const char* fallbackLogicJson = { R"JSON( + { + "values": [ + { + "$type": "ScriptProcessorRule", + "scriptFilename": "foo.py", + "fallbackLogic": "ContinueBuild" + } + ] + })JSON" }; + + auto scene = Containers::Scene("mock"); + auto result = scene.GetManifest().LoadFromString(fallbackLogicJson, m_serializeContext.get(), m_jsonRegistrationContext.get()); + EXPECT_TRUE(result.IsSuccess()); + EXPECT_FALSE(scene.GetManifest().IsEmpty()); + ASSERT_EQ(scene.GetManifest().GetEntryCount(), 1); + + auto view = Containers::MakeDerivedFilterView(scene.GetManifest().GetValueStorage()); + EXPECT_EQ(view.begin()->GetScriptProcessorFallbackLogic(), DataTypes::ScriptProcessorFallbackLogic::ContinueBuild); + } } } diff --git a/Code/Tools/SerializeContextTools/SliceConverter.cpp b/Code/Tools/SerializeContextTools/SliceConverter.cpp index d0528a9cad..cfb1998f48 100644 --- a/Code/Tools/SerializeContextTools/SliceConverter.cpp +++ b/Code/Tools/SerializeContextTools/SliceConverter.cpp @@ -79,10 +79,6 @@ namespace AZ return false; } - // Load the asset catalog so that we can find any nested assets successfully. We also need to tick the tick bus - // so that the OnCatalogLoaded event gets processed now, instead of during application shutdown. - application.Tick(); - AZStd::string logggingScratchBuffer; SetupLogging(logggingScratchBuffer, convertSettings.m_reporting, *commandLine); diff --git a/Code/Tools/TestImpactFramework/CMakeLists.txt b/Code/Tools/TestImpactFramework/CMakeLists.txt index 1cdf02d101..15d93b1a70 100644 --- a/Code/Tools/TestImpactFramework/CMakeLists.txt +++ b/Code/Tools/TestImpactFramework/CMakeLists.txt @@ -6,9 +6,9 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) -include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) +include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) if(PAL_TRAIT_TEST_IMPACT_FRAMEWORK_SUPPORTED) add_subdirectory(Runtime) diff --git a/Code/Tools/TestImpactFramework/Runtime/Code/CMakeLists.txt b/Code/Tools/TestImpactFramework/Runtime/Code/CMakeLists.txt index 0b8432642a..f3262a26af 100644 --- a/Code/Tools/TestImpactFramework/Runtime/Code/CMakeLists.txt +++ b/Code/Tools/TestImpactFramework/Runtime/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) +set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) ly_add_target( NAME TestImpact.Runtime.Static STATIC diff --git a/Gems/AWSClientAuth/CMakeLists.txt b/Gems/AWSClientAuth/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/AWSClientAuth/CMakeLists.txt +++ b/Gems/AWSClientAuth/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/AWSClientAuth/Code/CMakeLists.txt b/Gems/AWSClientAuth/Code/CMakeLists.txt index 1f0c119f5a..ac9d221f07 100644 --- a/Gems/AWSClientAuth/Code/CMakeLists.txt +++ b/Gems/AWSClientAuth/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME AWSClientAuth.Static STATIC diff --git a/Gems/AWSClientAuth/gem.json b/Gems/AWSClientAuth/gem.json index 9c7188f103..d6729cee99 100644 --- a/Gems/AWSClientAuth/gem.json +++ b/Gems/AWSClientAuth/gem.json @@ -3,7 +3,8 @@ "display_name": "AWS Client Authorization", "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", - "origin": "Amazon Web Services, Inc.", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "AWS Client Auth provides client authentication and AWS authorization solution.", "canonical_tags": [ @@ -15,6 +16,7 @@ "SDK" ], "icon_path": "preview.png", + "requirements": "", "documentation_url": "https://o3de.org/docs/user-guide/gems/reference/aws/aws-client-auth/", "dependencies": [ "AWSCore", diff --git a/Gems/AWSCore/CMakeLists.txt b/Gems/AWSCore/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/AWSCore/CMakeLists.txt +++ b/Gems/AWSCore/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/AWSCore/Code/CMakeLists.txt b/Gems/AWSCore/Code/CMakeLists.txt index 974f3f03bf..3911aefce6 100644 --- a/Gems/AWSCore/Code/CMakeLists.txt +++ b/Gems/AWSCore/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME AWSCore.Static STATIC @@ -61,7 +61,7 @@ ly_create_alias( if (PAL_TRAIT_BUILD_HOST_TOOLS) - include(${CMAKE_CURRENT_SOURCE_DIR}/Platform/${PAL_PLATFORM_NAME}/PAL_traits_editor_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) + include(${pal_dir}/PAL_traits_editor_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) ly_add_target( NAME AWSCore.Editor.Static STATIC @@ -202,6 +202,7 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) 3rdParty::Qt::Gui 3rdParty::Qt::Widgets AZ::AzTest + AZ::AWSNativeSDKInit Gem::AWSCore.Static Gem::AWSCore.Editor.Static ) diff --git a/Gems/AWSCore/Code/Platform/Linux/AWSCore_Traits_Linux.h b/Gems/AWSCore/Code/Platform/Linux/AWSCore_Traits_Linux.h index d7b1f32461..2cacfb0d34 100644 --- a/Gems/AWSCore/Code/Platform/Linux/AWSCore_Traits_Linux.h +++ b/Gems/AWSCore/Code/Platform/Linux/AWSCore_Traits_Linux.h @@ -7,4 +7,4 @@ */ #pragma once -#define AWSCORE_BACKWARD_INCOMPATIBLE_CHANGE 0 +#define AWSCORE_BACKWARD_INCOMPATIBLE_CHANGE 1 diff --git a/Gems/AWSCore/Code/Platform/Mac/AWSCore_Traits_Mac.h b/Gems/AWSCore/Code/Platform/Mac/AWSCore_Traits_Mac.h index d7b1f32461..2cacfb0d34 100644 --- a/Gems/AWSCore/Code/Platform/Mac/AWSCore_Traits_Mac.h +++ b/Gems/AWSCore/Code/Platform/Mac/AWSCore_Traits_Mac.h @@ -7,4 +7,4 @@ */ #pragma once -#define AWSCORE_BACKWARD_INCOMPATIBLE_CHANGE 0 +#define AWSCORE_BACKWARD_INCOMPATIBLE_CHANGE 1 diff --git a/Gems/AWSCore/Code/Platform/Windows/AWSCore_Traits_Windows.h b/Gems/AWSCore/Code/Platform/Windows/AWSCore_Traits_Windows.h index d7b1f32461..2cacfb0d34 100644 --- a/Gems/AWSCore/Code/Platform/Windows/AWSCore_Traits_Windows.h +++ b/Gems/AWSCore/Code/Platform/Windows/AWSCore_Traits_Windows.h @@ -7,4 +7,4 @@ */ #pragma once -#define AWSCORE_BACKWARD_INCOMPATIBLE_CHANGE 0 +#define AWSCORE_BACKWARD_INCOMPATIBLE_CHANGE 1 diff --git a/Gems/AWSCore/Code/Platform/iOS/AWSCore_Traits_iOS.h b/Gems/AWSCore/Code/Platform/iOS/AWSCore_Traits_iOS.h index d7b1f32461..2cacfb0d34 100644 --- a/Gems/AWSCore/Code/Platform/iOS/AWSCore_Traits_iOS.h +++ b/Gems/AWSCore/Code/Platform/iOS/AWSCore_Traits_iOS.h @@ -7,4 +7,4 @@ */ #pragma once -#define AWSCORE_BACKWARD_INCOMPATIBLE_CHANGE 0 +#define AWSCORE_BACKWARD_INCOMPATIBLE_CHANGE 1 diff --git a/Gems/AWSCore/Code/Tests/AWSCoreSystemComponentTest.cpp b/Gems/AWSCore/Code/Tests/AWSCoreSystemComponentTest.cpp index 648648e945..b66b43f735 100644 --- a/Gems/AWSCore/Code/Tests/AWSCoreSystemComponentTest.cpp +++ b/Gems/AWSCore/Code/Tests/AWSCoreSystemComponentTest.cpp @@ -19,6 +19,7 @@ #include #include +#include #include #include #include @@ -103,6 +104,9 @@ public: TEST_F(AWSCoreSystemComponentTest, ComponentActivateTest) { + // Shutdown SDK which is init in fixture setup step + AWSNativeSDKInit::InitializationManager::Shutdown(); + EXPECT_FALSE(m_coreSystemsComponent->IsAWSApiInitialized()); // activate component diff --git a/Gems/AWSCore/Code/Tests/Configuration/AWSCoreConfigurationTest.cpp b/Gems/AWSCore/Code/Tests/Configuration/AWSCoreConfigurationTest.cpp index e54a55f728..696dfd25d3 100644 --- a/Gems/AWSCore/Code/Tests/Configuration/AWSCoreConfigurationTest.cpp +++ b/Gems/AWSCore/Code/Tests/Configuration/AWSCoreConfigurationTest.cpp @@ -8,7 +8,6 @@ #include #include -#include #include #include @@ -39,12 +38,11 @@ class AWSCoreConfigurationTest : public AWSCoreFixture { public: - void CreateTestSetRegFile(const AZStd::string& setregContent) + AWSCoreConfigurationTest() { - m_normalizedSetRegFilePath = AZStd::string::format("%s/%s", - m_normalizedSetRegFolderPath.c_str(), AWSCore::AWSCoreConfiguration::AWSCoreConfigurationFileName); - AzFramework::StringFunc::Path::Normalize(m_normalizedSetRegFilePath); - CreateTestFile(m_normalizedSetRegFilePath, setregContent); + m_setRegFilePath = (GetTestTempDirectoryPath() / + AZ::SettingsRegistryInterface::RegistryFolder / + AWSCore::AWSCoreConfiguration::AWSCoreConfigurationFileName).LexicallyNormal(); } void SetUp() override @@ -53,22 +51,13 @@ public: m_awsCoreConfiguration = AZStd::make_unique(); - m_normalizedSourceProjectFolder = AZStd::string::format("%s/%s%s/", AZ::Test::GetCurrentExecutablePath().c_str(), - "AWSResourceMappingManager", AZ::Uuid::CreateRandom().ToString(false, false).c_str()); - AzFramework::StringFunc::Path::Normalize(m_normalizedSourceProjectFolder); - m_normalizedSetRegFolderPath = AZStd::string::format("%s/%s/", - m_normalizedSourceProjectFolder.c_str(), AZ::SettingsRegistryInterface::RegistryFolder); - AzFramework::StringFunc::Path::Normalize(m_normalizedSetRegFolderPath); - - m_localFileIO->SetAlias("@projectroot@", m_normalizedSourceProjectFolder.c_str()); - - CreateTestSetRegFile(TEST_VALID_RESOURCE_MAPPING_SETREG); + CreateFile(m_setRegFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_SETREG); + m_localFileIO->SetAlias("@projectroot@", GetTestTempDirectoryPath().Native().c_str()); } void TearDown() override { - RemoveTestFile(); - RemoveTestDirectory(); + RemoveFile(m_setRegFilePath.Native()); m_awsCoreConfiguration.reset(); @@ -76,52 +65,12 @@ public: } AZStd::unique_ptr m_awsCoreConfiguration; - AZStd::string m_normalizedSetRegFilePath; - -private: - AZStd::string m_normalizedSourceProjectFolder; - AZStd::string m_normalizedSetRegFolderPath; - - void CreateTestFile(const AZStd::string& filePath, const AZStd::string& fileContent) - { - AZ::IO::SystemFile file; - if (!file.Open(filePath.c_str(), - AZ::IO::SystemFile::OpenMode::SF_OPEN_CREATE | AZ::IO::SystemFile::SF_OPEN_CREATE_PATH | AZ::IO::SystemFile::SF_OPEN_WRITE_ONLY)) - { - AZ_Assert(false, "Failed to open test file"); - } - - if (file.Write(fileContent.c_str(), fileContent.size()) != fileContent.size()) - { - AZ_Assert(false, "Failed to write test file"); - } - file.Close(); - } - - void RemoveTestFile() - { - if (!m_normalizedSetRegFilePath.empty()) - { - AZ_Assert(AZ::IO::SystemFile::Delete(m_normalizedSetRegFilePath.c_str()), - "Failed to delete test settings registry file at %s", m_normalizedSetRegFilePath.c_str()); - } - } - - void RemoveTestDirectory() - { - if (!m_normalizedSetRegFilePath.empty()) - { - AZ_Assert(AZ::IO::SystemFile::DeleteDir(m_normalizedSetRegFolderPath.c_str()), - "Failed to delete test settings registry folder at %s", m_normalizedSetRegFolderPath.c_str()); - AZ_Assert(AZ::IO::SystemFile::DeleteDir(m_normalizedSourceProjectFolder.c_str()), - "Failed to delete test folder at %s", m_normalizedSourceProjectFolder.c_str()); - } - } + AZ::IO::Path m_setRegFilePath; }; TEST_F(AWSCoreConfigurationTest, InitConfig_NoSourceProjectFolderFound_ReturnEmptyConfigFilePath) { - m_settingsRegistry->MergeSettingsFile(m_normalizedSetRegFilePath, AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); + m_settingsRegistry->MergeSettingsFile(m_setRegFilePath.Native(), AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); m_localFileIO->ClearAlias("@projectroot@"); AZ_TEST_START_TRACE_SUPPRESSION; @@ -134,8 +83,8 @@ TEST_F(AWSCoreConfigurationTest, InitConfig_NoSourceProjectFolderFound_ReturnEmp TEST_F(AWSCoreConfigurationTest, InitConfig_SettingsRegistryIsEmpty_ReturnEmptyConfigFilePath) { - CreateTestSetRegFile(TEST_INVALID_RESOURCE_MAPPING_SETREG); - m_settingsRegistry->MergeSettingsFile(m_normalizedSetRegFilePath, AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); + CreateFile(m_setRegFilePath.Native(), TEST_INVALID_RESOURCE_MAPPING_SETREG); + m_settingsRegistry->MergeSettingsFile(m_setRegFilePath.Native(), AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); m_awsCoreConfiguration->InitConfig(); auto actualConfigFilePath = m_awsCoreConfiguration->GetResourceMappingConfigFilePath(); @@ -144,7 +93,7 @@ TEST_F(AWSCoreConfigurationTest, InitConfig_SettingsRegistryIsEmpty_ReturnEmptyC TEST_F(AWSCoreConfigurationTest, InitConfig_LoadValidSettingsRegistry_ReturnNonEmptyConfigFilePath) { - m_settingsRegistry->MergeSettingsFile(m_normalizedSetRegFilePath, AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); + m_settingsRegistry->MergeSettingsFile(m_setRegFilePath.Native(), AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); m_awsCoreConfiguration->InitConfig(); auto actualConfigFilePath = m_awsCoreConfiguration->GetResourceMappingConfigFilePath(); @@ -153,7 +102,7 @@ TEST_F(AWSCoreConfigurationTest, InitConfig_LoadValidSettingsRegistry_ReturnNonE TEST_F(AWSCoreConfigurationTest, ReloadConfiguration_NoSourceProjectFolderFound_ReturnEmptyConfigFilePath) { - m_settingsRegistry->MergeSettingsFile(m_normalizedSetRegFilePath, AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); + m_settingsRegistry->MergeSettingsFile(m_setRegFilePath.Native(), AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); m_localFileIO->ClearAlias("@projectroot@"); m_awsCoreConfiguration->ReloadConfiguration(); @@ -163,8 +112,8 @@ TEST_F(AWSCoreConfigurationTest, ReloadConfiguration_NoSourceProjectFolderFound_ TEST_F(AWSCoreConfigurationTest, ReloadConfiguration_LoadValidSettingsRegistryAfterInvalidOne_ReturnNonEmptyConfigFilePath) { - CreateTestSetRegFile(TEST_INVALID_RESOURCE_MAPPING_SETREG); - m_settingsRegistry->MergeSettingsFile(m_normalizedSetRegFilePath, AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); + CreateFile(m_setRegFilePath.Native(), TEST_INVALID_RESOURCE_MAPPING_SETREG); + m_settingsRegistry->MergeSettingsFile(m_setRegFilePath.Native(), AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); m_awsCoreConfiguration->InitConfig(); auto actualConfigFilePath = m_awsCoreConfiguration->GetResourceMappingConfigFilePath(); @@ -172,7 +121,7 @@ TEST_F(AWSCoreConfigurationTest, ReloadConfiguration_LoadValidSettingsRegistryAf EXPECT_TRUE(actualConfigFilePath.empty()); EXPECT_TRUE(actualProfileName == AWSCoreConfiguration::AWSCoreDefaultProfileName); - CreateTestSetRegFile(TEST_VALID_RESOURCE_MAPPING_SETREG); + CreateFile(m_setRegFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_SETREG); m_awsCoreConfiguration->ReloadConfiguration(); actualConfigFilePath = m_awsCoreConfiguration->GetResourceMappingConfigFilePath(); @@ -183,7 +132,7 @@ TEST_F(AWSCoreConfigurationTest, ReloadConfiguration_LoadValidSettingsRegistryAf TEST_F(AWSCoreConfigurationTest, ReloadConfiguration_LoadInvalidSettingsRegistryAfterValidOne_ReturnEmptyConfigFilePath) { - m_settingsRegistry->MergeSettingsFile(m_normalizedSetRegFilePath, AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); + m_settingsRegistry->MergeSettingsFile(m_setRegFilePath.Native(), AZ::SettingsRegistryInterface::Format::JsonMergePatch, {}); m_awsCoreConfiguration->InitConfig(); auto actualConfigFilePath = m_awsCoreConfiguration->GetResourceMappingConfigFilePath(); @@ -191,7 +140,7 @@ TEST_F(AWSCoreConfigurationTest, ReloadConfiguration_LoadInvalidSettingsRegistry EXPECT_FALSE(actualConfigFilePath.empty()); EXPECT_TRUE(actualProfileName != AWSCoreConfiguration::AWSCoreDefaultProfileName); - CreateTestSetRegFile(TEST_INVALID_RESOURCE_MAPPING_SETREG); + CreateFile(m_setRegFilePath.Native(), TEST_INVALID_RESOURCE_MAPPING_SETREG); m_awsCoreConfiguration->ReloadConfiguration(); actualConfigFilePath = m_awsCoreConfiguration->GetResourceMappingConfigFilePath(); diff --git a/Gems/AWSCore/Code/Tests/Credential/AWSCVarCredentialHandlerTest.cpp b/Gems/AWSCore/Code/Tests/Credential/AWSCVarCredentialHandlerTest.cpp index 244c945af9..248737fbe6 100644 --- a/Gems/AWSCore/Code/Tests/Credential/AWSCVarCredentialHandlerTest.cpp +++ b/Gems/AWSCore/Code/Tests/Credential/AWSCVarCredentialHandlerTest.cpp @@ -25,6 +25,11 @@ public: m_credentialHandler = AZStd::make_unique(); } + void TearDown() override + { + m_credentialHandler.reset(); + } + AZStd::unique_ptr m_credentialHandler; }; diff --git a/Gems/AWSCore/Code/Tests/Credential/AWSCredentialBusTest.cpp b/Gems/AWSCore/Code/Tests/Credential/AWSCredentialBusTest.cpp index 82c8c84b81..1b4318f472 100644 --- a/Gems/AWSCore/Code/Tests/Credential/AWSCredentialBusTest.cpp +++ b/Gems/AWSCore/Code/Tests/Credential/AWSCredentialBusTest.cpp @@ -6,8 +6,6 @@ * */ -#include - #include #include @@ -19,14 +17,10 @@ class TestCredentialHandlerOne : AWSCredentialRequestBus::Handler { public: - TestCredentialHandlerOne() + void ActivateHandler() { m_handlerCounter = 0; m_credentialsProvider = std::make_shared(); - } - - void ActivateHandler() - { AWSCredentialRequestBus::Handler::BusConnect(); } @@ -55,14 +49,10 @@ class TestCredentialHandlerTwo : AWSCredentialRequestBus::Handler { public: - TestCredentialHandlerTwo() + void ActivateHandler() { m_handlerCounter = 0; m_credentialsProvider = std::make_shared(); - } - - void ActivateHandler() - { AWSCredentialRequestBus::Handler::BusConnect(); } @@ -88,7 +78,7 @@ public: }; class AWSCredentialBusTest - : public UnitTest::ScopedAllocatorSetupFixture + : public AWSCoreFixture { public: AWSCredentialBusTest() @@ -99,6 +89,8 @@ public: void SetUp() override { + AWSCoreFixture::SetUpFixture(); + m_handlerOne->ActivateHandler(); m_handlerTwo->ActivateHandler(); } @@ -107,6 +99,8 @@ public: { m_handlerOne->DeactivateHandler(); m_handlerTwo->DeactivateHandler(); + + AWSCoreFixture::TearDownFixture(); } AZStd::unique_ptr m_handlerOne; diff --git a/Gems/AWSCore/Code/Tests/Credential/AWSDefaultCredentialHandlerTest.cpp b/Gems/AWSCore/Code/Tests/Credential/AWSDefaultCredentialHandlerTest.cpp index af03afb337..4ff82bcb62 100644 --- a/Gems/AWSCore/Code/Tests/Credential/AWSDefaultCredentialHandlerTest.cpp +++ b/Gems/AWSCore/Code/Tests/Credential/AWSDefaultCredentialHandlerTest.cpp @@ -6,11 +6,9 @@ * */ -#include -#include - #include #include +#include using namespace AWSCore; @@ -18,13 +16,15 @@ static constexpr char AWSDEFAULTCREDENTIALHANDLERTEST_ALLOC_TAG[] = "AWSDefaultC static constexpr const char* AWS_ACCESS_KEY = "AWSACCESSKEY"; static constexpr const char* AWS_SECRET_KEY = "AWSSECRETKEY"; -class EnvironmentAWSCredentialsProviderMock : public Aws::Auth::EnvironmentAWSCredentialsProvider +class EnvironmentAWSCredentialsProviderMock + : public Aws::Auth::EnvironmentAWSCredentialsProvider { public: MOCK_METHOD0(GetAWSCredentials, Aws::Auth::AWSCredentials()); }; -class ProfileConfigFileAWSCredentialsProviderMock : public Aws::Auth::ProfileConfigFileAWSCredentialsProvider +class ProfileConfigFileAWSCredentialsProviderMock + : public Aws::Auth::ProfileConfigFileAWSCredentialsProvider { public: MOCK_METHOD0(GetAWSCredentials, Aws::Auth::AWSCredentials()); @@ -44,7 +44,7 @@ public: }; class AWSDefaultCredentialHandlerTest - : public UnitTest::ScopedAllocatorSetupFixture + : public AWSCoreFixture , public AWSCoreInternalRequestBus::Handler { public: @@ -53,6 +53,8 @@ public: void SetUp() override { + AWSCoreFixture::SetUpFixture(); + AWSCoreInternalRequestBus::Handler::BusConnect(); m_environmentCredentialsProviderMock = Aws::MakeShared(AWSDEFAULTCREDENTIALHANDLERTEST_ALLOC_TAG); m_profileCredentialsProviderMock = Aws::MakeShared(AWSDEFAULTCREDENTIALHANDLERTEST_ALLOC_TAG); @@ -68,6 +70,8 @@ public: m_profileCredentialsProviderMock.reset(); m_environmentCredentialsProviderMock.reset(); AWSCoreInternalRequestBus::Handler::BusDisconnect(); + + AWSCoreFixture::TearDownFixture(); } // AWSCoreInternalRequestBus interface implementation diff --git a/Gems/AWSCore/Code/Tests/Editor/Attribution/AWSAttributionServiceApiTest.cpp b/Gems/AWSCore/Code/Tests/Editor/Attribution/AWSAttributionServiceApiTest.cpp index 4290713e5c..e17d5c1fbf 100644 --- a/Gems/AWSCore/Code/Tests/Editor/Attribution/AWSAttributionServiceApiTest.cpp +++ b/Gems/AWSCore/Code/Tests/Editor/Attribution/AWSAttributionServiceApiTest.cpp @@ -11,7 +11,7 @@ #include #include -#include +#include using namespace AWSCore; @@ -36,7 +36,7 @@ namespace AWSCoreUnitTest }; class AWSAttributionServiceApiTest - : public UnitTest::ScopedAllocatorSetupFixture + : public AWSCoreFixture { public: testing::NiceMock JsonReader; @@ -72,12 +72,11 @@ namespace AWSCoreUnitTest AWSCore::RequestBuilder requestBuilder{}; EXPECT_TRUE(request.parameters.BuildRequest(requestBuilder)); std::shared_ptr bodyContent = requestBuilder.GetBodyContent(); - EXPECT_TRUE(bodyContent != nullptr); + EXPECT_NE(nullptr, bodyContent); - AZStd::string bodyString; std::istreambuf_iterator eos; - bodyString = AZStd::string{ std::istreambuf_iterator(*bodyContent), eos }; - AZ_Printf("AWSAttributionServiceApiTest", bodyString.c_str()); - EXPECT_TRUE(bodyString.find(AZStd::string::format("{\"%s\":\"1.1\"", AwsAttributionAttributeKeyVersion)) != AZStd::string::npos); + AZStd::string bodyString{ std::istreambuf_iterator(*bodyContent), eos }; + AZ_Printf("AWSAttributionServiceApiTest", "%s", bodyString.c_str()); + EXPECT_TRUE(bodyString.contains(AZStd::string::format("{\"%s\":\"1.1\"", AwsAttributionAttributeKeyVersion))); } } diff --git a/Gems/AWSCore/Code/Tests/Editor/Attribution/AWSCoreAttributionManagerTest.cpp b/Gems/AWSCore/Code/Tests/Editor/Attribution/AWSCoreAttributionManagerTest.cpp index e996e0b9c0..b78bfe29c8 100644 --- a/Gems/AWSCore/Code/Tests/Editor/Attribution/AWSCoreAttributionManagerTest.cpp +++ b/Gems/AWSCore/Code/Tests/Editor/Attribution/AWSCoreAttributionManagerTest.cpp @@ -10,7 +10,6 @@ #include #include -#include #include #include #include @@ -23,7 +22,6 @@ #include #include #include -#include #include #include #include @@ -167,7 +165,6 @@ namespace AWSAttributionUnitTest AZStd::unique_ptr m_jobManager; AZStd::array m_resolvedSettingsPath; ModuleManagerRequestBusMock m_moduleManagerRequestBusMock; - AWSCredentialRquestsBusMock m_credentialRequestBusMock; void SetUp() override { @@ -221,6 +218,7 @@ namespace AWSAttributionUnitTest TEST_F(AttributionManagerTest, MetricsSettings_ConsentShown_AttributionDisabled_SkipsSend) { // GIVEN + AWSCredentialRquestsBusMock credentialRequestBusMock; AWSAttributionManagerMock manager; CreateFile(m_resolvedSettingsPath.data(), R"({ @@ -239,7 +237,7 @@ namespace AWSAttributionUnitTest EXPECT_CALL(manager, SubmitMetric(testing::_)).Times(0); EXPECT_CALL(m_moduleManagerRequestBusMock, EnumerateModules(testing::_)).Times(0); - EXPECT_CALL(m_credentialRequestBusMock, GetCredentialsProvider()).Times(1); + EXPECT_CALL(credentialRequestBusMock, GetCredentialsProvider()).Times(1); // WHEN manager.MetricCheck(); @@ -255,6 +253,7 @@ namespace AWSAttributionUnitTest TEST_F(AttributionManagerTest, AttributionEnabled_ContentShown_NoPreviousTimeStamp_SendSuccess) { // GIVEN + AWSCredentialRquestsBusMock credentialRequestBusMock; AWSAttributionManagerMock manager; CreateFile(m_resolvedSettingsPath.data(), R"({ @@ -272,7 +271,7 @@ namespace AWSAttributionUnitTest EXPECT_CALL(manager, SubmitMetric(testing::_)).Times(1); EXPECT_CALL(m_moduleManagerRequestBusMock, EnumerateModules(testing::_)).Times(1); - EXPECT_CALL(m_credentialRequestBusMock, GetCredentialsProvider()).Times(1); + EXPECT_CALL(credentialRequestBusMock, GetCredentialsProvider()).Times(1); // WHEN manager.MetricCheck(); @@ -289,6 +288,7 @@ namespace AWSAttributionUnitTest TEST_F(AttributionManagerTest, AttributionEnabled_ContentShown_ValidPreviousTimeStamp_SendSuccess) { // GIVEN + AWSCredentialRquestsBusMock credentialRequestBusMock; AWSAttributionManagerMock manager; CreateFile(m_resolvedSettingsPath.data(), R"({ @@ -308,7 +308,7 @@ namespace AWSAttributionUnitTest EXPECT_CALL(manager, SubmitMetric(testing::_)).Times(1); EXPECT_CALL(m_moduleManagerRequestBusMock, EnumerateModules(testing::_)).Times(1); - EXPECT_CALL(m_credentialRequestBusMock, GetCredentialsProvider()).Times(1); + EXPECT_CALL(credentialRequestBusMock, GetCredentialsProvider()).Times(1); // WHEN manager.MetricCheck(); @@ -324,6 +324,7 @@ namespace AWSAttributionUnitTest TEST_F(AttributionManagerTest, AttributionEnabled_ContentShown_DelayNotSatisfied_SendFail) { // GIVEN + AWSCredentialRquestsBusMock credentialRequestBusMock; AWSAttributionManagerMock manager; CreateFile(m_resolvedSettingsPath.data(), R"({ @@ -346,7 +347,7 @@ namespace AWSAttributionUnitTest EXPECT_CALL(manager, SubmitMetric(testing::_)).Times(0); EXPECT_CALL(m_moduleManagerRequestBusMock, EnumerateModules(testing::_)).Times(0); - EXPECT_CALL(m_credentialRequestBusMock, GetCredentialsProvider()).Times(1); + EXPECT_CALL(credentialRequestBusMock, GetCredentialsProvider()).Times(1); // WHEN manager.MetricCheck(); @@ -362,6 +363,7 @@ namespace AWSAttributionUnitTest TEST_F(AttributionManagerTest, AttributionEnabledNotFound_ContentShown_SendFail) { // GIVEN + AWSCredentialRquestsBusMock credentialRequestBusMock; AWSAttributionManagerMock manager; CreateFile(m_resolvedSettingsPath.data(), R"({ @@ -378,7 +380,7 @@ namespace AWSAttributionUnitTest EXPECT_CALL(manager, SubmitMetric(testing::_)).Times(0); EXPECT_CALL(m_moduleManagerRequestBusMock, EnumerateModules(testing::_)).Times(0); - EXPECT_CALL(m_credentialRequestBusMock, GetCredentialsProvider()).Times(1); + EXPECT_CALL(credentialRequestBusMock, GetCredentialsProvider()).Times(1); // WHEN manager.MetricCheck(); @@ -394,12 +396,13 @@ namespace AWSAttributionUnitTest TEST_F(AttributionManagerTest, AttributionEnabledNotFound_ContentNotShown_SendFail) { // GIVEN + AWSCredentialRquestsBusMock credentialRequestBusMock; AWSAttributionManagerMock manager; manager.Init(); EXPECT_CALL(manager, SubmitMetric(testing::_)).Times(0); EXPECT_CALL(m_moduleManagerRequestBusMock, EnumerateModules(testing::_)).Times(0); - EXPECT_CALL(m_credentialRequestBusMock, GetCredentialsProvider()).Times(1); + EXPECT_CALL(credentialRequestBusMock, GetCredentialsProvider()).Times(1); EXPECT_CALL(manager, ShowConsentDialog()).Times(1); // WHEN diff --git a/Gems/AWSCore/Code/Tests/Framework/AWSApiClientJobConfigTest.cpp b/Gems/AWSCore/Code/Tests/Framework/AWSApiClientJobConfigTest.cpp index db433062ad..0eca8a37ed 100644 --- a/Gems/AWSCore/Code/Tests/Framework/AWSApiClientJobConfigTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/AWSApiClientJobConfigTest.cpp @@ -6,9 +6,6 @@ * */ -#include - -#include #include #include @@ -19,7 +16,7 @@ using namespace AWSCore; class AWSApiClientJobConfigTest - : public UnitTest::ScopedAllocatorSetupFixture + : public AWSCoreFixture , public AWSCredentialRequestBus::Handler { public: @@ -30,13 +27,9 @@ public: void SetUp() override { - AWSNativeSDKInit::InitializationManager::InitAwsApi(); - m_credentialHandlerCounter = 0; - } + AWSCoreFixture::SetUpFixture(); - void TearDown() override - { - AWSNativeSDKInit::InitializationManager::Shutdown(); + m_credentialHandlerCounter = 0; } // AWSCredentialRequestBus interface implementation diff --git a/Gems/AWSCore/Code/Tests/Framework/AWSApiJobConfigTest.cpp b/Gems/AWSCore/Code/Tests/Framework/AWSApiJobConfigTest.cpp index 6976856b60..8caf0ac013 100644 --- a/Gems/AWSCore/Code/Tests/Framework/AWSApiJobConfigTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/AWSApiJobConfigTest.cpp @@ -8,7 +8,6 @@ #include #include -#include #include @@ -20,14 +19,14 @@ using namespace AWSCore; class AwsApiJobConfigTest - : public UnitTest::ScopedAllocatorSetupFixture + : public AWSCoreFixture , AWSCredentialRequestBus::Handler , AWSCoreRequestBus::Handler { public: void SetUp() override { - AZ::AllocatorInstance::Create(); + AWSCoreFixture::SetUpFixture(); m_credentialsHandler = std::make_shared(); AZ::JobManagerDesc jobDesc; @@ -45,7 +44,7 @@ public: m_jobManager.reset(); m_credentialsHandler.reset(); - AZ::AllocatorInstance::Destroy(); + AWSCoreFixture::TearDownFixture(); } // AWSCredentialRequestBus interface implementation diff --git a/Gems/AWSCore/Code/Tests/Framework/HttpRequestJobTest.cpp b/Gems/AWSCore/Code/Tests/Framework/HttpRequestJobTest.cpp index e04cdcb2d9..cee5ec0624 100644 --- a/Gems/AWSCore/Code/Tests/Framework/HttpRequestJobTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/HttpRequestJobTest.cpp @@ -6,24 +6,24 @@ * */ -#include - #include #include using namespace AWSCore; class HttpRequestJobTest - : public UnitTest::ScopedAllocatorSetupFixture + : public AWSCoreFixture { void SetUp() override { + AWSCoreFixture::SetUpFixture(); HttpRequestJob::StaticInit(); } void TearDown() override { HttpRequestJob::StaticShutdown(); + AWSCoreFixture::TearDownFixture(); } }; diff --git a/Gems/AWSCore/Code/Tests/Framework/JsonObjectHandlerTest.cpp b/Gems/AWSCore/Code/Tests/Framework/JsonObjectHandlerTest.cpp index f7b1546561..49e77be35f 100644 --- a/Gems/AWSCore/Code/Tests/Framework/JsonObjectHandlerTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/JsonObjectHandlerTest.cpp @@ -6,8 +6,6 @@ * */ -#include - #include #include @@ -18,7 +16,7 @@ using OBJECT_TYPE = TestObject; using ARRAY_TYPE = AZStd::vector; using ARRAY_OF_ARRAY_TYPE = AZStd::vector>; using ARRAY_OF_OBJECT_TYPE = AZStd::vector>; -using JsonReaderTest = UnitTest::ScopedAllocatorSetupFixture; +using JsonReaderTest = AWSCoreFixture; template void TestJsonReaderSuccess(const ValueType& expectedValue, const char* valueString) diff --git a/Gems/AWSCore/Code/Tests/Framework/JsonWriterTest.cpp b/Gems/AWSCore/Code/Tests/Framework/JsonWriterTest.cpp index 12ada1188c..9a08e6f111 100644 --- a/Gems/AWSCore/Code/Tests/Framework/JsonWriterTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/JsonWriterTest.cpp @@ -6,8 +6,6 @@ * */ -#include - #include #include @@ -17,7 +15,7 @@ using namespace AWSCoreTestingUtils; using OBJECT_TYPE = TestObject; using ARRAY_TYPE = AZStd::vector; -using JsonWriterTest = UnitTest::ScopedAllocatorSetupFixture; +using JsonWriterTest = AWSCoreFixture; template void TestJsonWriterSuccess(const ValueType& actualValue, const char* valueString) diff --git a/Gems/AWSCore/Code/Tests/Framework/RequestBuilderTest.cpp b/Gems/AWSCore/Code/Tests/Framework/RequestBuilderTest.cpp index 0c08868100..35ce262f30 100644 --- a/Gems/AWSCore/Code/Tests/Framework/RequestBuilderTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/RequestBuilderTest.cpp @@ -6,15 +6,13 @@ * */ -#include - #include #include using namespace AWSCore; using namespace AWSCoreTestingUtils; -using RequestBuilderTest = UnitTest::ScopedAllocatorSetupFixture; +using RequestBuilderTest = AWSCoreFixture; TEST_F(RequestBuilderTest, WriteJsonBodyParameter_UseTestJsonBody_GetExpectedValue) { diff --git a/Gems/AWSCore/Code/Tests/Framework/ServiceClientJobConfigTest.cpp b/Gems/AWSCore/Code/Tests/Framework/ServiceClientJobConfigTest.cpp index 9bc43482cd..3907b097db 100644 --- a/Gems/AWSCore/Code/Tests/Framework/ServiceClientJobConfigTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/ServiceClientJobConfigTest.cpp @@ -6,8 +6,6 @@ * */ -#include - #include #include #include @@ -19,17 +17,21 @@ static constexpr const char TEST_EXPECTED_FEATURE_SERVICE_URL[] = "https://featu static constexpr const char TEST_EXPECTED_CUSTOM_SERVICE_URL[] = "https://custom.service.com"; class ServiceClientJobConfigTest - : public UnitTest::ScopedAllocatorSetupFixture + : public AWSCoreFixture , AWSResourceMappingRequestBus::Handler { void SetUp() override { + AWSCoreFixture::SetUpFixture(); + AWSResourceMappingRequestBus::Handler::BusConnect(); } void TearDown() override { AWSResourceMappingRequestBus::Handler::BusDisconnect(); + + AWSCoreFixture::TearDownFixture(); } // AWSResourceMappingRequestBus interface implementation diff --git a/Gems/AWSCore/Code/Tests/Framework/ServiceJobUtilTest.cpp b/Gems/AWSCore/Code/Tests/Framework/ServiceJobUtilTest.cpp index 230fd304d2..c162a0fa13 100644 --- a/Gems/AWSCore/Code/Tests/Framework/ServiceJobUtilTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/ServiceJobUtilTest.cpp @@ -6,12 +6,10 @@ * */ -#include - #include #include -using ServiceJobUtilTest = UnitTest::ScopedAllocatorSetupFixture; +using ServiceJobUtilTest = AWSCoreFixture; TEST_F(ServiceJobUtilTest, DetermineRegionFromRequestUrl_DefaultUrlFormat_Success) { diff --git a/Gems/AWSCore/Code/Tests/Framework/ServiceRequestJobTest.cpp b/Gems/AWSCore/Code/Tests/Framework/ServiceRequestJobTest.cpp index bf4f6dd4fd..23fa78cc23 100644 --- a/Gems/AWSCore/Code/Tests/Framework/ServiceRequestJobTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/ServiceRequestJobTest.cpp @@ -6,15 +6,13 @@ * */ -#include - #include #include #include using namespace AWSCore; -using ServiceRequestJobTest = UnitTest::ScopedAllocatorSetupFixture; +using ServiceRequestJobTest = AWSCoreFixture; #define TEST_SERVICE_REQUEST(SERVICE_NAME, METHOD, PATH) \ static const char* Path() { return PATH; } \ diff --git a/Gems/AWSCore/Code/Tests/Framework/UtilTest.cpp b/Gems/AWSCore/Code/Tests/Framework/UtilTest.cpp index 5a1589c073..a0320a894c 100644 --- a/Gems/AWSCore/Code/Tests/Framework/UtilTest.cpp +++ b/Gems/AWSCore/Code/Tests/Framework/UtilTest.cpp @@ -6,14 +6,12 @@ * */ -#include - #include #include using namespace AWSCoreTestingUtils; -using FrameworkUtilTest = UnitTest::ScopedAllocatorSetupFixture; +using FrameworkUtilTest = AWSCoreFixture; TEST_F(FrameworkUtilTest, ToAwsString_UseAzString_GetExpectedAwsString) { diff --git a/Gems/AWSCore/Code/Tests/ResourceMapping/AWSResourceMappingManagerTest.cpp b/Gems/AWSCore/Code/Tests/ResourceMapping/AWSResourceMappingManagerTest.cpp index fd37e6e228..6c798dbeca 100644 --- a/Gems/AWSCore/Code/Tests/ResourceMapping/AWSResourceMappingManagerTest.cpp +++ b/Gems/AWSCore/Code/Tests/ResourceMapping/AWSResourceMappingManagerTest.cpp @@ -8,7 +8,6 @@ #include #include -#include #include #include @@ -112,31 +111,21 @@ public: m_resourceMappingManager = AZStd::make_unique(); } - void CreateTestConfigFile(const AZStd::string& configContent) - { - m_normalizedConfigFilePath = AZStd::string::format("%s/%s", m_normalizedConfigFolderPath.c_str(), "test_aws_resource_mappings.json"); - AzFramework::StringFunc::Path::Normalize(m_normalizedConfigFilePath); - CreateTestFile(m_normalizedConfigFilePath, configContent); - } - void SetUp() override { AWSCoreFixture::SetUpFixture(false); - m_normalizedSourceProjectFolder = AZStd::string::format("%s/%s%s/", AZ::Test::GetCurrentExecutablePath().c_str(), - "AWSResourceMappingManager", AZ::Uuid::CreateRandom().ToString(false, false).c_str()); - AzFramework::StringFunc::Path::Normalize(m_normalizedSourceProjectFolder); - m_normalizedConfigFolderPath = AZStd::string::format("%s/%s/", - m_normalizedSourceProjectFolder.c_str(), AWSCore::AWSCoreConfiguration::AWSCoreResourceMappingConfigFolderName); - AzFramework::StringFunc::Path::Normalize(m_normalizedConfigFolderPath); + m_configFilePath = (GetTestTempDirectoryPath() / + AWSCore::AWSCoreConfiguration::AWSCoreResourceMappingConfigFolderName / + "test_aws_resource_mappings.json").LexicallyNormal(); AWSCoreInternalRequestBus::Handler::BusConnect(); } void TearDown() override { AWSCoreInternalRequestBus::Handler::BusDisconnect(); - RemoveTestFile(); - RemoveTestDirectory(); + RemoveFile(m_configFilePath.Native()); + m_configFilePath.clear(); m_reloadConfigurationCounter = 0; m_resourceMappingManager->DeactivateManager(); @@ -147,57 +136,17 @@ public: // AWSCoreInternalRequestBus interface implementation AZStd::string GetProfileName() const override { return ""; } - AZStd::string GetResourceMappingConfigFilePath() const override { return m_normalizedConfigFilePath; } + AZStd::string GetResourceMappingConfigFilePath() const override { return m_configFilePath.Native(); } void ReloadConfiguration() override { m_reloadConfigurationCounter++; } AZStd::unique_ptr m_resourceMappingManager; AZ::u8 m_reloadConfigurationCounter; - -private: - AZStd::string m_normalizedSourceProjectFolder; - AZStd::string m_normalizedConfigFolderPath; - AZStd::string m_normalizedConfigFilePath; - - void CreateTestFile(const AZStd::string& filePath, const AZStd::string& fileContent) - { - AZ::IO::SystemFile file; - if (!file.Open(filePath.c_str(), - AZ::IO::SystemFile::OpenMode::SF_OPEN_CREATE | AZ::IO::SystemFile::SF_OPEN_CREATE_PATH | AZ::IO::SystemFile::SF_OPEN_WRITE_ONLY)) - { - AZ_Assert(false, "Failed to open test file"); - } - - if (file.Write(fileContent.c_str(), fileContent.size()) != fileContent.size()) - { - AZ_Assert(false, "Failed to write test file"); - } - file.Close(); - } - - void RemoveTestFile() - { - if (!m_normalizedConfigFilePath.empty()) - { - AZ_Assert(AZ::IO::SystemFile::Delete(m_normalizedConfigFilePath.c_str()), - "Failed to delete test config file at %s", m_normalizedConfigFilePath.c_str()); - } - } - - void RemoveTestDirectory() - { - if (!m_normalizedConfigFilePath.empty()) - { - AZ_Assert(AZ::IO::SystemFile::DeleteDir(m_normalizedConfigFolderPath.c_str()), - "Failed to delete test config folder at %s", m_normalizedConfigFolderPath.c_str()); - AZ_Assert(AZ::IO::SystemFile::DeleteDir(m_normalizedSourceProjectFolder.c_str()), - "Failed to delete test folder at %s", m_normalizedSourceProjectFolder.c_str()); - } - } + AZ::IO::Path m_configFilePath; }; TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseInvalidConfigFile_ConfigDataIsEmpty) { - CreateTestConfigFile(TEST_INVALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_INVALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -212,7 +161,7 @@ TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseInvalidConfigFile_Con TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseValidConfigFile_ConfigDataIsNotEmpty) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -227,7 +176,7 @@ TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseValidConfigFile_Confi TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseTemplateConfigFile_ConfigDataIsNotEmpty) { - CreateTestConfigFile(TEST_TEMPLATE_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_TEMPLATE_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -242,7 +191,7 @@ TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseTemplateConfigFile_Co TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseValidConfigFile_ConfigDataIsNotEmptyWithMultithreadCalls) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); constexpr int testThreadNumber = 10; @@ -267,7 +216,7 @@ TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseValidConfigFile_Confi TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseValidConfigFile_GlobalAccountIdEmpty) { - CreateTestConfigFile(TEST_VALID_EMPTY_ACCOUNTID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_EMPTY_ACCOUNTID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -282,7 +231,7 @@ TEST_F(AWSResourceMappingManagerTest, ActivateManager_ParseValidConfigFile_Globa TEST_F(AWSResourceMappingManagerTest, DeactivateManager_AfterActivatingWithValidConfigFile_ConfigDataGetCleanedUp) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -302,7 +251,7 @@ TEST_F(AWSResourceMappingManagerTest, DeactivateManager_AfterActivatingWithValid TEST_F(AWSResourceMappingManagerTest, GetDefaultAccountId_AfterParsingValidConfigFile_GetExpectedDefaultAccountId) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -313,7 +262,7 @@ TEST_F(AWSResourceMappingManagerTest, GetDefaultAccountId_AfterParsingValidConfi TEST_F(AWSResourceMappingManagerTest, GetDefaultRegion_AfterParsingValidConfigFile_GetExpectedDefaultRegion) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualRegion; @@ -324,7 +273,7 @@ TEST_F(AWSResourceMappingManagerTest, GetDefaultRegion_AfterParsingValidConfigFi TEST_F(AWSResourceMappingManagerTest, GetResourceAccountId_AfterParsingValidConfigFile_GetExpectedAccountId) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -341,7 +290,7 @@ TEST_F(AWSResourceMappingManagerTest, GetResourceAccountId_AfterParsingValidConf TEST_F(AWSResourceMappingManagerTest, GetResourceAccountId_QueryNonexistResourceMappingKeyName_GetEmptyAccountId) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -352,7 +301,7 @@ TEST_F(AWSResourceMappingManagerTest, GetResourceAccountId_QueryNonexistResource TEST_F(AWSResourceMappingManagerTest, GetResourceNameId_AfterParsingValidConfigFile_GetExpectedNameId) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualNameId; @@ -369,7 +318,7 @@ TEST_F(AWSResourceMappingManagerTest, GetResourceNameId_AfterParsingValidConfigF TEST_F(AWSResourceMappingManagerTest, GetResourceNameId_QueryNonexistResourceMappingKeyName_GetEmptyNameId) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualNameId; @@ -380,7 +329,7 @@ TEST_F(AWSResourceMappingManagerTest, GetResourceNameId_QueryNonexistResourceMap TEST_F(AWSResourceMappingManagerTest, GetResourceRegion_AfterParsingValidConfigFile_GetExpectedRegion) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualRegion; @@ -397,7 +346,7 @@ TEST_F(AWSResourceMappingManagerTest, GetResourceRegion_AfterParsingValidConfigF TEST_F(AWSResourceMappingManagerTest, GetResourceRegion_QueryNonexistResourceMappingKeyName_GetEmptyRegion) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualRegion; @@ -408,7 +357,7 @@ TEST_F(AWSResourceMappingManagerTest, GetResourceRegion_QueryNonexistResourceMap TEST_F(AWSResourceMappingManagerTest, GetResourceType_AfterParsingValidConfigFile_GetExpectedType) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualType; @@ -425,7 +374,7 @@ TEST_F(AWSResourceMappingManagerTest, GetResourceType_AfterParsingValidConfigFil TEST_F(AWSResourceMappingManagerTest, GetResourceType_QueryNonexistResourceMappingKeyName_GetEmptyType) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualType; @@ -436,7 +385,7 @@ TEST_F(AWSResourceMappingManagerTest, GetResourceType_QueryNonexistResourceMappi TEST_F(AWSResourceMappingManagerTest, GetServiceUrl_PassingEmptyServiceName_GetEmptyUrl) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualServiceUrl; @@ -447,7 +396,7 @@ TEST_F(AWSResourceMappingManagerTest, GetServiceUrl_PassingEmptyServiceName_GetE TEST_F(AWSResourceMappingManagerTest, GetServiceUrl_PassingEmptyRESTApiIdAndStage_GetEmptyUrl) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualServiceUrl; @@ -458,7 +407,7 @@ TEST_F(AWSResourceMappingManagerTest, GetServiceUrl_PassingEmptyRESTApiIdAndStag TEST_F(AWSResourceMappingManagerTest, GetServiceUrl_RESTApiIdAndStageHaveInconsistentRegion_GetEmptyUrl) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualServiceUrl; @@ -469,7 +418,7 @@ TEST_F(AWSResourceMappingManagerTest, GetServiceUrl_RESTApiIdAndStageHaveInconsi TEST_F(AWSResourceMappingManagerTest, ReloadConfigFile_ParseValidConfigFileAfterParsingInvalid_ConfigDataGetParsed) { - CreateTestConfigFile(TEST_INVALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_INVALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ActivateManager(); AZStd::string actualAccountId; @@ -481,7 +430,7 @@ TEST_F(AWSResourceMappingManagerTest, ReloadConfigFile_ParseValidConfigFileAfter EXPECT_TRUE(actualRegion.empty()); EXPECT_TRUE(m_resourceMappingManager->GetStatus() == AWSResourceMappingManager::Status::Error); - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ReloadConfigFile(); AWSResourceMappingRequestBus::BroadcastResult(actualAccountId, &AWSResourceMappingRequests::GetDefaultAccountId); @@ -494,7 +443,7 @@ TEST_F(AWSResourceMappingManagerTest, ReloadConfigFile_ParseValidConfigFileAfter TEST_F(AWSResourceMappingManagerTest, ReloadConfigFile_ReloadConfigFileNameAndParseValidConfigFile_ConfigDataGetParsed) { - CreateTestConfigFile(TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); + CreateFile(m_configFilePath.Native(), TEST_VALID_RESOURCE_MAPPING_CONFIG_FILE); m_resourceMappingManager->ReloadConfigFile(true); EXPECT_EQ(m_reloadConfigurationCounter, 1); @@ -505,6 +454,7 @@ TEST_F(AWSResourceMappingManagerTest, ReloadConfigFile_ReloadConfigFileNameAndPa TEST_F(AWSResourceMappingManagerTest, ReloadConfigFile_MissingSetRegFile_ConfigDataIsNotParsed) { + m_configFilePath.clear(); m_resourceMappingManager->ReloadConfigFile(true); EXPECT_EQ(m_reloadConfigurationCounter, 1); diff --git a/Gems/AWSCore/Code/Tests/ResourceMapping/AWSResourceMappingUtilsTest.cpp b/Gems/AWSCore/Code/Tests/ResourceMapping/AWSResourceMappingUtilsTest.cpp index f1a90aa2ae..f5215f89c2 100644 --- a/Gems/AWSCore/Code/Tests/ResourceMapping/AWSResourceMappingUtilsTest.cpp +++ b/Gems/AWSCore/Code/Tests/ResourceMapping/AWSResourceMappingUtilsTest.cpp @@ -6,8 +6,6 @@ * */ -#include - #include #include @@ -18,7 +16,7 @@ static constexpr const char TEST_VALID_RESTAPI_REGION[] = "us-west-2"; static constexpr const char TEST_VALID_RESTAPI_CHINA_REGION[] = "cn-north-1"; static constexpr const char TEST_VALID_RESTAPI_STAGE[] = "prod"; -using AWSResourceMappingUtilsTest = UnitTest::ScopedAllocatorSetupFixture; +using AWSResourceMappingUtilsTest = AWSCoreFixture; TEST_F(AWSResourceMappingUtilsTest, FormatRESTApiUrl_PassingValidArguments_ReturnExpectedResult) { diff --git a/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorDynamoDBTest.cpp b/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorDynamoDBTest.cpp index e42e270bc2..bd66ccb309 100644 --- a/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorDynamoDBTest.cpp +++ b/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorDynamoDBTest.cpp @@ -7,7 +7,6 @@ */ #include -#include #include #include @@ -32,7 +31,7 @@ public: MOCK_METHOD1(OnGetItemError, void(const AZStd::string&)); }; -using AWSScriptBehaviorDynamoDBTest = UnitTest::ScopedAllocatorSetupFixture; +using AWSScriptBehaviorDynamoDBTest = AWSCoreFixture; TEST_F(AWSScriptBehaviorDynamoDBTest, GetItemRaw_CallWithEmptyTableName_InvokeOnError) { diff --git a/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorLambdaTest.cpp b/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorLambdaTest.cpp index 42ccd6eddc..0b2dc8e30c 100644 --- a/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorLambdaTest.cpp +++ b/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorLambdaTest.cpp @@ -7,14 +7,14 @@ */ #include -#include #include #include using namespace AWSCore; -class AWSScriptBehaviorLambdaNotificationBusHandlerMock : public AWSScriptBehaviorLambdaNotificationBusHandler +class AWSScriptBehaviorLambdaNotificationBusHandlerMock + : public AWSScriptBehaviorLambdaNotificationBusHandler { public: AWSScriptBehaviorLambdaNotificationBusHandlerMock() @@ -31,7 +31,7 @@ public: MOCK_METHOD1(OnInvokeError, void(const AZStd::string&)); }; -using AWSScriptBehaviorLambdaTest = UnitTest::ScopedAllocatorSetupFixture; +using AWSScriptBehaviorLambdaTest = AWSCoreFixture; TEST_F(AWSScriptBehaviorLambdaTest, InvokeRaw_CallWithEmptyFunctionName_InvokeOnError) { diff --git a/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorS3Test.cpp b/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorS3Test.cpp index 34a0166e32..da754a0de6 100644 --- a/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorS3Test.cpp +++ b/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorS3Test.cpp @@ -145,17 +145,18 @@ TEST_F(AWSScriptBehaviorS3Test, GetObjectRaw_CallWithOutfileDirectoryNoExist_Inv AWSScriptBehaviorS3::GetObjectRaw("dummyBucket", "dummyObject", "dummyRegion", dummyDirectory); } +#if defined(AZ_DEBUG_BUILD) || defined(AZ_PROFILE_BUILD) +// The preparation step for this test case does not work in release mode TEST_F(AWSScriptBehaviorS3Test, GetObjectRaw_CallWithOutfileIsReadOnly_InvokeOnError) { AWSScriptBehaviorS3NotificationBusHandlerMock s3HandlerMock; EXPECT_CALL(s3HandlerMock, OnGetObjectError(::testing::_)).Times(1); - AZStd::string randomTestFile = AZStd::string::format("%s/test%s.txt", - AZ::Test::GetCurrentExecutablePath().c_str(), AZ::Uuid::CreateRandom().ToString(false, false).c_str()); - AzFramework::StringFunc::Path::Normalize(randomTestFile); - CreateReadOnlyTestFile(randomTestFile); - AWSScriptBehaviorS3::GetObjectRaw("dummyBucket", "dummyObject", "dummyRegion", randomTestFile); - RemoveReadOnlyTestFile(randomTestFile); + AZ::IO::Path randomTestFilePath = (GetTestTempDirectoryPath() / "random_test.txt").LexicallyNormal(); + CreateReadOnlyTestFile(randomTestFilePath.Native()); + AWSScriptBehaviorS3::GetObjectRaw("dummyBucket", "dummyObject", "dummyRegion", randomTestFilePath.Native()); + RemoveReadOnlyTestFile(randomTestFilePath.Native()); } +#endif TEST_F(AWSScriptBehaviorS3Test, GetObject_NoBucketNameInResourceMappingFound_InvokeOnError) { diff --git a/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorsComponentTest.cpp b/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorsComponentTest.cpp index caba8b5ae7..387aa932f6 100644 --- a/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorsComponentTest.cpp +++ b/Gems/AWSCore/Code/Tests/ScriptCanvas/AWSScriptBehaviorsComponentTest.cpp @@ -9,7 +9,6 @@ #include #include #include -#include #include #include @@ -17,11 +16,12 @@ using namespace AWSCore; class AWSScriptBehaviorsComponentTest - : public UnitTest::ScopedAllocatorSetupFixture + : public AWSCoreFixture { public: void SetUp() override { + AWSCoreFixture::SetUpFixture(); m_serializeContext = AZStd::make_unique(); m_serializeContext->CreateEditContext(); m_behaviorContext = AZStd::make_unique(); @@ -39,6 +39,7 @@ public: m_componentDescriptor.reset(); m_behaviorContext.reset(); m_serializeContext.reset(); + AWSCoreFixture::TearDownFixture(); } protected: diff --git a/Gems/AWSCore/Code/Tests/TestFramework/AWSCoreFixture.h b/Gems/AWSCore/Code/Tests/TestFramework/AWSCoreFixture.h index 65e609b490..6ea5593d0e 100644 --- a/Gems/AWSCore/Code/Tests/TestFramework/AWSCoreFixture.h +++ b/Gems/AWSCore/Code/Tests/TestFramework/AWSCoreFixture.h @@ -17,6 +17,8 @@ #include #include +#include + namespace AWSCoreTestingUtils { static const AZStd::string STRING_VALUE{"s"}; @@ -135,6 +137,8 @@ public: { m_app = AZStd::make_unique(); } + + AWSNativeSDKInit::InitializationManager::InitAwsApi(); } void TearDown() override @@ -144,6 +148,8 @@ public: void TearDownFixture(bool mockSettingsRegistry = true) { + AWSNativeSDKInit::InitializationManager::Shutdown(); + if (mockSettingsRegistry) { AZ::SettingsRegistry::Unregister(m_settingsRegistry.get()); @@ -171,7 +177,7 @@ public: bool CreateFile(const AZStd::string& filePath, const AZStd::string& content) { AZ::IO::HandleType fileHandle; - if (!m_localFileIO->Open(filePath.c_str(), AZ::IO::OpenMode::ModeWrite | AZ::IO::OpenMode::ModeText, fileHandle)) + if (!m_localFileIO->Open(filePath.c_str(), AZ::IO::OpenMode::ModeCreatePath | AZ::IO::OpenMode::ModeWrite | AZ::IO::OpenMode::ModeText, fileHandle)) { return false; } @@ -197,6 +203,13 @@ private: AZ::IO::FileIOBase* m_otherFileIO = nullptr; protected: + AZ::IO::Path GetTestTempDirectoryPath() + { + AZ::IO::Path testTempDirPath{ m_testTempDirectory.GetDirectory() }; + return testTempDirPath; + } + + AZ::Test::ScopedAutoTempDirectory m_testTempDirectory; AZStd::unique_ptr m_settingsRegistry; AZStd::unique_ptr m_app; }; diff --git a/Gems/AWSCore/Code/Tools/ResourceMappingTool/README.md b/Gems/AWSCore/Code/Tools/ResourceMappingTool/README.md index ba764dc993..33152fb2ee 100644 --- a/Gems/AWSCore/Code/Tools/ResourceMappingTool/README.md +++ b/Gems/AWSCore/Code/Tools/ResourceMappingTool/README.md @@ -1,35 +1,40 @@ # Welcome to the AWS Core Resource Mapping Tool project! -## Setup aws config and credential -Resource mapping tool is using boto3 to interact with aws services: +## Setup aws config and credentials +The Resource Mapping Tool uses boto3 to interact with aws services: * Read boto3 [Configuration](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/configuration.html) to setup default aws region. * Read boto3 [Credentials](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html) to setup default profile or credential keys. -Or follow **AWS CLI** configuration which can be reused by boto3 lib: +Or follow **AWS CLI** configuration directions which can be reused by the boto3 lib: * Follow [Quick configuration with aws configure](https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-quickstart.html#cli-configure-quickstart-config) ## Python Environment Setup Options -### 1. Engine python environment (Including Editor) -1. In order to use engine python environment, it requires to link Qt binaries for this tool. +### 1. Use Engine python environment (Including Editor) +1. In order to use the Open 3D Engine's python environment, this tool requires linking the Qt binaries. Follow cmake instructions to configure your project, for example: ``` $ cmake -B -S . -G "Visual Studio 16 2019" -DLY_PROJECTS= ``` -2. At this point, double check engine python environment gets setup under */python/runtime* directory +2. At this point, double check that the Open 3D Engine's python environment gets set up under */python/runtime* directory -3. Build project with **AWSCore.Editor** (or **AWSCore.ResourceMappintTool**, or **Editor**) target to generate required Qt binaries. +3. Build the project with the **AWSCore.Editor** (or **AWSCore.ResourceMappingTool**, or **Editor**) target to generate the required Qt binaries. + * Windows + ``` + $ cmake --build --target AWSCore.Editor --config /m + ``` + * Linux ``` $ cmake --build --target AWSCore.Editor --config -j ``` -4. At this point, double check Qt binaries gets generated under */bin//AWSCoreEditorQtBin* directory +4. At this point, double check the Qt binaries have been generated under */bin//AWSCoreEditorQtBin* directory -5. Launch resource mapping tool under engine root folder: +5. Launch the Resource Mapping Tool from the engine root folder: * Windows * release mode ``` @@ -49,10 +54,9 @@ Follow cmake instructions to configure your project, for example: $ python/python.sh Gems/AWSCore/Code/Tools/ResourceMappingTool/resource_mapping_tool.py --binaries_path /bin/debug/AWSCoreEditorQtBin ``` -* Note - Editor is integrated with the same engine python environment to launch Resource Mapping Tool. If it is failed to launch the tool -in Editor, please follow above steps to make sure expected scripts/binaries are present. +* Note - the engine Editor is integrated with the same python environment used to launch the Resource Mapping Tool. If the tool fails to launch from the Editor, please double check that you have completed all of the above steps and that the expected scripts and binaries are present in the expected directories. -### 2. Python virtual environment +### 2. Use a separate python virtual environment This project is set up like a standard Python project. The initialization process also creates a virtualenv within this project, stored under the `.env` directory. To create the virtualenv it assumes that there is a `python3` @@ -105,7 +109,23 @@ you can create the virtualenv manually. * `--config-path` **[Optional]** Path to resource mapping config directory, if not provided tool will use current directory. * `--debug` **[Optional]** Execute on debug mode to enable DEBUG logging level. -* `--log-path` **[Optional]** Path to resource mapping tool logging directory, +* `--log-path` **[Optional]** Path to Resource Mapping Tool logging directory, if not provided tool will store logging under tool source code directory. * `--profile` **[Optional]** Named AWS profile to use for querying AWS resources, - if not provided tool will use `default` aws profile. \ No newline at end of file + if not provided tool will use `default` aws profile. + + +## Running tests + +How to run the unit tests for the project: + +1. If not already activated, activate the project's python environment as explained above. +2. Use `pytest` to run one or more tests (command paths formatted as if run from this directory): + * Run all the tests + ``` + python -m pytest -vv . + ``` + * Run a specific test file or directory: + ``` + python -m pytest tests\unit\model\test_basic_resource_attributes.py + ``` \ No newline at end of file diff --git a/Gems/AWSCore/Code/Tools/ResourceMappingTool/requirements.txt b/Gems/AWSCore/Code/Tools/ResourceMappingTool/requirements.txt index 2b931e0b51..ee8e94640a 100644 --- a/Gems/AWSCore/Code/Tools/ResourceMappingTool/requirements.txt +++ b/Gems/AWSCore/Code/Tools/ResourceMappingTool/requirements.txt @@ -1,2 +1,5 @@ PySide2>=5.15.2 boto3>=1.17.30 +pytest>=5.3.2 + + diff --git a/Gems/AWSCore/gem.json b/Gems/AWSCore/gem.json index 3bced07e8d..3bc8e6f77c 100644 --- a/Gems/AWSCore/gem.json +++ b/Gems/AWSCore/gem.json @@ -3,7 +3,8 @@ "display_name": "AWS Core", "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", - "origin": "Amazon Web Services, Inc.", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The AWS Core Gem provides basic shared AWS functionality such as AWS SDK initialization and client configuration, and is automatically added when selecting any AWS feature Gem.", "canonical_tags": [ @@ -15,5 +16,8 @@ "SDK" ], "icon_path": "preview.png", - "documentation_url": "https://o3de.org/docs/user-guide/gems/reference/aws/aws-core/" + "requirements": "", + "documentation_url": "https://o3de.org/docs/user-guide/gems/reference/aws/aws-core/", + "dependencies": [ + ] } diff --git a/Gems/AWSGameLift/gem.json b/Gems/AWSGameLift/gem.json index 1ac65c4526..e1b80cb9fe 100644 --- a/Gems/AWSGameLift/gem.json +++ b/Gems/AWSGameLift/gem.json @@ -3,7 +3,8 @@ "display_name": "AWS GameLift", "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", - "origin": "Amazon Web Services, Inc.", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The AWS GameLift Gem provides a framework to extend O3DE networking layer to work with GameLift resources via GameLift server and client SDK.", "canonical_tags": [ @@ -12,7 +13,7 @@ "user_tags": [ "AWS", "Framework", - "Network", + "Network", "SDK" ], "icon_path": "preview.png", diff --git a/Gems/AWSMetrics/Code/Tests/AWSMetricsServiceApiTest.cpp b/Gems/AWSMetrics/Code/Tests/AWSMetricsServiceApiTest.cpp index 8844e727b6..b7e7527b20 100644 --- a/Gems/AWSMetrics/Code/Tests/AWSMetricsServiceApiTest.cpp +++ b/Gems/AWSMetrics/Code/Tests/AWSMetricsServiceApiTest.cpp @@ -100,11 +100,10 @@ namespace AWSMetrics AWSCore::RequestBuilder requestBuilder{}; EXPECT_TRUE(request.parameters.BuildRequest(requestBuilder)); std::shared_ptr bodyContent = requestBuilder.GetBodyContent(); - EXPECT_TRUE(bodyContent != nullptr); + ASSERT_NE(nullptr, bodyContent); - AZStd::string bodyString; std::istreambuf_iterator eos; - bodyString = AZStd::string{ std::istreambuf_iterator(*bodyContent), eos }; - EXPECT_TRUE(bodyString.find(AZStd::string::format("{\"%s\":[{\"event_timestamp\":", AwsMetricsRequestParameterKeyEvents)) != AZStd::string::npos); + AZStd::string bodyString{ std::istreambuf_iterator(*bodyContent), eos }; + EXPECT_TRUE(bodyString.contains(AZStd::string::format("{\"%s\":[{\"event_timestamp\":", AwsMetricsRequestParameterKeyEvents))); } } diff --git a/Gems/AWSMetrics/gem.json b/Gems/AWSMetrics/gem.json index 054c3624c4..bd462edec3 100644 --- a/Gems/AWSMetrics/gem.json +++ b/Gems/AWSMetrics/gem.json @@ -3,7 +3,8 @@ "display_name": "AWS Metrics", "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", - "origin": "Amazon Web Services, Inc.", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The AWS Metrics Gem provides a solution for AWS metrics submission and analytics.", "canonical_tags": [ @@ -15,6 +16,7 @@ "SDK" ], "icon_path": "preview.png", + "requirements": "", "documentation_url": "https://o3de.org/docs/user-guide/gems/reference/aws/aws-metrics/", "dependencies": [ "AWSCore" diff --git a/Gems/Achievements/CMakeLists.txt b/Gems/Achievements/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Achievements/CMakeLists.txt +++ b/Gems/Achievements/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Achievements/Code/CMakeLists.txt b/Gems/Achievements/Code/CMakeLists.txt index 2d00ac2fb2..5ac43e9736 100644 --- a/Gems/Achievements/Code/CMakeLists.txt +++ b/Gems/Achievements/Code/CMakeLists.txt @@ -6,16 +6,16 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME Achievements.Static STATIC NAMESPACE Gem PLATFORM_INCLUDE_FILES - ${pal_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}.cmake + ${pal_source_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}.cmake FILES_CMAKE achievements_files.cmake - ${pal_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake + ${pal_source_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake INCLUDE_DIRECTORIES PUBLIC Include diff --git a/Gems/Achievements/gem.json b/Gems/Achievements/gem.json index 8180584500..5fc83aefe2 100644 --- a/Gems/Achievements/gem.json +++ b/Gems/Achievements/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Achievements Gem provides a target platform agnostic interface for retrieving achievement details and unlocking achievements.", "canonical_tags": [ diff --git a/Gems/AssetValidation/gem.json b/Gems/AssetValidation/gem.json index 55cdffb9f3..de1d36ffb4 100644 --- a/Gems/AssetValidation/gem.json +++ b/Gems/AssetValidation/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Asset Validation Gem provides seed-related commands to ensure assets have valid seeds for asset bundling.", "canonical_tags": [ diff --git a/Gems/Atom/Asset/CMakeLists.txt b/Gems/Atom/Asset/CMakeLists.txt deleted file mode 100644 index 3ed20148a2..0000000000 --- a/Gems/Atom/Asset/CMakeLists.txt +++ /dev/null @@ -1,10 +0,0 @@ -# -# Copyright (c) Contributors to the Open 3D Engine Project. -# For complete copyright and license terms please see the LICENSE at the root of this distribution. -# -# SPDX-License-Identifier: Apache-2.0 OR MIT -# -# - -add_subdirectory(ImageProcessingAtom) -add_subdirectory(Shader) diff --git a/Gems/Atom/Asset/ImageProcessingAtom/CMakeLists.txt b/Gems/Atom/Asset/ImageProcessingAtom/CMakeLists.txt index 54543a000a..92079d35be 100644 --- a/Gems/Atom/Asset/ImageProcessingAtom/CMakeLists.txt +++ b/Gems/Atom/Asset/ImageProcessingAtom/CMakeLists.txt @@ -7,4 +7,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/Asset/ImageProcessingAtom/Code/CMakeLists.txt b/Gems/Atom/Asset/ImageProcessingAtom/Code/CMakeLists.txt index 982ec43715..74876994f6 100644 --- a/Gems/Atom/Asset/ImageProcessingAtom/Code/CMakeLists.txt +++ b/Gems/Atom/Asset/ImageProcessingAtom/Code/CMakeLists.txt @@ -26,15 +26,15 @@ set(pal_tools_include_dirs) foreach(enabled_platform ${LY_PAL_TOOLS_ENABLED}) string(TOLOWER ${enabled_platform} enabled_platform_lowercase) - ly_get_list_relative_pal_filename(pal_tools_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${enabled_platform}) + o3de_pal_dir(pal_tools_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${enabled_platform} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) list(APPEND pal_tools_include_dirs ${pal_tools_source_dir}) list(APPEND platform_tools_files ${pal_tools_source_dir}/pal_tools_${enabled_platform_lowercase}.cmake) list(APPEND pal_tools_include_files ${pal_tools_source_dir}/pal_tools_${enabled_platform_lowercase}_files.cmake) endforeach() -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) ly_add_target( NAME ImageProcessingAtom.Editor.Static STATIC diff --git a/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/BuilderSettings/TextureSettings.cpp b/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/BuilderSettings/TextureSettings.cpp index 29d9b21775..4772a94ffa 100644 --- a/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/BuilderSettings/TextureSettings.cpp +++ b/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/BuilderSettings/TextureSettings.cpp @@ -226,6 +226,14 @@ namespace ImageProcessingAtom MultiplatformTextureSettings settings; PlatformNameList platformsList = BuilderSettingManager::Instance()->GetPlatformList(); PresetName suggestedPreset = BuilderSettingManager::Instance()->GetSuggestedPreset(imageFilepath); + + // If the suggested preset doesn't exist (or was failed to be loaded), return empty texture settings + if (BuilderSettingManager::Instance()->GetPreset(suggestedPreset) == nullptr) + { + AZ_Error("Image Processing", false, "Failed to find suggested preset [%s]", suggestedPreset.GetCStr()); + return settings; + } + for (PlatformName& platform : platformsList) { TextureSettings textureSettings; diff --git a/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/Editor/EditorCommon.cpp b/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/Editor/EditorCommon.cpp index 3e255dcccc..f9fe1b791f 100644 --- a/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/Editor/EditorCommon.cpp +++ b/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/Editor/EditorCommon.cpp @@ -123,6 +123,10 @@ namespace ImageProcessingAtomEditor { readableString = "iOS"; } + else if (platformStrLowerCase == "salem") + { + readableString = "Salem"; + } else if (platformStrLowerCase == "jasper") { readableString = "Jasper"; diff --git a/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/ImageBuilderComponent.cpp b/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/ImageBuilderComponent.cpp index 5e021a3fdd..55a6c1ea8f 100644 --- a/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/ImageBuilderComponent.cpp +++ b/Gems/Atom/Asset/ImageProcessingAtom/Code/Source/ImageBuilderComponent.cpp @@ -241,8 +241,7 @@ namespace ImageProcessingAtom // Reload preset if it was changed ImageProcessingAtom::BuilderSettingManager::Instance()->ReloadPreset(presetName); - AZStd::string_view filePath; - auto presetSettings = BuilderSettingManager::Instance()->GetPreset(presetName, /*default platform*/"", &filePath); + auto presetSettings = BuilderSettingManager::Instance()->GetPreset(presetName, /*default platform*/""); AssetBuilderSDK::SourceFileDependency sourceFileDependency; sourceFileDependency.m_sourceDependencyType = AssetBuilderSDK::SourceFileDependency::SourceFileDependencyType::Absolute; @@ -274,6 +273,32 @@ namespace ImageProcessingAtom } } + void ReloadPresetIfNeeded(PresetName presetName) + { + // Reload preset if it was changed + ImageProcessingAtom::BuilderSettingManager::Instance()->ReloadPreset(presetName); + + auto presetSettings = BuilderSettingManager::Instance()->GetPreset(presetName, /*default platform*/""); + + if (presetSettings) + { + // handle special case here + // Cubemap setting may reference some other presets + if (presetSettings->m_cubemapSetting) + { + if (presetSettings->m_cubemapSetting->m_generateIBLDiffuse && !presetSettings->m_cubemapSetting->m_iblDiffusePreset.IsEmpty()) + { + ImageProcessingAtom::BuilderSettingManager::Instance()->ReloadPreset(presetSettings->m_cubemapSetting->m_iblDiffusePreset); + } + + if (presetSettings->m_cubemapSetting->m_generateIBLSpecular && !presetSettings->m_cubemapSetting->m_iblSpecularPreset.IsEmpty()) + { + ImageProcessingAtom::BuilderSettingManager::Instance()->ReloadPreset(presetSettings->m_cubemapSetting->m_iblSpecularPreset); + } + } + } + } + // this happens early on in the file scanning pass // this function should consistently always create the same jobs, and should do no checking whether the job is up to date or not - just be consistent. void ImageBuilderWorker::CreateJobs(const AssetBuilderSDK::CreateJobsRequest& request, AssetBuilderSDK::CreateJobsResponse& response) @@ -336,6 +361,11 @@ namespace ImageProcessingAtom // Do conversion and get exported file's path if (needConversion) { + + // Handles preset changes + auto presetName = GetImagePreset(request.m_fullPath); + ReloadPresetIfNeeded(presetName); + AZ_TracePrintf(AssetBuilderSDK::InfoWindow, "Performing image conversion: %s\n", request.m_fullPath.c_str()); ImageConvertProcess* process = CreateImageConvertProcess(request.m_fullPath, request.m_tempDirPath, request.m_jobDescription.GetPlatformIdentifier(), response.m_outputProducts); diff --git a/Gems/Atom/Asset/ImageProcessingAtom/gem.json b/Gems/Atom/Asset/ImageProcessingAtom/gem.json index 4fd437d298..c2af4b7e7e 100644 --- a/Gems/Atom/Asset/ImageProcessingAtom/gem.json +++ b/Gems/Atom/Asset/ImageProcessingAtom/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RPI", "Atom_RHI", diff --git a/Gems/Atom/Asset/Shader/CMakeLists.txt b/Gems/Atom/Asset/Shader/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Atom/Asset/Shader/CMakeLists.txt +++ b/Gems/Atom/Asset/Shader/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/Asset/Shader/Code/CMakeLists.txt b/Gems/Atom/Asset/Shader/Code/CMakeLists.txt index ed5aa45bbf..9ebd5e6d2d 100644 --- a/Gems/Atom/Asset/Shader/Code/CMakeLists.txt +++ b/Gems/Atom/Asset/Shader/Code/CMakeLists.txt @@ -10,8 +10,8 @@ if(NOT PAL_TRAIT_BUILD_HOST_TOOLS) return() endif() -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) #for PAL_TRAIT_BUILD_ATOM_ASSET_SHADER_SUPPORTED @@ -71,7 +71,7 @@ ly_add_target( set(builder_tools_include_files) foreach(enabled_platform ${LY_PAL_TOOLS_ENABLED}) string(TOLOWER ${enabled_platform} enabled_platform_lowercase) - ly_get_list_relative_pal_filename(builder_tools_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${enabled_platform}) + o3de_pal_dir(builder_tools_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${enabled_platform} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) list(APPEND builder_tools_include_files ${builder_tools_source_dir}/platform_builders_${enabled_platform_lowercase}.cmake) endforeach() diff --git a/Gems/Atom/Asset/Shader/Code/Source/Editor/AzslShaderBuilderSystemComponent.cpp b/Gems/Atom/Asset/Shader/Code/Source/Editor/AzslShaderBuilderSystemComponent.cpp index 99b7c814d1..cc80b38b85 100644 --- a/Gems/Atom/Asset/Shader/Code/Source/Editor/AzslShaderBuilderSystemComponent.cpp +++ b/Gems/Atom/Asset/Shader/Code/Source/Editor/AzslShaderBuilderSystemComponent.cpp @@ -82,8 +82,7 @@ namespace AZ // Register Shader Asset Builder AssetBuilderSDK::AssetBuilderDesc shaderAssetBuilderDescriptor; shaderAssetBuilderDescriptor.m_name = "Shader Asset Builder"; - shaderAssetBuilderDescriptor.m_version = 108; // The Build Time Stamp of ShaderAsset And ShaderVariantAsset Should Be Based On GetTimeUTCMilliSecond() - // .shader file changes trigger rebuilds + shaderAssetBuilderDescriptor.m_version = 109; // Modify Metal shader platform to permit the precise keyword to fix depth bitwise mismatch between passes shaderAssetBuilderDescriptor.m_patterns.push_back(AssetBuilderSDK::AssetBuilderPattern( AZStd::string::format("*.%s", RPI::ShaderSourceData::Extension), AssetBuilderSDK::AssetBuilderPattern::PatternType::Wildcard)); shaderAssetBuilderDescriptor.m_busId = azrtti_typeid(); shaderAssetBuilderDescriptor.m_createJobFunction = AZStd::bind(&ShaderAssetBuilder::CreateJobs, &m_shaderAssetBuilder, AZStd::placeholders::_1, AZStd::placeholders::_2); diff --git a/Gems/Atom/Asset/Shader/Code/Source/Editor/ShaderBuilderUtility.cpp b/Gems/Atom/Asset/Shader/Code/Source/Editor/ShaderBuilderUtility.cpp index e6c99630b2..911981142b 100644 --- a/Gems/Atom/Asset/Shader/Code/Source/Editor/ShaderBuilderUtility.cpp +++ b/Gems/Atom/Asset/Shader/Code/Source/Editor/ShaderBuilderUtility.cpp @@ -492,6 +492,14 @@ namespace AZ { platformId = AzFramework::PlatformId::IOS; } + else if (platformIdentifier == "salem") + { + platformId = AzFramework::PlatformId::SALEM; + } + else if (platformIdentifier == "jasper") + { + platformId = AzFramework::PlatformId::JASPER; + } else if (platformIdentifier == "server") { platformId = AzFramework::PlatformId::SERVER; diff --git a/Gems/Atom/Asset/Shader/Code/Source/Editor/ShaderVariantAssetBuilder.cpp b/Gems/Atom/Asset/Shader/Code/Source/Editor/ShaderVariantAssetBuilder.cpp index 5eaa0d9ddb..8dc67bb3d1 100644 --- a/Gems/Atom/Asset/Shader/Code/Source/Editor/ShaderVariantAssetBuilder.cpp +++ b/Gems/Atom/Asset/Shader/Code/Source/Editor/ShaderVariantAssetBuilder.cpp @@ -241,7 +241,7 @@ namespace AZ { // Need to get the name of the shader file from the template so that we can preprocess the shader data and setup // source file dependencies. - if (!RPI::JsonUtils::LoadObjectFromFile(variantListFullPath, shaderVariantList)) + if (!RPI::JsonUtils::LoadObjectFromFile(variantListFullPath, shaderVariantList, AZStd::numeric_limits::max())) { AZ_Error(ShaderVariantAssetBuilderName, false, "Failed to parse Shader Variant List Descriptor JSON from [%s]", variantListFullPath.c_str()); return LoadResult{LoadResult::Code::Error}; @@ -635,7 +635,7 @@ namespace AZ AzFramework::StringFunc::Path::ConstructFull(request.m_watchFolder.data(), request.m_sourceFile.data(), variantListFullPath, true); RPI::ShaderVariantListSourceData shaderVariantListDescriptor; - if (!RPI::JsonUtils::LoadObjectFromFile(variantListFullPath, shaderVariantListDescriptor)) + if (!RPI::JsonUtils::LoadObjectFromFile(variantListFullPath, shaderVariantListDescriptor, AZStd::numeric_limits::max())) { AZ_Assert(false, "Failed to parse Shader Variant List Descriptor JSON [%s]", variantListFullPath.c_str()); response.m_resultCode = AssetBuilderSDK::ProcessJobResult_Failed; diff --git a/Gems/Atom/Asset/Shader/gem.json b/Gems/Atom/Asset/Shader/gem.json index 9f59c65f78..8b4ba4fb0d 100644 --- a/Gems/Atom/Asset/Shader/gem.json +++ b/Gems/Atom/Asset/Shader/gem.json @@ -4,13 +4,17 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", - "summary": "", + "summary": "Atom Shader Builder", "canonical_tags": [ "Gem" ], - "user_tags": [], + "user_tags": [ + "AtomShader" + ], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI", "Atom_RPI" diff --git a/Gems/Atom/Bootstrap/CMakeLists.txt b/Gems/Atom/Bootstrap/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Atom/Bootstrap/CMakeLists.txt +++ b/Gems/Atom/Bootstrap/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/Bootstrap/Code/CMakeLists.txt b/Gems/Atom/Bootstrap/Code/CMakeLists.txt index fd9df96124..0ba8d17865 100644 --- a/Gems/Atom/Bootstrap/Code/CMakeLists.txt +++ b/Gems/Atom/Bootstrap/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME Atom_Bootstrap.Headers HEADERONLY diff --git a/Gems/Atom/Bootstrap/Code/Source/BootstrapSystemComponent.cpp b/Gems/Atom/Bootstrap/Code/Source/BootstrapSystemComponent.cpp index 84fc58718c..ef03a839d7 100644 --- a/Gems/Atom/Bootstrap/Code/Source/BootstrapSystemComponent.cpp +++ b/Gems/Atom/Bootstrap/Code/Source/BootstrapSystemComponent.cpp @@ -155,7 +155,7 @@ namespace AZ { Initialize(); }, - "LegacySystemInterfaceCreated"); + "CriticalAssetsCompiled"); } } diff --git a/Gems/Atom/Bootstrap/gem.json b/Gems/Atom/Bootstrap/gem.json index df615366da..543efe0f34 100644 --- a/Gems/Atom/Bootstrap/gem.json +++ b/Gems/Atom/Bootstrap/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RPI" ] diff --git a/Gems/Atom/CMakeLists.txt b/Gems/Atom/CMakeLists.txt index a71afa64e0..b5dd311e5a 100644 --- a/Gems/Atom/CMakeLists.txt +++ b/Gems/Atom/CMakeLists.txt @@ -6,12 +6,10 @@ # # -add_subdirectory(Asset) -add_subdirectory(Bootstrap) -add_subdirectory(Component) -add_subdirectory(Feature) -add_subdirectory(RHI) -add_subdirectory(RPI) +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Tools) add_subdirectory(Utils) diff --git a/Gems/Atom/Component/CMakeLists.txt b/Gems/Atom/Component/CMakeLists.txt deleted file mode 100644 index 8b867b8c67..0000000000 --- a/Gems/Atom/Component/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -# -# Copyright (c) Contributors to the Open 3D Engine Project. -# For complete copyright and license terms please see the LICENSE at the root of this distribution. -# -# SPDX-License-Identifier: Apache-2.0 OR MIT -# -# - -add_subdirectory(DebugCamera) diff --git a/Gems/Atom/Component/DebugCamera/CMakeLists.txt b/Gems/Atom/Component/DebugCamera/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Atom/Component/DebugCamera/CMakeLists.txt +++ b/Gems/Atom/Component/DebugCamera/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/Component/DebugCamera/Code/Include/Atom/Component/DebugCamera/CameraComponent.h b/Gems/Atom/Component/DebugCamera/Code/Include/Atom/Component/DebugCamera/CameraComponent.h index fb9c543bca..47254bcdc5 100644 --- a/Gems/Atom/Component/DebugCamera/Code/Include/Atom/Component/DebugCamera/CameraComponent.h +++ b/Gems/Atom/Component/DebugCamera/Code/Include/Atom/Component/DebugCamera/CameraComponent.h @@ -104,6 +104,10 @@ namespace AZ void SetOrthographicHalfWidth(float halfWidth) override; void MakeActiveView() override; bool IsActiveView() override; + AZ::Vector3 ScreenToWorld(const AZ::Vector2& screenPosition, float depth) override; + AZ::Vector3 ScreenNdcToWorld(const AZ::Vector2& screenPosition, float depth) override; + AZ::Vector2 WorldToScreen(const AZ::Vector3& worldPosition) override; + AZ::Vector2 WorldToScreenNdc(const AZ::Vector3& worldPosition) override; // RPI::WindowContextNotificationBus overrides... void OnViewportResized(uint32_t width, uint32_t height) override; diff --git a/Gems/Atom/Component/DebugCamera/Code/Source/CameraComponent.cpp b/Gems/Atom/Component/DebugCamera/Code/Source/CameraComponent.cpp index f3123e2b38..c4420dc417 100644 --- a/Gems/Atom/Component/DebugCamera/Code/Source/CameraComponent.cpp +++ b/Gems/Atom/Component/DebugCamera/Code/Source/CameraComponent.cpp @@ -245,7 +245,7 @@ namespace AZ AZ_Assert(false, "DebugCamera does not support orthographic projection"); } - void CameraComponent::MakeActiveView() + void CameraComponent::MakeActiveView() { // do nothing } @@ -255,6 +255,30 @@ namespace AZ return false; } + AZ::Vector3 CameraComponent::ScreenToWorld([[maybe_unused]] const AZ::Vector2& screenPosition, [[maybe_unused]] float depth) + { + // not implemented + return AZ::Vector3::CreateZero(); + } + + AZ::Vector3 CameraComponent::ScreenNdcToWorld([[maybe_unused]] const AZ::Vector2& screenPosition, [[maybe_unused]] float depth) + { + // not implemented + return AZ::Vector3::CreateZero(); + } + + AZ::Vector2 CameraComponent::WorldToScreen([[maybe_unused]] const AZ::Vector3& worldPosition) + { + // not implemented + return AZ::Vector2::CreateZero(); + } + + AZ::Vector2 CameraComponent::WorldToScreenNdc([[maybe_unused]] const AZ::Vector3& worldPosition) + { + // not implemented + return AZ::Vector2::CreateZero(); + } + void CameraComponent::OnViewportResized(uint32_t width, uint32_t height) { AZ_UNUSED(width); diff --git a/Gems/Atom/Component/DebugCamera/gem.json b/Gems/Atom/Component/DebugCamera/gem.json index 8eab74f41d..74d88a21b6 100644 --- a/Gems/Atom/Component/DebugCamera/gem.json +++ b/Gems/Atom/Component/DebugCamera/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RPI" ] diff --git a/Gems/Atom/Feature/CMakeLists.txt b/Gems/Atom/Feature/CMakeLists.txt deleted file mode 100644 index 32d654d5c4..0000000000 --- a/Gems/Atom/Feature/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -# -# Copyright (c) Contributors to the Open 3D Engine Project. -# For complete copyright and license terms please see the LICENSE at the root of this distribution. -# -# SPDX-License-Identifier: Apache-2.0 OR MIT -# -# - -add_subdirectory(Common) diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR.materialtype b/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR.materialtype index 5de756067a..d4b5882f21 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR.materialtype +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR.materialtype @@ -1652,6 +1652,12 @@ "file": "EnhancedPBR_SubsurfaceState.lua" } }, + { + "type": "Lua", + "args": { + "file": "EnhancedPBR_Anisotropy.lua" + } + }, { "type": "Lua", "args": { diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_Anisotropy.lua b/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_Anisotropy.lua new file mode 100644 index 0000000000..575a3a3d5e --- /dev/null +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_Anisotropy.lua @@ -0,0 +1,41 @@ +-------------------------------------------------------------------------------------- +-- +-- Copyright (c) Contributors to the Open 3D Engine Project. +-- For complete copyright and license terms please see the LICENSE at the root of this distribution. +-- +-- SPDX-License-Identifier: Apache-2.0 OR MIT +-- +-- +-- +---------------------------------------------------------------------------------------------------- + +function GetMaterialPropertyDependencies() + return { + "anisotropy.enableAnisotropy" + , "anisotropy.factor" + , "anisotropy.anisotropyAngle" + } +end + +function GetShaderOptionDependencies() + return {"o_enableAnisotropy"} +end + +function Process(context) + local enableAnisotropy = context:GetMaterialPropertyValue_bool("anisotropy.enableAnisotropy") +end + +function ProcessEditor(context) + + local enableAnisotropy = context:GetMaterialPropertyValue_bool("anisotropy.enableAnisotropy") + + local visibility + if(enableAnisotropy) then + visibility = MaterialPropertyVisibility_Enabled + else + visibility = MaterialPropertyVisibility_Hidden + end + + context:SetMaterialPropertyVisibility("anisotropy.factor", visibility) + context:SetMaterialPropertyVisibility("anisotropy.anisotropyAngle", visibility) +end diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_DepthPass_WithPS.azsl b/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_DepthPass_WithPS.azsl index f2564cf10c..08642decc0 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_DepthPass_WithPS.azsl +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_DepthPass_WithPS.azsl @@ -28,7 +28,7 @@ struct VSInput struct VSDepthOutput { - float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float2 m_uv[UvSetCount] : UV1; // only used for parallax depth calculation @@ -62,7 +62,7 @@ VSDepthOutput MainVS(VSInput IN) struct PSDepthOutput { - float m_depth : SV_Depth; + precise float m_depth : SV_Depth; }; PSDepthOutput MainPS(VSDepthOutput IN, bool isFrontFace : SV_IsFrontFace) diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_ForwardPass.azsl b/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_ForwardPass.azsl index 0f9771e480..4b37f67930 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_ForwardPass.azsl +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/EnhancedPBR_ForwardPass.azsl @@ -67,7 +67,7 @@ struct VSInput struct VSOutput { // Base fields (required by the template azsli file)... - float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float3 m_normal: NORMAL; float3 m_tangent : TANGENT; float3 m_bitangent : BITANGENT; diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin.azsl b/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin.azsl index 523353f8fa..00dee50c93 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin.azsl +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin.azsl @@ -86,7 +86,7 @@ struct VSInput struct VSOutput { // Base fields (required by the template azsli file)... - float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float3 m_normal: NORMAL; float3 m_tangent : TANGENT; float3 m_bitangent : BITANGENT; diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin.materialtype b/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin.materialtype index e2a05aa916..a49eba7975 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin.materialtype +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin.materialtype @@ -1084,6 +1084,12 @@ "file": "Skin_WrinkleMaps.lua" } }, + { + "type": "Lua", + "args": { + "file": "Skin_SpecularF0.lua" + } + }, { "type": "Lua", "args": { diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin_SpecularF0.lua b/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin_SpecularF0.lua new file mode 100644 index 0000000000..d727e8f301 --- /dev/null +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/Skin_SpecularF0.lua @@ -0,0 +1,30 @@ +-------------------------------------------------------------------------------------- +-- +-- Copyright (c) Contributors to the Open 3D Engine Project. +-- For complete copyright and license terms please see the LICENSE at the root of this distribution. +-- +-- SPDX-License-Identifier: Apache-2.0 OR MIT +-- +-- +-- +---------------------------------------------------------------------------------------------------- + +function GetMaterialPropertyDependencies() + return { + "specularF0.enableMultiScatterCompensation" + } +end + +function GetShaderOptionDependencies() + return { + "o_specularF0_enableMultiScatterCompensation" + } +end + +function Process(context) + local enableMultiScatterCompensation = context:GetMaterialPropertyValue_bool("specularF0.enableMultiScatterCompensation") +end + +function ProcessEditor(context) + context:SetMaterialPropertyVisibility("specularF0.enableMultiScatterCompensation", MaterialPropertyVisibility_Hidden) +end \ No newline at end of file diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardMultilayerPBR_DepthPass_WithPS.azsl b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardMultilayerPBR_DepthPass_WithPS.azsl index 39597e2bdd..7875457489 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardMultilayerPBR_DepthPass_WithPS.azsl +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardMultilayerPBR_DepthPass_WithPS.azsl @@ -41,7 +41,7 @@ struct VSInput struct VSDepthOutput { - float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float2 m_uv[UvSetCount] : UV1; // only used for parallax depth calculation @@ -88,7 +88,7 @@ VSDepthOutput MainVS(VSInput IN) struct PSDepthOutput { - float m_depth : SV_Depth; + precise float m_depth : SV_Depth; }; PSDepthOutput MainPS(VSDepthOutput IN, bool isFrontFace : SV_IsFrontFace) diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardMultilayerPBR_ForwardPass.azsl b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardMultilayerPBR_ForwardPass.azsl index 8f58c6dd33..5b05e48d3b 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardMultilayerPBR_ForwardPass.azsl +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardMultilayerPBR_ForwardPass.azsl @@ -80,7 +80,7 @@ struct VSInput struct VSOutput { // Base fields (required by the template azsli file)... - float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float3 m_normal: NORMAL; float3 m_tangent : TANGENT; float3 m_bitangent : BITANGENT; diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_ClearCoatState.lua b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_ClearCoatState.lua index 3d7eca134e..50644adef4 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_ClearCoatState.lua +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_ClearCoatState.lua @@ -58,6 +58,15 @@ function UpdateTextureDependentPropertyVisibility(context, textureMapPropertyNam end end +function UpdateNormalStrengthPropertyVisibility(context, textureMapPropertyName, useTexturePropertyName) + local textureMap = context:GetMaterialPropertyValue_Image(textureMapPropertyName) + local useTexture = context:GetMaterialPropertyValue_bool(useTexturePropertyName) + + if(textureMap == nil) or (not useTexture) then + context:SetMaterialPropertyVisibility("clearCoat.normalStrength", MaterialPropertyVisibility_Hidden) + end +end + function ProcessEditor(context) local enable = context:GetMaterialPropertyValue_bool("clearCoat.enable") @@ -79,10 +88,12 @@ function ProcessEditor(context) context:SetMaterialPropertyVisibility("clearCoat.normalMap", mainVisibility) context:SetMaterialPropertyVisibility("clearCoat.useNormalMap", mainVisibility) context:SetMaterialPropertyVisibility("clearCoat.normalMapUv", mainVisibility) + context:SetMaterialPropertyVisibility("clearCoat.normalStrength", mainVisibility) if(enable) then UpdateTextureDependentPropertyVisibility(context, "clearCoat.influenceMap", "clearCoat.useInfluenceMap", "clearCoat.influenceMapUv") UpdateTextureDependentPropertyVisibility(context, "clearCoat.roughnessMap", "clearCoat.useRoughnessMap", "clearCoat.roughnessMapUv") UpdateTextureDependentPropertyVisibility(context, "clearCoat.normalMap", "clearCoat.useNormalMap", "clearCoat.normalMapUv") + UpdateNormalStrengthPropertyVisibility(context, "clearCoat.normalMap", "clearCoat.useNormalMap") end end diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_DepthPass_WithPS.azsl b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_DepthPass_WithPS.azsl index 136841907b..04fd104407 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_DepthPass_WithPS.azsl +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_DepthPass_WithPS.azsl @@ -29,7 +29,7 @@ struct VSInput struct VSDepthOutput { // "centroid" is needed for SV_Depth to compile - linear centroid float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float2 m_uv[UvSetCount] : UV1; // only used for parallax depth calculation @@ -63,7 +63,7 @@ VSDepthOutput MainVS(VSInput IN) struct PSDepthOutput { - float m_depth : SV_Depth; + precise float m_depth : SV_Depth; }; PSDepthOutput MainPS(VSDepthOutput IN, bool isFrontFace : SV_IsFrontFace) diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_ForwardPass.azsl b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_ForwardPass.azsl index 1d5e4ad9e3..b99ea734af 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_ForwardPass.azsl +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_ForwardPass.azsl @@ -62,7 +62,7 @@ struct VSOutput { // Base fields (required by the template azsli file)... // "centroid" is needed for SV_Depth to compile - linear centroid float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float3 m_normal: NORMAL; float3 m_tangent : TANGENT; float3 m_bitangent : BITANGENT; diff --git a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_HandleOpacityMode.lua b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_HandleOpacityMode.lua index 9315131e44..462d433d34 100644 --- a/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_HandleOpacityMode.lua +++ b/Gems/Atom/Feature/Common/Assets/Materials/Types/StandardPBR_HandleOpacityMode.lua @@ -91,6 +91,10 @@ function ProcessEditor(context) if(mainVisibility == MaterialPropertyVisibility_Enabled) then local alphaSource = context:GetMaterialPropertyValue_enum("opacity.alphaSource") + if (opacityMode == OpacityMode_Cutout and alphaSource == AlphaSource_None) then + context:SetMaterialPropertyVisibility("opacity.factor", MaterialPropertyVisibility_Hidden) + end + if(alphaSource ~= AlphaSource_Split) then context:SetMaterialPropertyVisibility("opacity.textureMap", MaterialPropertyVisibility_Hidden) context:SetMaterialPropertyVisibility("opacity.textureMapUv", MaterialPropertyVisibility_Hidden) diff --git a/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/PBR/Surfaces/BasePbrSurfaceData.azsli b/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/PBR/Surfaces/BasePbrSurfaceData.azsli index 54bfa31fe8..484958c26c 100644 --- a/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/PBR/Surfaces/BasePbrSurfaceData.azsli +++ b/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/PBR/Surfaces/BasePbrSurfaceData.azsli @@ -24,7 +24,7 @@ static const float MinRoughnessA = 0.0005f; class BasePbrSurfaceData { - float3 position; //!< Position in world-space + precise float3 position; //!< Position in world-space float3 normal; //!< Normal in world-space float3 albedo; //!< Albedo color of the non-metallic material, will be multiplied against the diffuse lighting value float3 specularF0; //!< Fresnel f0 spectral value of the surface diff --git a/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/PBR/Surfaces/StandardSurface.azsli b/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/PBR/Surfaces/StandardSurface.azsli index 084943bf38..e1b3ff8206 100644 --- a/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/PBR/Surfaces/StandardSurface.azsli +++ b/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/PBR/Surfaces/StandardSurface.azsli @@ -20,7 +20,7 @@ class Surface // ------- BasePbrSurfaceData ------- - float3 position; //!< Position in world-space + precise float3 position; //!< Position in world-space float3 normal; //!< Normal in world-space float3 vertexNormal; //!< Vertex normal in world-space float3 albedo; //!< Albedo color of the non-metallic material, will be multiplied against the diffuse lighting value diff --git a/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/Shadow/DirectionalLightShadow.azsli b/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/Shadow/DirectionalLightShadow.azsli index 59817af701..870bebdf4b 100644 --- a/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/Shadow/DirectionalLightShadow.azsli +++ b/Gems/Atom/Feature/Common/Assets/ShaderLib/Atom/Features/Shadow/DirectionalLightShadow.azsli @@ -10,6 +10,7 @@ #include #include +#include #include "Shadow.azsli" #include "ShadowmapAtlasLib.azsli" #include "BicubicPcfFilters.azsli" @@ -25,6 +26,10 @@ enum class ShadowFilterMethod {None, Pcf, Esm, EsmPcf}; option ShadowFilterMethod o_directional_shadow_filtering_method = ShadowFilterMethod::None; option bool o_directional_shadow_receiver_plane_bias_enable = true; +option bool o_blend_between_cascades_enable = false; + +static const float CascadeBlendArea = 0.015f; // might be worth exposing this as a slider. + // DirectionalLightShadow calculates lit ratio for a directional light. class DirectionalLightShadow @@ -98,6 +103,8 @@ class DirectionalLightShadow float SamplePcfBicubic(float3 shadowCoord, uint indexOfCascade); + float CalculateCascadeBlendAmount(const float3 texCoord); + uint m_lightIndex; float3 m_shadowCoords[ViewSrg::MaxCascadeCount]; float m_slopeBias[ViewSrg::MaxCascadeCount]; @@ -174,6 +181,7 @@ bool2 DirectionalLightShadow::IsShadowed(float3 shadowCoord, uint indexOfCascade const uint cascadeCount = ViewSrg::m_directionalLightShadows[m_lightIndex].m_cascadeCount; Texture2DArray shadowmap = PassSrg::m_directionalLightShadowmap; + [branch] if (shadowCoord.x >= 0. && shadowCoord.x * size < size - PixelMargin && shadowCoord.y >= 0. && shadowCoord.y * size < size - PixelMargin) { @@ -213,20 +221,46 @@ float DirectionalLightShadow::GetVisibilityFromLightPcf() static const float PixelMargin = 1.5; // avoiding artifact between cascade levels. static const float DepthMargin = 1e-8; // avoiding artifact when near depth bounds. + bool cascadeFound = false; + int currentCascadeIndex = 0; + const uint size = ViewSrg::m_directionalLightShadows[m_lightIndex].m_shadowmapSize; const uint cascadeCount = ViewSrg::m_directionalLightShadows[m_lightIndex].m_cascadeCount; for (uint indexOfCascade = 0; indexOfCascade < cascadeCount; ++indexOfCascade) { const float3 shadowCoord = m_shadowCoords[indexOfCascade]; - + if (shadowCoord.x >= 0. && shadowCoord.x * size < size - PixelMargin && shadowCoord.y >= 0. && shadowCoord.y * size < size - PixelMargin && shadowCoord.z < 1. - DepthMargin) { - m_debugInfo.m_cascadeIndex = indexOfCascade; - return SamplePcfBicubic(shadowCoord, indexOfCascade); + currentCascadeIndex = m_debugInfo.m_cascadeIndex = indexOfCascade; + cascadeFound = true; + break; } } + + [branch] + if (cascadeFound) + { + float lit = SamplePcfBicubic(m_shadowCoords[currentCascadeIndex], currentCascadeIndex); + + if(o_blend_between_cascades_enable) + { + const float blendBetweenCascadesAmount = CalculateCascadeBlendAmount(m_shadowCoords[currentCascadeIndex].xyz); + + const int nextCascadeIndex = currentCascadeIndex + 1; + [branch] + if (blendBetweenCascadesAmount < 1.0f && nextCascadeIndex < cascadeCount) + { + const float nextLit = SamplePcfBicubic(m_shadowCoords[nextCascadeIndex], nextCascadeIndex); + lit = lerp(nextLit, lit, blendBetweenCascadesAmount); + } + } + + return lit; + } + m_debugInfo.m_cascadeIndex = cascadeCount; return 1.; } @@ -244,6 +278,8 @@ float DirectionalLightShadow::GetVisibilityFromLightEsm() const float distanceMin = ViewSrg::m_esmsDirectional[indexOfCascade].m_lightDistanceOfCameraViewFrustum; bool2 checkedShadowed = IsShadowed(shadowCoord, indexOfCascade); const float depthDiff = shadowCoord.z - distanceMin; + + [branch] if (checkedShadowed.x && depthDiff >= 0) { const float distanceWithinCameraView = depthDiff / (1. - distanceMin); @@ -274,6 +310,8 @@ float DirectionalLightShadow::GetVisibilityFromLightEsmPcf() const float distanceMin = ViewSrg::m_esmsDirectional[indexOfCascade].m_lightDistanceOfCameraViewFrustum; bool2 checkedShadowed = IsShadowed(shadowCoord, indexOfCascade); const float depthDiff = shadowCoord.z - distanceMin; + + [branch] if (checkedShadowed.x && depthDiff >= 0) { const float distanceWithinCameraView = depthDiff / (1. - distanceMin); @@ -319,6 +357,7 @@ float DirectionalLightShadow::SamplePcfBicubic(float3 shadowCoord, uint indexOfC param.samplerState = SceneSrg::m_hwPcfSampler; param.receiverPlaneDepthBias = o_directional_shadow_receiver_plane_bias_enable ? ComputeReceiverPlaneDepthBias(m_shadowPosDX[indexOfCascade], m_shadowPosDY[indexOfCascade]) : 0; + [branch] if (filteringSampleCount <= 4) { return SampleShadowMapBicubic_4Tap(param); @@ -420,3 +459,10 @@ float3 DirectionalLightShadow::AddDebugColoring( } return color; } + +float DirectionalLightShadow::CalculateCascadeBlendAmount(const float3 texCoord) +{ + const float distanceToOneMin = min3(1.0f - texCoord); + const float currentPixelsBlendBandLocation = min(min(texCoord.x, texCoord.y), distanceToOneMin); + return currentPixelsBlendBandLocation / CascadeBlendArea; +} diff --git a/Gems/Atom/Feature/Common/Assets/ShaderResourceGroups/SceneSrgAll.azsli b/Gems/Atom/Feature/Common/Assets/ShaderResourceGroups/SceneSrgAll.azsli index 421178bb01..4480524468 100644 --- a/Gems/Atom/Feature/Common/Assets/ShaderResourceGroups/SceneSrgAll.azsli +++ b/Gems/Atom/Feature/Common/Assets/ShaderResourceGroups/SceneSrgAll.azsli @@ -13,4 +13,5 @@ #ifdef AZ_COLLECTING_PARTIAL_SRGS #include #include +#include // Temporary until gem partial view srgs can be included automatically. #endif diff --git a/Gems/Atom/Feature/Common/Assets/ShaderResourceGroups/ViewSrgAll.azsli b/Gems/Atom/Feature/Common/Assets/ShaderResourceGroups/ViewSrgAll.azsli index 9253885cfc..3e90e1a441 100644 --- a/Gems/Atom/Feature/Common/Assets/ShaderResourceGroups/ViewSrgAll.azsli +++ b/Gems/Atom/Feature/Common/Assets/ShaderResourceGroups/ViewSrgAll.azsli @@ -12,5 +12,4 @@ #ifdef AZ_COLLECTING_PARTIAL_SRGS #include -#include // Temporary until gem partial view srgs can be included automatically. #endif diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/Depth/DepthPassCommon.azsli b/Gems/Atom/Feature/Common/Assets/Shaders/Depth/DepthPassCommon.azsli index f658dd13da..ba06dada74 100644 --- a/Gems/Atom/Feature/Common/Assets/Shaders/Depth/DepthPassCommon.azsli +++ b/Gems/Atom/Feature/Common/Assets/Shaders/Depth/DepthPassCommon.azsli @@ -17,7 +17,7 @@ struct VSInput struct VSDepthOutput { - float4 m_position : SV_Position; + precise float4 m_position : SV_Position; }; VSDepthOutput DepthPassVS(VSInput IN) diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/DiffuseComposite.azsl b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/DiffuseComposite.azsl index 9aa169beea..e3237e59a2 100644 --- a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/DiffuseComposite.azsl +++ b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/DiffuseComposite.azsl @@ -150,7 +150,7 @@ PSOutput MainPS(VSOutput IN, in uint sampleIndex : SV_SampleIndex) float4 encodedNormal = PassSrg::m_normal.Load(screenCoords, sampleIndex); float3 normal = DecodeNormalSignedOctahedron(encodedNormal.rgb); float4 albedo = PassSrg::m_albedo.Load(screenCoords, sampleIndex); - float probeIrradianceBlendWeight = PassSrg::m_downsampledProbeIrradiance.Load(probeIrradianceCoords, sampleIndex).a; + float probeIrradianceBlendWeight = saturate(PassSrg::m_downsampledProbeIrradiance.Load(probeIrradianceCoords, sampleIndex).a); float3 diffuse = float3(0.0f, 0.0f, 0.0f); if (probeIrradianceBlendWeight > 0.0f) diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender.azshader b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender.azshader index 781d7e26e5..1f04570625 100644 Binary files a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender.azshader and b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender.azshader differ diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_dx12_0.azshadervariant b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_dx12_0.azshadervariant index 668dc28ca0..a359556df6 100644 Binary files a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_dx12_0.azshadervariant and b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_dx12_0.azshadervariant differ diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_null_0.azshadervariant b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_null_0.azshadervariant index 77bb341839..7a90c7f352 100644 Binary files a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_null_0.azshadervariant and b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_null_0.azshadervariant differ diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_vulkan_0.azshadervariant b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_vulkan_0.azshadervariant index 117f993f28..4cbb76954d 100644 Binary files a/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_vulkan_0.azshadervariant and b/Gems/Atom/Feature/Common/Assets/Shaders/DiffuseGlobalIllumination/diffuseprobegridrender_vulkan_0.azshadervariant differ diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/LightCulling/LightCulling.azsl b/Gems/Atom/Feature/Common/Assets/Shaders/LightCulling/LightCulling.azsl index 707ede9868..e806bc7cb7 100644 --- a/Gems/Atom/Feature/Common/Assets/Shaders/LightCulling/LightCulling.azsl +++ b/Gems/Atom/Feature/Common/Assets/Shaders/LightCulling/LightCulling.azsl @@ -368,16 +368,19 @@ void CullDecals(uint groupIndex, TileLightData tileLightData, float3 aabb_center float3 decalPosition = WorldToView_Point(decal.m_position); // just wrapping a bounding sphere around a cube for now to get a minor perf boost. i.e. the sphere radius is sqrt(x*x + y*y + z*z) - // ATOM-4224 - try AABB-AABB and implement depth binning for the decals - float maxHalfSize = max(max(decal.m_halfSize.x, decal.m_halfSize.y), decal.m_halfSize.z); - float boundingSphereRadiusSqr = maxHalfSize * maxHalfSize * 3; + // ATOM-4224 - try AABB-AABB + float boundingSphereRadiusSqr = dot(decal.m_halfSize, decal.m_halfSize); bool potentiallyIntersects = TestSphereVsAabb(decalPosition, boundingSphereRadiusSqr, aabb_center, aabb_extents); + if (potentiallyIntersects) { - // Implement and profile fine-grained light culling testing - // ATOM-3732 - MarkLightAsVisibleInSharedMemory(decalIndex, 0xFFFF); + uint inside = 0; + float2 minmax = ComputePointLightMinMaxZ(sqrt(boundingSphereRadiusSqr), decalPosition); + if (IsObjectInsideTile(tileLightData, minmax, inside)) + { + MarkLightAsVisibleInSharedMemory(decalIndex, inside); + } } } } diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.azsl b/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.azsl deleted file mode 100644 index e31179c733..0000000000 --- a/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.azsl +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include -#include -#include - -ShaderResourceGroup PassSrg : SRG_PerPass -{ - Texture2D m_sourceTexture; - - Sampler TextureSampler - { - MinFilter = Point; - MagFilter = Point; - MipFilter = Point; - AddressU = Clamp; - AddressV = Clamp; - AddressW = Clamp; - }; -} - -float4 RestoreNormalMap(float4 normalMapSample) -{ - float4 restoredNormal; - - // [GFX TODO][ATOM-2404] For some reason, the image build pipeline swaps the R and G channels so we swap them back here. - restoredNormal.xy = normalMapSample.yx; - - // The image build pipeline drops the B channel so we have to reconstruct it here. - restoredNormal.z = sqrt(1 - dot(restoredNormal.xy, restoredNormal.xy)); - - restoredNormal.xyz = restoredNormal.xyz * 0.5 + 0.5; - restoredNormal.a = 1; - - return restoredNormal; -} - -option bool o_isNormal; - -PSOutput MainPS(VSOutput IN) -{ - PSOutput OUT; - - if(o_isNormal) - { - float4 sampledValue = PassSrg::m_sourceTexture.SampleLevel(PassSrg::TextureSampler, IN.m_texCoord, 0); - OUT.m_color = RestoreNormalMap(sampledValue); - } - else - { - OUT.m_color = PassSrg::m_sourceTexture.SampleLevel(PassSrg::TextureSampler, IN.m_texCoord, 0); - } - - return OUT; -} diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.shader b/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.shader deleted file mode 100644 index 6035f98f5d..0000000000 --- a/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.shader +++ /dev/null @@ -1,22 +0,0 @@ -{ - "Source" : "RenderTexture.azsl", - - "DepthStencilState" : { - "Depth" : { "Enable" : false } - }, - - "ProgramSettings": - { - "EntryPoints": - [ - { - "name": "MainVS", - "type": "Vertex" - }, - { - "name": "MainPS", - "type": "Fragment" - } - ] - } -} diff --git a/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.shadervariantlist b/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.shadervariantlist deleted file mode 100644 index 97faeac819..0000000000 --- a/Gems/Atom/Feature/Common/Assets/Shaders/LuxCore/RenderTexture.shadervariantlist +++ /dev/null @@ -1,17 +0,0 @@ -{ - "Shader" : "RenderTexture.shader", - "Variants" : [ - { - "StableId": 1, - "Options": { - "o_isNormal": "false" - } - }, - { - "StableId": 2, - "Options": { - "o_isNormal": "true" - } - } - ] -} diff --git a/Gems/Atom/Feature/Common/Assets/atom_feature_common_asset_files.cmake b/Gems/Atom/Feature/Common/Assets/atom_feature_common_asset_files.cmake index a03058e2bf..1844d26e10 100644 --- a/Gems/Atom/Feature/Common/Assets/atom_feature_common_asset_files.cmake +++ b/Gems/Atom/Feature/Common/Assets/atom_feature_common_asset_files.cmake @@ -366,8 +366,6 @@ set(FILES Shaders/LightCulling/LightCullingRemap.shader Shaders/LightCulling/LightCullingTilePrepare.azsl Shaders/LightCulling/LightCullingTilePrepare.shader - Shaders/LuxCore/RenderTexture.azsl - Shaders/LuxCore/RenderTexture.shader Shaders/MorphTargets/MorphTargetCS.azsl Shaders/MorphTargets/MorphTargetCS.shader Shaders/MorphTargets/MorphTargetSRG.azsli diff --git a/Gems/Atom/Feature/Common/CMakeLists.txt b/Gems/Atom/Feature/Common/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Atom/Feature/Common/CMakeLists.txt +++ b/Gems/Atom/Feature/Common/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/Feature/Common/Code/CMakeLists.txt b/Gems/Atom/Feature/Common/Code/CMakeLists.txt index b558be3714..a832c46539 100644 --- a/Gems/Atom/Feature/Common/Code/CMakeLists.txt +++ b/Gems/Atom/Feature/Common/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) ly_add_target( NAME Atom_Feature_Common.Static STATIC @@ -40,7 +40,6 @@ ly_add_target( Gem::Atom_Feature_Common.Public Gem::ImGui.imguilib 3rdParty::TIFF - #3rdParty::lux_core # AZ_TRAIT_LUXCORE_SUPPORTED is disabled in every platform, Issue #3915 will remove RUNTIME_DEPENDENCIES Gem::ImGui.imguilib ) @@ -91,11 +90,16 @@ ly_add_target( AZ::AzFramework Gem::Atom_Feature_Common.Static Gem::Atom_Feature_Common.Public - #3rdParty::lux_core # AZ_TRAIT_LUXCORE_SUPPORTED is disabled in every platform, Issue #3915 will remove ) if(PAL_TRAIT_BUILD_HOST_TOOLS) + set(runtime_dependencies_tools ${pal_source_dir}/runtime_dependencies_tools.cmake) + foreach(pal_tools_platform ${LY_PAL_TOOLS_ENABLED}) + ly_get_list_relative_pal_filename(pal_runtime_dependencies_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${pal_tools_platform}) + list(APPEND runtime_dependencies_tools ${pal_runtime_dependencies_source_dir}/runtime_dependencies_tools.cmake) + endforeach() + ly_add_target( NAME Atom_Feature_Common.Editor GEM_MODULE @@ -103,7 +107,7 @@ if(PAL_TRAIT_BUILD_HOST_TOOLS) FILES_CMAKE atom_feature_common_editor_files.cmake PLATFORM_INCLUDE_FILES - ${pal_source_dir}/runtime_dependencies_tools.cmake + ${runtime_dependencies_tools} INCLUDE_DIRECTORIES PRIVATE . @@ -136,7 +140,7 @@ if(PAL_TRAIT_BUILD_HOST_TOOLS) FILES_CMAKE atom_feature_common_builders_files.cmake PLATFORM_INCLUDE_FILES - ${pal_source_dir}/runtime_dependencies_tools.cmake + ${runtime_dependencies_tools} INCLUDE_DIRECTORIES PRIVATE Source/Builders diff --git a/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/CoreLights/DirectionalLightFeatureProcessorInterface.h b/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/CoreLights/DirectionalLightFeatureProcessorInterface.h index fa987a7156..6119585d9d 100644 --- a/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/CoreLights/DirectionalLightFeatureProcessorInterface.h +++ b/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/CoreLights/DirectionalLightFeatureProcessorInterface.h @@ -163,6 +163,9 @@ namespace AZ //! Reduces acne by biasing the shadowmap lookup along the geometric normal. virtual void SetNormalShadowBias(LightHandle handle, float normalShadowBias) = 0; + + //! Sets whether or not blending between shadow map cascades is enabled. + virtual void SetCascadeBlendingEnabled(LightHandle handle, bool enable) = 0; }; } // namespace Render } // namespace AZ diff --git a/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/LuxCoreBus.h b/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/LuxCoreBus.h deleted file mode 100644 index 1aa7778834..0000000000 --- a/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/LuxCoreBus.h +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - -#include -#include -#include - -namespace AZ -{ - namespace Render - { - enum LuxCoreTextureType - { - Default = 0, - IBL, - Albedo, - Normal - }; - - class LuxCoreRequests - : public EBusTraits - { - - public: - /// Overrides the default AZ::EBusTraits handler policy to allow one listener only. - static const EBusHandlerPolicy HandlerPolicy = EBusHandlerPolicy::Single; - virtual ~LuxCoreRequests() {} - virtual void SetCameraEntityID(AZ::EntityId id) = 0; - virtual void AddMesh(Data::Asset modelAsset) = 0; - virtual void AddMaterial(Data::Instance material) = 0; - virtual void AddTexture(Data::Instance texture, LuxCoreTextureType type) = 0; - virtual void AddObject(Data::Asset modelAsset, Data::InstanceId materialInstanceId) = 0; - virtual bool CheckTextureStatus() = 0; - virtual void RenderInLuxCore() = 0; - virtual void ClearLuxCore() = 0; - virtual void ClearObject() = 0; - }; - - typedef AZ::EBus LuxCoreRequestsBus; - - class LuxCoreNotification - : public EBusTraits - { - public: - static const EBusAddressPolicy AddressPolicy = EBusAddressPolicy::ById; - /** - * Overrides the default AZ::EBusTraits ID type so that AssetId are - * used to access the addresses of the bus. - */ - typedef Data::AssetId BusIdType; - virtual ~LuxCoreNotification() {} - - virtual void OnRenderPrepare() {} - }; - typedef AZ::EBus LuxCoreNotificationBus; - } -} diff --git a/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/LuxCoreTexturePass.h b/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/LuxCoreTexturePass.h deleted file mode 100644 index 63258a6570..0000000000 --- a/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/LuxCoreTexturePass.h +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - -#include - -#include -#include -#include - -#include - -namespace AZ -{ - namespace Render - { - class LuxCoreTexturePass final - : public RPI::ParentPass - { - public: - AZ_RTTI(LuxCoreTexturePass, "{A6CA80C0-63A6-4686-A627-B5D1DA04B627}", ParentPass); - AZ_CLASS_ALLOCATOR(LuxCoreTexturePass, SystemAllocator, 0); - - static RPI::Ptr Create(const RPI::PassDescriptor& descriptor); - - LuxCoreTexturePass(const RPI::PassDescriptor& descriptor); - ~LuxCoreTexturePass(); - - void SetSourceTexture(Data::Instance image, RHI::Format format); - void SetIsNormalTexture(bool isNormal); - void SetReadbackCallback(RPI::AttachmentReadback::CallbackFunction callbackFunciton); - - protected: - // Pass behavior overrides - void CreateChildPassesInternal() final; - void BuildInternal() final; - void FrameBeginInternal(FramePrepareParams params) final; - - private: - - RPI::Ptr m_renderTargetPass = nullptr; - AZStd::shared_ptr m_readback = nullptr; - bool m_attachmentReadbackComplete = false; - }; - } -} diff --git a/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/RenderTexturePass.h b/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/RenderTexturePass.h deleted file mode 100644 index 8389fe33a7..0000000000 --- a/Gems/Atom/Feature/Common/Code/Include/Atom/Feature/LuxCore/RenderTexturePass.h +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - -#include - -namespace AZ -{ - namespace Render - { - /* - * A simple pass to render a texture to an attachment render target - * The attachment size and format will be configure as the same as the input texture - */ - class RenderTexturePass final - : public RPI::FullscreenTrianglePass - { - - AZ_RPI_PASS(RenderTexturePass); - - public: - AZ_RTTI(RenderTexturePass, "{476A4E41-08D7-456C-B324-E0493A321FE7}", FullscreenTrianglePass); - AZ_CLASS_ALLOCATOR(RenderTexturePass, SystemAllocator, 0); - virtual ~RenderTexturePass(); - - static RPI::Ptr Create(const RPI::PassDescriptor& descriptor); - - // Set the source image - void SetPassSrgImage(AZ::Data::Instance image, RHI::Format format); - - RHI::AttachmentId GetRenderTargetId(); - - void InitShaderVariant(bool isNormal); - - protected: - RenderTexturePass(const RPI::PassDescriptor& descriptor); - - private: - - void BuildInternal() override; - void FrameBeginInternal(FramePrepareParams params) override; - - void UpdataAttachment(); - - RHI::ShaderInputImageIndex m_textureIndex; - RHI::Size m_attachmentSize; - RHI::Format m_attachmentFormat; - }; - } -} diff --git a/Gems/Atom/Feature/Common/Code/Source/CommonSystemComponent.cpp b/Gems/Atom/Feature/Common/Code/Source/CommonSystemComponent.cpp index dc5d1a5c12..a06defff08 100644 --- a/Gems/Atom/Feature/Common/Code/Source/CommonSystemComponent.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/CommonSystemComponent.cpp @@ -74,11 +74,6 @@ #include -#if AZ_TRAIT_LUXCORE_SUPPORTED -#include -#include -#endif - #include #include @@ -221,11 +216,6 @@ namespace AZ passSystem->AddPassCreator(Name("DisplayMapperFullScreenPass"), &DisplayMapperFullScreenPass::Create); passSystem->AddPassCreator(Name("OutputTransformPass"), &OutputTransformPass::Create); passSystem->AddPassCreator(Name("EyeAdaptationPass"), &EyeAdaptationPass::Create); - // Add RenderTexture and LuxCoreTexture pass -#if AZ_TRAIT_LUXCORE_SUPPORTED - passSystem->AddPassCreator(Name("RenderTexturePass"), &RenderTexturePass::Create); - passSystem->AddPassCreator(Name("LuxCoreTexturePass"), &LuxCoreTexturePass::Create); -#endif passSystem->AddPassCreator(Name("ImGuiPass"), &ImGuiPass::Create); passSystem->AddPassCreator(Name("LightCullingPass"), &LightCullingPass::Create); passSystem->AddPassCreator(Name("LightCullingRemapPass"), &LightCullingRemap::Create); diff --git a/Gems/Atom/Feature/Common/Code/Source/CommonSystemComponent.h b/Gems/Atom/Feature/Common/Code/Source/CommonSystemComponent.h index b12ad3459c..4838cc3d3d 100644 --- a/Gems/Atom/Feature/Common/Code/Source/CommonSystemComponent.h +++ b/Gems/Atom/Feature/Common/Code/Source/CommonSystemComponent.h @@ -12,10 +12,6 @@ #include -#if AZ_TRAIT_LUXCORE_SUPPORTED -#include "LuxCore/LuxCoreRenderer.h" -#endif - namespace AZ { namespace Render @@ -50,11 +46,6 @@ namespace AZ RPI::PassSystemInterface::OnReadyLoadTemplatesEvent::Handler m_loadTemplatesHandler; AZStd::unique_ptr m_modelReloaderSystem; - -#if AZ_TRAIT_LUXCORE_SUPPORTED - // LuxCore - LuxCoreRenderer m_luxCore; -#endif }; } // namespace Render } // namespace AZ diff --git a/Gems/Atom/Feature/Common/Code/Source/CoreLights/DirectionalLightFeatureProcessor.cpp b/Gems/Atom/Feature/Common/Code/Source/CoreLights/DirectionalLightFeatureProcessor.cpp index ee60ff412a..5cf65adcee 100644 --- a/Gems/Atom/Feature/Common/Code/Source/CoreLights/DirectionalLightFeatureProcessor.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/CoreLights/DirectionalLightFeatureProcessor.cpp @@ -198,13 +198,15 @@ namespace AZ if (m_shadowingLightHandle.IsValid()) { - uint32_t shadowFilterMethod = m_shadowData.at(nullptr).GetData(m_shadowingLightHandle.GetIndex()).m_shadowFilterMethod; + const uint32_t shadowFilterMethod = m_shadowData.at(nullptr).GetData(m_shadowingLightHandle.GetIndex()).m_shadowFilterMethod; RPI::ShaderSystemInterface::Get()->SetGlobalShaderOption(m_directionalShadowFilteringMethodName, AZ::RPI::ShaderOptionValue{shadowFilterMethod}); - RPI::ShaderSystemInterface::Get()->SetGlobalShaderOption(m_directionalShadowReceiverPlaneBiasEnableName, AZ::RPI::ShaderOptionValue{ m_shadowProperties.GetData(m_shadowingLightHandle.GetIndex()).m_isReceiverPlaneBiasEnabled }); + RPI::ShaderSystemInterface::Get()->SetGlobalShaderOption(m_directionalShadowReceiverPlaneBiasEnableName, AZ::RPI::ShaderOptionValue{ m_shadowProperties.GetData(m_shadowingLightHandle.GetIndex()).m_isReceiverPlaneBiasEnabled }); const uint32_t cascadeCount = m_shadowData.at(nullptr).GetData(m_shadowingLightHandle.GetIndex()).m_cascadeCount; - ShadowProperty& property = m_shadowProperties.GetData(m_shadowingLightHandle.GetIndex()); + RPI::ShaderSystemInterface::Get()->SetGlobalShaderOption(m_BlendBetweenCascadesEnableName, AZ::RPI::ShaderOptionValue{cascadeCount > 1 && m_shadowProperties.GetData(m_shadowingLightHandle.GetIndex()).m_blendBetwenCascades }); + + ShadowProperty& property = m_shadowProperties.GetData(m_shadowingLightHandle.GetIndex()); bool segmentsNeedUpdate = property.m_segments.empty(); for (const auto& passIt : m_cascadedShadowmapsPasses) { @@ -577,6 +579,11 @@ namespace AZ m_shadowProperties.GetData(handle.GetIndex()).m_isReceiverPlaneBiasEnabled = enable; } + void DirectionalLightFeatureProcessor::SetCascadeBlendingEnabled(LightHandle handle, bool enable) + { + m_shadowProperties.GetData(handle.GetIndex()).m_blendBetwenCascades = enable; + } + void DirectionalLightFeatureProcessor::SetShadowBias(LightHandle handle, float bias) { for (auto& it : m_shadowData) diff --git a/Gems/Atom/Feature/Common/Code/Source/CoreLights/DirectionalLightFeatureProcessor.h b/Gems/Atom/Feature/Common/Code/Source/CoreLights/DirectionalLightFeatureProcessor.h index c206a5097f..83ab7cb15b 100644 --- a/Gems/Atom/Feature/Common/Code/Source/CoreLights/DirectionalLightFeatureProcessor.h +++ b/Gems/Atom/Feature/Common/Code/Source/CoreLights/DirectionalLightFeatureProcessor.h @@ -176,6 +176,8 @@ namespace AZ // If true, this will reduce the shadow acne introduced by large pcf kernels by estimating the angle of the triangle being shaded // with the ddx/ddy functions. bool m_isReceiverPlaneBiasEnabled = true; + + bool m_blendBetwenCascades = false; }; static void Reflect(ReflectContext* context); @@ -215,6 +217,7 @@ namespace AZ void SetShadowFilterMethod(LightHandle handle, ShadowFilterMethod method) override; void SetFilteringSampleCount(LightHandle handle, uint16_t count) override; void SetShadowReceiverPlaneBiasEnabled(LightHandle handle, bool enable) override; + void SetCascadeBlendingEnabled(LightHandle handle, bool enable) override; void SetShadowBias(LightHandle handle, float bias) override; void SetNormalShadowBias(LightHandle handle, float normalShadowBias) override; @@ -367,6 +370,7 @@ namespace AZ Name m_lightTypeName = Name("directional"); Name m_directionalShadowFilteringMethodName = Name("o_directional_shadow_filtering_method"); Name m_directionalShadowReceiverPlaneBiasEnableName = Name("o_directional_shadow_receiver_plane_bias_enable"); + Name m_BlendBetweenCascadesEnableName = Name("o_blend_between_cascades_enable"); static constexpr const char* FeatureProcessorName = "DirectionalLightFeatureProcessor"; }; } // namespace Render diff --git a/Gems/Atom/Feature/Common/Code/Source/CoreLights/EsmShadowmapsPass.cpp b/Gems/Atom/Feature/Common/Code/Source/CoreLights/EsmShadowmapsPass.cpp index b92d538fb5..553133aef7 100644 --- a/Gems/Atom/Feature/Common/Code/Source/CoreLights/EsmShadowmapsPass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/CoreLights/EsmShadowmapsPass.cpp @@ -101,6 +101,13 @@ namespace AZ void EsmShadowmapsPass::UpdateChildren() { const RPI::PassAttachmentBinding& inputBinding = GetInputBinding(0); + + if (!inputBinding.m_attachment) + { + AZ_Assert(false, "[EsmShadowmapsPass %s] requires an input attachment", GetPathName().GetCStr()); + return; + } + AZ_Assert(inputBinding.m_attachment->m_descriptor.m_type == RHI::AttachmentType::Image, "[EsmShadowmapsPass %s] input attachment requires an image attachment", GetPathName().GetCStr()); m_shadowmapImageSize = inputBinding.m_attachment->m_descriptor.m_image.m_size; m_shadowmapArraySize = inputBinding.m_attachment->m_descriptor.m_image.m_arraySize; diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGrid.cpp b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGrid.cpp index de49c4ff50..a72d90fc94 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGrid.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGrid.cpp @@ -102,8 +102,17 @@ namespace AZ void DiffuseProbeGrid::SetProbeSpacing(const AZ::Vector3& probeSpacing) { + // remove previous spacing from the render extents + m_renderExtents -= m_probeSpacing; + + // update probe spacing m_probeSpacing = probeSpacing; + // expand the extents by one probe spacing unit in order to blend properly around the edges of the volume + m_renderExtents += m_probeSpacing; + + m_obbWs = Obb::CreateFromPositionRotationAndHalfLengths(m_transform.GetTranslation(), m_transform.GetRotation(), m_renderExtents / 2.0f); + // recompute the number of probes since the spacing changed UpdateProbeCount(); @@ -128,7 +137,8 @@ namespace AZ void DiffuseProbeGrid::SetTransform(const AZ::Transform& transform) { m_transform = transform; - m_obbWs = Obb::CreateFromPositionRotationAndHalfLengths(m_transform.GetTranslation(), m_transform.GetRotation(), m_extents / 2.0f); + + m_obbWs = Obb::CreateFromPositionRotationAndHalfLengths(m_transform.GetTranslation(), m_transform.GetRotation(), m_renderExtents / 2.0f); // probes need to be relocated since the grid position changed m_remainingRelocationIterations = DefaultNumRelocationIterations; @@ -144,11 +154,15 @@ namespace AZ void DiffuseProbeGrid::SetExtents(const AZ::Vector3& extents) { m_extents = extents; - m_obbWs = Obb::CreateFromPositionRotationAndHalfLengths(m_transform.GetTranslation(), m_transform.GetRotation(), m_extents / 2.0f); // recompute the number of probes since the extents changed UpdateProbeCount(); + // expand the extents by one probe spacing unit in order to blend properly around the edges of the volume + m_renderExtents = m_extents + m_probeSpacing; + + m_obbWs = Obb::CreateFromPositionRotationAndHalfLengths(m_transform.GetTranslation(), m_transform.GetRotation(), m_renderExtents / 2.0f); + // probes need to be relocated since the grid extents changed m_remainingRelocationIterations = DefaultNumRelocationIterations; @@ -700,11 +714,11 @@ namespace AZ RHI::ShaderInputImageIndex imageIndex; constantIndex = srgLayout->FindShaderInputConstantIndex(Name("m_modelToWorld")); - AZ::Matrix3x4 modelToWorld = AZ::Matrix3x4::CreateFromTransform(m_transform) * AZ::Matrix3x4::CreateScale(m_extents); + AZ::Matrix3x4 modelToWorld = AZ::Matrix3x4::CreateFromTransform(m_transform) * AZ::Matrix3x4::CreateScale(m_renderExtents); m_renderObjectSrg->SetConstant(constantIndex, modelToWorld); constantIndex = srgLayout->FindShaderInputConstantIndex(Name("m_modelToWorldInverse")); - AZ::Matrix3x4 modelToWorldInverse = AZ::Matrix3x4::CreateFromTransform(m_transform).GetInverseFull(); + AZ::Matrix3x4 modelToWorldInverse = modelToWorld.GetInverseFull(); m_renderObjectSrg->SetConstant(constantIndex, modelToWorldInverse); constantIndex = srgLayout->FindShaderInputConstantIndex(Name("m_obbHalfLengths")); diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGrid.h b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGrid.h index 6c3017fe33..a828fe4b96 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGrid.h +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGrid.h @@ -183,11 +183,14 @@ namespace AZ // extents of the probe grid AZ::Vector3 m_extents = AZ::Vector3(0.0f, 0.0f, 0.0f); + // expanded extents for rendering the volume + AZ::Vector3 m_renderExtents = AZ::Vector3(0.0f, 0.0f, 0.0f); + // probe grid OBB (world space), built from transform and extents AZ::Obb m_obbWs; // per-axis spacing of probes in the grid - AZ::Vector3 m_probeSpacing; + AZ::Vector3 m_probeSpacing = AZ::Vector3(0.0f, 0.0f, 0.0f); // per-axis number of probes in the grid uint32_t m_probeCountX = 0; diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBlendDistancePass.cpp b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBlendDistancePass.cpp index 0cdc4d14b1..702e784c86 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBlendDistancePass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBlendDistancePass.cpp @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include @@ -30,7 +31,15 @@ namespace AZ DiffuseProbeGridBlendDistancePass::DiffuseProbeGridBlendDistancePass(const RPI::PassDescriptor& descriptor) : RPI::RenderPass(descriptor) { - LoadShader(); + if (!AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED) + { + // GI is not supported on this platform + SetEnabled(false); + } + else + { + LoadShader(); + } } void DiffuseProbeGridBlendDistancePass::LoadShader() diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBlendIrradiancePass.cpp b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBlendIrradiancePass.cpp index e0a4f1ae42..7609e27b66 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBlendIrradiancePass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBlendIrradiancePass.cpp @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include @@ -30,7 +31,15 @@ namespace AZ DiffuseProbeGridBlendIrradiancePass::DiffuseProbeGridBlendIrradiancePass(const RPI::PassDescriptor& descriptor) : RPI::RenderPass(descriptor) { - LoadShader(); + if (!AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED) + { + // GI is not supported on this platform + SetEnabled(false); + } + else + { + LoadShader(); + } } void DiffuseProbeGridBlendIrradiancePass::LoadShader() diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBorderUpdatePass.cpp b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBorderUpdatePass.cpp index 6c72f904b9..c4fcb49c17 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBorderUpdatePass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridBorderUpdatePass.cpp @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include @@ -30,17 +31,25 @@ namespace AZ DiffuseProbeGridBorderUpdatePass::DiffuseProbeGridBorderUpdatePass(const RPI::PassDescriptor& descriptor) : RPI::RenderPass(descriptor) { - LoadShader("Shaders/DiffuseGlobalIllumination/DiffuseProbeGridBorderUpdateRow.azshader", - m_rowShader, - m_rowPipelineState, - m_rowSrgLayout, - m_rowDispatchArgs); - - LoadShader("Shaders/DiffuseGlobalIllumination/DiffuseProbeGridBorderUpdateColumn.azshader", - m_columnShader, - m_columnPipelineState, - m_columnSrgLayout, - m_columnDispatchArgs); + if (!AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED) + { + // GI is not supported on this platform + SetEnabled(false); + } + else + { + LoadShader("Shaders/DiffuseGlobalIllumination/DiffuseProbeGridBorderUpdateRow.azshader", + m_rowShader, + m_rowPipelineState, + m_rowSrgLayout, + m_rowDispatchArgs); + + LoadShader("Shaders/DiffuseGlobalIllumination/DiffuseProbeGridBorderUpdateColumn.azshader", + m_columnShader, + m_columnPipelineState, + m_columnSrgLayout, + m_columnDispatchArgs); + } } void DiffuseProbeGridBorderUpdatePass::LoadShader(AZStd::string shaderFilePath, diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridClassificationPass.cpp b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridClassificationPass.cpp index a6e5fd03ff..7394b1ccfb 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridClassificationPass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridClassificationPass.cpp @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -34,7 +35,15 @@ namespace AZ DiffuseProbeGridClassificationPass::DiffuseProbeGridClassificationPass(const RPI::PassDescriptor& descriptor) : RPI::RenderPass(descriptor) { - LoadShader(); + if (!AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED) + { + // GI is not supported on this platform + SetEnabled(false); + } + else + { + LoadShader(); + } } void DiffuseProbeGridClassificationPass::LoadShader() diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRayTracingPass.cpp b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRayTracingPass.cpp index abee3693f8..df551e7f42 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRayTracingPass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRayTracingPass.cpp @@ -19,6 +19,7 @@ #include #include #include +#include #include #include #include @@ -38,9 +39,9 @@ namespace AZ : RPI::RenderPass(descriptor) { RHI::Ptr device = RHI::RHISystemInterface::Get()->GetDevice(); - if (device->GetFeatures().m_rayTracing == false) + if (device->GetFeatures().m_rayTracing == false || !AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED) { - // raytracing is not supported on this platform + // raytracing or GI is not supported on this platform SetEnabled(false); } } diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRelocationPass.cpp b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRelocationPass.cpp index e35686d343..fd23dadf6f 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRelocationPass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRelocationPass.cpp @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -34,7 +35,15 @@ namespace AZ DiffuseProbeGridRelocationPass::DiffuseProbeGridRelocationPass(const RPI::PassDescriptor& descriptor) : RPI::RenderPass(descriptor) { - LoadShader(); + if (!AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED) + { + // GI is not supported on this platform + SetEnabled(false); + } + else + { + LoadShader(); + } } void DiffuseProbeGridRelocationPass::LoadShader() diff --git a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRenderPass.cpp b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRenderPass.cpp index fb674673fa..f444c0c6ba 100644 --- a/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRenderPass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/DiffuseGlobalIllumination/DiffuseProbeGridRenderPass.cpp @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include @@ -27,6 +28,13 @@ namespace AZ DiffuseProbeGridRenderPass::DiffuseProbeGridRenderPass(const RPI::PassDescriptor& descriptor) : Base(descriptor) { + if (!AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED) + { + // GI is not supported on this platform + SetEnabled(false); + return; + } + // create the shader resource group // Note: the shader may not be available on all platforms AZStd::string shaderFilePath = "Shaders/DiffuseGlobalIllumination/DiffuseProbeGridRender.azshader"; diff --git a/Gems/Atom/Feature/Common/Code/Source/ImGui/ImGuiPass.cpp b/Gems/Atom/Feature/Common/Code/Source/ImGui/ImGuiPass.cpp index 5dcb0dc2bb..8ba92a3317 100644 --- a/Gems/Atom/Feature/Common/Code/Source/ImGui/ImGuiPass.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/ImGui/ImGuiPass.cpp @@ -27,6 +27,7 @@ #include #include +#include #include namespace AZ @@ -460,6 +461,9 @@ namespace AZ { auto imguiContextScope = ImguiContextScope(m_imguiContext); auto& io = ImGui::GetIO(); + #if defined(AZ_TRAIT_IMGUI_INI_FILENAME) + io.IniFilename = AZ_TRAIT_IMGUI_INI_FILENAME; + #endif // ImGui IO Setup { diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMaterial.cpp b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMaterial.cpp deleted file mode 100644 index e454a1c7ba..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMaterial.cpp +++ /dev/null @@ -1,139 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include "LuxCoreMaterial.h" -#include - -#include -#include - -namespace AZ -{ - namespace Render - { - LuxCoreMaterial::LuxCoreMaterial(const AZ::Data::Instance& material) - { - Init(material); - } - - LuxCoreMaterial::LuxCoreMaterial(const LuxCoreMaterial &material) - { - Init(material.m_material); - } - - LuxCoreMaterial::~LuxCoreMaterial() - { - if (m_material) - { - m_material = nullptr; - } - } - - void LuxCoreMaterial::Init(const AZ::Data::Instance& material) - { - m_material = material; - m_luxCoreMaterialName = "scene.materials." + m_material->GetId().ToString(); - m_luxCoreMaterial = m_luxCoreMaterial << luxrays::Property(std::string(m_luxCoreMaterialName.data()) + ".type")("disney"); - - ParseProperty(s_pbrColorGroup, ".basecolor"); - ParseProperty(s_pbrMetallicGroup, ".metallic"); - ParseProperty(s_pbrRoughnessGroup, ".roughness"); - ParseProperty(s_pbrSpecularGroup, ".specular"); - ParseProperty(s_pbrNormalGroup, ".bumptex"); - } - - bool LuxCoreMaterial::ParseTexture(const char* group, AZStd::string propertyName) - { - AZ::RPI::MaterialPropertyIndex propertyIndex; - - propertyIndex = m_material->FindPropertyIndex(MakePbrPropertyName(group, s_pbrUseTextureProperty)); - bool useTexture = m_material->GetPropertyValue(propertyIndex); - - if (useTexture) - { - propertyIndex = m_material->FindPropertyIndex(MakePbrPropertyName(group, s_pbrTextureProperty)); - Data::Instance texture = m_material->GetPropertyValue>(propertyIndex); - - if (texture) - { - if (group == s_pbrNormalGroup) - { - AZ::Render::LuxCoreRequestsBus::Broadcast(&AZ::Render::LuxCoreRequestsBus::Events::AddTexture, texture, LuxCoreTextureType::Normal); - } - else if (group == s_pbrColorGroup) - { - AZ::Render::LuxCoreRequestsBus::Broadcast(&AZ::Render::LuxCoreRequestsBus::Events::AddTexture, texture, LuxCoreTextureType::Albedo); - } - else - { - AZ::Render::LuxCoreRequestsBus::Broadcast(&AZ::Render::LuxCoreRequestsBus::Events::AddTexture, texture, LuxCoreTextureType::Default); - } - - AZStd::string materialProperty = m_luxCoreMaterialName + propertyName; - m_luxCoreMaterial = m_luxCoreMaterial << luxrays::Property(std::string(materialProperty.data()))(std::string(texture->GetAssetId().ToString().data())); - return true; - } - } - - return false; - } - - AZ::Name LuxCoreMaterial::MakePbrPropertyName(const char* groupName, const char* propertyName) const - { - return AZ::Name{AZStd::string::format("%s.%s", groupName, propertyName)}; - } - - void LuxCoreMaterial::ParseProperty(const char* group, AZStd::string propertyName) - { - if (!ParseTexture(group, propertyName)) - { - if (group == s_pbrNormalGroup) - { - // Normal should always be texture - return; - } - else if (group == s_pbrColorGroup) - { - AZ::RPI::MaterialPropertyIndex propertyIndex; - propertyIndex = m_material->FindPropertyIndex(MakePbrPropertyName(s_pbrColorGroup, s_pbrColorProperty)); - Color color = m_material->GetPropertyValue(propertyIndex); - propertyIndex = m_material->FindPropertyIndex(MakePbrPropertyName(s_pbrColorGroup, s_pbrFactorProperty)); - float factor = m_material->GetPropertyValue(propertyIndex); - - AZStd::string materialProperty = m_luxCoreMaterialName + propertyName; - m_luxCoreMaterial = m_luxCoreMaterial << luxrays::Property(std::string(materialProperty.data()))(float(color.GetR())* factor, float(color.GetG())*factor, float(color.GetB())*factor); - } - else - { - AZ::RPI::MaterialPropertyIndex propertyIndex; - propertyIndex = m_material->FindPropertyIndex(MakePbrPropertyName(group, s_pbrFactorProperty)); - float factor = m_material->GetPropertyValue(propertyIndex); - - AZStd::string materialProperty = m_luxCoreMaterialName + propertyName; - m_luxCoreMaterial = m_luxCoreMaterial << luxrays::Property(std::string(materialProperty.data()))(factor); - } - } - } - - luxrays::Properties LuxCoreMaterial::GetLuxCoreMaterialProperties() - { - return m_luxCoreMaterial; - } - - AZ::Data::InstanceId LuxCoreMaterial::GetMaterialId() - { - return m_material->GetId(); - } - } -} - -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMaterial.h b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMaterial.h deleted file mode 100644 index 86c095f7fd..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMaterial.h +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include -#include "LuxCoreTexture.h" - -#include - -namespace AZ -{ - namespace Render - { - // Manage mapping between Atom PBR material and LuxCore Disney material - class LuxCoreMaterial final - { - public: - LuxCoreMaterial() = default; - LuxCoreMaterial(const AZ::Data::Instance& material); - LuxCoreMaterial(const LuxCoreMaterial &material); - ~LuxCoreMaterial(); - - luxrays::Properties GetLuxCoreMaterialProperties(); - AZ::Data::InstanceId GetMaterialId(); - private: - - static constexpr const char* s_pbrColorGroup = "baseColor"; - static constexpr const char* s_pbrMetallicGroup = "metallic"; - static constexpr const char* s_pbrRoughnessGroup = "roughness"; - static constexpr const char* s_pbrSpecularGroup = "specularF0"; - static constexpr const char* s_pbrNormalGroup = "normal"; - static constexpr const char* s_pbrOpacityGroup = "opacity"; - - static constexpr const char* s_pbrColorProperty = "color"; - static constexpr const char* s_pbrFactorProperty = "factor"; - static constexpr const char* s_pbrUseTextureProperty = "useTexture"; - static constexpr const char* s_pbrTextureProperty = "textureMap"; - - void ParseProperty(const char* group, AZStd::string propertyName); - bool ParseTexture(const char* group, AZStd::string propertyName); - AZ::Name MakePbrPropertyName(const char* groupName, const char* propertyName) const; - - void Init(const AZ::Data::Instance& material); - - AZStd::string m_luxCoreMaterialName; - luxrays::Properties m_luxCoreMaterial; - - AZ::Data::Instance m_material = nullptr; - }; - } -} -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMesh.cpp b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMesh.cpp deleted file mode 100644 index 34272f8cbf..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMesh.cpp +++ /dev/null @@ -1,135 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include "LuxCoreMesh.h" -#include - -namespace AZ -{ - namespace Render - { - LuxCoreMesh::LuxCoreMesh(AZ::Data::Asset modelAsset) - { - Init(modelAsset); - } - - LuxCoreMesh::LuxCoreMesh(const LuxCoreMesh &model) - { - Init(model.m_modelAsset); - } - - LuxCoreMesh::~LuxCoreMesh() - { - if (m_position) - { - delete m_position; - m_position = nullptr; - } - - if (m_normal) - { - delete m_normal; - m_normal = nullptr; - } - - if (m_uv) - { - delete m_uv; - m_uv = nullptr; - } - - if (m_index) - { - delete m_index; - m_index = nullptr; - } - - if (m_modelAsset) - { - m_modelAsset.Reset(); - } - } - - void LuxCoreMesh::Init(AZ::Data::Asset modelAsset) - { - m_modelAsset = modelAsset; - // [TODO ATOM-3547] Multiple meshes handling - AZ::RPI::ModelLodAsset::Mesh mesh = m_modelAsset->GetLodAssets()[0]->GetMeshes()[0]; - - // index data - AZStd::array_view indexBuffer = mesh.GetIndexBufferAssetView().GetBufferAsset()->GetBuffer(); - m_index = luxcore::Scene::AllocTrianglesBuffer(mesh.GetIndexCount() / 3); - memcpy(m_index, indexBuffer.data(), indexBuffer.size()); - - // vertices data - for (AZ::RPI::ModelLodAsset::Mesh::StreamBufferInfo streamBufferInfo : mesh.GetStreamBufferInfoList()) - { - AZStd::array_view dataBuffer = streamBufferInfo.m_bufferAssetView.GetBufferAsset()->GetBuffer(); - - if (streamBufferInfo.m_semantic == RHI::ShaderSemantic{ "POSITION" }) - { - m_position = luxcore::Scene::AllocVerticesBuffer(mesh.GetVertexCount()); - memcpy(m_position, dataBuffer.data(), dataBuffer.size()); - } - else if (streamBufferInfo.m_semantic == RHI::ShaderSemantic{ "NORMAL" }) - { - m_normal = new float[mesh.GetVertexCount() * 3]; - memcpy(m_normal, dataBuffer.data(), dataBuffer.size()); - } - else if (streamBufferInfo.m_semantic == RHI::ShaderSemantic{ "UV", 0 }) - { - m_uv = new float[mesh.GetVertexCount() * 2]; - memcpy(m_uv, dataBuffer.data(), dataBuffer.size()); - } - } - } - - - uint32_t LuxCoreMesh::GetVertexCount() - { - // [TODO ATOM-3547] Multiple meshes handling - return m_modelAsset->GetLodAssets()[0]->GetMeshes()[0].GetVertexCount(); - } - - uint32_t LuxCoreMesh::GetTriangleCount() - { - // [TODO ATOM-3547] Multiple meshes handling - return (m_modelAsset->GetLodAssets()[0]->GetMeshes()[0].GetIndexCount() / 3); - } - - AZ::Data::AssetId LuxCoreMesh::GetMeshId() - { - return m_modelAsset->GetId(); - } - - const float* LuxCoreMesh::GetPositionData() - { - return m_position; - } - - const float* LuxCoreMesh::GetNormalData() - { - return m_normal; - } - - const float* LuxCoreMesh::GetUVData() - { - return m_uv; - } - - const unsigned int* LuxCoreMesh::GetIndexData() - { - return m_index; - } - } -} -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMesh.h b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMesh.h deleted file mode 100644 index 597049f849..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreMesh.h +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include - -namespace AZ -{ - namespace Render - { - // Extract vertex and index data from source model - class LuxCoreMesh final - { - public: - LuxCoreMesh() = default; - LuxCoreMesh(AZ::Data::Asset modelAsset); - LuxCoreMesh(const LuxCoreMesh &mesh); - ~LuxCoreMesh(); - - AZ::Data::AssetId GetMeshId(); - const float* GetPositionData(); - const float* GetNormalData(); - const float* GetUVData(); - const unsigned int* GetIndexData(); - - uint32_t GetVertexCount(); - uint32_t GetTriangleCount(); - - private: - void Init(AZ::Data::Asset modelAsset); - - float* m_position = nullptr; - float* m_normal = nullptr; - float* m_uv = nullptr; - unsigned int* m_index = nullptr; - AZ::Data::Asset m_modelAsset; - }; - } -} -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreObject.cpp b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreObject.cpp deleted file mode 100644 index ddeb61e394..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreObject.cpp +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include "LuxCoreObject.h" -#include - -namespace AZ -{ - namespace Render - { - LuxCoreObject::LuxCoreObject(AZStd::string modelAssetId, AZStd::string materialInstanceId) - { - Init(modelAssetId, materialInstanceId); - } - - LuxCoreObject::LuxCoreObject(const LuxCoreObject &object) - { - Init(object.m_modelAssetId, object.m_materialInstanceId); - } - - LuxCoreObject::~LuxCoreObject() - { - } - - luxrays::Properties LuxCoreObject::GetLuxCoreObjectProperties() - { - return m_luxCoreObject; - } - - void LuxCoreObject::Init(AZStd::string modelAssetId, AZStd::string materialInstanceId) - { - m_modelAssetId = modelAssetId; - m_materialInstanceId = materialInstanceId; - - static std::atomic_int ObjectId { 0 }; - const int localObjectId = ObjectId++; - - m_luxCoreObjectName = "scene.objects." + AZStd::to_string(localObjectId); - AZStd::string shapePropertyName = m_luxCoreObjectName + ".shape"; - AZStd::string materialPropertyName = m_luxCoreObjectName + ".material"; - - m_luxCoreObject = m_luxCoreObject << luxrays::Property(std::string(shapePropertyName.data()))(std::string(modelAssetId.data())); - m_luxCoreObject = m_luxCoreObject << luxrays::Property(std::string(materialPropertyName.data()))(std::string(materialInstanceId.data())); - } - }; -}; - -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreObject.h b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreObject.h deleted file mode 100644 index 6529b0487b..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreObject.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include -#include - -namespace AZ -{ - namespace Render - { - // Object holds mesh and material in LuxCore - class LuxCoreObject final - { - public: - LuxCoreObject(AZStd::string modelAssetId, AZStd::string materialInstanceId); - LuxCoreObject(const LuxCoreObject &object); - ~LuxCoreObject(); - - luxrays::Properties GetLuxCoreObjectProperties(); - - private: - - void Init(AZStd::string modelAssetId, AZStd::string materialInstanceId); - AZStd::string m_luxCoreObjectName; - luxrays::Properties m_luxCoreObject; - - AZStd::string m_modelAssetId; - AZStd::string m_materialInstanceId; - }; - }; -}; -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreRenderer.cpp b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreRenderer.cpp deleted file mode 100644 index ef3f33d1c3..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreRenderer.cpp +++ /dev/null @@ -1,308 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include "LuxCoreRenderer.h" - -#include -#include -#include -#include -#include - -#include - -namespace LuxCoreUI -{ - void LaunchLuxCoreUI(const AZStd::string& luxCoreExeFullPath, const AZStd::string& commandLine); -} - -namespace AZ -{ - namespace Render - { - LuxCoreRenderer::LuxCoreRenderer() - { - LuxCoreRequestsBus::Handler::BusConnect(); - } - - LuxCoreRenderer::~LuxCoreRenderer() - { - LuxCoreRequestsBus::Handler::BusDisconnect(); - ClearLuxCore(); - } - - void LuxCoreRenderer::SetCameraEntityID(AZ::EntityId id) - { - m_cameraEntityId = id; - } - - void LuxCoreRenderer::AddMesh(Data::Asset modelAsset) - { - AZStd::string meshId = modelAsset->GetId().ToString(); - m_meshs.emplace(AZStd::piecewise_construct_t{}, - AZStd::forward_as_tuple(meshId), - AZStd::forward_as_tuple(modelAsset)); - } - - void LuxCoreRenderer::AddMaterial(Data::Instance material) - { - AZStd::string materialId = material->GetId().ToString(); - m_materials.emplace(AZStd::piecewise_construct_t{}, - AZStd::forward_as_tuple(materialId), - AZStd::forward_as_tuple(material)); - } - - void LuxCoreRenderer::AddTexture(Data::Instance image, LuxCoreTextureType type) - { - AZStd::string textureId = image->GetAssetId().ToString(); - m_textures.emplace(AZStd::piecewise_construct_t{}, - AZStd::forward_as_tuple(textureId), - AZStd::forward_as_tuple(image, type)); - } - - void LuxCoreRenderer::AddObject(AZ::Data::Asset modelAsset, AZ::Data::InstanceId materialInstanceId) - { - m_objects.emplace_back(modelAsset->GetId().ToString(), materialInstanceId.ToString()); - } - - bool LuxCoreRenderer::CheckTextureStatus() - { - for (auto it = m_textures.begin(); it != m_textures.end(); ++it) - { - if (!it->second.IsTextureReady()) - { - return false; - } - } - return true; - } - - void LuxCoreRenderer::ClearLuxCore() - { - m_meshs.clear(); - m_materials.clear(); - m_textures.clear(); - m_objects.clear(); - } - - void LuxCoreRenderer::ClearObject() - { - m_objects.clear(); - } - - void LuxCoreRenderer::RenderInLuxCore() - { - luxcore::Init(); - luxcore::Scene *luxCoreScene = luxcore::Scene::Create(); - - const char* folderName = "luxcoredata"; - if (!AZ::IO::FileIOBase::GetInstance()->Exists(folderName)) - { - AZ::IO::FileIOBase::GetInstance()->CreatePath(folderName); - } - - char resolvedPath[1024]; - AZ::IO::FileIOBase::GetInstance()->ResolvePath(folderName, resolvedPath, 1024); - - // Camera transform - if (!m_cameraEntityId.IsValid()) - { - AZ_Assert(false, "Please set camera entity id"); - return; - } - - AZ::Transform cameraTransform = AZ::Transform::CreateIdentity(); - AZ::Vector4 cameraUp, cameraFwd, cameraOrig, cameraTarget; - AZ::TransformBus::EventResult(cameraTransform, m_cameraEntityId, &AZ::TransformBus::Events::GetWorldTM); - - const AZ::Matrix4x4 rotationMatrix = AZ::Matrix4x4::CreateFromTransform(cameraTransform); - - cameraFwd = rotationMatrix.GetColumn(1); - cameraUp = rotationMatrix.GetColumn(2); - cameraOrig = rotationMatrix.GetColumn(3); - cameraTarget = cameraOrig + cameraFwd; - - // Camera parameter - float nearClip, farClip, fieldOfView; - Camera::CameraRequestBus::EventResult(fieldOfView, m_cameraEntityId, &Camera::CameraRequestBus::Events::GetFovDegrees); - Camera::CameraRequestBus::EventResult(nearClip, m_cameraEntityId, &Camera::CameraRequestBus::Events::GetNearClipDistance); - Camera::CameraRequestBus::EventResult(farClip, m_cameraEntityId, &Camera::CameraRequestBus::Events::GetFarClipDistance); - - // Set Camera - luxCoreScene->Parse( - luxrays::Property("scene.camera.lookat.orig")((float)cameraOrig.GetX(), (float)cameraOrig.GetY(), (float)cameraOrig.GetZ()) << - luxrays::Property("scene.camera.lookat.target")((float)cameraTarget.GetX(), (float)cameraTarget.GetY(), (float)cameraTarget.GetZ()) << - luxrays::Property("scene.camera.up")((float)cameraUp.GetX(), (float)cameraUp.GetY(), (float)cameraUp.GetZ()) << - luxrays::Property("scene.camera.fieldofview")(fieldOfView) << - luxrays::Property("scene.camera.cliphither")(nearClip) << - luxrays::Property("scene.camera.clipyon")(farClip) << - luxrays::Property("scene.camera.type")("perspective")); - - // Set Texture - try { - for (auto it = m_textures.begin(); it != m_textures.end(); ++it) - { - if (it->second.GetRawDataPointer() != nullptr) - { - if (it->second.IsIBLTexture()) - { - luxCoreScene->DefineImageMap(std::string(it->first.data()), static_cast(it->second.GetRawDataPointer()), 1.f, it->second.GetTextureChannels(), it->second.GetTextureWidth(), it->second.GetTextureHeight()); - } - else - { - luxCoreScene->DefineImageMap(std::string(it->first.data()), static_cast(it->second.GetRawDataPointer()), 1.f, it->second.GetTextureChannels(), it->second.GetTextureWidth(), it->second.GetTextureHeight()); - } - - luxCoreScene->Parse( - - it->second.GetLuxCoreTextureProperties() - ); - } - else - { - AZ_Assert(false, "texture data is nullptr!!!"); - return; - } - } - } - catch (const std::runtime_error& e) - { - (void)e; - AZ_Assert(false, "%s", e.what()); - return; - } - catch (const std::exception& e) - { - (void)e; - AZ_Assert(false, "%s", e.what()); - return; - } - - - // Set Material - try { - for (auto it = m_materials.begin(); it != m_materials.end(); ++it) - { - luxCoreScene->Parse( - it->second.GetLuxCoreMaterialProperties() - ); - } - } - catch (const std::exception& e) - { - (void)e; - AZ_Assert(false, "%s", e.what()); - return; - } - - // Set Model - try { - for (auto it = m_meshs.begin(); it != m_meshs.end(); ++it) - { - luxCoreScene->DefineMesh(std::string(it->second.GetMeshId().ToString().data()), - it->second.GetVertexCount(), - it->second.GetTriangleCount(), - const_cast(it->second.GetPositionData()), - const_cast(it->second.GetIndexData()), - const_cast(it->second.GetNormalData()), - const_cast(it->second.GetUVData()), - NULL, - NULL); - } - } - catch (const std::exception& e) - { - (void)e; - AZ_Assert(false, "%s", e.what()); - return; - } - - // Objects - try { - for (auto it = m_objects.begin(); it != m_objects.end(); ++it) - { - luxCoreScene->Parse( - it->GetLuxCoreObjectProperties() - ); - } - } - catch (const std::exception& e) - { - (void)e; - AZ_Assert(false, "%s", e.what()); - return; - } - - // RenderConfig - luxcore::RenderConfig *config = luxcore::RenderConfig::Create( - luxrays::Property("path.pathdepth.total")(7) << - luxrays::Property("path.pathdepth.diffuse")(5) << - luxrays::Property("path.pathdepth.glossy")(5) << - luxrays::Property("path.pathdepth.specular")(6) << - luxrays::Property("path.hybridbackforward.enable")(0) << - luxrays::Property("path.hybridbackforward.partition")(0) << - luxrays::Property("path.hybridbackforward.glossinessthreshold ")(0.05) << - luxrays::Property("path.forceblackbackground.enable")(0) << - luxrays::Property("film.noiseestimation.warmup")(8) << - luxrays::Property("film.noiseestimation.step")(32) << - luxrays::Property("film.width")(1920) << - luxrays::Property("film.height")(1080) << - luxrays::Property("film.filter.type")("BLACKMANHARRIS") << - luxrays::Property("film.filter.width")(1.5) << - luxrays::Property("film.imagepipelines.0.0.type")("NOP") << - luxrays::Property("film.imagepipelines.0.1.type")("GAMMA_CORRECTION") << - luxrays::Property("film.imagepipelines.0.1.value")(2.2f) << - luxrays::Property("film.imagepipelines.0.radiancescales.0.enabled")(1) << - luxrays::Property("film.imagepipelines.0.radiancescales.0.globalscale")(1) << - luxrays::Property("film.imagepipelines.0.radiancescales.0.rgbscale")(1, 1, 1) << - luxrays::Property("film.outputs.0.type")("RGB_IMAGEPIPELINE") << - luxrays::Property("film.outputs.0.index")(0) << - luxrays::Property("film.outputs.0.filename")("RGB_IMAGEPIPELINE_0.png") << - luxrays::Property("sampler.type")("SOBOL") << - luxrays::Property("renderengine.type")("PATHCPU") << - luxrays::Property("renderengine.seed")(1) << - luxrays::Property("lightstrategy.type")("LOG_POWER") << - luxrays::Property("scene.epsilon.min")(9.9999997473787516e-06f) << - luxrays::Property("scene.epsilon.max")(0.10000000149011612f) << - luxrays::Property("scene.epsilon.max")(0.10000000149011612f) << - luxrays::Property("batch.haltthreshold")(0.01953125f) << - luxrays::Property("batch.haltthreshold.warmup")(64) << - luxrays::Property("batch.haltthreshold.step")(64) << - luxrays::Property("batch.haltthreshold.filter.enable")(1) << - luxrays::Property("batch.haltthreshold.stoprendering.enable")(1) << - luxrays::Property("batch.haltspp")(0) << - luxrays::Property("batch.halttime")(0) << - luxrays::Property("filesaver.renderengine.type")("PATHCPU") << - luxrays::Property("filesaver.format")("TXT"), - luxCoreScene); - - - // Export - try { - config->Export(resolvedPath); - } - catch (const std::runtime_error& e) - { - (void)e; - AZ_Assert(false, "%s", e.what()); - return; - } - - // Run luxcoreui.exe - AZ::IO::FixedMaxPath luxCoreExeFullPath = AZ::Utils::GetEnginePath(); - luxCoreExeFullPath /= AZ_TRAIT_LUXCORE_EXEPATH; - - AZStd::string commandLine = "-o " + AZStd::string(resolvedPath) + "/render.cfg"; - - LuxCoreUI::LaunchLuxCoreUI(luxCoreExeFullPath.String(), commandLine); - } - } -} -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreRenderer.h b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreRenderer.h deleted file mode 100644 index 9c9f8039f5..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreRenderer.h +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include -#include "LuxCoreMaterial.h" -#include "LuxCoreMesh.h" -#include "LuxCoreObject.h" -#include "LuxCoreTexture.h" - -namespace AZ -{ - namespace Render - { - // Hold all converted data, write scene and render file to disk when command received - // Can be extend to do real-time rendering in the future - class LuxCoreRenderer - : public LuxCoreRequestsBus::Handler - { - public: - LuxCoreRenderer(); - ~LuxCoreRenderer(); - - //////////////////////////////////////////////////////////////////////// - // LuxCoreRequestsBus - void SetCameraEntityID(AZ::EntityId id); - void AddMesh( Data::Asset modelAsset); - void AddMaterial(Data::Instance material); - void AddTexture(Data::Instance image, LuxCoreTextureType type); - void AddObject(AZ::Data::Asset modelAsset, AZ::Data::InstanceId materialInstanceId); - bool CheckTextureStatus(); - void RenderInLuxCore(); - void ClearLuxCore(); - void ClearObject(); - ///////////////////////////////////////////////////////////////////////// - - private: - AZ::EntityId m_cameraEntityId; - AZ::Transform m_cameraTransform; - - AZStd::unordered_map m_meshs; - AZStd::unordered_map m_materials; - AZStd::unordered_map m_textures; - AZStd::vector m_objects; - }; - } -} -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexture.cpp b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexture.cpp deleted file mode 100644 index 1fd8f0d91c..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexture.cpp +++ /dev/null @@ -1,158 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include "LuxCoreTexture.h" -#include -#include - -namespace AZ -{ - namespace Render - { - LuxCoreTexture::LuxCoreTexture(AZ::Data::Instance image, LuxCoreTextureType type) - { - Init(image, type); - } - - LuxCoreTexture::LuxCoreTexture(const LuxCoreTexture &texture) - { - Init(texture.m_texture, texture.m_type); - } - - LuxCoreTexture::~LuxCoreTexture() - { - if (m_rtPipeline) - { - m_rtPipeline->RemoveFromScene(); - m_rtPipeline = nullptr; - } - - if (m_texture) - { - m_texture = nullptr; - } - } - - void LuxCoreTexture::Init(AZ::Data::Instance image, LuxCoreTextureType type) - { - m_textureAssetId = image->GetAssetId(); - m_texture = image; - m_type = type; - - if (m_type == LuxCoreTextureType::IBL) - { - m_luxCoreTextureName = "scene.lights." + m_textureAssetId.ToString(); - m_luxCoreTexture = m_luxCoreTexture << luxrays::Property(std::string(m_luxCoreTextureName.data()) + ".type")("infinite"); - } - else - { - m_luxCoreTextureName = "scene.textures." + m_textureAssetId.ToString(); - m_luxCoreTexture = m_luxCoreTexture << luxrays::Property(std::string(m_luxCoreTextureName.data()) + ".type")("imagemap"); - } - - m_luxCoreTexture = m_luxCoreTexture << luxrays::Property(std::string(m_luxCoreTextureName.data()) + ".file")(std::string(m_textureAssetId.ToString().data())); - m_textureChannels = 4; - - AddRenderTargetPipeline(); - } - - void LuxCoreTexture::AddRenderTargetPipeline() - { - // Render Texture pipeline - AZ::RPI::RenderPipelineDescriptor pipelineDesc; - pipelineDesc.m_name = m_textureAssetId.ToString(); - pipelineDesc.m_rootPassTemplate = "LuxCoreTexturePassTemplate"; - m_rtPipeline = AZ::RPI::RenderPipeline::CreateRenderPipeline(pipelineDesc); - - // Set source texture - AZ::RPI::Pass* rootPass = m_rtPipeline->GetRootPass().get(); - AZ_Assert(rootPass != nullptr, "Failed to get root pass for render target pipeline"); - LuxCoreTexturePass* parentPass = static_cast(rootPass); - - // Setup call back to save read back data to m_textureData - RPI::AttachmentReadback::CallbackFunction callback = - [this](const AZ::RPI::AttachmentReadback::ReadbackResult& readbackResult) - { - RHI::ImageSubresourceLayout imageLayout = RHI::GetImageSubresourceLayout(readbackResult.m_imageDescriptor.m_size, - readbackResult.m_imageDescriptor.m_format); - m_textureData.resize_no_construct(imageLayout.m_bytesPerImage); - memcpy(m_textureData.data(), readbackResult.m_dataBuffer->data(), imageLayout.m_bytesPerImage); - - m_textureReadbackComplete = true; - }; - parentPass->SetReadbackCallback(callback); - - switch (m_type) - { - case LuxCoreTextureType::Default: - // assume a 8 bits linear texture - parentPass->SetSourceTexture(m_texture, RHI::Format::R8G8B8A8_UNORM); - break; - case LuxCoreTextureType::IBL: - // assume its a float image if its an IBL source - parentPass->SetSourceTexture(m_texture, RHI::Format::R32G32B32A32_FLOAT); - break; - case LuxCoreTextureType::Albedo: - // albedo texture is in sRGB space - parentPass->SetSourceTexture(m_texture, RHI::Format::R8G8B8A8_UNORM_SRGB); - break; - case LuxCoreTextureType::Normal: - // Normal texture needs special handling - parentPass->SetIsNormalTexture(true); - parentPass->SetSourceTexture(m_texture, RHI::Format::R8G8B8A8_UNORM); - break; - } - - const auto mainScene = AZ::RPI::RPISystemInterface::Get()->GetSceneByName(AZ::Name("RPI")); - if (mainScene) - { - mainScene->AddRenderPipeline(m_rtPipeline); - } - } - - bool LuxCoreTexture::IsIBLTexture() - { - return m_type == LuxCoreTextureType::IBL; - } - - void* LuxCoreTexture::GetRawDataPointer() - { - return (void*)m_textureData.data(); - } - - unsigned int LuxCoreTexture::GetTextureWidth() - { - return m_texture->GetRHIImage()->GetDescriptor().m_size.m_width; - } - - unsigned int LuxCoreTexture::GetTextureHeight() - { - return m_texture->GetRHIImage()->GetDescriptor().m_size.m_height; - } - - unsigned int LuxCoreTexture::GetTextureChannels() - { - return m_textureChannels; - } - - luxrays::Properties LuxCoreTexture::GetLuxCoreTextureProperties() - { - return m_luxCoreTexture; - } - - bool LuxCoreTexture::IsTextureReady() - { - return m_textureReadbackComplete; - } - } -} -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexture.h b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexture.h deleted file mode 100644 index abfb7cfe13..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexture.h +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ -#pragma once - - -#include -#if AZ_TRAIT_LUXCORE_SUPPORTED - -#include -#include -#include -#include - -namespace AZ -{ - namespace Render - { - // Build a pipeline to get raw data from runtime texture - class LuxCoreTexture final - { - public: - LuxCoreTexture() = default; - LuxCoreTexture( AZ::Data::Instance image, LuxCoreTextureType type); - LuxCoreTexture(const LuxCoreTexture &texture); - ~LuxCoreTexture(); - - void* GetRawDataPointer(); - - unsigned int GetTextureWidth(); - unsigned int GetTextureHeight(); - unsigned int GetTextureChannels(); - - void Init(AZ::Data::Instance image, LuxCoreTextureType type); - - void AddRenderTargetPipeline(); - luxrays::Properties GetLuxCoreTextureProperties(); - bool IsIBLTexture(); - bool IsTextureReady(); - - private: - AZStd::string m_luxCoreTextureName; - luxrays::Properties m_luxCoreTexture; - - AZ::RPI::RenderPipelinePtr m_rtPipeline = nullptr; - - AZStd::vector m_textureData; - AZ::Data::Instance m_texture; - unsigned int m_textureChannels = 4; - - Data::AssetId m_textureAssetId; - LuxCoreTextureType m_type = LuxCoreTextureType::Default; - - bool m_textureReadbackComplete = false; - }; - } -} -#endif diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexturePass.cpp b/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexturePass.cpp deleted file mode 100644 index 721e8b0c90..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/LuxCoreTexturePass.cpp +++ /dev/null @@ -1,90 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include -#include - -#include - -namespace AZ -{ - namespace Render - { - RPI::Ptr LuxCoreTexturePass::Create(const RPI::PassDescriptor& descriptor) - { - RPI::Ptr pass = aznew LuxCoreTexturePass(descriptor); - return pass; - } - - LuxCoreTexturePass::LuxCoreTexturePass(const RPI::PassDescriptor& descriptor) - : ParentPass(descriptor) - { - RPI::PassSystemInterface* passSystem = RPI::PassSystemInterface::Get(); - - // Create render target pass - RPI::PassRequest request; - request.m_templateName = "RenderTextureTemplate"; - request.m_passName = "RenderTarget"; - m_renderTargetPass = passSystem->CreatePassFromRequest(&request); - AZ_Assert(m_renderTargetPass, "render target pass is invalid"); - - // Create readback - m_readback = AZStd::make_shared(AZ::RHI::ScopeId{ Uuid::CreateRandom().ToString() }); - } - - LuxCoreTexturePass::~LuxCoreTexturePass() - { - m_renderTargetPass = nullptr; - m_readback = nullptr; - } - - void LuxCoreTexturePass::SetSourceTexture(AZ::Data::Instance image, RHI::Format format) - { - static_cast(m_renderTargetPass.get())->SetPassSrgImage(image, format); - } - - void LuxCoreTexturePass::CreateChildPassesInternal() - { - AddChild(m_renderTargetPass); - } - - void LuxCoreTexturePass::BuildInternal() - { - ParentPass::BuildInternal(); - } - - void LuxCoreTexturePass::FrameBeginInternal(FramePrepareParams params) - { - if (!m_attachmentReadbackComplete && m_readback != nullptr) - { - // Set up read back attachment before children prepare - if (m_readback->IsReady()) - { - if (m_renderTargetPass) - { - m_attachmentReadbackComplete = m_renderTargetPass->ReadbackAttachment(m_readback, AZ::Name("RenderTargetOutput")); - } - } - } - ParentPass::FrameBeginInternal(params); - } - - void LuxCoreTexturePass::SetIsNormalTexture(bool isNormal) - { - static_cast(m_renderTargetPass.get())->InitShaderVariant(isNormal); - } - - void LuxCoreTexturePass::SetReadbackCallback(RPI::AttachmentReadback::CallbackFunction callbackFunciton) - { - if (m_readback != nullptr) - { - m_readback->SetCallback(callbackFunciton); - } - } - } -} diff --git a/Gems/Atom/Feature/Common/Code/Source/LuxCore/RenderTexturePass.cpp b/Gems/Atom/Feature/Common/Code/Source/LuxCore/RenderTexturePass.cpp deleted file mode 100644 index c890da596b..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/LuxCore/RenderTexturePass.cpp +++ /dev/null @@ -1,90 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include -#include - -namespace AZ -{ - namespace Render - { - RPI::Ptr RenderTexturePass::Create(const RPI::PassDescriptor& descriptor) - { - RPI::Ptr pass = aznew RenderTexturePass(descriptor); - return pass; - } - - RenderTexturePass::RenderTexturePass(const RPI::PassDescriptor& descriptor) - : FullscreenTrianglePass(descriptor) - { - m_textureIndex = m_shaderResourceGroup->FindShaderInputImageIndex(Name("m_sourceTexture")); - } - - RenderTexturePass::~RenderTexturePass() - { - } - - void RenderTexturePass::SetPassSrgImage(AZ::Data::Instance image, RHI::Format format) - { - m_attachmentSize = image->GetRHIImage()->GetDescriptor().m_size; - m_attachmentFormat = format; - m_shaderResourceGroup->SetImage(m_textureIndex, image); - QueueForBuildAndInitialization(); - } - - void RenderTexturePass::BuildInternal() - { - UpdataAttachment(); - FullscreenTrianglePass::BuildInternal(); - } - - void RenderTexturePass::FrameBeginInternal(FramePrepareParams params) - { - FullscreenTrianglePass::FrameBeginInternal(params); - } - - void RenderTexturePass::UpdataAttachment() - { - // [GFX TODO][ATOM-2470] stop caring about attachment - RPI::Ptr attachment = m_ownedAttachments.front(); - if (!attachment) - { - AZ_Assert(false, "[RenderTexturePass %s] Cannot find any image attachment.", GetPathName().GetCStr()); - return; - } - AZ_Assert(attachment->m_descriptor.m_type == RHI::AttachmentType::Image, "[RenderTexturePass %s] requires an image attachment", GetPathName().GetCStr()); - - RPI::PassAttachmentBinding& binding = GetOutputBinding(0); - binding.m_attachment = attachment; - - RHI::ImageDescriptor& imageDescriptor = attachment->m_descriptor.m_image; - imageDescriptor.m_size = m_attachmentSize; - imageDescriptor.m_format = m_attachmentFormat; - } - - RHI::AttachmentId RenderTexturePass::GetRenderTargetId() - { - return m_ownedAttachments.front()->GetAttachmentId(); - } - - void RenderTexturePass::InitShaderVariant(bool isNormal) - { - auto shaderOption = m_shader->CreateShaderOptionGroup(); - RPI::ShaderOptionValue isNormalOption{ isNormal }; - shaderOption.SetValue(AZ::Name("o_isNormal"), isNormalOption); - - RPI::ShaderVariantSearchResult result = m_shader->FindVariantStableId(shaderOption.GetShaderVariantId()); - m_shaderVariantStableId = result.GetStableId(); - - if (!result.IsFullyBaked() && m_drawShaderResourceGroup->HasShaderVariantKeyFallbackEntry()) - { - m_drawShaderResourceGroup->SetShaderVariantKeyFallbackValue(shaderOption.GetShaderVariantId().m_key); - } - } - } -} diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/Android/Atom_Feature_Traits_Android.h b/Gems/Atom/Feature/Common/Code/Source/Platform/Android/Atom_Feature_Traits_Android.h index 81f41bd8c9..40f06f7191 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/Android/Atom_Feature_Traits_Android.h +++ b/Gems/Atom/Feature/Common/Code/Source/Platform/Android/Atom_Feature_Traits_Android.h @@ -7,5 +7,5 @@ */ #pragma once -#define AZ_TRAIT_LUXCORE_SUPPORTED 0 -#define AZ_TRAIT_LUXCORE_EXEPATH UNUSED_TRAIT +#define AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED 1 + diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/Common/Clang/atom_feature_common_clang.cmake b/Gems/Atom/Feature/Common/Code/Source/Platform/Common/Clang/atom_feature_common_clang.cmake index b3f7867308..7a325ca97e 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/Common/Clang/atom_feature_common_clang.cmake +++ b/Gems/Atom/Feature/Common/Code/Source/Platform/Common/Clang/atom_feature_common_clang.cmake @@ -5,9 +5,3 @@ # SPDX-License-Identifier: Apache-2.0 OR MIT # # - -set_source_files_properties( - Source/LuxCore/LuxCoreRenderer.cpp - PROPERTIES - COMPILE_OPTIONS -fexceptions -) diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/Common/MSVC/atom_feature_common_msvc.cmake b/Gems/Atom/Feature/Common/Code/Source/Platform/Common/MSVC/atom_feature_common_msvc.cmake index 9b5c59d310..7a325ca97e 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/Common/MSVC/atom_feature_common_msvc.cmake +++ b/Gems/Atom/Feature/Common/Code/Source/Platform/Common/MSVC/atom_feature_common_msvc.cmake @@ -5,9 +5,3 @@ # SPDX-License-Identifier: Apache-2.0 OR MIT # # - -set_source_files_properties( - Source/LuxCore/LuxCoreRenderer.cpp - PROPERTIES - COMPILE_OPTIONS /EHsc -) diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/Linux/Atom_Feature_Traits_Linux.h b/Gems/Atom/Feature/Common/Code/Source/Platform/Linux/Atom_Feature_Traits_Linux.h index 81f41bd8c9..40f06f7191 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/Linux/Atom_Feature_Traits_Linux.h +++ b/Gems/Atom/Feature/Common/Code/Source/Platform/Linux/Atom_Feature_Traits_Linux.h @@ -7,5 +7,5 @@ */ #pragma once -#define AZ_TRAIT_LUXCORE_SUPPORTED 0 -#define AZ_TRAIT_LUXCORE_EXEPATH UNUSED_TRAIT +#define AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED 1 + diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/Mac/Atom_Feature_Traits_Mac.h b/Gems/Atom/Feature/Common/Code/Source/Platform/Mac/Atom_Feature_Traits_Mac.h index 81f41bd8c9..40f06f7191 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/Mac/Atom_Feature_Traits_Mac.h +++ b/Gems/Atom/Feature/Common/Code/Source/Platform/Mac/Atom_Feature_Traits_Mac.h @@ -7,5 +7,5 @@ */ #pragma once -#define AZ_TRAIT_LUXCORE_SUPPORTED 0 -#define AZ_TRAIT_LUXCORE_EXEPATH UNUSED_TRAIT +#define AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED 1 + diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/Atom_Feature_Traits_Windows.h b/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/Atom_Feature_Traits_Windows.h index c35b6f0960..40f06f7191 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/Atom_Feature_Traits_Windows.h +++ b/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/Atom_Feature_Traits_Windows.h @@ -7,5 +7,5 @@ */ #pragma once -#define AZ_TRAIT_LUXCORE_SUPPORTED 0 -#define AZ_TRAIT_LUXCORE_EXEPATH "Gems/Atom/Feature/Common/External/LuxCore2.2/win64/dll/luxcoreui.exe" +#define AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED 1 + diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/LaunchLuxCoreUI_Windows.cpp b/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/LaunchLuxCoreUI_Windows.cpp deleted file mode 100644 index 7f15949201..0000000000 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/LaunchLuxCoreUI_Windows.cpp +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#include -#include -#include - -namespace LuxCoreUI -{ - void LaunchLuxCoreUI(const AZStd::string& luxCoreExeFullPath, const AZStd::string& commandLine) - { - STARTUPINFO si; - PROCESS_INFORMATION pi; - - ZeroMemory(&si, sizeof(si)); - si.cb = sizeof(si); - ZeroMemory(&pi, sizeof(pi)); - - AZStd::wstring luxCoreExeFullPathW; - AZStd::to_wstring(luxCoreExeFullPathW, luxCoreExeFullPath.c_str()); - AZStd::wstring commandLineW; - AZStd::to_wstring(commandLineW, commandLine.c_str()); - - // start the program up - CreateProcessW(luxCoreExeFullPathW.c_str(), // the path - commandLineW.data(), // Command line - NULL, // Process handle not inheritable - NULL, // Thread handle not inheritable - FALSE, // Set handle inheritance to FALSE - 0, // No creation flags - NULL, // Use parent's environment block - NULL, // Use parent's starting directory - &si, // Pointer to STARTUPINFO structure - &pi // Pointer to PROCESS_INFORMATION structure (removed extra parentheses) - ); - // Close process and thread handles. - CloseHandle(pi.hProcess); - CloseHandle(pi.hThread); - } -} diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/platform_windows_files.cmake b/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/platform_windows_files.cmake index 95d27d01ac..4acf1599f5 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/platform_windows_files.cmake +++ b/Gems/Atom/Feature/Common/Code/Source/Platform/Windows/platform_windows_files.cmake @@ -9,5 +9,4 @@ set(FILES Atom_Feature_Traits_Platform.h Atom_Feature_Traits_Windows.h - LaunchLuxCoreUI_Windows.cpp ) diff --git a/Gems/Atom/Feature/Common/Code/Source/Platform/iOS/Atom_Feature_Traits_iOS.h b/Gems/Atom/Feature/Common/Code/Source/Platform/iOS/Atom_Feature_Traits_iOS.h index 81f41bd8c9..40f06f7191 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Platform/iOS/Atom_Feature_Traits_iOS.h +++ b/Gems/Atom/Feature/Common/Code/Source/Platform/iOS/Atom_Feature_Traits_iOS.h @@ -7,5 +7,5 @@ */ #pragma once -#define AZ_TRAIT_LUXCORE_SUPPORTED 0 -#define AZ_TRAIT_LUXCORE_EXEPATH UNUSED_TRAIT +#define AZ_TRAIT_DIFFUSE_GI_PASSES_SUPPORTED 1 + diff --git a/Gems/Atom/Feature/Common/Code/Source/Utils/EditorLightingPreset.cpp b/Gems/Atom/Feature/Common/Code/Source/Utils/EditorLightingPreset.cpp index e2a99668eb..120eaa84dc 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Utils/EditorLightingPreset.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/Utils/EditorLightingPreset.cpp @@ -72,7 +72,7 @@ namespace AZ ->Attribute(AZ::Edit::Attributes::AutoExpand, true) ->DataElement(AZ::Edit::UIHandlers::Default, &LightConfig::m_direction, "Direction", "") ->DataElement(Edit::UIHandlers::Color, &LightConfig::m_color, "Color", "Color of the light") - ->Attribute("ColorEditorConfiguration", AZ::RPI::ColorUtils::GetLinearRgbEditorConfig()) + ->Attribute("ColorEditorConfiguration", AZ::RPI::ColorUtils::GetRgbEditorConfig()) ->DataElement(Edit::UIHandlers::Default, &LightConfig::m_intensity, "Intensity", "Intensity of the light in the set photometric unit.") ->ClassElement(AZ::Edit::ClassElements::Group, "Shadow") diff --git a/Gems/Atom/Feature/Common/Code/Source/Utils/GpuBufferHandler.cpp b/Gems/Atom/Feature/Common/Code/Source/Utils/GpuBufferHandler.cpp index 7a2827bebe..65bdf655a7 100644 --- a/Gems/Atom/Feature/Common/Code/Source/Utils/GpuBufferHandler.cpp +++ b/Gems/Atom/Feature/Common/Code/Source/Utils/GpuBufferHandler.cpp @@ -24,14 +24,14 @@ namespace AZ { m_elementSize = descriptor.m_elementSize; m_elementCount = 0; - + m_bufferIndex = descriptor.m_srgLayout->FindShaderInputBufferIndex(Name(descriptor.m_bufferSrgName)); - AZ_Error(ClassName, m_bufferIndex.IsValid(), "Unable to find %s in view shader resource group.", descriptor.m_bufferSrgName.c_str()); + AZ_Error(ClassName, m_bufferIndex.IsValid(), "Unable to find %s in %s shader resource group.", descriptor.m_bufferSrgName.c_str(), descriptor.m_srgLayout->GetName().GetCStr()); if (!descriptor.m_elementCountSrgName.empty()) { m_elementCountIndex = descriptor.m_srgLayout->FindShaderInputConstantIndex(Name(descriptor.m_elementCountSrgName)); - AZ_Error(ClassName, m_elementCountIndex.IsValid(), "Unable to find %s in view shader resource group.", descriptor.m_elementCountSrgName.c_str()); + AZ_Error(ClassName, m_elementCountIndex.IsValid(), "Unable to find %s in %s shader resource group.", descriptor.m_elementCountSrgName.c_str(), descriptor.m_srgLayout->GetName().GetCStr()); } if (m_bufferIndex.IsValid()) diff --git a/Gems/Atom/Feature/Common/Code/atom_feature_common_files.cmake b/Gems/Atom/Feature/Common/Code/atom_feature_common_files.cmake index 900e71717c..375dbd9724 100644 --- a/Gems/Atom/Feature/Common/Code/atom_feature_common_files.cmake +++ b/Gems/Atom/Feature/Common/Code/atom_feature_common_files.cmake @@ -46,9 +46,6 @@ set(FILES Include/Atom/Feature/Utils/MultiSparseVector.h Include/Atom/Feature/Utils/ProfilingCaptureBus.h Include/Atom/Feature/Utils/SparseVector.h - Include/Atom/Feature/LuxCore/LuxCoreBus.h - Include/Atom/Feature/LuxCore/LuxCoreTexturePass.h - Include/Atom/Feature/LuxCore/RenderTexturePass.h Source/CommonModule.cpp Source/CommonSystemComponent.cpp Source/FrameCaptureSystemComponent.cpp @@ -317,18 +314,6 @@ set(FILES Source/SkyBox/SkyBoxFogSettings.cpp Source/TransformService/TransformServiceFeatureProcessor.cpp Source/Utils/GpuBufferHandler.cpp - Source/LuxCore/LuxCoreTexturePass.cpp - Source/LuxCore/RenderTexturePass.cpp - Source/LuxCore/LuxCoreMaterial.cpp - Source/LuxCore/LuxCoreMaterial.h - Source/LuxCore/LuxCoreMesh.cpp - Source/LuxCore/LuxCoreMesh.h - Source/LuxCore/LuxCoreObject.cpp - Source/LuxCore/LuxCoreObject.h - Source/LuxCore/LuxCoreRenderer.cpp - Source/LuxCore/LuxCoreRenderer.h - Source/LuxCore/LuxCoreTexture.cpp - Source/LuxCore/LuxCoreTexture.h ) set(SKIP_UNITY_BUILD_INCLUSION_FILES diff --git a/Gems/Atom/Feature/Common/gem.json b/Gems/Atom/Feature/Common/gem.json index 84ab07a9f9..f4c936dc4a 100644 --- a/Gems/Atom/Feature/Common/gem.json +++ b/Gems/Atom/Feature/Common/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RPI", "Atom", diff --git a/Gems/Atom/RHI/CMakeLists.txt b/Gems/Atom/RHI/CMakeLists.txt index 074f6acfd7..5812828c1a 100644 --- a/Gems/Atom/RHI/CMakeLists.txt +++ b/Gems/Atom/RHI/CMakeLists.txt @@ -6,10 +6,10 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + ly_add_external_target_path(${CMAKE_CURRENT_LIST_DIR}/3rdParty) add_subdirectory(Code) -add_subdirectory(DX12) -add_subdirectory(Metal) -add_subdirectory(Vulkan) -add_subdirectory(Null) diff --git a/Gems/Atom/RHI/Code/CMakeLists.txt b/Gems/Atom/RHI/Code/CMakeLists.txt index 5238985feb..fe9db107a8 100644 --- a/Gems/Atom/RHI/Code/CMakeLists.txt +++ b/Gems/Atom/RHI/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_dir}/AtomRHITests_traits_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/Gems/Atom/RHI/Code/Include/Atom/RHI.Reflect/PhysicalDeviceDescriptor.h b/Gems/Atom/RHI/Code/Include/Atom/RHI.Reflect/PhysicalDeviceDescriptor.h index ac79ff0521..4d78d24ca8 100644 --- a/Gems/Atom/RHI/Code/Include/Atom/RHI.Reflect/PhysicalDeviceDescriptor.h +++ b/Gems/Atom/RHI/Code/Include/Atom/RHI.Reflect/PhysicalDeviceDescriptor.h @@ -28,7 +28,8 @@ namespace AZ (AMD, 0x1002), (Qualcomm, 0x5143), (Samsung, 0x1099), - (ARM, 0x13B5) + (ARM, 0x13B5), + (Warp, 0x1414) ); void ReflectVendorIdEnums(ReflectContext* context); diff --git a/Gems/Atom/RHI/Code/Include/Atom/RHI/FrameScheduler.h b/Gems/Atom/RHI/Code/Include/Atom/RHI/FrameScheduler.h index eb2b0b5b0c..47cf7709db 100644 --- a/Gems/Atom/RHI/Code/Include/Atom/RHI/FrameScheduler.h +++ b/Gems/Atom/RHI/Code/Include/Atom/RHI/FrameScheduler.h @@ -164,23 +164,27 @@ namespace AZ //! it will defer to the platform for parallel dispatch support. void Execute(JobPolicy jobPolicy); - /// Returns the timing statistics for the previous frame. + //! Returns the timing statistics for the previous frame. const TransientAttachmentStatistics* GetTransientAttachmentStatistics() const; - /// Returns current CPU frame to frame time in milliseconds. + //! Returns current CPU frame to frame time in milliseconds. double GetCpuFrameTime() const; - /// Returns memory statistics for the previous frame. + //! Returns memory statistics for the previous frame. const MemoryStatistics* GetMemoryStatistics() const; - /// Returns the implicit root scope id. + //! Returns the implicit root scope id. ScopeId GetRootScopeId() const; + //! Returns the descriptor which has information on the properties of a TransientAttachmentPool. const TransientAttachmentPoolDescriptor* GetTransientAttachmentPoolDescriptor() const; //! Adds a RayTracingShaderTable to be built this frame void QueueRayTracingShaderTableForBuild(RayTracingShaderTable* rayTracingShaderTable); + //! Returns PhysicalDeviceDescriptor which can be used to extract vendor/driver information + const PhysicalDeviceDescriptor& GetPhysicalDeviceDescriptor(); + private: const ScopeId m_rootScopeId{"Root"}; diff --git a/Gems/Atom/RHI/Code/Include/Atom/RHI/MemorySubAllocator.h b/Gems/Atom/RHI/Code/Include/Atom/RHI/MemorySubAllocator.h index 514907b19e..4a038276d1 100644 --- a/Gems/Atom/RHI/Code/Include/Atom/RHI/MemorySubAllocator.h +++ b/Gems/Atom/RHI/Code/Include/Atom/RHI/MemorySubAllocator.h @@ -91,13 +91,15 @@ namespace AZ m_pageAllocator = &pageAllocator; m_descriptor = descriptor; m_descriptor.m_addressBase = 0; - m_descriptor.m_capacityInBytes = m_pageAllocator->GetPageSize(); + if (m_descriptor.m_capacityInBytes == 0) + { + m_descriptor.m_capacityInBytes = m_pageAllocator->GetPageSize(); + } } template typename MemorySubAllocator::memory_allocation MemorySubAllocator::Allocate(size_t sizeInBytes, size_t alignmentInBytes) { - AZ_PROFILE_FUNCTION(RHI); if (RHI::AlignUp(sizeInBytes, alignmentInBytes) > m_descriptor.m_capacityInBytes) { return memory_allocation(); diff --git a/Gems/Atom/RHI/Code/Include/Atom/RHI/RHISystem.h b/Gems/Atom/RHI/Code/Include/Atom/RHI/RHISystem.h index 6d416b77fc..c2a3162025 100644 --- a/Gems/Atom/RHI/Code/Include/Atom/RHI/RHISystem.h +++ b/Gems/Atom/RHI/Code/Include/Atom/RHI/RHISystem.h @@ -53,6 +53,7 @@ namespace AZ const RHI::TransientAttachmentPoolDescriptor* GetTransientAttachmentPoolDescriptor() const override; ConstPtr GetPlatformLimitsDescriptor() const override; void QueueRayTracingShaderTableForBuild(RayTracingShaderTable* rayTracingShaderTable) override; + const PhysicalDeviceDescriptor& GetPhysicalDeviceDescriptor() override; ////////////////////////////////////////////////////////////////////////// private: @@ -65,6 +66,8 @@ namespace AZ RHI::Ptr m_pipelineStateCache; RHI::FrameScheduler m_frameScheduler; RHI::FrameSchedulerCompileRequest m_compileRequest; + PhysicalDeviceDescriptor m_physicalDeviceDescriptor; + }; } // namespace RPI } // namespace AZ diff --git a/Gems/Atom/RHI/Code/Include/Atom/RHI/RHISystemInterface.h b/Gems/Atom/RHI/Code/Include/Atom/RHI/RHISystemInterface.h index 19ba1cb762..66f6b2bcde 100644 --- a/Gems/Atom/RHI/Code/Include/Atom/RHI/RHISystemInterface.h +++ b/Gems/Atom/RHI/Code/Include/Atom/RHI/RHISystemInterface.h @@ -26,6 +26,7 @@ namespace AZ class PipelineState; class PipelineStateCache; class PlatformLimitsDescriptor; + class PhysicalDeviceDescriptor; class RayTracingShaderTable; struct FrameSchedulerCompileRequest; struct TransientAttachmentStatistics; @@ -65,6 +66,8 @@ namespace AZ virtual ConstPtr GetPlatformLimitsDescriptor() const = 0; virtual void QueueRayTracingShaderTableForBuild(RayTracingShaderTable* rayTracingShaderTable) = 0; + + virtual const PhysicalDeviceDescriptor& GetPhysicalDeviceDescriptor() = 0; }; //! This bus exists to give RHI samples the ability to slot in scopes manually diff --git a/Gems/Atom/RHI/Code/Platform/Mac/AtomRHITests_traits_mac.cmake b/Gems/Atom/RHI/Code/Platform/Mac/AtomRHITests_traits_mac.cmake index 419331db3b..4645eb9444 100644 --- a/Gems/Atom/RHI/Code/Platform/Mac/AtomRHITests_traits_mac.cmake +++ b/Gems/Atom/RHI/Code/Platform/Mac/AtomRHITests_traits_mac.cmake @@ -6,6 +6,6 @@ # # -set(ATOM_RHI_TRAIT_BUILD_SUPPORTS_TEST TRUE) +set(ATOM_RHI_TRAIT_BUILD_SUPPORTS_TEST FALSE) set(ATOM_RHI_TRAIT_BUILD_SUPPORTS_EDIT TRUE) set(PAL_TRAIT_BUILD_RENDERDOC_SUPPORTED FALSE) diff --git a/Gems/Atom/RHI/Code/Source/RHI/RHISystem.cpp b/Gems/Atom/RHI/Code/Source/RHI/RHISystem.cpp index e7515bbf6e..3ec0cfeb93 100644 --- a/Gems/Atom/RHI/Code/Source/RHI/RHISystem.cpp +++ b/Gems/Atom/RHI/Code/Source/RHI/RHISystem.cpp @@ -165,6 +165,7 @@ namespace AZ RHI::Ptr device = RHI::Factory::Get().CreateDevice(); if (device->Init(*physicalDeviceFound) == RHI::ResultCode::Success) { + m_physicalDeviceDescriptor = physicalDeviceFound->GetDescriptor(); PlatformLimitsDescriptor::Create(); return device; } @@ -279,5 +280,10 @@ namespace AZ { m_frameScheduler.QueueRayTracingShaderTableForBuild(rayTracingShaderTable); } + + const PhysicalDeviceDescriptor& RHISystem::GetPhysicalDeviceDescriptor() + { + return m_physicalDeviceDescriptor; + } } //namespace RPI } //namespace AZ diff --git a/Gems/Atom/RHI/DX12/CMakeLists.txt b/Gems/Atom/RHI/DX12/CMakeLists.txt index 51912a5ff0..5812828c1a 100644 --- a/Gems/Atom/RHI/DX12/CMakeLists.txt +++ b/Gems/Atom/RHI/DX12/CMakeLists.txt @@ -6,6 +6,10 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + ly_add_external_target_path(${CMAKE_CURRENT_LIST_DIR}/3rdParty) add_subdirectory(Code) diff --git a/Gems/Atom/RHI/DX12/Code/CMakeLists.txt b/Gems/Atom/RHI/DX12/Code/CMakeLists.txt index 975b838ffa..95118c60a7 100644 --- a/Gems/Atom/RHI/DX12/Code/CMakeLists.txt +++ b/Gems/Atom/RHI/DX12/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_include_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_include_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # PAL_TRAIT_ATOM_RHI_DX12_SUPPORTED @@ -23,7 +23,7 @@ set(pal_builder_tools_files) set(pal_builder_tools_includes) foreach(enabled_platform ${LY_PAL_TOOLS_ENABLED}) string(TOLOWER ${enabled_platform} enabled_platform_lowercase) - ly_get_list_relative_pal_filename(pal_builder_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${enabled_platform}) + o3de_pal_dir(pal_builder_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${enabled_platform} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) list(APPEND pal_builder_tools_includes ${pal_builder_source_dir}) list(APPEND pal_builder_tools_files ${pal_builder_source_dir}/platform_builders_${enabled_platform_lowercase}_tools_files.cmake) endforeach() diff --git a/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/PAL_windows.cmake b/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/PAL_windows.cmake index eb733a4d5a..1ee87e3099 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/PAL_windows.cmake +++ b/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/PAL_windows.cmake @@ -33,6 +33,13 @@ if(aftermath_header) set(PAL_TRAIT_AFTERMATH_AVAILABLE TRUE) endif() +ly_add_source_properties( + SOURCES + Source/RHI.Builders/ShaderPlatformInterfaceSystemComponent.cpp + PROPERTY COMPILE_DEFINITIONS + VALUES ${LY_PAL_TOOLS_DEFINES} +) + # Disable windows OS version check until infra can upgrade all our jenkins nodes # if(NOT CMAKE_SYSTEM_VERSION VERSION_GREATER_EQUAL "10.0.17763") # message(FATAL_ERROR "Windows DX12 RHI implementation requires an OS version and SDK matching windows 10 build 1809 or greater") diff --git a/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/RHI/Device_Windows.cpp b/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/RHI/Device_Windows.cpp index f6ed3be692..a2ed31ff84 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/RHI/Device_Windows.cpp +++ b/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/RHI/Device_Windows.cpp @@ -157,7 +157,10 @@ namespace AZ disabledMessages.push_back(D3D12_MESSAGE_ID_COPY_DESCRIPTORS_INVALID_RANGES); } - // [GFX TODO][ATOM-4712] - Fix PipelineLibrary Loading. These warnings were silenced for a release and need to be fixed properly. + // We disable these warnings as the our current implementation of Pipeline Library will trigger these warnings unknowingly. For example + // it will always first try to load a pso from pipelinelibrary triggering D3D12_MESSAGE_ID_LOADPIPELINE_NAMENOTFOUND (for the first time) before storing the PSO in a library. + // Similarly when we merge multiple pipeline libraries (in multiple threads) we may trigger D3D12_MESSAGE_ID_STOREPIPELINE_DUPLICATENAME as it is possible to save + // a PSO already saved in the main library. #if defined (AZ_DX12_USE_PIPELINE_LIBRARY) disabledMessages.push_back(D3D12_MESSAGE_ID_LOADPIPELINE_NAMENOTFOUND); disabledMessages.push_back(D3D12_MESSAGE_ID_STOREPIPELINE_DUPLICATENAME); diff --git a/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/RHI/NsightAftermath_Windows.cpp b/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/RHI/NsightAftermath_Windows.cpp index 199efbb139..429fded6ad 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/RHI/NsightAftermath_Windows.cpp +++ b/Gems/Atom/RHI/DX12/Code/Source/Platform/Windows/RHI/NsightAftermath_Windows.cpp @@ -53,14 +53,14 @@ namespace Aftermath #endif } - void SetAftermathEventMarker( [[maybe_unused]] void* cntxHandle, [[maybe_unused]] const AZStd::string& markerData, [[maybe_unused]] bool isAftermathInitialized) + void SetAftermathEventMarker( [[maybe_unused]] void* cntxHandle, [[maybe_unused]] const char* markerData, [[maybe_unused]] bool isAftermathInitialized) { #if defined(USE_NSIGHT_AFTERMATH) if (isAftermathInitialized) { GFSDK_Aftermath_Result result = GFSDK_Aftermath_SetEventMarker( - static_cast(cntxHandle), static_cast(markerData.c_str()), - static_cast(markerData.size()) + 1); + static_cast(cntxHandle), static_cast(markerData), + static_cast(strlen(markerData) + 1); AssertOnError(result); } #endif diff --git a/Gems/Atom/RHI/DX12/Code/Source/RHI.Builders/ShaderPlatformInterfaceSystemComponent.cpp b/Gems/Atom/RHI/DX12/Code/Source/RHI.Builders/ShaderPlatformInterfaceSystemComponent.cpp index 18834bdf46..3912fbed80 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/RHI.Builders/ShaderPlatformInterfaceSystemComponent.cpp +++ b/Gems/Atom/RHI/DX12/Code/Source/RHI.Builders/ShaderPlatformInterfaceSystemComponent.cpp @@ -15,15 +15,15 @@ #include #if defined(AZ_TOOLS_EXPAND_FOR_RESTRICTED_PLATFORMS) - #if defined(TOOLS_SUPPORT_JASPER) - #include - #endif - #if defined(TOOLS_SUPPORT_PROVO) - #include - #endif - #if defined(TOOLS_SUPPORT_SALEM) - #include - #endif +# if defined(TOOLS_SUPPORT_JASPER) +# include AZ_RESTRICTED_FILE_EXPLICIT(RHI.Builders/ShaderPlatformInterface, Jasper) +# endif +# if defined(TOOLS_SUPPORT_PROVO) +# include AZ_RESTRICTED_FILE_EXPLICIT(RHI.Builders/ShaderPlatformInterface, Provo) +# endif +# if defined(TOOLS_SUPPORT_SALEM) +# include AZ_RESTRICTED_FILE_EXPLICIT(RHI.Builders/ShaderPlatformInterface, Salem) +# endif #endif #include diff --git a/Gems/Atom/RHI/DX12/Code/Source/RHI/CommandListBase.cpp b/Gems/Atom/RHI/DX12/Code/Source/RHI/CommandListBase.cpp index 9733045179..35f52b3930 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/RHI/CommandListBase.cpp +++ b/Gems/Atom/RHI/DX12/Code/Source/RHI/CommandListBase.cpp @@ -85,7 +85,7 @@ namespace AZ return m_hardwareQueueClass; } - void CommandListBase::SetAftermathEventMarker(const AZStd::string& markerData) + void CommandListBase::SetAftermathEventMarker(const char* markerData) { auto& device = static_cast(GetDevice()); Aftermath::SetAftermathEventMarker(m_aftermathCommandListContext, markerData, device.IsAftermathInitialized()); diff --git a/Gems/Atom/RHI/DX12/Code/Source/RHI/CommandListBase.h b/Gems/Atom/RHI/DX12/Code/Source/RHI/CommandListBase.h index 5f3e4dce1e..d2ad804524 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/RHI/CommandListBase.h +++ b/Gems/Atom/RHI/DX12/Code/Source/RHI/CommandListBase.h @@ -52,7 +52,7 @@ namespace AZ RHI::HardwareQueueClass GetHardwareQueueClass() const; - void SetAftermathEventMarker(const AZStd::string& markerData); + void SetAftermathEventMarker(const char* markerData); protected: void Init(Device& device, RHI::HardwareQueueClass hardwareQueueClass, ID3D12CommandAllocator* commandAllocator); diff --git a/Gems/Atom/RHI/DX12/Code/Source/RHI/MemoryView.cpp b/Gems/Atom/RHI/DX12/Code/Source/RHI/MemoryView.cpp index c1a7156362..8afebd4ea2 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/RHI/MemoryView.cpp +++ b/Gems/Atom/RHI/DX12/Code/Source/RHI/MemoryView.cpp @@ -9,6 +9,7 @@ #include #include +#include #include #include @@ -57,8 +58,6 @@ namespace AZ CpuVirtualAddress MemoryView::Map(RHI::HostMemoryAccess hostAccess) const { - AZ_PROFILE_FUNCTION(RHI); - CpuVirtualAddress cpuAddress = nullptr; D3D12_RANGE readRange = {}; if (hostAccess == RHI::HostMemoryAccess::Read) diff --git a/Gems/Atom/RHI/DX12/Code/Source/RHI/NsightAftermath.h b/Gems/Atom/RHI/DX12/Code/Source/RHI/NsightAftermath.h index a486822309..bce293ad29 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/RHI/NsightAftermath.h +++ b/Gems/Atom/RHI/DX12/Code/Source/RHI/NsightAftermath.h @@ -15,6 +15,7 @@ namespace Aftermath { void SetAftermathEventMarker(void* cntxHandle, const AZStd::string& markerData, bool isAftermathInitialized); + void SetAftermathEventMarker(void* cntxHandle, const char* markerData, bool isAftermathInitialized); bool InitializeAftermath(AZ::RHI::Ptr dx12Device); void* CreateAftermathContextHandle(ID3D12GraphicsCommandList* commandList, void* crashTracker); void OutputLastScopeExecutingOnGPU(void* crashTracker); diff --git a/Gems/Atom/RHI/DX12/Code/Source/RHI/PipelineLibrary.cpp b/Gems/Atom/RHI/DX12/Code/Source/RHI/PipelineLibrary.cpp index 63625fde72..ae3053f446 100644 --- a/Gems/Atom/RHI/DX12/Code/Source/RHI/PipelineLibrary.cpp +++ b/Gems/Atom/RHI/DX12/Code/Source/RHI/PipelineLibrary.cpp @@ -50,10 +50,9 @@ namespace AZ bool shouldCreateLibFromSerializedData = true; if (RHI::Factory::Get().IsRenderDocModuleLoaded() || - RHI::Factory::Get().IsPixModuleLoaded() || - RHI::Factory::Get().UsingWarpDevice()) + RHI::Factory::Get().IsPixModuleLoaded()) { - // CreatePipelineLibrary api does not function properly if Renderdoc, Pix or Warp is enabled + // CreatePipelineLibrary api does not function properly if Renderdoc or Pix is enabled shouldCreateLibFromSerializedData = false; } @@ -218,10 +217,9 @@ namespace AZ RHI::ResultCode PipelineLibrary::MergeIntoInternal([[maybe_unused]] AZStd::array_view pipelineLibraries) { if (RHI::Factory::Get().IsRenderDocModuleLoaded() || - RHI::Factory::Get().IsPixModuleLoaded() || - RHI::Factory::Get().UsingWarpDevice()) + RHI::Factory::Get().IsPixModuleLoaded()) { - // StorePipeline api does not function properly if RenderDoc, Pix or Warp is enabled + // StorePipeline api does not function properly if RenderDoc or Pix is enabled return RHI::ResultCode::Fail; } diff --git a/Gems/Atom/RHI/DX12/gem.json b/Gems/Atom/RHI/DX12/gem.json index 868acd43db..803ae4f4d0 100644 --- a/Gems/Atom/RHI/DX12/gem.json +++ b/Gems/Atom/RHI/DX12/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI" ] diff --git a/Gems/Atom/RHI/Metal/CMakeLists.txt b/Gems/Atom/RHI/Metal/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Atom/RHI/Metal/CMakeLists.txt +++ b/Gems/Atom/RHI/Metal/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/RHI/Metal/Code/CMakeLists.txt b/Gems/Atom/RHI/Metal/Code/CMakeLists.txt index 11876e0a30..3df00a30e0 100644 --- a/Gems/Atom/RHI/Metal/Code/CMakeLists.txt +++ b/Gems/Atom/RHI/Metal/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_include_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_include_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_source_dir}/PAL2_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/Gems/Atom/RHI/Metal/Code/Source/RHI.Builders/ShaderPlatformInterface.cpp b/Gems/Atom/RHI/Metal/Code/Source/RHI.Builders/ShaderPlatformInterface.cpp index d43d88a7e1..8c80205c17 100644 --- a/Gems/Atom/RHI/Metal/Code/Source/RHI.Builders/ShaderPlatformInterface.cpp +++ b/Gems/Atom/RHI/Metal/Code/Source/RHI.Builders/ShaderPlatformInterface.cpp @@ -347,7 +347,7 @@ namespace AZ // spirv cross compiler executable static const char* spirvCrossRelativePath = "Builders/SPIRVCross/spirv-cross"; - AZStd::string spirvCrossCommandOptions = AZStd::string::format("--msl --msl-version 20100 --msl-argument-buffers --msl-decoration-binding --msl-texture-buffer-native --output \"%s\" \"%s\"", shaderMSLOutputFile.c_str(), shaderSpirvOutputFile.c_str()); + AZStd::string spirvCrossCommandOptions = AZStd::string::format("--msl --msl-version 20100 --msl-invariant-float-math --msl-argument-buffers --msl-decoration-binding --msl-texture-buffer-native --output \"%s\" \"%s\"", shaderMSLOutputFile.c_str(), shaderSpirvOutputFile.c_str()); // Run spirv cross if (!RHI::ExecuteShaderCompiler(spirvCrossRelativePath, spirvCrossCommandOptions, shaderSpirvOutputFile, "SpirvCross")) @@ -426,6 +426,8 @@ namespace AZ //Debug symbols are always enabled at the moment. Need to turn them off for optimized shader assets. AZStd::string shaderDebugInfo = "-gline-tables-only -MO"; + AZStd::string shaderMslToAirOptions = "-fpreserve-invariance"; + //Apply the correct platform sdk option AZStd::string platformSdk = "macosx"; if (platform.HasTag("mobile")) @@ -434,7 +436,7 @@ namespace AZ } //Convert to air file - AZStd::string mslToAirCommandOptions = AZStd::string::format("-sdk %s metal \"%s\" %s -c -o \"%s\"", platformSdk.c_str(), inputMetalFile.c_str(), shaderDebugInfo.c_str(), outputAirFile.c_str()); + AZStd::string mslToAirCommandOptions = AZStd::string::format("-sdk %s metal \"%s\" %s %s -c -o \"%s\"", platformSdk.c_str(), inputMetalFile.c_str(), shaderDebugInfo.c_str(), shaderMslToAirOptions.c_str(), outputAirFile.c_str()); if (!RHI::ExecuteShaderCompiler("/usr/bin/xcrun", mslToAirCommandOptions, inputMetalFile, "MslToAir")) { diff --git a/Gems/Atom/RHI/Metal/gem.json b/Gems/Atom/RHI/Metal/gem.json index 6e983ba505..0257048bd3 100644 --- a/Gems/Atom/RHI/Metal/gem.json +++ b/Gems/Atom/RHI/Metal/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI" ] diff --git a/Gems/Atom/RHI/Null/CMakeLists.txt b/Gems/Atom/RHI/Null/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Atom/RHI/Null/CMakeLists.txt +++ b/Gems/Atom/RHI/Null/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/RHI/Null/Code/CMakeLists.txt b/Gems/Atom/RHI/Null/Code/CMakeLists.txt index 71df9f696f..081edd4c44 100644 --- a/Gems/Atom/RHI/Null/Code/CMakeLists.txt +++ b/Gems/Atom/RHI/Null/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_include_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_include_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( diff --git a/Gems/Atom/RHI/Null/gem.json b/Gems/Atom/RHI/Null/gem.json index e9f22c5fcb..1ea2eb4cb0 100644 --- a/Gems/Atom/RHI/Null/gem.json +++ b/Gems/Atom/RHI/Null/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI" ] diff --git a/Gems/Atom/RHI/Vulkan/CMakeLists.txt b/Gems/Atom/RHI/Vulkan/CMakeLists.txt index 51912a5ff0..5812828c1a 100644 --- a/Gems/Atom/RHI/Vulkan/CMakeLists.txt +++ b/Gems/Atom/RHI/Vulkan/CMakeLists.txt @@ -6,6 +6,10 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + ly_add_external_target_path(${CMAKE_CURRENT_LIST_DIR}/3rdParty) add_subdirectory(Code) diff --git a/Gems/Atom/RHI/Vulkan/Code/CMakeLists.txt b/Gems/Atom/RHI/Vulkan/Code/CMakeLists.txt index fb13d1fddb..674e5aff9e 100644 --- a/Gems/Atom/RHI/Vulkan/Code/CMakeLists.txt +++ b/Gems/Atom/RHI/Vulkan/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_include_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_include_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # PAL_TRAIT_ATOM_RHI_VULKAN_SUPPORTED / PAL_TRAIT_ATOM_RHI_VULKAN_TARGETS_ALREADY_DEFINED diff --git a/Gems/Atom/RHI/Vulkan/gem.json b/Gems/Atom/RHI/Vulkan/gem.json index 1dfeb9eafa..508ad85c75 100644 --- a/Gems/Atom/RHI/Vulkan/gem.json +++ b/Gems/Atom/RHI/Vulkan/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI" ] diff --git a/Gems/Atom/RHI/gem.json b/Gems/Atom/RHI/gem.json index 7b64476c65..858a64fc17 100644 --- a/Gems/Atom/RHI/gem.json +++ b/Gems/Atom/RHI/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,10 +12,17 @@ ], "user_tags": [], "requirements": "", + "external_subdirectories": [ + "DX12", + "Metal", + "Null", + "Vulkan" + ], "dependencies": [ "Atom_RHI_DX12", "Atom_RHI_Metal", "Atom_RHI_Vulkan", + "Atom_RHI_Salem", "Atom_RHI_Null", "Atom_Feature_Common" ] diff --git a/Gems/Atom/RPI/CMakeLists.txt b/Gems/Atom/RPI/CMakeLists.txt index 6d148328ec..2c2cee5804 100644 --- a/Gems/Atom/RPI/CMakeLists.txt +++ b/Gems/Atom/RPI/CMakeLists.txt @@ -6,6 +6,10 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) add_subdirectory(Tools) diff --git a/Gems/Atom/RPI/Code/CMakeLists.txt b/Gems/Atom/RPI/Code/CMakeLists.txt index f0459a23c2..dcdad13c10 100644 --- a/Gems/Atom/RPI/Code/CMakeLists.txt +++ b/Gems/Atom/RPI/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) #for PAL_TRAIT_BUILD_ATOM_RPI_ASSETS_SUPPORTED and PAL_TRAIT_BUILD_ATOM_RPI_MASKED_OCCLUSION_CULLING_SUPPORTED include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) @@ -176,8 +176,8 @@ endif() if(PAL_TRAIT_BUILD_HOST_TOOLS) - ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) - ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) + o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) + set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) if(NOT PAL_TRAIT_BUILD_ATOM_RPI_ASSETS_SUPPORTED) diff --git a/Gems/Atom/RPI/Code/Include/Atom/RPI.Edit/Common/ColorUtils.h b/Gems/Atom/RPI/Code/Include/Atom/RPI.Edit/Common/ColorUtils.h index 393cae6ca2..38b6a0bb80 100644 --- a/Gems/Atom/RPI/Code/Include/Atom/RPI.Edit/Common/ColorUtils.h +++ b/Gems/Atom/RPI/Code/Include/Atom/RPI.Edit/Common/ColorUtils.h @@ -19,6 +19,8 @@ namespace AZ //[GFX TODO][ATOM-4462] Replace this to use data driven color management system //! Return a ColorEditorConfiguration for editing a Linear sRGB color in sRGB space. AzToolsFramework::ColorEditorConfiguration GetLinearRgbEditorConfig(); + //! Return a ColorEditorConfiguration for editing a sRGB color in sRGB space. + AzToolsFramework::ColorEditorConfiguration GetRgbEditorConfig(); } // namespace PropertyColorConfigs } // namespace RPI diff --git a/Gems/Atom/RPI/Code/Include/Atom/RPI.Edit/Common/JsonUtils.h b/Gems/Atom/RPI/Code/Include/Atom/RPI.Edit/Common/JsonUtils.h index 4715acd64c..9f4cdcf31b 100644 --- a/Gems/Atom/RPI/Code/Include/Atom/RPI.Edit/Common/JsonUtils.h +++ b/Gems/Atom/RPI/Code/Include/Atom/RPI.Edit/Common/JsonUtils.h @@ -29,7 +29,7 @@ namespace AZ //! Loads serialized object data from a json file at the specified path //! Errors will be reported using AZ trace template - bool LoadObjectFromFile(const AZStd::string& path, ObjectType& objectData); + bool LoadObjectFromFile(const AZStd::string& path, ObjectType& objectData, size_t maxFileSize = DefaultMaxFileSize); //! Saves serialized object data to a json file at the specified path //! Errors will be reported using AZ trace @@ -39,11 +39,11 @@ namespace AZ // Definitions... template - bool LoadObjectFromFile(const AZStd::string& path, ObjectType& objectData) + bool LoadObjectFromFile(const AZStd::string& path, ObjectType& objectData, size_t maxFileSize) { objectData = ObjectType(); - auto loadOutcome = AZ::JsonSerializationUtils::ReadJsonFile(path, DefaultMaxFileSize); + auto loadOutcome = AZ::JsonSerializationUtils::ReadJsonFile(path, maxFileSize); if (!loadOutcome.IsSuccess()) { AZ_Error("AZ::RPI::JsonUtils", false, "%s", loadOutcome.GetError().c_str()); diff --git a/Gems/Atom/RPI/Code/Include/Atom/RPI.Public/RPISystemInterface.h b/Gems/Atom/RPI/Code/Include/Atom/RPI.Public/RPISystemInterface.h index 3f30d498cf..693185b6d2 100644 --- a/Gems/Atom/RPI/Code/Include/Atom/RPI.Public/RPISystemInterface.h +++ b/Gems/Atom/RPI/Code/Include/Atom/RPI.Public/RPISystemInterface.h @@ -34,8 +34,7 @@ namespace AZ RPISystemInterface() = default; virtual ~RPISystemInterface() = default; - //! Pre-load some system assets. This should be called once the asset catalog is ready and before create any RPI instances. - //! Note: can't rely on the AzFramework::AssetCatalogEventBus's OnCatalogLoaded since the order of calling handlers is undefined. + //! Pre-load some system assets. This should be called once Critical Asset have compiled ready and before create any RPI instances. virtual void InitializeSystemAssets() = 0; //! Was the RPI system initialized properly diff --git a/Gems/Atom/RPI/Code/Include/Atom/RPI.Public/Shader/Shader.h b/Gems/Atom/RPI/Code/Include/Atom/RPI.Public/Shader/Shader.h index 92b67c3a7a..be20d89d65 100644 --- a/Gems/Atom/RPI/Code/Include/Atom/RPI.Public/Shader/Shader.h +++ b/Gems/Atom/RPI/Code/Include/Atom/RPI.Public/Shader/Shader.h @@ -136,11 +136,6 @@ namespace AZ //! This tag corresponds to the ShaderAsset object's DrawListName. RHI::DrawListTag GetDrawListTag() const; - //! Changes the supervariant of the shader to the specified supervariantIndex. - //! [GFX TODO][ATOM-15813]: this can be removed when the shader InstanceDatabase can support multiple shader - //! instances with different supervariants. - void ChangeSupervariant(SupervariantIndex supervariantIndex); - private: explicit Shader(const SupervariantIndex& supervariantIndex) : m_supervariantIndex(supervariantIndex){}; Shader() = delete; diff --git a/Gems/Atom/RPI/Code/Include/Atom/RPI.Reflect/Shader/ShaderVariantAsset.h b/Gems/Atom/RPI/Code/Include/Atom/RPI.Reflect/Shader/ShaderVariantAsset.h index 5146ae370a..b65d9837f7 100644 --- a/Gems/Atom/RPI/Code/Include/Atom/RPI.Reflect/Shader/ShaderVariantAsset.h +++ b/Gems/Atom/RPI/Code/Include/Atom/RPI.Reflect/Shader/ShaderVariantAsset.h @@ -50,6 +50,7 @@ namespace AZ RPI::ShaderVariantStableId GetStableId() const { return m_stableId; } const ShaderVariantId& GetShaderVariantId() const { return m_shaderVariantId; } + uint32_t GetSupervariantIndex() const; //! Returns the shader stage function associated with the provided stage enum value. const RHI::ShaderStageFunction* GetShaderStageFunction(RHI::ShaderStage shaderStage) const; diff --git a/Gems/Atom/RPI/Code/Source/RPI.Builders/Pass/PassBuilder.cpp b/Gems/Atom/RPI/Code/Source/RPI.Builders/Pass/PassBuilder.cpp index 6a0b10633e..e2d4bd629a 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Builders/Pass/PassBuilder.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Builders/Pass/PassBuilder.cpp @@ -53,7 +53,7 @@ namespace AZ { AssetBuilderSDK::AssetBuilderDesc builder; builder.m_name = PassBuilderJobKey; - builder.m_version = 14; // making .pass files emit product dependencies for the shaders they reference so they are picked up by the asset bundler + builder.m_version = 15; // Changed dependency type to OrderOnce builder.m_busId = azrtti_typeid(); builder.m_createJobFunction = AZStd::bind(&PassBuilder::CreateJobs, this, AZStd::placeholders::_1, AZStd::placeholders::_2); builder.m_processJobFunction = AZStd::bind(&PassBuilder::ProcessJob, this, AZStd::placeholders::_1, AZStd::placeholders::_2); @@ -97,27 +97,16 @@ namespace AZ // Helper function to get a file reference and create a corresponding job dependency bool AddDependency(FindPassReferenceAssetParams& params, AssetBuilderSDK::JobDescriptor* job) { - AZStd::string_view& file = params.dependencySourceFile; - AZ::Data::AssetInfo sourceInfo; - AZStd::string watchFolder; - bool fileFound = false; - AzToolsFramework::AssetSystemRequestBus::BroadcastResult(fileFound, &AzToolsFramework::AssetSystem::AssetSystemRequest::GetSourceInfoBySourcePath, file.data(), sourceInfo, watchFolder); - - if (fileFound) - { - AssetBuilderSDK::JobDependency jobDependency; - jobDependency.m_jobKey = params.jobKey; - jobDependency.m_type = AssetBuilderSDK::JobDependencyType::Order; - jobDependency.m_sourceFile.m_sourceFileDependencyPath = file; - job->m_jobDependencyList.push_back(jobDependency); - AZ_TracePrintf(PassBuilderName, "Creating job dependency on file [%s] \n", file.data()); - return true; - } - else - { - AZ_Error(PassBuilderName, false, "Could not find referenced file [%s]", file.data()); - return false; - } + // We use an OrderOnce job dependency to ensure that the Asset Processor knows about the + // referenced asset, so we can make an AssetId for it later in ProcessJob. OrderOnce is + // enough because we don't need to read any data from the asset, we just needs its ID. + AssetBuilderSDK::JobDependency jobDependency; + jobDependency.m_jobKey = params.jobKey; + jobDependency.m_type = AssetBuilderSDK::JobDependencyType::OrderOnce; + jobDependency.m_sourceFile.m_sourceFileDependencyPath = params.dependencySourceFile; + job->m_jobDependencyList.push_back(jobDependency); + AZ_TracePrintf(PassBuilderName, "Creating job dependency on file [%.*s] \n", AZ_STRING_ARG(params.dependencySourceFile)); + return true; } bool SetJobKeyForExtension(const AZStd::string& filePath, FindPassReferenceAssetParams& params) diff --git a/Gems/Atom/RPI/Code/Source/RPI.Edit/Common/ColorUtils.cpp b/Gems/Atom/RPI/Code/Source/RPI.Edit/Common/ColorUtils.cpp index a6baa38a72..df88a530b9 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Edit/Common/ColorUtils.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Edit/Common/ColorUtils.cpp @@ -14,14 +14,14 @@ namespace AZ { namespace ColorUtils { + enum ColorSpace : uint32_t + { + LinearSRGB, + SRGB + }; + AzToolsFramework::ColorEditorConfiguration GetLinearRgbEditorConfig() { - enum ColorSpace : uint32_t - { - LinearSRGB, - SRGB - }; - AzToolsFramework::ColorEditorConfiguration configuration; configuration.m_colorPickerDialogConfiguration = AzQtComponents::ColorPicker::Configuration::RGB; @@ -59,6 +59,15 @@ namespace AZ return configuration; } + AzToolsFramework::ColorEditorConfiguration GetRgbEditorConfig() + { + AzToolsFramework::ColorEditorConfiguration configuration = GetLinearRgbEditorConfig(); + + configuration.m_propertyColorSpaceId = ColorSpace::SRGB; + + return configuration; + } + } // namespace ColorPropertyEditorConfigurations } // namespace RPI } // namespace AZ diff --git a/Gems/Atom/RPI/Code/Source/RPI.Public/DynamicDraw/DynamicDrawContext.cpp b/Gems/Atom/RPI/Code/Source/RPI.Public/DynamicDraw/DynamicDrawContext.cpp index 3b3473a2da..47791d3002 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Public/DynamicDraw/DynamicDrawContext.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Public/DynamicDraw/DynamicDrawContext.cpp @@ -141,6 +141,7 @@ namespace AZ void DynamicDrawContext::InitVertexFormat(const AZStd::vector& vertexChannels) { AZ_Assert(!m_initialized, "Can't call InitVertexFormat after context was initialized (EndInit was called)"); + AZ_Assert(m_pipelineState, "Can't call InitVertexFormat before InitShader is called with a valid shader"); m_perVertexDataSize = 0; RHI::InputStreamLayoutBuilder layoutBuilder; @@ -150,7 +151,10 @@ namespace AZ bufferBuilder->Channel(channel.m_channel, channel.m_format); m_perVertexDataSize += RHI::GetFormatSize(channel.m_format); } - m_pipelineState->InputStreamLayout() = layoutBuilder.End(); + if (m_pipelineState) + { + m_pipelineState->InputStreamLayout() = layoutBuilder.End(); + } } void DynamicDrawContext::InitDrawListTag(RHI::DrawListTag drawListTag) diff --git a/Gems/Atom/RPI/Code/Source/RPI.Public/Image/StreamingImage.cpp b/Gems/Atom/RPI/Code/Source/RPI.Public/Image/StreamingImage.cpp index fb03d109a2..49cd52f212 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Public/Image/StreamingImage.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Public/Image/StreamingImage.cpp @@ -143,11 +143,6 @@ namespace AZ RHI::ResultCode resultCode = RHI::ResultCode::Success; const ImageMipChainAsset& mipChainTailAsset = imageAsset.GetTailMipChain(); - -#ifdef AZ_RPI_STREAMING_IMAGE_DEBUG_LOG - m_image->SetName(Name(imageAsset.GetHint().c_str())); - AZ_TracePrintf("StreamingImage", "Init image [%s]\n", m_image->GetName().data()); -#endif { RHI::StreamingImageInitRequest initRequest; @@ -193,6 +188,13 @@ namespace AZ m_rhiPool = rhiPool; m_pool = pool; m_pool->AttachImage(this); + + // Set rhi image name + m_image->SetName(Name(m_imageAsset.GetHint())); + +#ifdef AZ_RPI_STREAMING_IMAGE_DEBUG_LOG + AZ_TracePrintf("StreamingImage", "Init image [%s]\n", m_image->GetName().data()); +#endif #if defined (AZ_RPI_STREAMING_IMAGE_HOT_RELOADING) BusConnect(imageAsset.GetId()); diff --git a/Gems/Atom/RPI/Code/Source/RPI.Public/Shader/Shader.cpp b/Gems/Atom/RPI/Code/Source/RPI.Public/Shader/Shader.cpp index b1ae460af6..130c0158d1 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Public/Shader/Shader.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Public/Shader/Shader.cpp @@ -17,6 +17,7 @@ #include +#define PSOCacheVersion 0 // Bump this if you want to reset PSO cache for everyone namespace AZ { @@ -25,21 +26,34 @@ namespace AZ Data::Instance Shader::FindOrCreate(const Data::Asset& shaderAsset, const Name& supervariantName) { auto anySupervariantName = AZStd::any(supervariantName); - Data::Instance shaderInstance = Data::InstanceDatabase::Instance().FindOrCreate( - Data::InstanceId::CreateFromAssetId(shaderAsset.GetId()), shaderAsset, &anySupervariantName); - if (shaderInstance) + // retrieve the supervariant index from the shader asset + SupervariantIndex supervariantIndex = shaderAsset->GetSupervariantIndex(supervariantName); + if (!supervariantIndex.IsValid()) { - // [GFX TODO][ATOM-15813] Change InstanceDatabase to support multiple instances with different supervariants. - // At this time we do not support multiple supervariants loaded for a shader asset simultaneously, so if this shader - // is referring to the wrong supervariant we need to change it to the correct one. - SupervariantIndex supervariantIndex = shaderAsset->GetSupervariantIndex(supervariantName); - if (supervariantIndex.IsValid() && shaderInstance->GetSupervariantIndex() != supervariantIndex) - { - shaderInstance->ChangeSupervariant(supervariantIndex); - } + AZ_Error("Shader", false, "Supervariant with name %s, was not found in shader %s", supervariantName.GetCStr(), shaderAsset->GetName().GetCStr()); + return nullptr; } + // create the InstanceId from the combined assetId and supervariantIndex + const Data::AssetId& assetId = shaderAsset.GetId(); + uint32_t shaderSupervariantIndex = supervariantIndex.GetIndex(); + + const uint32_t instanceIdDataSize = sizeof(assetId.m_guid) + sizeof(assetId.m_subId) + sizeof(shaderSupervariantIndex); + uint8_t instanceIdData[instanceIdDataSize]; + uint8_t* instanceIdDataPtr = instanceIdData; + + memcpy(instanceIdDataPtr, &assetId.m_guid, sizeof(assetId.m_guid)); + instanceIdDataPtr += sizeof(assetId.m_guid); + memcpy(instanceIdDataPtr, &assetId.m_subId, sizeof(assetId.m_subId)); + instanceIdDataPtr += sizeof(assetId.m_subId); + memcpy(instanceIdDataPtr, &shaderSupervariantIndex, sizeof(shaderSupervariantIndex)); + + Data::InstanceId instanceId = Data::InstanceId::CreateData(instanceIdData, instanceIdDataSize); + + // retrieve the shader instance from the Instance database + Data::Instance shaderInstance = Data::InstanceDatabase::Instance().FindOrCreate(instanceId, shaderAsset, &anySupervariantName); + return shaderInstance; } @@ -85,10 +99,17 @@ namespace AZ AZStd::string uuidString; assetId.m_guid.ToString(uuidString, false, false); + RHI::RHISystemInterface* rhiSystem = RHI::RHISystemInterface::Get(); + RHI::PhysicalDeviceDescriptor physicalDeviceDesc = rhiSystem->GetPhysicalDeviceDescriptor(); + char pipelineLibraryPathTemp[AZ_MAX_PATH_LEN]; azsnprintf( - pipelineLibraryPathTemp, AZ_MAX_PATH_LEN, "@user@/Atom/PipelineStateCache/%s/%s_%s_%d.bin", platformName.GetCStr(), - shaderName.GetCStr(), uuidString.data(), assetId.m_subId); + pipelineLibraryPathTemp, AZ_MAX_PATH_LEN, "@user@/Atom/PipelineStateCache_%s_%i_%i _Ver_%i/%s/%s_%s_%d.bin", + ToString(physicalDeviceDesc.m_vendorId).data(), physicalDeviceDesc.m_deviceId, physicalDeviceDesc.m_driverVersion, PSOCacheVersion, + platformName.GetCStr(), + shaderName.GetCStr(), + uuidString.data(), + assetId.m_subId); fileIOBase->ResolvePath(pipelineLibraryPathTemp, pipelineLibraryPath, pipelineLibraryPathLength); return true; @@ -240,6 +261,12 @@ namespace AZ AZ_Assert(shaderVariantAsset, "Reloaded ShaderVariantAsset is null"); const ShaderVariantStableId stableId = shaderVariantAsset->GetStableId(); + // check the supervariantIndex of the ShaderVariantAsset to make sure it matches the supervariantIndex of this shader instance + if (shaderVariantAsset->GetSupervariantIndex() != m_supervariantIndex.GetIndex()) + { + return; + } + // We make a copy of the updated variant because OnShaderVariantReinitialized must not be called inside // m_variantCacheMutex or deadlocks may occur. // Or if there is an error, we leave this object in its default state to indicate there was an error. @@ -478,14 +505,5 @@ namespace AZ return m_drawListTag; } - void Shader::ChangeSupervariant(SupervariantIndex supervariantIndex) - { - if (supervariantIndex != m_supervariantIndex) - { - m_supervariantIndex = supervariantIndex; - Init(*m_asset); - } - } - } // namespace RPI } // namespace AZ diff --git a/Gems/Atom/RPI/Code/Source/RPI.Public/Shader/ShaderResourceGroup.cpp b/Gems/Atom/RPI/Code/Source/RPI.Public/Shader/ShaderResourceGroup.cpp index 7e43fba7a3..b927e864fc 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Public/Shader/ShaderResourceGroup.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Public/Shader/ShaderResourceGroup.cpp @@ -74,8 +74,6 @@ namespace AZ RHI::ResultCode ShaderResourceGroup::Init(ShaderAsset& shaderAsset, const SupervariantIndex& supervariantIndex, const AZ::Name& srgName) { - AZ_PROFILE_FUNCTION(RPI); - const auto& lay = shaderAsset.FindShaderResourceGroupLayout(srgName, supervariantIndex); m_layout = lay.get(); diff --git a/Gems/Atom/RPI/Code/Source/RPI.Reflect/Shader/ShaderVariantAsset.cpp b/Gems/Atom/RPI/Code/Source/RPI.Reflect/Shader/ShaderVariantAsset.cpp index ec1a65a6d5..f9f046ac8a 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Reflect/Shader/ShaderVariantAsset.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Reflect/Shader/ShaderVariantAsset.cpp @@ -65,6 +65,11 @@ namespace AZ return m_buildTimestamp; } + uint32_t ShaderVariantAsset::GetSupervariantIndex() const + { + return (m_assetId.m_subId >> SupervariantIndexBitPosition) & SupervariantIndexMaxValue; + } + const RHI::ShaderStageFunction* ShaderVariantAsset::GetShaderStageFunction(RHI::ShaderStage shaderStage) const { return m_functionsByStage[static_cast(shaderStage)].get(); diff --git a/Gems/Atom/RPI/gem.json b/Gems/Atom/RPI/gem.json index 885f150508..0acef5179b 100644 --- a/Gems/Atom/RPI/gem.json +++ b/Gems/Atom/RPI/gem.json @@ -1,16 +1,18 @@ { "gem_name": "Atom_RPI", "display_name": "Atom API", - "summary": "", "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", + "summary": "", "canonical_tags": [ "Gem" ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI" ] diff --git a/Gems/Atom/TestData/TestData/Materials/SkinTestCases/001_lucy_regression_test.material b/Gems/Atom/TestData/TestData/Materials/SkinTestCases/001_hermanubis_regression_test.material similarity index 84% rename from Gems/Atom/TestData/TestData/Materials/SkinTestCases/001_lucy_regression_test.material rename to Gems/Atom/TestData/TestData/Materials/SkinTestCases/001_hermanubis_regression_test.material index bafb047be9..e6c032b0f9 100644 --- a/Gems/Atom/TestData/TestData/Materials/SkinTestCases/001_lucy_regression_test.material +++ b/Gems/Atom/TestData/TestData/Materials/SkinTestCases/001_hermanubis_regression_test.material @@ -11,7 +11,7 @@ 0.29372090101242068, 1.0 ], - "textureMap": "Objects/Lucy/Lucy_bronze_BaseColor.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_BaseColor.png", "useTexture": false }, "detailLayerGroup": { @@ -30,14 +30,14 @@ }, "normal": { "flipY": true, - "textureMap": "Objects/Lucy/Lucy_Normal.png" + "textureMap": "Objects/Hermanubis/Hermanubis_Normal.png" }, "subsurfaceScattering": { "enableSubsurfaceScattering": true, - "influenceMap": "Objects/Lucy/Lucy_thickness.tif", + "influenceMap": "Objects/Hermanubis/Hermanubis_thickness.tif", "scatterDistance": 15.0, "subsurfaceScatterFactor": 0.4300000071525574, - "thicknessMap": "Objects/Lucy/Lucy_thickness.tif", + "thicknessMap": "Objects/Hermanubis/Hermanubis_thickness.tif", "transmissionAttenuation": 15.0, "transmissionDistortion": 0.3499999940395355, "transmissionMode": "ThickObject", diff --git a/Gems/Atom/TestData/TestData/Materials/SkinTestCases/002_wrinkle_regression_test.material b/Gems/Atom/TestData/TestData/Materials/SkinTestCases/002_wrinkle_regression_test.material index 78f597b14f..9b955ddb1d 100644 --- a/Gems/Atom/TestData/TestData/Materials/SkinTestCases/002_wrinkle_regression_test.material +++ b/Gems/Atom/TestData/TestData/Materials/SkinTestCases/002_wrinkle_regression_test.material @@ -29,14 +29,14 @@ }, "normal": { "flipY": true, - "textureMap": "Objects/Lucy/Lucy_Normal.png" + "textureMap": "Objects/Hermanubis/Hermanubis_Normal.png" }, "subsurfaceScattering": { "enableSubsurfaceScattering": true, "influenceMap": "TestData/Textures/checker8x8_gray_512.png", "scatterDistance": 15.0, "subsurfaceScatterFactor": 0.4300000071525574, - "thicknessMap": "Objects/Lucy/Lucy_thickness.tif", + "thicknessMap": "Objects/Hermanubis/Hermanubis_thickness.tif", "transmissionAttenuation": 15.0, "transmissionDistortion": 0.3499999940395355, "transmissionMode": "ThickObject", diff --git a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/101_DetailMaps_LucyBaseNoDetailMaps.material b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/101_DetailMaps_BaseNoDetailMaps.material similarity index 66% rename from Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/101_DetailMaps_LucyBaseNoDetailMaps.material rename to Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/101_DetailMaps_BaseNoDetailMaps.material index 6d77be5a49..82192bac41 100644 --- a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/101_DetailMaps_LucyBaseNoDetailMaps.material +++ b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/101_DetailMaps_BaseNoDetailMaps.material @@ -5,7 +5,7 @@ "propertyLayoutVersion": 3, "properties": { "baseColor": { - "textureMap": "Objects/Lucy/Lucy_bronze_BaseColor.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_BaseColor.png", "textureMapUv": "Unwrapped" }, "detailUV": { @@ -15,16 +15,16 @@ ] }, "metallic": { - "textureMap": "Objects/Lucy/Lucy_bronze_Metallic.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_Metallic.png", "textureMapUv": "Unwrapped" }, "normal": { "flipY": true, - "textureMap": "Objects/Lucy/Lucy_Normal.png", + "textureMap": "Objects/Hermanubis/Hermanubis_Normal.png", "textureMapUv": "Unwrapped" }, "roughness": { - "textureMap": "Objects/Lucy/Lucy_bronze_Roughness.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_Roughness.png", "textureMapUv": "Unwrapped" } } diff --git a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/102_DetailMaps_All.material b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/102_DetailMaps_All.material index 1a29f392c8..dd31d00db0 100644 --- a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/102_DetailMaps_All.material +++ b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/102_DetailMaps_All.material @@ -5,12 +5,12 @@ "propertyLayoutVersion": 3, "properties": { "baseColor": { - "textureMap": "Objects/Lucy/Lucy_bronze_BaseColor.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_BaseColor.png", "textureMapUv": "Unwrapped" }, "detailLayerGroup": { "baseColorDetailMap": "TestData/Textures/cc0/Concrete019_1K_Color.jpg", - "blendDetailMask": "Objects/Lucy/Lucy_ao.tif", + "blendDetailMask": "Objects/Hermanubis/Hermanubis_ao.tif", "blendDetailMaskUv": "Unwrapped", "enableBaseColor": true, "enableDetailLayer": true, @@ -26,16 +26,16 @@ "scale": 10.0 }, "metallic": { - "textureMap": "Objects/Lucy/Lucy_bronze_Metallic.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_Metallic.png", "textureMapUv": "Unwrapped" }, "normal": { "flipY": true, - "textureMap": "Objects/Lucy/Lucy_Normal.png", + "textureMap": "Objects/Hermanubis/Hermanubis_Normal.png", "textureMapUv": "Unwrapped" }, "roughness": { - "textureMap": "Objects/Lucy/Lucy_bronze_Roughness.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_Roughness.png", "textureMapUv": "Unwrapped" } } diff --git a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/103_DetailMaps_BaseColor.material b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/103_DetailMaps_BaseColor.material index 5bddeaa7e5..eda8ef12de 100644 --- a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/103_DetailMaps_BaseColor.material +++ b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/103_DetailMaps_BaseColor.material @@ -1,7 +1,7 @@ { "description": "", "materialType": "Materials/Types/EnhancedPBR.materialtype", - "parentMaterial": "TestData/Materials/StandardPbrTestCases/101_DetailMaps_LucyBaseNoDetailMaps.material", + "parentMaterial": "TestData/Materials/StandardPbrTestCases/101_DetailMaps_BaseNoDetailMaps.material", "propertyLayoutVersion": 3, "properties": { "detailLayerGroup": { diff --git a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/104_DetailMaps_Normal.material b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/104_DetailMaps_Normal.material index 4c64a696d2..291f0fc828 100644 --- a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/104_DetailMaps_Normal.material +++ b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/104_DetailMaps_Normal.material @@ -1,7 +1,7 @@ { "description": "", "materialType": "Materials/Types/EnhancedPBR.materialtype", - "parentMaterial": "TestData/Materials/StandardPbrTestCases/101_DetailMaps_LucyBaseNoDetailMaps.material", + "parentMaterial": "TestData/Materials/StandardPbrTestCases/101_DetailMaps_BaseNoDetailMaps.material", "propertyLayoutVersion": 3, "properties": { "detailLayerGroup": { diff --git a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/105_DetailMaps_BlendMaskUsingDetailUVs.material b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/105_DetailMaps_BlendMaskUsingDetailUVs.material index a69b72b623..6964342447 100644 --- a/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/105_DetailMaps_BlendMaskUsingDetailUVs.material +++ b/Gems/Atom/TestData/TestData/Materials/StandardPbrTestCases/105_DetailMaps_BlendMaskUsingDetailUVs.material @@ -5,7 +5,7 @@ "propertyLayoutVersion": 3, "properties": { "baseColor": { - "textureMap": "Objects/Lucy/Lucy_bronze_BaseColor.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_BaseColor.png", "textureMapUv": "Unwrapped" }, "detailLayerGroup": { @@ -25,16 +25,16 @@ "scale": 10.0 }, "metallic": { - "textureMap": "Objects/Lucy/Lucy_bronze_Metallic.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_Metallic.png", "textureMapUv": "Unwrapped" }, "normal": { "flipY": true, - "textureMap": "Objects/Lucy/Lucy_Normal.png", + "textureMap": "Objects/Hermanubis/Hermanubis_Normal.png", "textureMapUv": "Unwrapped" }, "roughness": { - "textureMap": "Objects/Lucy/Lucy_bronze_Roughness.png", + "textureMap": "Objects/Hermanubis/Hermanubis_bronze_Roughness.png", "textureMapUv": "Unwrapped" } } diff --git a/Gems/Atom/TestData/TestData/Materials/Types/AutoBrick_ForwardPass.azsl b/Gems/Atom/TestData/TestData/Materials/Types/AutoBrick_ForwardPass.azsl index 2dbba46d8b..05ce5f4774 100644 --- a/Gems/Atom/TestData/TestData/Materials/Types/AutoBrick_ForwardPass.azsl +++ b/Gems/Atom/TestData/TestData/Materials/Types/AutoBrick_ForwardPass.azsl @@ -28,7 +28,7 @@ struct VSInput struct VSOutput { - float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float3 m_normal: NORMAL; float3 m_tangent : TANGENT; float3 m_bitangent : BITANGENT; diff --git a/Gems/Atom/TestData/TestData/Materials/Types/MinimalPBR_ForwardPass.azsl b/Gems/Atom/TestData/TestData/Materials/Types/MinimalPBR_ForwardPass.azsl index 2f6f038e4b..fe9e4099d0 100644 --- a/Gems/Atom/TestData/TestData/Materials/Types/MinimalPBR_ForwardPass.azsl +++ b/Gems/Atom/TestData/TestData/Materials/Types/MinimalPBR_ForwardPass.azsl @@ -33,7 +33,7 @@ struct VSInput struct VSOutput { - float4 m_position : SV_Position; + precise linear centroid float4 m_position : SV_Position; float3 m_normal: NORMAL; float3 m_tangent : TANGENT; float3 m_bitangent : BITANGENT; diff --git a/Gems/Atom/Tools/AtomToolsFramework/CMakeLists.txt b/Gems/Atom/Tools/AtomToolsFramework/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Atom/Tools/AtomToolsFramework/CMakeLists.txt +++ b/Gems/Atom/Tools/AtomToolsFramework/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/Tools/AtomToolsFramework/Code/CMakeLists.txt b/Gems/Atom/Tools/AtomToolsFramework/Code/CMakeLists.txt index e7e8208722..0fc896e88a 100644 --- a/Gems/Atom/Tools/AtomToolsFramework/Code/CMakeLists.txt +++ b/Gems/Atom/Tools/AtomToolsFramework/Code/CMakeLists.txt @@ -10,7 +10,7 @@ if(NOT PAL_TRAIT_BUILD_HOST_TOOLS) return() endif() -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME AtomToolsFramework.Static STATIC diff --git a/Gems/Atom/Tools/AtomToolsFramework/Code/Source/Application/AtomToolsApplication.cpp b/Gems/Atom/Tools/AtomToolsFramework/Code/Source/Application/AtomToolsApplication.cpp index ec365d7a6a..02248fffd4 100644 --- a/Gems/Atom/Tools/AtomToolsFramework/Code/Source/Application/AtomToolsApplication.cpp +++ b/Gems/Atom/Tools/AtomToolsFramework/Code/Source/Application/AtomToolsApplication.cpp @@ -12,6 +12,7 @@ #include #include +#include #include #include #include @@ -295,10 +296,24 @@ namespace AtomToolsFramework QMessageBox::critical( activeWindow(), QString("Failed to compile critical assets"), QString("Failed to compile the following critical assets:\n%1\n%2") - .arg(failedAssets.join(",\n")) - .arg("Make sure this is an Atom project.")); + .arg(failedAssets.join(",\n")) + .arg("Make sure this is an Atom project.")); ExitMainLoop(); } + + AZ::ComponentApplicationLifecycle::SignalEvent(*m_settingsRegistry, "CriticalAssetsCompiled", R"({})"); + // Reload the assetcatalog.xml at this point again + // Start Monitoring Asset changes over the network and load the AssetCatalog + auto LoadCatalog = [settingsRegistry = m_settingsRegistry.get()](AZ::Data::AssetCatalogRequests* assetCatalogRequests) + { + if (AZ::IO::FixedMaxPath assetCatalogPath; + settingsRegistry->Get(assetCatalogPath.Native(), AZ::SettingsRegistryMergeUtils::FilePathKey_CacheRootFolder)) + { + assetCatalogPath /= "assetcatalog.xml"; + assetCatalogRequests->LoadCatalog(assetCatalogPath.c_str()); + } + }; + AZ::Data::AssetCatalogRequestBus::Broadcast(AZStd::move(LoadCatalog)); } void AtomToolsApplication::SaveSettings() diff --git a/Gems/Atom/Tools/AtomToolsFramework/Code/Source/DynamicProperty/DynamicProperty.cpp b/Gems/Atom/Tools/AtomToolsFramework/Code/Source/DynamicProperty/DynamicProperty.cpp index 2054858726..d4599b68b7 100644 --- a/Gems/Atom/Tools/AtomToolsFramework/Code/Source/DynamicProperty/DynamicProperty.cpp +++ b/Gems/Atom/Tools/AtomToolsFramework/Code/Source/DynamicProperty/DynamicProperty.cpp @@ -160,7 +160,7 @@ namespace AtomToolsFramework ApplyRangeEditDataAttributes(); break; case DynamicPropertyType::Color: - AddEditDataAttribute(AZ_CRC("ColorEditorConfiguration", 0xc8b9510e), AZ::RPI::ColorUtils::GetLinearRgbEditorConfig()); + AddEditDataAttribute(AZ_CRC("ColorEditorConfiguration", 0xc8b9510e), AZ::RPI::ColorUtils::GetRgbEditorConfig()); break; case DynamicPropertyType::Enum: m_editData.m_elementId = AZ::Edit::UIHandlers::ComboBox; diff --git a/Gems/Atom/Tools/AtomToolsFramework/Code/Source/Viewport/RenderViewportWidget.cpp b/Gems/Atom/Tools/AtomToolsFramework/Code/Source/Viewport/RenderViewportWidget.cpp index 505ff70122..b15cf53427 100644 --- a/Gems/Atom/Tools/AtomToolsFramework/Code/Source/Viewport/RenderViewportWidget.cpp +++ b/Gems/Atom/Tools/AtomToolsFramework/Code/Source/Viewport/RenderViewportWidget.cpp @@ -68,6 +68,7 @@ namespace AtomToolsFramework { return false; } + const AzFramework::ViewportId newId = m_viewportContext->GetId(); SetControllerList(AZStd::make_shared()); @@ -78,14 +79,14 @@ namespace AtomToolsFramework m_viewportInteractionImpl = AZStd::make_unique(m_defaultCamera); m_viewportInteractionImpl->m_deviceScalingFactorFn = [this] { return aznumeric_cast(devicePixelRatioF()); }; m_viewportInteractionImpl->m_screenSizeFn = [this] { return AzFramework::ScreenSize(width(), height()); }; - m_viewportInteractionImpl->Connect(id); + m_viewportInteractionImpl->Connect(newId); AzToolsFramework::ViewportInteraction::ViewportMouseCursorRequestBus::Handler::BusConnect(GetId()); AzFramework::InputChannelEventListener::Connect(); AZ::TickBus::Handler::BusConnect(); AzFramework::WindowRequestBus::Handler::BusConnect(params.windowHandle); - m_inputChannelMapper = new AzToolsFramework::QtEventToAzInputMapper(this, id); + m_inputChannelMapper = new AzToolsFramework::QtEventToAzInputMapper(this, newId); // Forward input events to our controller list. QObject::connect(m_inputChannelMapper, &AzToolsFramework::QtEventToAzInputMapper::InputChannelUpdated, this, diff --git a/Gems/Atom/Tools/AtomToolsFramework/gem.json b/Gems/Atom/Tools/AtomToolsFramework/gem.json index de2a9e06f2..6e5a7b311a 100644 --- a/Gems/Atom/Tools/AtomToolsFramework/gem.json +++ b/Gems/Atom/Tools/AtomToolsFramework/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RPI", "Atom_RHI", diff --git a/Gems/Atom/Tools/CMakeLists.txt b/Gems/Atom/Tools/CMakeLists.txt index 653babd0b3..82a803bdef 100644 --- a/Gems/Atom/Tools/CMakeLists.txt +++ b/Gems/Atom/Tools/CMakeLists.txt @@ -6,6 +6,4 @@ # # -add_subdirectory(AtomToolsFramework) -add_subdirectory(MaterialEditor) add_subdirectory(ShaderManagementConsole) diff --git a/Gems/Atom/Tools/MaterialEditor/CMakeLists.txt b/Gems/Atom/Tools/MaterialEditor/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Atom/Tools/MaterialEditor/CMakeLists.txt +++ b/Gems/Atom/Tools/MaterialEditor/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Atom/Tools/MaterialEditor/Code/CMakeLists.txt b/Gems/Atom/Tools/MaterialEditor/Code/CMakeLists.txt index 99beb721d6..1d9295f9b3 100644 --- a/Gems/Atom/Tools/MaterialEditor/Code/CMakeLists.txt +++ b/Gems/Atom/Tools/MaterialEditor/Code/CMakeLists.txt @@ -10,7 +10,7 @@ if(NOT PAL_TRAIT_BUILD_HOST_TOOLS) return() endif() -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # PAL_TRAIT_ATOM_MATERIAL_EDITOR_APPLICATION_SUPPORTED diff --git a/Gems/Atom/Tools/MaterialEditor/Code/Source/Viewport/MaterialViewportComponent.cpp b/Gems/Atom/Tools/MaterialEditor/Code/Source/Viewport/MaterialViewportComponent.cpp index 35f5067cd0..9cf714b40e 100644 --- a/Gems/Atom/Tools/MaterialEditor/Code/Source/Viewport/MaterialViewportComponent.cpp +++ b/Gems/Atom/Tools/MaterialEditor/Code/Source/Viewport/MaterialViewportComponent.cpp @@ -18,7 +18,7 @@ #include #include #include -#include +#include #include #include #include @@ -165,12 +165,12 @@ namespace MaterialEditor // AssetCatalogRequestBus::EnumerateAssets can lead to deadlocked) AZ::Data::AssetCatalogRequests::AssetEnumerationCB enumerateCB = [this]([[maybe_unused]] const AZ::Data::AssetId id, const AZ::Data::AssetInfo& info) { - if (AzFramework::StringFunc::EndsWith(info.m_relativePath.c_str(), ".lightingpreset.azasset")) + if (AZ::StringFunc::EndsWith(info.m_relativePath.c_str(), ".lightingpreset.azasset")) { m_lightingPresetAssets[info.m_assetId] = { info.m_assetId, info.m_assetType }; AZ::Data::AssetBus::MultiHandler::BusConnect(info.m_assetId); } - else if (AzFramework::StringFunc::EndsWith(info.m_relativePath.c_str(), ".modelpreset.azasset")) + else if (AZ::StringFunc::EndsWith(info.m_relativePath.c_str(), ".modelpreset.azasset")) { m_modelPresetAssets[info.m_assetId] = { info.m_assetId, info.m_assetType }; AZ::Data::AssetBus::MultiHandler::BusConnect(info.m_assetId); @@ -429,4 +429,51 @@ namespace MaterialEditor ReloadContent(); }); } + + void MaterialViewportComponent::OnCatalogAssetChanged(const AZ::Data::AssetId& assetId) + { + auto ReloadLightingAndModelPresets = [this, &assetId](AZ::Data::AssetCatalogRequests* assetCatalogRequests) + { + AZ::Data::AssetInfo assetInfo = assetCatalogRequests->GetAssetInfoById(assetId); + AZ::Data::Asset* modifiedPresetAsset{}; + if (AZ::StringFunc::EndsWith(assetInfo.m_relativePath.c_str(), ".lightingpreset.azasset")) + { + m_lightingPresetAssets[assetInfo.m_assetId] = { assetInfo.m_assetId, assetInfo.m_assetType }; + AZ::Data::AssetBus::MultiHandler::BusConnect(assetInfo.m_assetId); + modifiedPresetAsset = &m_lightingPresetAssets[assetInfo.m_assetId]; + } + else if (AzFramework::StringFunc::EndsWith(assetInfo.m_relativePath.c_str(), ".modelpreset.azasset")) + { + m_modelPresetAssets[assetInfo.m_assetId] = { assetInfo.m_assetId, assetInfo.m_assetType }; + AZ::Data::AssetBus::MultiHandler::BusConnect(assetInfo.m_assetId); + modifiedPresetAsset = &m_modelPresetAssets[assetInfo.m_assetId]; + } + + // Queue a load on the changed asset + if (modifiedPresetAsset != nullptr) + { + modifiedPresetAsset->QueueLoad(); + } + }; + AZ::Data::AssetCatalogRequestBus::Broadcast(AZStd::move(ReloadLightingAndModelPresets)); + } + + void MaterialViewportComponent::OnCatalogAssetAdded(const AZ::Data::AssetId& assetId) + { + OnCatalogAssetChanged(assetId); + } + + void MaterialViewportComponent::OnCatalogAssetRemoved(const AZ::Data::AssetId& assetId, const AZ::Data::AssetInfo& assetInfo) + { + if (AZ::StringFunc::EndsWith(assetInfo.m_relativePath.c_str(), ".lightingpreset.azasset")) + { + AZ::Data::AssetBus::MultiHandler::BusDisconnect(assetInfo.m_assetId); + m_lightingPresetAssets.erase(assetId); + } + if (AZ::StringFunc::EndsWith(assetInfo.m_relativePath.c_str(), ".modelpreset.azasset")) + { + AZ::Data::AssetBus::MultiHandler::BusDisconnect(assetInfo.m_assetId); + m_modelPresetAssets.erase(assetId); + } + } } diff --git a/Gems/Atom/Tools/MaterialEditor/Code/Source/Viewport/MaterialViewportComponent.h b/Gems/Atom/Tools/MaterialEditor/Code/Source/Viewport/MaterialViewportComponent.h index 07385d842d..68668bd804 100644 --- a/Gems/Atom/Tools/MaterialEditor/Code/Source/Viewport/MaterialViewportComponent.h +++ b/Gems/Atom/Tools/MaterialEditor/Code/Source/Viewport/MaterialViewportComponent.h @@ -95,6 +95,9 @@ namespace MaterialEditor //////////////////////////////////////////////////////////////////////// // AzFramework::AssetCatalogEventBus::Handler overrides ... void OnCatalogLoaded(const char* catalogFile) override; + void OnCatalogAssetChanged(const AZ::Data::AssetId& assetId) override; + void OnCatalogAssetAdded(const AZ::Data::AssetId& assetId) override; + void OnCatalogAssetRemoved(const AZ::Data::AssetId& assetId, const AZ::Data::AssetInfo& assetInfo) override; //////////////////////////////////////////////////////////////////////// AZStd::unordered_map> m_lightingPresetAssets; diff --git a/Gems/Atom/Tools/MaterialEditor/gem.json b/Gems/Atom/Tools/MaterialEditor/gem.json index 807e3fa65f..463553c27d 100644 --- a/Gems/Atom/Tools/MaterialEditor/gem.json +++ b/Gems/Atom/Tools/MaterialEditor/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "Editor for creating, modifying, and previewing materials", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "AtomToolsFramework", "Atom_RPI", diff --git a/Gems/Atom/Tools/ShaderManagementConsole/Code/CMakeLists.txt b/Gems/Atom/Tools/ShaderManagementConsole/Code/CMakeLists.txt index d384378b09..3f7788418a 100644 --- a/Gems/Atom/Tools/ShaderManagementConsole/Code/CMakeLists.txt +++ b/Gems/Atom/Tools/ShaderManagementConsole/Code/CMakeLists.txt @@ -10,7 +10,7 @@ if(NOT PAL_TRAIT_BUILD_HOST_TOOLS) return() endif() -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # PAL_TRAIT_ATOM_SHADER_MANAGEMENT_CONSOLE_APPLICATION_SUPPORTED diff --git a/Gems/Atom/Utils/Code/CMakeLists.txt b/Gems/Atom/Utils/Code/CMakeLists.txt index 90d7ce501b..a657262f2d 100644 --- a/Gems/Atom/Utils/Code/CMakeLists.txt +++ b/Gems/Atom/Utils/Code/CMakeLists.txt @@ -6,8 +6,6 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) - ly_add_target( NAME Atom_Utils.Static STATIC NAMESPACE Gem @@ -52,6 +50,9 @@ endif() # Tests ################################################################################ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) + + o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) + ly_add_target( NAME Atom_Utils.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} NAMESPACE Gem diff --git a/Gems/Atom/Utils/Code/Include/Atom/Utils/PngFile.h b/Gems/Atom/Utils/Code/Include/Atom/Utils/PngFile.h index 1de27e9b96..b862786c2f 100644 --- a/Gems/Atom/Utils/Code/Include/Atom/Utils/PngFile.h +++ b/Gems/Atom/Utils/Code/Include/Atom/Utils/PngFile.h @@ -7,6 +7,7 @@ */ #pragma once +#include #include #include #include @@ -53,6 +54,9 @@ namespace AZ //! @return the loaded PngFile or an invalid PngFile if there was an error. static PngFile Load(const char* path, LoadSettings loadSettings = {}); + //! @return the loaded PngFile or an invalid PngFile if there was an error. + static PngFile LoadFromBuffer(AZStd::array_view data, LoadSettings loadSettings = {}); + //! Create a PngFile from an RHI data buffer. //! @param size the dimensions of the image (m_depth is not used, assumed to be 1) //! @param format indicates the pixel format represented by @data. Only a limited set of formats are supported, see implementation. @@ -83,10 +87,12 @@ namespace AZ private: AZ_DEFAULT_COPY(PngFile) - static const int HeaderSize = 8; + static const int HeaderSize = 8; static void DefaultErrorHandler(const char* message); + static PngFile LoadInternal(AZ::IO::GenericStream& dataStream, LoadSettings loadSettings); + uint32_t m_width = 0; uint32_t m_height = 0; int32_t m_bitDepth = 0; diff --git a/Gems/Atom/Utils/Code/Source/PngFile.cpp b/Gems/Atom/Utils/Code/Source/PngFile.cpp index 28f5374d88..1454dc68c9 100644 --- a/Gems/Atom/Utils/Code/Source/PngFile.cpp +++ b/Gems/Atom/Utils/Code/Source/PngFile.cpp @@ -8,6 +8,7 @@ #include #include +#include namespace AZ { @@ -68,24 +69,66 @@ namespace AZ { if (!loadSettings.m_errorHandler) { - loadSettings.m_errorHandler = [path](const char* message) { DefaultErrorHandler(AZStd::string::format("Could not load file '%s'. %s", path, message).c_str()); }; + loadSettings.m_errorHandler = [path](const char* message) + { + DefaultErrorHandler(AZStd::string::format("Could not load file '%s'. %s", path, message).c_str()); + }; + } + + AZ::IO::SystemFile file; + file.Open(path, AZ::IO::SystemFile::SF_OPEN_READ_ONLY); + if (!file.IsOpen()) + { + loadSettings.m_errorHandler("Cannot open file."); + return {}; } + constexpr bool StreamOwnsFilePointer = true; + AZ::IO::SystemFileStream fileLoadStream(&file, StreamOwnsFilePointer); + + auto pngFile = LoadInternal(fileLoadStream, loadSettings); + return pngFile; + } + + PngFile PngFile::LoadFromBuffer(AZStd::array_view data, LoadSettings loadSettings) + { + if (!loadSettings.m_errorHandler) + { + loadSettings.m_errorHandler = [](const char* message) + { + DefaultErrorHandler(AZStd::string::format("Could not load Png from buffer. %s", message).c_str()); + }; + } + + if (data.empty()) + { + loadSettings.m_errorHandler("Buffer is empty."); + return {}; + } + + AZ::IO::MemoryStream memStream(data.data(), data.size()); + + return LoadInternal(memStream, loadSettings); + } + PngFile PngFile::LoadInternal(AZ::IO::GenericStream& dataStream, LoadSettings loadSettings) + { // For documentation of this code, see http://www.libpng.org/pub/png/libpng-1.4.0-manual.pdf chapter 3 - FILE* fp = NULL; - azfopen(&fp, path, "rb"); // return type differs across platforms so can't do inside if - if (!fp) + // Verify that we've passed in a valid data stream. + if (!dataStream.IsOpen() || !dataStream.CanRead()) { - loadSettings.m_errorHandler("Cannot open file."); + loadSettings.m_errorHandler("Data stream isn't valid."); return {}; } png_byte header[HeaderSize] = {}; + size_t headerBytesRead = 0; - if (fread(header, 1, HeaderSize, fp) != HeaderSize) + // This is the one I/O read that occurs outside of the png library, so either read from the file or the buffer and + // verify the results. + headerBytesRead = dataStream.Read(HeaderSize, header); + if (headerBytesRead != HeaderSize) { - fclose(fp); loadSettings.m_errorHandler("Invalid png header."); return {}; } @@ -93,7 +136,6 @@ namespace AZ bool isPng = !png_sig_cmp(header, 0, HeaderSize); if (!isPng) { - fclose(fp); loadSettings.m_errorHandler("Invalid png header."); return {}; } @@ -105,7 +147,6 @@ namespace AZ png_structp png_ptr = png_create_read_struct(PNG_LIBPNG_VER_STRING, user_error_ptr, user_error_fn, user_warning_fn); if (!png_ptr) { - fclose(fp); loadSettings.m_errorHandler("png_create_read_struct failed."); return {}; } @@ -114,7 +155,6 @@ namespace AZ if (!info_ptr) { png_destroy_read_struct(&png_ptr, (png_infopp)NULL, (png_infopp)NULL); - fclose(fp); loadSettings.m_errorHandler("png_create_info_struct failed."); return {}; } @@ -123,22 +163,35 @@ namespace AZ if (!end_info) { png_destroy_read_struct(&png_ptr, &info_ptr, (png_infopp)NULL); - fclose(fp); loadSettings.m_errorHandler("png_create_info_struct failed."); return {}; } -AZ_PUSH_DISABLE_WARNING(4611, "-Wunknown-warning-option") // Disables "interaction between '_setjmp' and C++ object destruction is non-portable". See https://docs.microsoft.com/en-us/cpp/preprocessor/warning?view=msvc-160 +// Disables "interaction between '_setjmp' and C++ object destruction is non-portable". +// See https://docs.microsoft.com/en-us/cpp/preprocessor/warning?view=msvc-160 +AZ_PUSH_DISABLE_WARNING(4611, "-Wunknown-warning-option") if (setjmp(png_jmpbuf(png_ptr))) { png_destroy_read_struct(&png_ptr, &info_ptr, &end_info); - fclose(fp); // We don't report an error message here because the user_error_fn should have done that already. return {}; } AZ_POP_DISABLE_WARNING - png_init_io(png_ptr, fp); + auto genericStreamReader = [](png_structp pngPtr, png_bytep data, png_size_t length) + { + // Here we get our IO pointer back from the read struct. + // This should be the GenericStream pointer we passed to the png_set_read_fn() function. + png_voidp ioPtr = png_get_io_ptr(pngPtr); + + if (ioPtr != nullptr) + { + AZ::IO::GenericStream* genericStream = static_cast(ioPtr); + genericStream->Read(length, data); + } + }; + + png_set_read_fn(png_ptr, &dataStream, genericStreamReader); png_set_sig_bytes(png_ptr, HeaderSize); @@ -187,7 +240,6 @@ AZ_POP_DISABLE_WARNING default: AZ_Assert(false, "The png transforms should have ensured a pixel format of RGB or RGBA, 8 bits per channel"); png_destroy_read_struct(&png_ptr, &info_ptr, (png_infopp)NULL); - fclose(fp); loadSettings.m_errorHandler("Unsupported pixel format."); return {}; } @@ -201,7 +253,6 @@ AZ_POP_DISABLE_WARNING } png_destroy_read_struct(&png_ptr, &info_ptr, &end_info); - fclose(fp); return pngFile; } @@ -322,3 +373,4 @@ AZ_POP_DISABLE_WARNING } // namespace Utils }// namespace AZ + diff --git a/Gems/Atom/Utils/Code/Tests/PngFileTests.cpp b/Gems/Atom/Utils/Code/Tests/PngFileTests.cpp index b60939b39b..436b9ae752 100644 --- a/Gems/Atom/Utils/Code/Tests/PngFileTests.cpp +++ b/Gems/Atom/Utils/Code/Tests/PngFileTests.cpp @@ -311,4 +311,66 @@ namespace UnitTest EXPECT_TRUE(gotErrorMessage.find("PngFile is invalid") != AZStd::string::npos); EXPECT_FALSE(AZ::IO::FileIOBase::GetInstance()->Exists(m_tempPngFilePath.c_str())); } -} + + TEST_F(PngFileTests, LoadRgbFromMemoryBuffer) + { + // This is an in-memory copy of the ColorChart_rgb.png test file. + AZStd::fixed_vector pngBuffer = + { + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, + 0x00, 0x00, 0x00, 0x0d, 0x49, 0x48, 0x44, 0x52, + + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x02, + 0x08, 0x02, 0x00, 0x00, 0x00, 0x12, 0x16, 0xf1, + + 0x4d, 0x00, 0x00, 0x00, 0x01, 0x73, 0x52, 0x47, + 0x42, 0x00, 0xae, 0xce, 0x1c, 0xe9, 0x00, 0x00, + + 0x00, 0x04, 0x67, 0x41, 0x4d, 0x41, 0x00, 0x00, + 0xb1, 0x8f, 0x0b, 0xfc, 0x61, 0x05, 0x00, 0x00, + + 0x00, 0x09, 0x70, 0x48, 0x59, 0x73, 0x00, 0x00, + 0x0e, 0xc3, 0x00, 0x00, 0x0e, 0xc3, 0x01, 0xc7, + + 0x6f, 0xa8, 0x64, 0x00, 0x00, 0x00, 0x13, 0x49, + 0x44, 0x41, 0x54, 0x18, 0x57, 0x63, 0xf8, 0xcf, + + 0xc0, 0x00, 0xc1, 0x4c, 0x10, 0xea, 0x3f, 0x03, + 0x03, 0x00, 0x3b, 0xec, 0x05, 0xfd, 0x6a, 0x50, + + 0x07, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, + 0x4e, 0x44, 0xae, 0x42, 0x60, 0x82 + }; + + PngFile image = PngFile::LoadFromBuffer(pngBuffer); + EXPECT_TRUE(image.IsValid()); + EXPECT_EQ(image.GetBufferFormat(), PngFile::Format::RGB); + EXPECT_EQ(image.GetWidth(), 3); + EXPECT_EQ(image.GetHeight(), 2); + EXPECT_EQ(image.GetBuffer().size(), 18); + EXPECT_EQ(Color3(image.GetBuffer().begin() + 0), Color3(255u, 0u, 0u)); + EXPECT_EQ(Color3(image.GetBuffer().begin() + 3), Color3(0u, 255u, 0u)); + EXPECT_EQ(Color3(image.GetBuffer().begin() + 6), Color3(0u, 0u, 255u)); + EXPECT_EQ(Color3(image.GetBuffer().begin() + 9), Color3(255u, 255u, 0u)); + EXPECT_EQ(Color3(image.GetBuffer().begin() + 12), Color3(0u, 255u, 255u)); + EXPECT_EQ(Color3(image.GetBuffer().begin() + 15), Color3(255u, 0u, 255u)); + } + + TEST_F(PngFileTests, ErrorCannotLoadEmptyMemoryBuffer) + { + AZStd::vector pngBuffer; + + AZStd::string gotErrorMessage; + + PngFile::LoadSettings loadSettings; + loadSettings.m_errorHandler = [&gotErrorMessage](const char* errorMessage) + { + gotErrorMessage = errorMessage; + }; + + PngFile image = PngFile::LoadFromBuffer(pngBuffer, loadSettings); + EXPECT_FALSE(image.IsValid()); + EXPECT_TRUE(gotErrorMessage.find("Buffer is empty") != AZStd::string::npos); + } + +} // namespace UnitTest diff --git a/Gems/Atom/gem.json b/Gems/Atom/gem.json index 0f409ad993..ee6a617ee7 100644 --- a/Gems/Atom/gem.json +++ b/Gems/Atom/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Atom Renderer Gem provides Atom Renderer and its associated tools (such as Material Editor), utilites, libraries, and interfaces.", "canonical_tags": [ @@ -15,6 +16,17 @@ ], "requirements": "", "documentation_url": "https://o3de.org/docs/user-guide/gems/reference/rendering/atom/atom/", + "external_subdirectories": [ + "Asset/ImageProcessingAtom", + "Asset/Shader", + "Bootstrap", + "Component/DebugCamera", + "Feature/Common", + "RHI", + "RPI", + "Tools/AtomToolsFramework", + "Tools/MaterialEditor" + ], "dependencies": [ "Atom_Feature_Common", "AtomShader", diff --git a/Gems/AtomContent/CMakeLists.txt b/Gems/AtomContent/CMakeLists.txt index ee06f07bc3..29477608b9 100644 --- a/Gems/AtomContent/CMakeLists.txt +++ b/Gems/AtomContent/CMakeLists.txt @@ -5,8 +5,6 @@ # SPDX-License-Identifier: Apache-2.0 OR MIT # # -add_subdirectory(ReferenceMaterials) -add_subdirectory(Sponza) if(PAL_TRAIT_BUILD_HOST_TOOLS) ly_create_alias(NAME AtomContent.Builders NAMESPACE Gem TARGETS Gem::AtomContent_ReferenceMaterials.Builders Gem::AtomContent_Sponza.Builders) diff --git a/Gems/AtomContent/ReferenceMaterials/gem.json b/Gems/AtomContent/ReferenceMaterials/gem.json index b75b01e1ae..49a488b9d3 100644 --- a/Gems/AtomContent/ReferenceMaterials/gem.json +++ b/Gems/AtomContent/ReferenceMaterials/gem.json @@ -2,7 +2,9 @@ "gem_name": "ReferenceMaterials", "display_name": "PBR Reference Materials", "license": "Code, text, data files: Apache-2.0 Or MIT, assets/content/images: CC BY 4.0", - "origin": "https://github.com/aws-lumberyard-dev/o3de.git", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "Atom Asset Gem with a library of reference materials for StandardPBR (and others in the future)", "canonical_tags": [ @@ -14,6 +16,8 @@ "Materials" ], "icon_path": "preview.png", - "dependencies": [], - "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt" + "requirements": "", + "documentation_url": "", + "dependencies": [ + ] } diff --git a/Gems/AtomContent/Sponza/gem.json b/Gems/AtomContent/Sponza/gem.json index 68749cd5f4..f15d57a4d1 100644 --- a/Gems/AtomContent/Sponza/gem.json +++ b/Gems/AtomContent/Sponza/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "A standard test scene for Global Illumination (forked from crytek sponza scene)", "canonical_tags": [ @@ -13,5 +14,7 @@ "Assets" ], "requirements": "", - "dependencies": [] + "documentation_url": "", + "dependencies": [ + ] } diff --git a/Gems/AtomContent/gem.json b/Gems/AtomContent/gem.json index 400e897a3b..9be15f7da8 100644 --- a/Gems/AtomContent/gem.json +++ b/Gems/AtomContent/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "The Atom Content Gem provides assets for Atom Renderer and a modified version of the Pixar Look Development Studio.", "canonical_tags": [ @@ -17,7 +18,11 @@ "requirements": "", "documentation_url": "https://o3de.org/docs/user-guide/gems/reference/rendering/atom/atom-content/", "dependencies": [ - "ReferenceMaterials", - "Sponza" + "Sponza", + "ReferenceMaterials" + ], + "external_subdirectories": [ + "Sponza", + "ReferenceMaterials" ] } diff --git a/Gems/AtomLyIntegration/AtomBridge/CMakeLists.txt b/Gems/AtomLyIntegration/AtomBridge/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/AtomLyIntegration/AtomBridge/CMakeLists.txt +++ b/Gems/AtomLyIntegration/AtomBridge/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/AtomLyIntegration/AtomBridge/Code/CMakeLists.txt b/Gems/AtomLyIntegration/AtomBridge/Code/CMakeLists.txt index e53a0c6281..fa3669d7c2 100644 --- a/Gems/AtomLyIntegration/AtomBridge/Code/CMakeLists.txt +++ b/Gems/AtomLyIntegration/AtomBridge/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME Atom_AtomBridge.Static STATIC @@ -68,6 +68,14 @@ ly_create_alias(NAME Atom_AtomBridge.Clients NAMESPACE Gem TARGETS Gem::Atom_Ato ly_create_alias(NAME Atom_AtomBridge.Servers NAMESPACE Gem TARGETS Gem::Atom_AtomBridge) if(PAL_TRAIT_BUILD_HOST_TOOLS) + + set(additional_tool_deps ${pal_dir}/additional_${PAL_PLATFORM_NAME_LOWERCASE}_tool_deps.cmake) + foreach(pal_tools_platform ${LY_PAL_TOOLS_ENABLED}) + string(TOLOWER ${pal_tools_platform} pal_tools_platform_lowercase) + ly_get_list_relative_pal_filename(pal_runtime_dependencies_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${pal_tools_platform}) + list(APPEND additional_tool_deps ${pal_runtime_dependencies_source_dir}/additional_${pal_tools_platform_lowercase}_tool_deps.cmake) + endforeach() + ly_add_target( NAME Atom_AtomBridge.Editor ${PAL_TRAIT_MONOLITHIC_DRIVEN_MODULE_TYPE} NAMESPACE Gem @@ -79,7 +87,7 @@ if(PAL_TRAIT_BUILD_HOST_TOOLS) PUBLIC Include PLATFORM_INCLUDE_FILES - ${pal_dir}/additional_${PAL_PLATFORM_NAME_LOWERCASE}_tool_deps.cmake + ${additional_tool_deps} COMPILE_DEFINITIONS PRIVATE EDITOR diff --git a/Gems/AtomLyIntegration/AtomBridge/Code/Source/AtomDebugDisplayViewportInterface.cpp b/Gems/AtomLyIntegration/AtomBridge/Code/Source/AtomDebugDisplayViewportInterface.cpp index af91615283..352ffb6486 100644 --- a/Gems/AtomLyIntegration/AtomBridge/Code/Source/AtomDebugDisplayViewportInterface.cpp +++ b/Gems/AtomLyIntegration/AtomBridge/Code/Source/AtomDebugDisplayViewportInterface.cpp @@ -348,14 +348,7 @@ namespace AZ::AtomBridge void AtomDebugDisplayViewportInterface::SetAlpha(float a) { m_rendState.m_color.SetA(a); - if (a < 1.0f) - { - m_rendState.m_opacityType = AZ::RPI::AuxGeomDraw::OpacityType::Opaque; - } - else - { - m_rendState.m_opacityType = AZ::RPI::AuxGeomDraw::OpacityType::Translucent; - } + m_rendState.m_opacityType = a < 1.0f ? AZ::RPI::AuxGeomDraw::OpacityType::Translucent : AZ::RPI::AuxGeomDraw::OpacityType::Opaque; } void AtomDebugDisplayViewportInterface::DrawQuad( diff --git a/Gems/AtomLyIntegration/AtomBridge/gem.json b/Gems/AtomLyIntegration/AtomBridge/gem.json index e8ca413023..5a8512c90d 100644 --- a/Gems/AtomLyIntegration/AtomBridge/gem.json +++ b/Gems/AtomLyIntegration/AtomBridge/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RPI", "Atom_Bootstrap", diff --git a/Gems/AtomLyIntegration/AtomFont/CMakeLists.txt b/Gems/AtomLyIntegration/AtomFont/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/AtomLyIntegration/AtomFont/CMakeLists.txt +++ b/Gems/AtomLyIntegration/AtomFont/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/AtomLyIntegration/AtomFont/Code/CMakeLists.txt b/Gems/AtomLyIntegration/AtomFont/Code/CMakeLists.txt index 6567736f02..79d97e797d 100644 --- a/Gems/AtomLyIntegration/AtomFont/Code/CMakeLists.txt +++ b/Gems/AtomLyIntegration/AtomFont/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME AtomFont ${PAL_TRAIT_MONOLITHIC_DRIVEN_MODULE_TYPE} diff --git a/Gems/AtomLyIntegration/AtomFont/gem.json b/Gems/AtomLyIntegration/AtomFont/gem.json index 8907ec0979..d979509059 100644 --- a/Gems/AtomLyIntegration/AtomFont/gem.json +++ b/Gems/AtomLyIntegration/AtomFont/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI", "Atom_RPI", diff --git a/Gems/AtomLyIntegration/AtomImGuiTools/gem.json b/Gems/AtomLyIntegration/AtomImGuiTools/gem.json index e188ba0cb8..205120f6f0 100644 --- a/Gems/AtomLyIntegration/AtomImGuiTools/gem.json +++ b/Gems/AtomLyIntegration/AtomImGuiTools/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "", "canonical_tags": [ @@ -14,6 +15,7 @@ "Rendering" ], "requirements": "", + "documentation_url": "", "dependencies": [ "ImguiAtom", "Atom" diff --git a/Gems/AtomLyIntegration/AtomViewportDisplayIcons/gem.json b/Gems/AtomLyIntegration/AtomViewportDisplayIcons/gem.json index 5a0763e0da..cff957c1f1 100644 --- a/Gems/AtomLyIntegration/AtomViewportDisplayIcons/gem.json +++ b/Gems/AtomLyIntegration/AtomViewportDisplayIcons/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI", "Atom_RPI", diff --git a/Gems/AtomLyIntegration/AtomViewportDisplayInfo/Code/Source/AtomViewportDisplayInfoSystemComponent.cpp b/Gems/AtomLyIntegration/AtomViewportDisplayInfo/Code/Source/AtomViewportDisplayInfoSystemComponent.cpp index 91844c9b2f..0b11437620 100644 --- a/Gems/AtomLyIntegration/AtomViewportDisplayInfo/Code/Source/AtomViewportDisplayInfoSystemComponent.cpp +++ b/Gems/AtomLyIntegration/AtomViewportDisplayInfo/Code/Source/AtomViewportDisplayInfoSystemComponent.cpp @@ -285,13 +285,19 @@ namespace AZ::Render const double frameIntervalSeconds = m_fpsInterval.count(); + auto ClampedFloatDisplay = [](double value, const char* format) -> AZStd::string + { + constexpr float upperLimit = 10000.0f; + return value > upperLimit ? "inf" : AZStd::string::format(format, value); + }; + DrawLine( AZStd::string::format( - "FPS %.1f [%.0f..%.0f], %.1fms/frame, avg over %.1fs", - averageFPS, - minFPS, - maxFPS, - averageFrameMs, + "FPS %s [%s..%s], %sms/frame, avg over %.1fs", + ClampedFloatDisplay(averageFPS, "%.1f").c_str(), + ClampedFloatDisplay(minFPS, "%.0f").c_str(), + ClampedFloatDisplay(maxFPS, "%.0f").c_str(), + ClampedFloatDisplay(averageFrameMs, "%.1f").c_str(), frameIntervalSeconds), AZ::Colors::Yellow); } diff --git a/Gems/AtomLyIntegration/AtomViewportDisplayInfo/gem.json b/Gems/AtomLyIntegration/AtomViewportDisplayInfo/gem.json index 639d93d301..a2bc92c76d 100644 --- a/Gems/AtomLyIntegration/AtomViewportDisplayInfo/gem.json +++ b/Gems/AtomLyIntegration/AtomViewportDisplayInfo/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RHI", "Atom_RPI" diff --git a/Gems/AtomLyIntegration/CMakeLists.txt b/Gems/AtomLyIntegration/CMakeLists.txt index 4ab976d68f..25d7356b01 100644 --- a/Gems/AtomLyIntegration/CMakeLists.txt +++ b/Gems/AtomLyIntegration/CMakeLists.txt @@ -6,13 +6,4 @@ # # -add_subdirectory(CommonFeatures) -add_subdirectory(ImguiAtom) -add_subdirectory(AtomImGuiTools) -add_subdirectory(EMotionFXAtom) -add_subdirectory(AtomFont) -add_subdirectory(TechnicalArt) -add_subdirectory(AtomBridge) -add_subdirectory(AtomViewportDisplayInfo) -add_subdirectory(AtomViewportDisplayIcons) diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_Curvature.tif b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_Curvature.tif similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_Curvature.tif rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_Curvature.tif diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_High.fbx b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_High.fbx new file mode 100644 index 0000000000..0625c89874 --- /dev/null +++ b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_High.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d72cec207a7677ba027eac72f41285907237e04a45ebacf64341de86fc6f022d +size 159115308 diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_Normal.png b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_Normal.png similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_Normal.png rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_Normal.png diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_Stone_BaseColor.png b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_Stone_BaseColor.png similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_Stone_BaseColor.png rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_Stone_BaseColor.png diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_ao.tif b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_ao.tif similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_ao.tif rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_ao.tif diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/lucy_brass.material b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_brass.material similarity index 59% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/lucy_brass.material rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_brass.material index 6e490cb0b1..4ad325b086 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/lucy_brass.material +++ b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_brass.material @@ -1,39 +1,33 @@ { "description": "", - "materialType": "Materials/Types/StandardPBR.materialtype", "parentMaterial": "Materials/Presets/PBR/metal_brass.material", - "propertyLayoutVersion": 3, + "materialType": "Materials/Types/StandardPBR.materialtype", + "materialTypeVersion": 4, "properties": { - "occlusion": { - "diffuseTextureMap": "Objects/Lucy/Lucy_ao.tif", - "diffuseTextureMapUv": "Unwrapped" - }, "baseColor": { - "color": [ - 0.6745098233222961, - 0.48627451062202456, - 0.19607843458652497, - 1.0 - ], "factor": 1.0, "textureBlendMode": "Lerp", - "textureMap": "Objects/Lucy/Lucy_bronze_BaseColor.png", + "textureMap": "Hermanubis_bronze_BaseColor.png", "textureMapUv": "Unwrapped" }, "general": { "applySpecularAA": true }, "metallic": { - "textureMap": "Objects/Lucy/Lucy_bronze_Metallic.png", + "textureMap": "Hermanubis_bronze_Metallic.png", "textureMapUv": "Unwrapped" }, "normal": { "flipY": true, - "textureMap": "Objects/Lucy/Lucy_Normal.png", + "textureMap": "Hermanubis_Normal.png", "textureMapUv": "Unwrapped" }, + "occlusion": { + "diffuseTextureMap": "Hermanubis_ao.tif", + "diffuseTextureMapUv": "Unwrapped" + }, "roughness": { - "textureMap": "Objects/Lucy/Lucy_bronze_Roughness.png", + "textureMap": "Hermanubis_bronze_Roughness.png", "textureMapUv": "Unwrapped", "upperBound": 0.6767677068710327 } diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_brass_cavity.tif b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_brass_cavity.tif similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_brass_cavity.tif rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_brass_cavity.tif diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_bronze_BaseColor.png b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_bronze_BaseColor.png similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_bronze_BaseColor.png rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_bronze_BaseColor.png diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_bronze_Metallic.png b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_bronze_Metallic.png similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_bronze_Metallic.png rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_bronze_Metallic.png diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_bronze_Roughness.png b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_bronze_Roughness.png similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_bronze_Roughness.png rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_bronze_Roughness.png diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_convexity.tif b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_convexity.tif similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_convexity.tif rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_convexity.tif diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_low.fbx b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_low.fbx new file mode 100644 index 0000000000..79960433dd --- /dev/null +++ b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_low.fbx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4c9d1030b9467b58d640fbedf1bc58ab9a5f7d68811b2452dd8d60114287b731 +size 12410812 diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/lucy_stone.material b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_stone.material similarity index 77% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/lucy_stone.material rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_stone.material index a0e54d9d0e..1ba59a50c5 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/lucy_stone.material +++ b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_stone.material @@ -1,13 +1,9 @@ { "description": "", - "materialType": "Materials/Types/StandardPBR.materialtype", "parentMaterial": "Materials/Presets/PBR/metal_brass.material", - "propertyLayoutVersion": 3, + "materialType": "Materials/Types/StandardPBR.materialtype", + "materialTypeVersion": 4, "properties": { - "occlusion": { - "diffuseTextureMap": "Objects/Lucy/Lucy_ao.tif", - "diffuseTextureMapUv": "Unwrapped" - }, "baseColor": { "color": [ 1.0, @@ -17,7 +13,7 @@ ], "factor": 1.0, "textureBlendMode": "Lerp", - "textureMap": "Objects/Lucy/Lucy_Stone_BaseColor.png", + "textureMap": "Hermanubis_Stone_BaseColor.png", "textureMapUv": "Unwrapped" }, "clearCoat": { @@ -39,13 +35,17 @@ }, "normal": { "flipY": true, - "textureMap": "Objects/Lucy/Lucy_Normal.png", + "textureMap": "Hermanubis_Normal.png", "textureMapUv": "Unwrapped" }, + "occlusion": { + "diffuseTextureMap": "Hermanubis_ao.tif", + "diffuseTextureMapUv": "Unwrapped" + }, "roughness": { "factor": 1.0, - "lowerBound": 0.15000000596046449, - "textureMap": "Objects/Lucy/Lucy_bronze_Roughness.png", + "lowerBound": 0.15000000596046448, + "textureMap": "Hermanubis_bronze_Roughness.png", "textureMapUv": "Unwrapped", "upperBound": 0.7300000190734863 } diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_thickness.tif b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_thickness.tif similarity index 100% rename from Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_thickness.tif rename to Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Hermanubis/Hermanubis_thickness.tif diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_High.fbx b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_High.fbx deleted file mode 100644 index b87971bf6d..0000000000 --- a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_High.fbx +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:00e19e317613be5420fd78bac1159e66d1c4deeb1f32cd4fc8c20b1ea3a5ead1 -size 153114272 diff --git a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_low.fbx b/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_low.fbx deleted file mode 100644 index 46f5d1cfbd..0000000000 --- a/Gems/AtomLyIntegration/CommonFeatures/Assets/Objects/Lucy/Lucy_low.fbx +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:6a4a65d139a6088dd4ac34f3ba3f6a7a98b8fe9545150ee7d9879fbc2a55d8d4 -size 9022128 diff --git a/Gems/AtomLyIntegration/CommonFeatures/CMakeLists.txt b/Gems/AtomLyIntegration/CommonFeatures/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/CMakeLists.txt +++ b/Gems/AtomLyIntegration/CommonFeatures/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/CMakeLists.txt b/Gems/AtomLyIntegration/CommonFeatures/Code/CMakeLists.txt index 7b685ece13..3234db2292 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/CMakeLists.txt +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) ly_add_target( NAME AtomLyIntegration_CommonFeatures.Public HEADERONLY diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Include/AtomLyIntegration/CommonFeatures/CoreLights/DirectionalLightBus.h b/Gems/AtomLyIntegration/CommonFeatures/Code/Include/AtomLyIntegration/CommonFeatures/CoreLights/DirectionalLightBus.h index 3cafc183a5..ebccccadcd 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Include/AtomLyIntegration/CommonFeatures/CoreLights/DirectionalLightBus.h +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Include/AtomLyIntegration/CommonFeatures/CoreLights/DirectionalLightBus.h @@ -184,6 +184,14 @@ namespace AZ //! Reduces acne by biasing the shadowmap lookup along the geometric normal. //! @param normalShadowBias Sets the amount of normal shadow bias to apply. virtual void SetNormalShadowBias(float normalShadowBias) = 0; + + //! Gets whether the directional shadow map has cascade blending enabled. + //! This smooths out the border between cascades at the cost of some performance in the blend area. + virtual bool GetCascadeBlendingEnabled() const = 0; + + //! Sets whether the directional shadow map has cascade blending enabled. + //! @param enable flag specifying whether to enable cascade blending. + virtual void SetCascadeBlendingEnabled(bool enable) = 0; }; using DirectionalLightRequestBus = EBus; diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Include/AtomLyIntegration/CommonFeatures/CoreLights/DirectionalLightComponentConfig.h b/Gems/AtomLyIntegration/CommonFeatures/Code/Include/AtomLyIntegration/CommonFeatures/CoreLights/DirectionalLightComponentConfig.h index 92d5cc9ac0..ca872d78d6 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Include/AtomLyIntegration/CommonFeatures/CoreLights/DirectionalLightComponentConfig.h +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Include/AtomLyIntegration/CommonFeatures/CoreLights/DirectionalLightComponentConfig.h @@ -115,6 +115,9 @@ namespace AZ //! Reduces shadow acne by applying a small amount of offset along shadow-space z. float m_shadowBias = 0.0f; + // If true, sample between two adjacent shadow map cascades in a small boundary area to smooth out the transition. + bool m_cascadeBlendingEnabled = false; + bool IsSplitManual() const; bool IsSplitAutomatic() const; bool IsCascadeCorrectionDisabled() const; diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/Animation/AttachmentComponent.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/Animation/AttachmentComponent.cpp index ee66518779..e8cf03d26e 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/Animation/AttachmentComponent.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/Animation/AttachmentComponent.cpp @@ -10,7 +10,6 @@ #include #include #include -#include #include #include #include @@ -58,13 +57,17 @@ namespace AZ behaviorContext->EBus("AttachmentComponentRequestBus") ->Event("Attach", &LmbrCentral::AttachmentComponentRequestBus::Events::Attach) ->Event("Detach", &LmbrCentral::AttachmentComponentRequestBus::Events::Detach) - ->Event("SetAttachmentOffset", &LmbrCentral::AttachmentComponentRequestBus::Events::SetAttachmentOffset); + ->Event("SetAttachmentOffset", &LmbrCentral::AttachmentComponentRequestBus::Events::SetAttachmentOffset) + ->Event("GetJointName", &LmbrCentral::AttachmentComponentRequestBus::Events::GetJointName) + ->Event("GetTargetEntityId", &LmbrCentral::AttachmentComponentRequestBus::Events::GetTargetEntityId) + ->Event("GetOffset", &LmbrCentral::AttachmentComponentRequestBus::Events::GetOffset); behaviorContext->EBus("AttachmentComponentNotificationBus") ->Handler(); } } + void AttachmentComponent::Reflect(AZ::ReflectContext* context) { AttachmentConfiguration::Reflect(context); diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/AreaLightComponentController.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/AreaLightComponentController.cpp index 7668477690..d67548c3e9 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/AreaLightComponentController.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/AreaLightComponentController.cpp @@ -261,6 +261,11 @@ namespace AZ::Render m_lightShapeDelegate->SetPhotometricUnit(m_configuration.m_intensityMode); m_lightShapeDelegate->SetIntensity(m_configuration.m_intensity); } + + if (m_configuration.m_attenuationRadiusMode == LightAttenuationRadiusMode::Automatic) + { + AttenuationRadiusChanged(); + } } void AreaLightComponentController::ChromaChanged() diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentConfig.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentConfig.cpp index 78a9cc21d1..d9f93cc825 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentConfig.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentConfig.cpp @@ -40,7 +40,8 @@ namespace AZ ->Field("PcfFilteringSampleCount", &DirectionalLightComponentConfig::m_filteringSampleCount) ->Field("ShadowReceiverPlaneBiasEnabled", &DirectionalLightComponentConfig::m_receiverPlaneBiasEnabled) ->Field("Shadow Bias", &DirectionalLightComponentConfig::m_shadowBias) - ->Field("Normal Shadow Bias", &DirectionalLightComponentConfig::m_normalShadowBias); + ->Field("Normal Shadow Bias", &DirectionalLightComponentConfig::m_normalShadowBias) + ->Field("CascadeBlendingEnabled", &DirectionalLightComponentConfig::m_cascadeBlendingEnabled); } } @@ -113,8 +114,7 @@ namespace AZ bool DirectionalLightComponentConfig::IsShadowPcfDisabled() const { - return !(m_shadowFilterMethod == ShadowFilterMethod::Pcf || - m_shadowFilterMethod == ShadowFilterMethod::EsmPcf); + return !(m_shadowFilterMethod == ShadowFilterMethod::Pcf); } bool DirectionalLightComponentConfig::IsEsmDisabled() const diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentController.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentController.cpp index e36868c4bb..ce39a32b19 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentController.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentController.cpp @@ -88,6 +88,8 @@ namespace AZ ->Event("SetShadowBias", &DirectionalLightRequestBus::Events::SetShadowBias) ->Event("GetNormalShadowBias", &DirectionalLightRequestBus::Events::GetNormalShadowBias) ->Event("SetNormalShadowBias", &DirectionalLightRequestBus::Events::SetNormalShadowBias) + ->Event("GetCascadeBlendingEnabled", &DirectionalLightRequestBus::Events::GetCascadeBlendingEnabled) + ->Event("SetCascadeBlendingEnabled", &DirectionalLightRequestBus::Events::SetCascadeBlendingEnabled) ->VirtualProperty("Color", "GetColor", "SetColor") ->VirtualProperty("Intensity", "GetIntensity", "SetIntensity") ->VirtualProperty("AngularDiameter", "GetAngularDiameter", "SetAngularDiameter") @@ -104,7 +106,8 @@ namespace AZ ->VirtualProperty("FilteringSampleCount", "GetFilteringSampleCount", "SetFilteringSampleCount") ->VirtualProperty("ShadowReceiverPlaneBiasEnabled", "GetShadowReceiverPlaneBiasEnabled", "SetShadowReceiverPlaneBiasEnabled") ->VirtualProperty("ShadowBias", "GetShadowBias", "SetShadowBias") - ->VirtualProperty("NormalShadowBias", "GetNormalShadowBias", "SetNormalShadowBias"); + ->VirtualProperty("NormalShadowBias", "GetNormalShadowBias", "SetNormalShadowBias") + ->VirtualProperty("BlendBetweenCascadesEnabled", "GetCascadeBlendingEnabled", "SetCascadeBlendingEnabled"); ; } } @@ -537,6 +540,7 @@ namespace AZ SetNormalShadowBias(m_configuration.m_normalShadowBias); SetFilteringSampleCount(m_configuration.m_filteringSampleCount); SetShadowReceiverPlaneBiasEnabled(m_configuration.m_receiverPlaneBiasEnabled); + SetCascadeBlendingEnabled(m_configuration.m_cascadeBlendingEnabled); // [GFX TODO][ATOM-1726] share config for multiple light (e.g., light ID). // [GFX TODO][ATOM-2416] adapt to multiple viewports. @@ -636,5 +640,16 @@ namespace AZ m_featureProcessor->SetShadowReceiverPlaneBiasEnabled(m_lightHandle, enable); } + bool DirectionalLightComponentController::GetCascadeBlendingEnabled() const + { + return m_configuration.m_cascadeBlendingEnabled; + } + + void DirectionalLightComponentController::SetCascadeBlendingEnabled(bool enable) + { + m_configuration.m_cascadeBlendingEnabled = enable; + m_featureProcessor->SetCascadeBlendingEnabled(m_lightHandle, enable); + } + } // namespace Render } // namespace AZ diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentController.h b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentController.h index 9a6edda666..4aa8aed2fd 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentController.h +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/DirectionalLightComponentController.h @@ -83,7 +83,9 @@ namespace AZ float GetShadowBias() const override; void SetShadowBias(float bias) override; float GetNormalShadowBias() const override; - void SetNormalShadowBias(float bias) override; + void SetNormalShadowBias(float bias) override; + bool GetCascadeBlendingEnabled() const override; + void SetCascadeBlendingEnabled(bool enable) override; private: friend class EditorDirectionalLightComponent; diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/EditorAreaLightComponent.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/EditorAreaLightComponent.cpp index 02c9f77436..d15862451a 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/EditorAreaLightComponent.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/EditorAreaLightComponent.cpp @@ -75,7 +75,7 @@ namespace AZ ->DataElement(Edit::UIHandlers::Color, &AreaLightComponentConfig::m_color, "Color", "Color of the light") ->Attribute(Edit::Attributes::ChangeNotify, Edit::PropertyRefreshLevels::ValuesOnly) ->Attribute(Edit::Attributes::Visibility, &AreaLightComponentConfig::LightTypeIsSelected) - ->Attribute("ColorEditorConfiguration", RPI::ColorUtils::GetLinearRgbEditorConfig()) + ->Attribute("ColorEditorConfiguration", RPI::ColorUtils::GetRgbEditorConfig()) ->DataElement(Edit::UIHandlers::ComboBox, &AreaLightComponentConfig::m_intensityMode, "Intensity mode", "Allows specifying which photometric unit to work in.") ->Attribute(AZ::Edit::Attributes::EnumValues, &AreaLightComponentConfig::GetValidPhotometricUnits) ->Attribute(Edit::Attributes::Visibility, &AreaLightComponentConfig::LightTypeIsSelected) diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/EditorDirectionalLightComponent.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/EditorDirectionalLightComponent.cpp index 545064b86f..1759b830d2 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/EditorDirectionalLightComponent.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/CoreLights/EditorDirectionalLightComponent.cpp @@ -59,7 +59,7 @@ namespace AZ ->ClassElement(Edit::ClassElements::EditorData, "") ->DataElement(Edit::UIHandlers::Color, &DirectionalLightComponentConfig::m_color, "Color", "Color of the light") ->Attribute(Edit::Attributes::ChangeNotify, Edit::PropertyRefreshLevels::ValuesOnly) - ->Attribute("ColorEditorConfiguration", AZ::RPI::ColorUtils::GetLinearRgbEditorConfig()) + ->Attribute("ColorEditorConfiguration", AZ::RPI::ColorUtils::GetRgbEditorConfig()) ->DataElement(Edit::UIHandlers::ComboBox, &DirectionalLightComponentConfig::m_intensityMode, "Intensity mode", "Allows specifying light values in lux or Ev100") ->EnumAttribute(PhotometricUnit::Lux, "Lux") ->EnumAttribute(PhotometricUnit::Ev100Illuminance, "Ev100") @@ -161,7 +161,11 @@ namespace AZ ->Attribute(Edit::Attributes::Min, 0.f) ->Attribute(Edit::Attributes::Max, 10.0f) ->Attribute(Edit::Attributes::ChangeNotify, Edit::PropertyRefreshLevels::ValuesOnly) - ; + ->DataElement( + Edit::UIHandlers::CheckBox, &DirectionalLightComponentConfig::m_cascadeBlendingEnabled, + "Blend between cascades\n", "Enables smooth blending between shadow map cascades.") + ->Attribute(Edit::Attributes::ReadOnly, &DirectionalLightComponentConfig::IsShadowPcfDisabled) + ; } } diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/EditorCommonFeaturesSystemComponent.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/EditorCommonFeaturesSystemComponent.cpp index 2bf428bd2d..0250640d65 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/EditorCommonFeaturesSystemComponent.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/EditorCommonFeaturesSystemComponent.cpp @@ -6,6 +6,7 @@ * */ +#include #include #include #include @@ -88,14 +89,22 @@ namespace AZ AzToolsFramework::EditorLevelNotificationBus::Handler::BusConnect(); AzToolsFramework::AssetBrowser::PreviewerRequestBus::Handler::BusConnect(); - AzFramework::AssetCatalogEventBus::Handler::BusConnect(); + if (auto settingsRegistry{ AZ::SettingsRegistry::Get() }; settingsRegistry != nullptr) + { + auto LifecycleCallback = [this](AZStd::string_view, AZ::SettingsRegistryInterface::Type) + { + SetupThumbnails(); + }; + AZ::ComponentApplicationLifecycle::RegisterHandler(*settingsRegistry, m_criticalAssetsHandler, + AZStd::move(LifecycleCallback), "CriticalAssetsCompiled"); + } AzFramework::ApplicationLifecycleEvents::Bus::Handler::BusConnect(); } void EditorCommonFeaturesSystemComponent::Deactivate() { AzFramework::ApplicationLifecycleEvents::Bus::Handler::BusDisconnect(); - AzFramework::AssetCatalogEventBus::Handler::BusDisconnect(); + m_criticalAssetsHandler = {}; AzToolsFramework::EditorLevelNotificationBus::Handler::BusDisconnect(); AzToolsFramework::AssetBrowser::PreviewerRequestBus::Handler::BusDisconnect(); @@ -192,13 +201,6 @@ namespace AZ } } - void EditorCommonFeaturesSystemComponent::OnCatalogLoaded([[maybe_unused]] const char* catalogFile) - { - AZ::TickBus::QueueFunction([this](){ - SetupThumbnails(); - }); - } - const AzToolsFramework::AssetBrowser::PreviewerFactory* EditorCommonFeaturesSystemComponent::GetPreviewerFactory( const AzToolsFramework::AssetBrowser::AssetBrowserEntry* entry) const { diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/EditorCommonFeaturesSystemComponent.h b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/EditorCommonFeaturesSystemComponent.h index 82bb93a808..dff9e68814 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/EditorCommonFeaturesSystemComponent.h +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/EditorCommonFeaturesSystemComponent.h @@ -28,7 +28,6 @@ namespace AZ , public AzToolsFramework::EditorLevelNotificationBus::Handler , public AzToolsFramework::SliceEditorEntityOwnershipServiceNotificationBus::Handler , public AzToolsFramework::AssetBrowser::PreviewerRequestBus::Handler - , public AzFramework::AssetCatalogEventBus::Handler , public AzFramework::ApplicationLifecycleEvents::Bus::Handler { public: @@ -58,9 +57,6 @@ namespace AZ const AZ::Data::AssetId&, AZ::SliceComponent::SliceInstanceAddress&, const AzFramework::SliceInstantiationTicket&) override; void OnSliceInstantiationFailed(const AZ::Data::AssetId&, const AzFramework::SliceInstantiationTicket&) override; - // AzFramework::AssetCatalogEventBus::Handler overrides ... - void OnCatalogLoaded(const char* catalogFile) override; - // AzToolsFramework::AssetBrowser::PreviewerRequestBus::Handler overrides... const AzToolsFramework::AssetBrowser::PreviewerFactory* GetPreviewerFactory( const AzToolsFramework::AssetBrowser::AssetBrowserEntry* entry) const override; @@ -80,6 +76,7 @@ namespace AZ AZStd::unique_ptr m_thumbnailRenderer; AZStd::unique_ptr m_previewerFactory; + AZ::SettingsRegistryInterface::NotifyEventHandler m_criticalAssetsHandler; }; } // namespace Render } // namespace AZ diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/PostProcess/ColorGrading/EditorHDRColorGradingComponent.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/PostProcess/ColorGrading/EditorHDRColorGradingComponent.cpp index 3cc9535d7a..67db519669 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/PostProcess/ColorGrading/EditorHDRColorGradingComponent.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/PostProcess/ColorGrading/EditorHDRColorGradingComponent.cpp @@ -11,6 +11,9 @@ #include #include #include +#include +#include +#include namespace AZ { @@ -199,7 +202,14 @@ namespace AZ } const char* LutAttachment = "LutOutput"; - const AZStd::vector LutGenerationPassHierarchy{ "LutGenerationPass" }; + auto renderPipelineName = AZ::Interface::Get() + ->GetDefaultViewportContext() + ->GetCurrentPipeline() + ->GetId(); + const AZStd::vector LutGenerationPassHierarchy{ + renderPipelineName.GetCStr(), + "LutGenerationPass" + }; char resolvedOutputFilePath[AZ_MAX_PATH_LEN] = { 0 }; AZ::IO::FileIOBase::GetDirectInstance()->ResolvePath(m_currentTiffFilePath.c_str(), resolvedOutputFilePath, AZ_MAX_PATH_LEN); diff --git a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/SurfaceData/SurfaceDataMeshComponent.cpp b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/SurfaceData/SurfaceDataMeshComponent.cpp index d8cae4564d..862e3599a3 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/Code/Source/SurfaceData/SurfaceDataMeshComponent.cpp +++ b/Gems/AtomLyIntegration/CommonFeatures/Code/Source/SurfaceData/SurfaceDataMeshComponent.cpp @@ -17,8 +17,6 @@ #include #include -#include - namespace SurfaceData { void SurfaceDataMeshConfig::Reflect(AZ::ReflectContext* context) diff --git a/Gems/AtomLyIntegration/CommonFeatures/gem.json b/Gems/AtomLyIntegration/CommonFeatures/gem.json index 6fa8938332..a06f607fab 100644 --- a/Gems/AtomLyIntegration/CommonFeatures/gem.json +++ b/Gems/AtomLyIntegration/CommonFeatures/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_Feature_Common", "LmbrCentral", diff --git a/Gems/AtomLyIntegration/EMotionFXAtom/Code/Source/AtomActorDebugDraw.cpp b/Gems/AtomLyIntegration/EMotionFXAtom/Code/Source/AtomActorDebugDraw.cpp index 421e5828b1..21f9f69f7c 100644 --- a/Gems/AtomLyIntegration/EMotionFXAtom/Code/Source/AtomActorDebugDraw.cpp +++ b/Gems/AtomLyIntegration/EMotionFXAtom/Code/Source/AtomActorDebugDraw.cpp @@ -63,7 +63,10 @@ namespace AZ::Render // Render aabb if (renderFlags[EMotionFX::ActorRenderFlag::RENDER_AABB]) { - RenderAABB(instance, renderActorSettings.m_staticAABBColor); + RenderAABB(instance, + renderActorSettings.m_enabledNodeBasedAabb, renderActorSettings.m_nodeAABBColor, + renderActorSettings.m_enabledMeshBasedAabb, renderActorSettings.m_meshAABBColor, + renderActorSettings.m_enabledStaticBasedAabb, renderActorSettings.m_staticAABBColor); } // Render simple line skeleton @@ -201,11 +204,46 @@ namespace AZ::Render return AzFramework::DebugDisplayRequestBus::FindFirstHandler(debugDisplayBus); } - void AtomActorDebugDraw::RenderAABB(EMotionFX::ActorInstance* instance, const AZ::Color& aabbColor) + void AtomActorDebugDraw::RenderAABB(EMotionFX::ActorInstance* instance, + bool enableNodeAabb, + const AZ::Color& nodeAabbColor, + bool enableMeshAabb, + const AZ::Color& meshAabbColor, + bool enableStaticAabb, + const AZ::Color& staticAabbColor) { RPI::AuxGeomDrawPtr auxGeom = m_auxGeomFeatureProcessor->GetDrawQueue(); - const AZ::Aabb& aabb = instance->GetAabb(); - auxGeom->DrawAabb(aabb, aabbColor, RPI::AuxGeomDraw::DrawStyle::Line); + + if (enableNodeAabb) + { + AZ::Aabb aabb; + instance->CalcNodeBasedAabb(&aabb); + if (aabb.IsValid()) + { + auxGeom->DrawAabb(aabb, nodeAabbColor, RPI::AuxGeomDraw::DrawStyle::Line); + } + } + + if (enableMeshAabb) + { + AZ::Aabb aabb; + const size_t lodLevel = instance->GetLODLevel(); + instance->CalcMeshBasedAabb(lodLevel, &aabb); + if (aabb.IsValid()) + { + auxGeom->DrawAabb(aabb, meshAabbColor, RPI::AuxGeomDraw::DrawStyle::Line); + } + } + + if (enableStaticAabb) + { + AZ::Aabb aabb; + instance->CalcStaticBasedAabb(&aabb); + if (aabb.IsValid()) + { + auxGeom->DrawAabb(aabb, staticAabbColor, RPI::AuxGeomDraw::DrawStyle::Line); + } + } } void AtomActorDebugDraw::RenderLineSkeleton(EMotionFX::ActorInstance* instance, const AZ::Color& skeletonColor) diff --git a/Gems/AtomLyIntegration/EMotionFXAtom/Code/Source/AtomActorDebugDraw.h b/Gems/AtomLyIntegration/EMotionFXAtom/Code/Source/AtomActorDebugDraw.h index 3c0258cfef..8e985fdbc6 100644 --- a/Gems/AtomLyIntegration/EMotionFXAtom/Code/Source/AtomActorDebugDraw.h +++ b/Gems/AtomLyIntegration/EMotionFXAtom/Code/Source/AtomActorDebugDraw.h @@ -49,7 +49,13 @@ namespace AZ::Render void PrepareForMesh(EMotionFX::Mesh* mesh, const AZ::Transform& worldTM); AzFramework::DebugDisplayRequests* GetDebugDisplay(AzFramework::ViewportId viewportId); - void RenderAABB(EMotionFX::ActorInstance* instance, const AZ::Color& aabbColor); + void RenderAABB(EMotionFX::ActorInstance* instance, + bool enableNodeAabb, + const AZ::Color& nodeAabbColor, + bool enableMeshAabb, + const AZ::Color& meshAabbColor, + bool enableStaticAabb, + const AZ::Color& staticAabbColor); void RenderLineSkeleton(EMotionFX::ActorInstance* instance, const AZ::Color& skeletonColor); void RenderSkeleton(EMotionFX::ActorInstance* instance, const AZ::Color& skeletonColor); void RenderEMFXDebugDraw(EMotionFX::ActorInstance* instance); diff --git a/Gems/AtomLyIntegration/EMotionFXAtom/gem.json b/Gems/AtomLyIntegration/EMotionFXAtom/gem.json index 3514d4c1b9..8bea93da91 100644 --- a/Gems/AtomLyIntegration/EMotionFXAtom/gem.json +++ b/Gems/AtomLyIntegration/EMotionFXAtom/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "EMotionFX", "Atom", diff --git a/Gems/AtomLyIntegration/ImguiAtom/gem.json b/Gems/AtomLyIntegration/ImguiAtom/gem.json index fa611d8224..4c65d80e33 100644 --- a/Gems/AtomLyIntegration/ImguiAtom/gem.json +++ b/Gems/AtomLyIntegration/ImguiAtom/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "", "canonical_tags": [ @@ -11,6 +12,7 @@ ], "user_tags": [], "requirements": "", + "documentation_url": "", "dependencies": [ "ImGui", "Atom_Feature_Common" diff --git a/Gems/AtomLyIntegration/TechnicalArt/CMakeLists.txt b/Gems/AtomLyIntegration/TechnicalArt/CMakeLists.txt deleted file mode 100644 index 4fc1e5241d..0000000000 --- a/Gems/AtomLyIntegration/TechnicalArt/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -# -# Copyright (c) Contributors to the Open 3D Engine Project. -# For complete copyright and license terms please see the LICENSE at the root of this distribution. -# -# SPDX-License-Identifier: Apache-2.0 OR MIT -# -# - -add_subdirectory(DccScriptingInterface) diff --git a/Gems/AtomLyIntegration/TechnicalArt/DccScriptingInterface/CMakeLists.txt b/Gems/AtomLyIntegration/TechnicalArt/DccScriptingInterface/CMakeLists.txt index 5780172755..f26d18b90e 100644 --- a/Gems/AtomLyIntegration/TechnicalArt/DccScriptingInterface/CMakeLists.txt +++ b/Gems/AtomLyIntegration/TechnicalArt/DccScriptingInterface/CMakeLists.txt @@ -6,5 +6,4 @@ # # -add_subdirectory(Code) update_pip_requirements(${CMAKE_CURRENT_LIST_DIR}/requirements.txt DccScriptingInterface) diff --git a/Gems/AtomLyIntegration/TechnicalArt/DccScriptingInterface/gem.json b/Gems/AtomLyIntegration/TechnicalArt/DccScriptingInterface/gem.json index 4cc6fff169..7786a8adf4 100644 --- a/Gems/AtomLyIntegration/TechnicalArt/DccScriptingInterface/gem.json +++ b/Gems/AtomLyIntegration/TechnicalArt/DccScriptingInterface/gem.json @@ -1,11 +1,12 @@ { "gem_name": "DccScriptingInterface", "display_name": "Atom DccScriptingInterface (DCCsi)", - "summary": "A python framework for working with various DCC tools and workflows.", "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", + "summary": "A python framework for working with various DCC tools and workflows.", "canonical_tags": [ "Gem" ], @@ -16,5 +17,6 @@ "Creation" ], "requirements": "", + "documentation_url": "", "dependencies": [] } diff --git a/Gems/AtomLyIntegration/gem.json b/Gems/AtomLyIntegration/gem.json index d9e526aee0..c491126269 100644 --- a/Gems/AtomLyIntegration/gem.json +++ b/Gems/AtomLyIntegration/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Atom O3DE Integration Gem provides components, libraries, and functionality to support and integrate Atom Renderer in Open 3D Engine.", "canonical_tags": [ @@ -25,5 +26,16 @@ "CommonFeaturesAtom", "EMotionFX_Atom", "ImguiAtom" + ], + "external_subdirectories": [ + "AtomBridge", + "AtomFont", + "AtomImGuiTools", + "AtomViewportDisplayIcons", + "AtomViewportDisplayInfo", + "CommonFeatures", + "EMotionFXAtom", + "ImguiAtom", + "TechnicalArt/DccScriptingInterface" ] } diff --git a/Gems/AtomTressFX/Code/Rendering/HairRenderObject.cpp b/Gems/AtomTressFX/Code/Rendering/HairRenderObject.cpp index fe167cae8b..472a610016 100644 --- a/Gems/AtomTressFX/Code/Rendering/HairRenderObject.cpp +++ b/Gems/AtomTressFX/Code/Rendering/HairRenderObject.cpp @@ -213,6 +213,8 @@ namespace AZ Data::Instance rasterShader, uint32_t vertexCount, uint32_t strandsCount ) { + m_initialized = false; + AZ_Assert(vertexCount <= std::numeric_limits().max(), "Hair vertex count exceeds uint32_t size."); // Create the dynamic shared buffers Srg. @@ -608,8 +610,16 @@ namespace AZ // First, Directly loading from the asset stored in the render settings. if (pRenderSettings) { - m_baseAlbedo = RPI::StreamingImage::FindOrCreate(pRenderSettings->m_baseAlbedoAsset); - m_strandAlbedo = RPI::StreamingImage::FindOrCreate(pRenderSettings->m_strandAlbedoAsset); + if (pRenderSettings->m_baseAlbedoAsset) + { + pRenderSettings->m_baseAlbedoAsset.BlockUntilLoadComplete(); + m_baseAlbedo = RPI::StreamingImage::FindOrCreate(pRenderSettings->m_baseAlbedoAsset); + } + if (pRenderSettings->m_strandAlbedoAsset) + { + pRenderSettings->m_strandAlbedoAsset.BlockUntilLoadComplete(); + m_strandAlbedo = RPI::StreamingImage::FindOrCreate(pRenderSettings->m_strandAlbedoAsset); + } } // Fallback using the texture name stored in the render settings. @@ -1142,7 +1152,7 @@ namespace AZ if (!renderMaterialSrg || !simSrg) { - AZ_Error("Hair Gem", false, "Failed to get thre hair material Srg for the raster pass."); + AZ_Error("Hair Gem", false, "Failed to get the hair material Srg for the raster pass."); return false; } // No need to compile the simSrg since it was compiled already by the Compute pass this frame diff --git a/Gems/AtomTressFX/Code/Rendering/HairRenderObject.h b/Gems/AtomTressFX/Code/Rendering/HairRenderObject.h index 817ebd89fa..564272e6f0 100644 --- a/Gems/AtomTressFX/Code/Rendering/HairRenderObject.h +++ b/Gems/AtomTressFX/Code/Rendering/HairRenderObject.h @@ -110,8 +110,14 @@ namespace AZ PrepareSrgDescriptors(m_dynamicBuffersDescriptors, vertexCount, strandsCount); } - Data::Instance GetSimSrgForCompute() { return m_simSrgForCompute; } - Data::Instance GetSimSrgForRaster() { return m_simSrgForRaster; } + Data::Instance GetSimSrgForCompute() + { + return m_initialized ? m_simSrgForCompute : nullptr; + } + + Data::Instance GetSimSrgForRaster() + { + return m_initialized ? m_simSrgForRaster : nullptr; } bool IsInitialized() { return m_initialized; } diff --git a/Gems/AtomTressFX/gem.json b/Gems/AtomTressFX/gem.json index b7588ea374..1bd619a418 100644 --- a/Gems/AtomTressFX/gem.json +++ b/Gems/AtomTressFX/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "Atom TressFX Gem provides a cutting edge hair and fur simulation and rendering in Atom enhancing the AMD TressFX 4.1. The open source TressFX can be found here: https://github.com/GPUOpen-Effects/TressFX", "canonical_tags": [ @@ -15,5 +16,7 @@ "Animation" ], "requirements": "", - "documentation_url": "https://o3de.org/docs/user-guide/gems/reference/rendering/amd/atom-tressfx/" + "documentation_url": "https://o3de.org/docs/user-guide/gems/reference/rendering/amd/atom-tressfx/", + "dependencies": [ + ] } diff --git a/Gems/AudioEngineWwise/CMakeLists.txt b/Gems/AudioEngineWwise/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/AudioEngineWwise/CMakeLists.txt +++ b/Gems/AudioEngineWwise/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/AudioEngineWwise/Code/CMakeLists.txt b/Gems/AudioEngineWwise/Code/CMakeLists.txt index 33c80bc31c..02d4f1e6c8 100644 --- a/Gems/AudioEngineWwise/Code/CMakeLists.txt +++ b/Gems/AudioEngineWwise/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) #for PAL_TRAIT_AUDIO_ENGINE_WWISE Traits diff --git a/Gems/AudioEngineWwise/gem.json b/Gems/AudioEngineWwise/gem.json index 2b0af30d40..f0d8c73be2 100644 --- a/Gems/AudioEngineWwise/gem.json +++ b/Gems/AudioEngineWwise/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Wwise Audio Engine Gem provides support for Audiokinetic Wave Works Interactive Sound Engine (Wwise).", "canonical_tags": [ diff --git a/Gems/AudioSystem/CMakeLists.txt b/Gems/AudioSystem/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/AudioSystem/CMakeLists.txt +++ b/Gems/AudioSystem/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/AudioSystem/Code/CMakeLists.txt b/Gems/AudioSystem/Code/CMakeLists.txt index 17dbd91878..e5778e9152 100644 --- a/Gems/AudioSystem/Code/CMakeLists.txt +++ b/Gems/AudioSystem/Code/CMakeLists.txt @@ -10,7 +10,7 @@ set(AUDIOSYSTEM_COMPILEDEFINITIONS $,AUDIO_RELEASE,ENABLE_AUDIO_LOGGING> ) -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME AudioSystem.Static STATIC @@ -65,7 +65,7 @@ ly_create_alias(NAME AudioSystem.Clients NAMESPACE Gem TARGETS Gem::AudioSystem # Tests ################################################################################ if (PAL_TRAIT_BUILD_TESTS_SUPPORTED) - ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) + set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) ly_add_target( NAME AudioSystem.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} NAMESPACE Gem diff --git a/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorMainWindow.ui b/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorMainWindow.ui index 549e746de6..b375f5e174 100644 --- a/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorMainWindow.ui +++ b/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorMainWindow.ui @@ -28,101 +28,105 @@
- - - - 1 - 0 - + + + Qt::Horizontal - - QDockWidget::NoDockWidgetFeatures - - - ATL Controls + + false - - - - 4 - - - 9 - - - 4 - - - 9 - - + + + + 1 + 0 + + + + QDockWidget::NoDockWidgetFeatures + + + ATL Controls + + + + + 4 + + + 9 + + + 4 + + + 9 + + + - - - - - - - 2 - 1 - - - - QDockWidget::NoDockWidgetFeatures - - - Inspector - - - - - 4 - - - 9 - - - 4 - - - 9 - - + + + + 2 + 1 + + + + QDockWidget::NoDockWidgetFeatures + + + Inspector + + + + + 4 + + + 9 + + + 4 + + + 9 + + + - - - - - - - 1 - 0 - - - - false - - - QDockWidget::NoDockWidgetFeatures - - - Audio Middleware Controls - - - - - 4 - - - 9 - - - 4 - - - 9 - - + + + + 1 + 0 + + + + false + + + QDockWidget::NoDockWidgetFeatures + + + Audio Middleware Controls + + + + + 4 + + + 9 + + + 4 + + + 9 + + + @@ -134,7 +138,7 @@ 0 0 972 - 21 + 26 @@ -143,6 +147,7 @@ +
@@ -166,6 +171,17 @@ Reload + + Ctrl+R + + + + + Refresh Audio System + + + Ctrl+Shift+R + @@ -204,6 +220,22 @@ + + actionRefreshAudioSystem + triggered() + MainWindow + RefreshAudioSystem() + + + -1 + -1 + + + 485 + 336 + + + CurrentControlNameChanged(QString) diff --git a/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorWindow.cpp b/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorWindow.cpp index 5f870d06d4..35b1f3f2c8 100644 --- a/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorWindow.cpp +++ b/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorWindow.cpp @@ -198,6 +198,20 @@ namespace AudioControls } } + //-------------------------------------------------------------------------------------------// + void CAudioControlsEditorWindow::RefreshAudioSystem() + { + QString sLevelName = GetIEditor()->GetLevelName(); + + if (QString::compare(sLevelName, "Untitled", Qt::CaseInsensitive) == 0) + { + // Rather pass empty QString to indicate that no level is loaded! + sLevelName = QString(); + } + + Audio::AudioSystemRequestBus::Broadcast(&Audio::AudioSystemRequestBus::Events::RefreshAudioSystem, sLevelName.toUtf8().data()); + } + //-------------------------------------------------------------------------------------------// void CAudioControlsEditorWindow::Save() { @@ -215,15 +229,7 @@ namespace AudioControls messageBox.setWindowTitle("Audio Controls Editor"); if (messageBox.exec() == QMessageBox::Yes) { - QString sLevelName = GetIEditor()->GetLevelName(); - - if (QString::compare(sLevelName, "Untitled", Qt::CaseInsensitive) == 0) - { - // Rather pass empty QString to indicate that no level is loaded! - sLevelName = QString(); - } - - Audio::AudioSystemRequestBus::Broadcast(&Audio::AudioSystemRequestBus::Events::RefreshAudioSystem, sLevelName.toUtf8().data()); + RefreshAudioSystem(); } } m_pATLModel->ClearDirtyFlags(); diff --git a/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorWindow.h b/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorWindow.h index 00ffabfbe9..43d0ed8c8e 100644 --- a/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorWindow.h +++ b/Gems/AudioSystem/Code/Source/Editor/AudioControlsEditorWindow.h @@ -61,6 +61,7 @@ namespace AudioControls void UpdateInspector(); void FilterControlType(EACEControlType type, bool bShow); void Update(); + void RefreshAudioSystem(); protected: void closeEvent(QCloseEvent* pEvent) override; diff --git a/Gems/AudioSystem/Code/Source/Editor/QConnectionsWidget.cpp b/Gems/AudioSystem/Code/Source/Editor/QConnectionsWidget.cpp index d827f657b8..f8414e25e4 100644 --- a/Gems/AudioSystem/Code/Source/Editor/QConnectionsWidget.cpp +++ b/Gems/AudioSystem/Code/Source/Editor/QConnectionsWidget.cpp @@ -33,6 +33,7 @@ namespace AudioControls { setupUi(this); + m_connectionPropertiesFrame->setHidden(true); m_connectionList->viewport()->installEventFilter(this); m_connectionList->installEventFilter(this); diff --git a/Gems/AudioSystem/gem.json b/Gems/AudioSystem/gem.json index ed028068a1..be618ee44e 100644 --- a/Gems/AudioSystem/gem.json +++ b/Gems/AudioSystem/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Audio System Gem provides the Audio Translation Layer (ATL) and Audio Controls Editor, which add support for audio in Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/BarrierInput/gem.json b/Gems/BarrierInput/gem.json index 72d6398550..e8dcf0d93c 100644 --- a/Gems/BarrierInput/gem.json +++ b/Gems/BarrierInput/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Barrier Input Gem allows the Open 3D Engine to function as a Barrier client so that it can receive input from a remote Barrier server.", "canonical_tags": [ @@ -16,6 +17,7 @@ ], "icon_path": "preview.png", "requirements": "", + "documentation_url": "", "dependencies": [ "Atom_RPI" ] diff --git a/Gems/Blast/CMakeLists.txt b/Gems/Blast/CMakeLists.txt index 7c478ef2b2..e2fe57d8cc 100644 --- a/Gems/Blast/CMakeLists.txt +++ b/Gems/Blast/CMakeLists.txt @@ -6,5 +6,9 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Blast/Code/CMakeLists.txt b/Gems/Blast/Code/CMakeLists.txt index d3555b2855..7f478054b8 100644 --- a/Gems/Blast/Code/CMakeLists.txt +++ b/Gems/Blast/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # for PAL_TRAIT_BLAST Traits diff --git a/Gems/Blast/gem.json b/Gems/Blast/gem.json index 761eb04761..dc90c587d7 100644 --- a/Gems/Blast/gem.json +++ b/Gems/Blast/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The NVIDIA Blast Gem provides tools to author fractured mesh assets in Houdini, and functionality to create realistic destruction simulations in Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/Camera/Code/Source/CameraComponent.cpp b/Gems/Camera/Code/Source/CameraComponent.cpp index 960f13a082..290691bbbe 100644 --- a/Gems/Camera/Code/Source/CameraComponent.cpp +++ b/Gems/Camera/Code/Source/CameraComponent.cpp @@ -106,6 +106,10 @@ namespace Camera ->Event("SetOrthographic", &CameraRequestBus::Events::SetOrthographic) ->Event("GetOrthographicHalfWidth", &CameraRequestBus::Events::GetOrthographicHalfWidth) ->Event("SetOrthographicHalfWidth", &CameraRequestBus::Events::SetOrthographicHalfWidth) + ->Event("ScreenToWorld", &CameraRequestBus::Events::ScreenToWorld) + ->Event("ScreenNdcToWorld", &CameraRequestBus::Events::ScreenNdcToWorld) + ->Event("WorldToScreen", &CameraRequestBus::Events::WorldToScreen) + ->Event("WorldToScreenNdc", &CameraRequestBus::Events::WorldToScreenNdc) ->VirtualProperty("FieldOfView","GetFovDegrees","SetFovDegrees") ->VirtualProperty("NearClipDistance", "GetNearClipDistance", "SetNearClipDistance") ->VirtualProperty("FarClipDistance", "GetFarClipDistance", "SetFarClipDistance") diff --git a/Gems/Camera/Code/Source/CameraComponentController.cpp b/Gems/Camera/Code/Source/CameraComponentController.cpp index 5b2e26b897..dfb2810fe2 100644 --- a/Gems/Camera/Code/Source/CameraComponentController.cpp +++ b/Gems/Camera/Code/Source/CameraComponentController.cpp @@ -10,12 +10,15 @@ #include "CameraViewRegistrationBus.h" #include +#include #include #include #include #include +#include + namespace Camera { void CameraComponentConfig::Reflect(AZ::ReflectContext* context) @@ -412,6 +415,66 @@ namespace Camera return m_isActiveView; } + namespace Util + { + AZ::Vector3 GetWorldPosition(const AZ::Vector3& origin, float depth, const AzFramework::CameraState& cameraState) + { + if (depth == 0.f) + { + return origin; + } + else + { + const AZ::Vector3 rayDirection = cameraState.m_orthographic ? cameraState.m_forward : (origin - cameraState.m_position); + return origin + (rayDirection.GetNormalized() * depth); + } + } + } + + AZ::Vector3 CameraComponentController::ScreenToWorld(const AZ::Vector2& screenPosition, float depth) + { + const AzFramework::ScreenPoint point{ static_cast(screenPosition.GetX()), static_cast(screenPosition.GetY()) }; + const AzFramework::CameraState& cameraState = GetCameraState(); + const AZ::Vector3 origin = AzFramework::ScreenToWorld(point, cameraState); + return Util::GetWorldPosition(origin, depth, cameraState); + } + + AZ::Vector3 CameraComponentController::ScreenNdcToWorld(const AZ::Vector2& screenNdcPosition, float depth) + { + const AzFramework::CameraState& cameraState = GetCameraState(); + const AZ::Vector3 origin = AzFramework::ScreenNdcToWorld(screenNdcPosition, AzFramework::InverseCameraView(cameraState), AzFramework::InverseCameraProjection(cameraState)); + return Util::GetWorldPosition(origin, depth, cameraState); + } + + AZ::Vector2 CameraComponentController::WorldToScreenNdc(const AZ::Vector3& worldPosition) + { + const AzFramework::CameraState& cameraState = GetCameraState(); + const AZ::Vector3 screenPosition = AzFramework::WorldToScreenNdc(worldPosition, AzFramework::CameraView(cameraState), AzFramework::CameraProjection(cameraState)); + return AZ::Vector3ToVector2(screenPosition); + } + + AZ::Vector2 CameraComponentController::WorldToScreen(const AZ::Vector3& worldPosition) + { + const AzFramework::ScreenPoint& point = AzFramework::WorldToScreen(worldPosition, GetCameraState()); + return AZ::Vector2(static_cast(point.m_x), static_cast(point.m_y)); + } + + AzFramework::CameraState CameraComponentController::GetCameraState() + { + auto viewportContext = GetViewportContext(); + if (!m_atomCamera || ! viewportContext) + { + return AzFramework::CameraState(); + } + + auto windowSize = viewportContext->GetViewportSize(); + auto viewportSize = AzFramework::Vector2FromScreenSize(AzFramework::ScreenSize(windowSize.m_width, windowSize.m_height)); + + AzFramework::CameraState cameraState = AzFramework::CreateDefaultCamera(m_atomCamera->GetCameraTransform(), viewportSize); + AzFramework::SetCameraClippingVolumeFromPerspectiveFovMatrixRH(cameraState, m_atomCamera->GetViewToClipMatrix()); + return cameraState; + } + void CameraComponentController::OnTransformChanged([[maybe_unused]] const AZ::Transform& local, const AZ::Transform& world) { if (m_updatingTransformFromEntity) diff --git a/Gems/Camera/Code/Source/CameraComponentController.h b/Gems/Camera/Code/Source/CameraComponentController.h index 09af7529dc..265ffaa0e9 100644 --- a/Gems/Camera/Code/Source/CameraComponentController.h +++ b/Gems/Camera/Code/Source/CameraComponentController.h @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include @@ -110,6 +111,11 @@ namespace Camera void MakeActiveView() override; bool IsActiveView() override; + AZ::Vector3 ScreenToWorld(const AZ::Vector2& screenPosition, float depth) override; + AZ::Vector3 ScreenNdcToWorld(const AZ::Vector2& screenNdcPosition, float depth) override; + AZ::Vector2 WorldToScreen(const AZ::Vector3& worldPosition) override; + AZ::Vector2 WorldToScreenNdc(const AZ::Vector3& worldPosition) override; + // AZ::TransformNotificationBus::Handler interface void OnTransformChanged(const AZ::Transform& local, const AZ::Transform& world) override; @@ -127,6 +133,7 @@ namespace Camera void DeactivateAtomView(); void UpdateCamera(); void SetupAtomAuxGeom(AZ::RPI::ViewportContextPtr viewportContext); + AzFramework::CameraState GetCameraState(); CameraComponentConfig m_config; AZ::EntityId m_entityId; diff --git a/Gems/Camera/gem.json b/Gems/Camera/gem.json index 4cf0747c7b..c6367d4663 100644 --- a/Gems/Camera/gem.json +++ b/Gems/Camera/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Camera Gem provides a basic camera component that defines a frustum for runtime rendering.", "canonical_tags": [ diff --git a/Gems/CameraFramework/gem.json b/Gems/CameraFramework/gem.json index d24014be61..0803fd7522 100644 --- a/Gems/CameraFramework/gem.json +++ b/Gems/CameraFramework/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Camera Framework Gem provides a base for implementing more complex camera systems.", "canonical_tags": [ diff --git a/Gems/CertificateManager/gem.json b/Gems/CertificateManager/gem.json index 11ea14ea5e..c582e932be 100644 --- a/Gems/CertificateManager/gem.json +++ b/Gems/CertificateManager/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Certificate Manager Gem provides access to authentication files for secure game connections from Amazon S3, files on disk, and other 3rd party sources.", "canonical_tags": [ diff --git a/Gems/CrashReporting/CMakeLists.txt b/Gems/CrashReporting/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/CrashReporting/CMakeLists.txt +++ b/Gems/CrashReporting/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/CrashReporting/Code/CMakeLists.txt b/Gems/CrashReporting/Code/CMakeLists.txt index 8bcb143d1c..7d7b2c76da 100644 --- a/Gems/CrashReporting/Code/CMakeLists.txt +++ b/Gems/CrashReporting/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/Gems/CrashReporting/gem.json b/Gems/CrashReporting/gem.json index b8c75548a4..1651bad7b8 100644 --- a/Gems/CrashReporting/gem.json +++ b/Gems/CrashReporting/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Crash Reporting Gem provides support for external crash reporting for Open 3D Engine projects.", "canonical_tags": [ diff --git a/Gems/CustomAssetExample/gem.json b/Gems/CustomAssetExample/gem.json index 89492ee6ea..ba1030b280 100644 --- a/Gems/CustomAssetExample/gem.json +++ b/Gems/CustomAssetExample/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Custom Asset Example Gem provides example code for creating a custom asset for Open 3D Engine's asset pipeline.", "canonical_tags": [ diff --git a/Gems/DebugDraw/gem.json b/Gems/DebugDraw/gem.json index 58eff5f87a..e140d642b8 100644 --- a/Gems/DebugDraw/gem.json +++ b/Gems/DebugDraw/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Debug Draw Gem provides Editor and runtime debug visualization features for Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/DevTextures/gem.json b/Gems/DevTextures/gem.json index 00cafbd6fb..f8c436887d 100644 --- a/Gems/DevTextures/gem.json +++ b/Gems/DevTextures/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "The Dev Textures Gem provides a collection of general purpose texture assets useful for prototypes and preproduction.", "canonical_tags": [ diff --git a/Gems/EMotionFX/CMakeLists.txt b/Gems/EMotionFX/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/EMotionFX/CMakeLists.txt +++ b/Gems/EMotionFX/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/EMotionFX/Code/CMakeLists.txt b/Gems/EMotionFX/Code/CMakeLists.txt index 67d0ba6d85..bd90e589c9 100644 --- a/Gems/EMotionFX/Code/CMakeLists.txt +++ b/Gems/EMotionFX/Code/CMakeLists.txt @@ -6,10 +6,9 @@ # # -ly_get_list_relative_pal_filename(core_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) - -ly_get_list_relative_pal_filename(editor_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Editor/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(editor_common_dir ${CMAKE_CURRENT_LIST_DIR}/Editor/Platform/Common) +o3de_pal_dir(core_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +o3de_pal_dir(editor_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Editor/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(editor_common_dir ${CMAKE_CURRENT_LIST_DIR}/Editor/Platform/Common) ly_add_target( NAME EMotionFXStaticLib STATIC diff --git a/Gems/EMotionFX/Code/EMotionFX/CommandSystem/Source/ActorInstanceCommands.cpp b/Gems/EMotionFX/Code/EMotionFX/CommandSystem/Source/ActorInstanceCommands.cpp index ba25318944..328c905ded 100644 --- a/Gems/EMotionFX/Code/EMotionFX/CommandSystem/Source/ActorInstanceCommands.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/CommandSystem/Source/ActorInstanceCommands.cpp @@ -439,6 +439,12 @@ namespace CommandSystem return false; } + if (actorInstance->GetEntity()) + { + outResult = AZStd::string::format("Cannot remove actor instance. Actor instance %i belongs to an entity.", actorInstanceID); + return false; + } + // store the old values before removing the instance m_oldPosition = actorInstance->GetLocalSpaceTransform().m_position; m_oldRotation = actorInstance->GetLocalSpaceTransform().m_rotation; @@ -618,7 +624,7 @@ namespace CommandSystem MCore::CommandGroup commandGroup("Remove actor instances", numActorInstances); AZStd::string tempString; - // iterate over the selected instances and clone them + // iterate over the selected instances and remove them for (size_t i = 0; i < numActorInstances; ++i) { // get the current actor instance @@ -628,6 +634,18 @@ namespace CommandSystem continue; } + // Do not remove any runtime instance from the manager using the commands. + if (actorInstance->GetIsOwnedByRuntime()) + { + continue; + } + + // Do not remove the any instances owned by an entity from the manager using the commands. + if (actorInstance->GetEntity()) + { + continue; + } + tempString = AZStd::string::format("RemoveActorInstance -actorInstanceID %i", actorInstance->GetID()); commandGroup.AddCommandString(tempString.c_str()); } diff --git a/Gems/EMotionFX/Code/EMotionFX/CommandSystem/Source/AnimGraphCommands.cpp b/Gems/EMotionFX/Code/EMotionFX/CommandSystem/Source/AnimGraphCommands.cpp index bd5a14f772..b1a830c838 100644 --- a/Gems/EMotionFX/Code/EMotionFX/CommandSystem/Source/AnimGraphCommands.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/CommandSystem/Source/AnimGraphCommands.cpp @@ -455,8 +455,17 @@ namespace CommandSystem EMotionFX::ActorInstance* actorInstance = nullptr; if (parameters.CheckIfHasParameter("actorInstanceID")) { - const uint32 actorInstanceID = parameters.GetValueAsInt("actorInstanceID", this); - actorInstance = EMotionFX::GetActorManager().FindActorInstanceByID(actorInstanceID); + const int actorInstanceID = parameters.GetValueAsInt("actorInstanceID", this); + if (actorInstanceID == -1) + { + // If there isn't an actorInstanceId, grab the first actor instance. + actorInstance = EMotionFX::GetActorManager().GetFirstEditorActorInstance(); + } + else + { + actorInstance = EMotionFX::GetActorManager().FindActorInstanceByID(actorInstanceID); + } + if (!actorInstance) { outResult = AZStd::string::format("Cannot activate anim graph. Actor instance id '%i' is not valid.", actorInstanceID); diff --git a/Gems/EMotionFX/Code/EMotionFX/Rendering/Common/RenderUtil.cpp b/Gems/EMotionFX/Code/EMotionFX/Rendering/Common/RenderUtil.cpp index 6fd28ee72f..23e5d25824 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Rendering/Common/RenderUtil.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Rendering/Common/RenderUtil.cpp @@ -688,7 +688,7 @@ namespace MCommon const AZ::Vector3 nodeWorldPos = pose->GetWorldSpaceTransform(jointIndex).m_position; const AZ::Vector3 parentWorldPos = pose->GetWorldSpaceTransform(parentIndex).m_position; const AZ::Vector3 bone = parentWorldPos - nodeWorldPos; - const AZ::Vector3 boneDirection = MCore::SafeNormalize(bone); + const AZ::Vector3 boneDirection = bone.GetNormalizedSafe(); const float boneLength = MCore::SafeLength(bone); const float boneScale = GetBoneScale(actorInstance, joint); const float parentBoneScale = GetBoneScale(actorInstance, skeleton->GetNode(parentIndex)); @@ -952,7 +952,15 @@ namespace MCommon } else { - worldTM = AZ::Transform::CreateFromQuaternion(MCore::AzEulerAnglesToAzQuat(0.0f, 0.0f, MCore::Math::DegreesToRadians(180.0f))); + if (direction.GetX() > 0) + { + worldTM = AZ::Transform::CreateFromQuaternion(MCore::AzEulerAnglesToAzQuat(MCore::Math::DegreesToRadians(180.0f), 0.0f, MCore::Math::DegreesToRadians(180.0f))); + } + else + { + worldTM = AZ::Transform::CreateFromQuaternion(MCore::AzEulerAnglesToAzQuat(0.0f, 0.0f, 0.0f)); + } + } // set the cylinder to the given position diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/ActorManager.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/ActorManager.cpp index 184aac6e2c..252fccdb94 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/ActorManager.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Source/ActorManager.cpp @@ -434,6 +434,20 @@ namespace EMotionFX } + ActorInstance* ActorManager::GetFirstEditorActorInstance() const + { + const size_t numActorInstances = m_actorInstances.size(); + for (size_t i = 0; i < numActorInstances; ++i) + { + if (!m_actorInstances[i]->GetIsOwnedByRuntime()) + { + return m_actorInstances[i]; + } + } + return nullptr; + } + + const AZStd::vector& ActorManager::GetActorInstanceArray() const { return m_actorInstances; diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/ActorManager.h b/Gems/EMotionFX/Code/EMotionFX/Source/ActorManager.h index 003153b36c..016edb302e 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/ActorManager.h +++ b/Gems/EMotionFX/Code/EMotionFX/Source/ActorManager.h @@ -136,6 +136,12 @@ namespace EMotionFX */ MCORE_INLINE ActorInstance* GetActorInstance(size_t nr) const { return m_actorInstances[nr]; } + /** + * Get a given registered actor instance owned by editor (not owned by runtime). + * @result A pointer to the actor instance. + */ + ActorInstance* GetFirstEditorActorInstance() const; + /** * Get the array of actor instances. * @result The const reference to the actor instance array. diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeBlendNNode.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeBlendNNode.cpp index 7720822655..f4f96e6b93 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeBlendNNode.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeBlendNNode.cpp @@ -224,6 +224,11 @@ namespace EMotionFX poseIndexB = poseIndexA; *outWeight = 0.0f; } + else if ((*outWeight > 1.0f - MCore::Math::epsilon)) + { + poseIndexA = poseIndexB; + *outWeight = 0.0f; + } // Search complete: the input weight is between m_paramWeights[i] and m_paramWeights[i - 1] // Calculate the blend weight and get the nodes and then return diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeFootIKNode.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeFootIKNode.cpp index d81b090300..25fcfa7193 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeFootIKNode.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeFootIKNode.cpp @@ -258,9 +258,9 @@ namespace EMotionFX // Calculate the matrix to rotate the solve plane. void BlendTreeFootIKNode::CalculateMatrix(const AZ::Vector3& goal, const AZ::Vector3& bendDir, AZ::Matrix3x3* outForward) { - const AZ::Vector3 x = MCore::SafeNormalize(goal); + const AZ::Vector3 x = goal.GetNormalizedSafe(); const float dot = bendDir.Dot(x); - const AZ::Vector3 y = MCore::SafeNormalize(bendDir - (dot * x)); + const AZ::Vector3 y = (bendDir - (dot * x)).GetNormalizedSafe(); const AZ::Vector3 z = x.Cross(y); outForward->SetRow(0, x); outForward->SetRow(1, y); diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeTwoLinkIKNode.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeTwoLinkIKNode.cpp index 9a91a59390..ec9d69c68a 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeTwoLinkIKNode.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Source/BlendTreeTwoLinkIKNode.cpp @@ -189,11 +189,11 @@ namespace EMotionFX void BlendTreeTwoLinkIKNode::CalculateMatrix(const AZ::Vector3& goal, const AZ::Vector3& bendDir, AZ::Matrix3x3* outForward) { // the inverse matrix defines a coordinate system whose x axis contains P, so X = unit(P). - const AZ::Vector3 x = MCore::SafeNormalize(goal); + const AZ::Vector3 x = goal.GetNormalizedSafe(); // the y axis of the inverse is perpendicular to P, so Y = unit( D - X(D . X) ). const float dot = bendDir.Dot(x); - const AZ::Vector3 y = MCore::SafeNormalize(bendDir - (dot * x)); + const AZ::Vector3 y = (bendDir - (dot * x)).GetNormalizedSafe(); // the z axis of the inverse is perpendicular to both X and Y, so Z = X x Y. const AZ::Vector3 z = x.Cross(y); @@ -372,11 +372,11 @@ namespace EMotionFX if (m_relativeBendDir && !m_extractBendDir) { bendDir = actorInstance->GetWorldSpaceTransform().m_rotation.TransformVector(bendDir); - bendDir = MCore::SafeNormalize(bendDir); + bendDir.NormalizeSafe(); } else { - bendDir = MCore::SafeNormalize(bendDir); + bendDir.NormalizeSafe(); } // if end node rotation is enabled @@ -470,8 +470,8 @@ namespace EMotionFX // calculate the differences between the current forward vector and the new one after IK AZ::Vector3 oldForward = globalTransformB.m_position - globalTransformA.m_position; AZ::Vector3 newForward = midPos - globalTransformA.m_position; - oldForward = MCore::SafeNormalize(oldForward); - newForward = MCore::SafeNormalize(newForward); + oldForward.NormalizeSafe(); + newForward.NormalizeSafe(); // perform a delta rotation to rotate into the new direction after IK float dotProduct = oldForward.Dot(newForward); @@ -499,9 +499,8 @@ namespace EMotionFX oldForward = endEffectorNodePos - globalTransformB.m_position; } - oldForward = MCore::SafeNormalize(oldForward); - newForward = goal - globalTransformB.m_position; - newForward = MCore::SafeNormalize(newForward); + oldForward.NormalizeSafe(); + newForward = (goal - globalTransformB.m_position).GetNormalizedSafe(); // calculate the delta rotation dotProduct = oldForward.Dot(newForward); diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/EMotionFXManager.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/EMotionFXManager.cpp index 4ecd1c0117..864c193a9a 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/EMotionFXManager.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Source/EMotionFXManager.cpp @@ -6,7 +6,6 @@ * */ -// include the required headers #include "EMotionFXConfig.h" #include "EMotionFXManager.h" #include "Importer/Importer.h" @@ -29,6 +28,7 @@ #include #include #include +#include #include namespace EMotionFX @@ -76,6 +76,7 @@ namespace EMotionFX gEMFX.Get()->SetRecorder (Recorder::Create()); gEMFX.Get()->SetMotionInstancePool (MotionInstancePool::Create()); gEMFX.Get()->SetDebugDraw (aznew DebugDraw()); + gEMFX.Get()->SetPoseDataFactory (aznew PoseDataFactory()); gEMFX.Get()->SetGlobalSimulationSpeed (1.0f); // set the number of threads @@ -124,6 +125,7 @@ namespace EMotionFX m_recorder = nullptr; m_motionInstancePool = nullptr; m_debugDraw = nullptr; + m_poseDataFactory = nullptr; m_unitType = MCore::Distance::UNITTYPE_METERS; m_globalSimulationSpeed = 1.0f; m_isInEditorMode = false; @@ -170,6 +172,9 @@ namespace EMotionFX delete m_debugDraw; m_debugDraw = nullptr; + delete m_poseDataFactory; + m_poseDataFactory = nullptr; + m_renderActorSettings.reset(); m_eventManager->Destroy(); diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/EMotionFXManager.h b/Gems/EMotionFX/Code/EMotionFX/Source/EMotionFXManager.h index 4d55143b2f..7276516739 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/EMotionFXManager.h +++ b/Gems/EMotionFX/Code/EMotionFX/Source/EMotionFXManager.h @@ -37,6 +37,7 @@ namespace EMotionFX class MotionInstancePool; class EventDataFactory; class DebugDraw; + class PoseDataFactory; // versions #define EMFX_HIGHVERSION 4 @@ -188,6 +189,8 @@ namespace EMotionFX */ MCORE_INLINE DebugDraw* GetDebugDraw() const { return m_debugDraw; } + MCORE_INLINE PoseDataFactory* GetPoseDataFactory() const { return m_poseDataFactory; } + /** * Get the render actor settings * @result A pointer to global render actor settings. @@ -357,6 +360,7 @@ namespace EMotionFX EventManager* m_eventManager; /**< The motion event manager. */ SoftSkinManager* m_softSkinManager; /**< The softskin manager. */ AnimGraphManager* m_animGraphManager; /**< The animgraph manager. */ + PoseDataFactory* m_poseDataFactory; Recorder* m_recorder; /**< The recorder. */ MotionInstancePool* m_motionInstancePool; /**< The motion instance pool. */ DebugDraw* m_debugDraw; /**< The debug drawing system. */ @@ -433,6 +437,8 @@ namespace EMotionFX */ void SetMotionInstancePool(MotionInstancePool* pool); + void SetPoseDataFactory(PoseDataFactory* poseDataFactory) { m_poseDataFactory = poseDataFactory; } + /** * Set the number of threads to use. * @param numThreads The number of threads to use internally. This must be a value of 1 or above. @@ -520,5 +526,6 @@ namespace EMotionFX MCORE_INLINE Recorder& GetRecorder() { return *GetEMotionFX().GetRecorder(); } /**< Get the recorder. */ MCORE_INLINE MotionInstancePool& GetMotionInstancePool() { return *GetEMotionFX().GetMotionInstancePool(); } /**< Get the motion instance pool. */ MCORE_INLINE DebugDraw& GetDebugDraw() { return *GetEMotionFX().GetDebugDraw(); } /**< Get the debug drawing. */ + MCORE_INLINE PoseDataFactory& GetPoseDataFactory() { return *GetEMotionFX().GetPoseDataFactory(); } MCORE_INLINE AZ::Render::RenderActorSettings& GetRenderActorSettings() { return *GetEMotionFX().GetRenderActorSettings(); }/**< Get the render actor settings. */ } // namespace EMotionFX diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/Mesh.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/Mesh.cpp index 9845ec1939..9130636e2a 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/Mesh.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Source/Mesh.cpp @@ -581,8 +581,8 @@ namespace EMotionFX &curTangent, &curBitangent); // normalize the vectors - curTangent = MCore::SafeNormalize(curTangent); - curBitangent = MCore::SafeNormalize(curBitangent); + curTangent.NormalizeSafe(); + curBitangent.NormalizeSafe(); // store the tangents in the orgTangents array const AZ::Vector4 vec4Tangent(curTangent.GetX(), curTangent.GetY(), curTangent.GetZ(), 1.0f); @@ -605,7 +605,7 @@ namespace EMotionFX { // get the normal AZ::Vector3 normal(normals[i]); - normal = MCore::SafeNormalize(normal); + normal.NormalizeSafe(); // get the tangent AZ::Vector3 tangent = AZ::Vector3(orgTangents[i].GetX(), orgTangents[i].GetY(), orgTangents[i].GetZ()); @@ -631,7 +631,7 @@ namespace EMotionFX // Gram-Schmidt orthogonalize AZ::Vector3 fixedTangent = tangent - (normal * normal.Dot(tangent)); - fixedTangent = MCore::SafeNormalize(fixedTangent); + fixedTangent.NormalizeSafe(); // calculate handedness const AZ::Vector3 crossResult = normal.Cross(tangent); @@ -1671,7 +1671,7 @@ namespace EMotionFX const AZ::Vector3& posA = positions[ indexA ]; const AZ::Vector3& posB = positions[ indexB ]; const AZ::Vector3& posC = positions[ indexC ]; - AZ::Vector3 faceNormal = MCore::SafeNormalize((posB - posA).Cross(posC - posB)); + AZ::Vector3 faceNormal = (posB - posA).Cross(posC - posB).GetNormalizedSafe(); // store the tangents in the orgTangents array smoothNormals[ orgVerts[indexA] ] += faceNormal; @@ -1684,7 +1684,7 @@ namespace EMotionFX // normalize for (uint32 i = 0; i < m_numOrgVerts; ++i) { - smoothNormals[i] = MCore::SafeNormalize(smoothNormals[i]); + smoothNormals[i].NormalizeSafe(); } for (uint32 i = 0; i < m_numVertices; ++i) @@ -1721,7 +1721,7 @@ namespace EMotionFX const AZ::Vector3& posA = positions[ indexA ]; const AZ::Vector3& posB = positions[ indexB ]; const AZ::Vector3& posC = positions[ indexC ]; - AZ::Vector3 faceNormal = MCore::SafeNormalize((posB - posA).Cross(posC - posB)); + AZ::Vector3 faceNormal = (posB - posA).Cross(posC - posB).GetNormalizedSafe(); // store the tangents in the orgTangents array normals[indexA] = normals[indexA] + faceNormal; @@ -1734,7 +1734,7 @@ namespace EMotionFX // normalize the normals for (uint32 i = 0; i < m_numVertices; ++i) { - normals[i] = MCore::SafeNormalize(normals[i]); + normals[i].NormalizeSafe(); } } } diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/Pose.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/Pose.cpp index e2bff677ad..232bdacfd1 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/Pose.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Source/Pose.cpp @@ -1428,4 +1428,38 @@ namespace EMotionFX GetEMotionFX().GetThreadData(m_actorInstance->GetThreadIndex())->GetPosePool().FreePose(tempPose); } -} // namespace EMotionFX + + void Pose::DebugDraw(AzFramework::DebugDisplayRequests& debugDisplay, const AZ::Color& color, bool drawPoseDatas) const + { + debugDisplay.SetColor(color); + debugDisplay.DepthTestOff(); + + const Skeleton* skeleton = m_actorInstance->GetActor()->GetSkeleton(); + const size_t numEnabledJoints = m_actorInstance->GetNumEnabledNodes(); + for (size_t i = 0; i < numEnabledJoints; ++i) + { + const size_t jointIndex = m_actorInstance->GetEnabledNode(i); + const size_t parentIndex = skeleton->GetNode(jointIndex)->GetParentIndex(); + if (parentIndex != InvalidIndex) + { + const AZ::Vector3 startPos = GetWorldSpaceTransform(jointIndex).m_position; + const AZ::Vector3 endPos = GetWorldSpaceTransform(parentIndex).m_position; + + debugDisplay.DrawSolidCylinder(/*center=*/(startPos + endPos) * 0.5f, + /*direction=*/(endPos - startPos).GetNormalizedSafe(), + /*radius=*/0.005f, + /*height=*/(endPos - startPos).GetLength(), + /*drawShaded=*/false); + } + } + + if (drawPoseDatas) + { + for (const auto& poseDataItem : m_poseDatas) + { + PoseData* poseData = poseDataItem.second.get(); + poseData->DebugDraw(debugDisplay, color); + } + } + } +} // namespace EMotionFX diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/Pose.h b/Gems/EMotionFX/Code/EMotionFX/Source/Pose.h index b7844276be..451e855150 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/Pose.h +++ b/Gems/EMotionFX/Code/EMotionFX/Source/Pose.h @@ -10,10 +10,10 @@ #include #include +#include #include #include - namespace EMotionFX { // forward declarations @@ -25,10 +25,6 @@ namespace EMotionFX class Skeleton; class MotionLinkData; - /** - * - * - */ class EMFX_API Pose { MCORE_MEMORYOBJECTCATEGORY(Pose, EMFX_DEFAULT_ALIGNMENT, EMFX_MEMCATEGORY_POSE); @@ -192,6 +188,14 @@ namespace EMotionFX template T* GetAndPreparePoseData(ActorInstance* linkToActorInstance) { return azdynamic_cast(GetAndPreparePoseData(azrtti_typeid(), linkToActorInstance)); } + /** + * Draw debug visualization for the given pose. + * @param[in] debugDisplay Debug display request bus to spawn the render commands. + * @param[in] color The color the skeletal pose should be in. + * @param[in] drawPoseDatas Draw the pose data debug visualizations (e.g. joint velocities) along with the actual skeletal pose. [Default = false] + */ + void DebugDraw(AzFramework::DebugDisplayRequests& debugDisplay, const AZ::Color& color, bool drawPoseDatas = false) const; + private: mutable AZStd::vector m_localSpaceTransforms; mutable AZStd::vector m_modelSpaceTransforms; diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/PoseData.h b/Gems/EMotionFX/Code/EMotionFX/Source/PoseData.h index 31c22a3839..69e8800c0a 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/PoseData.h +++ b/Gems/EMotionFX/Code/EMotionFX/Source/PoseData.h @@ -12,9 +12,9 @@ #include #include #include +#include #include - namespace EMotionFX { class Actor; @@ -40,6 +40,8 @@ namespace EMotionFX virtual void Blend(const Pose* destPose, float weight) = 0; + virtual void DebugDraw([[maybe_unused]] AzFramework::DebugDisplayRequests& debugDisplay, [[maybe_unused]] const AZ::Color& color) const {} + bool IsUsed() const { return m_isUsed; } void SetIsUsed(bool isUsed) { m_isUsed = isUsed; } diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/PoseDataFactory.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/PoseDataFactory.cpp index c1c2627c8d..857cc7da7e 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/PoseDataFactory.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Source/PoseDataFactory.cpp @@ -8,13 +8,20 @@ #include #include +#include #include #include #include - namespace EMotionFX { + AZ_CLASS_ALLOCATOR_IMPL(PoseDataFactory, PoseAllocator, 0) + + PoseDataFactory::PoseDataFactory() + { + AddPoseDataType(azrtti_typeid()); + } + PoseData* PoseDataFactory::Create(Pose* pose, const AZ::TypeId& type) { AZ::SerializeContext* context = nullptr; @@ -34,13 +41,13 @@ namespace EMotionFX return result; } - const AZStd::unordered_set& PoseDataFactory::GetTypeIds() + void PoseDataFactory::AddPoseDataType(const AZ::TypeId& poseDataType) { - static AZStd::unordered_set typeIds = - { - azrtti_typeid() - }; + m_poseDataTypeIds.emplace(poseDataType); + } - return typeIds; + const AZStd::unordered_set& PoseDataFactory::GetTypeIds() const + { + return m_poseDataTypeIds; } } // namespace EMotionFX diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/PoseDataFactory.h b/Gems/EMotionFX/Code/EMotionFX/Source/PoseDataFactory.h index 31bc3e0d3f..624f0aeebf 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Source/PoseDataFactory.h +++ b/Gems/EMotionFX/Code/EMotionFX/Source/PoseDataFactory.h @@ -25,7 +25,18 @@ namespace EMotionFX class EMFX_API PoseDataFactory { public: + AZ_RTTI(PoseDataFactory, "{F10014A0-2B6A-44E5-BA53-0E11ED566701}") + AZ_CLASS_ALLOCATOR_DECL + + PoseDataFactory(); + virtual ~PoseDataFactory() = default; + static PoseData* Create(Pose* pose, const AZ::TypeId& type); - static const AZStd::unordered_set& GetTypeIds(); + + void AddPoseDataType(const AZ::TypeId& poseDataType); + const AZStd::unordered_set& GetTypeIds() const; + + private: + AZStd::unordered_set m_poseDataTypeIds; }; } // namespace EMotionFX diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/Velocity.cpp b/Gems/EMotionFX/Code/EMotionFX/Source/Velocity.cpp new file mode 100644 index 0000000000..e02262fa8e --- /dev/null +++ b/Gems/EMotionFX/Code/EMotionFX/Source/Velocity.cpp @@ -0,0 +1,83 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include + +namespace EMotionFX +{ + AZ::Vector3 CalculateLinearVelocity(const AZ::Vector3& lastPosition, + const AZ::Vector3& currentPosition, + float timeDelta) + { + if (timeDelta <= AZ::Constants::FloatEpsilon) + { + return AZ::Vector3::CreateZero(); + } + + const AZ::Vector3 deltaPosition = currentPosition - lastPosition; + const AZ::Vector3 velocity = deltaPosition / timeDelta; + + if (velocity.GetLength() > AZ::Constants::FloatEpsilon) + { + return velocity; + } + + return AZ::Vector3::CreateZero(); + } + + AZ::Vector3 CalculateAngularVelocity(const AZ::Quaternion& lastRotation, + const AZ::Quaternion& currentRotation, + float timeDelta) + { + if (timeDelta <= AZ::Constants::FloatEpsilon) + { + return AZ::Vector3::CreateZero(); + } + + const AZ::Quaternion deltaRotation = currentRotation * lastRotation.GetInverseFull(); + const AZ::Quaternion shortestEquivalent = deltaRotation.GetShortestEquivalent().GetNormalized(); + const AZ::Vector3 scaledAxisAngle = shortestEquivalent.ConvertToScaledAxisAngle(); + const AZ::Vector3 angularVelocity = scaledAxisAngle / timeDelta; + + if (angularVelocity.GetLength() > AZ::Constants::FloatEpsilon) + { + return angularVelocity; + } + + return AZ::Vector3::CreateZero(); + } + + void DebugDrawVelocity(AzFramework::DebugDisplayRequests& debugDisplay, + const AZ::Vector3& position, const AZ::Vector3& velocity, const AZ::Color& color) + { + // Don't visualize joints that remain motionless (zero velocity). + if (velocity.GetLength() < AZ::Constants::FloatEpsilon) + { + return; + } + + const float scale = 0.15f; + const AZ::Vector3 arrowPosition = position + velocity; + + debugDisplay.DepthTestOff(); + debugDisplay.SetColor(color); + + debugDisplay.DrawSolidCylinder(/*center=*/(arrowPosition + position) * 0.5f, + /*direction=*/(arrowPosition - position).GetNormalizedSafe(), + /*radius=*/0.003f, + /*height=*/(arrowPosition - position).GetLength(), + /*drawShaded=*/false); + + debugDisplay.DrawSolidCone(position + velocity, + velocity, + 0.1f * scale, + scale * 0.5f, + /*drawShaded=*/false); + } +} // namespace EMotionFX diff --git a/Gems/EMotionFX/Code/EMotionFX/Source/Velocity.h b/Gems/EMotionFX/Code/EMotionFX/Source/Velocity.h new file mode 100644 index 0000000000..a37a888024 --- /dev/null +++ b/Gems/EMotionFX/Code/EMotionFX/Source/Velocity.h @@ -0,0 +1,23 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include +#include + +namespace EMotionFX +{ + AZ::Vector3 EMFX_API CalculateLinearVelocity(const AZ::Vector3& lastPosition, const AZ::Vector3& currentPosition, float timeDelta); + AZ::Vector3 EMFX_API CalculateAngularVelocity(const AZ::Quaternion& lastRotation, const AZ::Quaternion& currentRotation, float timeDelta); + + void EMFX_API DebugDrawVelocity(AzFramework::DebugDisplayRequests& debugDisplay, + const AZ::Vector3& position, const AZ::Vector3& velocity, const AZ::Color& color); +} // namespace EMotionFX diff --git a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/MainWindow.cpp b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/MainWindow.cpp index b75fb71060..083d6a9be1 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/MainWindow.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/MainWindow.cpp @@ -26,6 +26,7 @@ #include #include #include +#include #include #include @@ -1340,8 +1341,15 @@ namespace EMStudio // add the load and the create instance commands commandGroup.AddCommandString(loadActorCommand.c_str()); - commandGroup.AddCommandString("CreateActorInstance -actorID %LASTRESULT%"); + // Temp solution after we refactor / remove the actor manager. + // We only need to create the actor instance by ourselves when openGLRenderPlugin is present. + // Atom render viewport will create actor instance along with the actor component. + PluginManager* pluginManager = GetPluginManager(); + if (pluginManager->FindActivePlugin(static_cast(OpenGLRenderPlugin::CLASS_ID))) + { + commandGroup.AddCommandString("CreateActorInstance -actorID %LASTRESULT%"); + } // execute the group command if (GetCommandManager()->ExecuteCommandGroup(commandGroup, outResult) == false) diff --git a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderOptions.cpp b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderOptions.cpp index 241412c6c8..cc344db488 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderOptions.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderOptions.cpp @@ -1071,6 +1071,8 @@ namespace EMStudio settings.m_mirroredBitangentsColor = m_mirroredBitangentsColor; settings.m_bitangentsColor = m_bitangentsColor; settings.m_wireframeColor = m_wireframeColor; + settings.m_nodeAABBColor = m_nodeAABBColor; + settings.m_meshAABBColor = m_meshAABBColor; settings.m_staticAABBColor = m_staticAABBColor; settings.m_skeletonColor = m_skeletonColor; settings.m_lineSkeletonColor = m_lineSkeletonColor; diff --git a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderPlugin.cpp b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderPlugin.cpp index 2c9e84c9b9..3451855c86 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderPlugin.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/RenderPlugin/RenderPlugin.cpp @@ -429,6 +429,7 @@ namespace EMStudio // 3. Relink the actor instances with the emstudio actors const size_t numActorInstances = EMotionFX::GetActorManager().GetNumActorInstances(); + size_t numActorInstancesInRenderPlugin = 0; for (size_t i = 0; i < numActorInstances; ++i) { EMotionFX::ActorInstance* actorInstance = EMotionFX::GetActorManager().GetActorInstance(i); @@ -440,6 +441,12 @@ namespace EMStudio continue; } + if (actorInstance->GetEntity()) + { + continue; + } + + numActorInstancesInRenderPlugin++; if (!emstudioActor) { for (EMStudioRenderActor* currentEMStudioActor : m_actors) @@ -485,6 +492,7 @@ namespace EMStudio if (found == false) { emstudioActor->m_actorInstances.erase(AZStd::next(begin(emstudioActor->m_actorInstances), j)); + numActorInstancesInRenderPlugin--; } else { @@ -497,7 +505,7 @@ namespace EMStudio m_reinitRequested = false; // zoom the camera to the available character only in case we're dealing with a single instance - if (resetViewCloseup && numActorInstances == 1) + if (resetViewCloseup && numActorInstancesInRenderPlugin == 1) { ViewCloseup(false); } diff --git a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/Workspace.cpp b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/Workspace.cpp index cada8c7f59..c8ee9be995 100644 --- a/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/Workspace.cpp +++ b/Gems/EMotionFX/Code/EMotionFX/Tools/EMotionStudio/EMStudioSDK/Source/Workspace.cpp @@ -23,6 +23,7 @@ #include #include #include +#include #include #include @@ -430,6 +431,18 @@ namespace EMStudio continue; } + // Temp solution after we refactor / remove the actor manager. + // We only need to create the actor instance by ourselves when openGLRenderPlugin is present. + // Atom render viewport will create actor instance along with the actor component. + PluginManager* pluginManager = GetPluginManager(); + if (!pluginManager->FindActivePlugin(static_cast(OpenGLRenderPlugin::CLASS_ID))) + { + if (commands[i].find("CreateActorInstance") == 0) + { + continue; + } + } + AzFramework::StringFunc::Replace(commands[i], "@products@", assetCacheFolder.c_str()); AzFramework::StringFunc::Replace(commands[i], "@assets@", assetCacheFolder.c_str()); AzFramework::StringFunc::Replace(commands[i], "@root@", assetCacheFolder.c_str()); diff --git a/Gems/EMotionFX/Code/EMotionFX/emotionfx_files.cmake b/Gems/EMotionFX/Code/EMotionFX/emotionfx_files.cmake index 8135f14f12..52c9d6aa15 100644 --- a/Gems/EMotionFX/Code/EMotionFX/emotionfx_files.cmake +++ b/Gems/EMotionFX/Code/EMotionFX/emotionfx_files.cmake @@ -144,6 +144,8 @@ set(FILES Source/TransformData.h Source/TriggerActionSetup.cpp Source/TriggerActionSetup.h + Source/Velocity.cpp + Source/Velocity.h Source/VertexAttributeLayer.cpp Source/VertexAttributeLayer.h Source/VertexAttributeLayerAbstractData.cpp diff --git a/Gems/EMotionFX/Code/MCore/Source/MCoreCommandManager.cpp b/Gems/EMotionFX/Code/MCore/Source/MCoreCommandManager.cpp index b59f2b69a0..4b21cde9f6 100644 --- a/Gems/EMotionFX/Code/MCore/Source/MCoreCommandManager.cpp +++ b/Gems/EMotionFX/Code/MCore/Source/MCoreCommandManager.cpp @@ -547,7 +547,12 @@ namespace MCore } tmpStr = commandString.substr(lastResultIndex, rightPercentagePos - lastResultIndex + 1); - AzFramework::StringFunc::Replace(commandString, tmpStr.c_str(), intermediateCommandResults[i - relativeIndex].c_str()); + AZStd::string replaceStr = intermediateCommandResults[i - relativeIndex]; + if (replaceStr.empty()) + { + replaceStr = "-1"; + } + AzFramework::StringFunc::Replace(commandString, tmpStr.c_str(), replaceStr.c_str()); replaceHappen = true; // Search again in case the command group is referring to other results diff --git a/Gems/EMotionFX/Code/MCore/Source/Vector.h b/Gems/EMotionFX/Code/MCore/Source/Vector.h index 3f5765762c..d904efcaaa 100644 --- a/Gems/EMotionFX/Code/MCore/Source/Vector.h +++ b/Gems/EMotionFX/Code/MCore/Source/Vector.h @@ -17,12 +17,14 @@ namespace MCore { + //! @deprecated Use AZ::Vector3::NormalizeSafeWithLength() inline float SafeLength(const AZ::Vector3& rhs) { const float lenSq = rhs.Dot(rhs); return (lenSq > FLT_EPSILON) ? sqrtf(lenSq) : 0.0f; } + //! @deprecated Use AZ::Vector3::GetNormalizedSafe() inline AZ::Vector3 SafeNormalize(const AZ::Vector3& rhs) { AZ::Vector3 result(0.0f); @@ -43,6 +45,7 @@ namespace MCore return AZ::Vector3(vec.GetX() - fac * n.GetX(), vec.GetY() - fac * n.GetY(), vec.GetZ() - fac * n.GetZ()); } + //! @deprecated Use AZ::Vector3::Project() MCORE_INLINE AZ::Vector3 Projected(const AZ::Vector3& vec, const AZ::Vector3& projectOnto) { AZ::Vector3 result = projectOnto; @@ -60,6 +63,7 @@ namespace MCore (MCore::Math::Abs(val.GetX() - val.GetZ()) < MCore::Math::epsilon)); } + //! @deprecated Use AZ::Vector3::Lerp() template <> MCORE_INLINE AZ::Vector3 LinearInterpolate(const AZ::Vector3& source, const AZ::Vector3& target, float timeValue) { diff --git a/Gems/EMotionFX/Code/Source/Editor/Plugins/Ragdoll/RagdollNodeWidget.cpp b/Gems/EMotionFX/Code/Source/Editor/Plugins/Ragdoll/RagdollNodeWidget.cpp index 29745beb68..538ad3ba52 100644 --- a/Gems/EMotionFX/Code/Source/Editor/Plugins/Ragdoll/RagdollNodeWidget.cpp +++ b/Gems/EMotionFX/Code/Source/Editor/Plugins/Ragdoll/RagdollNodeWidget.cpp @@ -125,6 +125,10 @@ namespace EMotionFX Physics::RagdollNodeConfiguration* ragdollNodeConfig = GetRagdollNodeConfig(); if (ragdollNodeConfig) { + AzPhysics::JointConfiguration* jointLimitConfig = ragdollNodeConfig->m_jointConfig.get(); + jointLimitConfig->SetPropertyVisibility(AzPhysics::JointConfiguration::PropertyVisibility::ParentLocalRotation, jointLimitConfig != nullptr); + jointLimitConfig->SetPropertyVisibility(AzPhysics::JointConfiguration::PropertyVisibility::ChildLocalRotation, jointLimitConfig != nullptr); + m_addColliderButton->show(); m_addRemoveButton->setText("Remove from ragdoll"); diff --git a/Gems/EMotionFX/Code/Source/Editor/PropertyWidgets/AnimGraphNodeNameHandler.cpp b/Gems/EMotionFX/Code/Source/Editor/PropertyWidgets/AnimGraphNodeNameHandler.cpp index 754acdaf1c..854825b45c 100644 --- a/Gems/EMotionFX/Code/Source/Editor/PropertyWidgets/AnimGraphNodeNameHandler.cpp +++ b/Gems/EMotionFX/Code/Source/Editor/PropertyWidgets/AnimGraphNodeNameHandler.cpp @@ -38,6 +38,12 @@ namespace EMotionFX m_node = node; } + void AnimGraphNodeNameLineEdit::focusInEvent([[maybe_unused]] QFocusEvent* event) + { + selectAll(); + QLineEdit::focusInEvent(event); + } + //--------------------------------------------------------------------------------------------------------------------------------------------------------- AnimGraphNodeNameHandler::AnimGraphNodeNameHandler() diff --git a/Gems/EMotionFX/Code/Source/Editor/PropertyWidgets/AnimGraphNodeNameHandler.h b/Gems/EMotionFX/Code/Source/Editor/PropertyWidgets/AnimGraphNodeNameHandler.h index ad6f0116ca..8da69f7437 100644 --- a/Gems/EMotionFX/Code/Source/Editor/PropertyWidgets/AnimGraphNodeNameHandler.h +++ b/Gems/EMotionFX/Code/Source/Editor/PropertyWidgets/AnimGraphNodeNameHandler.h @@ -29,7 +29,8 @@ namespace EMotionFX ~AnimGraphNodeNameLineEdit() = default; void SetNode(AnimGraphNode* node); - + private: + void focusInEvent(QFocusEvent* event) override; private: AnimGraphNode* m_node; }; diff --git a/Gems/EMotionFX/Code/Source/Integration/Components/AnimAudioComponent.cpp b/Gems/EMotionFX/Code/Source/Integration/Components/AnimAudioComponent.cpp index eac3705300..7cfea90ae2 100644 --- a/Gems/EMotionFX/Code/Source/Integration/Components/AnimAudioComponent.cpp +++ b/Gems/EMotionFX/Code/Source/Integration/Components/AnimAudioComponent.cpp @@ -405,6 +405,7 @@ namespace EMotionFX ActorNotificationBus::Handler::BusConnect(GetEntityId()); AnimAudioComponentNotificationBus::Handler::BusConnect(GetEntityId()); + AnimAudioComponentRequestBus::Handler::BusConnect(GetEntityId()); } void AnimAudioComponent::Deactivate() @@ -421,6 +422,7 @@ namespace EMotionFX ActorNotificationBus::Handler::BusDisconnect(GetEntityId()); AnimAudioComponentNotificationBus::Handler::BusDisconnect(GetEntityId()); + AnimAudioComponentRequestBus::Handler::BusDisconnect(GetEntityId()); } void AnimAudioComponent::OnTick(float deltaTime, AZ::ScriptTimePoint time) diff --git a/Gems/EMotionFX/Code/Source/Integration/Components/SimpleLODComponent.cpp b/Gems/EMotionFX/Code/Source/Integration/Components/SimpleLODComponent.cpp index fdc6426e4c..c12a7ee6bc 100644 --- a/Gems/EMotionFX/Code/Source/Integration/Components/SimpleLODComponent.cpp +++ b/Gems/EMotionFX/Code/Source/Integration/Components/SimpleLODComponent.cpp @@ -53,6 +53,7 @@ namespace EMotionFX ->Attribute(AZ::Edit::Attributes::AutoExpand, true) ->ElementAttribute(AZ::Edit::Attributes::Step, 0.01f) ->ElementAttribute(AZ::Edit::Attributes::Suffix, " m") + ->ElementAttribute(AZ::Edit::Attributes::Min, 0.00f) ->DataElement(0, &SimpleLODComponent::Configuration::m_enableLodSampling, "Enable LOD anim graph sampling", "AnimGraph sample rate will adjust based on LOD level.") ->Attribute(AZ::Edit::Attributes::ChangeNotify, AZ::Edit::PropertyRefreshLevels::EntireTree) @@ -61,7 +62,8 @@ namespace EMotionFX ->Attribute(AZ::Edit::Attributes::Visibility, &SimpleLODComponent::Configuration::GetEnableLodSampling) ->Attribute(AZ::Edit::Attributes::ContainerCanBeModified, false) ->Attribute(AZ::Edit::Attributes::AutoExpand, true) - ->ElementAttribute(AZ::Edit::Attributes::Step, 1.0f); + ->ElementAttribute(AZ::Edit::Attributes::Step, 1.0f) + ->ElementAttribute(AZ::Edit::Attributes::Min, 0.0f); } } } @@ -232,6 +234,10 @@ namespace EMotionFX const float updateRateInSeconds = animGraphSampleRate > 0.0f ? 1.0f / animGraphSampleRate : 0.0f; actorInstance->SetMotionSamplingRate(updateRateInSeconds); } + else if (actorInstance->GetMotionSamplingRate() != 0) + { + actorInstance->SetMotionSamplingRate(0); + } // Disable the automatic mesh LOD level adjustment based on screen space in case a simple LOD component is present. // The simple LOD component overrides the mesh LOD level and syncs the skeleton with the mesh LOD level. diff --git a/Gems/EMotionFX/Code/Source/Integration/Rendering/RenderActorSettings.h b/Gems/EMotionFX/Code/Source/Integration/Rendering/RenderActorSettings.h index 0260d1aae5..8663b768c8 100644 --- a/Gems/EMotionFX/Code/Source/Integration/Rendering/RenderActorSettings.h +++ b/Gems/EMotionFX/Code/Source/Integration/Rendering/RenderActorSettings.h @@ -28,6 +28,10 @@ namespace AZ::Render float m_wireframeScale = 1.0f; float m_nodeOrientationScale = 1.0f; + bool m_enabledNodeBasedAabb = true; + bool m_enabledMeshBasedAabb = true; + bool m_enabledStaticBasedAabb = true; + AZ::Color m_hitDetectionColliderColor{0.44f, 0.44f, 0.44f, 1.0f}; AZ::Color m_selectedHitDetectionColliderColor{ 0.3f, 0.56f, 0.88f, 1.0f }; AZ::Color m_ragdollColliderColor{ 0.44f, 0.44f, 0.44f, 1.0f }; @@ -44,9 +48,12 @@ namespace AZ::Render AZ::Color m_mirroredBitangentsColor{ 1.0f, 1.0f, 0.0f, 1.0f }; AZ::Color m_bitangentsColor{ 1.0f, 1.0f, 1.0f, 1.0f }; AZ::Color m_wireframeColor{ 0.0f, 0.0f, 0.0f, 1.0f }; - AZ::Color m_staticAABBColor{ 0.0f, 0.7f, 0.7f, 1.0f }; AZ::Color m_lineSkeletonColor{ 0.33333f, 1.0f, 0.0f, 1.0f }; AZ::Color m_skeletonColor{ 0.19f, 0.58f, 0.19f, 1.0f }; AZ::Color m_jointNameColor{ 1.0f, 1.0f, 1.0f, 1.0f }; + + AZ::Color m_nodeAABBColor{ 1.0f, 0.0f, 0.0f, 1.0f }; + AZ::Color m_meshAABBColor{ 0.0f, 0.0f, 0.7f, 1.0f }; + AZ::Color m_staticAABBColor{ 0.0f, 0.7f, 0.7f, 1.0f }; }; } // namespace AZ::Render diff --git a/Gems/EMotionFX/Code/Source/Integration/System/SystemComponent.cpp b/Gems/EMotionFX/Code/Source/Integration/System/SystemComponent.cpp index 15037793f1..08607c330d 100644 --- a/Gems/EMotionFX/Code/Source/Integration/System/SystemComponent.cpp +++ b/Gems/EMotionFX/Code/Source/Integration/System/SystemComponent.cpp @@ -400,17 +400,16 @@ namespace EMotionFX behaviorContext->EBus("SystemNotificationBus") ; - // In order for a property to be displayed in ScriptCanvas. Both a setter and a getter are necessary(both must be non-null). - // This is being worked on in dragon branch, once this is complete the dummy lambda functions can be removed. + // In order for a property to be displayed in ScriptCanvas. behaviorContext->Class("MotionEvent") - ->Property("entityId", BehaviorValueGetter(&MotionEvent::m_entityId), [](MotionEvent*, const AZ::EntityId&) {}) - ->Property("parameter", BehaviorValueGetter(&MotionEvent::m_parameter), [](MotionEvent*, const char*) {}) - ->Property("eventType", BehaviorValueGetter(&MotionEvent::m_eventType), [](MotionEvent*, const AZ::u32&) {}) - ->Property("eventTypeName", BehaviorValueGetter(&MotionEvent::m_eventTypeName), [](MotionEvent*, const char*) {}) - ->Property("time", BehaviorValueGetter(&MotionEvent::m_time), [](MotionEvent*, const float&) {}) - ->Property("globalWeight", BehaviorValueGetter(&MotionEvent::m_globalWeight), [](MotionEvent*, const float&) {}) - ->Property("localWeight", BehaviorValueGetter(&MotionEvent::m_localWeight), [](MotionEvent*, const float&) {}) - ->Property("isEventStart", BehaviorValueGetter(&MotionEvent::m_isEventStart), [](MotionEvent*, const bool&) {}) + ->Property("entityId", BehaviorValueGetter(&MotionEvent::m_entityId), nullptr) + ->Property("parameter", BehaviorValueGetter(&MotionEvent::m_parameter), nullptr) + ->Property("eventType", BehaviorValueGetter(&MotionEvent::m_eventType), nullptr) + ->Property("eventTypeName", BehaviorValueGetter(&MotionEvent::m_eventTypeName), nullptr) + ->Property("time", BehaviorValueGetter(&MotionEvent::m_time), nullptr) + ->Property("globalWeight", BehaviorValueGetter(&MotionEvent::m_globalWeight), nullptr) + ->Property("localWeight", BehaviorValueGetter(&MotionEvent::m_localWeight), nullptr) + ->Property("isEventStart", BehaviorValueGetter(&MotionEvent::m_isEventStart), nullptr) ; behaviorContext->EBus("ActorNotificationBus") diff --git a/Gems/EMotionFX/Code/Tests/AnimGraphEventTests.cpp b/Gems/EMotionFX/Code/Tests/AnimGraphEventTests.cpp index bd3fa10b24..11865674c8 100644 --- a/Gems/EMotionFX/Code/Tests/AnimGraphEventTests.cpp +++ b/Gems/EMotionFX/Code/Tests/AnimGraphEventTests.cpp @@ -49,7 +49,7 @@ namespace EMotionFX for (int i = 0; i < params.m_numStates; ++i) { AnimGraphNode* state = aznew AnimGraphMotionNode(); - state->SetName(AZStd::string(1, startChar + i).c_str()); + state->SetName(AZStd::string(1, static_cast(startChar + i)).c_str()); m_rootStateMachine->AddChildNode(state); AddTransitionWithTimeCondition(prevState, state, /*blendTime*/params.m_transitionBlendTime, /*countDownTime*/params.m_conditionCountDownTime); prevState = state; diff --git a/Gems/EMotionFX/Code/Tests/AnimGraphRefCountTests.cpp b/Gems/EMotionFX/Code/Tests/AnimGraphRefCountTests.cpp index 54f945d95f..c4e6462fff 100644 --- a/Gems/EMotionFX/Code/Tests/AnimGraphRefCountTests.cpp +++ b/Gems/EMotionFX/Code/Tests/AnimGraphRefCountTests.cpp @@ -90,7 +90,7 @@ namespace EMotionFX for (int i = 0; i < param.m_numStates; ++i) { AnimGraphBindPoseNode* state = aznew AnimGraphBindPoseNode(); - state->SetName(AZStd::string(1, startChar + i).c_str()); + state->SetName(AZStd::string(1, static_cast(startChar + i)).c_str()); m_rootStateMachine->AddChildNode(state); AddTransitionWithTimeCondition(prevState, state, /*blendTime*/param.m_blendTime, /*countDownTime*/param.m_countDownTime); prevState = state; diff --git a/Gems/EMotionFX/gem.json b/Gems/EMotionFX/gem.json index ed80517af1..c07c8368c2 100644 --- a/Gems/EMotionFX/gem.json +++ b/Gems/EMotionFX/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The EMotion FX Animation Gem provides Open 3D Engine's animation system for rigged actors and includes Animation Editor, a tool for creating animated behaviors, simulated objects, and colliders for rigged actors.", "canonical_tags": [ diff --git a/Gems/EditorPythonBindings/gem.json b/Gems/EditorPythonBindings/gem.json index 475483f13b..a5ee9f5631 100644 --- a/Gems/EditorPythonBindings/gem.json +++ b/Gems/EditorPythonBindings/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Editor Python Bindings Gem provides Python commands for Open 3D Engine Editor functions.", "canonical_tags": [ diff --git a/Gems/ExpressionEvaluation/gem.json b/Gems/ExpressionEvaluation/gem.json index cd712f4da9..667eebbcb5 100644 --- a/Gems/ExpressionEvaluation/gem.json +++ b/Gems/ExpressionEvaluation/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Expression Evaluation Gem provides a method for parsing and executing string expressions in Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/FastNoise/Code/CMakeLists.txt b/Gems/FastNoise/Code/CMakeLists.txt index 76b2cb4bd1..819592e018 100644 --- a/Gems/FastNoise/Code/CMakeLists.txt +++ b/Gems/FastNoise/Code/CMakeLists.txt @@ -18,9 +18,11 @@ ly_add_target( Include BUILD_DEPENDENCIES PUBLIC - Legacy::CryCommon Gem::GradientSignal + PUBLIC + AZ::AzCore PRIVATE + AZ::AzFramework Gem::LmbrCentral ) diff --git a/Gems/FastNoise/Code/Source/FastNoiseGradientComponent.cpp b/Gems/FastNoise/Code/Source/FastNoiseGradientComponent.cpp index 0f8ce4c5da..4cea2efcc8 100644 --- a/Gems/FastNoise/Code/Source/FastNoiseGradientComponent.cpp +++ b/Gems/FastNoise/Code/Source/FastNoiseGradientComponent.cpp @@ -249,6 +249,9 @@ namespace FastNoiseGem void FastNoiseGradientComponent::Activate() { + // This will immediately call OnGradientTransformChanged and initialize m_gradientTransform. + GradientSignal::GradientTransformNotificationBus::Handler::BusConnect(GetEntityId()); + // Some platforms require random seeds to be > 0. Clamp to a positive range to ensure we're always safe. m_generator.SetSeed(AZ::GetMax(m_configuration.m_seed, 1)); m_generator.SetFrequency(m_configuration.m_frequency); @@ -272,6 +275,7 @@ namespace FastNoiseGem { GradientSignal::GradientRequestBus::Handler::BusDisconnect(); FastNoiseGradientRequestBus::Handler::BusDisconnect(); + GradientSignal::GradientTransformNotificationBus::Handler::BusDisconnect(); } bool FastNoiseGradientComponent::ReadInConfig(const AZ::ComponentConfig* baseConfig) @@ -294,14 +298,21 @@ namespace FastNoiseGem return false; } + void FastNoiseGradientComponent::OnGradientTransformChanged(const GradientSignal::GradientTransform& newTransform) + { + AZStd::unique_lock lock(m_transformMutex); + m_gradientTransform = newTransform; + } + float FastNoiseGradientComponent::GetValue(const GradientSignal::GradientSampleParams& sampleParams) const { AZ::Vector3 uvw = sampleParams.m_position; - bool wasPointRejected = false; - const bool shouldNormalizeOutput = false; - GradientSignal::GradientTransformRequestBus::Event( - GetEntityId(), &GradientSignal::GradientTransformRequestBus::Events::TransformPositionToUVW, sampleParams.m_position, uvw, shouldNormalizeOutput, wasPointRejected); + + { + AZStd::shared_lock lock(m_transformMutex); + m_gradientTransform.TransformPositionToUVW(sampleParams.m_position, uvw, wasPointRejected); + } if (!wasPointRejected) { diff --git a/Gems/FastNoise/Code/Source/FastNoiseGradientComponent.h b/Gems/FastNoise/Code/Source/FastNoiseGradientComponent.h index da972743ec..dd19049ee6 100644 --- a/Gems/FastNoise/Code/Source/FastNoiseGradientComponent.h +++ b/Gems/FastNoise/Code/Source/FastNoiseGradientComponent.h @@ -12,6 +12,7 @@ #include #include #include +#include #include #include @@ -67,6 +68,7 @@ namespace FastNoiseGem : public AZ::Component , private GradientSignal::GradientRequestBus::Handler , private FastNoiseGradientRequestBus::Handler + , private GradientSignal::GradientTransformNotificationBus::Handler { public: friend class EditorFastNoiseGradientComponent; @@ -80,23 +82,25 @@ namespace FastNoiseGem FastNoiseGradientComponent(const FastNoiseGradientConfig& configuration); FastNoiseGradientComponent() = default; - ////////////////////////////////////////////////////////////////////////// - // AZ::Component interface implementation + // AZ::Component overrides... void Activate() override; void Deactivate() override; bool ReadInConfig(const AZ::ComponentConfig* baseConfig) override; bool WriteOutConfig(AZ::ComponentConfig* outBaseConfig) const override; - ////////////////////////////////////////////////////////////////////////// - // GradientRequestBus + // GradientRequestBus overrides... float GetValue(const GradientSignal::GradientSampleParams& sampleParams) const override; protected: FastNoiseGradientConfig m_configuration; FastNoise m_generator; + GradientSignal::GradientTransform m_gradientTransform; + mutable AZStd::shared_mutex m_transformMutex; - ///////////////////////////////////////////////////////////////////////// - // FastNoiseGradientRequest overrides + // GradientTransformNotificationBus overrides... + void OnGradientTransformChanged(const GradientSignal::GradientTransform& newTransform) override; + + // FastNoiseGradientRequest overrides... int GetRandomSeed() const override; void SetRandomSeed(int seed) override; diff --git a/Gems/FastNoise/Code/Tests/FastNoiseTest.cpp b/Gems/FastNoise/Code/Tests/FastNoiseTest.cpp index 3fb60cdaf6..f0d5a9d1bd 100644 --- a/Gems/FastNoise/Code/Tests/FastNoiseTest.cpp +++ b/Gems/FastNoise/Code/Tests/FastNoiseTest.cpp @@ -7,9 +7,6 @@ */ #include -#include -#include -#include #include #include @@ -49,9 +46,10 @@ public: //////////////////////////////////////////////////////////////////////////// //// GradientTransformRequestBus - void TransformPositionToUVW([[maybe_unused]] const AZ::Vector3& inPosition, [[maybe_unused]] AZ::Vector3& outUVW, [[maybe_unused]] const bool shouldNormalizeOutput, [[maybe_unused]] bool& wasPointRejected) const override {} - void GetGradientLocalBounds([[maybe_unused]] AZ::Aabb& bounds) const override {} - void GetGradientEncompassingBounds([[maybe_unused]] AZ::Aabb& bounds) const override {} + const GradientSignal::GradientTransform& GetGradientTransform() const override + { + return m_gradientTransform; + } ////////////////////////////////////////////////////////////////////////// // GradientTransformModifierRequestBus @@ -99,28 +97,8 @@ public: bool GetAdvancedMode() const override { return false; } void SetAdvancedMode([[maybe_unused]] bool value) override {} -}; -struct MockGlobalEnvironment -{ - MockGlobalEnvironment() - { - m_stubEnv.pCryPak = &m_stubPak; - m_stubEnv.pConsole = &m_stubConsole; - m_stubEnv.pSystem = &m_stubSystem; - gEnv = &m_stubEnv; - } - - ~MockGlobalEnvironment() - { - gEnv = nullptr; - } - -private: - SSystemGlobalEnvironment m_stubEnv; - testing::NiceMock m_stubPak; - testing::NiceMock m_stubConsole; - testing::NiceMock m_stubSystem; + GradientSignal::GradientTransform m_gradientTransform; }; TEST(FastNoiseTest, ComponentsWithComponentApplication) @@ -130,8 +108,6 @@ TEST(FastNoiseTest, ComponentsWithComponentApplication) appDesc.m_recordingMode = AZ::Debug::AllocationRecords::RECORD_FULL; appDesc.m_stackRecordLevels = 20; - MockGlobalEnvironment mocks; - AZ::ComponentApplication app; AZ::Entity* systemEntity = app.Create(appDesc); ASSERT_TRUE(systemEntity != nullptr); @@ -186,7 +162,6 @@ public: AZ::ComponentApplication m_application; AZ::Entity* m_systemEntity; - MockGlobalEnvironment m_mocks; }; ////////////////////////////////////////////////////////////////////////// diff --git a/Gems/FastNoise/gem.json b/Gems/FastNoise/gem.json index d8dfb878b4..a9c0f1f42d 100644 --- a/Gems/FastNoise/gem.json +++ b/Gems/FastNoise/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The FastNoise Gradient Gem uses the third-party, open source FastNoise library to provide a variety of high-performance noise generation algorithms.", "canonical_tags": [ diff --git a/Gems/GameState/gem.json b/Gems/GameState/gem.json index fe3a338997..d3e2d76c5a 100644 --- a/Gems/GameState/gem.json +++ b/Gems/GameState/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Game State Gem provides a generic framework to determine and manage game states and game state transitions in Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/GameStateSamples/CMakeLists.txt b/Gems/GameStateSamples/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/GameStateSamples/CMakeLists.txt +++ b/Gems/GameStateSamples/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/GameStateSamples/Code/CMakeLists.txt b/Gems/GameStateSamples/Code/CMakeLists.txt index 5d1d180de0..939b2ce1bd 100644 --- a/Gems/GameStateSamples/Code/CMakeLists.txt +++ b/Gems/GameStateSamples/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(include_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(include_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Include/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME GameStateSamples.Headers HEADERONLY @@ -21,7 +21,7 @@ ly_add_target( INTERFACE Gem::GameState Gem::LocalUser - Gem::LyShine.Static + Gem::LyShine.Clients.API Gem::SaveData.Static Gem::MessagePopup.Static Legacy::CryCommon diff --git a/Gems/GameStateSamples/gem.json b/Gems/GameStateSamples/gem.json index 80018ff1a8..94556ee677 100644 --- a/Gems/GameStateSamples/gem.json +++ b/Gems/GameStateSamples/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Game State Samples Gem provides a set of sample game states (built on top of the Game State Gem), including primary user selection, main menu, level loading, level running, and level paused.", "canonical_tags": [ diff --git a/Gems/Gestures/gem.json b/Gems/Gestures/gem.json index 8efd389d53..c0609c8d54 100644 --- a/Gems/Gestures/gem.json +++ b/Gems/Gestures/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Gestures Gem provides detection for common gesture-based input actions on iOS and Android devices.", "canonical_tags": [ diff --git a/Gems/GradientSignal/Code/CMakeLists.txt b/Gems/GradientSignal/Code/CMakeLists.txt index 5b88044116..d2d8f8c696 100644 --- a/Gems/GradientSignal/Code/CMakeLists.txt +++ b/Gems/GradientSignal/Code/CMakeLists.txt @@ -18,10 +18,10 @@ ly_add_target( Include BUILD_DEPENDENCIES PUBLIC - Legacy::CryCommon + AZ::AzCore + AZ::AzFramework Gem::SurfaceData Gem::ImageProcessingAtom.Headers - PRIVATE Gem::LmbrCentral ) @@ -37,9 +37,10 @@ ly_add_target( Include BUILD_DEPENDENCIES PRIVATE - Gem::GradientSignal.Static Gem::LmbrCentral PUBLIC + AZ::AzCore + Gem::GradientSignal.Static Gem::ImageProcessingAtom.Headers # Atom/ImageProcessing/PixelFormats.h is part of a header in Includes RUNTIME_DEPENDENCIES Gem::LmbrCentral @@ -69,7 +70,8 @@ if(PAL_TRAIT_BUILD_HOST_TOOLS) Gem::LmbrCentral.Editor PUBLIC 3rdParty::Qt::Widgets - Legacy::CryCommon + AZ::AzCore + AZ::AzFramework AZ::AzToolsFramework AZ::AssetBuilderSDK Gem::GradientSignal.Static @@ -117,6 +119,27 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) Mocks ) + ly_add_target( + NAME GradientSignal.Tests.Static STATIC + NAMESPACE Gem + FILES_CMAKE + gradientsignal_shared_tests_files.cmake + INCLUDE_DIRECTORIES + PUBLIC + Tests + PRIVATE + . + Source + BUILD_DEPENDENCIES + PRIVATE + AZ::AzTest + AZ::AzTestShared + Gem::GradientSignal.Static + Gem::LmbrCentral + Gem::LmbrCentral.Mocks + Gem::GradientSignal.Mocks + ) + ly_add_target( NAME GradientSignal.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} NAMESPACE Gem @@ -129,14 +152,23 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) BUILD_DEPENDENCIES PRIVATE AZ::AzTest + AZ::AzTestShared + Gem::GradientSignal.Tests.Static Gem::GradientSignal.Static Gem::LmbrCentral + Gem::LmbrCentral.Mocks Gem::GradientSignal.Mocks ) ly_add_googletest( NAME Gem::GradientSignal.Tests ) + ly_add_googlebenchmark( + NAME Gem::GradientSignal.Benchmarks + TARGET Gem::GradientSignal.Tests + ) + + if(PAL_TRAIT_BUILD_HOST_TOOLS) ly_add_target( NAME GradientSignal.Editor.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} @@ -150,9 +182,12 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) BUILD_DEPENDENCIES PRIVATE AZ::AzTest + AZ::AzTestShared + Gem::GradientSignal.Tests.Static Gem::GradientSignal.Static Gem::GradientSignal.Editor.Static Gem::LmbrCentral.Editor + Gem::LmbrCentral.Mocks ) ly_add_googletest( NAME Gem::GradientSignal.Editor.Tests diff --git a/Gems/GradientSignal/Code/Source/Components/ConstantGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/ConstantGradientComponent.h similarity index 96% rename from Gems/GradientSignal/Code/Source/Components/ConstantGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/ConstantGradientComponent.h index cb27914b8a..1ed06a976a 100644 --- a/Gems/GradientSignal/Code/Source/Components/ConstantGradientComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/ConstantGradientComponent.h @@ -62,6 +62,7 @@ namespace GradientSignal ////////////////////////////////////////////////////////////////////////// // GradientRequestBus float GetValue(const GradientSampleParams& sampleParams) const override; + void GetValues(AZStd::span positions, AZStd::span outValues) const override; protected: ////////////////////////////////////////////////////////////////////////// diff --git a/Gems/GradientSignal/Code/Source/Components/DitherGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/DitherGradientComponent.h similarity index 89% rename from Gems/GradientSignal/Code/Source/Components/DitherGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/DitherGradientComponent.h index ed12ec2ff7..add6de06cf 100644 --- a/Gems/GradientSignal/Code/Source/Components/DitherGradientComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/DitherGradientComponent.h @@ -77,6 +77,7 @@ namespace GradientSignal ////////////////////////////////////////////////////////////////////////// // GradientRequestBus float GetValue(const GradientSampleParams& sampleParams) const override; + void GetValues(AZStd::span positions, AZStd::span outValues) const override; bool IsEntityInHierarchy(const AZ::EntityId& entityId) const override; ////////////////////////////////////////////////////////////////////////// @@ -102,6 +103,13 @@ namespace GradientSignal GradientSampler& GetGradientSampler() override; private: + static int ScaledPositionToPatternIndex(const AZ::Vector3& scaledPosition, int patternSize); + static float GetDitherValue4x4(const AZ::Vector3& scaledPosition); + static float GetDitherValue8x8(const AZ::Vector3& scaledPosition); + + float GetCalculatedPointsPerUnit() const; + float GetDitherValue(const AZ::Vector3& scaledPosition, float value) const; + DitherGradientConfig m_configuration; LmbrCentral::DependencyMonitor m_dependencyMonitor; }; diff --git a/Gems/GradientSignal/Code/Source/Components/GradientSurfaceDataComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/GradientSurfaceDataComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/GradientSurfaceDataComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/GradientSurfaceDataComponent.h diff --git a/Gems/GradientSignal/Code/Source/Components/GradientTransformComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/GradientTransformComponent.h similarity index 92% rename from Gems/GradientSignal/Code/Source/Components/GradientTransformComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/GradientTransformComponent.h index abaa245f15..805fba9e74 100644 --- a/Gems/GradientSignal/Code/Source/Components/GradientTransformComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/GradientTransformComponent.h @@ -101,9 +101,7 @@ namespace GradientSignal ////////////////////////////////////////////////////////////////////////// // GradientTransformRequestBus - void TransformPositionToUVW(const AZ::Vector3& inPosition, AZ::Vector3& outUVW, const bool shouldNormalizeOutput, bool& wasPointRejected) const override; - void GetGradientLocalBounds(AZ::Aabb& bounds) const override; - void GetGradientEncompassingBounds(AZ::Aabb& bounds) const override; + const GradientTransform& GetGradientTransform() const override; ////////////////////////////////////////////////////////////////////////// // DependencyNotificationBus @@ -113,7 +111,7 @@ namespace GradientSignal // AZ::TickBus::Handler void OnTick(float deltaTime, AZ::ScriptTimePoint time) override; - void UpdateFromShape(); + void UpdateFromShape(bool notifyDependentsOfChange); AZ::EntityId GetShapeEntityId() const; @@ -168,9 +166,8 @@ namespace GradientSignal private: mutable AZStd::recursive_mutex m_cacheMutex; GradientTransformConfig m_configuration; - AZ::Aabb m_shapeBounds = AZ::Aabb::CreateNull(); - AZ::Matrix3x4 m_shapeTransformInverse = AZ::Matrix3x4::CreateIdentity(); LmbrCentral::DependencyMonitor m_dependencyMonitor; AZStd::atomic_bool m_dirty{ false }; + GradientTransform m_gradientTransform; }; } //namespace GradientSignal diff --git a/Gems/GradientSignal/Code/Source/Components/ImageGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/ImageGradientComponent.h similarity index 83% rename from Gems/GradientSignal/Code/Source/Components/ImageGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/ImageGradientComponent.h index 5033c44735..79d42ec478 100644 --- a/Gems/GradientSignal/Code/Source/Components/ImageGradientComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/ImageGradientComponent.h @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include @@ -46,6 +47,7 @@ namespace GradientSignal , private AZ::Data::AssetBus::Handler , private GradientRequestBus::Handler , private ImageGradientRequestBus::Handler + , private GradientTransformNotificationBus::Handler { public: template friend class LmbrCentral::EditorWrappedComponentBase; @@ -59,29 +61,28 @@ namespace GradientSignal ImageGradientComponent() = default; ~ImageGradientComponent() = default; - ////////////////////////////////////////////////////////////////////////// - // AZ::Component interface implementation + // AZ::Component overrides... void Activate() override; void Deactivate() override; bool ReadInConfig(const AZ::ComponentConfig* baseConfig) override; bool WriteOutConfig(AZ::ComponentConfig* outBaseConfig) const override; - ////////////////////////////////////////////////////////////////////////// - // GradientRequestBus + // GradientRequestBus overrides... float GetValue(const GradientSampleParams& sampleParams) const override; + void GetValues(AZStd::span positions, AZStd::span outValues) const override; - ////////////////////////////////////////////////////////////////////////// - // AZ::Data::AssetBus::Handler + // AZ::Data::AssetBus overrides... void OnAssetReady(AZ::Data::Asset asset) override; void OnAssetMoved(AZ::Data::Asset asset, void* oldDataPointer) override; void OnAssetReloaded(AZ::Data::Asset asset) override; protected: + // GradientTransformNotificationBus overrides... + void OnGradientTransformChanged(const GradientTransform& newTransform) override; void SetupDependencies(); - ////////////////////////////////////////////////////////////////////////// - // ImageGradientRequestBus + // ImageGradientRequestBus overrides... AZStd::string GetImageAssetPath() const override; void SetImageAssetPath(const AZStd::string& assetPath) override; @@ -94,6 +95,7 @@ namespace GradientSignal private: ImageGradientConfig m_configuration; LmbrCentral::DependencyMonitor m_dependencyMonitor; - mutable AZStd::recursive_mutex m_imageMutex; + mutable AZStd::shared_mutex m_imageMutex; + GradientTransform m_gradientTransform; }; } diff --git a/Gems/GradientSignal/Code/Source/Components/InvertGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/InvertGradientComponent.h similarity index 96% rename from Gems/GradientSignal/Code/Source/Components/InvertGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/InvertGradientComponent.h index 79dbea975b..a370286b0b 100644 --- a/Gems/GradientSignal/Code/Source/Components/InvertGradientComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/InvertGradientComponent.h @@ -64,6 +64,7 @@ namespace GradientSignal ////////////////////////////////////////////////////////////////////////// // GradientRequestBus float GetValue(const GradientSampleParams& sampleParams) const override; + void GetValues(AZStd::span positions, AZStd::span outValues) const override; bool IsEntityInHierarchy(const AZ::EntityId& entityId) const override; protected: diff --git a/Gems/GradientSignal/Code/Source/Components/LevelsGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/LevelsGradientComponent.h similarity index 97% rename from Gems/GradientSignal/Code/Source/Components/LevelsGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/LevelsGradientComponent.h index 5e70adfe32..093f84ef3a 100644 --- a/Gems/GradientSignal/Code/Source/Components/LevelsGradientComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/LevelsGradientComponent.h @@ -69,6 +69,7 @@ namespace GradientSignal ////////////////////////////////////////////////////////////////////////// // GradientRequestBus float GetValue(const GradientSampleParams& sampleParams) const override; + void GetValues(AZStd::span positions, AZStd::span outValues) const override; bool IsEntityInHierarchy(const AZ::EntityId& entityId) const override; protected: diff --git a/Gems/GradientSignal/Code/Source/Components/MixedGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/MixedGradientComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/MixedGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/MixedGradientComponent.h diff --git a/Gems/GradientSignal/Code/Source/Components/PerlinGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/PerlinGradientComponent.h similarity index 82% rename from Gems/GradientSignal/Code/Source/Components/PerlinGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/PerlinGradientComponent.h index 9fda45c716..19f3fe7294 100644 --- a/Gems/GradientSignal/Code/Source/Components/PerlinGradientComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/PerlinGradientComponent.h @@ -12,6 +12,7 @@ #include #include #include +#include #include #include @@ -47,6 +48,7 @@ namespace GradientSignal : public AZ::Component , private GradientRequestBus::Handler , private PerlinGradientRequestBus::Handler + , private GradientTransformNotificationBus::Handler { public: template friend class LmbrCentral::EditorWrappedComponentBase; @@ -60,23 +62,26 @@ namespace GradientSignal PerlinGradientComponent() = default; ~PerlinGradientComponent() = default; - ////////////////////////////////////////////////////////////////////////// - // AZ::Component interface implementation + // AZ::Component overrides... void Activate() override; void Deactivate() override; bool ReadInConfig(const AZ::ComponentConfig* baseConfig) override; bool WriteOutConfig(AZ::ComponentConfig* outBaseConfig) const override; - ////////////////////////////////////////////////////////////////////////// - // GradientRequestBus + // GradientRequestBus overrides... float GetValue(const GradientSampleParams& sampleParams) const override; + void GetValues(AZStd::span positions, AZStd::span outValues) const override; private: PerlinGradientConfig m_configuration; AZStd::unique_ptr m_perlinImprovedNoise; + GradientTransform m_gradientTransform; + mutable AZStd::shared_mutex m_transformMutex; - ///////////////////////////////////////////////////////////////////////// - //PerlinGradientRequest overrides + // GradientTransformNotificationBus overrides... + void OnGradientTransformChanged(const GradientTransform& newTransform) override; + + // PerlinGradientRequestBus overrides... int GetRandomSeed() const override; void SetRandomSeed(int seed) override; diff --git a/Gems/GradientSignal/Code/Source/Components/PosterizeGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/PosterizeGradientComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/PosterizeGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/PosterizeGradientComponent.h diff --git a/Gems/GradientSignal/Code/Source/Components/RandomGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/RandomGradientComponent.h similarity index 77% rename from Gems/GradientSignal/Code/Source/Components/RandomGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/RandomGradientComponent.h index 299b9dadfe..328fed5118 100644 --- a/Gems/GradientSignal/Code/Source/Components/RandomGradientComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/RandomGradientComponent.h @@ -10,6 +10,7 @@ #include #include +#include #include namespace LmbrCentral @@ -38,6 +39,7 @@ namespace GradientSignal : public AZ::Component , private GradientRequestBus::Handler , private RandomGradientRequestBus::Handler + , private GradientTransformNotificationBus::Handler { public: template friend class LmbrCentral::EditorWrappedComponentBase; @@ -51,23 +53,28 @@ namespace GradientSignal RandomGradientComponent() = default; ~RandomGradientComponent() = default; - ////////////////////////////////////////////////////////////////////////// - // AZ::Component interface implementation + // AZ::Component overrides... void Activate() override; void Deactivate() override; bool ReadInConfig(const AZ::ComponentConfig* baseConfig) override; bool WriteOutConfig(AZ::ComponentConfig* outBaseConfig) const override; - ////////////////////////////////////////////////////////////////////////// - // GradientRequestBus + // GradientRequestBus overrides... float GetValue(const GradientSampleParams& sampleParams) const override; + void GetValues(AZStd::span positions, AZStd::span outValues) const override; private: RandomGradientConfig m_configuration; + GradientTransform m_gradientTransform; + mutable AZStd::shared_mutex m_transformMutex; - ///////////////////////////////////////////////////////////////////////// - // RandomGradientRequest overrides + // GradientTransformNotificationBus overrides... + void OnGradientTransformChanged(const GradientTransform& newTransform) override; + + // RandomGradientRequestBus overrides... int GetRandomSeed() const override; void SetRandomSeed(int seed) override; + + float GetRandomValue(const AZ::Vector3& position, AZStd::size_t seed) const; }; } diff --git a/Gems/GradientSignal/Code/Source/Components/ReferenceGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/ReferenceGradientComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/ReferenceGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/ReferenceGradientComponent.h diff --git a/Gems/GradientSignal/Code/Source/Components/ShapeAreaFalloffGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/ShapeAreaFalloffGradientComponent.h similarity index 97% rename from Gems/GradientSignal/Code/Source/Components/ShapeAreaFalloffGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/ShapeAreaFalloffGradientComponent.h index d7c2344fd2..27b2da58a3 100644 --- a/Gems/GradientSignal/Code/Source/Components/ShapeAreaFalloffGradientComponent.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Components/ShapeAreaFalloffGradientComponent.h @@ -69,6 +69,7 @@ namespace GradientSignal ////////////////////////////////////////////////////////////////////////// // GradientRequestBus float GetValue(const GradientSampleParams& sampleParams) const override; + void GetValues(AZStd::span positions, AZStd::span outValues) const override; protected: ////////////////////////////////////////////////////////////////////////// diff --git a/Gems/GradientSignal/Code/Source/Components/SmoothStepGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/SmoothStepGradientComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/SmoothStepGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/SmoothStepGradientComponent.h diff --git a/Gems/GradientSignal/Code/Source/Components/SurfaceAltitudeGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/SurfaceAltitudeGradientComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/SurfaceAltitudeGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/SurfaceAltitudeGradientComponent.h diff --git a/Gems/GradientSignal/Code/Source/Components/SurfaceMaskGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/SurfaceMaskGradientComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/SurfaceMaskGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/SurfaceMaskGradientComponent.h diff --git a/Gems/GradientSignal/Code/Source/Components/SurfaceSlopeGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/SurfaceSlopeGradientComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/SurfaceSlopeGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/SurfaceSlopeGradientComponent.h diff --git a/Gems/GradientSignal/Code/Source/Components/ThresholdGradientComponent.h b/Gems/GradientSignal/Code/Include/GradientSignal/Components/ThresholdGradientComponent.h similarity index 100% rename from Gems/GradientSignal/Code/Source/Components/ThresholdGradientComponent.h rename to Gems/GradientSignal/Code/Include/GradientSignal/Components/ThresholdGradientComponent.h diff --git a/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientRequestBus.h b/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientRequestBus.h index 1782972acf..45b5a173a3 100644 --- a/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientRequestBus.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientRequestBus.h @@ -10,6 +10,7 @@ #include #include #include +#include namespace GradientSignal { @@ -49,6 +50,31 @@ namespace GradientSignal */ virtual float GetValue(const GradientSampleParams& sampleParams) const = 0; + /** + * Given a list of positions, generate values. Implementations of this need to be thread-safe without using locks, + * as it can get called from multiple threads simultaneously and has the potential to cause lock inversion deadlocks. + * \param positions The input list of positions to query. + * \param outValues The output list of values. This list is expected to be the same size as the positions list. + */ + virtual void GetValues(AZStd::span positions, AZStd::span outValues) const + { + // Reference implementation of GetValues for any gradients that don't have their own optimized implementations. + // This is 10%-60% faster than calling GetValue via EBus many times due to the per-call EBus overhead. + + if (positions.size() != outValues.size()) + { + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; + } + + GradientSampleParams sampleParams; + for (size_t index = 0; index < positions.size(); index++) + { + sampleParams.m_position = positions[index]; + outValues[index] = GetValue(sampleParams); + } + } + /** * Call to check the hierarchy to see if a given entityId exists in the gradient signal chain */ diff --git a/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientTransformModifierRequestBus.h b/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientTransformModifierRequestBus.h index 34cc8ef685..eba6aad12c 100644 --- a/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientTransformModifierRequestBus.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientTransformModifierRequestBus.h @@ -13,14 +13,30 @@ namespace GradientSignal { + //! TransformType describes where the gradient's origin is mapped to. + enum class TransformType : AZ::u8 + { + //! The gradient's origin is the world position of this entity. + World_ThisEntity = 0, + //! The gradient's origin is the local position of this entity, but in world space. + //! i.e. If the parent is at (2, 2), and the gradient is at (3,3) in local space, the gradient entity itself will be at (5,5) in + //! world space but its origin will frozen at (3,3) in world space, no matter how much the parent moves around. + Local_ThisEntity, + //! The gradient's origin is the world position of the reference entity. + World_ReferenceEntity, + //! The gradient's origin is the local position of the reference entity, but in world space. + Local_ReferenceEntity, + //! The gradient's origin is at (0,0,0) in world space. + World_Origin, + //! The gradient's origin is in translated world space relative to the reference entity. + Relative, + }; + class GradientTransformModifierRequests : public AZ::ComponentBus { public: - /** - * Overrides the default AZ::EBusTraits handler policy to allow one - * listener only. - */ + //! Overrides the default AZ::EBusTraits handler policy to allow only one listener. static const AZ::EBusHandlerPolicy HandlerPolicy = AZ::EBusHandlerPolicy::Single; virtual bool GetAllowReference() const = 0; diff --git a/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientTransformRequestBus.h b/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientTransformRequestBus.h index 426255efe7..3b674d0bd5 100644 --- a/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientTransformRequestBus.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Ebuses/GradientTransformRequestBus.h @@ -11,6 +11,7 @@ #include #include #include +#include namespace GradientSignal { @@ -22,15 +23,56 @@ namespace GradientSignal static const AZ::EBusAddressPolicy AddressPolicy = AZ::EBusAddressPolicy::ById; using BusIdType = AZ::EntityId; - //! allows multiple threads to call shape requests + //! allows multiple threads to call gradient transform requests using MutexType = AZStd::recursive_mutex; virtual ~GradientTransformRequests() = default; - virtual void TransformPositionToUVW(const AZ::Vector3& inPosition, AZ::Vector3& outUVW, const bool shouldNormalizeOutput, bool& wasPointRejected) const = 0; - virtual void GetGradientLocalBounds(AZ::Aabb& bounds) const = 0; - virtual void GetGradientEncompassingBounds(AZ::Aabb& bounds) const = 0; + //! Get the GradientTransform that's been configured by the bus listener. + //! \return the GradientTransform instance that can be used to transform world points into gradient lookup space. + virtual const GradientTransform& GetGradientTransform() const = 0; }; using GradientTransformRequestBus = AZ::EBus; + + /** + * Notifies about changes to the GradientTransform configuration + */ + class GradientTransformNotifications + : public AZ::EBusTraits + { + public: + //////////////////////////////////////////////////////////////////////// + // EBusTraits + static const AZ::EBusAddressPolicy AddressPolicy = AZ::EBusAddressPolicy::ById; + using BusIdType = AZ::EntityId; + using MutexType = AZStd::recursive_mutex; + //////////////////////////////////////////////////////////////////////// + + //! Notify listeners that the GradientTransform configuration has changed. + //! \return the GradientTransform instance that can be used to transform world points into gradient lookup space. + virtual void OnGradientTransformChanged(const GradientTransform& newTransform) = 0; + + //! Connection policy that auto-calls OnGradientTransformChanged on connection with the current GradientTransform data. + template + struct ConnectionPolicy : public AZ::EBusConnectionPolicy + { + static void Connect( + typename Bus::BusPtr& busPtr, + typename Bus::Context& context, + typename Bus::HandlerNode& handler, + typename Bus::Context::ConnectLockGuard& connectLock, + const typename Bus::BusIdType& id = 0) + { + AZ::EBusConnectionPolicy::Connect(busPtr, context, handler, connectLock, id); + + GradientTransform transform; + GradientTransformRequestBus::EventResult(transform, id, &GradientTransformRequests::GetGradientTransform); + handler->OnGradientTransformChanged(transform); + } + }; + }; + + using GradientTransformNotificationBus = AZ::EBus; + } //namespace GradientSignal diff --git a/Gems/GradientSignal/Code/Include/GradientSignal/GradientSampler.h b/Gems/GradientSignal/Code/Include/GradientSignal/GradientSampler.h index c06265fb24..c9aa7f680c 100644 --- a/Gems/GradientSignal/Code/Include/GradientSignal/GradientSampler.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/GradientSampler.h @@ -33,6 +33,7 @@ namespace GradientSignal static void Reflect(AZ::ReflectContext* context); inline float GetValue(const GradientSampleParams& sampleParams) const; + inline void GetValues(AZStd::span positions, AZStd::span outValues) const; bool IsEntityInHierarchy(const AZ::EntityId& entityId) const; @@ -88,8 +89,6 @@ namespace GradientSignal inline float GradientSampler::GetValue(const GradientSampleParams& sampleParams) const { - AZ_PROFILE_FUNCTION(Entity); - if (m_opacity <= 0.0f || !m_gradientId.IsValid()) { return 0.0f; @@ -121,7 +120,7 @@ namespace GradientSignal if (m_isRequestInProgress) { - AZ_ErrorOnce("GradientSignal", !m_isRequestInProgress, "Detected cyclic dependences with gradient entity references"); + AZ_ErrorOnce("GradientSignal", !m_isRequestInProgress, "Detected cyclic dependencies with gradient entity references"); } else { @@ -147,4 +146,83 @@ namespace GradientSignal return output * m_opacity; } + + inline void GradientSampler::GetValues(AZStd::span positions, AZStd::span outValues) const + { + auto ClearOutputValues = [](AZStd::span outValues) + { + // If we don't have a valid gradient (or it is fully transparent), clear out all the output values. + memset(outValues.data(), 0, outValues.size() * sizeof(float)); + }; + + if (m_opacity <= 0.0f || !m_gradientId.IsValid()) + { + ClearOutputValues(outValues); + return; + } + + AZStd::vector transformedPositions; + bool useTransformedPositions = false; + + // apply transform if set + if (m_enableTransform && GradientSamplerUtil::AreTransformParamsSet(*this)) + { + AZ::Matrix3x4 matrix3x4; + matrix3x4.SetFromEulerDegrees(m_rotate); + matrix3x4.MultiplyByScale(m_scale); + matrix3x4.SetTranslation(m_translate); + + useTransformedPositions = true; + transformedPositions.resize(positions.size()); + for (size_t index = 0; index < positions.size(); index++) + { + transformedPositions[index] = matrix3x4 * positions[index]; + } + } + + { + // Block other threads from accessing the surface data bus while we are in GetValue (which may call into the SurfaceData bus). + // We lock our surface data mutex *before* checking / setting "isRequestInProgress" so that we prevent race conditions + // that create false detection of cyclic dependencies when multiple requests occur on different threads simultaneously. + // (One case where this was previously able to occur was in rapid updating of the Preview widget on the + // GradientSurfaceDataComponent in the Editor when moving the threshold sliders back and forth rapidly) + auto& surfaceDataContext = SurfaceData::SurfaceDataSystemRequestBus::GetOrCreateContext(false); + typename SurfaceData::SurfaceDataSystemRequestBus::Context::DispatchLockGuard scopeLock(surfaceDataContext.m_contextMutex); + + if (m_isRequestInProgress) + { + AZ_ErrorOnce("GradientSignal", !m_isRequestInProgress, "Detected cyclic dependencies with gradient entity references"); + ClearOutputValues(outValues); + return; + } + else + { + m_isRequestInProgress = true; + + GradientRequestBus::Event( + m_gradientId, &GradientRequestBus::Events::GetValues, useTransformedPositions ? transformedPositions : positions, + outValues); + + m_isRequestInProgress = false; + } + } + + // Perform any post-fetch transformations on the gradient values (invert, levels, opacity). + for (auto& outValue : outValues) + { + if (m_invertInput) + { + outValue = 1.0f - outValue; + } + + // apply levels if set + if (m_enableLevels && GradientSamplerUtil::AreLevelParamsSet(*this)) + { + outValue = GetLevels(outValue, m_inputMid, m_inputMin, m_inputMax, m_outputMin, m_outputMax); + } + + outValue = outValue * m_opacity; + } + } + } diff --git a/Gems/GradientSignal/Code/Include/GradientSignal/GradientTransform.h b/Gems/GradientSignal/Code/Include/GradientSignal/GradientTransform.h new file mode 100644 index 0000000000..b191ea245a --- /dev/null +++ b/Gems/GradientSignal/Code/Include/GradientSignal/GradientTransform.h @@ -0,0 +1,155 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ +#pragma once + +#include +#include +#include +#include +#include + +namespace GradientSignal +{ + //! Controls how the gradient repeats itself when queried outside the bounds of the shape. + enum class WrappingType : AZ::u8 + { + None = 0, //! Unbounded - the gradient ignores the shape bounds. + ClampToEdge, //! The values on the edge of the shape will be extended outward in each direction. + Mirror, //! The gradient signal will be repeated but mirrored on every repeat. + Repeat, //! The gradient signal will be repeated in every direction. + ClampToZero, //! The value will always be 0 outside of the shape. + }; + + class GradientTransform + { + public: + GradientTransform() = default; + + /** + * Create a GradientTransform with the given parameters. + * GradientTransform is a utility class that converts world space positions to gradient space UVW values which can be used + * to look up deterministic gradient values for the input spatial locations. + * \param shapeBounds The bounds of the shape associated with the gradient, in local space. + * \param transform The transform to use to convert from world space to gradient space. + * \param use3d True for 3D gradient lookup outputs, false for 2D gradient lookup outputs. (i.e. output W will be nonzero or zero) + * \param frequencyZoom Amount to scale the UVW results after wrapping is applied. + * \param wrappingType The way in which the gradient repeats itself outside the shape bounds. + */ + GradientTransform( + const AZ::Aabb& shapeBounds, + const AZ::Matrix3x4& transform, + bool use3d, + float frequencyZoom, + GradientSignal::WrappingType wrappingType); + + /** + * Checks to see if two GradientTransform instances are equivalent. + * Useful for being able to send out notifications when a GradientTransform has changed. + * \param rhs The second GradientTranform to compare against. + * \return True if they're equal, False if they aren't. + */ + bool operator==(const GradientTransform& rhs) const + { + return ( + (m_shapeBounds == rhs.m_shapeBounds) && + (m_inverseTransform == rhs.m_inverseTransform) && + (m_alwaysAcceptPoint == rhs.m_alwaysAcceptPoint) && + (m_frequencyZoom == rhs.m_frequencyZoom) && + (m_wrappingType == rhs.m_wrappingType) && + (m_normalizeExtentsReciprocal == rhs.m_normalizeExtentsReciprocal)); + } + + /** + * Checks to see if two GradientTransform instances aren't equivalent. + * Useful for being able to send out notifications when a GradientTransform has changed. + * \param rhs The second GradientTranform to compare against. + * \return True if they're not equal, False if they are. + */ + bool operator!=(const GradientTransform& rhs) const + { + return !(*this == rhs); + } + + + /** + * Transform the given world space position to a gradient space UVW lookup value. + * \param inPosition The input world space position to transform. + * \param outUVW [out] The UVW value that can be used to look up a deterministic gradient value. + * \param wasPointRejected [out] True if the input position doesn't have a gradient value, false if it does. + * Most gradients have values mapped to infinite world space, so wasPointRejected will almost always be false. + * It will only be true when using ClampToZero and the world space position falls outside the shape bounds. + */ + void TransformPositionToUVW(const AZ::Vector3& inPosition, AZ::Vector3& outUVW, bool& wasPointRejected) const; + + /** + * Transform the given world space position to a gradient space UVW lookup value and normalize to the shape bounds. + * "Normalizing" in this context means that regardless of the world space coordinates, (0,0,0) represents the minimum + * shape bounds corner, and (1,1,1) represents the maximum shape bounds corner. Depending on the wrapping type, it's possible + * (and even likely) to get values outside the 0-1 range. + * \param inPosition The input world space position to transform. + * \param outUVW [out] The UVW value that can be used to look up a deterministic gradient value. + * \param wasPointRejected [out] True if the input position doesn't have a gradient value, false if it does. + * Most gradients have values mapped to infinite world space, so wasPointRejected will almost always be false. + * It will only be true when using ClampToZero and the world space position falls outside the shape bounds. + */ + void TransformPositionToUVWNormalized(const AZ::Vector3& inPosition, AZ::Vector3& outUVW, bool& wasPointRejected) const; + + /** + * Epsilon value to allow our UVW range to go to [min, max) by using the range [min, max - epsilon]. + * To keep things behaving consistently between clamped and unbounded uv ranges, we want our clamped uvs to use a + * range of [min, max), so we'll actually clamp to [min, max - epsilon]. Since our floating-point numbers are likely in the + * -16384 to 16384 range, an epsilon of 0.001 will work without rounding to 0. + * (This constant is public so that it can be used from unit tests for validating transformation results) + */ + static constexpr float UvEpsilon = 0.001f; + + private: + + //! These are the various transformations that will be performed, based on wrapping type. + static AZ::Vector3 NoTransform(const AZ::Vector3& point, const AZ::Aabb& bounds); + static AZ::Vector3 GetUnboundedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); + static AZ::Vector3 GetClampedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); + static AZ::Vector3 GetMirroredPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); + static AZ::Vector3 GetRelativePointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); + static AZ::Vector3 GetWrappedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); + + //! The shape bounds are used for determining the wrapping bounds, and to normalize the UVW results into if requested. + AZ::Aabb m_shapeBounds = AZ::Aabb::CreateNull(); + + /** + * The relative transform to use for converting from world space to gradient space, stored as an inverse transform. + * We only ever need to use the inverse transform, so we compute it once and store it instead of keeping the original + * transform around. Note that the GradientTransformComponent has many options for choosing which relative space to use + * for the transform, so the transform passed in to this class might already have many modifications applied to it. + * The inverse transform will also get its 3rd row cleared out if "use3d" is false and we're only performing 2D gradient + * transformations, so that the W component of the UVW output will always be 0. + */ + AZ::Matrix3x4 m_inverseTransform = AZ::Matrix3x4::CreateIdentity(); + + /** + * Whether or not to always accept the input point as a valid output point. + * Most of the time, the gradient exists everywhere in world space, so we always accept the input point. + * The one exception is ClampToZero, which will return that the point is rejected if it falls outside the shape bounds. + */ + bool m_alwaysAcceptPoint = true; + + //! Apply a scale to the point *after* the wrapping is applied. + float m_frequencyZoom = 1.0f; + + //! How the gradient should repeat itself outside of the shape bounds. + WrappingType m_wrappingType = WrappingType::None; + + /** + * Cached reciprocal for performing an inverse lerp back to shape bounds. + * When normalizing the output UVW back into the shape bounds, we perform an inverse lerp. The inverse lerp + * equation is (point - min) * (1 / (max-min)), so we save off the (1 / (max-min)) term to avoid recalculating it on every point. + */ + AZ::Vector3 m_normalizeExtentsReciprocal = AZ::Vector3(1.0f); + }; + +} // namespace GradientSignal diff --git a/Gems/GradientSignal/Code/Include/GradientSignal/ImageAsset.h b/Gems/GradientSignal/Code/Include/GradientSignal/ImageAsset.h index f65702c36c..4ffab0b4b4 100644 --- a/Gems/GradientSignal/Code/Include/GradientSignal/ImageAsset.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/ImageAsset.h @@ -35,6 +35,13 @@ namespace GradientSignal static bool VersionConverter(AZ::SerializeContext& context, AZ::SerializeContext::DataElementNode& classElement); + ImageAsset() = default; + + ImageAsset(const AZ::Data::AssetId& assetId, AZ::Data::AssetData::AssetStatus status) + : AssetData(assetId, status) + { + } + AZ::u32 m_imageWidth = 0; AZ::u32 m_imageHeight = 0; AZ::u8 m_bytesPerPixel = 0; diff --git a/Gems/GradientSignal/Code/Include/GradientSignal/Util.h b/Gems/GradientSignal/Code/Include/GradientSignal/Util.h index 1e0ae79e08..f91c5d54f1 100644 --- a/Gems/GradientSignal/Code/Include/GradientSignal/Util.h +++ b/Gems/GradientSignal/Code/Include/GradientSignal/Util.h @@ -7,60 +7,17 @@ */ #pragma once +#include #include #include -#include #include #include +#include #include - -namespace LmbrCentral -{ - class MeshAsset; -} +#include namespace GradientSignal { - enum class WrappingType : AZ::u8 - { - None = 0, - ClampToEdge, - Mirror, - Repeat, - ClampToZero, - }; - - enum class TransformType : AZ::u8 - { - World_ThisEntity = 0, - Local_ThisEntity, - World_ReferenceEntity, - Local_ReferenceEntity, - World_Origin, - Relative, - }; - - AZ::Vector3 GetUnboundedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); - AZ::Vector3 GetClampedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); - AZ::Vector3 GetMirroredPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); - AZ::Vector3 GetRelativePointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds); - - inline AZ::Vector3 GetWrappedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) - { - return AZ::Vector3( - AZ::Wrap(point.GetX(), bounds.GetMin().GetX(), bounds.GetMax().GetX()), - AZ::Wrap(point.GetY(), bounds.GetMin().GetY(), bounds.GetMax().GetY()), - AZ::Wrap(point.GetZ(), bounds.GetMin().GetZ(), bounds.GetMax().GetZ())); - } - - inline AZ::Vector3 GetNormalizedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) - { - return AZ::Vector3( - AZ::LerpInverse(bounds.GetMin().GetX(), bounds.GetMax().GetX(), point.GetX()), - AZ::LerpInverse(bounds.GetMin().GetY(), bounds.GetMax().GetY(), point.GetY()), - AZ::LerpInverse(bounds.GetMin().GetZ(), bounds.GetMax().GetZ(), point.GetZ())); - } - inline void GetObbParamsFromShape(const AZ::EntityId& entity, AZ::Aabb& bounds, AZ::Matrix3x4& worldToBoundsTransform) { //get bound and transform data for associated shape @@ -97,27 +54,61 @@ namespace GradientSignal inline float GetLevels(float input, float inputMid, float inputMin, float inputMax, float outputMin, float outputMax) { - input = AZ::GetClamp(input, 0.0f, 1.0f); - inputMid = AZ::GetClamp(inputMid, 0.01f, 10.0f); // Clamp the midpoint to a non-zero value so that it's always safe to divide by it. + inputMid = AZ::GetClamp(inputMid, 0.01f, 10.0f); // Clamp the midpoint to a non-zero value so that it's always safe to divide by it. + inputMin = AZ::GetClamp(inputMin, 0.0f, 1.0f); + inputMax = AZ::GetClamp(inputMax, 0.0f, 1.0f); + outputMin = AZ::GetClamp(outputMin, 0.0f, 1.0f); + outputMax = AZ::GetClamp(outputMax, 0.0f, 1.0f); + + if (inputMin == inputMax) + { + return (AZ::GetClamp(input, 0.0f, 1.0f) <= inputMin) ? outputMin : outputMax; + } + + const float inputMidReciprocal = 1.0f / inputMid; + const float inputExtentsReciprocal = 1.0f / (inputMax - inputMin); + + const float inputRemapped = + AZ::GetMin(AZ::GetMax(AZ::GetClamp(input, 0.0f, 1.0f) - inputMin, 0.0f) * inputExtentsReciprocal, 1.0f); + + // Note: Some paint programs map the midpoint using 1/mid where low values are dark and high values are light, + // others do the reverse and use mid directly, so low values are light and high values are dark. We've chosen to + // align with 1/mid since it appears to be the more prevalent of the two approaches. + const float inputCorrected = powf(inputRemapped, inputMidReciprocal); + + return AZ::Lerp(outputMin, outputMax, inputCorrected); + } + + inline void GetLevels(AZStd::span inOutValues, float inputMid, float inputMin, float inputMax, float outputMin, float outputMax) + { + inputMid = AZ::GetClamp(inputMid, 0.01f, 10.0f); // Clamp the midpoint to a non-zero value so that it's always safe to divide by it. inputMin = AZ::GetClamp(inputMin, 0.0f, 1.0f); inputMax = AZ::GetClamp(inputMax, 0.0f, 1.0f); outputMin = AZ::GetClamp(outputMin, 0.0f, 1.0f); outputMax = AZ::GetClamp(outputMax, 0.0f, 1.0f); - float inputCorrected = 0.0f; if (inputMin == inputMax) { - inputCorrected = (input <= inputMin) ? 0.0f : 1.0f; + for (auto& inOutValue : inOutValues) + { + inOutValue = (AZ::GetClamp(inOutValue, 0.0f, 1.0f) <= inputMin) ? outputMin : outputMax; + } } - else + + const float inputMidReciprocal = 1.0f / inputMid; + const float inputExtentsReciprocal = 1.0f / (inputMax - inputMin); + + for (auto& inOutValue : inOutValues) { - const float inputRemapped = AZ::GetMin(AZ::GetMax(input - inputMin, 0.0f) / (inputMax - inputMin), 1.0f); - // Note: Some paint programs map the midpoint using 1/mid where low values are dark and high values are light, - // others do the reverse and use mid directly, so low values are light and high values are dark. We've chosen to + const float inputRemapped = + AZ::GetMin(AZ::GetMax(AZ::GetClamp(inOutValue, 0.0f, 1.0f) - inputMin, 0.0f) * inputExtentsReciprocal, 1.0f); + + // Note: Some paint programs map the midpoint using 1/mid where low values are dark and high values are light, + // others do the reverse and use mid directly, so low values are light and high values are dark. We've chosen to // align with 1/mid since it appears to be the more prevalent of the two approaches. - inputCorrected = powf(inputRemapped, 1.0f / inputMid); - } + const float inputCorrected = powf(inputRemapped, inputMidReciprocal); - return AZ::Lerp(outputMin, outputMax, inputCorrected); + inOutValue = AZ::Lerp(outputMin, outputMax, inputCorrected); + } } } // namespace GradientSignal diff --git a/Gems/GradientSignal/Code/Source/Components/ConstantGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/ConstantGradientComponent.cpp index 3bb27b00f3..ac81f616c6 100644 --- a/Gems/GradientSignal/Code/Source/Components/ConstantGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/ConstantGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "ConstantGradientComponent.h" +#include #include #include #include @@ -134,6 +134,18 @@ namespace GradientSignal return m_configuration.m_value; } + void ConstantGradientComponent::GetValues( + [[maybe_unused]] AZStd::span positions, AZStd::span outValues) const + { + if (positions.size() != outValues.size()) + { + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; + } + + AZStd::fill(outValues.begin(), outValues.end(), m_configuration.m_value); + } + float ConstantGradientComponent::GetConstantValue() const { return m_configuration.m_value; diff --git a/Gems/GradientSignal/Code/Source/Components/DitherGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/DitherGradientComponent.cpp index dbc2cd2827..1b320afeb9 100644 --- a/Gems/GradientSignal/Code/Source/Components/DitherGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/DitherGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "DitherGradientComponent.h" +#include #include #include #include @@ -174,90 +174,122 @@ namespace GradientSignal return false; } - int PositionToMatrixIndex(float position, int patternSize) + int DitherGradientComponent::ScaledPositionToPatternIndex(const AZ::Vector3& scaledPosition, int patternSize) { - int result = static_cast(std::floor(fmod(position, static_cast(patternSize)))); + // The input position is expected to be scaled up so that each integer value is a unique point in our dither pattern, and + // the fractional value is just the amount within the point. The output is the specific index into an NxN pattern to use + // for the dither comparison value. - if (result < 0) - { - result += patternSize; - } + // Get the floor before casting to int because we want fractional negative values to go "down" to the next negative value. + AZ::Vector3 flooredScaledPosition = scaledPosition.GetFloor(); + + // For a pattern of 4, we want our indices to go 0, 1, 2, 3, 0, 1, 2, 3, etc. However, we want it continuous across + // negative and positive positions so we can't just use mod with abs(). Instead, we use a double-mod which gives us + // a result that's continuous across all coordinate space. + const int x = ((static_cast(flooredScaledPosition.GetX()) % patternSize) + patternSize) % patternSize; + const int y = ((static_cast(flooredScaledPosition.GetY()) % patternSize) + patternSize) % patternSize; - return result; + return (patternSize * y + x); } - float GetDitherValue4x4(const AZ::Vector3& position) + float DitherGradientComponent::GetDitherValue4x4(const AZ::Vector3& scaledPosition) { - const int patternSize = 4; - const int patternSizeSq = patternSize * patternSize; - const int indexMatrix[patternSizeSq] = { - 0, 8, 2, 10, - 12, 4, 14, 6, - 3, 11, 1, 9, - 15, 7, 13, 5 }; - - const int x = PositionToMatrixIndex(position.GetX(), patternSize); - const int y = PositionToMatrixIndex(position.GetY(), patternSize); - - return indexMatrix[patternSize * y + x] / static_cast(patternSizeSq); + constexpr int patternSize = 4; + constexpr float indexMatrix[] = { + 0.0f / 16.0f, 8.0f / 16.0f, 2.0f / 16.0f, 10.0f / 16.0f, + 12.0f / 16.0f, 4.0f / 16.0f, 14.0f / 16.0f, 6.0f / 16.0f, + 3.0f / 16.0f, 11.0f / 16.0f, 1.0f / 16.0f, 9.0f / 16.0f, + 15.0f / 16.0f, 7.0f / 16.0f, 13.0f / 16.0f, 5.0f / 16.0f }; + + return indexMatrix[ScaledPositionToPatternIndex(scaledPosition, patternSize)]; } - float GetDitherValue8x8(const AZ::Vector3& position) + float DitherGradientComponent::GetDitherValue8x8(const AZ::Vector3& scaledPosition) { - const int patternSize = 8; - const int patternSizeSq = patternSize * patternSize; - const int indexMatrix[patternSizeSq] = { - 0, 32, 8, 40, 2, 34, 10, 42, - 48, 16, 56, 24, 50, 18, 58, 26, - 12, 44, 4, 36, 14, 46, 6, 38, - 60, 28, 52, 20, 62, 30, 54, 22, - 3, 35, 11, 43, 1, 33, 9, 41, - 51, 19, 59, 27, 49, 17, 57, 25, - 15, 47, 7, 39, 13, 45, 5, 37, - 63, 31, 55, 23, 61, 29, 53, 21 }; - - const int x = PositionToMatrixIndex(position.GetX(), patternSize); - const int y = PositionToMatrixIndex(position.GetY(), patternSize); - - return indexMatrix[patternSize * y + x] / static_cast(patternSizeSq); + constexpr int patternSize = 8; + constexpr float indexMatrix[] = { + 0.0f / 64.0f, 32.0f / 64.0f, 8.0f / 64.0f, 40.0f / 64.0f, 2.0f / 64.0f, 34.0f / 64.0f, 10.0f / 64.0f, 42.0f / 64.0f, + 48.0f / 64.0f, 16.0f / 64.0f, 56.0f / 64.0f, 24.0f / 64.0f, 50.0f / 64.0f, 18.0f / 64.0f, 58.0f / 64.0f, 26.0f / 64.0f, + 12.0f / 64.0f, 44.0f / 64.0f, 4.0f / 64.0f, 36.0f / 64.0f, 14.0f / 64.0f, 46.0f / 64.0f, 6.0f / 64.0f, 38.0f / 64.0f, + 60.0f / 64.0f, 28.0f / 64.0f, 52.0f / 64.0f, 20.0f / 64.0f, 62.0f / 64.0f, 30.0f / 64.0f, 54.0f / 64.0f, 22.0f / 64.0f, + 3.0f / 64.0f, 35.0f / 64.0f, 11.0f / 64.0f, 43.0f / 64.0f, 1.0f / 64.0f, 33.0f / 64.0f, 9.0f / 64.0f, 41.0f / 64.0f, + 51.0f / 64.0f, 19.0f / 64.0f, 59.0f / 64.0f, 27.0f / 64.0f, 49.0f / 64.0f, 17.0f / 64.0f, 57.0f / 64.0f, 25.0f / 64.0f, + 15.0f / 64.0f, 47.0f / 64.0f, 7.0f / 64.0f, 39.0f / 64.0f, 13.0f / 64.0f, 45.0f / 64.0f, 5.0f / 64.0f, 37.0f / 64.0f, + 63.0f / 64.0f, 31.0f / 64.0f, 55.0f / 64.0f, 23.0f / 64.0f, 61.0f / 64.0f, 29.0f / 64.0f, 53.0f / 64.0f, 21.0f / 64.0f + }; + + return indexMatrix[ScaledPositionToPatternIndex(scaledPosition, patternSize)]; } - float DitherGradientComponent::GetValue(const GradientSampleParams& sampleParams) const + float DitherGradientComponent::GetCalculatedPointsPerUnit() const { - AZ_PROFILE_FUNCTION(Entity); - - const AZ::Vector3& coordinate = sampleParams.m_position; - float pointsPerUnit = m_configuration.m_pointsPerUnit; if (m_configuration.m_useSystemPointsPerUnit) { SectorDataRequestBus::Broadcast(&SectorDataRequestBus::Events::GetPointsPerMeter, pointsPerUnit); } - pointsPerUnit = AZ::GetMax(pointsPerUnit, 0.0001f); - - auto scaledCoordinate = coordinate * pointsPerUnit; - auto x = std::floor(scaledCoordinate.GetX()) / pointsPerUnit; - auto y = std::floor(scaledCoordinate.GetY()) / pointsPerUnit; - auto z = std::floor(scaledCoordinate.GetZ()) / pointsPerUnit; - AZ::Vector3 flooredCoordinate(x, y, z); - - GradientSampleParams adjustedSampleParams = sampleParams; - adjustedSampleParams.m_position = flooredCoordinate; - float value = m_configuration.m_gradientSampler.GetValue(adjustedSampleParams); + return AZ::GetMax(pointsPerUnit, 0.0001f); + } + float DitherGradientComponent::GetDitherValue(const AZ::Vector3& scaledPosition, float value) const + { float d = 0.0f; switch (m_configuration.m_patternType) { default: case DitherGradientConfig::BayerPatternType::PATTERN_SIZE_4x4: - d = GetDitherValue4x4((scaledCoordinate) + m_configuration.m_patternOffset); + d = GetDitherValue4x4(scaledPosition + m_configuration.m_patternOffset); break; case DitherGradientConfig::BayerPatternType::PATTERN_SIZE_8x8: - d = GetDitherValue8x8((scaledCoordinate) + m_configuration.m_patternOffset); + d = GetDitherValue8x8(scaledPosition + m_configuration.m_patternOffset); break; } - return value > d ? 1.0f : 0.0f; + return (value > d) ? 1.0f : 0.0f; + } + + float DitherGradientComponent::GetValue(const GradientSampleParams& sampleParams) const + { + const AZ::Vector3& coordinate = sampleParams.m_position; + + const float pointsPerUnit = GetCalculatedPointsPerUnit(); + + AZ::Vector3 scaledCoordinate = coordinate * pointsPerUnit; + AZ::Vector3 flooredCoordinate = scaledCoordinate.GetFloor() / pointsPerUnit; + + GradientSampleParams adjustedSampleParams = sampleParams; + adjustedSampleParams.m_position = flooredCoordinate; + float value = m_configuration.m_gradientSampler.GetValue(adjustedSampleParams); + + return GetDitherValue(scaledCoordinate, value); + } + + void DitherGradientComponent::GetValues(AZStd::span positions, AZStd::span outValues) const + { + if (positions.size() != outValues.size()) + { + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; + } + + const float pointsPerUnit = GetCalculatedPointsPerUnit(); + + // Create the entire set of floored coordinates to use in the gradient value lookups. + AZStd::vector flooredCoordinates(positions.size()); + for (size_t index = 0; index < positions.size(); index++) + { + AZ::Vector3 scaledCoordinate = positions[index] * pointsPerUnit; + flooredCoordinates[index] = scaledCoordinate.GetFloor() / pointsPerUnit; + } + + m_configuration.m_gradientSampler.GetValues(flooredCoordinates, outValues); + + // For each gradient value, turn it into a 0 or 1 based on the location and the dither pattern. + for (size_t index = 0; index < positions.size(); index++) + { + AZ::Vector3 scaledCoordinate = positions[index] * pointsPerUnit; + outValues[index] = GetDitherValue(scaledCoordinate, outValues[index]); + } } bool DitherGradientComponent::IsEntityInHierarchy(const AZ::EntityId& entityId) const diff --git a/Gems/GradientSignal/Code/Source/Components/GradientSurfaceDataComponent.cpp b/Gems/GradientSignal/Code/Source/Components/GradientSurfaceDataComponent.cpp index bdda0e48d2..5a0555fe33 100644 --- a/Gems/GradientSignal/Code/Source/Components/GradientSurfaceDataComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/GradientSurfaceDataComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "GradientSurfaceDataComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Components/GradientTransformComponent.cpp b/Gems/GradientSignal/Code/Source/Components/GradientTransformComponent.cpp index 57de6f776a..67f073a178 100644 --- a/Gems/GradientSignal/Code/Source/Components/GradientTransformComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/GradientTransformComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "GradientTransformComponent.h" +#include #include #include #include @@ -276,24 +276,29 @@ namespace GradientSignal void GradientTransformComponent::Activate() { + m_dirty = false; + m_gradientTransform = GradientTransform(); + + // Update our GradientTransform to be configured correctly. We don't need to notify dependents of the change though. + // If anyone is listening, they're already getting notified below. + const bool notifyDependentsOfChange = false; + UpdateFromShape(notifyDependentsOfChange); + GradientTransformRequestBus::Handler::BusConnect(GetEntityId()); LmbrCentral::DependencyNotificationBus::Handler::BusConnect(GetEntityId()); AZ::TickBus::Handler::BusConnect(); GradientTransformModifierRequestBus::Handler::BusConnect(GetEntityId()); - m_dirty = false; - m_dependencyMonitor.Reset(); m_dependencyMonitor.ConnectOwner(GetEntityId()); m_dependencyMonitor.ConnectDependency(GetEntityId()); m_dependencyMonitor.ConnectDependency(GetShapeEntityId()); - - UpdateFromShape(); } void GradientTransformComponent::Deactivate() { m_dirty = false; + m_gradientTransform = GradientTransform(); m_dependencyMonitor.Reset(); GradientTransformRequestBus::Handler::BusDisconnect(); @@ -322,66 +327,10 @@ namespace GradientSignal return false; } - void GradientTransformComponent::TransformPositionToUVW(const AZ::Vector3& inPosition, AZ::Vector3& outUVW, const bool shouldNormalizeOutput, bool& wasPointRejected) const + const GradientTransform& GradientTransformComponent::GetGradientTransform() const { AZStd::lock_guard lock(m_cacheMutex); - - //transforming coordinate into "local" relative space of shape bounds - outUVW = m_shapeTransformInverse * inPosition; - - if (!m_configuration.m_advancedMode || !m_configuration.m_is3d) - { - outUVW.SetZ(0.0f); - } - - wasPointRejected = false; - if (m_shapeBounds.IsValid()) - { - //all wrap types and transformations are applied after the coordinate is transformed into shape relative space - //this allows all calculations to be simplified and done using the shapes untransformed aabb - //outputting a value that can be used to sample a gradient in its local space - switch (m_configuration.m_wrappingType) - { - default: - case WrappingType::None: - outUVW = GetUnboundedPointInAabb(outUVW, m_shapeBounds); - break; - case WrappingType::ClampToEdge: - outUVW = GetClampedPointInAabb(outUVW, m_shapeBounds); - break; - case WrappingType::ClampToZero: - // We don't want to use m_shapeBounds.Contains() here because Contains() is inclusive on all edges. - // For uv consistency between clamped and unclamped states, we only want to accept uv ranges of [min, max), - // so we specifically need to exclude the max edges here. - wasPointRejected = !(outUVW.IsGreaterEqualThan(m_shapeBounds.GetMin()) && outUVW.IsLessThan(m_shapeBounds.GetMax())); - outUVW = GetClampedPointInAabb(outUVW, m_shapeBounds); - break; - case WrappingType::Mirror: - outUVW = GetMirroredPointInAabb(outUVW, m_shapeBounds); - break; - case WrappingType::Repeat: - outUVW = GetWrappedPointInAabb(outUVW, m_shapeBounds); - break; - } - } - - outUVW *= m_configuration.m_frequencyZoom; - - if (shouldNormalizeOutput) - { - outUVW = GetNormalizedPointInAabb(outUVW, m_shapeBounds); - } - } - - void GradientTransformComponent::GetGradientLocalBounds(AZ::Aabb& bounds) const - { - bounds = m_shapeBounds; - } - - void GradientTransformComponent::GetGradientEncompassingBounds(AZ::Aabb& bounds) const - { - bounds = m_shapeBounds; - bounds.ApplyMatrix3x4(m_shapeTransformInverse.GetInverseFull()); + return m_gradientTransform; } void GradientTransformComponent::OnCompositionChanged() @@ -393,25 +342,16 @@ namespace GradientSignal { if (m_dirty) { - const auto configurationOld = m_configuration; - const auto shapeBoundsOld = m_shapeBounds; - const auto shapeTransformInverseOld = m_shapeTransformInverse; - - //updating on tick to query transform bus on main thread - UpdateFromShape(); + // Updating on tick to query transform bus on main thread. + // Also, if the GradientTransform configuration changes, notify listeners so they can refresh themselves. + const bool notifyDependentsOfChange = true; + UpdateFromShape(notifyDependentsOfChange); - //notify observers if content has changed - if (configurationOld != m_configuration || - shapeBoundsOld != m_shapeBounds || - shapeTransformInverseOld != m_shapeTransformInverse) - { - LmbrCentral::DependencyNotificationBus::Event(GetEntityId(), &LmbrCentral::DependencyNotificationBus::Events::OnCompositionChanged); - } m_dirty = false; } } - void GradientTransformComponent::UpdateFromShape() + void GradientTransformComponent::UpdateFromShape(bool notifyDependentsOfChange) { AZ_PROFILE_FUNCTION(Entity); @@ -423,6 +363,10 @@ namespace GradientSignal return; } + const GradientTransform oldGradientTransform = m_gradientTransform; + AZ::Aabb shapeBounds = AZ::Aabb::CreateNull(); + AZ::Matrix3x4 shapeTransformInverse = AZ::Matrix3x4::CreateIdentity(); + AZ::Transform shapeTransform = AZ::Transform::CreateIdentity(); switch (m_configuration.m_transformType) { @@ -466,10 +410,10 @@ namespace GradientSignal if (!m_configuration.m_advancedMode || !m_configuration.m_overrideBounds) { // If we have a shape reference, grab its local space bounds and (inverse) transform into that local space - GetObbParamsFromShape(shapeReference, m_shapeBounds, m_shapeTransformInverse); - if (m_shapeBounds.IsValid()) + GetObbParamsFromShape(shapeReference, shapeBounds, shapeTransformInverse); + if (shapeBounds.IsValid()) { - m_configuration.m_bounds = m_shapeBounds.GetExtents(); + m_configuration.m_bounds = shapeBounds.GetExtents(); } } @@ -491,14 +435,34 @@ namespace GradientSignal //rebuild bounds from parameters m_configuration.m_bounds = m_configuration.m_bounds.GetAbs(); - m_shapeBounds = AZ::Aabb::CreateFromMinMax(-m_configuration.m_bounds * 0.5f, m_configuration.m_bounds * 0.5f); + shapeBounds = AZ::Aabb::CreateFromMinMax(-m_configuration.m_bounds * 0.5f, m_configuration.m_bounds * 0.5f); //rebuild transform from parameters AZ::Matrix3x4 shapeTransformFinal; shapeTransformFinal.SetFromEulerDegrees(m_configuration.m_rotate); shapeTransformFinal.SetTranslation(m_configuration.m_translate); shapeTransformFinal.MultiplyByScale(m_configuration.m_scale); - m_shapeTransformInverse = shapeTransformFinal.GetInverseFull(); + shapeTransformInverse = shapeTransformFinal.GetInverseFull(); + + // Set everything up on the Gradient Transform + const bool use3dGradients = m_configuration.m_advancedMode && m_configuration.m_is3d; + m_gradientTransform = GradientTransform( + shapeBounds, shapeTransformFinal, use3dGradients, m_configuration.m_frequencyZoom, m_configuration.m_wrappingType); + + // If the transform has changed, send out notifications. + if (oldGradientTransform != m_gradientTransform) + { + // Always notify on the GradientTransformNotificationBus. + GradientTransformNotificationBus::Event( + GetEntityId(), &GradientTransformNotificationBus::Events::OnGradientTransformChanged, m_gradientTransform); + + // Only notify the DependencyNotificationBus when requested by the caller. + if (notifyDependentsOfChange) + { + LmbrCentral::DependencyNotificationBus::Event( + GetEntityId(), &LmbrCentral::DependencyNotificationBus::Events::OnCompositionChanged); + } + } } AZ::EntityId GradientTransformComponent::GetShapeEntityId() const diff --git a/Gems/GradientSignal/Code/Source/Components/ImageGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/ImageGradientComponent.cpp index 021e083ea6..d948f6269e 100644 --- a/Gems/GradientSignal/Code/Source/Components/ImageGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/ImageGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "ImageGradientComponent.h" +#include #include #include #include @@ -129,13 +129,16 @@ namespace GradientSignal void ImageGradientComponent::Activate() { + // This will immediately call OnGradientTransformChanged and initialize m_gradientTransform. + GradientTransformNotificationBus::Handler::BusConnect(GetEntityId()); + SetupDependencies(); ImageGradientRequestBus::Handler::BusConnect(GetEntityId()); GradientRequestBus::Handler::BusConnect(GetEntityId()); AZ::Data::AssetBus::Handler::BusConnect(m_configuration.m_imageAsset.GetId()); - AZStd::lock_guard imageLock(m_imageMutex); + AZStd::unique_lock imageLock(m_imageMutex); m_configuration.m_imageAsset.QueueLoad(); } @@ -144,10 +147,11 @@ namespace GradientSignal AZ::Data::AssetBus::Handler::BusDisconnect(); GradientRequestBus::Handler::BusDisconnect(); ImageGradientRequestBus::Handler::BusDisconnect(); + GradientTransformNotificationBus::Handler::BusDisconnect(); m_dependencyMonitor.Reset(); - AZStd::lock_guard imageLock(m_imageMutex); + AZStd::unique_lock imageLock(m_imageMutex); m_configuration.m_imageAsset.Release(); } @@ -173,40 +177,77 @@ namespace GradientSignal void ImageGradientComponent::OnAssetReady(AZ::Data::Asset asset) { - AZStd::lock_guard imageLock(m_imageMutex); + AZStd::unique_lock imageLock(m_imageMutex); m_configuration.m_imageAsset = asset; } void ImageGradientComponent::OnAssetMoved(AZ::Data::Asset asset, [[maybe_unused]] void* oldDataPointer) { - AZStd::lock_guard imageLock(m_imageMutex); + AZStd::unique_lock imageLock(m_imageMutex); m_configuration.m_imageAsset = asset; } void ImageGradientComponent::OnAssetReloaded(AZ::Data::Asset asset) { - AZStd::lock_guard imageLock(m_imageMutex); + AZStd::unique_lock imageLock(m_imageMutex); m_configuration.m_imageAsset = asset; } + void ImageGradientComponent::OnGradientTransformChanged(const GradientTransform& newTransform) + { + AZStd::unique_lock lock(m_imageMutex); + m_gradientTransform = newTransform; + } + float ImageGradientComponent::GetValue(const GradientSampleParams& sampleParams) const { AZ::Vector3 uvw = sampleParams.m_position; - bool wasPointRejected = false; - const bool shouldNormalizeOutput = true; - GradientTransformRequestBus::Event( - GetEntityId(), &GradientTransformRequestBus::Events::TransformPositionToUVW, sampleParams.m_position, uvw, shouldNormalizeOutput, wasPointRejected); - if (!wasPointRejected) { - AZStd::lock_guard imageLock(m_imageMutex); - return GetValueFromImageAsset(m_configuration.m_imageAsset, uvw, m_configuration.m_tilingX, m_configuration.m_tilingY, 0.0f); + AZStd::shared_lock imageLock(m_imageMutex); + + m_gradientTransform.TransformPositionToUVWNormalized(sampleParams.m_position, uvw, wasPointRejected); + + if (!wasPointRejected) + { + return GetValueFromImageAsset( + m_configuration.m_imageAsset, uvw, m_configuration.m_tilingX, m_configuration.m_tilingY, 0.0f); + } } return 0.0f; } + void ImageGradientComponent::GetValues(AZStd::span positions, AZStd::span outValues) const + { + if (positions.size() != outValues.size()) + { + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; + } + + AZ::Vector3 uvw; + bool wasPointRejected = false; + + AZStd::shared_lock imageLock(m_imageMutex); + + for (size_t index = 0; index < positions.size(); index++) + { + m_gradientTransform.TransformPositionToUVWNormalized(positions[index], uvw, wasPointRejected); + + if (!wasPointRejected) + { + outValues[index] = GetValueFromImageAsset( + m_configuration.m_imageAsset, uvw, m_configuration.m_tilingX, m_configuration.m_tilingY, 0.0f); + } + else + { + outValues[index] = 0.0f; + } + } + } + AZStd::string ImageGradientComponent::GetImageAssetPath() const { AZStd::string assetPathString; @@ -223,7 +264,7 @@ namespace GradientSignal AZ::Data::AssetBus::Handler::BusDisconnect(m_configuration.m_imageAsset.GetId()); { - AZStd::lock_guard imageLock(m_imageMutex); + AZStd::unique_lock imageLock(m_imageMutex); m_configuration.m_imageAsset = AZ::Data::AssetManager::Instance().FindOrCreateAsset(assetId, azrtti_typeid(), m_configuration.m_imageAsset.GetAutoLoadBehavior()); } diff --git a/Gems/GradientSignal/Code/Source/Components/InvertGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/InvertGradientComponent.cpp index 11ae5a67da..aef5cc7a52 100644 --- a/Gems/GradientSignal/Code/Source/Components/InvertGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/InvertGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "InvertGradientComponent.h" +#include #include #include #include @@ -137,6 +137,21 @@ namespace GradientSignal return output; } + void InvertGradientComponent::GetValues(AZStd::span positions, AZStd::span outValues) const + { + if (positions.size() != outValues.size()) + { + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; + } + + m_configuration.m_gradientSampler.GetValues(positions, outValues); + for (auto& outValue : outValues) + { + outValue = 1.0f - AZ::GetClamp(outValue, 0.0f, 1.0f); + } + } + bool InvertGradientComponent::IsEntityInHierarchy(const AZ::EntityId& entityId) const { return m_configuration.m_gradientSampler.IsEntityInHierarchy(entityId); diff --git a/Gems/GradientSignal/Code/Source/Components/LevelsGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/LevelsGradientComponent.cpp index af26ba494d..25f6a34614 100644 --- a/Gems/GradientSignal/Code/Source/Components/LevelsGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/LevelsGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "LevelsGradientComponent.h" +#include #include #include #include @@ -172,8 +172,6 @@ namespace GradientSignal float LevelsGradientComponent::GetValue(const GradientSampleParams& sampleParams) const { - AZ_PROFILE_FUNCTION(Entity); - float output = 0.0f; output = GetLevels( @@ -187,6 +185,21 @@ namespace GradientSignal return output; } + void LevelsGradientComponent::GetValues(AZStd::span positions, AZStd::span outValues) const + { + if (positions.size() != outValues.size()) + { + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; + } + + m_configuration.m_gradientSampler.GetValues(positions, outValues); + + GetLevels(outValues, + m_configuration.m_inputMid, m_configuration.m_inputMin, m_configuration.m_inputMax, + m_configuration.m_outputMin, m_configuration.m_outputMax); + } + bool LevelsGradientComponent::IsEntityInHierarchy(const AZ::EntityId& entityId) const { return m_configuration.m_gradientSampler.IsEntityInHierarchy(entityId); diff --git a/Gems/GradientSignal/Code/Source/Components/MixedGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/MixedGradientComponent.cpp index 5f6a18c7fb..e042188f8a 100644 --- a/Gems/GradientSignal/Code/Source/Components/MixedGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/MixedGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "MixedGradientComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Components/PerlinGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/PerlinGradientComponent.cpp index e150ff4305..e3dfaf2161 100644 --- a/Gems/GradientSignal/Code/Source/Components/PerlinGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/PerlinGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "PerlinGradientComponent.h" +#include #include #include #include @@ -138,6 +138,9 @@ namespace GradientSignal void PerlinGradientComponent::Activate() { + // This will immediately call OnGradientTransformChanged and initialize m_gradientTransform. + GradientTransformNotificationBus::Handler::BusConnect(GetEntityId()); + m_perlinImprovedNoise.reset(aznew PerlinImprovedNoise(AZ::GetMax(m_configuration.m_randomSeed, 1))); GradientRequestBus::Handler::BusConnect(GetEntityId()); PerlinGradientRequestBus::Handler::BusConnect(GetEntityId()); @@ -148,6 +151,7 @@ namespace GradientSignal m_perlinImprovedNoise.reset(); GradientRequestBus::Handler::BusDisconnect(); PerlinGradientRequestBus::Handler::BusDisconnect(); + GradientTransformNotificationBus::Handler::BusDisconnect(); } bool PerlinGradientComponent::ReadInConfig(const AZ::ComponentConfig* baseConfig) @@ -170,28 +174,65 @@ namespace GradientSignal return false; } - float PerlinGradientComponent::GetValue(const GradientSampleParams& sampleParams) const + void PerlinGradientComponent::OnGradientTransformChanged(const GradientTransform& newTransform) { - AZ_PROFILE_FUNCTION(Entity); + AZStd::unique_lock lock(m_transformMutex); + m_gradientTransform = newTransform; + } + float PerlinGradientComponent::GetValue(const GradientSampleParams& sampleParams) const + { if (m_perlinImprovedNoise) { AZ::Vector3 uvw = sampleParams.m_position; - bool wasPointRejected = false; - const bool shouldNormalizeOutput = false; - GradientTransformRequestBus::Event( - GetEntityId(), &GradientTransformRequestBus::Events::TransformPositionToUVW, sampleParams.m_position, uvw, shouldNormalizeOutput, wasPointRejected); + + { + AZStd::shared_lock lock(m_transformMutex); + m_gradientTransform.TransformPositionToUVW(sampleParams.m_position, uvw, wasPointRejected); + } if (!wasPointRejected) { - return m_perlinImprovedNoise->GenerateOctaveNoise(uvw.GetX(), uvw.GetY(), uvw.GetZ(), m_configuration.m_octave, m_configuration.m_amplitude, m_configuration.m_frequency); + return m_perlinImprovedNoise->GenerateOctaveNoise( + uvw.GetX(), uvw.GetY(), uvw.GetZ(), m_configuration.m_octave, m_configuration.m_amplitude, + m_configuration.m_frequency); } } return 0.0f; } + void PerlinGradientComponent::GetValues(AZStd::span positions, AZStd::span outValues) const + { + if (positions.size() != outValues.size()) + { + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; + } + + AZ::Vector3 uvw; + bool wasPointRejected = false; + + AZStd::shared_lock lock(m_transformMutex); + + for (size_t index = 0; index < positions.size(); index++) + { + m_gradientTransform.TransformPositionToUVW(positions[index], uvw, wasPointRejected); + + if (!wasPointRejected) + { + outValues[index] = m_perlinImprovedNoise->GenerateOctaveNoise( + uvw.GetX(), uvw.GetY(), uvw.GetZ(), m_configuration.m_octave, m_configuration.m_amplitude, + m_configuration.m_frequency); + } + else + { + outValues[index] = 0.0f; + } + } + } + int PerlinGradientComponent::GetRandomSeed() const { return m_configuration.m_randomSeed; diff --git a/Gems/GradientSignal/Code/Source/Components/PosterizeGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/PosterizeGradientComponent.cpp index 89beb15f32..21d321df13 100644 --- a/Gems/GradientSignal/Code/Source/Components/PosterizeGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/PosterizeGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "PosterizeGradientComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Components/RandomGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/RandomGradientComponent.cpp index d28fe13aff..0f4ece38a1 100644 --- a/Gems/GradientSignal/Code/Source/Components/RandomGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/RandomGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "RandomGradientComponent.h" +#include #include #include #include @@ -105,6 +105,9 @@ namespace GradientSignal void RandomGradientComponent::Activate() { + // This will immediately call OnGradientTransformChanged and initialize m_gradientTransform. + GradientTransformNotificationBus::Handler::BusConnect(GetEntityId()); + GradientRequestBus::Handler::BusConnect(GetEntityId()); RandomGradientRequestBus::Handler::BusConnect(GetEntityId()); } @@ -113,6 +116,7 @@ namespace GradientSignal { GradientRequestBus::Handler::BusDisconnect(); RandomGradientRequestBus::Handler::BusDisconnect(); + GradientTransformNotificationBus::Handler::BusDisconnect(); } bool RandomGradientComponent::ReadInConfig(const AZ::ComponentConfig* baseConfig) @@ -135,36 +139,81 @@ namespace GradientSignal return false; } + void RandomGradientComponent::OnGradientTransformChanged(const GradientTransform& newTransform) + { + AZStd::unique_lock lock(m_transformMutex); + m_gradientTransform = newTransform; + } + + float RandomGradientComponent::GetRandomValue(const AZ::Vector3& position, AZStd::size_t seed) const + { + // generating stable pseudo-random noise from a position based hash + float x = position.GetX(); + float y = position.GetY(); + AZStd::size_t result = 0; + + AZStd::hash_combine(result, x * seed + y); + AZStd::hash_combine(result, y * seed + x); + AZStd::hash_combine(result, x * y * seed); + + // always returns [0.0,1.0] + return static_cast(result % std::numeric_limits::max()) / static_cast(std::numeric_limits::max()); + } + + float RandomGradientComponent::GetValue(const GradientSampleParams& sampleParams) const { - AZ_PROFILE_FUNCTION(Entity); AZ::Vector3 uvw = sampleParams.m_position; - bool wasPointRejected = false; - const bool shouldNormalizeOutput = false; - GradientTransformRequestBus::Event( - GetEntityId(), &GradientTransformRequestBus::Events::TransformPositionToUVW, sampleParams.m_position, uvw, shouldNormalizeOutput, wasPointRejected); + + { + AZStd::shared_lock lock(m_transformMutex); + m_gradientTransform.TransformPositionToUVW(sampleParams.m_position, uvw, wasPointRejected); + } if (!wasPointRejected) { - //generating stable pseudo-random noise from a position based hash - float x = uvw.GetX(); - float y = uvw.GetY(); - AZStd::size_t result = 0; - const AZStd::size_t seed = m_configuration.m_randomSeed + AZStd::size_t(2); // Add 2 to avoid seeds 0 and 1, which can create strange patterns with this particular algorithm - - AZStd::hash_combine(result, x * seed + y); - AZStd::hash_combine(result, y * seed + x); - AZStd::hash_combine(result, x * y * seed); - - //always returns [0.0,1.0] - return static_cast(result % std::numeric_limits::max()) / static_cast(std::numeric_limits::max()); + const AZStd::size_t seed = m_configuration.m_randomSeed + + AZStd::size_t(2); // Add 2 to avoid seeds 0 and 1, which can create strange patterns with this particular algorithm + + return GetRandomValue(uvw, seed); } return 0.0f; } + void RandomGradientComponent::GetValues(AZStd::span positions, AZStd::span outValues) const + { + if (positions.size() != outValues.size()) + { + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; + } + + AZ::Vector3 uvw; + bool wasPointRejected = false; + const AZStd::size_t seed = m_configuration.m_randomSeed + + AZStd::size_t(2); // Add 2 to avoid seeds 0 and 1, which can create strange patterns with this particular algorithm + + AZStd::shared_lock lock(m_transformMutex); + + for (size_t index = 0; index < positions.size(); index++) + { + m_gradientTransform.TransformPositionToUVW(positions[index], uvw, wasPointRejected); + + if (!wasPointRejected) + { + outValues[index] = GetRandomValue(uvw, seed); + } + else + { + outValues[index] = 0.0f; + } + } + } + + int RandomGradientComponent::GetRandomSeed() const { return m_configuration.m_randomSeed; diff --git a/Gems/GradientSignal/Code/Source/Components/ReferenceGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/ReferenceGradientComponent.cpp index 28ffaad7d3..ea304a7eed 100644 --- a/Gems/GradientSignal/Code/Source/Components/ReferenceGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/ReferenceGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "ReferenceGradientComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Components/ShapeAreaFalloffGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/ShapeAreaFalloffGradientComponent.cpp index cdf542bf51..77b7f1a428 100644 --- a/Gems/GradientSignal/Code/Source/Components/ShapeAreaFalloffGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/ShapeAreaFalloffGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "ShapeAreaFalloffGradientComponent.h" +#include #include #include #include @@ -157,21 +157,55 @@ namespace GradientSignal float ShapeAreaFalloffGradientComponent::GetValue(const GradientSampleParams& sampleParams) const { - AZ_PROFILE_FUNCTION(Entity); - float distance = 0.0f; LmbrCentral::ShapeComponentRequestsBus::EventResult(distance, m_configuration.m_shapeEntityId, &LmbrCentral::ShapeComponentRequestsBus::Events::DistanceFromPoint, sampleParams.m_position); - // In the special case of 0 falloff, make sure that all points inside the shape (0 distance) return - // 1.0, and all points outside the shape return 0. - if (m_configuration.m_falloffWidth == 0.0f) + // Since this is outer falloff, distance should give us values from 1.0 at the minimum distance to 0.0 at the maximum distance. + // The statement is written specifically to handle the 0 falloff case as well. For 0 falloff, all points inside the shape + // (0 distance) return 1.0, and all points outside the shape return 0. This works because division by 0 gives infinity, which gets + // clamped by the GetMax() to 0. However, if distance == 0, it would give us NaN, so we have the separate conditional check to + // handle that case and clamp to 1.0. + return (distance <= 0.0f) ? 1.0f : AZ::GetMax(1.0f - (distance / m_configuration.m_falloffWidth), 0.0f); + } + + void ShapeAreaFalloffGradientComponent::GetValues(AZStd::span positions, AZStd::span outValues) const + { + if (positions.size() != outValues.size()) { - return (distance > 0.0f) ? 0.0f : 1.0f; + AZ_Assert(false, "input and output lists are different sizes (%zu vs %zu).", positions.size(), outValues.size()); + return; } - // Since this is outer falloff, distance should give us values from 1.0 at the minimum distance - // to 0.0 at the maximum distance. - return GetRatio(m_configuration.m_falloffWidth, 0.0f, distance); + bool shapeConnected = false; + const float falloffWidth = m_configuration.m_falloffWidth; + + LmbrCentral::ShapeComponentRequestsBus::Event( + m_configuration.m_shapeEntityId, + [falloffWidth, positions, &outValues, &shapeConnected](LmbrCentral::ShapeComponentRequestsBus::Events* shapeRequests) + { + shapeConnected = true; + + for (size_t index = 0; index < positions.size(); index++) + { + float distance = shapeRequests->DistanceFromPoint(positions[index]); + + // Since this is outer falloff, distance should give us values from 1.0 at the minimum distance to 0.0 at the maximum + // distance. The statement is written specifically to handle the 0 falloff case as well. For 0 falloff, all points + // inside the shape (0 distance) return 1.0, and all points outside the shape return 0. This works because division by 0 + // gives infinity, which gets clamped by the GetMax() to 0. However, if distance == 0, it would give us NaN, so we have + // the separate conditional check to handle that case and clamp to 1.0. + outValues[index] = (distance <= 0.0f) ? 1.0f : AZ::GetMax(1.0f - (distance / falloffWidth), 0.0f); + } + }); + + // If there's no shape, there's no falloff. + if (!shapeConnected) + { + for (auto& outValue : outValues) + { + outValue = 1.0f; + } + } } AZ::EntityId ShapeAreaFalloffGradientComponent::GetShapeEntityId() const diff --git a/Gems/GradientSignal/Code/Source/Components/SmoothStepGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/SmoothStepGradientComponent.cpp index 13b641426b..510ed41510 100644 --- a/Gems/GradientSignal/Code/Source/Components/SmoothStepGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/SmoothStepGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "SmoothStepGradientComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Components/SurfaceAltitudeGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/SurfaceAltitudeGradientComponent.cpp index 476e0971f4..8b36182750 100644 --- a/Gems/GradientSignal/Code/Source/Components/SurfaceAltitudeGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/SurfaceAltitudeGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "SurfaceAltitudeGradientComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Components/SurfaceMaskGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/SurfaceMaskGradientComponent.cpp index 7f46ad6e98..df7a3f5787 100644 --- a/Gems/GradientSignal/Code/Source/Components/SurfaceMaskGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/SurfaceMaskGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "SurfaceMaskGradientComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Components/SurfaceSlopeGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/SurfaceSlopeGradientComponent.cpp index 15b462f292..84e0b61a62 100644 --- a/Gems/GradientSignal/Code/Source/Components/SurfaceSlopeGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/SurfaceSlopeGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "SurfaceSlopeGradientComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Components/ThresholdGradientComponent.cpp b/Gems/GradientSignal/Code/Source/Components/ThresholdGradientComponent.cpp index 97acbb4441..a47ebdebe6 100644 --- a/Gems/GradientSignal/Code/Source/Components/ThresholdGradientComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Components/ThresholdGradientComponent.cpp @@ -6,7 +6,7 @@ * */ -#include "ThresholdGradientComponent.h" +#include #include #include #include diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorConstantGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorConstantGradientComponent.h index 02a5d8ec33..87228671b3 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorConstantGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorConstantGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorDitherGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorDitherGradientComponent.h index 39ce4973c5..b01968eed6 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorDitherGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorDitherGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorGradientSurfaceDataComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorGradientSurfaceDataComponent.h index 4c31283768..e79571e662 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorGradientSurfaceDataComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorGradientSurfaceDataComponent.h @@ -8,7 +8,7 @@ #pragma once -#include +#include #include #include diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorGradientTransformComponent.cpp b/Gems/GradientSignal/Code/Source/Editor/EditorGradientTransformComponent.cpp index 4517c30711..850faf19df 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorGradientTransformComponent.cpp +++ b/Gems/GradientSignal/Code/Source/Editor/EditorGradientTransformComponent.cpp @@ -55,9 +55,13 @@ namespace GradientSignal void EditorGradientTransformComponent::UpdateFromShape() { - // Update config from shape on game component, copy that back to our config - m_component.UpdateFromShape(); - m_component.WriteOutConfig(&m_configuration); - SetDirty(); + if (m_runtimeComponentActive) + { + // Update config from shape on game component, copy that back to our config. + bool notifyDependentsOfChange = true; + m_component.UpdateFromShape(notifyDependentsOfChange); + m_component.WriteOutConfig(&m_configuration); + SetDirty(); + } } } //namespace GradientSignal diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorGradientTransformComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorGradientTransformComponent.h index 8478d3e434..d2e2dc38eb 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorGradientTransformComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorGradientTransformComponent.h @@ -8,7 +8,7 @@ #pragma once -#include +#include #include namespace GradientSignal diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorImageGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorImageGradientComponent.h index d1682be46f..f84766e73b 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorImageGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorImageGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorInvertGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorInvertGradientComponent.h index ab9c13679c..652ddc3279 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorInvertGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorInvertGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorLevelsGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorLevelsGradientComponent.h index a2626d9a0a..b43f9bbb73 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorLevelsGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorLevelsGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorMixedGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorMixedGradientComponent.h index 837c64e6d8..c2ca707014 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorMixedGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorMixedGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorPerlinGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorPerlinGradientComponent.h index 4ef09ee3e4..1c39cf8faa 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorPerlinGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorPerlinGradientComponent.h @@ -10,7 +10,7 @@ #include #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorPosterizeGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorPosterizeGradientComponent.h index af85429b32..0078e2865f 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorPosterizeGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorPosterizeGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorRandomGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorRandomGradientComponent.h index 750e5bae4f..f5f9daee0a 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorRandomGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorRandomGradientComponent.h @@ -12,7 +12,7 @@ #include #include #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorReferenceGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorReferenceGradientComponent.h index 41eccf27e4..bf29b270bd 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorReferenceGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorReferenceGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorShapeAreaFalloffGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorShapeAreaFalloffGradientComponent.h index d8d7c052ce..7772dfe7c5 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorShapeAreaFalloffGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorShapeAreaFalloffGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorSmoothStepGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorSmoothStepGradientComponent.h index 864a419985..4a43920a6c 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorSmoothStepGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorSmoothStepGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceAltitudeGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceAltitudeGradientComponent.h index b334bb149d..f40176a9f5 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceAltitudeGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceAltitudeGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceMaskGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceMaskGradientComponent.h index 5df17a2699..9e71526541 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceMaskGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceMaskGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceSlopeGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceSlopeGradientComponent.h index ad1adb98f9..20daa662a9 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceSlopeGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorSurfaceSlopeGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/Editor/EditorThresholdGradientComponent.h b/Gems/GradientSignal/Code/Source/Editor/EditorThresholdGradientComponent.h index 0291e65fd8..cbeb626c5e 100644 --- a/Gems/GradientSignal/Code/Source/Editor/EditorThresholdGradientComponent.h +++ b/Gems/GradientSignal/Code/Source/Editor/EditorThresholdGradientComponent.h @@ -9,7 +9,7 @@ #pragma once #include -#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/GradientSignalModule.cpp b/Gems/GradientSignal/Code/Source/GradientSignalModule.cpp index 9986e62b34..eeaeae00dd 100644 --- a/Gems/GradientSignal/Code/Source/GradientSignalModule.cpp +++ b/Gems/GradientSignal/Code/Source/GradientSignalModule.cpp @@ -9,24 +9,24 @@ #include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include namespace GradientSignal { diff --git a/Gems/GradientSignal/Code/Source/GradientTransform.cpp b/Gems/GradientSignal/Code/Source/GradientTransform.cpp new file mode 100644 index 0000000000..ffaa8f7e6a --- /dev/null +++ b/Gems/GradientSignal/Code/Source/GradientTransform.cpp @@ -0,0 +1,167 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + + +#include +#include + + +namespace GradientSignal +{ + GradientTransform::GradientTransform( + const AZ::Aabb& shapeBounds, const AZ::Matrix3x4& transform, bool use3d, + float frequencyZoom, GradientSignal::WrappingType wrappingType) + : m_shapeBounds(shapeBounds) + , m_inverseTransform(transform.GetInverseFull()) + , m_frequencyZoom(frequencyZoom) + , m_wrappingType(wrappingType) + , m_alwaysAcceptPoint(true) + { + // If we want this to be a 2D gradient lookup, we always want to set the W result in the output to 0. + // The easiest / cheapest way to make this happen is just to clear out the third row in the inverseTransform. + if (!use3d) + { + m_inverseTransform.SetRow(2, AZ::Vector4::CreateZero()); + } + + // If we have invalid shape bounds, reset the wrapping type back to None. Wrapping won't work without valid bounds. + if (!m_shapeBounds.IsValid()) + { + m_wrappingType = WrappingType::None; + } + + // ClampToZero is the only wrapping type that allows us to return a "pointIsRejected" result for points that fall + // outside the shape bounds. + if (m_wrappingType == WrappingType::ClampToZero) + { + m_alwaysAcceptPoint = false; + } + + m_normalizeExtentsReciprocal = AZ::Vector3( + AZ::IsClose(0.0f, m_shapeBounds.GetXExtent()) ? 0.0f : (1.0f / m_shapeBounds.GetXExtent()), + AZ::IsClose(0.0f, m_shapeBounds.GetYExtent()) ? 0.0f : (1.0f / m_shapeBounds.GetYExtent()), + AZ::IsClose(0.0f, m_shapeBounds.GetZExtent()) ? 0.0f : (1.0f / m_shapeBounds.GetZExtent())); + } + + void GradientTransform::TransformPositionToUVW(const AZ::Vector3& inPosition, AZ::Vector3& outUVW, bool& wasPointRejected) const + { + // Transform coordinate into "local" relative space of shape bounds, and set W to 0 if this is a 2D gradient. + outUVW = m_inverseTransform * inPosition; + + // For most wrapping types, we always accept the point, but for ClampToZero we only accept it if it's within + // the shape bounds. We don't use m_shapeBounds.Contains() here because Contains() is inclusive on all edges. + // For uv consistency between clamped and unclamped states, we only want to accept uv ranges of [min, max), + // so we specifically need to exclude the max edges here. + bool wasPointAccepted = m_alwaysAcceptPoint || + (outUVW.IsGreaterEqualThan(m_shapeBounds.GetMin()) && outUVW.IsLessThan(m_shapeBounds.GetMax())); + wasPointRejected = !wasPointAccepted; + + switch (m_wrappingType) + { + default: + case WrappingType::None: + outUVW = GetUnboundedPointInAabb(outUVW, m_shapeBounds); + break; + case WrappingType::ClampToEdge: + outUVW = GetClampedPointInAabb(outUVW, m_shapeBounds); + break; + case WrappingType::ClampToZero: + outUVW = GetClampedPointInAabb(outUVW, m_shapeBounds); + break; + case WrappingType::Mirror: + outUVW = GetMirroredPointInAabb(outUVW, m_shapeBounds); + break; + case WrappingType::Repeat: + outUVW = GetWrappedPointInAabb(outUVW, m_shapeBounds); + break; + } + + outUVW *= m_frequencyZoom; + } + + void GradientTransform::TransformPositionToUVWNormalized(const AZ::Vector3& inPosition, AZ::Vector3& outUVW, bool& wasPointRejected) const + { + TransformPositionToUVW(inPosition, outUVW, wasPointRejected); + + // This effectively does AZ::LerpInverse(bounds.GetMin(), bounds.GetMax(), point) if shouldNormalize is true, + // and just returns outUVW if shouldNormalize is false. + outUVW = m_normalizeExtentsReciprocal * (outUVW - m_shapeBounds.GetMin()); + } + + AZ::Vector3 GradientTransform::NoTransform(const AZ::Vector3& point, const AZ::Aabb& /*bounds*/) + { + return point; + } + + AZ::Vector3 GradientTransform::GetUnboundedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& /*bounds*/) + { + return point; + } + + AZ::Vector3 GradientTransform::GetClampedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) + { + // We want the clamped sampling states to clamp uvs to the [min, max) range. + return point.GetClamp(bounds.GetMin(), bounds.GetMax() - AZ::Vector3(UvEpsilon)); + } + + AZ::Vector3 GradientTransform::GetWrappedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) + { + return AZ::Vector3( + AZ::Wrap(point.GetX(), bounds.GetMin().GetX(), bounds.GetMax().GetX()), + AZ::Wrap(point.GetY(), bounds.GetMin().GetY(), bounds.GetMax().GetY()), + AZ::Wrap(point.GetZ(), bounds.GetMin().GetZ(), bounds.GetMax().GetZ())); + } + + AZ::Vector3 GradientTransform::GetMirroredPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) + { + /* For mirroring, we want to produce the following pattern: + * [min, max) : value + * [max, min) : max - value - epsilon + * [min, max) : value + * [max, min) : max - value - epsilon + * ... + * The epsilon is because we always want to keep our output values in the [min, max) range. We apply the epsilon to all + * the mirrored values so that we get consistent spacing between the values. + */ + + auto GetMirror = [](float value, float min, float max) -> float + { + // To calculate the mirror value, we move our value into relative space of [0, rangeX2), then use + // the first half of the range for our "[min, max)" range, and the second half for our "[max, min)" mirrored range. + + float relativeValue = value - min; + float range = max - min; + float rangeX2 = range * 2.0f; + + // A positive relativeValue will produce a value of [0, rangeX2) from a single mod, but a negative relativeValue + // will produce a value of (-rangeX2, 0]. Adding rangeX2 to the result and taking the mod again puts us back in + // the range of [0, rangeX2) for both negative and positive values. This keeps our mirroring pattern consistent and + // unbroken across both negative and positive coordinate space. + relativeValue = AZ::Mod(AZ::Mod(relativeValue, rangeX2) + rangeX2, rangeX2); + + // [range, rangeX2) is our mirrored range, so flip the value when we're in this range and apply the epsilon so that + // we never return the max value, and so that our mirrored values have consistent spacing in the results. + if (relativeValue >= range) + { + relativeValue = rangeX2 - (relativeValue + UvEpsilon); + } + + return relativeValue + min; + }; + + return AZ::Vector3( + GetMirror(point.GetX(), bounds.GetMin().GetX(), bounds.GetMax().GetX()), + GetMirror(point.GetY(), bounds.GetMin().GetY(), bounds.GetMax().GetY()), + GetMirror(point.GetZ(), bounds.GetMin().GetZ(), bounds.GetMax().GetZ())); + } + + AZ::Vector3 GradientTransform::GetRelativePointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) + { + return point - bounds.GetMin(); + } +} diff --git a/Gems/GradientSignal/Code/Source/Util.cpp b/Gems/GradientSignal/Code/Source/Util.cpp deleted file mode 100644 index d9ebf36aec..0000000000 --- a/Gems/GradientSignal/Code/Source/Util.cpp +++ /dev/null @@ -1,77 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - - -#include -#include -#include -#include -#include - - -namespace GradientSignal -{ - // To keep things behaving consistently between clamped and unbounded uv ranges, we - // we want our clamped uvs to use a range of [min, max), so we'll actually clamp to - // [min, max - epsilon]. Since our floating-point numbers are likely in the - // -16384 to 16384 range, an epsilon of 0.001 will work without rounding to 0. - static const float uvEpsilon = 0.001f; - - AZ::Vector3 GetUnboundedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& /*bounds*/) - { - return point; - } - - AZ::Vector3 GetClampedPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) - { - // We want the clamped sampling states to clamp uvs to the [min, max) range. - return AZ::Vector3( - AZ::GetClamp(point.GetX(), bounds.GetMin().GetX(), bounds.GetMax().GetX() - uvEpsilon), - AZ::GetClamp(point.GetY(), bounds.GetMin().GetY(), bounds.GetMax().GetY() - uvEpsilon), - AZ::GetClamp(point.GetZ(), bounds.GetMin().GetZ(), bounds.GetMax().GetZ() - uvEpsilon)); - } - - float GetMirror(float value, float min, float max) - { - float relativeValue = value - min; - float range = max - min; - float rangeX2 = range * 2.0f; - if (relativeValue < 0.0) - { - relativeValue = rangeX2 - fmod(-relativeValue, rangeX2); - } - else - { - relativeValue = fmod(relativeValue, rangeX2); - } - if (relativeValue >= range) - { - // Since we want our uv range to stay in the [min, max) range, - // it means that for mirroring, we want both the "forward" values - // and the "mirrored" values to be in [0, range). We don't want - // relativeValue == range, so we shift relativeValue by a small epsilon - // in the mirrored case. - relativeValue = rangeX2 - (relativeValue + uvEpsilon); - } - - return relativeValue + min; - } - - AZ::Vector3 GetMirroredPointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) - { - return AZ::Vector3( - GetMirror(point.GetX(), bounds.GetMin().GetX(), bounds.GetMax().GetX()), - GetMirror(point.GetY(), bounds.GetMin().GetY(), bounds.GetMax().GetY()), - GetMirror(point.GetZ(), bounds.GetMin().GetZ(), bounds.GetMax().GetZ())); - } - - AZ::Vector3 GetRelativePointInAabb(const AZ::Vector3& point, const AZ::Aabb& bounds) - { - return point - bounds.GetMin(); - } -} diff --git a/Gems/GradientSignal/Code/Tests/EditorGradientSignalPreviewTests.cpp b/Gems/GradientSignal/Code/Tests/EditorGradientSignalPreviewTests.cpp index 7e98aa1361..83892f1c69 100644 --- a/Gems/GradientSignal/Code/Tests/EditorGradientSignalPreviewTests.cpp +++ b/Gems/GradientSignal/Code/Tests/EditorGradientSignalPreviewTests.cpp @@ -6,7 +6,7 @@ * */ -#include "Tests/GradientSignalTestMocks.h" +#include #include #include @@ -28,25 +28,36 @@ namespace UnitTest void SetUp() override { GradientSignalTest::SetUp(); - AZ::AllocatorInstance::Create(); - - // Set up job manager with two threads so that we can run and test the preview job logic. - AZ::JobManagerDesc desc; - AZ::JobManagerThreadDesc threadDesc; - desc.m_workerThreads.push_back(threadDesc); - desc.m_workerThreads.push_back(threadDesc); - m_jobManager = aznew AZ::JobManager(desc); - m_jobContext = aznew AZ::JobContext(*m_jobManager); - AZ::JobContext::SetGlobalContext(m_jobContext); + + auto globalContext = AZ::JobContext::GetGlobalContext(); + if (globalContext) + { + AZ_Assert( + globalContext->GetJobManager().GetNumWorkerThreads() >= 2, + "Job Manager previously started by test environment with too few threads for this test."); + } + else + { + // Set up job manager with two threads so that we can run and test the preview job logic. + AZ::JobManagerDesc desc; + AZ::JobManagerThreadDesc threadDesc; + desc.m_workerThreads.push_back(threadDesc); + desc.m_workerThreads.push_back(threadDesc); + m_jobManager = aznew AZ::JobManager(desc); + m_jobContext = aznew AZ::JobContext(*m_jobManager); + AZ::JobContext::SetGlobalContext(m_jobContext); + } } void TearDown() override { - AZ::JobContext::SetGlobalContext(nullptr); - delete m_jobContext; - delete m_jobManager; + if (m_jobContext) + { + AZ::JobContext::SetGlobalContext(nullptr); + delete m_jobContext; + delete m_jobManager; + } - AZ::AllocatorInstance::Destroy(); GradientSignalTest::TearDown(); } @@ -182,4 +193,5 @@ namespace UnitTest } } -AZ_UNIT_TEST_HOOK(DEFAULT_UNIT_TEST_ENV); +// This uses a custom test hook so that we can load LmbrCentral and use Shape components in our unit tests. +AZ_UNIT_TEST_HOOK(new UnitTest::GradientSignalTestEnvironment); diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalBenchmarks.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalBenchmarks.cpp new file mode 100644 index 0000000000..bd4ccf5205 --- /dev/null +++ b/Gems/GradientSignal/Code/Tests/GradientSignalBenchmarks.cpp @@ -0,0 +1,352 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#ifdef HAVE_BENCHMARK + +#include + +#include +#include +#include +#include +#include + +namespace UnitTest +{ + class GradientGetValues : public GradientSignalBenchmarkFixture + { + public: + // We use an enum to list out the different types of GetValue() benchmarks to run so that way we can condense our test cases + // to just take the value in as a benchmark argument and switch on it. Otherwise, we would need to write a different benchmark + // function for each test case for each gradient. + enum GetValuePermutation : int64_t + { + EBUS_GET_VALUE, + EBUS_GET_VALUES, + SAMPLER_GET_VALUE, + SAMPLER_GET_VALUES, + }; + + // Create an arbitrary size shape for creating our gradients for benchmark runs. + const float TestShapeHalfBounds = 128.0f; + + void FillQueryPositions(AZStd::vector& positions, float height, float width) + { + size_t index = 0; + for (float y = 0.0f; y < height; y += 1.0f) + { + for (float x = 0.0f; x < width; x += 1.0f) + { + positions[index++] = AZ::Vector3(x, y, 0.0f); + } + } + } + + void RunEBusGetValueBenchmark(benchmark::State& state, const AZ::EntityId& gradientId, int64_t queryRange) + { + AZ_PROFILE_FUNCTION(Entity); + + GradientSignal::GradientSampleParams params; + + // Get the height and width ranges for querying from our benchmark parameters + const float height = aznumeric_cast(queryRange); + const float width = aznumeric_cast(queryRange); + + // Call GetValue() on the EBus for every height and width in our ranges. + for (auto _ : state) + { + for (float y = 0.0f; y < height; y += 1.0f) + { + for (float x = 0.0f; x < width; x += 1.0f) + { + float value = 0.0f; + params.m_position = AZ::Vector3(x, y, 0.0f); + GradientSignal::GradientRequestBus::EventResult( + value, gradientId, &GradientSignal::GradientRequestBus::Events::GetValue, params); + benchmark::DoNotOptimize(value); + } + } + } + } + + void RunEBusGetValuesBenchmark(benchmark::State& state, const AZ::EntityId& gradientId, int64_t queryRange) + { + AZ_PROFILE_FUNCTION(Entity); + + // Get the height and width ranges for querying from our benchmark parameters + float height = aznumeric_cast(queryRange); + float width = aznumeric_cast(queryRange); + int64_t totalQueryPoints = queryRange * queryRange; + + // Call GetValues() for every height and width in our ranges. + for (auto _ : state) + { + // Set up our vector of query positions. This is done inside the benchmark timing since we're counting the work to create + // each query position in the single GetValue() call benchmarks, and will make the timing more directly comparable. + AZStd::vector positions(totalQueryPoints); + FillQueryPositions(positions, height, width); + + // Query and get the results. + AZStd::vector results(totalQueryPoints); + GradientSignal::GradientRequestBus::Event( + gradientId, &GradientSignal::GradientRequestBus::Events::GetValues, positions, results); + } + } + + void RunSamplerGetValueBenchmark(benchmark::State& state, const AZ::EntityId& gradientId, int64_t queryRange) + { + AZ_PROFILE_FUNCTION(Entity); + + // Create a gradient sampler to use for querying our gradient. + GradientSignal::GradientSampler gradientSampler; + gradientSampler.m_gradientId = gradientId; + + // Get the height and width ranges for querying from our benchmark parameters + const float height = aznumeric_cast(queryRange); + const float width = aznumeric_cast(queryRange); + + // Call GetValue() through the GradientSampler for every height and width in our ranges. + for (auto _ : state) + { + for (float y = 0.0f; y < height; y += 1.0f) + { + for (float x = 0.0f; x < width; x += 1.0f) + { + GradientSignal::GradientSampleParams params; + params.m_position = AZ::Vector3(x, y, 0.0f); + float value = gradientSampler.GetValue(params); + benchmark::DoNotOptimize(value); + } + } + } + } + + void RunSamplerGetValuesBenchmark(benchmark::State& state, const AZ::EntityId& gradientId, int64_t queryRange) + { + AZ_PROFILE_FUNCTION(Entity); + + // Create a gradient sampler to use for querying our gradient. + GradientSignal::GradientSampler gradientSampler; + gradientSampler.m_gradientId = gradientId; + + // Get the height and width ranges for querying from our benchmark parameters + const float height = aznumeric_cast(queryRange); + const float width = aznumeric_cast(queryRange); + const int64_t totalQueryPoints = queryRange * queryRange; + + // Call GetValues() through the GradientSampler for every height and width in our ranges. + for (auto _ : state) + { + // Set up our vector of query positions. This is done inside the benchmark timing since we're counting the work to create + // each query position in the single GetValue() call benchmarks, and will make the timing more directly comparable. + AZStd::vector positions(totalQueryPoints); + FillQueryPositions(positions, height, width); + + // Query and get the results. + AZStd::vector results(totalQueryPoints); + gradientSampler.GetValues(positions, results); + } + } + + void RunGetValueOrGetValuesBenchmark(benchmark::State& state, const AZ::EntityId& gradientId) + { + switch (state.range(0)) + { + case GetValuePermutation::EBUS_GET_VALUE: + RunEBusGetValueBenchmark(state, gradientId, state.range(1)); + break; + case GetValuePermutation::EBUS_GET_VALUES: + RunEBusGetValuesBenchmark(state, gradientId, state.range(1)); + break; + case GetValuePermutation::SAMPLER_GET_VALUE: + RunSamplerGetValueBenchmark(state, gradientId, state.range(1)); + break; + case GetValuePermutation::SAMPLER_GET_VALUES: + RunSamplerGetValuesBenchmark(state, gradientId, state.range(1)); + break; + default: + AZ_Assert(false, "Benchmark permutation type not supported."); + } + } + }; + +// Because there's no good way to label different enums in the output results (they just appear as integer values), we work around it by +// registering one set of benchmark runs for each enum value and use ArgNames() to give it a friendly name in the results. +#define GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(Fixture, Func) \ + BENCHMARK_REGISTER_F(Fixture, Func) \ + ->Args({ GradientGetValues::GetValuePermutation::EBUS_GET_VALUE, 1024 }) \ + ->Args({ GradientGetValues::GetValuePermutation::EBUS_GET_VALUE, 2048 }) \ + ->Args({ GradientGetValues::GetValuePermutation::EBUS_GET_VALUE, 4096 }) \ + ->ArgNames({ "EbusGetValue", "size" }) \ + ->Unit(::benchmark::kMillisecond); \ + BENCHMARK_REGISTER_F(Fixture, Func) \ + ->Args({ GradientGetValues::GetValuePermutation::EBUS_GET_VALUES, 1024 }) \ + ->Args({ GradientGetValues::GetValuePermutation::EBUS_GET_VALUES, 2048 }) \ + ->Args({ GradientGetValues::GetValuePermutation::EBUS_GET_VALUES, 4096 }) \ + ->ArgNames({ "EbusGetValues", "size" }) \ + ->Unit(::benchmark::kMillisecond); \ + BENCHMARK_REGISTER_F(Fixture, Func) \ + ->Args({ GradientGetValues::GetValuePermutation::SAMPLER_GET_VALUE, 1024 }) \ + ->Args({ GradientGetValues::GetValuePermutation::SAMPLER_GET_VALUE, 2048 }) \ + ->Args({ GradientGetValues::GetValuePermutation::SAMPLER_GET_VALUE, 4096 }) \ + ->ArgNames({ "SamplerGetValue", "size" }) \ + ->Unit(::benchmark::kMillisecond); \ + BENCHMARK_REGISTER_F(Fixture, Func) \ + ->Args({ GradientGetValues::GetValuePermutation::SAMPLER_GET_VALUES, 1024 }) \ + ->Args({ GradientGetValues::GetValuePermutation::SAMPLER_GET_VALUES, 2048 }) \ + ->Args({ GradientGetValues::GetValuePermutation::SAMPLER_GET_VALUES, 4096 }) \ + ->ArgNames({ "SamplerGetValues", "size" }) \ + ->Unit(::benchmark::kMillisecond); + + // -------------------------------------------------------------------------------------- + // Base Gradients + + BENCHMARK_DEFINE_F(GradientGetValues, BM_ConstantGradient)(benchmark::State& state) + { + auto entity = BuildTestConstantGradient(TestShapeHalfBounds); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_ImageGradient)(benchmark::State& state) + { + auto entity = BuildTestImageGradient(TestShapeHalfBounds); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + + BENCHMARK_DEFINE_F(GradientGetValues, BM_PerlinGradient)(benchmark::State& state) + { + auto entity = BuildTestPerlinGradient(TestShapeHalfBounds); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_RandomGradient)(benchmark::State& state) + { + auto entity = BuildTestRandomGradient(TestShapeHalfBounds); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_ShapeAreaFalloffGradient)(benchmark::State& state) + { + auto entity = BuildTestShapeAreaFalloffGradient(TestShapeHalfBounds); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_ConstantGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_ImageGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_PerlinGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_RandomGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_ShapeAreaFalloffGradient); + + // -------------------------------------------------------------------------------------- + // Gradient Modifiers + + BENCHMARK_DEFINE_F(GradientGetValues, BM_DitherGradient)(benchmark::State& state) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestDitherGradient(TestShapeHalfBounds, baseEntity->GetId()); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_InvertGradient)(benchmark::State& state) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestDitherGradient(TestShapeHalfBounds, baseEntity->GetId()); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_LevelsGradient)(benchmark::State& state) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestLevelsGradient(TestShapeHalfBounds, baseEntity->GetId()); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_MixedGradient)(benchmark::State& state) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto mixedEntity = BuildTestConstantGradient(TestShapeHalfBounds); + auto entity = BuildTestMixedGradient(TestShapeHalfBounds, baseEntity->GetId(), mixedEntity->GetId()); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_PosterizeGradient)(benchmark::State& state) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestPosterizeGradient(TestShapeHalfBounds, baseEntity->GetId()); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_ReferenceGradient)(benchmark::State& state) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestReferenceGradient(TestShapeHalfBounds, baseEntity->GetId()); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_SmoothStepGradient)(benchmark::State& state) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestSmoothStepGradient(TestShapeHalfBounds, baseEntity->GetId()); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_ThresholdGradient)(benchmark::State& state) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestThresholdGradient(TestShapeHalfBounds, baseEntity->GetId()); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_DitherGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_InvertGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_LevelsGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_MixedGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_PosterizeGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_ReferenceGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_SmoothStepGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_ThresholdGradient); + + // -------------------------------------------------------------------------------------- + // Surface Gradients + + BENCHMARK_DEFINE_F(GradientGetValues, BM_SurfaceAltitudeGradient)(benchmark::State& state) + { + auto mockSurfaceDataSystem = + CreateMockSurfaceDataSystem(AZ::Aabb::CreateFromMinMax(AZ::Vector3(-TestShapeHalfBounds), AZ::Vector3(TestShapeHalfBounds))); + + auto entity = BuildTestSurfaceAltitudeGradient(TestShapeHalfBounds); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_SurfaceMaskGradient)(benchmark::State& state) + { + auto mockSurfaceDataSystem = + CreateMockSurfaceDataSystem(AZ::Aabb::CreateFromMinMax(AZ::Vector3(-TestShapeHalfBounds), AZ::Vector3(TestShapeHalfBounds))); + + auto entity = BuildTestSurfaceMaskGradient(TestShapeHalfBounds); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + BENCHMARK_DEFINE_F(GradientGetValues, BM_SurfaceSlopeGradient)(benchmark::State& state) + { + auto mockSurfaceDataSystem = + CreateMockSurfaceDataSystem(AZ::Aabb::CreateFromMinMax(AZ::Vector3(-TestShapeHalfBounds), AZ::Vector3(TestShapeHalfBounds))); + + auto entity = BuildTestSurfaceSlopeGradient(TestShapeHalfBounds); + RunGetValueOrGetValuesBenchmark(state, entity->GetId()); + } + + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_SurfaceAltitudeGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_SurfaceMaskGradient); + GRADIENT_SIGNAL_GET_VALUES_BENCHMARK_REGISTER_F(GradientGetValues, BM_SurfaceSlopeGradient); + +#endif +} + + diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalGetValuesTests.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalGetValuesTests.cpp new file mode 100644 index 0000000000..6c4ebcc4c0 --- /dev/null +++ b/Gems/GradientSignal/Code/Tests/GradientSignalGetValuesTests.cpp @@ -0,0 +1,182 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + + +#include +#include + +namespace UnitTest +{ + struct GradientSignalGetValuesTestsFixture + : public GradientSignalTest + { + // Create an arbitrary size shape for comparing values within. It should be large enough that we detect any value anomalies + // but small enough that the tests run quickly. + const float TestShapeHalfBounds = 128.0f; + + void CompareGetValueAndGetValues(AZ::EntityId gradientEntityId) + { + // Create a gradient sampler and run through a series of points to see if they match expectations. + + const AZ::Aabb queryRegion = AZ::Aabb::CreateFromMinMax(AZ::Vector3(-TestShapeHalfBounds), AZ::Vector3(TestShapeHalfBounds)); + const AZ::Vector2 stepSize(1.0f, 1.0f); + + GradientSignal::GradientSampler gradientSampler; + gradientSampler.m_gradientId = gradientEntityId; + + const size_t numSamplesX = aznumeric_cast(ceil(queryRegion.GetExtents().GetX() / stepSize.GetX())); + const size_t numSamplesY = aznumeric_cast(ceil(queryRegion.GetExtents().GetY() / stepSize.GetY())); + + // Build up the list of positions to query. + AZStd::vector positions(numSamplesX * numSamplesY); + size_t index = 0; + for (size_t yIndex = 0; yIndex < numSamplesY; yIndex++) + { + float y = queryRegion.GetMin().GetY() + (stepSize.GetY() * yIndex); + for (size_t xIndex = 0; xIndex < numSamplesX; xIndex++) + { + float x = queryRegion.GetMin().GetX() + (stepSize.GetX() * xIndex); + positions[index++] = AZ::Vector3(x, y, 0.0f); + } + } + + // Get the results from GetValues + AZStd::vector results(numSamplesX * numSamplesY); + gradientSampler.GetValues(positions, results); + + // For each position, call GetValue and verify that the values match. + for (size_t positionIndex = 0; positionIndex < positions.size(); positionIndex++) + { + GradientSignal::GradientSampleParams params; + params.m_position = positions[positionIndex]; + float value = gradientSampler.GetValue(params); + + // We use ASSERT_NEAR instead of EXPECT_NEAR because if one value doesn't match, they probably all won't, so there's no + // reason to keep running and printing failures for every value. + ASSERT_NEAR(value, results[positionIndex], 0.000001f); + } + } + }; + + TEST_F(GradientSignalGetValuesTestsFixture, ImageGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto entity = BuildTestImageGradient(TestShapeHalfBounds); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, PerlinGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto entity = BuildTestPerlinGradient(TestShapeHalfBounds); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, RandomGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto entity = BuildTestRandomGradient(TestShapeHalfBounds); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, ConstantGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto entity = BuildTestConstantGradient(TestShapeHalfBounds); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, ShapeAreaFalloffGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto entity = BuildTestShapeAreaFalloffGradient(TestShapeHalfBounds); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, DitherGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + + auto entity = BuildTestDitherGradient(TestShapeHalfBounds, baseEntity->GetId()); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, InvertGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestInvertGradient(TestShapeHalfBounds, baseEntity->GetId()); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, LevelsGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestLevelsGradient(TestShapeHalfBounds, baseEntity->GetId()); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, MixedGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto mixedEntity = BuildTestConstantGradient(TestShapeHalfBounds); + auto entity = BuildTestMixedGradient(TestShapeHalfBounds, baseEntity->GetId(), mixedEntity->GetId()); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, PosterizeGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestPosterizeGradient(TestShapeHalfBounds, baseEntity->GetId()); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, ReferenceGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestReferenceGradient(TestShapeHalfBounds, baseEntity->GetId()); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, SmoothStepGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestSmoothStepGradient(TestShapeHalfBounds, baseEntity->GetId()); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, ThresholdGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto baseEntity = BuildTestRandomGradient(TestShapeHalfBounds); + auto entity = BuildTestThresholdGradient(TestShapeHalfBounds, baseEntity->GetId()); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, SurfaceAltitudeGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto mockSurfaceDataSystem = + CreateMockSurfaceDataSystem(AZ::Aabb::CreateFromMinMax(AZ::Vector3(-TestShapeHalfBounds), AZ::Vector3(TestShapeHalfBounds))); + + auto entity = BuildTestSurfaceAltitudeGradient(TestShapeHalfBounds); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, SurfaceMaskGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto mockSurfaceDataSystem = + CreateMockSurfaceDataSystem(AZ::Aabb::CreateFromMinMax(AZ::Vector3(-TestShapeHalfBounds), AZ::Vector3(TestShapeHalfBounds))); + + auto entity = BuildTestSurfaceMaskGradient(TestShapeHalfBounds); + CompareGetValueAndGetValues(entity->GetId()); + } + + TEST_F(GradientSignalGetValuesTestsFixture, SurfaceSlopeGradientComponent_VerifyGetValueAndGetValuesMatch) + { + auto mockSurfaceDataSystem = + CreateMockSurfaceDataSystem(AZ::Aabb::CreateFromMinMax(AZ::Vector3(-TestShapeHalfBounds), AZ::Vector3(TestShapeHalfBounds))); + + auto entity = BuildTestSurfaceSlopeGradient(TestShapeHalfBounds); + CompareGetValueAndGetValues(entity->GetId()); + } +} + + diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalImageTests.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalImageTests.cpp index 4c22afac76..8ec190000d 100644 --- a/Gems/GradientSignal/Code/Tests/GradientSignalImageTests.cpp +++ b/Gems/GradientSignal/Code/Tests/GradientSignalImageTests.cpp @@ -7,85 +7,25 @@ */ -#include "Tests/GradientSignalTestMocks.h" +#include #include #include #include #include #include +#include -#include -#include +#include +#include + +#include namespace UnitTest { struct GradientSignalImageTestsFixture : public GradientSignalTest { - struct MockAssetHandler - : public AZ::Data::AssetHandler - { - AZ::Data::AssetPtr CreateAsset([[maybe_unused]] const AZ::Data::AssetId& id, [[maybe_unused]] const AZ::Data::AssetType& type) override - { - return AZ::Data::AssetPtr(); - } - - void DestroyAsset(AZ::Data::AssetPtr ptr) override - { - if (ptr) - { - delete ptr; - } - } - - void GetHandledAssetTypes([[maybe_unused]] AZStd::vector& assetTypes) override - { - } - - AZ::Data::AssetHandler::LoadResult LoadAssetData( - [[maybe_unused]] const AZ::Data::Asset& asset, - [[maybe_unused]] AZStd::shared_ptr stream, - [[maybe_unused]] const AZ::Data::AssetFilterCB& assetLoadFilterCB) override - { - return AZ::Data::AssetHandler::LoadResult::LoadComplete; - } - - }; - - MockAssetHandler* m_mockHandler = nullptr; - GradientSignal::ImageAsset* m_imageData = nullptr; - - void SetUp() override - { - GradientSignalTest::SetUp(); - AZ::AllocatorInstance::Create(); - AZ::Data::AssetManager::Descriptor desc; - AZ::Data::AssetManager::Create(desc); - m_mockHandler = new MockAssetHandler(); - AZ::Data::AssetManager::Instance().RegisterHandler(m_mockHandler, azrtti_typeid()); - } - - void TearDown() override - { - AZ::Data::AssetManager::Instance().UnregisterHandler(m_mockHandler); - delete m_mockHandler; // delete after removing from the asset manager - AzFramework::LegacyAssetEventBus::ClearQueuedEvents(); - AZ::Data::AssetManager::Destroy(); - AZ::AllocatorInstance::Destroy(); - GradientSignalTest::TearDown(); - } - - struct AssignIdToAsset - : public AZ::Data::AssetData - { - void MakeReady() - { - m_assetId = AZ::Data::AssetId(AZ::Uuid::CreateRandom()); - m_status.store(AZ::Data::AssetData::AssetStatus::Ready); - } - }; - struct PixelTestSetup { // How to create the source image @@ -105,61 +45,6 @@ namespace UnitTest static const AZ::Vector2 EndOfList; }; - AZ::Data::Asset CreateImageAsset(AZ::u32 width, AZ::u32 height, AZ::s32 seed) - { - m_imageData = aznew GradientSignal::ImageAsset(); - m_imageData->m_imageWidth = width; - m_imageData->m_imageHeight = height; - m_imageData->m_bytesPerPixel = 1; - m_imageData->m_imageFormat = ImageProcessingAtom::EPixelFormat::ePixelFormat_R8; - - size_t value = 0; - AZStd::hash_combine(value, seed); - - for (AZ::u32 x = 0; x < width; ++x) - { - for (AZ::u32 y = 0; y < height; ++y) - { - AZStd::hash_combine(value, x); - AZStd::hash_combine(value, y); - m_imageData->m_imageData.push_back(static_cast(value)); - } - } - - reinterpret_cast(m_imageData)->MakeReady(); - return AZ::Data::Asset(m_imageData, AZ::Data::AssetLoadBehavior::Default); - } - - AZ::Data::Asset CreateSpecificPixelImageAsset(AZ::u32 width, AZ::u32 height, AZ::u32 pixelX, AZ::u32 pixelY) - { - m_imageData = aznew GradientSignal::ImageAsset(); - m_imageData->m_imageWidth = width; - m_imageData->m_imageHeight = height; - m_imageData->m_bytesPerPixel = 1; - m_imageData->m_imageFormat = ImageProcessingAtom::EPixelFormat::ePixelFormat_R8; - - const AZ::u8 pixelValue = 255; - - // Image data should be stored inverted on the y axis relative to our engine, so loop backwards through y. - for (int y = static_cast(height) - 1; y >= 0; --y) - { - for (AZ::u32 x = 0; x < width; ++x) - { - if ((x == static_cast(pixelX)) && (y == static_cast(pixelY))) - { - m_imageData->m_imageData.push_back(pixelValue); - } - else - { - m_imageData->m_imageData.push_back(0); - } - } - } - - reinterpret_cast(m_imageData)->MakeReady(); - return AZ::Data::Asset(m_imageData, AZ::Data::AssetLoadBehavior::Default); - } - void TestPixels(GradientSignal::GradientSampler& sampler, AZ::u32 width, AZ::u32 height, float stepSize, const AZStd::vector& expectedPoints) { AZStd::vector foundPoints; @@ -203,26 +88,25 @@ namespace UnitTest // Create the Image Gradient Component. GradientSignal::ImageGradientConfig config; - config.m_imageAsset = CreateSpecificPixelImageAsset(test.m_imageSize, test.m_imageSize, static_cast(test.m_pixel.GetX()), static_cast(test.m_pixel.GetY())); + config.m_imageAsset = ImageAssetMockAssetHandler::CreateSpecificPixelImageAsset( + test.m_imageSize, test.m_imageSize, static_cast(test.m_pixel.GetX()), static_cast(test.m_pixel.GetY())); config.m_tilingX = test.m_tiling; config.m_tilingY = test.m_tiling; - CreateComponent(entity.get(), config); + entity->CreateComponent(config); // Create the Gradient Transform Component. GradientSignal::GradientTransformConfig gradientTransformConfig; gradientTransformConfig.m_wrappingType = test.m_wrappingType; - CreateComponent(entity.get(), gradientTransformConfig); + entity->CreateComponent(gradientTransformConfig); - // Create a mock Shape component that describes the bounds that we're using to map our ImageGradient into world space. - CreateComponent(entity.get()); - MockShapeComponentHandler mockShapeHandler(entity->GetId()); - mockShapeHandler.m_GetLocalBounds = AZ::Aabb::CreateCenterRadius(AZ::Vector3(shapeHalfBounds), shapeHalfBounds); + LmbrCentral::BoxShapeConfig boxConfig(AZ::Vector3(shapeHalfBounds * 2.0f)); + auto boxComponent = entity->CreateComponent(LmbrCentral::AxisAlignedBoxShapeComponentTypeId); + boxComponent->SetConfiguration(boxConfig); - // Create a mock Transform component that locates our ImageGradient in the center of our desired mock Shape. - MockTransformHandler mockTransformHandler; - mockTransformHandler.m_GetLocalTMOutput = AZ::Transform::CreateTranslation(AZ::Vector3(shapeHalfBounds)); - mockTransformHandler.m_GetWorldTMOutput = AZ::Transform::CreateTranslation(AZ::Vector3(shapeHalfBounds)); - mockTransformHandler.BusConnect(entity->GetId()); + // Create a transform that locates our gradient in the center of our desired mock Shape. + auto transform = entity->CreateComponent(); + transform->SetLocalTM(AZ::Transform::CreateTranslation(AZ::Vector3(shapeHalfBounds))); + transform->SetWorldTM(AZ::Transform::CreateTranslation(AZ::Vector3(shapeHalfBounds))); // All components are created, so activate the entity ActivateEntity(entity.get()); @@ -482,7 +366,7 @@ namespace UnitTest mockShapeTransformHandler.BusConnect(mockShape->GetId()); // Create the mock shape that maps our 3x3 image to a 3x3 sample space in the world. - CreateComponent(mockShape.get()); + mockShape->CreateComponent(); MockShapeComponentHandler mockShapeComponentHandler(mockShape->GetId()); // Create a 2x2 box shape (shapes are inclusive, so that's 3x3 sampling space), so that each pixel in the image directly maps to 1 meter in the box. mockShapeComponentHandler.m_GetEncompassingAabb = AZ::Aabb::CreateFromMinMax(AZ::Vector3(0.0f), AZ::Vector3(2.0f)); @@ -495,8 +379,8 @@ namespace UnitTest // Create an ImageGradient with a 3x3 asset with the center pixel set. GradientSignal::ImageGradientConfig gradientConfig; - gradientConfig.m_imageAsset = CreateSpecificPixelImageAsset(3, 3, 1, 1); - CreateComponent(entity.get(), gradientConfig); + gradientConfig.m_imageAsset = ImageAssetMockAssetHandler::CreateSpecificPixelImageAsset(3, 3, 1, 1); + entity->CreateComponent(gradientConfig); // Create the test GradientTransform GradientSignal::GradientTransformConfig config; @@ -517,7 +401,7 @@ namespace UnitTest config.m_overrideRotate = false; config.m_overrideScale = false; config.m_is3d = false; - CreateComponent(entity.get(), config); + entity->CreateComponent(config); // Set up the transform on the gradient entity. MockTransformHandler mockTransformHandler; @@ -526,7 +410,7 @@ namespace UnitTest mockTransformHandler.BusConnect(entity->GetId()); // Put a default shape on our gradient entity. This is only used for previews, so it doesn't matter what it gets set to. - CreateComponent(entity.get()); + entity->CreateComponent(); MockShapeComponentHandler mockShapeHandler(entity->GetId()); ActivateEntity(entity.get()); @@ -534,7 +418,6 @@ namespace UnitTest TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); } } - } diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalReferencesTests.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalReferencesTests.cpp index 25a1aa28bb..72bdfa202e 100644 --- a/Gems/GradientSignal/Code/Tests/GradientSignalReferencesTests.cpp +++ b/Gems/GradientSignal/Code/Tests/GradientSignalReferencesTests.cpp @@ -10,18 +10,18 @@ #include #include #include -#include "Tests/GradientSignalTestMocks.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include namespace UnitTest { @@ -55,7 +55,7 @@ namespace UnitTest config.m_layers.push_back(layer); auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -88,7 +88,7 @@ namespace UnitTest config.m_smoothStep.m_falloffStrength = falloffStrength; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -371,12 +371,9 @@ namespace UnitTest const AZ::EntityId id = mockReference->GetId(); MockGradientArrayRequestsBus mockGradientRequestsBus(id, inputData, dataSize); - GradientSignal::ReferenceGradientConfig config; - config.m_gradientSampler.m_gradientId = mockReference->GetId(); - - auto entity = CreateEntity(); - CreateComponent(entity.get(), config); - ActivateEntity(entity.get()); + // Create a reference gradient with an arbitrary box shape on it. + const float HalfBounds = 64.0f; + auto entity = BuildTestReferenceGradient(HalfBounds, mockReference->GetId()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); } @@ -385,17 +382,16 @@ namespace UnitTest { // Verify that gradient references can validate and disconnect cyclic connections - auto constantGradientEntity = CreateEntity(); - GradientSignal::ConstantGradientConfig constantGradientConfig; - CreateComponent(constantGradientEntity.get(), constantGradientConfig); - ActivateEntity(constantGradientEntity.get()); + // Create a constant gradient with an arbitrary box shape on it. + const float HalfBounds = 64.0f; + auto constantGradientEntity = BuildTestConstantGradient(HalfBounds); // Verify cyclic reference test passes when pointing to gradient generator entity auto referenceGradientEntity1 = CreateEntity(); GradientSignal::ReferenceGradientConfig referenceGradientConfig1; referenceGradientConfig1.m_gradientSampler.m_ownerEntityId = referenceGradientEntity1->GetId(); referenceGradientConfig1.m_gradientSampler.m_gradientId = constantGradientEntity->GetId(); - CreateComponent(referenceGradientEntity1.get(), referenceGradientConfig1); + referenceGradientEntity1->CreateComponent(referenceGradientConfig1); ActivateEntity(referenceGradientEntity1.get()); EXPECT_TRUE(referenceGradientConfig1.m_gradientSampler.ValidateGradientEntityId()); @@ -404,7 +400,7 @@ namespace UnitTest GradientSignal::ReferenceGradientConfig referenceGradientConfig2; referenceGradientConfig2.m_gradientSampler.m_ownerEntityId = referenceGradientEntity2->GetId(); referenceGradientConfig2.m_gradientSampler.m_gradientId = referenceGradientEntity1->GetId(); - CreateComponent(referenceGradientEntity2.get(), referenceGradientConfig2); + referenceGradientEntity2->CreateComponent(referenceGradientConfig2); ActivateEntity(referenceGradientEntity2.get()); EXPECT_TRUE(referenceGradientConfig2.m_gradientSampler.ValidateGradientEntityId()); @@ -413,7 +409,7 @@ namespace UnitTest GradientSignal::ReferenceGradientConfig referenceGradientConfig3; referenceGradientConfig3.m_gradientSampler.m_ownerEntityId = referenceGradientEntity3->GetId(); referenceGradientConfig3.m_gradientSampler.m_gradientId = referenceGradientEntity3->GetId(); - CreateComponent(referenceGradientEntity3.get(), referenceGradientConfig3); + referenceGradientEntity3->CreateComponent(referenceGradientConfig3); ActivateEntity(referenceGradientEntity3.get()); EXPECT_FALSE(referenceGradientConfig3.m_gradientSampler.ValidateGradientEntityId()); EXPECT_EQ(referenceGradientConfig3.m_gradientSampler.m_gradientId, AZ::EntityId()); @@ -426,19 +422,19 @@ namespace UnitTest GradientSignal::ReferenceGradientConfig referenceGradientConfig4; referenceGradientConfig4.m_gradientSampler.m_ownerEntityId = referenceGradientEntity4->GetId(); referenceGradientConfig4.m_gradientSampler.m_gradientId = referenceGradientEntity5->GetId(); - CreateComponent(referenceGradientEntity4.get(), referenceGradientConfig4); + referenceGradientEntity4->CreateComponent(referenceGradientConfig4); ActivateEntity(referenceGradientEntity4.get()); GradientSignal::ReferenceGradientConfig referenceGradientConfig5; referenceGradientConfig5.m_gradientSampler.m_ownerEntityId = referenceGradientEntity5->GetId(); referenceGradientConfig5.m_gradientSampler.m_gradientId = referenceGradientEntity6->GetId(); - CreateComponent(referenceGradientEntity5.get(), referenceGradientConfig5); + referenceGradientEntity5->CreateComponent(referenceGradientConfig5); ActivateEntity(referenceGradientEntity5.get()); GradientSignal::ReferenceGradientConfig referenceGradientConfig6; referenceGradientConfig6.m_gradientSampler.m_ownerEntityId = referenceGradientEntity6->GetId(); referenceGradientConfig6.m_gradientSampler.m_gradientId = referenceGradientEntity4->GetId(); - CreateComponent(referenceGradientEntity6.get(), referenceGradientConfig6); + referenceGradientEntity6->CreateComponent(referenceGradientConfig6); ActivateEntity(referenceGradientEntity6.get()); EXPECT_FALSE(referenceGradientConfig6.m_gradientSampler.ValidateGradientEntityId()); @@ -460,7 +456,7 @@ namespace UnitTest // Create an AABB from -1 to 1, so points at coorindates 0 and 1 fall on it, but any points at coordinate 2 won't. auto entityShape = CreateEntity(); - CreateComponent(entityShape.get()); + entityShape->CreateComponent(); MockShapeComponentHandler mockShapeComponentHandler(entityShape->GetId()); mockShapeComponentHandler.m_GetEncompassingAabb = AZ::Aabb::CreateFromMinMax(AZ::Vector3(-1.0f), AZ::Vector3(1.0f)); @@ -470,7 +466,7 @@ namespace UnitTest config.m_falloffType = GradientSignal::FalloffType::Outer; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -485,7 +481,7 @@ namespace UnitTest // Create our test shape from -1 to 0, so we have a corner directly on (0, 0). auto entityShape = CreateEntity(); - CreateComponent(entityShape.get()); + entityShape->CreateComponent(); MockShapeComponentHandler mockShapeComponentHandler(entityShape->GetId()); mockShapeComponentHandler.m_GetEncompassingAabb = AZ::Aabb::CreateFromMinMax(AZ::Vector3(-1.0f), AZ::Vector3(0.0f)); @@ -516,7 +512,7 @@ namespace UnitTest } auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -537,7 +533,7 @@ namespace UnitTest // We're pinning a shape, so the bounding box of (0, 0, 0) - (10, 10, 10) will be the one that applies. auto entityShape = CreateEntity(); - CreateComponent(entityShape.get()); + entityShape->CreateComponent(); MockShapeComponentHandler mockShapeComponentHandler(entityShape->GetId()); mockShapeComponentHandler.m_GetEncompassingAabb = AZ::Aabb::CreateFromMinMax(AZ::Vector3::CreateZero(), AZ::Vector3(10.0f)); @@ -555,7 +551,7 @@ namespace UnitTest config.m_altitudeMax = 24.0f; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -588,7 +584,7 @@ namespace UnitTest config.m_altitudeMax = 10.0f; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -616,7 +612,7 @@ namespace UnitTest config.m_altitudeMax = 15.0f; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -653,7 +649,7 @@ namespace UnitTest config.m_altitudeMax = 15.0f; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -688,7 +684,7 @@ namespace UnitTest config.m_surfaceTagList.push_back(AZ_CRC("test_mask", 0x7a16e9ff)); auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -715,7 +711,7 @@ namespace UnitTest config.m_surfaceTagList.push_back(AZ_CRC("test_mask", 0x7a16e9ff)); auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalServicesTests.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalServicesTests.cpp index b8c0f85cf3..830c578b9b 100644 --- a/Gems/GradientSignal/Code/Tests/GradientSignalServicesTests.cpp +++ b/Gems/GradientSignal/Code/Tests/GradientSignalServicesTests.cpp @@ -6,13 +6,15 @@ * */ -#include "Tests/GradientSignalTestMocks.h" +#include #include -#include -#include -#include +#include + +#include +#include +#include namespace UnitTest { @@ -31,7 +33,7 @@ namespace UnitTest config.m_value = expectedOutput; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); GradientSignal::GradientSampler gradientSampler; @@ -75,12 +77,136 @@ namespace UnitTest config.m_gradientSampler.m_gradientId = entityMock->GetId(); auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); + ActivateEntity(entity.get()); + + TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); + } + + TEST_F(GradientSignalServicesTestsFixture, DitherGradientComponent_4x4At50Pct_CrossingZero) + { + // With a 4x4 gradient filled with 8/16 (0.5), verify that the resulting dithered output + // is an expected checkerboard pattern with 8 of 16 pixels filled. The pattern offset is + // shifted -2 in the X direction so that the lookups go from [-2, 2) to verify that the + // pattern remains consistent across negative and positive coordinates. + + constexpr int dataSize = 4; + + AZStd::vector inputData(dataSize * dataSize, 8.0f / 16.0f); + AZStd::vector expectedOutput = { + 1.0f, 0.0f, 1.0f, 0.0f, + 0.0f, 1.0f, 0.0f, 1.0f, + 1.0f, 0.0f, 1.0f, 0.0f, + 0.0f, 1.0f, 0.0f, 1.0f, + }; + + auto entityMock = CreateEntity(); + const AZ::EntityId id = entityMock->GetId(); + UnitTest::MockGradientArrayRequestsBus mockGradientRequestsBus(id, inputData, dataSize); + + GradientSignal::DitherGradientConfig config; + config.m_useSystemPointsPerUnit = false; + config.m_pointsPerUnit = 1.0f; + config.m_patternOffset = AZ::Vector3(-2.0f, 0.0f, 0.0f); + config.m_patternType = GradientSignal::DitherGradientConfig::BayerPatternType::PATTERN_SIZE_4x4; + config.m_gradientSampler.m_gradientId = entityMock->GetId(); + + auto entity = CreateEntity(); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); } + TEST_F(GradientSignalServicesTestsFixture, DitherGradientComponent_4x4At50Pct_MorePointsPerUnit) + { + // With a 4x4 gradient filled with 8/16 (0.5), and 1/2 point per unit, if we query a 4x4 region, + // we should get a checkerboard in 2x2 blocks of the same value because it takes 2 units before the value changes. + + constexpr int dataSize = 4; + + AZStd::vector inputData(dataSize * dataSize, 8.0f / 16.0f); + AZStd::vector expectedOutput = { + 1.0f, 1.0f, 0.0f, 0.0f, + 1.0f, 1.0f, 0.0f, 0.0f, + 0.0f, 0.0f, 1.0f, 1.0f, + 0.0f, 0.0f, 1.0f, 1.0f, + }; + + auto entityMock = CreateEntity(); + const AZ::EntityId id = entityMock->GetId(); + UnitTest::MockGradientArrayRequestsBus mockGradientRequestsBus(id, inputData, dataSize); + + GradientSignal::DitherGradientConfig config; + config.m_useSystemPointsPerUnit = false; + config.m_pointsPerUnit = 0.5f; + config.m_patternOffset = AZ::Vector3::CreateZero(); + config.m_patternType = GradientSignal::DitherGradientConfig::BayerPatternType::PATTERN_SIZE_4x4; + config.m_gradientSampler.m_gradientId = entityMock->GetId(); + + auto entity = CreateEntity(); + entity->CreateComponent(config); + ActivateEntity(entity.get()); + + TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); + } + + TEST_F(GradientSignalServicesTestsFixture, DitherGradientComponent_4x4At50Pct_MorePointsAndCrossingZero) + { + // With a 4x4 gradient filled with 8/16 (0.5), and 2 points per unit, verify that querying + // from -1 to 1 produces a constant checkerboard pattern of results as it crosses the 0 boundary. + // Our expected results are a consistent checkerboard pattern, but with 2x2 blocks of the same value because we're + // querying at 2x the point density (i.e. querying 4 points per unit) to ensure that fractional position lookups work too. + + float expectedValues[] = { + 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 0.0f, + 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 0.0f, + 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, + 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, + 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 0.0f, + 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 0.0f, + 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, + 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, + }; + + // Create a 50% constant gradient. + GradientSignal::ConstantGradientConfig constantConfig; + constantConfig.m_value = 8.0f / 16.0f; + auto constantGradientEntity = CreateEntity(); + constantGradientEntity->CreateComponent(constantConfig); + ActivateEntity(constantGradientEntity.get()); + + GradientSignal::DitherGradientConfig config; + config.m_useSystemPointsPerUnit = false; + config.m_pointsPerUnit = 2.0f; + config.m_patternOffset = AZ::Vector3::CreateZero(); + config.m_patternType = GradientSignal::DitherGradientConfig::BayerPatternType::PATTERN_SIZE_4x4; + config.m_gradientSampler.m_gradientId = constantGradientEntity->GetId(); + + auto entity = CreateEntity(); + entity->CreateComponent(config); + ActivateEntity(entity.get()); + + // Run through [-1, 1) at 1/4 intervals and make sure we get our expected checkerboard. This is testing both that + // we have a consistent pattern across the 0 boundary and that fractional position lookups work correctly + GradientSignal::GradientSampler gradientSampler; + gradientSampler.m_gradientId = entity->GetId(); + int expectedValueIndex = 0; + for (float y = -1.0f; y < 1.0f; y += 0.25f) + { + for (float x = -1.0f; x < 1.0f; x += 0.25f) + { + GradientSignal::GradientSampleParams params; + params.m_position = AZ::Vector3(x, y, 0.0f); + + float actualValue = gradientSampler.GetValue(params); + float expectedValue = expectedValues[expectedValueIndex++]; + + EXPECT_NEAR(actualValue, expectedValue, 0.01f); + } + } + } + TEST_F(GradientSignalServicesTestsFixture, DitherGradientComponent_4x4At31Pct) { // With a 4x4 gradient filled with 5/16 (0.3125), verify that the resulting dithered output @@ -109,7 +235,7 @@ namespace UnitTest config.m_gradientSampler.m_gradientId = entityMock->GetId(); auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -147,7 +273,7 @@ namespace UnitTest config.m_gradientSampler.m_gradientId = entityMock->GetId(); auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -185,7 +311,7 @@ namespace UnitTest config.m_gradientSampler.m_gradientId = entityMock->GetId(); auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -212,12 +338,9 @@ namespace UnitTest const AZ::EntityId id = entityMock->GetId(); UnitTest::MockGradientArrayRequestsBus mockGradientRequestsBus(id, inputData, dataSize); - GradientSignal::InvertGradientConfig config; - config.m_gradientSampler.m_gradientId = entityMock->GetId(); - - auto entity = CreateEntity(); - CreateComponent(entity.get(), config); - ActivateEntity(entity.get()); + // Create the entity with an arbitrarily-sized box. + const float HalfBounds = 64.0f; + auto entity = BuildTestInvertGradient(HalfBounds, entityMock->GetId()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); } diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalSurfaceTests.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalSurfaceTests.cpp index 809bbf2fe6..a716fc79b8 100644 --- a/Gems/GradientSignal/Code/Tests/GradientSignalSurfaceTests.cpp +++ b/Gems/GradientSignal/Code/Tests/GradientSignalSurfaceTests.cpp @@ -9,10 +9,10 @@ #include #include #include -#include "Tests/GradientSignalTestMocks.h" +#include -#include -#include +#include +#include namespace UnitTest { @@ -44,11 +44,9 @@ namespace UnitTest // This lets our component register with surfaceData successfully. MockSurfaceDataSystem mockSurfaceDataSystem; - // Create a mock shape entity in case we want to use it. + // Create a mock shape entity in case our gradient test uses shape constraints. // The mock shape is a cube that goes from -0.5 to 0.5 in space. - auto mockShapeEntity = CreateEntity(); - CreateComponent(mockShapeEntity.get()); - MockShapeComponentHandler mockShapeHandler(mockShapeEntity->GetId()); + auto mockShapeEntity = CreateTestEntity(0.5f); ActivateEntity(mockShapeEntity.get()); // For ease of testing, use a constant gradient as our input gradient. @@ -76,8 +74,8 @@ namespace UnitTest // Create the test entity with the GradientSurfaceData component and the required gradient dependency auto entity = CreateEntity(); - CreateComponent(entity.get(), constantGradientConfig); - CreateComponent(entity.get(), config); + entity->CreateComponent(constantGradientConfig); + entity->CreateComponent(config); ActivateEntity(entity.get()); // Get our registered modifier handle (and verify that it's valid) diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalTest.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalTest.cpp index 78aa4f1ac5..13e535e072 100644 --- a/Gems/GradientSignal/Code/Tests/GradientSignalTest.cpp +++ b/Gems/GradientSignal/Code/Tests/GradientSignalTest.cpp @@ -7,17 +7,17 @@ */ -#include "Tests/GradientSignalTestMocks.h" +#include #include #include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include namespace UnitTest { @@ -27,14 +27,12 @@ namespace UnitTest void TestLevelsGradientComponent(int dataSize, const AZStd::vector& inputData, const AZStd::vector& expectedOutput, float inputMin, float inputMid, float inputMax, float outputMin, float outputMax) { - auto entityMock = CreateEntity(); + auto entityMock = CreateTestEntity(1.0f); const AZ::EntityId id = entityMock->GetId(); UnitTest::MockGradientArrayRequestsBus mockGradientRequestsBus(id, inputData, dataSize); GradientSignal::GradientTransformConfig gradientTransformConfig; - CreateComponent(entityMock.get(), gradientTransformConfig); - CreateComponent(entityMock.get()); - MockShapeComponentHandler mockShapeHandler(entityMock->GetId()); + entityMock->CreateComponent(gradientTransformConfig); ActivateEntity(entityMock.get()); @@ -47,7 +45,7 @@ namespace UnitTest config.m_outputMax = outputMax; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -56,14 +54,12 @@ namespace UnitTest void TestPosterizeGradientComponent(int dataSize, const AZStd::vector& inputData, const AZStd::vector& expectedOutput, GradientSignal::PosterizeGradientConfig::ModeType posterizeMode, int bands) { - auto entityMock = CreateEntity(); + auto entityMock = CreateTestEntity(0.5f); const AZ::EntityId id = entityMock->GetId(); UnitTest::MockGradientArrayRequestsBus mockGradientRequestsBus(id, inputData, dataSize); GradientSignal::GradientTransformConfig gradientTransformConfig; - CreateComponent(entityMock.get(), gradientTransformConfig); - CreateComponent(entityMock.get()); - MockShapeComponentHandler mockShapeHandler(entityMock->GetId()); + entityMock->CreateComponent(gradientTransformConfig); ActivateEntity(entityMock.get()); @@ -73,7 +69,7 @@ namespace UnitTest config.m_bands = bands; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -82,14 +78,12 @@ namespace UnitTest void TestSmoothStepGradientComponent(int dataSize, const AZStd::vector& inputData, const AZStd::vector& expectedOutput, float midpoint, float range, float softness) { - auto entityMock = CreateEntity(); + auto entityMock = CreateTestEntity(0.5f); const AZ::EntityId id = entityMock->GetId(); UnitTest::MockGradientArrayRequestsBus mockGradientRequestsBus(id, inputData, dataSize); GradientSignal::GradientTransformConfig gradientTransformConfig; - CreateComponent(entityMock.get(), gradientTransformConfig); - CreateComponent(entityMock.get()); - MockShapeComponentHandler mockShapeHandler(entityMock->GetId()); + entityMock->CreateComponent(gradientTransformConfig); ActivateEntity(entityMock.get()); @@ -100,7 +94,7 @@ namespace UnitTest config.m_smoothStep.m_falloffStrength = softness; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -108,14 +102,12 @@ namespace UnitTest void TestThresholdGradientComponent(int dataSize, const AZStd::vector& inputData, const AZStd::vector& expectedOutput, float threshold) { - auto entityMock = CreateEntity(); + auto entityMock = CreateTestEntity(0.5f); const AZ::EntityId id = entityMock->GetId(); UnitTest::MockGradientArrayRequestsBus mockGradientRequestsBus(id, inputData, dataSize); GradientSignal::GradientTransformConfig gradientTransformConfig; - CreateComponent(entityMock.get(), gradientTransformConfig); - CreateComponent(entityMock.get()); - MockShapeComponentHandler mockShapeHandler(entityMock->GetId()); + entityMock->CreateComponent(gradientTransformConfig); ActivateEntity(entityMock.get()); @@ -124,7 +116,7 @@ namespace UnitTest config.m_threshold = threshold; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); ActivateEntity(entity.get()); TestFixedDataSampler(expectedOutput, dataSize, entity->GetId()); @@ -167,11 +159,11 @@ namespace UnitTest AZStd::vector expectedOutput = { AZ_TRAIT_UNIT_TEST_PERLINE_GRADIANT_GOLDEN_VALUES_7878 }; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); GradientSignal::GradientTransformConfig gradientTransformConfig; - CreateComponent(entity.get(), gradientTransformConfig); - CreateComponent(entity.get()); + entity->CreateComponent(gradientTransformConfig); + entity->CreateComponent(); MockShapeComponentHandler mockShapeHandler(entity->GetId()); ActivateEntity(entity.get()); @@ -197,11 +189,11 @@ namespace UnitTest config.m_randomSeed = 5656; auto entity = CreateEntity(); - CreateComponent(entity.get(), config); + entity->CreateComponent(config); GradientSignal::GradientTransformConfig gradientTransformConfig; - CreateComponent(entity.get(), gradientTransformConfig); - CreateComponent(entity.get()); + entity->CreateComponent(gradientTransformConfig); + entity->CreateComponent(); MockShapeComponentHandler mockShapeHandler(entity->GetId()); ActivateEntity(entity.get()); @@ -546,4 +538,5 @@ namespace UnitTest } } -AZ_UNIT_TEST_HOOK(DEFAULT_UNIT_TEST_ENV); +// This uses custom test / benchmark hooks so that we can load LmbrCentral and use Shape components in our unit tests and benchmarks. +AZ_UNIT_TEST_HOOK(new UnitTest::GradientSignalTestEnvironment, UnitTest::GradientSignalBenchmarkEnvironment); diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalTestFixtures.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalTestFixtures.cpp new file mode 100644 index 0000000000..d81370f6a8 --- /dev/null +++ b/Gems/GradientSignal/Code/Tests/GradientSignalTestFixtures.cpp @@ -0,0 +1,411 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + + +#include + +#include +#include +#include +#include + +// Base gradient components +#include +#include +#include +#include +#include + +// Gradient modifier components +#include +#include +#include +#include +#include +#include +#include +#include + +// Gradient surface data components +#include +#include +#include + +namespace UnitTest +{ + void GradientSignalTestEnvironment::AddGemsAndComponents() + { + AddDynamicModulePaths({ "LmbrCentral" }); + + AddComponentDescriptors({ + AzFramework::TransformComponent::CreateDescriptor(), + + GradientSignal::ConstantGradientComponent::CreateDescriptor(), + GradientSignal::DitherGradientComponent::CreateDescriptor(), + GradientSignal::GradientSurfaceDataComponent::CreateDescriptor(), + GradientSignal::GradientTransformComponent::CreateDescriptor(), + GradientSignal::ImageGradientComponent::CreateDescriptor(), + GradientSignal::InvertGradientComponent::CreateDescriptor(), + GradientSignal::LevelsGradientComponent::CreateDescriptor(), + GradientSignal::MixedGradientComponent::CreateDescriptor(), + GradientSignal::PerlinGradientComponent::CreateDescriptor(), + GradientSignal::PosterizeGradientComponent::CreateDescriptor(), + GradientSignal::RandomGradientComponent::CreateDescriptor(), + GradientSignal::ReferenceGradientComponent::CreateDescriptor(), + GradientSignal::ShapeAreaFalloffGradientComponent::CreateDescriptor(), + GradientSignal::SmoothStepGradientComponent::CreateDescriptor(), + GradientSignal::SurfaceAltitudeGradientComponent::CreateDescriptor(), + GradientSignal::SurfaceMaskGradientComponent::CreateDescriptor(), + GradientSignal::SurfaceSlopeGradientComponent::CreateDescriptor(), + GradientSignal::ThresholdGradientComponent::CreateDescriptor(), + + MockShapeComponent::CreateDescriptor(), + }); + } + + void GradientSignalBaseFixture::SetupCoreSystems() + { + m_mockHandler = new UnitTest::ImageAssetMockAssetHandler(); + AZ::Data::AssetManager::Instance().RegisterHandler(m_mockHandler, azrtti_typeid()); + } + + void GradientSignalBaseFixture::TearDownCoreSystems() + { + AZ::Data::AssetManager::Instance().UnregisterHandler(m_mockHandler); + delete m_mockHandler; // delete after removing from the asset manager + + AzFramework::LegacyAssetEventBus::ClearQueuedEvents(); + } + + AZStd::unique_ptr GradientSignalBaseFixture::CreateMockSurfaceDataSystem(const AZ::Aabb& spawnerBox) + { + SurfaceData::SurfacePoint point; + AZStd::unique_ptr mockSurfaceDataSystem = AZStd::make_unique(); + + // Give the mock surface data a bunch of fake point values to return. + for (float y = spawnerBox.GetMin().GetY(); y < spawnerBox.GetMax().GetY(); y+= 1.0f) + { + for (float x = spawnerBox.GetMin().GetX(); x < spawnerBox.GetMax().GetX(); x += 1.0f) + { + // Use our x distance into the spawnerBox as an arbitrary percentage value that we'll use to calculate + // our other arbitrary values below. + float arbitraryPercentage = AZStd::abs(x / spawnerBox.GetExtents().GetX()); + + // Create a position that's between min and max Z of the box. + point.m_position = AZ::Vector3(x, y, AZ::Lerp(spawnerBox.GetMin().GetZ(), spawnerBox.GetMax().GetZ(), arbitraryPercentage)); + // Create an arbitrary normal value. + point.m_normal = point.m_position.GetNormalized(); + // Create an arbitrary surface value. + point.m_masks[AZ_CRC_CE("test_mask")] = arbitraryPercentage; + + mockSurfaceDataSystem->m_GetSurfacePoints[AZStd::make_pair(x, y)] = { { point } }; + } + } + + return mockSurfaceDataSystem; + } + + AZStd::unique_ptr GradientSignalBaseFixture::CreateTestEntity(float shapeHalfBounds) + { + // Create the base entity + AZStd::unique_ptr testEntity = CreateEntity(); + + LmbrCentral::BoxShapeConfig boxConfig(AZ::Vector3(shapeHalfBounds * 2.0f)); + auto boxComponent = testEntity->CreateComponent(LmbrCentral::AxisAlignedBoxShapeComponentTypeId); + boxComponent->SetConfiguration(boxConfig); + + // Create a transform that locates our gradient in the center of our desired mock Shape. + auto transform = testEntity->CreateComponent(); + transform->SetLocalTM(AZ::Transform::CreateTranslation(AZ::Vector3(shapeHalfBounds))); + transform->SetWorldTM(AZ::Transform::CreateTranslation(AZ::Vector3(shapeHalfBounds))); + + return testEntity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestConstantGradient(float shapeHalfBounds) + { + // Create a Constant Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::ConstantGradientConfig config; + config.m_value = 0.75f; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestImageGradient(float shapeHalfBounds) + { + // Create an Image Gradient Component with arbitrary sizes and parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::ImageGradientConfig config; + const uint32_t imageSize = 4096; + const int32_t imageSeed = 12345; + config.m_imageAsset = ImageAssetMockAssetHandler::CreateImageAsset(imageSize, imageSize, imageSeed); + config.m_tilingX = 1.0f; + config.m_tilingY = 1.0f; + entity->CreateComponent(config); + + // Create a Gradient Transform Component with arbitrary parameters. + GradientSignal::GradientTransformConfig gradientTransformConfig; + gradientTransformConfig.m_wrappingType = GradientSignal::WrappingType::None; + entity->CreateComponent(gradientTransformConfig); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestPerlinGradient(float shapeHalfBounds) + { + // Create a Perlin Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::PerlinGradientConfig config; + config.m_amplitude = 1.0f; + config.m_frequency = 1.1f; + config.m_octave = 4; + config.m_randomSeed = 12345; + entity->CreateComponent(config); + + // Create a Gradient Transform Component with arbitrary parameters. + GradientSignal::GradientTransformConfig gradientTransformConfig; + gradientTransformConfig.m_wrappingType = GradientSignal::WrappingType::None; + entity->CreateComponent(gradientTransformConfig); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestRandomGradient(float shapeHalfBounds) + { + // Create a Random Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::RandomGradientConfig config; + config.m_randomSeed = 12345; + entity->CreateComponent(config); + + // Create a Gradient Transform Component with arbitrary parameters. + GradientSignal::GradientTransformConfig gradientTransformConfig; + gradientTransformConfig.m_wrappingType = GradientSignal::WrappingType::None; + entity->CreateComponent(gradientTransformConfig); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestShapeAreaFalloffGradient(float shapeHalfBounds) + { + // Create a Shape Area Falloff Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::ShapeAreaFalloffGradientConfig config; + config.m_shapeEntityId = entity->GetId(); + config.m_falloffWidth = 16.0f; + config.m_falloffType = GradientSignal::FalloffType::InnerOuter; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestDitherGradient( + float shapeHalfBounds, const AZ::EntityId& inputGradientId) + { + // Create a Dither Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::DitherGradientConfig config; + config.m_gradientSampler.m_gradientId = inputGradientId; + config.m_useSystemPointsPerUnit = false; + // Use a number other than 1.0f for pointsPerUnit to ensure the dither math is getting exercised properly. + config.m_pointsPerUnit = 0.25f; + config.m_patternOffset = AZ::Vector3::CreateZero(); + config.m_patternType = GradientSignal::DitherGradientConfig::BayerPatternType::PATTERN_SIZE_4x4; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestInvertGradient( + float shapeHalfBounds, const AZ::EntityId& inputGradientId) + { + // Create an Invert Gradient Component. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::InvertGradientConfig config; + config.m_gradientSampler.m_gradientId = inputGradientId; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestLevelsGradient( + float shapeHalfBounds, const AZ::EntityId& inputGradientId) + { + // Create a Levels Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::LevelsGradientConfig config; + config.m_gradientSampler.m_gradientId = inputGradientId; + config.m_inputMin = 0.1f; + config.m_inputMid = 0.3f; + config.m_inputMax = 0.9f; + config.m_outputMin = 0.0f; + config.m_outputMax = 1.0f; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestMixedGradient( + float shapeHalfBounds, const AZ::EntityId& baseGradientId, const AZ::EntityId& mixedGradientId) + { + // Create a Mixed Gradient Component that mixes two input gradients together in arbitrary ways. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::MixedGradientConfig config; + + GradientSignal::MixedGradientLayer layer; + layer.m_enabled = true; + + layer.m_operation = GradientSignal::MixedGradientLayer::MixingOperation::Initialize; + layer.m_gradientSampler.m_gradientId = baseGradientId; + layer.m_gradientSampler.m_opacity = 1.0f; + config.m_layers.push_back(layer); + + layer.m_operation = GradientSignal::MixedGradientLayer::MixingOperation::Overlay; + layer.m_gradientSampler.m_gradientId = mixedGradientId; + layer.m_gradientSampler.m_opacity = 0.75f; + config.m_layers.push_back(layer); + + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestPosterizeGradient( + float shapeHalfBounds, const AZ::EntityId& inputGradientId) + { + // Create a Posterize Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::PosterizeGradientConfig config; + config.m_gradientSampler.m_gradientId = inputGradientId; + config.m_mode = GradientSignal::PosterizeGradientConfig::ModeType::Ps; + config.m_bands = 5; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestReferenceGradient( + float shapeHalfBounds, const AZ::EntityId& inputGradientId) + { + // Create a Reference Gradient Component. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::ReferenceGradientConfig config; + config.m_gradientSampler.m_gradientId = inputGradientId; + config.m_gradientSampler.m_ownerEntityId = entity->GetId(); + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestSmoothStepGradient( + float shapeHalfBounds, const AZ::EntityId& inputGradientId) + { + // Create a Smooth Step Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::SmoothStepGradientConfig config; + config.m_gradientSampler.m_gradientId = inputGradientId; + config.m_smoothStep.m_falloffMidpoint = 0.75f; + config.m_smoothStep.m_falloffRange = 0.125f; + config.m_smoothStep.m_falloffStrength = 0.25f; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestThresholdGradient( + float shapeHalfBounds, const AZ::EntityId& inputGradientId) + { + // Create a Threshold Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::ThresholdGradientConfig config; + config.m_gradientSampler.m_gradientId = inputGradientId; + config.m_threshold = 0.75f; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestSurfaceAltitudeGradient(float shapeHalfBounds) + { + // Create a Surface Altitude Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::SurfaceAltitudeGradientConfig config; + config.m_altitudeMin = -5.0f; + config.m_altitudeMax = 15.0f; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestSurfaceMaskGradient(float shapeHalfBounds) + { + // Create a Surface Mask Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::SurfaceMaskGradientConfig config; + config.m_surfaceTagList.push_back(AZ_CRC_CE("test_mask")); + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + AZStd::unique_ptr GradientSignalBaseFixture::BuildTestSurfaceSlopeGradient(float shapeHalfBounds) + { + // Create a Surface Slope Gradient Component with arbitrary parameters. + auto entity = CreateTestEntity(shapeHalfBounds); + GradientSignal::SurfaceSlopeGradientConfig config; + config.m_slopeMin = 5.0f; + config.m_slopeMax = 50.0f; + config.m_rampType = GradientSignal::SurfaceSlopeGradientConfig::RampType::SMOOTH_STEP; + config.m_smoothStep.m_falloffMidpoint = 0.75f; + config.m_smoothStep.m_falloffRange = 0.125f; + config.m_smoothStep.m_falloffStrength = 0.25f; + entity->CreateComponent(config); + + ActivateEntity(entity.get()); + return entity; + } + + void GradientSignalTest::TestFixedDataSampler(const AZStd::vector& expectedOutput, int size, AZ::EntityId gradientEntityId) + { + GradientSignal::GradientSampler gradientSampler; + gradientSampler.m_gradientId = gradientEntityId; + + for (int y = 0; y < size; ++y) + { + for (int x = 0; x < size; ++x) + { + GradientSignal::GradientSampleParams params; + params.m_position = AZ::Vector3(static_cast(x), static_cast(y), 0.0f); + + const int index = y * size + x; + float actualValue = gradientSampler.GetValue(params); + float expectedValue = expectedOutput[index]; + + EXPECT_NEAR(actualValue, expectedValue, 0.01f); + } + } + } +} + diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalTestFixtures.h b/Gems/GradientSignal/Code/Tests/GradientSignalTestFixtures.h new file mode 100644 index 0000000000..5fda88ea27 --- /dev/null +++ b/Gems/GradientSignal/Code/Tests/GradientSignalTestFixtures.h @@ -0,0 +1,149 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ +#pragma once + +#include +#include +#include + +namespace UnitTest +{ + // The GradientSignal unit tests need to use the GemTestEnvironment to load the LmbrCentral Gem so that Shape components can be used + // in the unit tests and benchmarks. + class GradientSignalTestEnvironment + : public AZ::Test::GemTestEnvironment + { + public: + void AddGemsAndComponents() override; + }; + +#ifdef HAVE_BENCHMARK + //! The Benchmark environment is used for one time setup and tear down of shared resources + class GradientSignalBenchmarkEnvironment + : public AZ::Test::BenchmarkEnvironmentBase + , public GradientSignalTestEnvironment + + { + protected: + void SetUpBenchmark() override + { + SetupEnvironment(); + } + + void TearDownBenchmark() override + { + TeardownEnvironment(); + } + }; +#endif + + // Base test fixture used for GradientSignal unit tests and benchmark tests + class GradientSignalBaseFixture + { + public: + void SetupCoreSystems(); + void TearDownCoreSystems(); + + AZStd::unique_ptr CreateEntity() + { + return AZStd::make_unique(); + } + + void ActivateEntity(AZ::Entity* entity) + { + entity->Init(); + entity->Activate(); + } + + // Create a mock SurfaceDataSystem that will respond to requests for surface points with mock responses for points inside + // the given input box. + AZStd::unique_ptr CreateMockSurfaceDataSystem(const AZ::Aabb& spawnerBox); + + // Create an entity with a mock shape and a transform. It won't be activated yet though, because we expect a gradient component + // to also get added to it first before activation. + AZStd::unique_ptr CreateTestEntity(float shapeHalfBounds); + + // Create and activate an entity with a gradient component of the requested type, initialized with test data. + AZStd::unique_ptr BuildTestConstantGradient(float shapeHalfBounds); + AZStd::unique_ptr BuildTestImageGradient(float shapeHalfBounds); + AZStd::unique_ptr BuildTestPerlinGradient(float shapeHalfBounds); + AZStd::unique_ptr BuildTestRandomGradient(float shapeHalfBounds); + AZStd::unique_ptr BuildTestShapeAreaFalloffGradient(float shapeHalfBounds); + + AZStd::unique_ptr BuildTestDitherGradient(float shapeHalfBounds, const AZ::EntityId& inputGradientId); + AZStd::unique_ptr BuildTestInvertGradient(float shapeHalfBounds, const AZ::EntityId& inputGradientId); + AZStd::unique_ptr BuildTestLevelsGradient(float shapeHalfBounds, const AZ::EntityId& inputGradientId); + AZStd::unique_ptr BuildTestMixedGradient( + float shapeHalfBounds, const AZ::EntityId& baseGradientId, const AZ::EntityId& mixedGradientId); + AZStd::unique_ptr BuildTestPosterizeGradient(float shapeHalfBounds, const AZ::EntityId& inputGradientId); + AZStd::unique_ptr BuildTestReferenceGradient(float shapeHalfBounds, const AZ::EntityId& inputGradientId); + AZStd::unique_ptr BuildTestSmoothStepGradient(float shapeHalfBounds, const AZ::EntityId& inputGradientId); + AZStd::unique_ptr BuildTestThresholdGradient(float shapeHalfBounds, const AZ::EntityId& inputGradientId); + + AZStd::unique_ptr BuildTestSurfaceAltitudeGradient(float shapeHalfBounds); + AZStd::unique_ptr BuildTestSurfaceMaskGradient(float shapeHalfBounds); + AZStd::unique_ptr BuildTestSurfaceSlopeGradient(float shapeHalfBounds); + + UnitTest::ImageAssetMockAssetHandler* m_mockHandler = nullptr; + }; + + struct GradientSignalTest + : public GradientSignalBaseFixture + , public ::testing::Test + { + protected: + void SetUp() override + { + SetupCoreSystems(); + } + + void TearDown() override + { + TearDownCoreSystems(); + } + + void TestFixedDataSampler(const AZStd::vector& expectedOutput, int size, AZ::EntityId gradientEntityId); + }; + +#ifdef HAVE_BENCHMARK + class GradientSignalBenchmarkFixture + : public GradientSignalBaseFixture + , public ::benchmark::Fixture + { + public: + void internalSetUp() + { + SetupCoreSystems(); + } + + void internalTearDown() + { + TearDownCoreSystems(); + } + + protected: + void SetUp([[maybe_unused]] const benchmark::State& state) override + { + internalSetUp(); + } + void SetUp([[maybe_unused]] benchmark::State& state) override + { + internalSetUp(); + } + + void TearDown([[maybe_unused]] const benchmark::State& state) override + { + internalTearDown(); + } + void TearDown([[maybe_unused]] benchmark::State& state) override + { + internalTearDown(); + } + }; +#endif +} diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalTestMocks.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalTestMocks.cpp new file mode 100644 index 0000000000..7ac6ef1ecc --- /dev/null +++ b/Gems/GradientSignal/Code/Tests/GradientSignalTestMocks.cpp @@ -0,0 +1,74 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + + +#include + +namespace UnitTest +{ + AZ::Data::Asset ImageAssetMockAssetHandler::CreateImageAsset(AZ::u32 width, AZ::u32 height, AZ::s32 seed) + { + auto imageAsset = AZ::Data::AssetManager::Instance().CreateAsset( + AZ::Data::AssetId(AZ::Uuid::CreateRandom()), AZ::Data::AssetLoadBehavior::Default); + + imageAsset->m_imageWidth = width; + imageAsset->m_imageHeight = height; + imageAsset->m_bytesPerPixel = 1; + imageAsset->m_imageFormat = ImageProcessingAtom::EPixelFormat::ePixelFormat_R8; + imageAsset->m_imageData.reserve(width * height); + + size_t value = 0; + AZStd::hash_combine(value, seed); + + for (AZ::u32 x = 0; x < width; ++x) + { + for (AZ::u32 y = 0; y < height; ++y) + { + AZStd::hash_combine(value, x); + AZStd::hash_combine(value, y); + imageAsset->m_imageData.push_back(static_cast(value)); + } + } + + return imageAsset; + } + + AZ::Data::Asset ImageAssetMockAssetHandler::CreateSpecificPixelImageAsset( + AZ::u32 width, AZ::u32 height, AZ::u32 pixelX, AZ::u32 pixelY) + { + auto imageAsset = AZ::Data::AssetManager::Instance().CreateAsset( + AZ::Data::AssetId(AZ::Uuid::CreateRandom()), AZ::Data::AssetLoadBehavior::Default); + + imageAsset->m_imageWidth = width; + imageAsset->m_imageHeight = height; + imageAsset->m_bytesPerPixel = 1; + imageAsset->m_imageFormat = ImageProcessingAtom::EPixelFormat::ePixelFormat_R8; + imageAsset->m_imageData.reserve(width * height); + + const AZ::u8 pixelValue = 255; + + // Image data should be stored inverted on the y axis relative to our engine, so loop backwards through y. + for (int y = static_cast(height) - 1; y >= 0; --y) + { + for (AZ::u32 x = 0; x < width; ++x) + { + if ((x == static_cast(pixelX)) && (y == static_cast(pixelY))) + { + imageAsset->m_imageData.push_back(pixelValue); + } + else + { + imageAsset->m_imageData.push_back(0); + } + } + } + + return imageAsset; + } +} + diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalTestMocks.h b/Gems/GradientSignal/Code/Tests/GradientSignalTestMocks.h index 9c0d8be588..30f262d9b4 100644 --- a/Gems/GradientSignal/Code/Tests/GradientSignalTestMocks.h +++ b/Gems/GradientSignal/Code/Tests/GradientSignalTestMocks.h @@ -8,90 +8,69 @@ #pragma once #include -#include +#include +#include #include #include #include +#include +#include +#include #include #include #include +#include #include #include -#include - #include namespace UnitTest { - struct GradientSignalTest - : public ::testing::Test + // Mock asset handler for GradientSignal::ImageAsset that we can use in unit tests to pretend to load an image asset with. + // Also includes utility functions for creating image assets with specific testable patterns. + struct ImageAssetMockAssetHandler : public AZ::Data::AssetHandler { - protected: - AZ::ComponentApplication m_app; - AZ::Entity* m_systemEntity = nullptr; + //! Creates a deterministically random set of pixel data as an ImageAsset. + //! \param width The width of the ImageAsset + //! \param height The height of the ImageAsset + //! \param seed The random seed to use for generating the random data + //! \return The ImageAsset in a loaded ready state + static AZ::Data::Asset CreateImageAsset(AZ::u32 width, AZ::u32 height, AZ::s32 seed); - void SetUp() override - { - AZ::ComponentApplication::Descriptor appDesc; - appDesc.m_memoryBlocksByteSize = 128 * 1024 * 1024; - m_systemEntity = m_app.Create(appDesc); - m_app.AddEntity(m_systemEntity); - } + //! Creates an ImageAsset where all the pixels are 0 except for the one pixel at the given coordinates, which is set to 1. + //! \param width The width of the ImageAsset + //! \param height The height of the ImageAsset + //! \param pixelX The X coordinate of the pixel to set to 1 + //! \param pixelY The Y coordinate of the pixel to set to 1 + //! \return The ImageAsset in a loaded ready state + static AZ::Data::Asset CreateSpecificPixelImageAsset( + AZ::u32 width, AZ::u32 height, AZ::u32 pixelX, AZ::u32 pixelY); - void TearDown() override + AZ::Data::AssetPtr CreateAsset(const AZ::Data::AssetId& id, [[maybe_unused]] const AZ::Data::AssetType& type) override { - m_app.Destroy(); - m_systemEntity = nullptr; + // For our mock handler, always mark our assets as immediately ready. + return aznew GradientSignal::ImageAsset(id, AZ::Data::AssetData::AssetStatus::Ready); } - void TestFixedDataSampler(const AZStd::vector& expectedOutput, int size, AZ::EntityId gradientEntityId) + void DestroyAsset(AZ::Data::AssetPtr ptr) override { - GradientSignal::GradientSampler gradientSampler; - gradientSampler.m_gradientId = gradientEntityId; - - for(int y = 0; y < size; ++y) + if (ptr) { - for (int x = 0; x < size; ++x) - { - GradientSignal::GradientSampleParams params; - params.m_position = AZ::Vector3(static_cast(x), static_cast(y), 0.0f); - - const int index = y * size + x; - float actualValue = gradientSampler.GetValue(params); - float expectedValue = expectedOutput[index]; - - EXPECT_NEAR(actualValue, expectedValue, 0.01f); - } + delete ptr; } } - AZStd::unique_ptr CreateEntity() - { - return AZStd::make_unique(); - } - - void ActivateEntity(AZ::Entity* entity) - { - entity->Init(); - EXPECT_EQ(AZ::Entity::State::Init, entity->GetState()); - - entity->Activate(); - EXPECT_EQ(AZ::Entity::State::Active, entity->GetState()); - } - - template - AZ::Component* CreateComponent(AZ::Entity* entity, const Configuration& config) + void GetHandledAssetTypes([[maybe_unused]] AZStd::vector& assetTypes) override { - m_app.RegisterComponentDescriptor(Component::CreateDescriptor()); - return entity->CreateComponent(config); } - template - AZ::Component* CreateComponent(AZ::Entity* entity) + AZ::Data::AssetHandler::LoadResult LoadAssetData( + [[maybe_unused]] const AZ::Data::Asset& asset, + [[maybe_unused]] AZStd::shared_ptr stream, + [[maybe_unused]] const AZ::Data::AssetFilterCB& assetLoadFilterCB) override { - m_app.RegisterComponentDescriptor(Component::CreateDescriptor()); - return entity->CreateComponent(); + return AZ::Data::AssetHandler::LoadResult::LoadComplete; } }; diff --git a/Gems/GradientSignal/Code/Tests/GradientSignalTransformTests.cpp b/Gems/GradientSignal/Code/Tests/GradientSignalTransformTests.cpp new file mode 100644 index 0000000000..04e4611e71 --- /dev/null +++ b/Gems/GradientSignal/Code/Tests/GradientSignalTransformTests.cpp @@ -0,0 +1,284 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + + +#include + +#include +#include +#include +#include +#include + +#include + +namespace UnitTest +{ + struct GradientSignalTransformTestsFixture : public GradientSignalTest + { + // By default, we'll use a shape half extents of (5, 10, 20) for every test, and a world translation of (100, 200, 300). + struct GradientTransformSetupData + { + GradientSignal::WrappingType m_wrappingType{ GradientSignal::WrappingType::None }; + AZ::Vector3 m_shapeHalfExtents{ 5.0f, 10.0f, 20.0f }; + AZ::Vector3 m_worldTranslation{ 100.0f, 200.0f, 300.0f }; + float m_frequencyZoom{ 1.0f }; + }; + + struct GradientTransformTestData + { + AZ::Vector3 m_positionToTest; + AZ::Vector3 m_expectedOutputUVW; + bool m_expectedOutputRejectionResult; + }; + + static constexpr float UvEpsilon = GradientSignal::GradientTransform::UvEpsilon; + + void TestGradientTransform(const GradientTransformSetupData& setup, const GradientTransformTestData& test) + { + AZ::Aabb shapeBounds = AZ::Aabb::CreateCenterHalfExtents(AZ::Vector3::CreateZero(), setup.m_shapeHalfExtents); + AZ::Matrix3x4 transform = AZ::Matrix3x4::CreateTranslation(setup.m_worldTranslation); + float frequencyZoom = setup.m_frequencyZoom; + GradientSignal::WrappingType wrappingType = setup.m_wrappingType; + + AZ::Vector3 outUVW; + bool wasPointRejected; + + // Perform the query with a 3D gradient and verify that the results match expectations. + GradientSignal::GradientTransform gradientTransform3d(shapeBounds, transform, true, frequencyZoom, wrappingType); + gradientTransform3d.TransformPositionToUVW(test.m_positionToTest, outUVW, wasPointRejected); + EXPECT_THAT(outUVW, IsClose(test.m_expectedOutputUVW)); + EXPECT_EQ(wasPointRejected, test.m_expectedOutputRejectionResult); + + // Perform the query with a 2D gradient and verify that the results match, but always returns a W value of 0. + GradientSignal::GradientTransform gradientTransform2d(shapeBounds, transform, false, frequencyZoom, wrappingType); + gradientTransform2d.TransformPositionToUVW(test.m_positionToTest, outUVW, wasPointRejected); + EXPECT_THAT(outUVW, IsClose(AZ::Vector3(test.m_expectedOutputUVW.GetX(), test.m_expectedOutputUVW.GetY(), 0.0f))); + EXPECT_EQ(wasPointRejected, test.m_expectedOutputRejectionResult); + } + }; + + TEST_F(GradientSignalTransformTestsFixture, UnboundedWrappingReturnsTranslatedInput) + { + GradientTransformSetupData setup = { GradientSignal::WrappingType::None }; + GradientTransformTestData test = { + // Input position to query + { 0.0f, 0.0f, 0.0f }, + + // Output: For no wrapping, the output is just the input position offset by the world translation. + { -100.0f, -200.0f, -300.0f }, false + }; + + TestGradientTransform(setup, test); + } + + TEST_F(GradientSignalTransformTestsFixture, ClampToEdgeReturnsValuesClampedToShapeBounds) + { + GradientTransformSetupData setup = { GradientSignal::WrappingType::ClampToEdge }; + GradientTransformTestData tests[] = { + // Test: Input point far below minimum shape bounds + // Our input point is below the minimum of shape bounds, so the result should be the minimum corner of the shape. + { { 0.0f, 0.0f, 0.0f }, { -5.0f, -10.0f, -20.0f }, false }, + + // Test: Input point directly on minimum shape bounds + // Our input point is directly on the minimum of shape bounds, so the result should be the minimum corner of the shape. + { { 95.0f, 190.0f, 280.0f }, { -5.0f, -10.0f, -20.0f }, false }, + + // Test: Input point inside shape bounds + // Our input point is inside the shape bounds, so the result is just input - translation. + { { 101.0f, 202.0f, 303.0f }, { 1.0f, 2.0f, 3.0f }, false }, + + // Test: Input point directly on maximum shape bounds + // On the maximum side, GradientTransform clamps to "max - epsilon" for consistency with other wrapping types, so our + // expected results are the max shape corner - epsilon. + { { 105.0f, 210.0f, 320.0f }, { 5.0f - UvEpsilon, 10.0f - UvEpsilon, 20.0f - UvEpsilon }, false }, + + // Test: Input point far above maximum shape bounds + // On the maximum side, GradientTransform clamps to "max - epsilon" for consistency with other wrapping types, so our + // expected results are the max shape corner - epsilon. + { { 1000.0f, 1000.0f, 1000.0f }, { 5.0f - UvEpsilon, 10.0f - UvEpsilon, 20.0f - UvEpsilon }, false }, + }; + + for (auto& test : tests) + { + TestGradientTransform(setup, test); + } + } + + TEST_F(GradientSignalTransformTestsFixture, MirrorReturnsValuesMirroredBasedOnShapeBounds) + { + /* Here's how the results are expected to work for various inputs when using Mirror wrapping. + * This assumes shape half extents of (5, 10, 20), and a center translation of (100, 200, 300): + * Inputs: Outputs: + * ... ... + * (75, 150, 200) - (85, 170, 240) (-5, -10, -20) to (5, 10, 20) // forward mirror + * (85, 170, 240) - (95, 190, 280) (5, 10, 20) to (-5, -10, -20) // back mirror + * (95, 190, 280) - (105, 210, 320) (-5, -10, -20) to (5, 10, 20) // starting point + * (105, 210, 320) - (115, 230, 360) (5, 10, 20) to (-5, -10, -20) // back mirror + * (115, 230, 360) - (125, 250, 400) (-5, -10, -20) to (5, 10, 20) // forward mirror + * ... ... + * When below the starting point, both forward and back mirrors will be adjusted by UvEpsilon except for points that fall on the + * shape minimums. + * When above the starting point, only back mirrors will be adjusted by UvEpsilon. + */ + + GradientTransformSetupData setup = { GradientSignal::WrappingType::Mirror }; + GradientTransformTestData tests[] = { + // Test: Input exactly 2x below minimum bounds + // When landing exactly on the 2x boundary, we return the minumum shape bounds. There is no adjustment by epsilon + // on the minimum side of the bounds, even when we're in a mirror below the shape bounds. + { { 75.0f, 150.0f, 200.0f }, { -5.0f, -10.0f, -20.0f }, false }, + + // Test: Input within 2nd mirror repeat below minimum bounds + // The second mirror repeat should go forward in values, but will be adjusted by UvEpsilon since we're below the + // minimum bounds. + { { 84.0f, 168.0f, 237.0f }, { 4.0f - UvEpsilon, 8.0f - UvEpsilon, 17.0f - UvEpsilon }, false }, + + // Test: Input exactly 1x below minimum bounds. + // When landing exactly on the 1x boundary, we return the maximum shape bounds minus epsilon. + { { 85.0f, 170.0f, 240.0f }, { 5.0f - UvEpsilon, 10.0f - UvEpsilon, 20.0f - UvEpsilon }, false }, + + // Test: Input within 1st mirror repeat below minimum bounds + // The first mirror repeat should go backwards in values, but will be adjusted by UvEpsilon since we're below the + // minimum bounds. + { { 94.0f, 188.0f, 277.0f }, { -4.0f - UvEpsilon, -8.0f - UvEpsilon, -17.0f - UvEpsilon }, false }, + + // Test: Input inside shape bounds + // The translated input position is (1, 2, 3) is inside the shape bounds, so we should just get the translated + // position back as output. + { { 101.0f, 202.0f, 303.0f }, { 1.0f, 2.0f, 3.0f }, false }, + + // Test: Input within 1st mirror repeat above maximum bounds + // The first mirror repeat should go backwards in values. We're above the maximum bounds, so the expected result + // is (4, 8, 17) minus an epsilon. + { { 106.0f, 212.0f, 323.0f }, { 4.0f - UvEpsilon, 8.0f - UvEpsilon, 17.0f - UvEpsilon }, false }, + + // Test: Input exactly 2x above minimum bounds. + // When landing exactly on the 2x boundary, we return the exact minimum value again. + { { 115.0f, 230.0f, 360.0f }, { -5.0f, -10.0f, -20.0f }, false }, + + // Test: Input within 2nd mirror repeat above maximum bounds + // The second mirror repeat should go forwards in values. We're above the maximum bounds, so the expected result + // is (-4, -8, -17) with no epsilon. + { { 116.0f, 232.0f, 363.0f }, { -4.0f, -8.0f, -17.0f }, false }, + + // Test: Input exactly 2x above maximum bounds + // When landing exactly on the 2x boundary, we return the maximum adjusted by the epsilon again. + { { 125.0f, 250.0f, 400.0f }, { 5.0f - UvEpsilon, 10.0f - UvEpsilon, 20.0f - UvEpsilon }, false } + }; + + for (auto& test : tests) + { + TestGradientTransform(setup, test); + } + } + + TEST_F(GradientSignalTransformTestsFixture, RepeatReturnsRepeatingValuesBasedOnShapeBounds) + { + /* Here's how the results are expected to work for various inputs when using Repeat wrapping. + * This assumes shape half extents of (5, 10, 20), and a center translation of (100, 200, 300): + * Inputs: Outputs: + * ... ... + * (75, 150, 200) - (85, 170, 240) (-5, -10, -20) to (5, 10, 20) + * (85, 170, 240) - (95, 190, 280) (-5, -10, -20) to (5, 10, 20) + * (95, 190, 280) - (105, 210, 320) (-5, -10, -20) to (5, 10, 20) // starting point + * (105, 210, 320) - (115, 230, 360) (-5, -10, -20) to (5, 10, 20) + * (115, 230, 360) - (125, 250, 400) (-5, -10, -20) to (5, 10, 20) + * ... ... + * Every shape min/max boundary point below the starting point will have the max shape value. + * Every shape min/max boundary point above the starting point with have the min shape value. + */ + + + GradientTransformSetupData setup = { GradientSignal::WrappingType::Repeat }; + GradientTransformTestData tests[] = { + // Test: 2x below minimum shape bounds + // We're on a shape boundary below the minimum bounds, so it should return the maximum. + { { 75.0f, 150.0f, 200.0f }, { 5.0f, 10.0f, 20.0f }, false }, + + // Test: Input within 2nd repeat below minimum shape bounds + // Every repeat should go forwards in values. + { { 76.0f, 152.0f, 203.0f }, { -4.0f, -8.0f, -17.0f }, false }, + + // Test: 1x below minimum shape bounds + // We're on a shape boundary below the minimum bounds, so it should return the maximum. + { { 85.0f, 170.0f, 240.0f }, { 5.0f, 10.0f, 20.0f }, false }, + + // Test: Input within 1st repeat below minimum shape bounds + // Every repeat should go forwards in values. + { { 86.0f, 172.0f, 243.0f }, { -4.0f, -8.0f, -17.0f }, false }, + + // Test: Input exactly on minimum shape bounds + // This should return the actual minimum bounds. + { { 95.0f, 190.0f, 280.0f }, { -5.0f, -10.0f, -20.0f }, false }, + + // Test: Input inside shape bounds + // This should return the mapped value. + { { 101.0f, 202.0f, 303.0f }, { 1.0f, 2.0f, 3.0f }, false }, + + // Test: Input exactly on maximum shape bounds + // We're on a shape boundary above the minimum bounds, so it should return the minimum. + { { 105.0f, 210.0f, 320.0f }, { -5.0f, -10.0f, -20.0f }, false }, + + // Test: Input within 1st repeat above maximum shape bounds + // Every repeat should go forwards in values. + { { 106.0f, 212.0f, 323.0f }, { -4.0f, -8.0f, -17.0f }, false }, + + // Test: 1x above maximum shape bounds + // We're on a shape boundary above the minimum bounds, so it should return the minimum. + { { 105.0f, 210.0f, 320.0f }, { -5.0f, -10.0f, -20.0f }, false }, + + // Test: Input within 2nd repeat above maximum shape bounds + // Every repeat should go forwards in values. + { { 106.0f, 212.0f, 323.0f }, { -4.0f, -8.0f, -17.0f }, false }, + }; + + for (auto& test : tests) + { + TestGradientTransform(setup, test); + } + } + + TEST_F(GradientSignalTransformTestsFixture, ClampToZeroReturnsClampedValuesBasedOnShapeBounds) + { + GradientTransformSetupData setup = { GradientSignal::WrappingType::ClampToZero }; + GradientTransformTestData tests[] = { + // Test: Input point far below minimum shape bounds + // Our input point is below the minimum of shape bounds, so the result should be the minimum corner of the shape. + // Points outside the shape bounds should return "true" for rejected. + { { 0.0f, 0.0f, 0.0f }, { -5.0f, -10.0f, -20.0f }, true }, + + // Test: Input point directly on minimum shape bounds + // Our input point is directly on the minimum of shape bounds, so the result should be the minimum corner of the shape. + { { 95.0f, 190.0f, 280.0f }, { -5.0f, -10.0f, -20.0f }, false }, + + // Test: Input point inside shape bounds + // Our input point is inside the shape bounds, so the result is just input - translation. + { { 101.0f, 202.0f, 303.0f }, { 1.0f, 2.0f, 3.0f }, false }, + + // Test: Input point directly on maximum shape bounds + // On the maximum side, GradientTransform clamps to "max - epsilon" for consistency with other wrapping types, so our + // expected results are the max shape corner - epsilon. + // Points outside the shape bounds (which includes the maximum edge of the shape bounds) should return "true" for rejected. + { { 105.0f, 210.0f, 320.0f }, { 5.0f - UvEpsilon, 10.0f - UvEpsilon, 20.0f - UvEpsilon }, true }, + + // Test: Input point far above maximum shape bounds + // On the maximum side, GradientTransform clamps to "max - epsilon" for consistency with other wrapping types, so our + // expected results are the max shape corner - epsilon. + // Points outside the shape bounds should return "true" for rejected. + { { 1000.0f, 1000.0f, 1000.0f }, { 5.0f - UvEpsilon, 10.0f - UvEpsilon, 20.0f - UvEpsilon }, true }, + }; + + for (auto& test : tests) + { + TestGradientTransform(setup, test); + } + } +} + + diff --git a/Gems/GradientSignal/Code/Tests/ImageAssetTests.cpp b/Gems/GradientSignal/Code/Tests/ImageAssetTests.cpp index 0111f10c3a..7b1c260d45 100644 --- a/Gems/GradientSignal/Code/Tests/ImageAssetTests.cpp +++ b/Gems/GradientSignal/Code/Tests/ImageAssetTests.cpp @@ -11,6 +11,7 @@ #include #include #include +#include #include @@ -64,26 +65,8 @@ namespace } } - class ImageAssetTest - : public ::testing::Test + class ImageAssetTest : public ::testing::Test { - protected: - AZ::ComponentApplication m_app; - AZ::Entity* m_systemEntity = nullptr; - - void SetUp() override - { - AZ::ComponentApplication::Descriptor appDesc; - appDesc.m_memoryBlocksByteSize = 128 * 1024 * 1024; - m_systemEntity = m_app.Create(appDesc); - m_app.AddEntity(m_systemEntity); - } - - void TearDown() override - { - m_app.Destroy(); - m_systemEntity = nullptr; - } }; #if AZ_TRAIT_DISABLE_FAILED_GRADIENT_SIGNAL_TESTS diff --git a/Gems/GradientSignal/Code/gradientsignal_files.cmake b/Gems/GradientSignal/Code/gradientsignal_files.cmake index 5b28150eb4..8555c2c0b4 100644 --- a/Gems/GradientSignal/Code/gradientsignal_files.cmake +++ b/Gems/GradientSignal/Code/gradientsignal_files.cmake @@ -8,12 +8,31 @@ set(FILES Include/GradientSignal/GradientSampler.h + Include/GradientSignal/GradientTransform.h Include/GradientSignal/SmoothStep.h Include/GradientSignal/ImageAsset.h Include/GradientSignal/ImageSettings.h Include/GradientSignal/PerlinImprovedNoise.h Include/GradientSignal/Util.h Include/GradientSignal/GradientImageConversion.h + Include/GradientSignal/Components/ConstantGradientComponent.h + Include/GradientSignal/Components/DitherGradientComponent.h + Include/GradientSignal/Components/GradientSurfaceDataComponent.h + Include/GradientSignal/Components/GradientTransformComponent.h + Include/GradientSignal/Components/ImageGradientComponent.h + Include/GradientSignal/Components/InvertGradientComponent.h + Include/GradientSignal/Components/LevelsGradientComponent.h + Include/GradientSignal/Components/MixedGradientComponent.h + Include/GradientSignal/Components/PerlinGradientComponent.h + Include/GradientSignal/Components/PosterizeGradientComponent.h + Include/GradientSignal/Components/RandomGradientComponent.h + Include/GradientSignal/Components/ReferenceGradientComponent.h + Include/GradientSignal/Components/ShapeAreaFalloffGradientComponent.h + Include/GradientSignal/Components/SmoothStepGradientComponent.h + Include/GradientSignal/Components/SurfaceAltitudeGradientComponent.h + Include/GradientSignal/Components/SurfaceMaskGradientComponent.h + Include/GradientSignal/Components/SurfaceSlopeGradientComponent.h + Include/GradientSignal/Components/ThresholdGradientComponent.h Include/GradientSignal/Ebuses/GradientTransformRequestBus.h Include/GradientSignal/Ebuses/GradientRequestBus.h Include/GradientSignal/Ebuses/GradientPreviewRequestBus.h @@ -39,48 +58,30 @@ set(FILES Include/GradientSignal/Ebuses/GradientSurfaceDataRequestBus.h Include/GradientSignal/Ebuses/SmoothStepRequestBus.h Source/Components/ConstantGradientComponent.cpp - Source/Components/ConstantGradientComponent.h Source/Components/DitherGradientComponent.cpp - Source/Components/DitherGradientComponent.h Source/Components/GradientSurfaceDataComponent.cpp - Source/Components/GradientSurfaceDataComponent.h Source/Components/GradientTransformComponent.cpp - Source/Components/GradientTransformComponent.h Source/Components/ImageGradientComponent.cpp - Source/Components/ImageGradientComponent.h Source/Components/InvertGradientComponent.cpp - Source/Components/InvertGradientComponent.h Source/Components/LevelsGradientComponent.cpp - Source/Components/LevelsGradientComponent.h Source/Components/MixedGradientComponent.cpp - Source/Components/MixedGradientComponent.h Source/Components/PerlinGradientComponent.cpp - Source/Components/PerlinGradientComponent.h Source/Components/PosterizeGradientComponent.cpp - Source/Components/PosterizeGradientComponent.h Source/Components/RandomGradientComponent.cpp - Source/Components/RandomGradientComponent.h Source/Components/ReferenceGradientComponent.cpp - Source/Components/ReferenceGradientComponent.h Source/Components/ShapeAreaFalloffGradientComponent.cpp - Source/Components/ShapeAreaFalloffGradientComponent.h Source/Components/SmoothStepGradientComponent.cpp - Source/Components/SmoothStepGradientComponent.h Source/Components/SurfaceAltitudeGradientComponent.cpp - Source/Components/SurfaceAltitudeGradientComponent.h Source/Components/SurfaceMaskGradientComponent.cpp - Source/Components/SurfaceMaskGradientComponent.h Source/Components/SurfaceSlopeGradientComponent.cpp - Source/Components/SurfaceSlopeGradientComponent.h Source/Components/ThresholdGradientComponent.cpp - Source/Components/ThresholdGradientComponent.h Source/GradientSampler.cpp Source/GradientSignalSystemComponent.cpp Source/GradientSignalSystemComponent.h + Source/GradientTransform.cpp Source/SmoothStep.cpp Source/ImageAsset.cpp Source/ImageSettings.cpp Source/PerlinImprovedNoise.cpp - Source/Util.cpp Source/GradientImageConversion.cpp ) diff --git a/Gems/GradientSignal/Code/gradientsignal_shared_tests_files.cmake b/Gems/GradientSignal/Code/gradientsignal_shared_tests_files.cmake new file mode 100644 index 0000000000..7d867b0a33 --- /dev/null +++ b/Gems/GradientSignal/Code/gradientsignal_shared_tests_files.cmake @@ -0,0 +1,14 @@ +# +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# +# + +set(FILES + Tests/GradientSignalTestFixtures.cpp + Tests/GradientSignalTestFixtures.h + Tests/GradientSignalTestMocks.cpp + Tests/GradientSignalTestMocks.h +) diff --git a/Gems/GradientSignal/Code/gradientsignal_tests_files.cmake b/Gems/GradientSignal/Code/gradientsignal_tests_files.cmake index 8c8a4c25e1..814347c395 100644 --- a/Gems/GradientSignal/Code/gradientsignal_tests_files.cmake +++ b/Gems/GradientSignal/Code/gradientsignal_tests_files.cmake @@ -7,11 +7,13 @@ # set(FILES + Tests/GradientSignalBenchmarks.cpp + Tests/GradientSignalGetValuesTests.cpp Tests/GradientSignalImageTests.cpp Tests/GradientSignalReferencesTests.cpp Tests/GradientSignalServicesTests.cpp Tests/GradientSignalSurfaceTests.cpp - Tests/GradientSignalTestMocks.h + Tests/GradientSignalTransformTests.cpp Tests/GradientSignalTest.cpp Tests/ImageAssetTests.cpp ) diff --git a/Gems/GradientSignal/gem.json b/Gems/GradientSignal/gem.json index aac4c652c5..f0136ef104 100644 --- a/Gems/GradientSignal/gem.json +++ b/Gems/GradientSignal/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Gradient Signal Gem provides a number of components for generating, modifying, and mixing gradient signals.", "canonical_tags": [ diff --git a/Gems/GraphCanvas/Code/Source/GraphCanvas.cpp b/Gems/GraphCanvas/Code/Source/GraphCanvas.cpp index ebc15023cc..de7966e53c 100644 --- a/Gems/GraphCanvas/Code/Source/GraphCanvas.cpp +++ b/Gems/GraphCanvas/Code/Source/GraphCanvas.cpp @@ -227,7 +227,6 @@ namespace GraphCanvas AzFramework::AssetCatalogEventBus::Handler::BusDisconnect(); Styling::PseudoElementFactoryRequestBus::Handler::BusDisconnect(); GraphCanvasRequestBus::Handler::BusDisconnect(); - AZ::Data::AssetBus::MultiHandler::BusDisconnect(); m_translationAssetWorker.Deactivate(); UnregisterAssetHandler(); @@ -369,26 +368,28 @@ namespace GraphCanvas void GraphCanvasSystemComponent::OnCatalogLoaded(const char* /*catalogFile*/) { - auto postEnumerateCb = [this]() - { - PopulateTranslationDatabase(); - }; + GraphCanvas::TranslationRequestBus::Broadcast(&GraphCanvas::TranslationRequests::Restore); + } - // Find any TranslationAsset files that may have translation database key/values - AZ::Data::AssetCatalogRequests::AssetEnumerationCB collectAssetsCb = [this](const AZ::Data::AssetId assetId, const AZ::Data::AssetInfo& assetInfo) + void GraphCanvasSystemComponent::OnCatalogAssetRemoved(const AZ::Data::AssetId& /*assetId*/, const AZ::Data::AssetInfo& assetInfo) + { + if (assetInfo.m_assetType == azrtti_typeid()) { - if (AZ::StringFunc::EndsWith(assetInfo.m_relativePath, ".names", false)) - { - m_translationAssets.push_back(assetId); - } - }; - - m_translationAssets.clear(); + GraphCanvas::TranslationRequestBus::Broadcast(&GraphCanvas::TranslationRequests::Restore); + } + } - AZ::Data::AssetCatalogRequestBus::Broadcast(&AZ::Data::AssetCatalogRequestBus::Events::EnumerateAssets, nullptr, collectAssetsCb, postEnumerateCb); + void GraphCanvasSystemComponent::OnCatalogAssetAdded(const AZ::Data::AssetId& assetId) + { + ReloadDatabase(assetId); } void GraphCanvasSystemComponent::OnCatalogAssetChanged(const AZ::Data::AssetId& assetId) + { + ReloadDatabase(assetId); + } + + void GraphCanvasSystemComponent::ReloadDatabase(const AZ::Data::AssetId& assetId) { AZ::Data::AssetInfo assetInfo; AZ::Data::AssetCatalogRequestBus::BroadcastResult(assetInfo, &AZ::Data::AssetCatalogRequestBus::Events::GetAssetInfoById, assetId); @@ -405,20 +406,5 @@ namespace GraphCanvas AZ::Data::AssetManager::Instance().UnregisterHandler(m_assetHandler.get()); m_assetHandler.reset(); } - - for (const AZ::Data::AssetId& assetId : m_translationAssets) - { - AZ::Data::AssetBus::MultiHandler::BusDisconnect(assetId); - } - m_translationAssets.clear(); - } - - void GraphCanvasSystemComponent::PopulateTranslationDatabase() - { - for (const AZ::Data::AssetId& assetId : m_translationAssets) - { - AZ::Data::AssetBus::MultiHandler::BusConnect(assetId); - AZ::Data::AssetManager::Instance().GetAsset(assetId, AZ::Data::AssetLoadBehavior::Default); - } } } diff --git a/Gems/GraphCanvas/Code/Source/GraphCanvas.h b/Gems/GraphCanvas/Code/Source/GraphCanvas.h index 0b47e9010a..37bf064203 100644 --- a/Gems/GraphCanvas/Code/Source/GraphCanvas.h +++ b/Gems/GraphCanvas/Code/Source/GraphCanvas.h @@ -25,7 +25,6 @@ namespace GraphCanvas , private GraphCanvasRequestBus::Handler , protected Styling::PseudoElementFactoryRequestBus::Handler , protected AzFramework::AssetCatalogEventBus::Handler - , protected AZ::Data::AssetBus::MultiHandler { public: @@ -80,15 +79,17 @@ namespace GraphCanvas // AzFramework::AssetCatalogEventBus::Handler void OnCatalogLoaded(const char* /*catalogFile*/) override; void OnCatalogAssetChanged(const AZ::Data::AssetId&) override; + void OnCatalogAssetAdded(const AZ::Data::AssetId&) override; + void OnCatalogAssetRemoved(const AZ::Data::AssetId& /*assetId*/, const AZ::Data::AssetInfo& /*assetInfo*/) override; //// + void ReloadDatabase(const AZ::Data::AssetId&); + AZStd::unique_ptr m_assetHandler; void RegisterTranslationBuilder(); void UnregisterAssetHandler(); TranslationAssetWorker m_translationAssetWorker; - AZStd::vector m_translationAssets; - void PopulateTranslationDatabase(); TranslationDatabase m_translationDatabase; }; diff --git a/Gems/GraphCanvas/Code/Source/Translation/TranslationDatabase.cpp b/Gems/GraphCanvas/Code/Source/Translation/TranslationDatabase.cpp index 0b5029de63..448f69adfa 100644 --- a/Gems/GraphCanvas/Code/Source/Translation/TranslationDatabase.cpp +++ b/Gems/GraphCanvas/Code/Source/Translation/TranslationDatabase.cpp @@ -163,9 +163,11 @@ namespace GraphCanvas } else { - AZStd::string warning = AZStd::string::format("Unable to store key: %s with value: %s because that key already exists with value: %s", entry.first.c_str(), entry.second.c_str(), m_database[entry.first].c_str()); - AZ_Warning("TranslationSerializer", false, warning.c_str()); - warnings = true; + const bool valueMatches = entry.second == m_database[entry.first]; + AZ_Warning("TranslationDatabase", valueMatches, + R"(Unable to store key: "%s" with value: "%s" because that key already exists with value: "%s")", + entry.first.c_str(), entry.second.c_str(), m_database[entry.first].c_str()); + warnings = !valueMatches; } } diff --git a/Gems/GraphCanvas/Code/Source/Translation/TranslationSerializer.cpp b/Gems/GraphCanvas/Code/Source/Translation/TranslationSerializer.cpp index 754267b27d..035954555c 100644 --- a/Gems/GraphCanvas/Code/Source/Translation/TranslationSerializer.cpp +++ b/Gems/GraphCanvas/Code/Source/Translation/TranslationSerializer.cpp @@ -24,11 +24,12 @@ namespace GraphCanvas } else { - const AZStd::string& existingValue = translationDbItr->second; + [[maybe_unused]] const AZStd::string& existingValue = translationDbItr->second; // There is a name collision - const AZStd::string error = AZStd::string::format("Unable to store key: %s with value: %s because that key already exists with value: %s (proposed: %s)", baseKey.c_str(), it.GetString(), existingValue.c_str(), it.GetString()); - AZ_Error("TranslationSerializer", false, error.c_str()); + AZ_Error("TranslationSerializer", existingValue == it.GetString(), + R"(Unable to store key: "%s" with value: "%s" because that key already exists with value: "%s" (proposed: "%s"))", + baseKey.c_str(), it.GetString(), existingValue.c_str(), it.GetString()); } } else if (it.IsObject()) @@ -136,7 +137,7 @@ namespace GraphCanvas if (keyStr.empty()) { - AZ_Error("TranslationDatabase", false, "Every entry in the Translation data must have a key: %s", contextStr.c_str()); + AZ_Warning("TranslationDatabase", false, "Every entry in the Translation data must have a key: %s", baseKey.c_str()); return context.Report(JSR::Tasks::ReadField, JSR::Outcomes::Unsupported, "Every entry in the Translation data must have a key"); } diff --git a/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Styling/SelectorImplementations.h b/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Styling/SelectorImplementations.h index 1c65bf1915..eac9abdec8 100644 --- a/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Styling/SelectorImplementations.h +++ b/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Styling/SelectorImplementations.h @@ -79,7 +79,7 @@ namespace GraphCanvas private: AZStd::string m_value; - AZStd::hash::result_type m_hash; + size_t m_hash; friend class BasicSelectorEventHandler; }; diff --git a/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Widgets/AssetEditorToolbar/AssetEditorToolbar.ui b/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Widgets/AssetEditorToolbar/AssetEditorToolbar.ui index 688b3724e4..cf7a8e31d1 100644 --- a/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Widgets/AssetEditorToolbar/AssetEditorToolbar.ui +++ b/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Widgets/AssetEditorToolbar/AssetEditorToolbar.ui @@ -56,7 +56,7 @@ - Groups the current selection in the active graph [Ctrl+Shift+G] + Groups the current selection in the active graph [Ctrl+Alt+O] ... @@ -66,14 +66,14 @@ :/GraphCanvasEditorResources/group.svg:/GraphCanvasEditorResources/group.svg - Ctrl+Shift+G + Ctrl+Alt+O - <html><head/><body><p>Ungroups the selected element in the active graph [Ctrl+Shift+H]</p></body></html> + Ungroups the selected element in the active graph [Ctrl+Alt+P] ... @@ -83,7 +83,7 @@ :/GraphCanvasEditorResources/ungroup.svg:/GraphCanvasEditorResources/ungroup.svg - Ctrl+Shift+H + Ctrl+Alt+P diff --git a/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Widgets/NodePalette/NodePaletteWidget.cpp b/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Widgets/NodePalette/NodePaletteWidget.cpp index 5a1aaedeb9..f6cec6de6b 100644 --- a/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Widgets/NodePalette/NodePaletteWidget.cpp +++ b/Gems/GraphCanvas/Code/StaticLib/GraphCanvas/Widgets/NodePalette/NodePaletteWidget.cpp @@ -85,7 +85,7 @@ namespace GraphCanvas if (leftSpot < textRect.right()) { int visibleLength = AZStd::GetMin(selectedTextLength, textRect.right() - leftSpot); - QRect highlightRect(textRect.left() + preSelectedTextLength, textRect.top(), visibleLength, textRect.height()); + QRect highlightRect(textRect.left() + preSelectedTextLength + 4, textRect.top(), visibleLength, textRect.height()); // paint the highlight rect painter->fillRect(highlightRect, options.palette.highlight()); diff --git a/Gems/GraphCanvas/gem.json b/Gems/GraphCanvas/gem.json index 4762cfef35..c2038f4645 100644 --- a/Gems/GraphCanvas/gem.json +++ b/Gems/GraphCanvas/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Graph Canvas Gem provides a C++ framework for creating custom graphical node based editors for Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/GraphModel/gem.json b/Gems/GraphModel/gem.json index ad6b592430..ece520278b 100644 --- a/Gems/GraphModel/gem.json +++ b/Gems/GraphModel/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Graph Model Gem provides a generic node graph data model framework for Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/HttpRequestor/CMakeLists.txt b/Gems/HttpRequestor/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/HttpRequestor/CMakeLists.txt +++ b/Gems/HttpRequestor/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/HttpRequestor/Code/CMakeLists.txt b/Gems/HttpRequestor/Code/CMakeLists.txt index 831eb52231..56d3527e24 100644 --- a/Gems/HttpRequestor/Code/CMakeLists.txt +++ b/Gems/HttpRequestor/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(source_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(source_pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME HttpRequestor.Static STATIC @@ -71,5 +71,6 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) ) ly_add_googletest( NAME Gem::HttpRequestor.Tests + TEST_SUITE sandbox ) endif() diff --git a/Gems/HttpRequestor/gem.json b/Gems/HttpRequestor/gem.json index 582bfa0071..a8e111ac63 100644 --- a/Gems/HttpRequestor/gem.json +++ b/Gems/HttpRequestor/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The HTTP Requestor Gem provides functionality to make asynchronous HTTP/HTTPS requests and return data through a user-provided call back function.", "canonical_tags": [ diff --git a/Gems/ImGui/CMakeLists.txt b/Gems/ImGui/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/ImGui/CMakeLists.txt +++ b/Gems/ImGui/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/ImGui/Code/CMakeLists.txt b/Gems/ImGui/Code/CMakeLists.txt index e345e3d546..c293065636 100644 --- a/Gems/ImGui/Code/CMakeLists.txt +++ b/Gems/ImGui/Code/CMakeLists.txt @@ -8,7 +8,7 @@ set(config_base_defines $,IMGUI_DISABLED,IMGUI_ENABLED>) -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) # This library is the 3rdParty imgui that is in the Gem's External ly_add_target( diff --git a/Gems/ImGui/Code/Source/ImGuiManager.cpp b/Gems/ImGui/Code/Source/ImGuiManager.cpp index 4f49fd6509..4b841a7b1e 100644 --- a/Gems/ImGui/Code/Source/ImGuiManager.cpp +++ b/Gems/ImGui/Code/Source/ImGuiManager.cpp @@ -115,7 +115,9 @@ void ImGuiManager::Initialize() // Set config file ImGuiIO& io = ImGui::GetIO(); - io.IniFilename = "imgui.ini"; +#if defined(IMGUI_DISABLE_AUTOMATIC_INI_SAVING_LOADING) + io.IniFilename = nullptr; +#endif // Enable Nav Keyboard by default and allow io.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard; diff --git a/Gems/ImGui/Code/Source/Platform/Windows/imgui_windows.cmake b/Gems/ImGui/Code/Source/Platform/Windows/imgui_windows.cmake index 419c652a38..bea2cfc38b 100644 --- a/Gems/ImGui/Code/Source/Platform/Windows/imgui_windows.cmake +++ b/Gems/ImGui/Code/Source/Platform/Windows/imgui_windows.cmake @@ -8,6 +8,5 @@ set(LY_COMPILE_DEFINITIONS PRIVATE - IMGUI_DISABLE_WIN32_DEFAULT_CLIPBOARD_FUNCTIONS IMGUI_DISABLE_WIN32_DEFAULT_IME_FUNCTIONS ) diff --git a/Gems/ImGui/gem.json b/Gems/ImGui/gem.json index dfc12f64b4..0ed889f693 100644 --- a/Gems/ImGui/gem.json +++ b/Gems/ImGui/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Immediate Mode GUI Gem provides the 3rdParty library IMGUI which can be used to create run time immediate mode overlays for debugging and profiling information in Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/InAppPurchases/CMakeLists.txt b/Gems/InAppPurchases/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/InAppPurchases/CMakeLists.txt +++ b/Gems/InAppPurchases/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/InAppPurchases/Code/CMakeLists.txt b/Gems/InAppPurchases/Code/CMakeLists.txt index 99fc937919..e7b34296d1 100644 --- a/Gems/InAppPurchases/Code/CMakeLists.txt +++ b/Gems/InAppPurchases/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME InAppPurchases.Static STATIC diff --git a/Gems/InAppPurchases/gem.json b/Gems/InAppPurchases/gem.json index 21febbfeca..0b3d2e65e4 100644 --- a/Gems/InAppPurchases/gem.json +++ b/Gems/InAppPurchases/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The In-App Purchases Gem provides functionality for in app purchases for iOS and Android.", "canonical_tags": [ diff --git a/Gems/LandscapeCanvas/gem.json b/Gems/LandscapeCanvas/gem.json index 8653da40e1..f1e326efce 100644 --- a/Gems/LandscapeCanvas/gem.json +++ b/Gems/LandscapeCanvas/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Landscape Canvas Gem provides the Landscape Canvas editor, a node-based graph tool for authoring workflows to populate landscape with dynamic vegetation.", "canonical_tags": [ diff --git a/Gems/LmbrCentral/CMakeLists.txt b/Gems/LmbrCentral/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/LmbrCentral/CMakeLists.txt +++ b/Gems/LmbrCentral/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/LmbrCentral/Code/CMakeLists.txt b/Gems/LmbrCentral/Code/CMakeLists.txt index 2df0bd0632..a4c94a7b40 100644 --- a/Gems/LmbrCentral/Code/CMakeLists.txt +++ b/Gems/LmbrCentral/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) ly_add_target( NAME LmbrCentral.Static STATIC @@ -121,75 +121,4 @@ if (PAL_TRAIT_BUILD_HOST_TOOLS) endif() -################################################################################ -# Tests -################################################################################ -if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) - ly_add_target( - NAME LmbrCentral.Mocks HEADERONLY - NAMESPACE Gem - FILES_CMAKE - lmbrcentral_mocks_files.cmake - INCLUDE_DIRECTORIES - INTERFACE - Mocks - ) - - ly_add_target( - NAME LmbrCentral.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} - NAMESPACE Gem - FILES_CMAKE - lmbrcentral_tests_files.cmake - lmbrcentral_shared_files.cmake - INCLUDE_DIRECTORIES - PRIVATE - Source - Tests - BUILD_DEPENDENCIES - PRIVATE - AZ::AzTest - AZ::AzTestShared - Legacy::CryCommon - AZ::AzFramework - Gem::LmbrCentral.Static - Gem::LmbrCentral.Mocks - ) - ly_add_googletest( - NAME Gem::LmbrCentral.Tests - ) - - if (PAL_TRAIT_BUILD_HOST_TOOLS) - ly_add_target( - NAME LmbrCentral.Editor.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} - NAMESPACE Gem - FILES_CMAKE - lmbrcentral_editor_tests_files.cmake - INCLUDE_DIRECTORIES - PRIVATE - . - Source - Tests - COMPILE_DEFINITIONS - PRIVATE - LMBR_CENTRAL_EDITOR - BUILD_DEPENDENCIES - PRIVATE - 3rdParty::Qt::Gui - 3rdParty::Qt::Widgets - Legacy::CryCommon - Legacy::Editor.Headers - AZ::AzTest - AZ::AzCore - AZ::AzTestShared - AZ::AzToolsFramework - AZ::AzToolsFrameworkTestCommon - AZ::AssetBuilderSDK - AZ::AzManipulatorTestFramework.Static - Gem::LmbrCentral.Static - Gem::LmbrCentral.Editor.Static - ) - ly_add_googletest( - NAME Gem::LmbrCentral.Editor.Tests - ) - endif() -endif() +add_subdirectory(Tests) diff --git a/Gems/LmbrCentral/Code/Source/Shape/ReferenceShapeComponent.cpp b/Gems/LmbrCentral/Code/Source/Shape/ReferenceShapeComponent.cpp index 7ed79fe3a3..1fc4bb5107 100644 --- a/Gems/LmbrCentral/Code/Source/Shape/ReferenceShapeComponent.cpp +++ b/Gems/LmbrCentral/Code/Source/Shape/ReferenceShapeComponent.cpp @@ -190,7 +190,7 @@ namespace LmbrCentral { AZ::Crc32 result = {}; - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Shape", !m_isRequestInProgress, "Detected cyclic dependencies with shape entity references"); if (AllowRequest()) { m_isRequestInProgress = true; @@ -205,7 +205,7 @@ namespace LmbrCentral { AZ::Aabb result = AZ::Aabb::CreateNull(); - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Shape", !m_isRequestInProgress, "Detected cyclic dependencies with shape entity references"); if (AllowRequest()) { m_isRequestInProgress = true; @@ -221,7 +221,7 @@ namespace LmbrCentral transform = AZ::Transform::CreateIdentity(); bounds = AZ::Aabb::CreateNull(); - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Shape", !m_isRequestInProgress, "Detected cyclic dependencies with shape entity references"); if (AllowRequest()) { m_isRequestInProgress = true; @@ -234,7 +234,7 @@ namespace LmbrCentral { bool result = false; - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Shape", !m_isRequestInProgress, "Detected cyclic dependencies with shape entity references"); if (AllowRequest()) { m_isRequestInProgress = true; @@ -249,7 +249,7 @@ namespace LmbrCentral { float result = FLT_MAX; - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Shape", !m_isRequestInProgress, "Detected cyclic dependencies with shape entity references"); if (AllowRequest()) { m_isRequestInProgress = true; @@ -264,7 +264,7 @@ namespace LmbrCentral { float result = FLT_MAX; - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Shape", !m_isRequestInProgress, "Detected cyclic dependencies with shape entity references"); if (AllowRequest()) { m_isRequestInProgress = true; @@ -279,7 +279,7 @@ namespace LmbrCentral { AZ::Vector3 result = AZ::Vector3::CreateZero(); - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Shape", !m_isRequestInProgress, "Detected cyclic dependencies with shape entity references"); if (AllowRequest()) { m_isRequestInProgress = true; @@ -294,7 +294,7 @@ namespace LmbrCentral { bool result = false; - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Shape", !m_isRequestInProgress, "Detected cyclic dependencies with shape entity references"); if (AllowRequest()) { m_isRequestInProgress = true; diff --git a/Gems/LmbrCentral/Code/Tests/CMakeLists.txt b/Gems/LmbrCentral/Code/Tests/CMakeLists.txt new file mode 100644 index 0000000000..52928cc5db --- /dev/null +++ b/Gems/LmbrCentral/Code/Tests/CMakeLists.txt @@ -0,0 +1,79 @@ +# +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# +# + +if(NOT PAL_TRAIT_BUILD_TESTS_SUPPORTED) + return() +endif() + +ly_add_target( + NAME LmbrCentral.Mocks HEADERONLY + NAMESPACE Gem + FILES_CMAKE + lmbrcentral_mocks_files.cmake + INCLUDE_DIRECTORIES + INTERFACE + ../Mocks +) + +ly_add_target( + NAME LmbrCentral.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} + NAMESPACE Gem + FILES_CMAKE + lmbrcentral_tests_files.cmake + INCLUDE_DIRECTORIES + PRIVATE + ../Source + . + BUILD_DEPENDENCIES + PRIVATE + AZ::AzTest + AZ::AzTestShared + Legacy::CryCommon + AZ::AzFramework + Gem::LmbrCentral.Static + Gem::LmbrCentral.Mocks +) +ly_add_googletest( + NAME Gem::LmbrCentral.Tests +) + +if (PAL_TRAIT_BUILD_HOST_TOOLS) + ly_add_target( + NAME LmbrCentral.Editor.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} + NAMESPACE Gem + FILES_CMAKE + lmbrcentral_editor_tests_files.cmake + INCLUDE_DIRECTORIES + PRIVATE + .. + ../Source + . + COMPILE_DEFINITIONS + PRIVATE + LMBR_CENTRAL_EDITOR + BUILD_DEPENDENCIES + PRIVATE + 3rdParty::Qt::Gui + 3rdParty::Qt::Widgets + Legacy::CryCommon + Legacy::Editor.Headers + AZ::AzTest + AZ::AzCore + AZ::AzTestShared + AZ::AzToolsFramework + AZ::AzToolsFrameworkTestCommon + AZ::AssetBuilderSDK + AZ::AzManipulatorTestFramework.Static + Gem::LmbrCentral.Static + Gem::LmbrCentral.Editor.Static + ) + ly_add_googletest( + NAME Gem::LmbrCentral.Editor.Tests + ) +endif() + diff --git a/Gems/LmbrCentral/Code/Tests/lmbrcentral_editor_tests_files.cmake b/Gems/LmbrCentral/Code/Tests/lmbrcentral_editor_tests_files.cmake new file mode 100644 index 0000000000..72a26c2884 --- /dev/null +++ b/Gems/LmbrCentral/Code/Tests/lmbrcentral_editor_tests_files.cmake @@ -0,0 +1,28 @@ +# +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# +# + +set(FILES + LmbrCentralEditorTest.cpp + LmbrCentralReflectionTest.h + LmbrCentralReflectionTest.cpp + EditorBoxShapeComponentTests.cpp + EditorSphereShapeComponentTests.cpp + EditorCapsuleShapeComponentTests.cpp + EditorCompoundShapeComponentTests.cpp + EditorCylinderShapeComponentTests.cpp + EditorPolygonPrismShapeComponentTests.cpp + EditorTubeShapeComponentTests.cpp + SpawnerComponentTest.cpp + Builders/CopyDependencyBuilderTest.cpp + Builders/SliceBuilderTests.cpp + Builders/LevelBuilderTest.cpp + Builders/LuaBuilderTests.cpp + Builders/SeedBuilderTests.cpp + ../Source/LmbrCentral.cpp + ../Source/LmbrCentralEditor.cpp +) diff --git a/Gems/LmbrCentral/Code/lmbrcentral_mocks_files.cmake b/Gems/LmbrCentral/Code/Tests/lmbrcentral_mocks_files.cmake similarity index 83% rename from Gems/LmbrCentral/Code/lmbrcentral_mocks_files.cmake rename to Gems/LmbrCentral/Code/Tests/lmbrcentral_mocks_files.cmake index c3a5cca3f8..1e510747f2 100644 --- a/Gems/LmbrCentral/Code/lmbrcentral_mocks_files.cmake +++ b/Gems/LmbrCentral/Code/Tests/lmbrcentral_mocks_files.cmake @@ -7,5 +7,5 @@ # set(FILES - Mocks/LmbrCentral/Shape/MockShapes.h + ../Mocks/LmbrCentral/Shape/MockShapes.h ) diff --git a/Gems/LmbrCentral/Code/Tests/lmbrcentral_tests_files.cmake b/Gems/LmbrCentral/Code/Tests/lmbrcentral_tests_files.cmake new file mode 100644 index 0000000000..1555ff53d8 --- /dev/null +++ b/Gems/LmbrCentral/Code/Tests/lmbrcentral_tests_files.cmake @@ -0,0 +1,32 @@ +# +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# +# + +set(FILES + AudioComponentTests.cpp + AxisAlignedBoxShapeTest.cpp + BoxShapeTest.cpp + BundlingSystemComponentTests.cpp + SphereShapeTest.cpp + CylinderShapeTest.cpp + CapsuleShapeTest.cpp + PolygonPrismShapeTest.cpp + QuadShapeTest.cpp + TubeShapeTest.cpp + LmbrCentralReflectionTest.h + LmbrCentralReflectionTest.cpp + LmbrCentralTest.cpp + ShapeGeometryUtilTest.cpp + SpawnerComponentTest.cpp + SplineComponentTests.cpp + DiskShapeTest.cpp + ReferenceShapeTests.cpp + ../Source/LmbrCentral.cpp + ../Source/Ai/NavigationComponent.cpp + ../Source/Scripting/SpawnerComponent.cpp + ../Source/Shape/TubeShape.cpp +) diff --git a/Gems/LmbrCentral/Code/include/LmbrCentral/Component/EditorWrappedComponentBase.h b/Gems/LmbrCentral/Code/include/LmbrCentral/Component/EditorWrappedComponentBase.h index 29169ec9d7..af7509e3a6 100644 --- a/Gems/LmbrCentral/Code/include/LmbrCentral/Component/EditorWrappedComponentBase.h +++ b/Gems/LmbrCentral/Code/include/LmbrCentral/Component/EditorWrappedComponentBase.h @@ -56,6 +56,7 @@ namespace LmbrCentral TComponent m_component; TConfiguration m_configuration; bool m_visible = true; + bool m_runtimeComponentActive = false; }; } // namespace LmbrCentral diff --git a/Gems/LmbrCentral/Code/include/LmbrCentral/Component/EditorWrappedComponentBase.inl b/Gems/LmbrCentral/Code/include/LmbrCentral/Component/EditorWrappedComponentBase.inl index 6a9fceabbf..ee5dbe867e 100644 --- a/Gems/LmbrCentral/Code/include/LmbrCentral/Component/EditorWrappedComponentBase.inl +++ b/Gems/LmbrCentral/Code/include/LmbrCentral/Component/EditorWrappedComponentBase.inl @@ -177,6 +177,7 @@ namespace LmbrCentral void EditorWrappedComponentBase::Init() { AzToolsFramework::Components::EditorComponentBase::Init(); + m_runtimeComponentActive = false; m_component.ReadInConfig(&m_configuration); m_component.Init(); } @@ -196,6 +197,7 @@ namespace LmbrCentral if (m_visible) { m_component.Activate(); + m_runtimeComponentActive = true; } } @@ -205,8 +207,10 @@ namespace LmbrCentral AzToolsFramework::EditorVisibilityNotificationBus::Handler::BusDisconnect(); AzToolsFramework::Components::EditorComponentBase::Deactivate(); + m_runtimeComponentActive = false; m_component.Deactivate(); - m_component.SetEntity(nullptr); // remove the entity association, in case the parent component is being removed, otherwise the component will be reactivated + // remove the entity association, in case the parent component is being removed, otherwise the component will be reactivated + m_component.SetEntity(nullptr); } template @@ -222,12 +226,18 @@ namespace LmbrCentral template AZ::u32 EditorWrappedComponentBase::ConfigurationChanged() { - m_component.Deactivate(); + if (m_runtimeComponentActive) + { + m_runtimeComponentActive = false; + m_component.Deactivate(); + } + m_component.ReadInConfig(&m_configuration); - if (m_visible && m_component.GetEntity()) + if (m_visible && !m_runtimeComponentActive) { m_component.Activate(); + m_runtimeComponentActive = true; } return AZ::Edit::PropertyRefreshLevels::None; diff --git a/Gems/LmbrCentral/Code/include/LmbrCentral/Rendering/MeshAsset.h b/Gems/LmbrCentral/Code/include/LmbrCentral/Rendering/MeshAsset.h index b4cefa8502..329687ab82 100644 --- a/Gems/LmbrCentral/Code/include/LmbrCentral/Rendering/MeshAsset.h +++ b/Gems/LmbrCentral/Code/include/LmbrCentral/Rendering/MeshAsset.h @@ -9,8 +9,6 @@ #include -#include - namespace LmbrCentral { class MeshAsset diff --git a/Gems/LmbrCentral/Code/lmbrcentral_editor_tests_files.cmake b/Gems/LmbrCentral/Code/lmbrcentral_editor_tests_files.cmake deleted file mode 100644 index afba79e566..0000000000 --- a/Gems/LmbrCentral/Code/lmbrcentral_editor_tests_files.cmake +++ /dev/null @@ -1,28 +0,0 @@ -# -# Copyright (c) Contributors to the Open 3D Engine Project. -# For complete copyright and license terms please see the LICENSE at the root of this distribution. -# -# SPDX-License-Identifier: Apache-2.0 OR MIT -# -# - -set(FILES - Tests/LmbrCentralEditorTest.cpp - Tests/LmbrCentralReflectionTest.h - Tests/LmbrCentralReflectionTest.cpp - Tests/EditorBoxShapeComponentTests.cpp - Tests/EditorSphereShapeComponentTests.cpp - Tests/EditorCapsuleShapeComponentTests.cpp - Tests/EditorCompoundShapeComponentTests.cpp - Tests/EditorCylinderShapeComponentTests.cpp - Tests/EditorPolygonPrismShapeComponentTests.cpp - Tests/EditorTubeShapeComponentTests.cpp - Tests/SpawnerComponentTest.cpp - Tests/Builders/CopyDependencyBuilderTest.cpp - Tests/Builders/SliceBuilderTests.cpp - Tests/Builders/LevelBuilderTest.cpp - Tests/Builders/LuaBuilderTests.cpp - Tests/Builders/SeedBuilderTests.cpp - Source/LmbrCentral.cpp - Source/LmbrCentralEditor.cpp -) diff --git a/Gems/LmbrCentral/Code/lmbrcentral_tests_files.cmake b/Gems/LmbrCentral/Code/lmbrcentral_tests_files.cmake deleted file mode 100644 index 97e5d87829..0000000000 --- a/Gems/LmbrCentral/Code/lmbrcentral_tests_files.cmake +++ /dev/null @@ -1,29 +0,0 @@ -# -# Copyright (c) Contributors to the Open 3D Engine Project. -# For complete copyright and license terms please see the LICENSE at the root of this distribution. -# -# SPDX-License-Identifier: Apache-2.0 OR MIT -# -# - -set(FILES - Tests/AudioComponentTests.cpp - Tests/AxisAlignedBoxShapeTest.cpp - Tests/BoxShapeTest.cpp - Tests/BundlingSystemComponentTests.cpp - Tests/SphereShapeTest.cpp - Tests/CylinderShapeTest.cpp - Tests/CapsuleShapeTest.cpp - Tests/PolygonPrismShapeTest.cpp - Tests/QuadShapeTest.cpp - Tests/TubeShapeTest.cpp - Tests/LmbrCentralReflectionTest.h - Tests/LmbrCentralReflectionTest.cpp - Tests/LmbrCentralTest.cpp - Tests/ShapeGeometryUtilTest.cpp - Tests/SpawnerComponentTest.cpp - Tests/SplineComponentTests.cpp - Tests/DiskShapeTest.cpp - Tests/ReferenceShapeTests.cpp - Source/LmbrCentral.cpp -) diff --git a/Gems/LmbrCentral/gem.json b/Gems/LmbrCentral/gem.json index a0a6ea813f..4eea28d26e 100644 --- a/Gems/LmbrCentral/gem.json +++ b/Gems/LmbrCentral/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The O3DE Core (LmbrCentral) Gem provides required code and assets for running Open 3D Engine Editor.", "canonical_tags": [ diff --git a/Gems/LocalUser/CMakeLists.txt b/Gems/LocalUser/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/LocalUser/CMakeLists.txt +++ b/Gems/LocalUser/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/LocalUser/Code/CMakeLists.txt b/Gems/LocalUser/Code/CMakeLists.txt index 055cfe6c7c..ce937e9dc5 100644 --- a/Gems/LocalUser/Code/CMakeLists.txt +++ b/Gems/LocalUser/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME LocalUser.Static STATIC diff --git a/Gems/LocalUser/gem.json b/Gems/LocalUser/gem.json index 5199b4f777..04f2145956 100644 --- a/Gems/LocalUser/gem.json +++ b/Gems/LocalUser/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Local User Gem provides functionality for mapping local user ids to local player slots and managing local user profiles.", "canonical_tags": [ diff --git a/Gems/AtomLyIntegration/AtomBridge/Assets/Shaders/LyShineUI.azsl b/Gems/LyShine/Assets/LyShine/Shaders/LyShineUI.azsl similarity index 100% rename from Gems/AtomLyIntegration/AtomBridge/Assets/Shaders/LyShineUI.azsl rename to Gems/LyShine/Assets/LyShine/Shaders/LyShineUI.azsl diff --git a/Gems/AtomLyIntegration/AtomBridge/Assets/Shaders/LyShineUI.shader b/Gems/LyShine/Assets/LyShine/Shaders/LyShineUI.shader similarity index 100% rename from Gems/AtomLyIntegration/AtomBridge/Assets/Shaders/LyShineUI.shader rename to Gems/LyShine/Assets/LyShine/Shaders/LyShineUI.shader diff --git a/Gems/AtomLyIntegration/AtomBridge/Assets/Shaders/LyShineUI.shadervariantlist b/Gems/LyShine/Assets/LyShine/Shaders/LyShineUI.shadervariantlist similarity index 100% rename from Gems/AtomLyIntegration/AtomBridge/Assets/Shaders/LyShineUI.shadervariantlist rename to Gems/LyShine/Assets/LyShine/Shaders/LyShineUI.shadervariantlist diff --git a/Gems/LyShine/CMakeLists.txt b/Gems/LyShine/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/LyShine/CMakeLists.txt +++ b/Gems/LyShine/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/LyShine/Code/CMakeLists.txt b/Gems/LyShine/Code/CMakeLists.txt index 77aaa681e0..76d7742ddf 100644 --- a/Gems/LyShine/Code/CMakeLists.txt +++ b/Gems/LyShine/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) ly_add_target( NAME LyShine.Static STATIC @@ -47,6 +47,9 @@ ly_add_target( Gem::LyShine.Static Legacy::CryCommon Gem::LmbrCentral + PUBLIC + Gem::Atom_RHI.Reflect + Gem::Atom_RPI.Public RUNTIME_DEPENDENCIES Gem::LmbrCentral Gem::TextureAtlas @@ -55,10 +58,13 @@ ly_add_target( # by default, load the above "Gem::LyShine" module in Client and Server applications: ly_create_alias(NAME LyShine.Clients NAMESPACE Gem TARGETS Gem::LyShine) ly_create_alias(NAME LyShine.Servers NAMESPACE Gem TARGETS Gem::LyShine) +# create an alias for other gems to depend on an LyShine public API (may be converted to a target in the future): +ly_create_alias(NAME LyShine.Clients.API NAMESPACE Gem TARGETS Gem::LyShine.Clients) +ly_create_alias(NAME LyShine.Servers.API NAMESPACE Gem TARGETS Gem::LyShine.Servers) if (PAL_TRAIT_BUILD_HOST_TOOLS) ly_add_target( - NAME LyShine.Editor.Static STATIC + NAME LyShine.Tools.Static STATIC NAMESPACE Gem AUTOMOC AUTOUIC @@ -70,7 +76,6 @@ if (PAL_TRAIT_BUILD_HOST_TOOLS) . Source Editor - PUBLIC Include BUILD_DEPENDENCIES PRIVATE @@ -97,7 +102,7 @@ if (PAL_TRAIT_BUILD_HOST_TOOLS) ) ly_add_target( - NAME LyShine.Editor GEM_MODULE + NAME LyShine.Tools GEM_MODULE NAMESPACE Gem FILES_CMAKE lyshine_common_module_files.cmake @@ -109,18 +114,18 @@ if (PAL_TRAIT_BUILD_HOST_TOOLS) . Source Editor - PUBLIC Include BUILD_DEPENDENCIES PRIVATE Legacy::CryCommon AZ::AzToolsFramework - Gem::LyShine.Editor.Static + Gem::LyShine.Tools.Static Gem::LmbrCentral.Editor Gem::TextureAtlas.Editor RUNTIME_DEPENDENCIES Gem::LmbrCentral.Editor Gem::TextureAtlas.Editor + Gem::UiBasics.Tools ) # by naming this target LyShine.Builders it ensures that it is loaded @@ -176,10 +181,9 @@ if (PAL_TRAIT_BUILD_HOST_TOOLS) Gem::LyShine.Builders.Static Gem::LmbrCentral.Editor Gem::TextureAtlas.Editor + RUNTIME_DEPENDENCIES + Gem::UiBasics.Builders ) - - # by default, load the above "Gem::LyShine.Editor" module in dev tools: - ly_create_alias(NAME LyShine.Tools NAMESPACE Gem TARGETS Gem::LyShine.Editor) endif() ################################################################################ @@ -238,7 +242,7 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) AZ::AzTest Legacy::CryCommon AZ::AssetBuilderSDK - Gem::LyShine.Editor.Static + Gem::LyShine.Tools.Static Gem::LyShine.Builders.Static Gem::LmbrCentral.Editor Gem::TextureAtlas diff --git a/Gems/LyShine/Code/Editor/Animation/Util/UiEditorUtils.cpp b/Gems/LyShine/Code/Editor/Animation/Util/UiEditorUtils.cpp index 41f7300002..85270df355 100644 --- a/Gems/LyShine/Code/Editor/Animation/Util/UiEditorUtils.cpp +++ b/Gems/LyShine/Code/Editor/Animation/Util/UiEditorUtils.cpp @@ -92,23 +92,6 @@ QString TrimTrailingZeros(QString str) return str; } -////////////////////////////////////////////////////////////////////////// -// This function is supposed to format float in user-friendly way, -// omitting the exponent notation. -// -// Why not using printf? Its formatting rules has following drawbacks: -// %g - will use exponent for small numbers; -// %.Nf - doesn't allow to control total amount of significant numbers, -// which exposes limited precision during binary-to-decimal fraction -// conversion. -////////////////////////////////////////////////////////////////////////// -void FormatFloatForUI(QString& str, int significantDigits, double value) -{ - str = TrimTrailingZeros(QString::number(value, 'f', significantDigits)); - return; -} -//////////////////////////////////////////////////////////////////////////- - ////////////////////////////////////////////////////////////////////////// QColor ColorLinearToGamma(ColorF col) { diff --git a/Gems/LyShine/Code/Editor/GuideHelpers.cpp b/Gems/LyShine/Code/Editor/GuideHelpers.cpp index eb5966568e..b6d7acc57a 100644 --- a/Gems/LyShine/Code/Editor/GuideHelpers.cpp +++ b/Gems/LyShine/Code/Editor/GuideHelpers.cpp @@ -173,7 +173,7 @@ namespace GuideHelpers // the line is drawn as the inverse of the background color AZ::Color guideColor(1.0f, 1.0f, 1.0f, 1.0f); - CDraw2d::RenderState renderState; + IDraw2d::RenderState renderState; renderState.m_blendState.m_blendSource = AZ::RHI::BlendFactor::ColorDestInverse; renderState.m_blendState.m_blendDest = AZ::RHI::BlendFactor::Zero; diff --git a/Gems/LyShine/Code/Editor/ViewportCanvasBackground.cpp b/Gems/LyShine/Code/Editor/ViewportCanvasBackground.cpp index 668c4e8024..b1961de0a1 100644 --- a/Gems/LyShine/Code/Editor/ViewportCanvasBackground.cpp +++ b/Gems/LyShine/Code/Editor/ViewportCanvasBackground.cpp @@ -50,7 +50,7 @@ void ViewportCanvasBackground::Draw(Draw2dHelper& draw2d, const AZ::Vector2& can // now draw the same as Stretched but with UV's adjusted const AZ::Vector2 uvs[4] = { AZ::Vector2(0, 0), AZ::Vector2(uvScale.GetX(), 0), AZ::Vector2(uvScale.GetX(), uvScale.GetY()), AZ::Vector2(0, uvScale.GetY()) }; AZ::Color colorWhite(1.0f, 1.0f, 1.0f, 1.0f); - CDraw2d::VertexPosColUV verts[4]; + IDraw2d::VertexPosColUV verts[4]; for (int i = 0; i < 4; ++i) { verts[i].position = positions[i]; diff --git a/Gems/LyShine/Code/Editor/ViewportDragInteraction.h b/Gems/LyShine/Code/Editor/ViewportDragInteraction.h index 3b26b66308..6b48fc0133 100644 --- a/Gems/LyShine/Code/Editor/ViewportDragInteraction.h +++ b/Gems/LyShine/Code/Editor/ViewportDragInteraction.h @@ -8,7 +8,7 @@ #pragma once #include -#include +#include //! Abstract base class for drag interactions in the UI Editor viewport window. class ViewportDragInteraction diff --git a/Gems/LyShine/Code/Editor/ViewportHelpers.h b/Gems/LyShine/Code/Editor/ViewportHelpers.h index 8068f4af65..f2722fb6b8 100644 --- a/Gems/LyShine/Code/Editor/ViewportHelpers.h +++ b/Gems/LyShine/Code/Editor/ViewportHelpers.h @@ -7,7 +7,7 @@ */ #pragma once -#include +#include namespace ViewportHelpers { diff --git a/Gems/LyShine/Code/Editor/ViewportIcon.cpp b/Gems/LyShine/Code/Editor/ViewportIcon.cpp index 3f0fdfaba0..33f2f40ffe 100644 --- a/Gems/LyShine/Code/Editor/ViewportIcon.cpp +++ b/Gems/LyShine/Code/Editor/ViewportIcon.cpp @@ -6,7 +6,7 @@ * */ #include "EditorCommon.h" -#include +#include #include #include @@ -15,7 +15,7 @@ float ViewportIcon::m_dpiScaleFactor = 1.0f; ViewportIcon::ViewportIcon(const char* textureFilename) { - m_image = CDraw2d::LoadTexture(textureFilename); + m_image = Draw2dHelper::LoadTexture(textureFilename); } ViewportIcon::~ViewportIcon() @@ -48,7 +48,7 @@ void ViewportIcon::DrawImageAligned(Draw2dHelper& draw2d, AZ::Vector2& pivot, fl opacity); } -void ViewportIcon::DrawImageTiled(Draw2dHelper& draw2d, CDraw2d::VertexPosColUV* verts) +void ViewportIcon::DrawImageTiled(Draw2dHelper& draw2d, IDraw2d::VertexPosColUV* verts) { // Use default blending and rounding modes IDraw2d::Rounding rounding = IDraw2d::Rounding::Nearest; @@ -63,7 +63,7 @@ void ViewportIcon::DrawAxisAlignedBoundingBox(Draw2dHelper& draw2d, AZ::Vector2 float endTexCoordU = fabsf((bound1.GetX() - bound0.GetX()) * pixelLengthForDottedLineTexture); float endTexCoordV = fabsf((bound1.GetY() - bound0.GetY()) * pixelLengthForDottedLineTexture); - CDraw2d::VertexPosColUV verts[2]; + IDraw2d::VertexPosColUV verts[2]; { verts[0].color = dottedColor; verts[1].color = dottedColor; @@ -158,7 +158,7 @@ void ViewportIcon::Draw(Draw2dHelper& draw2d, AZ::Vector2 anchorPos, const AZ::M AZ::Matrix4x4 moveFromPivotSpaceMat = AZ::Matrix4x4::CreateTranslation(pivot3); AZ::Matrix4x4 newTransform = transform * moveFromPivotSpaceMat * rotMat * moveToPivotSpaceMat; - CDraw2d::VertexPosColUV verts[4]; + IDraw2d::VertexPosColUV verts[4]; // points are a clockwise quad static const AZ::Vector2 uvs[4] = { AZ::Vector2(0.0f, 0.0f), AZ::Vector2(1.0f, 0.0f), AZ::Vector2(1.0f, 1.0f), AZ::Vector2(0.0f, 1.0f) @@ -251,7 +251,7 @@ void ViewportIcon::DrawDistanceLine(Draw2dHelper& draw2d, AZ::Vector2 start, AZ: const float pixelLengthForDottedLineTexture = 8.0f; float endTexCoordU = length / pixelLengthForDottedLineTexture; - CDraw2d::VertexPosColUV verts[2]; + IDraw2d::VertexPosColUV verts[2]; verts[0].position = start; verts[0].color = dottedColor; diff --git a/Gems/LyShine/Code/Editor/ViewportIcon.h b/Gems/LyShine/Code/Editor/ViewportIcon.h index f815b244e9..fadd829bcf 100644 --- a/Gems/LyShine/Code/Editor/ViewportIcon.h +++ b/Gems/LyShine/Code/Editor/ViewportIcon.h @@ -20,7 +20,7 @@ public: void DrawImageAligned(Draw2dHelper& draw2d, AZ::Vector2& pivot, float opacity); - void DrawImageTiled(Draw2dHelper& draw2d, CDraw2d::VertexPosColUV* verts); + void DrawImageTiled(Draw2dHelper& draw2d, IDraw2d::VertexPosColUV* verts); void Draw(Draw2dHelper& draw2d, AZ::Vector2 anchorPos, const AZ::Matrix4x4& transform, float iconRot = 0.0f, AZ::Color color = AZ::Color(1.0f, 1.0f, 1.0f, 1.0f)) const; diff --git a/Gems/LyShine/Code/Editor/ViewportWidget.cpp b/Gems/LyShine/Code/Editor/ViewportWidget.cpp index 993f57aeeb..b481e9cbf1 100644 --- a/Gems/LyShine/Code/Editor/ViewportWidget.cpp +++ b/Gems/LyShine/Code/Editor/ViewportWidget.cpp @@ -16,7 +16,6 @@ #include #include -#include #include "LyShine.h" #include "UiRenderer.h" @@ -27,6 +26,7 @@ #include "RulerWidget.h" #include "CanvasHelpers.h" #include "AssetDropHelpers.h" +#include "Draw2d.h" #include "QtHelpers.h" #include diff --git a/Gems/LyShine/Code/Include/LyShine/IDraw2d.h b/Gems/LyShine/Code/Include/LyShine/IDraw2d.h index 3bfa3a1c14..77dc5ac601 100644 --- a/Gems/LyShine/Code/Include/LyShine/IDraw2d.h +++ b/Gems/LyShine/Code/Include/LyShine/IDraw2d.h @@ -11,6 +11,10 @@ #include #include #include +#include +#include +#include +#include //////////////////////////////////////////////////////////////////////////////////////////////////// //! Class for 2D drawing in screen space @@ -55,8 +59,505 @@ public: // types MAX_TEXT_STRING_LENGTH = 1024, }; + struct RenderState + { + RenderState() + { + m_blendState.m_enable = true; + m_blendState.m_blendSource = AZ::RHI::BlendFactor::AlphaSource; + m_blendState.m_blendDest = AZ::RHI::BlendFactor::AlphaSourceInverse; + + m_depthState.m_enable = false; + } + + AZ::RHI::TargetBlendState m_blendState; + AZ::RHI::DepthState m_depthState; + }; + + //! Struct used to pass additional image options. + // + //! If this is not passed then the defaults are used + struct ImageOptions + { + AZ::Vector3 color = AZ::Vector3(1.0f, 1.0f, 1.0f); + Rounding pixelRounding = Rounding::Nearest; + bool m_clamp = false; + RenderState m_renderState; + }; + + //! Struct used to pass additional text options - mostly ones that do not change from call to call. + // + //! If this is not passed then the defaults below are used + struct TextOptions + { + AZStd::string fontName; //!< default is "default" + unsigned int effectIndex; //!< default is 0 + AZ::Vector3 color; //!< default is (1,1,1) + HAlign horizontalAlignment; //!< default is HAlign::Left + VAlign verticalAlignment; //!< default is VAlign::Top + AZ::Vector2 dropShadowOffset; //!< default is (0,0), zero offset means no drop shadow is drawn + AZ::Color dropShadowColor; //!< default is (0,0,0,0), zero alpha means no drop shadow is drawn + float rotation; //!< default is 0 + bool depthTestEnabled; //!< default is false + }; + + //! Used to pass in arrays of vertices (e.g. to DrawQuad) + struct VertexPosColUV + { + VertexPosColUV() {} + VertexPosColUV(const AZ::Vector2& inPos, const AZ::Color& inColor, const AZ::Vector2& inUV) + { + position = inPos; + color = inColor; + uv = inUV; + } + + AZ::Vector2 position; //!< 2D position of vertex + AZ::Color color; //!< Float color + AZ::Vector2 uv; //!< Texture coordinate + }; + public: // member functions //! Implement virtual destructor just for safety. virtual ~IDraw2d() {} + + //! Draw a textured quad with the top left corner at the given position. + // + //! The image is drawn with the color specified by SetShapeColor and the opacity + //! passed as an argument. + //! If rotation is non-zero then the quad is rotated. If the pivot point is + //! provided then the points of the quad are rotated about that point, otherwise + //! they are rotated about the top left corner of the quad. + //! \param texId The texture ID returned by ITexture::GetTextureID() + //! \param position Position of the top left corner of the quad (before rotation) in pixels + //! \param size The width and height of the quad. Use texture width and height to avoid minification, + //! magnification or stretching (assuming the minMaxTexCoords are left to the default) + //! \param opacity The alpha value used when blending + //! \param rotation Angle of rotation in degrees counter-clockwise + //! \param pivotPoint The point about which the quad is rotated + //! \param minMaxTexCoords An optional two component array. The first component is the UV coord for the top left + //! point of the quad and the second is the UV coord of the bottom right point of the quad + //! \param imageOptions Optional struct specifying options that tend to be the same from call to call + virtual void DrawImage(AZ::Data::Instance image, AZ::Vector2 position, AZ::Vector2 size, float opacity = 1.0f, + float rotation = 0.0f, const AZ::Vector2* pivotPoint = nullptr, const AZ::Vector2* minMaxTexCoords = nullptr, + ImageOptions* imageOptions = nullptr) = 0; + + //! Draw a textured quad where the position specifies the point specified by the alignment. + // + //! Rotation is always around the position. + //! \param texId The texture ID returned by ITexture::GetTextureID() + //! \param position Position align point of the quad (before rotation) in pixels + //! \param size The width and height of the quad. Use texture width and height to avoid minification, + //! magnification or stretching (assuming the minMaxTexCoords are left to the default) + //! \param horizontalAlignment Specifies how the quad is horizontally aligned to the given position + //! \param verticalAlignment Specifies how the quad is vertically aligned to the given position + //! \param opacity The alpha value used when blending + //! \param rotation Angle of rotation in degrees counter-clockwise + //! \param minMaxTexCoords An optional two component array. The first component is the UV coord for the top left + //! point of the quad and the second is the UV coord of the bottom right point of the quad + //! \param imageOptions Optional struct specifying options that tend to be the same from call to call + virtual void DrawImageAligned(AZ::Data::Instance image, AZ::Vector2 position, AZ::Vector2 size, + HAlign horizontalAlignment, VAlign verticalAlignment, + float opacity = 1.0f, float rotation = 0.0f, const AZ::Vector2* minMaxTexCoords = nullptr, + ImageOptions* imageOptions = nullptr) = 0; + + //! Draw a textured quad where the position, color and uv of each point is specified explicitly + // + //! \param texId The texture ID returned by ITexture::GetTextureID() + //! \param verts An array of 4 vertices, in clockwise order (e.g. top left, top right, bottom right, bottom left) + //! \param pixelRounding Whether and how to round pixel coordinates + //! \param renderState Blend mode and depth state + virtual void DrawQuad(AZ::Data::Instance image, + VertexPosColUV* verts, + Rounding pixelRounding = Rounding::Nearest, + bool clamp = false, + const RenderState& renderState = RenderState{}) = 0; + + //! Draw a line + // + //! \param start The start position + //! \param end The end position + //! \param color The color of the line + //! \param pixelRounding Whether and how to round pixel coordinates + //! \param renderState Blend mode and depth state + virtual void DrawLine(AZ::Vector2 start, AZ::Vector2 end, AZ::Color color, + IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, + const RenderState& renderState = RenderState{}) = 0; + + //! Draw a line with a texture so it can be dotted or dashed + // + //! \param texId The texture ID returned by ITexture::GetTextureID() + //! \param verts An array of 2 vertices for the start and end points of the line + //! \param pixelRounding Whether and how to round pixel coordinates + //! \param renderState Blend mode and depth state + virtual void DrawLineTextured(AZ::Data::Instance image, + VertexPosColUV* verts, + IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, + const RenderState& renderState = RenderState{}) = 0; + //! Draw a text string. Only supports ASCII text. + // + //! The font and effect used to render the text are specified in the textOptions structure + //! \param textString A null terminated ASCII text string. May contain \n characters + //! \param position Position of the text in pixels. Alignment values in textOptions affect actual position + //! \param pointSize The size of the font to use + //! \param opacity The opacity (alpha value) to use to draw the text + //! \param textOptions Pointer to an options struct. If null the default options are used + virtual void DrawText(const char* textString, AZ::Vector2 position, float pointSize, + float opacity = 1.0f, TextOptions* textOptions = nullptr) = 0; + + //! Draw a rectangular outline with a texture + // + //! \param image The texture to be used for drawing the outline + //! \param points The rect's vertices (top left, top right, bottom right, bottom left) + //! \param rightVec Right vector. Specified because the rect's width/height could be 0 + //! \param downVec Down vector. Specified because the rect's width/height could be 0 + //! \param color The color of the outline + //! \param lineThickness The thickness in pixels of the outline. If 0, it will be based on image height + virtual void DrawRectOutlineTextured(AZ::Data::Instance image, + UiTransformInterface::RectPoints points, + AZ::Vector2 rightVec, + AZ::Vector2 downVec, + AZ::Color color, + uint32_t lineThickness = 0) = 0; + + //! Get the width and height (in pixels) that would be used to draw the given text string. + // + //! Pass the same parameter values that would be used to draw the string + virtual AZ::Vector2 GetTextSize(const char* textString, float pointSize, TextOptions* textOptions = nullptr) = 0; + + //! Get the width of the rendering viewport (in pixels). + virtual float GetViewportWidth() const = 0; + + //! Get the height of the rendering viewport (in pixels). + virtual float GetViewportHeight() const = 0; + + //! Get dpi scale factor + virtual float GetViewportDpiScalingFactor() const = 0; + + //! Get the default values that would be used if no image options were passed in + // + //! This is a convenient way to initialize the imageOptions struct + virtual const ImageOptions& GetDefaultImageOptions() const = 0; + + //! Get the default values that would be used if no text options were passed in + // + //! This is a convenient way to initialize the textOptions struct + virtual const TextOptions& GetDefaultTextOptions() const = 0; + + //! Render the primitives that have been deferred + virtual void RenderDeferredPrimitives() = 0; + + //! Specify whether to defer future primitives or render them right away + virtual void SetDeferPrimitives(bool deferPrimitives) = 0; + + //! Return whether future primitives will be deferred or rendered right away + virtual bool GetDeferPrimitives() = 0; + + //! Set sort key offset for following draws. + virtual void SetSortKey(int64_t key) = 0; +}; + +//////////////////////////////////////////////////////////////////////////////////////////////////// +//! Helper class for using the IDraw2d interface +//! +//! The Draw2dHelper class is an inline wrapper that provides the convenience feature of +//! automatically setting member options structures to their defaults and providing set functions. +class Draw2dHelper +{ +public: // member functions + + //! Start a section of 2D drawing function calls that will render to the default viewport + Draw2dHelper(bool deferCalls = false) + { + InitCommon(nullptr, deferCalls); + } + + //! Start a section of 2D drawing function calls that will render to the viewport + //! associated with the specified Draw2d object + Draw2dHelper(IDraw2d* draw2d, bool deferCalls = false) + { + InitCommon(draw2d, deferCalls); + } + + void InitCommon(IDraw2d* draw2d, bool deferCalls) + { + m_draw2d = draw2d; + + if (!m_draw2d) + { + // Set to default which is the game's draw 2d object + m_draw2d = GetDefaultDraw2d(); + } + + if (m_draw2d) + { + m_previousDeferCalls = m_draw2d->GetDeferPrimitives(); + m_draw2d->SetDeferPrimitives(deferCalls); + m_imageOptions = m_draw2d->GetDefaultImageOptions(); + m_textOptions = m_draw2d->GetDefaultTextOptions(); + } + } + + //! End a section of 2D drawing function calls. + ~Draw2dHelper() + { + if (m_draw2d) + { + m_draw2d->SetDeferPrimitives(m_previousDeferCalls); + } + } + + //! Draw a textured quad, optional rotation is counter-clockwise in degrees. + // + //! See IDraw2d:DrawImage for parameter descriptions + void DrawImage(AZ::Data::Instance image, AZ::Vector2 position, AZ::Vector2 size, float opacity = 1.0f, + float rotation = 0.0f, const AZ::Vector2* pivotPoint = nullptr, const AZ::Vector2* minMaxTexCoords = nullptr) + { + if (m_draw2d) + { + m_draw2d->DrawImage(image, position, size, opacity, rotation, pivotPoint, minMaxTexCoords, &m_imageOptions); + } + } + + //! Draw a textured quad where the position specifies the point specified by the alignment. + // + //! See IDraw2d:DrawImageAligned for parameter descriptions + void DrawImageAligned(AZ::Data::Instance image, AZ::Vector2 position, AZ::Vector2 size, + IDraw2d::HAlign horizontalAlignment, IDraw2d::VAlign verticalAlignment, + float opacity = 1.0f, float rotation = 0.0f, const AZ::Vector2* minMaxTexCoords = nullptr) + { + if (m_draw2d) + { + m_draw2d->DrawImageAligned(image, position, size, horizontalAlignment, verticalAlignment, + opacity, rotation, minMaxTexCoords, &m_imageOptions); + } + } + + //! Draw a textured quad where the position, color and uv of each point is specified explicitly + // + //! See IDraw2d:DrawQuad for parameter descriptions + void DrawQuad(AZ::Data::Instance image, IDraw2d::VertexPosColUV* verts, + IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, + bool clamp = false, + const IDraw2d::RenderState& renderState = IDraw2d::RenderState{}) + { + if (m_draw2d) + { + m_draw2d->DrawQuad(image, verts, pixelRounding, clamp, renderState); + } + } + + //! Draw a line + // + //! See IDraw2d:DrawLine for parameter descriptions + void DrawLine(AZ::Vector2 start, AZ::Vector2 end, AZ::Color color, + IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, + const IDraw2d::RenderState& renderState = IDraw2d::RenderState{}) + { + if (m_draw2d) + { + m_draw2d->DrawLine(start, end, color, pixelRounding, renderState); + } + } + + //! Draw a line with a texture so it can be dotted or dashed + // + //! See IDraw2d:DrawLineTextured for parameter descriptions + void DrawLineTextured(AZ::Data::Instance image, IDraw2d::VertexPosColUV* verts, + IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, + const IDraw2d::RenderState& renderState = IDraw2d::RenderState{}) + { + if (m_draw2d) + { + m_draw2d->DrawLineTextured(image, verts, pixelRounding, renderState); + } + } + + //! Draw a rect outline with a texture + // + //! See IDraw2d:DrawRectOutlineTextured for parameter descriptions + void DrawRectOutlineTextured(AZ::Data::Instance image, + UiTransformInterface::RectPoints points, + AZ::Vector2 rightVec, + AZ::Vector2 downVec, + AZ::Color color, + uint32_t lineThickness = 0) + { + if (m_draw2d) + { + m_draw2d->DrawRectOutlineTextured(image, points, rightVec, downVec, color, lineThickness); + } + } + + //! Draw a text string. Only supports ASCII text. + // + //! See IDraw2d:DrawText for parameter descriptions + void DrawText(const char* textString, AZ::Vector2 position, float pointSize, float opacity = 1.0f) + { + if (m_draw2d) + { + m_draw2d->DrawText(textString, position, pointSize, opacity, &m_textOptions); + } + } + + //! Get the width and height (in pixels) that would be used to draw the given text string. + // + //! See IDraw2d:GetTextSize for parameter descriptions + AZ::Vector2 GetTextSize(const char* textString, float pointSize) + { + if (m_draw2d) + { + return m_draw2d->GetTextSize(textString, pointSize, &m_textOptions); + } + else + { + return AZ::Vector2(0, 0); + } + } + + // State management + + //! Set the blend mode used for images, default is GS_BLSRC_SRCALPHA|GS_BLDST_ONEMINUSSRCALPHA. + void SetImageBlendMode(const AZ::RHI::TargetBlendState& blendState) { m_imageOptions.m_renderState.m_blendState = blendState; } + + //! Set the color used for DrawImage and other image drawing. + void SetImageColor(AZ::Vector3 color) { m_imageOptions.color = color; } + + //! Set whether images are rounded to have the points on exact pixel boundaries. + void SetImagePixelRounding(IDraw2d::Rounding round) { m_imageOptions.pixelRounding = round; } + + //! Set the base state (that blend mode etc is combined with) used for images, default is GS_NODEPTHTEST. + void SetImageDepthState(const AZ::RHI::DepthState& depthState) { m_imageOptions.m_renderState.m_depthState = depthState; } + + //! Set image clamp mode + void SetImageClamp(bool clamp) { m_imageOptions.m_clamp = clamp; } + + //! Set the text font. + void SetTextFont(AZStd::string_view fontName) { m_textOptions.fontName = fontName; } + + //! Set the text font effect index. + void SetTextEffectIndex(unsigned int effectIndex) { m_textOptions.effectIndex = effectIndex; } + + //! Set the text color. + void SetTextColor(AZ::Vector3 color) { m_textOptions.color = color; } + + //! Set the text alignment. + void SetTextAlignment(IDraw2d::HAlign horizontalAlignment, IDraw2d::VAlign verticalAlignment) + { + m_textOptions.horizontalAlignment = horizontalAlignment; + m_textOptions.verticalAlignment = verticalAlignment; + } + + //! Set a drop shadow for text drawing. An alpha of zero disables drop shadow. + void SetTextDropShadow(AZ::Vector2 offset, AZ::Color color) + { + m_textOptions.dropShadowOffset = offset; + m_textOptions.dropShadowColor = color; + } + + //! Set a rotation for the text. The text rotates around its position (taking into account alignment). + void SetTextRotation(float rotation) + { + m_textOptions.rotation = rotation; + } + + //! Set wheter to enable depth test for the text + void SetTextDepthTestEnabled(bool enabled) + { + m_textOptions.depthTestEnabled = enabled; + } + +public: // static member functions + + //! Helper to get the default IDraw2d interface + static IDraw2d* GetDefaultDraw2d() + { + if (gEnv && gEnv->pLyShine) // [LYSHINE_ATOM_TODO][GHI #3569] Remove LyShine global interface pointer from legacy global environment + { + IDraw2d* draw2d = gEnv->pLyShine->GetDraw2d(); + return reinterpret_cast(draw2d); + } + + return nullptr; + } + + //! Helper to load a texture + static AZ::Data::Instance LoadTexture(const AZStd::string& pathName) + { + if (gEnv && gEnv->pLyShine) // [LYSHINE_ATOM_TODO][GHI #3569] Remove LyShine global interface pointer from legacy global environment + { + return gEnv->pLyShine->LoadTexture(pathName); + } + + return nullptr; + } + + //! Given a position and size and an alignment return the top left corner of the aligned quad + static AZ::Vector2 Align(AZ::Vector2 position, AZ::Vector2 size, IDraw2d::HAlign horizontalAlignment, IDraw2d::VAlign verticalAlignment) + { + AZ::Vector2 result = AZ::Vector2::CreateZero(); + switch (horizontalAlignment) + { + case IDraw2d::HAlign::Left: + result.SetX(position.GetX()); + break; + case IDraw2d::HAlign::Center: + result.SetX(position.GetX() - size.GetX() * 0.5f); + break; + case IDraw2d::HAlign::Right: + result.SetX(position.GetX() - size.GetX()); + break; + } + + switch (verticalAlignment) + { + case IDraw2d::VAlign::Top: + result.SetY(position.GetY()); + break; + case IDraw2d::VAlign::Center: + result.SetY(position.GetY() - size.GetY() * 0.5f); + break; + case IDraw2d::VAlign::Bottom: + result.SetY(position.GetY() - size.GetY()); + break; + } + + return result; + } + + //! Round the X and Y coordinates of a point using the given rounding policy + template + static T RoundXY(T value, IDraw2d::Rounding roundingType) + { + T result = value; + + switch (roundingType) + { + case IDraw2d::Rounding::None: + // nothing to do + break; + case IDraw2d::Rounding::Nearest: + result.SetX(floor(value.GetX() + 0.5f)); + result.SetY(floor(value.GetY() + 0.5f)); + break; + case IDraw2d::Rounding::Down: + result.SetX(floor(value.GetX())); + result.SetY(floor(value.GetY())); + break; + case IDraw2d::Rounding::Up: + result.SetX(ceil(value.GetX())); + result.SetY(ceil(value.GetY())); + break; + } + + return result; + } + +protected: // attributes + + IDraw2d::ImageOptions m_imageOptions; //!< image options are stored locally and updated by member functions + IDraw2d::TextOptions m_textOptions; //!< text options are stored locally and updated by member functions + IDraw2d* m_draw2d; + bool m_previousDeferCalls; }; diff --git a/Gems/LyShine/Code/Include/LyShine/ILyShine.h b/Gems/LyShine/Code/Include/LyShine/ILyShine.h index 7832497d8c..71ca6ec074 100644 --- a/Gems/LyShine/Code/Include/LyShine/ILyShine.h +++ b/Gems/LyShine/Code/Include/LyShine/ILyShine.h @@ -9,12 +9,18 @@ #include #include +#include class IDraw2d; class ISprite; struct IUiAnimationSystem; class UiEntityContext; +namespace AZ::RPI +{ + class Image; +} + // The following ifdef block is the standard way of creating macros which make exporting // from a DLL simpler. All files within this DLL are compiled with the LYSHINE_EXPORTS // symbol defined in the StdAfx.h. this symbol should not be defined on any project @@ -82,6 +88,9 @@ public: //! Check if a sprite's texture asset exists. The .sprite sidecar file is optional and is not checked virtual bool DoesSpriteTextureAssetExist(const AZStd::string& pathname) = 0; + //! Load an image asset by texture pathname + virtual AZ::Data::Instance LoadTexture(const AZStd::string& pathName) = 0; + //! Perform post-initialization (script system will be available) virtual void PostInit() = 0; diff --git a/Gems/LyShine/Code/Source/Animation/AnimNode.h b/Gems/LyShine/Code/Source/Animation/AnimNode.h index 4d139e99ca..0076276204 100644 --- a/Gems/LyShine/Code/Source/Animation/AnimNode.h +++ b/Gems/LyShine/Code/Source/Animation/AnimNode.h @@ -13,7 +13,6 @@ #include #include "UiAnimationSystem.h" -#include /*! @@ -40,7 +39,7 @@ public: , valueType(_valueType) , flags(_flags) {}; - AZStd::basic_string, AZStd::stateless_allocator> name; // parameter name. + AZStd::string name; // parameter name. CUiAnimParamType paramType; // parameter id. EUiAnimValue valueType; // value type, defines type of track to use for animating this parameter. ESupportedParamFlags flags; // combination of flags from ESupportedParamFlags. diff --git a/Gems/LyShine/Code/Source/Animation/UiAnimationSystem.cpp b/Gems/LyShine/Code/Source/Animation/UiAnimationSystem.cpp index c8818836d6..06e7110fe2 100644 --- a/Gems/LyShine/Code/Source/Animation/UiAnimationSystem.cpp +++ b/Gems/LyShine/Code/Source/Animation/UiAnimationSystem.cpp @@ -14,77 +14,59 @@ #include "UiAnimSerialize.h" #include -#include #include #include -#include #include #include #include ////////////////////////////////////////////////////////////////////////// -namespace -{ - using UiAnimParamSystemString = AZStd::basic_string, AZStd::stateless_allocator>; - template > - using UiAnimSystemOrderedMap = AZStd::map; - template , typename EqualKey = AZStd::equal_to> - using UiAnimSystemUnorderedMap = AZStd::unordered_map; -} // Serialization for anim nodes & param types -#define REGISTER_NODE_TYPE(name) assert(!g_animNodeEnumToStringMap.contains(eUiAnimNodeType_ ## name)); \ - g_animNodeEnumToStringMap[eUiAnimNodeType_ ## name] = AZ_STRINGIZE(name); \ - g_animNodeStringToEnumMap[UiAnimParamSystemString(AZ_STRINGIZE(name))] = eUiAnimNodeType_ ## name; - -#define REGISTER_PARAM_TYPE(name) assert(!g_animParamEnumToStringMap.contains(eUiAnimParamType_ ## name)); \ - g_animParamEnumToStringMap[eUiAnimParamType_ ## name] = AZ_STRINGIZE(name); \ - g_animParamStringToEnumMap[UiAnimParamSystemString(AZ_STRINGIZE(name))] = eUiAnimParamType_ ## name; - -namespace -{ - UiAnimSystemUnorderedMap g_animNodeEnumToStringMap; - UiAnimSystemOrderedMap> g_animNodeStringToEnumMap; - - UiAnimSystemUnorderedMap g_animParamEnumToStringMap; - UiAnimSystemOrderedMap> g_animParamStringToEnumMap; - - // If you get an assert in this function, it means two node types have the same enum value. - void RegisterNodeTypes() - { - REGISTER_NODE_TYPE(Entity) - REGISTER_NODE_TYPE(Director) - REGISTER_NODE_TYPE(Camera) - REGISTER_NODE_TYPE(CVar) - REGISTER_NODE_TYPE(ScriptVar) - REGISTER_NODE_TYPE(Material) - REGISTER_NODE_TYPE(Event) - REGISTER_NODE_TYPE(Group) - REGISTER_NODE_TYPE(Layer) - REGISTER_NODE_TYPE(Comment) - REGISTER_NODE_TYPE(RadialBlur) - REGISTER_NODE_TYPE(ColorCorrection) - REGISTER_NODE_TYPE(DepthOfField) - REGISTER_NODE_TYPE(ScreenFader) - REGISTER_NODE_TYPE(Light) - REGISTER_NODE_TYPE(HDRSetup) - REGISTER_NODE_TYPE(ShadowSetup) - REGISTER_NODE_TYPE(Alembic) - REGISTER_NODE_TYPE(GeomCache) - REGISTER_NODE_TYPE(Environment) - REGISTER_NODE_TYPE(ScreenDropsSetup) - REGISTER_NODE_TYPE(AzEntity) - } - - // If you get an assert in this function, it means two param types have the same enum value. - void RegisterParamTypes() - { - REGISTER_PARAM_TYPE(Event) - REGISTER_PARAM_TYPE(Float) - REGISTER_PARAM_TYPE(TrackEvent) - REGISTER_PARAM_TYPE(AzComponentField) - } +#define REGISTER_NODE_TYPE(name) assert(!m_animNodeEnumToStringMap.contains(eUiAnimNodeType_ ## name)); \ + m_animNodeEnumToStringMap[eUiAnimNodeType_ ## name] = AZ_STRINGIZE(name); \ + m_animNodeStringToEnumMap[UiAnimParamSystemString(AZ_STRINGIZE(name))] = eUiAnimNodeType_ ## name; + +#define REGISTER_PARAM_TYPE(name) assert(!m_animParamEnumToStringMap.contains(eUiAnimParamType_ ## name)); \ + m_animParamEnumToStringMap[eUiAnimParamType_ ## name] = AZ_STRINGIZE(name); \ + m_animParamStringToEnumMap[UiAnimParamSystemString(AZ_STRINGIZE(name))] = eUiAnimParamType_ ## name; + + +// If you get an assert in this function, it means two node types have the same enum value. +void UiAnimationSystem::RegisterNodeTypes() +{ + REGISTER_NODE_TYPE(Entity) + REGISTER_NODE_TYPE(Director) + REGISTER_NODE_TYPE(Camera) + REGISTER_NODE_TYPE(CVar) + REGISTER_NODE_TYPE(ScriptVar) + REGISTER_NODE_TYPE(Material) + REGISTER_NODE_TYPE(Event) + REGISTER_NODE_TYPE(Group) + REGISTER_NODE_TYPE(Layer) + REGISTER_NODE_TYPE(Comment) + REGISTER_NODE_TYPE(RadialBlur) + REGISTER_NODE_TYPE(ColorCorrection) + REGISTER_NODE_TYPE(DepthOfField) + REGISTER_NODE_TYPE(ScreenFader) + REGISTER_NODE_TYPE(Light) + REGISTER_NODE_TYPE(HDRSetup) + REGISTER_NODE_TYPE(ShadowSetup) + REGISTER_NODE_TYPE(Alembic) + REGISTER_NODE_TYPE(GeomCache) + REGISTER_NODE_TYPE(Environment) + REGISTER_NODE_TYPE(ScreenDropsSetup) + REGISTER_NODE_TYPE(AzEntity) +} + +// If you get an assert in this function, it means two param types have the same enum value. +void UiAnimationSystem::RegisterParamTypes() +{ + REGISTER_PARAM_TYPE(Event) + REGISTER_PARAM_TYPE(Float) + REGISTER_PARAM_TYPE(TrackEvent) + REGISTER_PARAM_TYPE(AzComponentField) } ////////////////////////////////////////////////////////////////////////// @@ -98,6 +80,10 @@ UiAnimationSystem::UiAnimationSystem() m_lastUpdateTime = AZ::Time::ZeroTimeUs; m_nextSequenceId = 1; + + DoNodeStaticInitialisation(); + RegisterNodeTypes(); + RegisterParamTypes(); } ////////////////////////////////////////////////////////////////////////// @@ -1173,16 +1159,16 @@ void UiAnimationSystem::SerializeNodeType(EUiAnimNodeType& animNodeType, XmlNode XmlString nodeTypeString; if (xmlNode->getAttr(kType, nodeTypeString)) { - assert(g_animNodeStringToEnumMap.find(nodeTypeString.c_str()) != g_animNodeStringToEnumMap.end()); - animNodeType = stl::find_in_map(g_animNodeStringToEnumMap, nodeTypeString.c_str(), eUiAnimNodeType_Invalid); + assert(m_animNodeStringToEnumMap.contains(nodeTypeString.c_str())); + animNodeType = stl::find_in_map(m_animNodeStringToEnumMap, nodeTypeString.c_str(), eUiAnimNodeType_Invalid); } } } else { const char* pTypeString = "Invalid"; - assert(g_animNodeEnumToStringMap.find(animNodeType) != g_animNodeEnumToStringMap.end()); - pTypeString = g_animNodeEnumToStringMap[animNodeType].c_str(); + assert(m_animNodeEnumToStringMap.find(animNodeType) != m_animNodeEnumToStringMap.end()); + pTypeString = m_animNodeEnumToStringMap[animNodeType].c_str(); xmlNode->setAttr(kType, pTypeString); } } @@ -1242,8 +1228,8 @@ void UiAnimationSystem::SerializeParamType(CUiAnimParamType& animParamType, XmlN } else { - assert(g_animParamStringToEnumMap.find(paramTypeString.c_str()) != g_animParamStringToEnumMap.end()); - animParamType.m_type = stl::find_in_map(g_animParamStringToEnumMap, paramTypeString.c_str(), eUiAnimParamType_Invalid); + assert(m_animParamStringToEnumMap.contains(paramTypeString.c_str())); + animParamType.m_type = stl::find_in_map(m_animParamStringToEnumMap, paramTypeString.c_str(), eUiAnimParamType_Invalid); } } } @@ -1265,8 +1251,8 @@ void UiAnimationSystem::SerializeParamType(CUiAnimParamType& animParamType, XmlN } else { - assert(g_animParamEnumToStringMap.find(animParamType.m_type) != g_animParamEnumToStringMap.end()); - pTypeString = g_animParamEnumToStringMap[animParamType.m_type].c_str(); + assert(m_animParamEnumToStringMap.find(animParamType.m_type) != m_animParamEnumToStringMap.end()); + pTypeString = m_animParamEnumToStringMap[animParamType.m_type].c_str(); } xmlNode->setAttr(kParamType, pTypeString); @@ -1332,9 +1318,9 @@ const char* UiAnimationSystem::GetParamTypeName(const CUiAnimParamType& animPara } else { - if (g_animParamEnumToStringMap.find(animParamType.m_type) != g_animParamEnumToStringMap.end()) + if (m_animParamEnumToStringMap.find(animParamType.m_type) != m_animParamEnumToStringMap.end()) { - return g_animParamEnumToStringMap[animParamType.m_type].c_str(); + return m_animParamEnumToStringMap[animParamType.m_type].c_str(); } } @@ -1346,15 +1332,6 @@ void UiAnimationSystem::OnCameraCut() { } -////////////////////////////////////////////////////////////////////////// -void UiAnimationSystem::StaticInitialize() -{ - DoNodeStaticInitialisation(); - - RegisterNodeTypes(); - RegisterParamTypes(); -} - ////////////////////////////////////////////////////////////////////////// void UiAnimationSystem::Reflect(AZ::SerializeContext* serializeContext) { @@ -1380,13 +1357,13 @@ void UiAnimationSystem::Reflect(AZ::SerializeContext* serializeContext) ////////////////////////////////////////////////////////////////////////// EUiAnimNodeType UiAnimationSystem::GetNodeTypeFromString(const char* pString) const { - return stl::find_in_map(g_animNodeStringToEnumMap, pString, eUiAnimNodeType_Invalid); + return stl::find_in_map(m_animNodeStringToEnumMap, pString, eUiAnimNodeType_Invalid); } ////////////////////////////////////////////////////////////////////////// CUiAnimParamType UiAnimationSystem::GetParamTypeFromString(const char* pString) const { - const EUiAnimParamType paramType = stl::find_in_map(g_animParamStringToEnumMap, pString, eUiAnimParamType_Invalid); + const EUiAnimParamType paramType = stl::find_in_map(m_animParamStringToEnumMap, pString, eUiAnimParamType_Invalid); if (paramType != eUiAnimParamType_Invalid) { diff --git a/Gems/LyShine/Code/Source/Animation/UiAnimationSystem.h b/Gems/LyShine/Code/Source/Animation/UiAnimationSystem.h index cd51cd51d0..6c710205fa 100644 --- a/Gems/LyShine/Code/Source/Animation/UiAnimationSystem.h +++ b/Gems/LyShine/Code/Source/Animation/UiAnimationSystem.h @@ -14,6 +14,8 @@ #include #include +#include + struct PlayingUIAnimSequence { //! Sequence playing @@ -134,12 +136,10 @@ public: void SerializeParamType(CUiAnimParamType& animParamType, XmlNodeRef& xmlNode, bool bLoading, const uint version) override; void SerializeParamData(UiAnimParamData& animParamData, XmlNodeRef& xmlNode, bool bLoading) override; - static const char* GetParamTypeName(const CUiAnimParamType& animParamType); + const char* GetParamTypeName(const CUiAnimParamType& animParamType); void OnCameraCut(); - static void StaticInitialize(); - static void Reflect(AZ::SerializeContext* serializeContext); void NotifyTrackEventListeners(const char* eventName, const char* valueName, IUiAnimSequence* pSequence) override; @@ -187,5 +187,21 @@ private: // A sequence which turned on the early animation update last time uint32 m_nextSequenceId; + + using UiAnimParamSystemString = AZStd::string; + template > + using UiAnimSystemOrderedMap = AZStd::map; + template , typename EqualKey = AZStd::equal_to<>> + using UiAnimSystemUnorderedMap = AZStd::unordered_map; + + UiAnimSystemUnorderedMap m_animNodeEnumToStringMap; + UiAnimSystemOrderedMap m_animNodeStringToEnumMap; + + UiAnimSystemUnorderedMap m_animParamEnumToStringMap; + UiAnimSystemOrderedMap m_animParamStringToEnumMap; + + void RegisterNodeTypes(); + void RegisterParamTypes(); + void ShowPlayedSequencesDebug(); }; diff --git a/Gems/LyShine/Code/Source/Draw2d.cpp b/Gems/LyShine/Code/Source/Draw2d.cpp index f2c7c360d2..ff8c7f1c6d 100644 --- a/Gems/LyShine/Code/Source/Draw2d.cpp +++ b/Gems/LyShine/Code/Source/Draw2d.cpp @@ -6,7 +6,7 @@ * */ -#include +#include "Draw2d.h" #include #include "LyShinePassDataBus.h" @@ -103,10 +103,7 @@ void CDraw2d::OnBootstrapSceneReady(AZ::RPI::Scene* bootstrapScene) LyShinePassRequestBus::EventResult(uiCanvasPass, sceneId, &LyShinePassRequestBus::Events::GetUiCanvasPass); m_dynamicDraw = AZ::RPI::DynamicDrawInterface::Get()->CreateDynamicDrawContext(); - AZ::RPI::ShaderOptionList shaderOptions; - shaderOptions.push_back(AZ::RPI::ShaderOption(AZ::Name("o_useColorChannels"), AZ::Name("true"))); - shaderOptions.push_back(AZ::RPI::ShaderOption(AZ::Name("o_clamp"), AZ::Name("false"))); - m_dynamicDraw->InitShaderWithVariant(shader, &shaderOptions); + m_dynamicDraw->InitShader(shader); m_dynamicDraw->InitVertexFormat( { {"POSITION", AZ::RHI::Format::R32G32B32_FLOAT}, {"COLOR", AZ::RHI::Format::B8G8R8A8_UNORM}, @@ -125,17 +122,34 @@ void CDraw2d::OnBootstrapSceneReady(AZ::RPI::Scene* bootstrapScene) } m_dynamicDraw->EndInit(); - // Cache draw srg input indices for later use - static const char textureIndexName[] = "m_texture"; - static const char worldToProjIndexName[] = "m_worldToProj"; - AZ::Data::Instance drawSrg = m_dynamicDraw->NewDrawSrg(); - const AZ::RHI::ShaderResourceGroupLayout* layout = drawSrg->GetLayout(); - m_shaderData.m_imageInputIndex = layout->FindShaderInputImageIndex(AZ::Name(textureIndexName)); - AZ_Error("Draw2d", m_shaderData.m_imageInputIndex.IsValid(), "Failed to find shader input constant %s.", - textureIndexName); - m_shaderData.m_viewProjInputIndex = layout->FindShaderInputConstantIndex(AZ::Name(worldToProjIndexName)); - AZ_Error("Draw2d", m_shaderData.m_viewProjInputIndex.IsValid(), "Failed to find shader input constant %s.", - worldToProjIndexName); + // Check that the dynamic draw context has been initialized appropriately + if (m_dynamicDraw->IsReady()) + { + // Cache draw srg input indices for later use + static const char textureIndexName[] = "m_texture"; + static const char worldToProjIndexName[] = "m_worldToProj"; + AZ::Data::Instance drawSrg = m_dynamicDraw->NewDrawSrg(); + if (drawSrg) + { + const AZ::RHI::ShaderResourceGroupLayout* layout = drawSrg->GetLayout(); + m_shaderData.m_imageInputIndex = layout->FindShaderInputImageIndex(AZ::Name(textureIndexName)); + AZ_Error("Draw2d", m_shaderData.m_imageInputIndex.IsValid(), "Failed to find shader input constant %s.", + textureIndexName); + m_shaderData.m_viewProjInputIndex = layout->FindShaderInputConstantIndex(AZ::Name(worldToProjIndexName)); + AZ_Error("Draw2d", m_shaderData.m_viewProjInputIndex.IsValid(), "Failed to find shader input constant %s.", + worldToProjIndexName); + } + + // Cache shader variants that will be used + AZ::RPI::ShaderOptionList shaderOptionsClamp; + shaderOptionsClamp.push_back(AZ::RPI::ShaderOption(AZ::Name("o_clamp"), AZ::Name("true"))); + shaderOptionsClamp.push_back(AZ::RPI::ShaderOption(AZ::Name("o_useColorChannels"), AZ::Name("true"))); + m_shaderData.m_shaderOptionsClamp = m_dynamicDraw->UseShaderVariant(shaderOptionsClamp); + AZ::RPI::ShaderOptionList shaderOptionsWrap; + shaderOptionsWrap.push_back(AZ::RPI::ShaderOption(AZ::Name("o_clamp"), AZ::Name("false"))); + shaderOptionsWrap.push_back(AZ::RPI::ShaderOption(AZ::Name("o_useColorChannels"), AZ::Name("true"))); + m_shaderData.m_shaderOptionsWrap = m_dynamicDraw->UseShaderVariant(shaderOptionsWrap); + } } //////////////////////////////////////////////////////////////////////////////////////////////////// @@ -181,6 +195,8 @@ void CDraw2d::DrawImage(AZ::Data::Instance image, AZ::Vector2 po quad.m_image = image; + quad.m_clamp = actualImageOptions->m_clamp; + // add the blendMode flags to the base state quad.m_renderState = actualImageOptions->m_renderState; @@ -199,14 +215,14 @@ void CDraw2d::DrawImageAligned(AZ::Data::Instance image, AZ::Vec HAlign horizontalAlignment, VAlign verticalAlignment, float opacity, float rotation, const AZ::Vector2* minMaxTexCoords, ImageOptions* imageOptions) { - AZ::Vector2 alignedPosition = Align(position, size, horizontalAlignment, verticalAlignment); + AZ::Vector2 alignedPosition = Draw2dHelper::Align(position, size, horizontalAlignment, verticalAlignment); DrawImage(image, alignedPosition, size, opacity, rotation, &position, minMaxTexCoords, imageOptions); } //////////////////////////////////////////////////////////////////////////////////////////////////// void CDraw2d::DrawQuad(AZ::Data::Instance image, VertexPosColUV* verts, Rounding pixelRounding, - const CDraw2d::RenderState& renderState) + bool clamp, const CDraw2d::RenderState& renderState) { // define quad DeferredQuad quad; @@ -217,6 +233,7 @@ void CDraw2d::DrawQuad(AZ::Data::Instance image, VertexPosColUV* quad.m_packedColors[i] = PackARGB8888(verts[i].color); } quad.m_image = image; + quad.m_clamp = clamp; // add the blendMode flags to the base state quad.m_renderState = renderState; @@ -452,6 +469,12 @@ float CDraw2d::GetViewportHeight() const return viewHeight; } +//////////////////////////////////////////////////////////////////////////////////////////////////// +float CDraw2d::GetViewportDpiScalingFactor() const +{ + return GetViewportContext()->GetDpiScalingFactor(); +} + //////////////////////////////////////////////////////////////////////////////////////////////////// const CDraw2d::ImageOptions& CDraw2d::GetDefaultImageOptions() const { @@ -501,40 +524,6 @@ void CDraw2d::SetSortKey(int64_t key) // PUBLIC STATIC FUNCTIONS //////////////////////////////////////////////////////////////////////////////////////////////////// -//////////////////////////////////////////////////////////////////////////////////////////////////// -AZ::Vector2 CDraw2d::Align(AZ::Vector2 position, AZ::Vector2 size, - HAlign horizontalAlignment, VAlign verticalAlignment) -{ - AZ::Vector2 result = AZ::Vector2::CreateZero(); - switch (horizontalAlignment) - { - case HAlign::Left: - result.SetX(position.GetX()); - break; - case HAlign::Center: - result.SetX(position.GetX() - size.GetX() * 0.5f); - break; - case HAlign::Right: - result.SetX(position.GetX() - size.GetX()); - break; - } - - switch (verticalAlignment) - { - case VAlign::Top: - result.SetY(position.GetY()); - break; - case VAlign::Center: - result.SetY(position.GetY() - size.GetY() * 0.5f); - break; - case VAlign::Bottom: - result.SetY(position.GetY() - size.GetY()); - break; - } - - return result; -} - //////////////////////////////////////////////////////////////////////////////////////////////////// AZ::Data::Instance CDraw2d::LoadTexture(const AZStd::string& pathName) { @@ -760,6 +749,8 @@ void CDraw2d::DeferredQuad::Draw(AZ::RHI::Ptr dynam vertices[i].st = Vec2(m_texCoords[j].GetX(), m_texCoords[j].GetY()); } + dynamicDraw->SetShaderVariant(m_clamp ? shaderData.m_shaderOptionsClamp : shaderData.m_shaderOptionsWrap); + // Set up per draw SRG AZ::Data::Instance drawSrg = dynamicDraw->NewDrawSrg(); diff --git a/Gems/LyShine/Code/Include/LyShine/Draw2d.h b/Gems/LyShine/Code/Source/Draw2d.h similarity index 50% rename from Gems/LyShine/Code/Include/LyShine/Draw2d.h rename to Gems/LyShine/Code/Source/Draw2d.h index 8123a834a1..6d400c6b55 100644 --- a/Gems/LyShine/Code/Include/LyShine/Draw2d.h +++ b/Gems/LyShine/Code/Source/Draw2d.h @@ -8,13 +8,10 @@ #pragma once #include -#include -#include #include #include #include -#include #include //////////////////////////////////////////////////////////////////////////////////////////////////// @@ -23,68 +20,11 @@ //! The CDraw2d class implements the IDraw2d interface for drawing 2D images, shapes and text. //! Positions and sizes are specified in pixels in the associated 2D viewport. class CDraw2d - : public IDraw2d // [LYSHINE_ATOM_TODO][GHI #3573] Make Draw2d work better as an API + : public IDraw2d , public AZ::Render::Bootstrap::NotificationBus::Handler { public: // types - struct RenderState - { - RenderState() - { - m_blendState.m_enable = true; - m_blendState.m_blendSource = AZ::RHI::BlendFactor::AlphaSource; - m_blendState.m_blendDest = AZ::RHI::BlendFactor::AlphaSourceInverse; - - m_depthState.m_enable = false; - } - - AZ::RHI::TargetBlendState m_blendState; - AZ::RHI::DepthState m_depthState; - }; - - //! Struct used to pass additional image options. - // - //! If this is not passed then the defaults are used - struct ImageOptions - { - AZ::Vector3 color = AZ::Vector3(1.0f, 1.0f, 1.0f); - Rounding pixelRounding = Rounding::Nearest; - RenderState m_renderState; - }; - - //! Struct used to pass additional text options - mostly ones that do not change from call to call. - // - //! If this is not passed then the defaults below are used - struct TextOptions - { - AZStd::string fontName; //!< default is "default" - unsigned int effectIndex; //!< default is 0 - AZ::Vector3 color; //!< default is (1,1,1) - HAlign horizontalAlignment; //!< default is HAlign::Left - VAlign verticalAlignment; //!< default is VAlign::Top - AZ::Vector2 dropShadowOffset; //!< default is (0,0), zero offset means no drop shadow is drawn - AZ::Color dropShadowColor; //!< default is (0,0,0,0), zero alpha means no drop shadow is drawn - float rotation; //!< default is 0 - bool depthTestEnabled; //!< default is false - }; - - //! Used to pass in arrays of vertices (e.g. to DrawQuad) - struct VertexPosColUV - { - VertexPosColUV() {} - VertexPosColUV(const AZ::Vector2& inPos, const AZ::Color& inColor, const AZ::Vector2& inUV) - { - position = inPos; - color = inColor; - uv = inUV; - } - - AZ::Vector2 position; //!< 2D position of vertex - AZ::Color color; //!< Float color - AZ::Vector2 uv; //!< Texture coordinate - }; - public: // member functions //! Constructor, constructed by the LyShine class @@ -115,7 +55,7 @@ public: // member functions //! \param imageOptions Optional struct specifying options that tend to be the same from call to call void DrawImage(AZ::Data::Instance image, AZ::Vector2 position, AZ::Vector2 size, float opacity = 1.0f, float rotation = 0.0f, const AZ::Vector2* pivotPoint = nullptr, const AZ::Vector2* minMaxTexCoords = nullptr, - ImageOptions* imageOptions = nullptr); + ImageOptions* imageOptions = nullptr) override; //! Draw a textured quad where the position specifies the point specified by the alignment. // @@ -134,7 +74,7 @@ public: // member functions void DrawImageAligned(AZ::Data::Instance image, AZ::Vector2 position, AZ::Vector2 size, HAlign horizontalAlignment, VAlign verticalAlignment, float opacity = 1.0f, float rotation = 0.0f, const AZ::Vector2* minMaxTexCoords = nullptr, - ImageOptions* imageOptions = nullptr); + ImageOptions* imageOptions = nullptr) override; //! Draw a textured quad where the position, color and uv of each point is specified explicitly // @@ -142,10 +82,11 @@ public: // member functions //! \param verts An array of 4 vertices, in clockwise order (e.g. top left, top right, bottom right, bottom left) //! \param pixelRounding Whether and how to round pixel coordinates //! \param renderState Blend mode and depth state - virtual void DrawQuad(AZ::Data::Instance image, + void DrawQuad(AZ::Data::Instance image, VertexPosColUV* verts, Rounding pixelRounding = Rounding::Nearest, - const RenderState& renderState = RenderState{}); + bool clamp = false, + const RenderState& renderState = RenderState{}) override; //! Draw a line // @@ -154,9 +95,9 @@ public: // member functions //! \param color The color of the line //! \param pixelRounding Whether and how to round pixel coordinates //! \param renderState Blend mode and depth state - virtual void DrawLine(AZ::Vector2 start, AZ::Vector2 end, AZ::Color color, + void DrawLine(AZ::Vector2 start, AZ::Vector2 end, AZ::Color color, IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, - const RenderState& renderState = RenderState{}); + const RenderState& renderState = RenderState{}) override; //! Draw a line with a texture so it can be dotted or dashed // @@ -164,10 +105,10 @@ public: // member functions //! \param verts An array of 2 vertices for the start and end points of the line //! \param pixelRounding Whether and how to round pixel coordinates //! \param renderState Blend mode and depth state - virtual void DrawLineTextured(AZ::Data::Instance image, + void DrawLineTextured(AZ::Data::Instance image, VertexPosColUV* verts, IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, - const RenderState& renderState = RenderState{}); + const RenderState& renderState = RenderState{}) override; //! Draw a text string. Only supports ASCII text. // //! The font and effect used to render the text are specified in the textOptions structure @@ -177,7 +118,7 @@ public: // member functions //! \param opacity The opacity (alpha value) to use to draw the text //! \param textOptions Pointer to an options struct. If null the default options are used void DrawText(const char* textString, AZ::Vector2 position, float pointSize, - float opacity = 1.0f, TextOptions* textOptions = nullptr); + float opacity = 1.0f, TextOptions* textOptions = nullptr) override; //! Draw a rectangular outline with a texture // @@ -192,40 +133,43 @@ public: // member functions AZ::Vector2 rightVec, AZ::Vector2 downVec, AZ::Color color, - uint32_t lineThickness = 0); + uint32_t lineThickness = 0) override; //! Get the width and height (in pixels) that would be used to draw the given text string. // //! Pass the same parameter values that would be used to draw the string - AZ::Vector2 GetTextSize(const char* textString, float pointSize, TextOptions* textOptions = nullptr); + AZ::Vector2 GetTextSize(const char* textString, float pointSize, TextOptions* textOptions = nullptr) override; //! Get the width of the rendering viewport (in pixels). - float GetViewportWidth() const; + float GetViewportWidth() const override; //! Get the height of the rendering viewport (in pixels). - float GetViewportHeight() const; + float GetViewportHeight() const override; + + //! Get dpi scale factor + float GetViewportDpiScalingFactor() const override; //! Get the default values that would be used if no image options were passed in // //! This is a convenient way to initialize the imageOptions struct - virtual const ImageOptions& GetDefaultImageOptions() const; + const ImageOptions& GetDefaultImageOptions() const override; //! Get the default values that would be used if no text options were passed in // //! This is a convenient way to initialize the textOptions struct - virtual const TextOptions& GetDefaultTextOptions() const; + const TextOptions& GetDefaultTextOptions() const override; //! Render the primitives that have been deferred - void RenderDeferredPrimitives(); + void RenderDeferredPrimitives() override; //! Specify whether to defer future primitives or render them right away - void SetDeferPrimitives(bool deferPrimitives); + void SetDeferPrimitives(bool deferPrimitives) override; //! Return whether future primitives will be deferred or rendered right away - bool GetDeferPrimitives(); + bool GetDeferPrimitives() override; //! Set sort key offset for following draws. - void SetSortKey(int64_t key); + void SetSortKey(int64_t key) override; private: @@ -236,9 +180,6 @@ private: public: // static member functions - //! Given a position and size and an alignment return the top left corner of the aligned quad - static AZ::Vector2 Align(AZ::Vector2 position, AZ::Vector2 size, HAlign horizontalAlignment, VAlign verticalAlignment); - //! Helper to load a texture static AZ::Data::Instance LoadTexture(const AZStd::string& pathName); @@ -254,6 +195,8 @@ protected: // types and constants { AZ::RHI::ShaderInputImageIndex m_imageInputIndex; AZ::RHI::ShaderInputConstantIndex m_viewProjInputIndex; + AZ::RPI::ShaderVariantId m_shaderOptionsClamp; + AZ::RPI::ShaderVariantId m_shaderOptionsWrap; }; class DeferredPrimitive @@ -278,6 +221,7 @@ protected: // types and constants AZ::Vector2 m_texCoords[4]; uint32 m_packedColors[4]; AZ::Data::Instance m_image; + bool m_clamp; RenderState m_renderState; }; @@ -370,259 +314,3 @@ protected: // attributes AZ::RHI::Ptr m_dynamicDraw; Draw2dShaderData m_shaderData; }; - -//////////////////////////////////////////////////////////////////////////////////////////////////// -//! Helper class for using the IDraw2d interface -//! -//! The Draw2dHelper class is an inline wrapper that provides the convenience feature of -//! automatically setting member options structures to their defaults and providing set functions. -class Draw2dHelper -{ -public: // member functions - - //! Start a section of 2D drawing function calls that will render to the default viewport - Draw2dHelper(bool deferCalls = false) - { - InitCommon(nullptr, deferCalls); - } - - //! Start a section of 2D drawing function calls that will render to the viewport - //! associated with the specified Draw2d object - Draw2dHelper(CDraw2d* draw2d, bool deferCalls = false) - { - InitCommon(draw2d, deferCalls); - } - - void InitCommon(CDraw2d* draw2d, bool deferCalls) - { - m_draw2d = draw2d; - - if (!m_draw2d) - { - // Set to default which is the game's draw 2d object - m_draw2d = GetDefaultDraw2d(); - } - - if (m_draw2d) - { - m_previousDeferCalls = m_draw2d->GetDeferPrimitives(); - m_draw2d->SetDeferPrimitives(deferCalls); - m_imageOptions = m_draw2d->GetDefaultImageOptions(); - m_textOptions = m_draw2d->GetDefaultTextOptions(); - } - } - - //! End a section of 2D drawing function calls. - ~Draw2dHelper() - { - if (m_draw2d) - { - m_draw2d->SetDeferPrimitives(m_previousDeferCalls); - } - } - - //! Draw a textured quad, optional rotation is counter-clockwise in degrees. - // - //! See IDraw2d:DrawImage for parameter descriptions - void DrawImage(AZ::Data::Instance image, AZ::Vector2 position, AZ::Vector2 size, float opacity = 1.0f, - float rotation = 0.0f, const AZ::Vector2* pivotPoint = nullptr, const AZ::Vector2* minMaxTexCoords = nullptr) - { - if (m_draw2d) - { - m_draw2d->DrawImage(image, position, size, opacity, rotation, pivotPoint, minMaxTexCoords, &m_imageOptions); - } - } - - //! Draw a textured quad where the position specifies the point specified by the alignment. - // - //! See IDraw2d:DrawImageAligned for parameter descriptions - void DrawImageAligned(AZ::Data::Instance image, AZ::Vector2 position, AZ::Vector2 size, - IDraw2d::HAlign horizontalAlignment, IDraw2d::VAlign verticalAlignment, - float opacity = 1.0f, float rotation = 0.0f, const AZ::Vector2* minMaxTexCoords = nullptr) - { - if (m_draw2d) - { - m_draw2d->DrawImageAligned(image, position, size, horizontalAlignment, verticalAlignment, - opacity, rotation, minMaxTexCoords, &m_imageOptions); - } - } - - //! Draw a textured quad where the position, color and uv of each point is specified explicitly - // - //! See IDraw2d:DrawQuad for parameter descriptions - void DrawQuad(AZ::Data::Instance image, CDraw2d::VertexPosColUV* verts, - IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, - const CDraw2d::RenderState& renderState = CDraw2d::RenderState{}) - { - if (m_draw2d) - { - m_draw2d->DrawQuad(image, verts, pixelRounding, renderState); - } - } - - //! Draw a line - // - //! See IDraw2d:DrawLine for parameter descriptions - void DrawLine(AZ::Vector2 start, AZ::Vector2 end, AZ::Color color, - IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, - const CDraw2d::RenderState& renderState = CDraw2d::RenderState{}) - { - if (m_draw2d) - { - m_draw2d->DrawLine(start, end, color, pixelRounding, renderState); - } - } - - //! Draw a line with a texture so it can be dotted or dashed - // - //! See IDraw2d:DrawLineTextured for parameter descriptions - void DrawLineTextured(AZ::Data::Instance image, CDraw2d::VertexPosColUV* verts, - IDraw2d::Rounding pixelRounding = IDraw2d::Rounding::Nearest, - const CDraw2d::RenderState& renderState = CDraw2d::RenderState{}) - { - if (m_draw2d) - { - m_draw2d->DrawLineTextured(image, verts, pixelRounding, renderState); - } - } - - //! Draw a rect outline with a texture - // - //! See IDraw2d:DrawRectOutlineTextured for parameter descriptions - void DrawRectOutlineTextured(AZ::Data::Instance image, - UiTransformInterface::RectPoints points, - AZ::Vector2 rightVec, - AZ::Vector2 downVec, - AZ::Color color, - uint32_t lineThickness = 0) - { - if (m_draw2d) - { - m_draw2d->DrawRectOutlineTextured(image, points, rightVec, downVec, color, lineThickness); - } - } - - //! Draw a text string. Only supports ASCII text. - // - //! See IDraw2d:DrawText for parameter descriptions - void DrawText(const char* textString, AZ::Vector2 position, float pointSize, float opacity = 1.0f) - { - if (m_draw2d) - { - m_draw2d->DrawText(textString, position, pointSize, opacity, &m_textOptions); - } - } - - //! Get the width and height (in pixels) that would be used to draw the given text string. - // - //! See IDraw2d:GetTextSize for parameter descriptions - AZ::Vector2 GetTextSize(const char* textString, float pointSize) - { - if (m_draw2d) - { - return m_draw2d->GetTextSize(textString, pointSize, &m_textOptions); - } - else - { - return AZ::Vector2(0, 0); - } - } - - // State management - - //! Set the blend mode used for images, default is GS_BLSRC_SRCALPHA|GS_BLDST_ONEMINUSSRCALPHA. - void SetImageBlendMode(const AZ::RHI::TargetBlendState& blendState) { m_imageOptions.m_renderState.m_blendState = blendState; } - - //! Set the color used for DrawImage and other image drawing. - void SetImageColor(AZ::Vector3 color) { m_imageOptions.color = color; } - - //! Set whether images are rounded to have the points on exact pixel boundaries. - void SetImagePixelRounding(IDraw2d::Rounding round) { m_imageOptions.pixelRounding = round; } - - //! Set the base state (that blend mode etc is combined with) used for images, default is GS_NODEPTHTEST. - void SetImageDepthState(const AZ::RHI::DepthState& depthState) { m_imageOptions.m_renderState.m_depthState = depthState; } - - //! Set the text font. - void SetTextFont(AZStd::string_view fontName) { m_textOptions.fontName = fontName; } - - //! Set the text font effect index. - void SetTextEffectIndex(unsigned int effectIndex) { m_textOptions.effectIndex = effectIndex; } - - //! Set the text color. - void SetTextColor(AZ::Vector3 color) { m_textOptions.color = color; } - - //! Set the text alignment. - void SetTextAlignment(IDraw2d::HAlign horizontalAlignment, IDraw2d::VAlign verticalAlignment) - { - m_textOptions.horizontalAlignment = horizontalAlignment; - m_textOptions.verticalAlignment = verticalAlignment; - } - - //! Set a drop shadow for text drawing. An alpha of zero disables drop shadow. - void SetTextDropShadow(AZ::Vector2 offset, AZ::Color color) - { - m_textOptions.dropShadowOffset = offset; - m_textOptions.dropShadowColor = color; - } - - //! Set a rotation for the text. The text rotates around its position (taking into account alignment). - void SetTextRotation(float rotation) - { - m_textOptions.rotation = rotation; - } - - //! Set wheter to enable depth test for the text - void SetTextDepthTestEnabled(bool enabled) - { - m_textOptions.depthTestEnabled = enabled; - } - -public: // static member functions - - //! Helper to get the default IDraw2d interface - static CDraw2d* GetDefaultDraw2d() - { - if (gEnv && gEnv->pLyShine) // [LYSHINE_ATOM_TODO][GHI #3569] Remove LyShine global interface pointer from legacy global environment - { - IDraw2d* draw2d = gEnv->pLyShine->GetDraw2d(); - return reinterpret_cast(draw2d); - } - - return nullptr; - } - - //! Round the X and Y coordinates of a point using the given rounding policy - template - static T RoundXY(T value, IDraw2d::Rounding roundingType) - { - T result = value; - - switch (roundingType) - { - case IDraw2d::Rounding::None: - // nothing to do - break; - case IDraw2d::Rounding::Nearest: - result.SetX(floor(value.GetX() + 0.5f)); - result.SetY(floor(value.GetY() + 0.5f)); - break; - case IDraw2d::Rounding::Down: - result.SetX(floor(value.GetX())); - result.SetY(floor(value.GetY())); - break; - case IDraw2d::Rounding::Up: - result.SetX(ceil(value.GetX())); - result.SetY(ceil(value.GetY())); - break; - } - - return result; - } - -protected: // attributes - - CDraw2d::ImageOptions m_imageOptions; //!< image options are stored locally and updated by member functions - CDraw2d::TextOptions m_textOptions; //!< text options are stored locally and updated by member functions - CDraw2d* m_draw2d; - bool m_previousDeferCalls; -}; diff --git a/Gems/LyShine/Code/Source/LyShine.cpp b/Gems/LyShine/Code/Source/LyShine.cpp index d19bc3f92d..b362ed2106 100644 --- a/Gems/LyShine/Code/Source/LyShine.cpp +++ b/Gems/LyShine/Code/Source/LyShine.cpp @@ -43,11 +43,11 @@ #include "Sprite.h" #include "UiSerialize.h" #include "UiRenderer.h" +#include "Draw2d.h" #include #include #include -#include #if defined(LYSHINE_INTERNAL_UNIT_TEST) #include "TextMarkup.h" @@ -156,8 +156,6 @@ CLyShine::CLyShine([[maybe_unused]] ISystem* system) UiElementComponent::Initialize(); UiCanvasComponent::Initialize(); - UiAnimationSystem::StaticInitialize(); - AzFramework::InputChannelEventListener::Connect(); AzFramework::InputTextEventListener::Connect(); UiCursorBus::Handler::BusConnect(); @@ -355,6 +353,12 @@ bool CLyShine::DoesSpriteTextureAssetExist(const AZStd::string& pathname) return CSprite::DoesSpriteTextureAssetExist(pathname); } +//////////////////////////////////////////////////////////////////////////////////////////////////// +AZ::Data::Instance CLyShine::LoadTexture(const AZStd::string& pathname) +{ + return CDraw2d::LoadTexture(pathname); +} + //////////////////////////////////////////////////////////////////////////////////////////////////// void CLyShine::PostInit() { @@ -668,7 +672,7 @@ void CLyShine::LoadUiCursor() { if (!m_cursorImagePathToLoad.empty()) { - m_uiCursorTexture = CDraw2d::LoadTexture(m_cursorImagePathToLoad); // LYSHINE_ATOM_TODO - add clamp option to draw2d and set cursor to clamp + m_uiCursorTexture = CDraw2d::LoadTexture(m_cursorImagePathToLoad); m_cursorImagePathToLoad.clear(); } } @@ -691,7 +695,13 @@ void CLyShine::RenderUiCursor() AZ::RHI::Size cursorSize = m_uiCursorTexture->GetDescriptor().m_size; const AZ::Vector2 dimensions(aznumeric_cast(cursorSize.m_width), aznumeric_cast(cursorSize.m_height)); - m_draw2d->DrawImage(m_uiCursorTexture, position, dimensions); + IDraw2d::ImageOptions imageOptions; + imageOptions.m_clamp = true; + const float opacity = 1.0f; + const float rotation = 0.0f; + const AZ::Vector2* pivotPoint = nullptr; + const AZ::Vector2* minMaxTexCoords = nullptr; + m_draw2d->DrawImage(m_uiCursorTexture, position, dimensions, opacity, rotation, pivotPoint, minMaxTexCoords, &imageOptions); } #ifndef _RELEASE diff --git a/Gems/LyShine/Code/Source/LyShine.h b/Gems/LyShine/Code/Source/LyShine.h index 82f902a9f8..eab52258c1 100644 --- a/Gems/LyShine/Code/Source/LyShine.h +++ b/Gems/LyShine/Code/Source/LyShine.h @@ -72,6 +72,7 @@ public: ISprite* LoadSprite(const AZStd::string& pathname) override; ISprite* CreateSprite(const AZStd::string& renderTargetName) override; bool DoesSpriteTextureAssetExist(const AZStd::string& pathname) override; + AZ::Data::Instance LoadTexture(const AZStd::string& pathname) override; void PostInit() override; diff --git a/Gems/LyShine/Code/Source/LyShineDebug.cpp b/Gems/LyShine/Code/Source/LyShineDebug.cpp index 7762b1403b..7e99652f45 100644 --- a/Gems/LyShine/Code/Source/LyShineDebug.cpp +++ b/Gems/LyShine/Code/Source/LyShineDebug.cpp @@ -7,7 +7,7 @@ */ #include "LyShineDebug.h" #include "IConsole.h" -#include +#include #include @@ -375,9 +375,9 @@ static void DebugDrawColoredBox(AZ::Vector2 pos, AZ::Vector2 size, AZ::Color col IDraw2d::HAlign horizontalAlignment = IDraw2d::HAlign::Left, IDraw2d::VAlign verticalAlignment = IDraw2d::VAlign::Top) { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); - CDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); + IDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); imageOptions.color = color.GetAsVector3(); auto whiteTexture = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::White); draw2d->DrawImageAligned(whiteTexture, pos, size, horizontalAlignment, verticalAlignment, @@ -390,9 +390,9 @@ static void DebugDrawColoredBox(AZ::Vector2 pos, AZ::Vector2 size, AZ::Color col static void DebugDrawStringWithSizeBox(AZStd::string_view font, unsigned int effectIndex, const char* sizeString, const char* testString, AZ::Vector2 pos, float spacing, float size) { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); - CDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); + IDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); if (!font.empty()) { textOptions.fontName = font; @@ -424,7 +424,7 @@ static void DebugDrawStringWithSizeBox(AZStd::string_view font, unsigned int eff #if !defined(_RELEASE) static void DebugDraw2dFontSizes(AZStd::string_view font, unsigned int effectIndex) { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); float xOffset = 20.0f; float yOffset = 20.0f; @@ -546,7 +546,7 @@ static void DebugDrawAlignedTextWithOriginBox(AZ::Vector2 pos, #if !defined(_RELEASE) static void DebugDraw2dFontAlignment() { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); float w = draw2d->GetViewportWidth(); float yPos = 20; @@ -613,12 +613,12 @@ static void DebugDraw2dFontAlignment() #if !defined(_RELEASE) static AZ::Vector2 DebugDrawFontColorTestBox(AZ::Vector2 pos, const char* string, AZ::Vector3 color, float opacity) { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); float pointSize = 32.0f; const float spacing = 6.0f; - CDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); + IDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); textOptions.effectIndex = 1; // no drop shadow baked in textOptions.color = color; @@ -648,7 +648,7 @@ static AZ::Vector2 DebugDrawFontColorTestBox(AZ::Vector2 pos, const char* string #if !defined(_RELEASE) static void DebugDraw2dFontColorAndOpacity() { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); AZ::Vector2 size; AZ::Vector2 pos(20.0f, 20.0f); @@ -686,7 +686,7 @@ static void DebugDraw2dFontColorAndOpacity() #if !defined(_RELEASE) static void DebugDraw2dImageRotations() { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); AZ::Data::Instance texture = GetMonoTestTexture(); @@ -738,11 +738,11 @@ static void DebugDraw2dImageRotations() #if !defined(_RELEASE) static void DebugDraw2dImageColor() { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); AZ::Data::Instance texture = GetMonoAlphaTestTexture(); - CDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); + IDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); draw2d->DrawText( "Testing image colors, image is black and white, top row is opacity=1, bottom row is opacity = 0.5", @@ -774,13 +774,13 @@ static void DebugDraw2dImageColor() #if !defined(_RELEASE) static void DebugDraw2dImageBlendMode() { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); auto whiteTexture = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::White); AZ::Data::Instance texture = GetColorAlphaTestTexture(); - CDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); + IDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); draw2d->DrawText("Testing blend modes, src blend changes across x-axis, dst blend changes across y axis", AZ::Vector2(20, 20), 16); @@ -801,7 +801,7 @@ static void DebugDraw2dImageBlendMode() AZ::Vector2 pos(xStart + xSpacing * srcIndex, yStart + ySpacing * dstIndex); // first draw a background with varying color and alpha - CDraw2d::VertexPosColUV verts[4] = + IDraw2d::VertexPosColUV verts[4] = { { // top left AZ::Vector2(pos.GetX(), pos.GetY()), @@ -828,7 +828,7 @@ static void DebugDraw2dImageBlendMode() // Draw the image with this color - CDraw2d::RenderState renderState; + IDraw2d::RenderState renderState; renderState.m_blendState.m_blendSource = g_srcBlendModes[srcIndex]; renderState.m_blendState.m_blendDest = g_dstBlendModes[dstIndex]; draw2d->DrawImage(texture, pos, size, 1.0f, 0.0f, 0, 0, &imageOptions); @@ -841,11 +841,11 @@ static void DebugDraw2dImageBlendMode() #if !defined(_RELEASE) static void DebugDraw2dImageUVs() { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); AZ::Data::Instance texture = GetColorTestTexture(); - CDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); + IDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); draw2d->DrawText( "Testing DrawImage with minMaxTexCoords. Full image, top left quadrant, middle section, full flipped", @@ -890,11 +890,11 @@ static void DebugDraw2dImageUVs() #if !defined(_RELEASE) static void DebugDraw2dImagePixelRounding() { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); AZ::Data::Instance texture = GetColorTestTexture(); - CDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); + IDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); draw2d->DrawText("Testing DrawImage pixel rounding options", AZ::Vector2(20, 20), 16); @@ -931,9 +931,9 @@ static void DebugDraw2dImagePixelRounding() #if !defined(_RELEASE) static void DebugDraw2dLineBasic() { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); - CDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); + IDraw2d::ImageOptions imageOptions = draw2d->GetDefaultImageOptions(); draw2d->DrawText("Testing DrawLine", AZ::Vector2(20, 20), 16); @@ -1422,7 +1422,7 @@ void LyShineDebug::RenderDebug() #if !defined(_RELEASE) #ifndef EXCLUDE_DOCUMENTATION_PURPOSE - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); if (!draw2d) { return; diff --git a/Gems/LyShine/Code/Source/RenderGraph.cpp b/Gems/LyShine/Code/Source/RenderGraph.cpp index db17fde601..c05e87bc64 100644 --- a/Gems/LyShine/Code/Source/RenderGraph.cpp +++ b/Gems/LyShine/Code/Source/RenderGraph.cpp @@ -122,14 +122,10 @@ namespace LyShine uint32_t isClampTextureMode = 0; for (int i = 0; i < m_numTextures; ++i) { - const AZ::RHI::ImageView* imageView = m_textures[i].m_texture ? m_textures[i].m_texture->GetImageView() : nullptr; - - if (!imageView) - { - // Default to white texture - auto image = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::White); - imageView = image->GetImageView(); - } + // Default to white texture + const AZ::Data::Instance& image = m_textures[i].m_texture ? m_textures[i].m_texture + : AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::White); + const AZ::RHI::ImageView* imageView = image->GetImageView(); if (imageView) { @@ -138,6 +134,9 @@ namespace LyShine { isClampTextureMode |= (1 << i); } +#ifndef _RELEASE + uiRenderer->DebugUseTexture(image); +#endif } } diff --git a/Gems/LyShine/Code/Source/UiCanvasComponent.cpp b/Gems/LyShine/Code/Source/UiCanvasComponent.cpp index 78b9c71f8e..ea6e3681a3 100644 --- a/Gems/LyShine/Code/Source/UiCanvasComponent.cpp +++ b/Gems/LyShine/Code/Source/UiCanvasComponent.cpp @@ -27,7 +27,7 @@ #include #include #include -#include +#include #include #include @@ -2122,13 +2122,13 @@ void UiCanvasComponent::DebugReportDrawCalls(AZ::IO::HandleType fileHandle, LySh } //////////////////////////////////////////////////////////////////////////////////////////////////// -void UiCanvasComponent::DebugDisplayElemBounds(CDraw2d* draw2d) const +void UiCanvasComponent::DebugDisplayElemBounds(IDraw2d* draw2d) const { DebugDisplayChildElemBounds(draw2d, m_rootElement); } //////////////////////////////////////////////////////////////////////////////////////////////////// -void UiCanvasComponent::DebugDisplayChildElemBounds(CDraw2d* draw2d, const AZ::EntityId entity) const +void UiCanvasComponent::DebugDisplayChildElemBounds(IDraw2d* draw2d, const AZ::EntityId entity) const { AZ::u64 time = AZStd::GetTimeUTCMilliSecond(); uint32 fractionsOfOneSecond = time % 1000; diff --git a/Gems/LyShine/Code/Source/UiCanvasComponent.h b/Gems/LyShine/Code/Source/UiCanvasComponent.h index 79cb044af0..050773131f 100644 --- a/Gems/LyShine/Code/Source/UiCanvasComponent.h +++ b/Gems/LyShine/Code/Source/UiCanvasComponent.h @@ -292,8 +292,8 @@ public: // member functions void DebugReportDrawCalls(AZ::IO::HandleType fileHandle, LyShineDebug::DebugInfoDrawCallReport& reportInfo, void* context) const; - void DebugDisplayElemBounds(CDraw2d* draw2d) const; - void DebugDisplayChildElemBounds(CDraw2d* draw2d, const AZ::EntityId entity) const; + void DebugDisplayElemBounds(IDraw2d* draw2d) const; + void DebugDisplayChildElemBounds(IDraw2d* draw2d, const AZ::EntityId entity) const; #endif public: // static member functions diff --git a/Gems/LyShine/Code/Source/UiCanvasManager.cpp b/Gems/LyShine/Code/Source/UiCanvasManager.cpp index 62d1c6e2a8..fc373f17f6 100644 --- a/Gems/LyShine/Code/Source/UiCanvasManager.cpp +++ b/Gems/LyShine/Code/Source/UiCanvasManager.cpp @@ -6,7 +6,7 @@ * */ #include "UiCanvasManager.h" -#include +#include #include "UiCanvasFileObject.h" #include "UiCanvasComponent.h" @@ -997,33 +997,30 @@ void UiCanvasManager::DebugDisplayCanvasData(int setting) const { bool onlyShowEnabledCanvases = (setting == 2) ? true : false; - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); - float xOffset = 20.0f; - float yOffset = 20.0f; + float dpiScale = draw2d->GetViewportDpiScalingFactor(); + float xOffset = 20.0f * dpiScale; + float yOffset = 20.0f * dpiScale; const int elementNameFieldLength = 20; auto blackTexture = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::Black); - float textOpacity = 1.0f; - float backgroundRectOpacity = 0.75f; + float backgroundRectOpacity = 0.0f; // 0.75f; // [GHI #6515] Reenable background rect const AZ::Vector3 white(1.0f, 1.0f, 1.0f); const AZ::Vector3 grey(0.5f, 0.5f, 0.5f); const AZ::Vector3 red(1.0f, 0.3f, 0.3f); const AZ::Vector3 blue(0.3f, 0.3f, 1.0f); - // If the viewport is narrow then a font size of 16 might be too large, so we use a size between 12 and 16 depending - // on the viewport width. - float fontSize(draw2d->GetViewportWidth() / 75.f); - fontSize = AZ::GetClamp(fontSize, 12.f, 16.f); - const float lineSpacing = fontSize; + const float fontSize = 8.0f; + const float lineSpacing = 20.0f * dpiScale; // local function to write a line of text (with a background rect) and increment Y offset AZStd::function WriteLine = [&](const char* buffer, const AZ::Vector3& color) { - CDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); + IDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); textOptions.color = color; AZ::Vector2 textSize = draw2d->GetTextSize(buffer, fontSize, &textOptions); AZ::Vector2 rectTopLeft = AZ::Vector2(xOffset - 2, yOffset); @@ -1155,15 +1152,15 @@ void UiCanvasManager::DebugDisplayCanvasData(int setting) const //////////////////////////////////////////////////////////////////////////////////////////////////// void UiCanvasManager::DebugDisplayDrawCallData() const { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); - float xOffset = 20.0f; - float yOffset = 20.0f; + float dpiScale = draw2d->GetViewportDpiScalingFactor(); + float xOffset = 20.0f * dpiScale; + float yOffset = 20.0f * dpiScale; auto blackTexture = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::Black); float textOpacity = 1.0f; - float backgroundRectOpacity = 0.75f; - const float lineSpacing = 20.0f; + float backgroundRectOpacity = 0.0f; // 0.75f; // [GHI #6515] Reenable background rect const AZ::Vector3 white(1,1,1); const AZ::Vector3 red(1,0.3f,0.3f); @@ -1171,16 +1168,19 @@ void UiCanvasManager::DebugDisplayDrawCallData() const const AZ::Vector3 green(0.3f,1,0.3f); const AZ::Vector3 yellow(0.7f,0.7f,0.2f); + const float fontSize = 8.0f; + const float lineSpacing = 20.0f * dpiScale; + // local function to write a line of text (with a background rect) and increment Y offset AZStd::function WriteLine = [&](const char* buffer, const AZ::Vector3& color) { - CDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); + IDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); textOptions.color = color; - AZ::Vector2 textSize = draw2d->GetTextSize(buffer, 16, &textOptions); + AZ::Vector2 textSize = draw2d->GetTextSize(buffer, fontSize, &textOptions); AZ::Vector2 rectTopLeft = AZ::Vector2(xOffset - 2, yOffset); AZ::Vector2 rectSize = AZ::Vector2(textSize.GetX() + 4, lineSpacing); draw2d->DrawImage(blackTexture, rectTopLeft, rectSize, backgroundRectOpacity); - draw2d->DrawText(buffer, AZ::Vector2(xOffset, yOffset), 16, textOpacity, &textOptions); + draw2d->DrawText(buffer, AZ::Vector2(xOffset, yOffset), fontSize, textOpacity, &textOptions); yOffset += lineSpacing; }; @@ -1486,7 +1486,7 @@ void UiCanvasManager::DebugReportDrawCalls(const AZStd::string& name) const //////////////////////////////////////////////////////////////////////////////////////////////////// void UiCanvasManager::DebugDisplayElemBounds(int canvasIndexFilter) const { - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); int canvasIndex = 0; for (auto canvas : m_loadedCanvases) diff --git a/Gems/LyShine/Code/Source/UiFaderComponent.cpp b/Gems/LyShine/Code/Source/UiFaderComponent.cpp index e1f5153e99..e84e5162b5 100644 --- a/Gems/LyShine/Code/Source/UiFaderComponent.cpp +++ b/Gems/LyShine/Code/Source/UiFaderComponent.cpp @@ -7,7 +7,7 @@ */ #include "UiFaderComponent.h" #include "RenderGraph.h" -#include +#include #include #include diff --git a/Gems/LyShine/Code/Source/UiImageComponent.cpp b/Gems/LyShine/Code/Source/UiImageComponent.cpp index 100bee6bf6..a8b4210d6b 100644 --- a/Gems/LyShine/Code/Source/UiImageComponent.cpp +++ b/Gems/LyShine/Code/Source/UiImageComponent.cpp @@ -13,7 +13,7 @@ #include #include -#include +#include #include #include #include @@ -353,7 +353,6 @@ void UiImageComponent::SetOverrideSprite(ISprite* sprite, AZ::u32 cellIndex) //////////////////////////////////////////////////////////////////////////////////////////////////// void UiImageComponent::Render(LyShine::IRenderGraph* renderGraph) { - // get fade value (tracked by UiRenderer) and compute the desired alpha for the image float fade = renderGraph->GetAlphaFade(); float desiredAlpha = m_overrideAlpha * fade; @@ -376,9 +375,8 @@ void UiImageComponent::Render(LyShine::IRenderGraph* renderGraph) ImageType imageType = m_imageType; -#ifdef LYSHINE_ATOM_TODO // support default white texture // if there is no texture we will just use a white texture and want to stretch it - const bool spriteOrTextureIsNull = sprite == nullptr || sprite->GetTexture() == nullptr; + const bool spriteOrTextureIsNull = sprite == nullptr || sprite->GetImage() == nullptr; // Zero texture size may occur even if the UiImageComponent has a valid non-zero-sized texture, // because a canvas can be requested to Render() before the texture asset is done loading. @@ -399,12 +397,6 @@ void UiImageComponent::Render(LyShine::IRenderGraph* renderGraph) { imageType = ImageType::Stretched; } -#else - if (sprite == nullptr) - { - imageType = ImageType::Stretched; - } -#endif switch (imageType) { diff --git a/Gems/LyShine/Code/Source/UiImageSequenceComponent.cpp b/Gems/LyShine/Code/Source/UiImageSequenceComponent.cpp index 4e7d22d96a..3559dc6306 100644 --- a/Gems/LyShine/Code/Source/UiImageSequenceComponent.cpp +++ b/Gems/LyShine/Code/Source/UiImageSequenceComponent.cpp @@ -9,7 +9,7 @@ #include "Sprite.h" #include "RenderGraph.h" -#include +#include #include #include #include diff --git a/Gems/LyShine/Code/Source/UiMaskComponent.cpp b/Gems/LyShine/Code/Source/UiMaskComponent.cpp index 09975d1351..67ba8ee0fb 100644 --- a/Gems/LyShine/Code/Source/UiMaskComponent.cpp +++ b/Gems/LyShine/Code/Source/UiMaskComponent.cpp @@ -6,7 +6,7 @@ * */ #include "UiMaskComponent.h" -#include +#include #include #include diff --git a/Gems/LyShine/Code/Source/UiRenderer.cpp b/Gems/LyShine/Code/Source/UiRenderer.cpp index ea5dfdd134..a9c56ece90 100644 --- a/Gems/LyShine/Code/Source/UiRenderer.cpp +++ b/Gems/LyShine/Code/Source/UiRenderer.cpp @@ -20,7 +20,7 @@ #include #include -#include +#include //////////////////////////////////////////////////////////////////////////////////////////////////// // PUBLIC MEMBER FUNCTIONS @@ -57,7 +57,7 @@ void UiRenderer::OnBootstrapSceneReady(AZ::RPI::Scene* bootstrapScene) // At this point the RPI is ready for use // Load the UI shader - const char* uiShaderFilepath = "Shaders/LyShineUI.azshader"; + const char* uiShaderFilepath = "LyShine/Shaders/LyShineUI.azshader"; AZ::Data::Instance uiShader = AZ::RPI::LoadCriticalShader(uiShaderFilepath); // Create scene to be used by the dynamic draw context @@ -76,7 +76,7 @@ void UiRenderer::OnBootstrapSceneReady(AZ::RPI::Scene* bootstrapScene) // Create a dynamic draw context for UI Canvas drawing for the scene m_dynamicDraw = CreateDynamicDrawContext(uiShader); - if (m_dynamicDraw) + if (m_dynamicDraw && m_dynamicDraw->IsReady()) { // Cache shader data such as input indices for later use CacheShaderData(m_dynamicDraw); @@ -85,7 +85,7 @@ void UiRenderer::OnBootstrapSceneReady(AZ::RPI::Scene* bootstrapScene) } else { - AZ_Error(LogName, false, "Failed to create a dynamic draw context for LyShine. \ + AZ_Error(LogName, false, "Failed to create or initialize a dynamic draw context for LyShine. \ This can happen if the LyShine pass hasn't been added to the main render pipeline."); } } @@ -216,17 +216,11 @@ void UiRenderer::BeginUiFrameRender() m_texturesUsedInFrame.clear(); } #endif - - // Various platform drivers expect all texture slots used in the shader to be bound - BindNullTexture(); } //////////////////////////////////////////////////////////////////////////////////////////////////// void UiRenderer::EndUiFrameRender() { - // We never want to leave a texture bound that could get unloaded before the next render - // So bind the global white texture for all the texture units we use. - BindNullTexture(); } //////////////////////////////////////////////////////////////////////////////////////////////////// @@ -384,45 +378,6 @@ void UiRenderer::DecrementStencilRef() --m_stencilRef; } -#ifdef LYSHINE_ATOM_TODO -//////////////////////////////////////////////////////////////////////////////////////////////////// -void UiRenderer::SetTexture(ITexture* texture, int texUnit, bool clamp) -{ - if (!texture) - { - texture = m_renderer->GetWhiteTexture(); - } - else - { - texture->SetClamp(clamp); - } - - m_renderer->SetTexture(texture->GetTextureID(), texUnit); - -#ifndef _RELEASE - if (m_debugTextureDataRecordLevel > 0) - { - m_texturesUsedInFrame.insert(texture); - } -#endif -} -#endif - - -//////////////////////////////////////////////////////////////////////////////////////////////////// -void UiRenderer::BindNullTexture() -{ -#ifdef LYSHINE_ATOM_TODO - // Bind the global white texture for all the texture units we use - const int MaxTextures = 16; - int whiteTexId = m_renderer->GetWhiteTextureId(); - for (int texUnit = 0; texUnit < MaxTextures; ++texUnit) - { - m_renderer->SetTexture(whiteTexId, texUnit); - } -#endif -} - #ifndef _RELEASE //////////////////////////////////////////////////////////////////////////////////////////////////// @@ -436,38 +391,42 @@ void UiRenderer::DebugDisplayTextureData(int recordingOption) { if (recordingOption > 0) { -#ifdef LYSHINE_ATOM_TODO // [GHI #3568] Support canvas debug display with Atom // compute the total area of all the textures, also create a vector that we can sort by area - AZStd::vector textures; + AZStd::vector, uint32_t>> textures; int totalArea = 0; int totalDataSize = 0; - for (ITexture* texture : m_texturesUsedInFrame) + for (AZ::Data::Instance image : m_texturesUsedInFrame) { - int area = texture->GetWidth() * texture->GetHeight(); - int dataSize = texture->GetDataSize(); + const AZ::RHI::ImageDescriptor& imageDescriptor = image->GetRHIImage()->GetDescriptor(); + AZ::RHI::Size size = imageDescriptor.m_size; + int area = size.m_width * size.m_height; + uint32_t dataSize = AZ::RHI::GetFormatSize(imageDescriptor.m_format) * area; + totalArea += area; totalDataSize += dataSize; - textures.push_back(texture); + textures.push_back(AZStd::pair, uint32_t>(image, dataSize)); } // sort the vector by data size - std::sort( textures.begin( ), textures.end( ), [ ]( const ITexture* lhs, const ITexture* rhs ) + std::sort( textures.begin( ), textures.end( ), [ ]( const AZStd::pair, uint32_t> lhs, const AZStd::pair, uint32_t> rhs ) { - return lhs->GetDataSize() > rhs->GetDataSize(); + return lhs.second > rhs.second; }); - CDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); + IDraw2d* draw2d = Draw2dHelper::GetDefaultDraw2d(); // setup to render lines of text for the debug display - float xOffset = 20.0f; - float yOffset = 20.0f; + float dpiScale = GetViewportContext()->GetDpiScalingFactor(); + float xOffset = 20.0f * dpiScale; + float yOffset = 20.0f * dpiScale; auto blackTexture = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::Black); float textOpacity = 1.0f; - float backgroundRectOpacity = 0.75f; - const float lineSpacing = 20.0f; + float backgroundRectOpacity = 0.0f; // 0.75f; // [GHI #6515] Reenable background rect + const float fontSize = 8.0f; + const float lineSpacing = 20.0f * dpiScale; const AZ::Vector3 white(1,1,1); const AZ::Vector3 red(1,0.3f,0.3f); @@ -490,31 +449,63 @@ void UiRenderer::DebugDisplayTextureData(int recordingOption) // local function to write a line of text (with a background rect) and increment Y offset AZStd::function WriteLine = [&](const char* buffer, const AZ::Vector3& color) { - CDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); + IDraw2d::TextOptions textOptions = draw2d->GetDefaultTextOptions(); textOptions.color = color; - AZ::Vector2 textSize = draw2d->GetTextSize(buffer, 16, &textOptions); + AZ::Vector2 textSize = draw2d->GetTextSize(buffer, fontSize, &textOptions); AZ::Vector2 rectTopLeft = AZ::Vector2(xOffset - 2, yOffset); AZ::Vector2 rectSize = AZ::Vector2(textSize.GetX() + 4, lineSpacing); draw2d->DrawImage(blackTexture, rectTopLeft, rectSize, backgroundRectOpacity); - draw2d->DrawText(buffer, AZ::Vector2(xOffset, yOffset), 16, textOpacity, &textOptions); + draw2d->DrawText(buffer, AZ::Vector2(xOffset, yOffset), fontSize, textOpacity, &textOptions); yOffset += lineSpacing; }; - int numTexturesUsedInFrame = m_texturesUsedInFrame.size(); + size_t numTexturesUsedInFrame = m_texturesUsedInFrame.size(); char buffer[200]; - sprintf_s(buffer, "There are %d unique UI textures rendered in this frame, the total texture area is %d (%d x %d), total data size is %d (%.2f MB)", + sprintf_s(buffer, "There are %zu unique UI textures rendered in this frame, the total texture area is %d (%d x %d), total data size is %d (%.2f MB)", numTexturesUsedInFrame, totalArea, xDim, yDim, totalDataSize, totalDataSizeMB); WriteLine(buffer, white); - sprintf_s(buffer, "Dimensions Data Size Format Texture name"); + sprintf_s(buffer, "Dimensions Data Size Format Texture name"); WriteLine(buffer, blue); - for (ITexture* texture : textures) + for (auto texture : textures) { - sprintf_s(buffer, "%4d x %4d, %9d %8s %s", - texture->GetWidth(), texture->GetHeight(), texture->GetDataSize(), texture->GetFormatName(), texture->GetName()); + AZ::Data::Instance image = texture.first; + const AZ::RHI::ImageDescriptor& imageDescriptor = image->GetRHIImage()->GetDescriptor(); + uint32_t width = imageDescriptor.m_size.m_width; + uint32_t height = imageDescriptor.m_size.m_height; + uint32_t dataSize = texture.second; + + const char* displayName = "Unnamed Texture"; + AZStd::string imagePath; + // Check if the image has been assigned a name (ex. if it's an attachment image or a cpu generated image) + const AZ::Name& imageName = image->GetRHIImage()->GetName(); + if (!imageName.IsEmpty()) + { + displayName = imageName.GetCStr(); + } + else + { + // Use the image's asset path as the display name + AZ::Data::AssetCatalogRequestBus::BroadcastResult(imagePath, + &AZ::Data::AssetCatalogRequests::GetAssetPathById, image->GetAssetId()); + if (!imagePath.empty()) + { + displayName = imagePath.c_str(); + } + } + + sprintf_s(buffer, "%4u x %4u, %9u %19s %s", + width, height, dataSize, AZ::RHI::ToString(imageDescriptor.m_format), displayName); WriteLine(buffer, white); } -#endif + } +} + +void UiRenderer::DebugUseTexture(AZ::Data::Instance image) +{ + if (m_debugTextureDataRecordLevel > 0) + { + m_texturesUsedInFrame.insert(image); } } diff --git a/Gems/LyShine/Code/Source/UiRenderer.h b/Gems/LyShine/Code/Source/UiRenderer.h index 3ff3de5507..35705441f5 100644 --- a/Gems/LyShine/Code/Source/UiRenderer.h +++ b/Gems/LyShine/Code/Source/UiRenderer.h @@ -19,8 +19,6 @@ #include #endif -class ITexture; - //////////////////////////////////////////////////////////////////////////////////////////////////// //! UI render interface // @@ -137,6 +135,9 @@ public: // member functions //! Display debug texture data after rendering void DebugDisplayTextureData(int recordingOption); + + //! Track textures being used in the current frame + void DebugUseTexture(AZ::Data::Instance image); #endif private: // member functions @@ -179,6 +180,6 @@ protected: // attributes #ifndef _RELEASE int m_debugTextureDataRecordLevel = 0; - AZStd::unordered_set m_texturesUsedInFrame; // [LYN-7857] - Support debug display with Atom + AZStd::unordered_set> m_texturesUsedInFrame; #endif }; diff --git a/Gems/LyShine/Code/Source/UiTextComponent.cpp b/Gems/LyShine/Code/Source/UiTextComponent.cpp index 01cfd49e99..aa0235470a 100644 --- a/Gems/LyShine/Code/Source/UiTextComponent.cpp +++ b/Gems/LyShine/Code/Source/UiTextComponent.cpp @@ -23,7 +23,7 @@ #include #include #include -#include +#include #include @@ -1105,7 +1105,7 @@ UiTextComponent::InlineImage::InlineImage(const AZStd::string& texturePathname, else { // Load the texture - m_texture = CDraw2d::LoadTexture(m_filepath); + m_texture = Draw2dHelper::LoadTexture(m_filepath); if (m_texture) { AZ::RHI::Size size = m_texture->GetDescriptor().m_size; @@ -1157,7 +1157,7 @@ bool UiTextComponent::InlineImage::OnAtlasUnloaded(const TextureAtlasNamespace:: else { // Load the texture - m_texture = CDraw2d::LoadTexture(m_filepath); + m_texture = Draw2dHelper::LoadTexture(m_filepath); } return true; } @@ -2675,7 +2675,7 @@ void UiTextComponent::GetClickableTextRects(UiClickableTextInterface::ClickableT } else { - alignedPosition = CDraw2d::Align(pos, drawBatchLine.lineSize, m_textHAlignment, IDraw2d::VAlign::Top); // y is already aligned + alignedPosition = Draw2dHelper::Align(pos, drawBatchLine.lineSize, m_textHAlignment, IDraw2d::VAlign::Top); // y is already aligned } alignedPosition.SetY(alignedPosition.GetY() + newlinePosYIncrement); @@ -4043,7 +4043,7 @@ void UiTextComponent::RenderDrawBatchLines( } else { - alignedPosition = CDraw2d::Align(pos, drawBatchLine.lineSize, m_textHAlignment, IDraw2d::VAlign::Top); // y is already aligned + alignedPosition = Draw2dHelper::Align(pos, drawBatchLine.lineSize, m_textHAlignment, IDraw2d::VAlign::Top); // y is already aligned } alignedPosition.SetY(alignedPosition.GetY() + newlinePosYIncrement); diff --git a/Gems/LyShine/Code/lyshine_static_files.cmake b/Gems/LyShine/Code/lyshine_static_files.cmake index 1adbe1b796..925658e756 100644 --- a/Gems/LyShine/Code/lyshine_static_files.cmake +++ b/Gems/LyShine/Code/lyshine_static_files.cmake @@ -7,8 +7,6 @@ # set(FILES - Source/Draw2d.cpp - Include/LyShine/Draw2d.h Include/LyShine/IDraw2d.h Include/LyShine/IRenderGraph.h Include/LyShine/ISprite.h @@ -88,6 +86,8 @@ set(FILES Include/LyShine/Bus/World/UiCanvasOnMeshBus.h Include/LyShine/Bus/World/UiCanvasRefBus.h Include/LyShine/Bus/Tools/UiSystemToolsBus.h + Source/Draw2d.cpp + Source/Draw2d.h Source/LyShine.cpp Source/LyShine.h Source/LyShinePassDataBus.h diff --git a/Gems/LyShine/gem.json b/Gems/LyShine/gem.json index f3c3fc2c67..7ebb733b0f 100644 --- a/Gems/LyShine/gem.json +++ b/Gems/LyShine/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The LyShine Gem provides the runtime UI system and creation tools for Open 3D Engine projects.", "canonical_tags": [ @@ -24,6 +25,7 @@ "Atom_Bootstrap", "AtomFont", "TextureAtlas", - "AtomToolsFramework" + "AtomToolsFramework", + "UiBasics" ] } diff --git a/Gems/LyShineExamples/Code/CMakeLists.txt b/Gems/LyShineExamples/Code/CMakeLists.txt index 6e8f53d5cd..40032d6342 100644 --- a/Gems/LyShineExamples/Code/CMakeLists.txt +++ b/Gems/LyShineExamples/Code/CMakeLists.txt @@ -21,7 +21,7 @@ ly_add_target( Gem::LmbrCentral PUBLIC Legacy::CryCommon - Gem::LyShine.Static + Gem::LyShine.Clients.API ) ly_add_target( @@ -42,7 +42,7 @@ ly_add_target( # if enabled, LyShineExamples is used by all kinds of applications, however, the dependency to LmbrCentral is different # per application type -ly_create_alias(NAME LyShineExamples.Builders NAMESPACE Gem TARGETS Gem::LyShineExamples Gem::LmbrCentral.Editor) +ly_create_alias(NAME LyShineExamples.Builders NAMESPACE Gem TARGETS Gem::LyShineExamples Gem::UiBasics.Builders Gem::LmbrCentral.Editor) ly_create_alias(NAME LyShineExamples.Tools NAMESPACE Gem TARGETS Gem::LyShineExamples Gem::LmbrCentral.Editor) ly_create_alias(NAME LyShineExamples.Clients NAMESPACE Gem TARGETS Gem::LyShineExamples Gem::LmbrCentral) ly_create_alias(NAME LyShineExamples.Servers NAMESPACE Gem TARGETS Gem::LyShineExamples Gem::LmbrCentral) diff --git a/Gems/LyShineExamples/Code/Source/UiCustomImageComponent.cpp b/Gems/LyShineExamples/Code/Source/UiCustomImageComponent.cpp index 09ea375923..e8b0e4370a 100644 --- a/Gems/LyShineExamples/Code/Source/UiCustomImageComponent.cpp +++ b/Gems/LyShineExamples/Code/Source/UiCustomImageComponent.cpp @@ -14,7 +14,7 @@ #include #include -#include +#include #include #include #include @@ -72,36 +72,25 @@ namespace LyShineExamples } //////////////////////////////////////////////////////////////////////////////////////////////////// - void UiCustomImageComponent::Render([[maybe_unused]] LyShine::IRenderGraph* renderGraph) + void UiCustomImageComponent::Render(LyShine::IRenderGraph* renderGraph) { -#ifdef LYSHINE_ATOM_TODO // [GHI #3568] Convert draws to use Atom // get fade value (tracked by UiRenderer) and compute the desired alpha for the image float fade = renderGraph->GetAlphaFade(); float desiredAlpha = m_overrideAlpha * fade; uint8 desiredPackedAlpha = static_cast(desiredAlpha * 255.0f); - // if desired alpha is zero then no need to do any more - if (desiredPackedAlpha == 0) - { - return; - } - - ISprite* sprite = (m_overrideSprite) ? m_overrideSprite : m_sprite; - ITexture* texture = (sprite) ? sprite->GetTexture() : nullptr; - - if (!texture) - { - // if there is no texture we will just use a white texture - // TODO: Get a default atom texture here when possible - //texture = ???->EF_GetTextureByID(???->GetWhiteTextureId()); - } - if (m_isRenderCacheDirty) { RenderToCache(renderGraph); m_isRenderCacheDirty = false; } + // if desired alpha is zero then no need to do any more + if (desiredPackedAlpha == 0) + { + return; + } + // Render cache is now valid - render using the cache // If the fade value has changed we need to update the alpha values in the vertex colors but we do @@ -109,7 +98,7 @@ namespace LyShineExamples if (m_cachedPrimitive.m_vertices[0].color.a != desiredPackedAlpha) { // go through all the cached vertices and update the alpha values - UCol desiredPackedColor = m_cachedPrimitive.m_vertices[0].color; + LyShine::UCol desiredPackedColor = m_cachedPrimitive.m_vertices[0].color; desiredPackedColor.a = desiredPackedAlpha; for (int i = 0; i < m_cachedPrimitive.m_numVertices; ++i) { @@ -117,11 +106,12 @@ namespace LyShineExamples } } + ISprite* sprite = (m_overrideSprite) ? m_overrideSprite : m_sprite; + AZ::Data::Instance image = sprite->GetImage(); bool isTextureSRGB = false; bool isTexturePremultipliedAlpha = false; // we are not rendering from a render target with alpha in it LyShine::BlendMode blendMode = LyShine::BlendMode::Normal; - renderGraph->AddPrimitive(&m_cachedPrimitive, texture, m_clamp, isTextureSRGB, isTexturePremultipliedAlpha, blendMode); -#endif + renderGraph->AddPrimitive(&m_cachedPrimitive, image, m_clamp, isTextureSRGB, isTexturePremultipliedAlpha, blendMode); } //////////////////////////////////////////////////////////////////////////////////////////////////// diff --git a/Gems/LyShineExamples/gem.json b/Gems/LyShineExamples/gem.json index 74d2b6fe51..c91e9b819e 100644 --- a/Gems/LyShineExamples/gem.json +++ b/Gems/LyShineExamples/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "The LyShine Examples Gem provides example code and assets for LyShine, the runtime UI system and editor for Open 3D Engine projects.", "canonical_tags": [ diff --git a/Gems/Maestro/Code/Source/Cinematics/AnimPostFXNode.cpp b/Gems/Maestro/Code/Source/Cinematics/AnimPostFXNode.cpp index b535033351..7e32301b71 100644 --- a/Gems/Maestro/Code/Source/Cinematics/AnimPostFXNode.cpp +++ b/Gems/Maestro/Code/Source/Cinematics/AnimPostFXNode.cpp @@ -8,7 +8,6 @@ #include -#include #include "AnimPostFXNode.h" #include "AnimSplineTrack.h" #include "CompoundSplineTrack.h" @@ -39,7 +38,7 @@ public: virtual void GetDefault(bool& val) const = 0; virtual void GetDefault(Vec4& val) const = 0; - AZStd::basic_string, AZStd::stateless_allocator> m_name; + AZStd::string m_name; protected: virtual ~CControlParamBase(){} diff --git a/Gems/Maestro/Code/Source/Cinematics/Movie.cpp b/Gems/Maestro/Code/Source/Cinematics/Movie.cpp index dc0782f982..51be8a4c24 100644 --- a/Gems/Maestro/Code/Source/Cinematics/Movie.cpp +++ b/Gems/Maestro/Code/Source/Cinematics/Movie.cpp @@ -7,7 +7,6 @@ */ #include -#include #include #include #include @@ -28,7 +27,6 @@ #include "LayerNode.h" #include "ShadowsSetupNode.h" -#include #include #include @@ -74,136 +72,117 @@ static SMovieSequenceAutoComplete s_movieSequenceAutoComplete; #endif ////////////////////////////////////////////////////////////////////////// -namespace -{ - using AnimParamSystemString = AZStd::basic_string, AZStd::stateless_allocator>; - - template > - using AnimSystemOrderedMap = AZStd::map; - template , typename EqualKey = AZStd::equal_to> - using AnimSystemUnorderedMap = AZStd::unordered_map; -} - // Serialization for anim nodes & param types -#define REGISTER_NODE_TYPE(name) assert(!g_animNodeEnumToStringMap.contains(AnimNodeType::name)); \ - g_animNodeEnumToStringMap[AnimNodeType::name] = AZ_STRINGIZE(name); \ - g_animNodeStringToEnumMap[AnimParamSystemString(AZ_STRINGIZE(name))] = AnimNodeType::name; - -#define REGISTER_PARAM_TYPE(name) assert(!g_animParamEnumToStringMap.contains(AnimParamType::name)); \ - g_animParamEnumToStringMap[AnimParamType::name] = AZ_STRINGIZE(name); \ - g_animParamStringToEnumMap[AnimParamSystemString(AZ_STRINGIZE(name))] = AnimParamType::name; - -namespace -{ - AnimSystemUnorderedMap g_animNodeEnumToStringMap; - AnimSystemOrderedMap> g_animNodeStringToEnumMap; - - AnimSystemUnorderedMap g_animParamEnumToStringMap; - AnimSystemOrderedMap> g_animParamStringToEnumMap; - - // If you get an assert in this function, it means two node types have the same enum value. - void RegisterNodeTypes() - { - REGISTER_NODE_TYPE(Entity) - REGISTER_NODE_TYPE(Director) - REGISTER_NODE_TYPE(Camera) - REGISTER_NODE_TYPE(CVar) - REGISTER_NODE_TYPE(ScriptVar) - REGISTER_NODE_TYPE(Material) - REGISTER_NODE_TYPE(Event) - REGISTER_NODE_TYPE(Group) - REGISTER_NODE_TYPE(Layer) - REGISTER_NODE_TYPE(Comment) - REGISTER_NODE_TYPE(RadialBlur) - REGISTER_NODE_TYPE(ColorCorrection) - REGISTER_NODE_TYPE(DepthOfField) - REGISTER_NODE_TYPE(ScreenFader) - REGISTER_NODE_TYPE(Light) - REGISTER_NODE_TYPE(ShadowSetup) - REGISTER_NODE_TYPE(Alembic) - REGISTER_NODE_TYPE(GeomCache) - REGISTER_NODE_TYPE(Environment) - REGISTER_NODE_TYPE(AzEntity) - REGISTER_NODE_TYPE(Component) - } - - // If you get an assert in this function, it means two param types have the same enum value. - void RegisterParamTypes() - { - REGISTER_PARAM_TYPE(FOV) - REGISTER_PARAM_TYPE(Position) - REGISTER_PARAM_TYPE(Rotation) - REGISTER_PARAM_TYPE(Scale) - REGISTER_PARAM_TYPE(Event) - REGISTER_PARAM_TYPE(Visibility) - REGISTER_PARAM_TYPE(Camera) - REGISTER_PARAM_TYPE(Animation) - REGISTER_PARAM_TYPE(Sound) - REGISTER_PARAM_TYPE(Sequence) - REGISTER_PARAM_TYPE(Console) - REGISTER_PARAM_TYPE(Music) ///@deprecated in 1.11, left in for legacy serialization - REGISTER_PARAM_TYPE(Float) - REGISTER_PARAM_TYPE(LookAt) - REGISTER_PARAM_TYPE(TrackEvent) - REGISTER_PARAM_TYPE(ShakeAmplitudeA) - REGISTER_PARAM_TYPE(ShakeAmplitudeB) - REGISTER_PARAM_TYPE(ShakeFrequencyA) - REGISTER_PARAM_TYPE(ShakeFrequencyB) - REGISTER_PARAM_TYPE(ShakeMultiplier) - REGISTER_PARAM_TYPE(ShakeNoise) - REGISTER_PARAM_TYPE(ShakeWorking) - REGISTER_PARAM_TYPE(ShakeAmpAMult) - REGISTER_PARAM_TYPE(ShakeAmpBMult) - REGISTER_PARAM_TYPE(ShakeFreqAMult) - REGISTER_PARAM_TYPE(ShakeFreqBMult) - REGISTER_PARAM_TYPE(DepthOfField) - REGISTER_PARAM_TYPE(FocusDistance) - REGISTER_PARAM_TYPE(FocusRange) - REGISTER_PARAM_TYPE(BlurAmount) - REGISTER_PARAM_TYPE(Capture) - REGISTER_PARAM_TYPE(TransformNoise) - REGISTER_PARAM_TYPE(TimeWarp) - REGISTER_PARAM_TYPE(FixedTimeStep) - REGISTER_PARAM_TYPE(NearZ) - REGISTER_PARAM_TYPE(Goto) - REGISTER_PARAM_TYPE(PositionX) - REGISTER_PARAM_TYPE(PositionY) - REGISTER_PARAM_TYPE(PositionZ) - REGISTER_PARAM_TYPE(RotationX) - REGISTER_PARAM_TYPE(RotationY) - REGISTER_PARAM_TYPE(RotationZ) - REGISTER_PARAM_TYPE(ScaleX) - REGISTER_PARAM_TYPE(ScaleY) - REGISTER_PARAM_TYPE(ScaleZ) - REGISTER_PARAM_TYPE(ColorR) - REGISTER_PARAM_TYPE(ColorG) - REGISTER_PARAM_TYPE(ColorB) - REGISTER_PARAM_TYPE(CommentText) - REGISTER_PARAM_TYPE(ScreenFader) - REGISTER_PARAM_TYPE(LightDiffuse) - REGISTER_PARAM_TYPE(LightRadius) - REGISTER_PARAM_TYPE(LightDiffuseMult) - REGISTER_PARAM_TYPE(LightHDRDynamic) - REGISTER_PARAM_TYPE(LightSpecularMult) - REGISTER_PARAM_TYPE(LightSpecPercentage) - REGISTER_PARAM_TYPE(MaterialDiffuse) - REGISTER_PARAM_TYPE(MaterialSpecular) - REGISTER_PARAM_TYPE(MaterialEmissive) - REGISTER_PARAM_TYPE(MaterialEmissiveIntensity) - REGISTER_PARAM_TYPE(MaterialOpacity) - REGISTER_PARAM_TYPE(MaterialSmoothness) - REGISTER_PARAM_TYPE(TimeRanges) - REGISTER_PARAM_TYPE(Physics) - REGISTER_PARAM_TYPE(GSMCache) - REGISTER_PARAM_TYPE(ShutterSpeed) - REGISTER_PARAM_TYPE(Physicalize) - REGISTER_PARAM_TYPE(PhysicsDriven) - REGISTER_PARAM_TYPE(SunLongitude) - REGISTER_PARAM_TYPE(SunLatitude) - REGISTER_PARAM_TYPE(MoonLongitude) - REGISTER_PARAM_TYPE(MoonLatitude) - REGISTER_PARAM_TYPE(ProceduralEyes) - } +#define REGISTER_NODE_TYPE(name) assert(!m_animNodeEnumToStringMap.contains(AnimNodeType::name)); \ + m_animNodeEnumToStringMap[AnimNodeType::name] = AZ_STRINGIZE(name); \ + m_animNodeStringToEnumMap[AnimParamSystemString(AZ_STRINGIZE(name))] = AnimNodeType::name; + +#define REGISTER_PARAM_TYPE(name) assert(!m_animParamEnumToStringMap.contains(AnimParamType::name)); \ + m_animParamEnumToStringMap[AnimParamType::name] = AZ_STRINGIZE(name); \ + m_animParamStringToEnumMap[AnimParamSystemString(AZ_STRINGIZE(name))] = AnimParamType::name; + +// If you get an assert in this function, it means two node types have the same enum value. +void CMovieSystem::RegisterNodeTypes() +{ + REGISTER_NODE_TYPE(Entity) + REGISTER_NODE_TYPE(Director) + REGISTER_NODE_TYPE(Camera) + REGISTER_NODE_TYPE(CVar) + REGISTER_NODE_TYPE(ScriptVar) + REGISTER_NODE_TYPE(Material) + REGISTER_NODE_TYPE(Event) + REGISTER_NODE_TYPE(Group) + REGISTER_NODE_TYPE(Layer) + REGISTER_NODE_TYPE(Comment) + REGISTER_NODE_TYPE(RadialBlur) + REGISTER_NODE_TYPE(ColorCorrection) + REGISTER_NODE_TYPE(DepthOfField) + REGISTER_NODE_TYPE(ScreenFader) + REGISTER_NODE_TYPE(Light) + REGISTER_NODE_TYPE(ShadowSetup) + REGISTER_NODE_TYPE(Alembic) + REGISTER_NODE_TYPE(GeomCache) + REGISTER_NODE_TYPE(Environment) + REGISTER_NODE_TYPE(AzEntity) + REGISTER_NODE_TYPE(Component) +} + +// If you get an assert in this function, it means two param types have the same enum value. +void CMovieSystem::RegisterParamTypes() +{ + REGISTER_PARAM_TYPE(FOV) + REGISTER_PARAM_TYPE(Position) + REGISTER_PARAM_TYPE(Rotation) + REGISTER_PARAM_TYPE(Scale) + REGISTER_PARAM_TYPE(Event) + REGISTER_PARAM_TYPE(Visibility) + REGISTER_PARAM_TYPE(Camera) + REGISTER_PARAM_TYPE(Animation) + REGISTER_PARAM_TYPE(Sound) + REGISTER_PARAM_TYPE(Sequence) + REGISTER_PARAM_TYPE(Console) + REGISTER_PARAM_TYPE(Music) ///@deprecated in 1.11, left in for legacy serialization + REGISTER_PARAM_TYPE(Float) + REGISTER_PARAM_TYPE(LookAt) + REGISTER_PARAM_TYPE(TrackEvent) + REGISTER_PARAM_TYPE(ShakeAmplitudeA) + REGISTER_PARAM_TYPE(ShakeAmplitudeB) + REGISTER_PARAM_TYPE(ShakeFrequencyA) + REGISTER_PARAM_TYPE(ShakeFrequencyB) + REGISTER_PARAM_TYPE(ShakeMultiplier) + REGISTER_PARAM_TYPE(ShakeNoise) + REGISTER_PARAM_TYPE(ShakeWorking) + REGISTER_PARAM_TYPE(ShakeAmpAMult) + REGISTER_PARAM_TYPE(ShakeAmpBMult) + REGISTER_PARAM_TYPE(ShakeFreqAMult) + REGISTER_PARAM_TYPE(ShakeFreqBMult) + REGISTER_PARAM_TYPE(DepthOfField) + REGISTER_PARAM_TYPE(FocusDistance) + REGISTER_PARAM_TYPE(FocusRange) + REGISTER_PARAM_TYPE(BlurAmount) + REGISTER_PARAM_TYPE(Capture) + REGISTER_PARAM_TYPE(TransformNoise) + REGISTER_PARAM_TYPE(TimeWarp) + REGISTER_PARAM_TYPE(FixedTimeStep) + REGISTER_PARAM_TYPE(NearZ) + REGISTER_PARAM_TYPE(Goto) + REGISTER_PARAM_TYPE(PositionX) + REGISTER_PARAM_TYPE(PositionY) + REGISTER_PARAM_TYPE(PositionZ) + REGISTER_PARAM_TYPE(RotationX) + REGISTER_PARAM_TYPE(RotationY) + REGISTER_PARAM_TYPE(RotationZ) + REGISTER_PARAM_TYPE(ScaleX) + REGISTER_PARAM_TYPE(ScaleY) + REGISTER_PARAM_TYPE(ScaleZ) + REGISTER_PARAM_TYPE(ColorR) + REGISTER_PARAM_TYPE(ColorG) + REGISTER_PARAM_TYPE(ColorB) + REGISTER_PARAM_TYPE(CommentText) + REGISTER_PARAM_TYPE(ScreenFader) + REGISTER_PARAM_TYPE(LightDiffuse) + REGISTER_PARAM_TYPE(LightRadius) + REGISTER_PARAM_TYPE(LightDiffuseMult) + REGISTER_PARAM_TYPE(LightHDRDynamic) + REGISTER_PARAM_TYPE(LightSpecularMult) + REGISTER_PARAM_TYPE(LightSpecPercentage) + REGISTER_PARAM_TYPE(MaterialDiffuse) + REGISTER_PARAM_TYPE(MaterialSpecular) + REGISTER_PARAM_TYPE(MaterialEmissive) + REGISTER_PARAM_TYPE(MaterialEmissiveIntensity) + REGISTER_PARAM_TYPE(MaterialOpacity) + REGISTER_PARAM_TYPE(MaterialSmoothness) + REGISTER_PARAM_TYPE(TimeRanges) + REGISTER_PARAM_TYPE(Physics) + REGISTER_PARAM_TYPE(GSMCache) + REGISTER_PARAM_TYPE(ShutterSpeed) + REGISTER_PARAM_TYPE(Physicalize) + REGISTER_PARAM_TYPE(PhysicsDriven) + REGISTER_PARAM_TYPE(SunLongitude) + REGISTER_PARAM_TYPE(SunLatitude) + REGISTER_PARAM_TYPE(MoonLongitude) + REGISTER_PARAM_TYPE(MoonLatitude) + REGISTER_PARAM_TYPE(ProceduralEyes) } namespace Internal @@ -1666,16 +1645,16 @@ void CMovieSystem::SerializeNodeType(AnimNodeType& animNodeType, XmlNodeRef& xml XmlString nodeTypeString; if (xmlNode->getAttr(kType, nodeTypeString)) { - assert(g_animNodeStringToEnumMap.find(nodeTypeString.c_str()) != g_animNodeStringToEnumMap.end()); - animNodeType = stl::find_in_map(g_animNodeStringToEnumMap, nodeTypeString.c_str(), AnimNodeType::Invalid); + assert(m_animNodeStringToEnumMap.find(nodeTypeString.c_str()) != m_animNodeStringToEnumMap.end()); + animNodeType = stl::find_in_map(m_animNodeStringToEnumMap, nodeTypeString.c_str(), AnimNodeType::Invalid); } } } else { const char* pTypeString = "Invalid"; - assert(g_animNodeEnumToStringMap.find(animNodeType) != g_animNodeEnumToStringMap.end()); - pTypeString = g_animNodeEnumToStringMap[animNodeType].c_str(); + assert(m_animNodeEnumToStringMap.find(animNodeType) != m_animNodeEnumToStringMap.end()); + pTypeString = m_animNodeEnumToStringMap[animNodeType].c_str(); xmlNode->setAttr(kType, pTypeString); } } @@ -1744,8 +1723,8 @@ void CMovieSystem::LoadParamTypeFromXml(CAnimParamType& animParamType, const Xml animParamType.m_name = virtualPropertyValue; } - assert(g_animParamStringToEnumMap.find(paramTypeString.c_str()) != g_animParamStringToEnumMap.end()); - animParamType.m_type = stl::find_in_map(g_animParamStringToEnumMap, paramTypeString.c_str(), AnimParamType::Invalid); + assert(m_animParamStringToEnumMap.find(paramTypeString.c_str()) != m_animParamStringToEnumMap.end()); + animParamType.m_type = stl::find_in_map(m_animParamStringToEnumMap, paramTypeString.c_str(), AnimParamType::Invalid); } } } @@ -1775,8 +1754,8 @@ void CMovieSystem::SaveParamTypeToXml(const CAnimParamType& animParamType, XmlNo xmlNode->setAttr(CAnimParamTypeXmlNames::kVirtualPropertyName, animParamType.m_name.c_str()); } - assert(g_animParamEnumToStringMap.find(animParamType.m_type) != g_animParamEnumToStringMap.end()); - pTypeString = g_animParamEnumToStringMap[animParamType.m_type].c_str(); + assert(m_animParamEnumToStringMap.find(animParamType.m_type) != m_animParamEnumToStringMap.end()); + pTypeString = m_animParamEnumToStringMap[animParamType.m_type].c_str(); } xmlNode->setAttr(kParamType, pTypeString); @@ -1809,9 +1788,9 @@ const char* CMovieSystem::GetParamTypeName(const CAnimParamType& animParamType) } else { - if (g_animParamEnumToStringMap.find(animParamType.m_type) != g_animParamEnumToStringMap.end()) + if (m_animParamEnumToStringMap.contains(animParamType.m_type)) { - return g_animParamEnumToStringMap[animParamType.m_type].c_str(); + return m_animParamEnumToStringMap[animParamType.m_type].c_str(); } } @@ -1973,13 +1952,13 @@ void CLightAnimWrapper::RemoveCachedLightAnim(const char* name) ////////////////////////////////////////////////////////////////////////// AnimNodeType CMovieSystem::GetNodeTypeFromString(const char* pString) const { - return stl::find_in_map(g_animNodeStringToEnumMap, pString, AnimNodeType::Invalid); + return stl::find_in_map(m_animNodeStringToEnumMap, pString, AnimNodeType::Invalid); } ////////////////////////////////////////////////////////////////////////// CAnimParamType CMovieSystem::GetParamTypeFromString(const char* pString) const { - const AnimParamType paramType = stl::find_in_map(g_animParamStringToEnumMap, pString, AnimParamType::Invalid); + const AnimParamType paramType = stl::find_in_map(m_animParamStringToEnumMap, pString, AnimParamType::Invalid); if (paramType != AnimParamType::Invalid) { diff --git a/Gems/Maestro/Code/Source/Cinematics/Movie.h b/Gems/Maestro/Code/Source/Cinematics/Movie.h index ab2c2e649b..4af2b55ced 100644 --- a/Gems/Maestro/Code/Source/Cinematics/Movie.h +++ b/Gems/Maestro/Code/Source/Cinematics/Movie.h @@ -18,6 +18,7 @@ #include #include +#include #include "IMovieSystem.h" #include "IShader.h" @@ -192,7 +193,7 @@ public: void SaveParamTypeToXml(const CAnimParamType& animParamType, XmlNodeRef& xmlNode) override; void SerializeParamType(CAnimParamType& animParamType, XmlNodeRef& xmlNode, bool bLoading, const uint version) override; - static const char* GetParamTypeName(const CAnimParamType& animParamType); + const char* GetParamTypeName(const CAnimParamType& animParamType); void OnCameraCut(); @@ -290,6 +291,23 @@ private: void ShowPlayedSequencesDebug(); + + using AnimParamSystemString = AZStd::string; + + template > + using AnimSystemOrderedMap = AZStd::map; + template , typename EqualKey = AZStd::equal_to<>> + using AnimSystemUnorderedMap = AZStd::unordered_map; + + AnimSystemUnorderedMap m_animNodeEnumToStringMap; + AnimSystemOrderedMap m_animNodeStringToEnumMap; + + AnimSystemUnorderedMap m_animParamEnumToStringMap; + AnimSystemOrderedMap m_animParamStringToEnumMap; + + void RegisterNodeTypes(); + void RegisterParamTypes(); + public: static float m_mov_cameraPrecacheTime; #if !defined(_RELEASE) diff --git a/Gems/Maestro/gem.json b/Gems/Maestro/gem.json index d8f884e271..95aa43c179 100644 --- a/Gems/Maestro/gem.json +++ b/Gems/Maestro/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Maestro Cinematics Gem provides Track View, Open 3D Engine's animated sequence and cinematics editor.", "canonical_tags": [ diff --git a/Gems/MessagePopup/Code/CMakeLists.txt b/Gems/MessagePopup/Code/CMakeLists.txt index 51ec1a3bd1..2ed9c71632 100644 --- a/Gems/MessagePopup/Code/CMakeLists.txt +++ b/Gems/MessagePopup/Code/CMakeLists.txt @@ -19,7 +19,7 @@ ly_add_target( BUILD_DEPENDENCIES PUBLIC Legacy::CryCommon - Gem::LyShine + Gem::LyShine.Clients.API ) ly_add_target( @@ -39,4 +39,4 @@ ly_add_target( # MessagePopup is used only in client applications ly_create_alias(NAME MessagePopup.Clients NAMESPACE Gem TARGETS Gem::MessagePopup) - +ly_create_alias(NAME MessagePopup.Builders NAMESPACE Gem TARGETS Gem::UiBasics.Builders) diff --git a/Gems/MessagePopup/gem.json b/Gems/MessagePopup/gem.json index fb44dd93a5..5e1b4843b0 100644 --- a/Gems/MessagePopup/gem.json +++ b/Gems/MessagePopup/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Message Popup Gem provides an example implementation of popup messages using LyShine in Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/Metastream/CMakeLists.txt b/Gems/Metastream/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Metastream/CMakeLists.txt +++ b/Gems/Metastream/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Metastream/Code/CMakeLists.txt b/Gems/Metastream/Code/CMakeLists.txt index a032fc34ff..f1652058ac 100644 --- a/Gems/Metastream/Code/CMakeLists.txt +++ b/Gems/Metastream/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) ly_add_target( NAME Metastream.Static STATIC diff --git a/Gems/Metastream/gem.json b/Gems/Metastream/gem.json index 309f16b221..9a37a0a8ee 100644 --- a/Gems/Metastream/gem.json +++ b/Gems/Metastream/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Metastream Gem provides functionality for an HTTP server that allows broadcasters to customize game streams with overlays of statistics and event data from a game session.", "canonical_tags": [ diff --git a/Gems/Microphone/CMakeLists.txt b/Gems/Microphone/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Microphone/CMakeLists.txt +++ b/Gems/Microphone/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Microphone/Code/CMakeLists.txt b/Gems/Microphone/Code/CMakeLists.txt index 5b40521f6a..873d05e98d 100644 --- a/Gems/Microphone/Code/CMakeLists.txt +++ b/Gems/Microphone/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME Microphone.Static STATIC diff --git a/Gems/Microphone/gem.json b/Gems/Microphone/gem.json index 6e57bec854..6a5b415a22 100644 --- a/Gems/Microphone/gem.json +++ b/Gems/Microphone/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Microphone Gem provides support for audio input through microphones.", "canonical_tags": [ diff --git a/Gems/Multiplayer/CMakeLists.txt b/Gems/Multiplayer/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Multiplayer/CMakeLists.txt +++ b/Gems/Multiplayer/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Multiplayer/Code/CMakeLists.txt b/Gems/Multiplayer/Code/CMakeLists.txt index afe40408ab..66085476e5 100644 --- a/Gems/Multiplayer/Code/CMakeLists.txt +++ b/Gems/Multiplayer/Code/CMakeLists.txt @@ -6,6 +6,8 @@ # # +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) + ly_add_target( NAME Multiplayer.Static STATIC NAMESPACE Gem diff --git a/Gems/Multiplayer/Code/Include/Multiplayer/AutoGen/AutoComponent_Source.jinja b/Gems/Multiplayer/Code/Include/Multiplayer/AutoGen/AutoComponent_Source.jinja index d0b77159f8..01bed7d52d 100644 --- a/Gems/Multiplayer/Code/Include/Multiplayer/AutoGen/AutoComponent_Source.jinja +++ b/Gems/Multiplayer/Code/Include/Multiplayer/AutoGen/AutoComponent_Source.jinja @@ -309,11 +309,11 @@ void {{ ClassName }}::Set{{ UpperFirst(Property.attrib['Name']) }}(const {{ Prop {# #} -{% macro PrintRpcParameters(printPrefix, paramDefines) %} -{% if paramDefines|count > 0 %} +{% macro PrintRpcParameters(printPrefix, paramDefines) -%} +{% if paramDefines|count > 0 -%} {{ printPrefix }}{{ ', '.join(paramDefines) }} -{% endif %} -{% endmacro %} +{%- endif %} +{%- endmacro -%} {# #} @@ -366,47 +366,45 @@ void {{ ClassName }}::{{ UpperFirst(Property.attrib['Name']) }}({{ PrintRpcParam {% set paramTypes = [] %} {% set paramDefines = [] %} {{ AutoComponentMacros.ParseRpcParams(Property, paramNames, paramTypes, paramDefines) }} - ->Method("{{ UpperFirst(Property.attrib['Name']) }}", []({{ ClassName }}* self{{ PrintRpcParameters(', ', paramDefines) }}) { -{% if (InvokeFrom == 'Server') %} - self->{{ UpperFirst(Property.attrib['Name']) }}({{ ', '.join(paramNames) }}); -{% elif (InvokeFrom == 'Authority') or (InvokeFrom == 'Autonomous') %} - if (self->m_controller) - { - self->m_controller->{{ UpperFirst(Property.attrib['Name']) }}({{ ', '.join(paramNames) }}); - } - else - { - AZ_Warning("Network RPC", false, "{{ ClassName }} {{ UpperFirst(Property.attrib['Name']) }} method failed. Entity '%s' (id: %s) {{ ClassName }} is missing the network controller. This remote-procedure can only be invoked from {{InvokeFrom}} network entities, because this entity doesn't have a controller, it must not be a {{InvokeFrom}} entity. Please check your network context before attempting to call {{ UpperFirst(Property.attrib['Name']) }}.", self->GetEntity()->GetName().c_str(), self->GetEntityId().ToString().c_str()) - } -{% endif %} - }) + ->Method("{{ UpperFirst(Property.attrib['Name']) }}", []({{ ClassName }}* self{{ PrintRpcParameters(', ', paramDefines) }}){ +{% if (InvokeFrom == 'Server') %} + self->{{ UpperFirst(Property.attrib['Name']) }}({{ ', '.join(paramNames) }}); +{% elif (InvokeFrom == 'Authority') or (InvokeFrom == 'Autonomous') %} + if (self->m_controller) + { + self->m_controller->{{ UpperFirst(Property.attrib['Name']) }}({{ ', '.join(paramNames) }}); + } + else + { + AZ_Warning("Network RPC", false, "{{ ClassName }} {{ UpperFirst(Property.attrib['Name']) }} method failed. Entity '%s' (id: %s) {{ ClassName }} is missing the network controller. This remote-procedure can only be invoked from {{InvokeFrom}} network entities, because this entity doesn't have a controller, it must not be a {{InvokeFrom}} entity. Please check your network context before attempting to call {{ UpperFirst(Property.attrib['Name']) }}.", self->GetEntity()->GetName().c_str(), self->GetEntityId().ToString().c_str()) + } +{% endif %} + }) ->Method("{{ UpperFirst(Property.attrib['Name']) }}ByEntityId", [](AZ::EntityId id{{ PrintRpcParameters(', ', paramDefines) }}) { - - AZ::Entity* entity = AZ::Interface::Get()->FindEntity(id); - if (!entity) - { - AZ_Warning("Network RPC", false, "{{ ClassName }} {{ UpperFirst(Property.attrib['Name']) }}ByEntityId failed. The entity with id %s doesn't exist, please provide a valid entity id.", id.ToString().c_str()) - return; - } - - {{ ClassName }}* networkComponent = entity->FindComponent<{{ ClassName }}>(); - if (!networkComponent) - { - AZ_Warning("Network RPC", false, "{{ ClassName }} {{ UpperFirst(Property.attrib['Name']) }}ByEntityId failed. Entity '%s' (id: %s) is missing {{ ClassName }}, be sure to add {{ ClassName }} to this entity.", entity->GetName().c_str(), id.ToString().c_str()) - return; - } -{% if (InvokeFrom == 'Server') %} - networkComponent->{{ UpperFirst(Property.attrib['Name']) }}({{ ', '.join(paramNames) }}); -{% elif (InvokeFrom == 'Authority') or (InvokeFrom == 'Autonomous') %} - {{ ClassName }}Controller* controller = static_cast<{{ ClassName }}Controller*>(networkComponent->GetController()); - if (!controller) - { - AZ_Warning("Network RPC", false, "{{ ClassName }} {{ UpperFirst(Property.attrib['Name']) }}ByEntityId method failed. Entity '%s' (id: %s) {{ ClassName }} is missing the network controller. This RemoteProcedure can only be invoked from {{InvokeFrom}} network entities, because this entity doesn't have a controller, it must not be a {{InvokeFrom}} entity. Please check your network context before attempting to call {{ UpperFirst(Property.attrib['Name']) }}.", entity->GetName().c_str(), id.ToString().c_str()) - return; - } - controller->{{ UpperFirst(Property.attrib['Name']) }}({{ ', '.join(paramNames) }}); -{% endif %} - }, { { { "Source", "The Source containing the {{ ClassName }}Controller" }{% for paramName in paramNames %}, {"{{ paramName }}"}{% endfor %}}}) + AZ::Entity* entity = AZ::Interface::Get()->FindEntity(id); + if (!entity) + { + AZ_Warning("Network RPC", false, "{{ ClassName }} {{ UpperFirst(Property.attrib['Name']) }}ByEntityId failed. The entity with id %s doesn't exist, please provide a valid entity id.", id.ToString().c_str()) + return; + } + {{ ClassName }}* networkComponent = entity->FindComponent<{{ ClassName }}>(); + if (!networkComponent) + { + AZ_Warning("Network RPC", false, "{{ ClassName }} {{ UpperFirst(Property.attrib['Name']) }}ByEntityId failed. Entity '%s' (id: %s) is missing {{ ClassName }}, be sure to add {{ ClassName }} to this entity.", entity->GetName().c_str(), id.ToString().c_str()) + return; + } +{% if (InvokeFrom == 'Server') %} + networkComponent->{{ UpperFirst(Property.attrib['Name']) }}({{ ', '.join(paramNames) }}); +{% elif (InvokeFrom == 'Authority') or (InvokeFrom == 'Autonomous') %} + {{ ClassName }}Controller* controller = static_cast<{{ ClassName }}Controller*>(networkComponent->GetController()); + if (!controller) + { + AZ_Warning("Network RPC", false, "{{ ClassName }} {{ UpperFirst(Property.attrib['Name']) }}ByEntityId method failed. Entity '%s' (id: %s) {{ ClassName }} is missing the network controller. This RemoteProcedure can only be invoked from {{InvokeFrom}} network entities, because this entity doesn't have a controller, it must not be a {{InvokeFrom}} entity. Please check your network context before attempting to call {{ UpperFirst(Property.attrib['Name']) }}.", entity->GetName().c_str(), id.ToString().c_str()) + return; + } + controller->{{ UpperFirst(Property.attrib['Name']) }}({{ ', '.join(paramNames) }}); +{% endif %} + }, { { { "Source", "The Source containing the {{ ClassName }}Controller" }{% for paramName in paramNames %}, {"{{ paramName }}"}{% endfor %}}}) ->Attribute(AZ::Script::Attributes::ToolTip, "{{Property.attrib['Description']}}") {% endif %} {% endcall %} diff --git a/Gems/Multiplayer/Code/Source/Components/NetBindComponent.cpp b/Gems/Multiplayer/Code/Source/Components/NetBindComponent.cpp index e7cf297f1e..beb17ed9f6 100644 --- a/Gems/Multiplayer/Code/Source/Components/NetBindComponent.cpp +++ b/Gems/Multiplayer/Code/Source/Components/NetBindComponent.cpp @@ -39,8 +39,8 @@ namespace Multiplayer "Network Binding", "The Network Binding component marks an entity as able to be replicated across the network") ->ClassElement(AZ::Edit::ClassElements::EditorData, "") ->Attribute(AZ::Edit::Attributes::Category, "Multiplayer") - ->Attribute(AZ::Edit::Attributes::Icon, "Icons/Components/NetBind.png") - ->Attribute(AZ::Edit::Attributes::ViewportIcon, "Icons/Components/Viewport/NetBind.png") + ->Attribute(AZ::Edit::Attributes::Icon, "Icons/Components/NetBinding.svg") + ->Attribute(AZ::Edit::Attributes::ViewportIcon, "Icons/Components/Viewport/NetBinding.svg") ->Attribute(AZ::Edit::Attributes::AppearsInAddComponentMenu, AZ_CRC_CE("Game")); } } diff --git a/Gems/Multiplayer/Code/Source/Editor/MultiplayerEditorConnection.cpp b/Gems/Multiplayer/Code/Source/Editor/MultiplayerEditorConnection.cpp index 66b14579fa..c8c1ed15bd 100644 --- a/Gems/Multiplayer/Code/Source/Editor/MultiplayerEditorConnection.cpp +++ b/Gems/Multiplayer/Code/Source/Editor/MultiplayerEditorConnection.cpp @@ -41,6 +41,12 @@ namespace Multiplayer // Automated testing listens for these logs if (editorsv_isDedicated) { + // Server logs will be piped to the editor so turn off buffering, + // otherwise it'll take a lot of logs to fill up the buffer before stdout is finally flushed. + // This isn't optimal, but will only affect editor-servers (used when testing multiplayer levels in Editor gameplay mode) and not production servers. + // Note: _IOLBF (flush on newlines) won't work for Automated Testing which uses a headless server app and will fall back to _IOFBF (full buffering) + setvbuf(stdout, NULL, _IONBF, 0); + // If the settings registry is not available at this point, // then something catastrophic has happened in the application startup. // That should have been caught and messaged out earlier in startup. @@ -52,7 +58,7 @@ namespace Multiplayer { ActivateDedicatedEditorServer(); }, - "LegacySystemInterfaceCreated"); + "CriticalAssetsCompiled"); } } } @@ -235,5 +241,4 @@ namespace Multiplayer { return MultiplayerEditorPackets::DispatchPacket(connection, packetHeader, serializer, *this); } - } diff --git a/Gems/Multiplayer/Code/Source/Editor/MultiplayerEditorConnection.h b/Gems/Multiplayer/Code/Source/Editor/MultiplayerEditorConnection.h index 0c892c847f..721c7e0a0f 100644 --- a/Gems/Multiplayer/Code/Source/Editor/MultiplayerEditorConnection.h +++ b/Gems/Multiplayer/Code/Source/Editor/MultiplayerEditorConnection.h @@ -12,6 +12,7 @@ #include #include #include +#include namespace AzNetworking { diff --git a/Gems/Multiplayer/Code/Source/NetworkEntity/NetworkSpawnableLibrary.cpp b/Gems/Multiplayer/Code/Source/NetworkEntity/NetworkSpawnableLibrary.cpp index ba8836b6e6..f60778dbb4 100644 --- a/Gems/Multiplayer/Code/Source/NetworkEntity/NetworkSpawnableLibrary.cpp +++ b/Gems/Multiplayer/Code/Source/NetworkEntity/NetworkSpawnableLibrary.cpp @@ -8,6 +8,7 @@ #include #include +#include #include #include #include @@ -17,12 +18,20 @@ namespace Multiplayer NetworkSpawnableLibrary::NetworkSpawnableLibrary() { AZ::Interface::Register(this); - AzFramework::AssetCatalogEventBus::Handler::BusConnect(); + if (auto settingsRegistry{ AZ::SettingsRegistry::Get() }; settingsRegistry != nullptr) + { + auto LifecycleCallback = [this](AZStd::string_view, AZ::SettingsRegistryInterface::Type) + { + BuildSpawnablesList(); + }; + AZ::ComponentApplicationLifecycle::RegisterHandler(*settingsRegistry, m_criticalAssetsHandler, + AZStd::move(LifecycleCallback), "CriticalAssetsCompiled"); + } } NetworkSpawnableLibrary::~NetworkSpawnableLibrary() { - AzFramework::AssetCatalogEventBus::Handler::BusDisconnect(); + m_criticalAssetsHandler = {}; AZ::Interface::Unregister(this); } @@ -50,11 +59,6 @@ namespace Multiplayer m_spawnablesReverseLookup[id] = name; } - void NetworkSpawnableLibrary::OnCatalogLoaded([[maybe_unused]] const char* catalogFile) - { - BuildSpawnablesList(); - } - AZ::Name NetworkSpawnableLibrary::GetSpawnableNameFromAssetId(AZ::Data::AssetId assetId) { if (assetId.IsValid()) diff --git a/Gems/Multiplayer/Code/Source/NetworkEntity/NetworkSpawnableLibrary.h b/Gems/Multiplayer/Code/Source/NetworkEntity/NetworkSpawnableLibrary.h index 1cec63f81d..0fc3ae07cc 100644 --- a/Gems/Multiplayer/Code/Source/NetworkEntity/NetworkSpawnableLibrary.h +++ b/Gems/Multiplayer/Code/Source/NetworkEntity/NetworkSpawnableLibrary.h @@ -9,14 +9,13 @@ #pragma once #include -#include +#include namespace Multiplayer { /// Implementation of the network prefab library interface. class NetworkSpawnableLibrary final : public INetworkSpawnableLibrary - , private AzFramework::AssetCatalogEventBus::Handler { public: AZ_RTTI(NetworkSpawnableLibrary, "{65E15F33-E893-49C2-A8E2-B6A8A6EF31E0}", INetworkSpawnableLibrary); @@ -30,11 +29,10 @@ namespace Multiplayer AZ::Name GetSpawnableNameFromAssetId(AZ::Data::AssetId assetId) override; AZ::Data::AssetId GetAssetIdByName(AZ::Name name) override; - /// AssetCatalogEventBus overrides. - void OnCatalogLoaded(const char* catalogFile) override; private: AZStd::unordered_map m_spawnables; AZStd::unordered_map m_spawnablesReverseLookup; + AZ::SettingsRegistryInterface::NotifyEventHandler m_criticalAssetsHandler; }; } diff --git a/Gems/Multiplayer/Code/Source/Pipeline/NetworkPrefabProcessor.cpp b/Gems/Multiplayer/Code/Source/Pipeline/NetworkPrefabProcessor.cpp index 2a6baed411..a797523bc0 100644 --- a/Gems/Multiplayer/Code/Source/Pipeline/NetworkPrefabProcessor.cpp +++ b/Gems/Multiplayer/Code/Source/Pipeline/NetworkPrefabProcessor.cpp @@ -20,11 +20,10 @@ namespace Multiplayer { - using AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessor; - using AzToolsFramework::Prefab::PrefabConversionUtils::ProcessedObjectStore; - - void NetworkPrefabProcessor::Process(PrefabProcessorContext& context) + void NetworkPrefabProcessor::Process(AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context) { + using AzToolsFramework::Prefab::PrefabConversionUtils::PrefabDocument; + IMultiplayerTools* mpTools = AZ::Interface::Get(); if (mpTools) { @@ -33,11 +32,17 @@ namespace Multiplayer AZ::DataStream::StreamType serializationFormat = GetAzSerializationFormat(); - context.ListPrefabs([&context, serializationFormat](AZStd::string_view prefabName, PrefabDom& prefab) { - ProcessPrefab(context, prefabName, prefab, serializationFormat); - }); + bool networkPrefabsAdded = false; + context.ListPrefabs( + [&networkPrefabsAdded, &context, serializationFormat](PrefabDocument& prefab) + { + if (ProcessPrefab(context, prefab, serializationFormat)) + { + networkPrefabsAdded = true; + } + }); - if (mpTools && !context.GetProcessedObjects().empty()) + if (mpTools && networkPrefabsAdded) { mpTools->SetDidProcessNetworkPrefabs(true); } @@ -59,28 +64,6 @@ namespace Multiplayer } } - static AZStd::unique_ptr LoadInstanceFromPrefab(const PrefabDom& prefab) - { - using namespace AzToolsFramework::Prefab; - - // convert Prefab DOM into Prefab Instance. - AZStd::unique_ptr sourceInstance(aznew Instance()); - if (!PrefabDomUtils::LoadInstanceFromPrefabDom(*sourceInstance, prefab, PrefabDomUtils::LoadFlags::AssignRandomEntityId)) - { - PrefabDomValueConstReference sourceReference = PrefabDomUtils::FindPrefabDomValue(prefab, PrefabDomUtils::SourceName); - - AZStd::string errorMessage("NetworkPrefabProcessor: Failed to Load Prefab Instance from given Prefab Dom."); - if (sourceReference.has_value() && sourceReference->get().IsString() && sourceReference->get().GetStringLength() != 0) - { - AZStd::string_view source(sourceReference->get().GetString(), sourceReference->get().GetStringLength()); - errorMessage += AZStd::string::format("Prefab Source: %.*s", AZ_STRING_ARG(source)); - } - AZ_Error("NetworkPrefabProcessor", false, errorMessage.c_str()); - return nullptr; - } - return sourceInstance; - } - static void GatherNetEntities( AzToolsFramework::Prefab::Instance* instance, AZStd::unordered_map& entityToInstanceMap, @@ -103,18 +86,15 @@ namespace Multiplayer }); } - void NetworkPrefabProcessor::ProcessPrefab(PrefabProcessorContext& context, AZStd::string_view prefabName, PrefabDom& prefab, AZ::DataStream::StreamType serializationFormat) + bool NetworkPrefabProcessor::ProcessPrefab( + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context, + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabDocument& prefab, + AZ::DataStream::StreamType serializationFormat) { + using AzToolsFramework::Prefab::PrefabConversionUtils::ProcessedObjectStore; using namespace AzToolsFramework::Prefab; - // convert Prefab DOM into Prefab Instance. - AZStd::unique_ptr sourceInstance = LoadInstanceFromPrefab(prefab); - if (!sourceInstance) - { - return; - } - - AZStd::string uniqueName = prefabName; + AZStd::string uniqueName = prefab.GetName(); uniqueName += ".network.spawnable"; auto serializer = [serializationFormat](AZStd::vector& output, const ProcessedObjectStore& object) -> bool { @@ -127,15 +107,16 @@ namespace Multiplayer ProcessedObjectStore::Create(uniqueName, context.GetSourceUuid(), AZStd::move(serializer)); auto& netSpawnableEntities = networkSpawnable->GetEntities(); + Instance& sourceInstance = prefab.GetInstance(); // Grab all net entities with their corresponding Instances to handle nested prefabs correctly AZStd::unordered_map netEntityToInstanceMap; AZStd::vector prefabNetEntities; - GatherNetEntities(sourceInstance.get(), netEntityToInstanceMap, prefabNetEntities); + GatherNetEntities(&sourceInstance, netEntityToInstanceMap, prefabNetEntities); if (prefabNetEntities.empty()) { // No networked entities in the prefab, no need to do anything in this processor. - return; + return false; } // Sort the entities prior to processing. The entities will end up in the net spawnable in this order. @@ -182,7 +163,7 @@ namespace Multiplayer // Add net spawnable asset holder to the prefab root { - EntityOptionalReference containerEntityRef = sourceInstance->GetContainerEntity(); + EntityOptionalReference containerEntityRef = sourceInstance.GetContainerEntity(); if (containerEntityRef.has_value()) { auto* networkSpawnableHolderComponent = containerEntityRef.value().get().CreateComponent(); @@ -193,18 +174,12 @@ namespace Multiplayer AZ::Entity* networkSpawnableHolderEntity = aznew AZ::Entity(uniqueName); auto* networkSpawnableHolderComponent = networkSpawnableHolderEntity->CreateComponent(); networkSpawnableHolderComponent->SetNetworkSpawnableAsset(networkSpawnableAsset); - sourceInstance->AddEntity(*networkSpawnableHolderEntity); + sourceInstance.AddEntity(*networkSpawnableHolderEntity); } } - // save the final result in the target Prefab DOM. - if (!PrefabDomUtils::StoreInstanceInPrefabDom(*sourceInstance, prefab)) - { - AZ_Error("NetworkPrefabProcessor", false, "Saving exported Prefab Instance within a Prefab Dom failed."); - return; - } - context.GetProcessedObjects().push_back(AZStd::move(object)); + return true; } AZ::DataStream::StreamType NetworkPrefabProcessor::GetAzSerializationFormat() const diff --git a/Gems/Multiplayer/Code/Source/Pipeline/NetworkPrefabProcessor.h b/Gems/Multiplayer/Code/Source/Pipeline/NetworkPrefabProcessor.h index 0fd3529db7..ef8912467d 100644 --- a/Gems/Multiplayer/Code/Source/Pipeline/NetworkPrefabProcessor.h +++ b/Gems/Multiplayer/Code/Source/Pipeline/NetworkPrefabProcessor.h @@ -14,23 +14,23 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils { class PrefabProcessorContext; + class PrefabDocument; } namespace Multiplayer { - using AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessor; - using AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext; - using AzToolsFramework::Prefab::PrefabDom; - - class NetworkPrefabProcessor : public PrefabProcessor + class NetworkPrefabProcessor : public AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessor { public: AZ_CLASS_ALLOCATOR(NetworkPrefabProcessor, AZ::SystemAllocator, 0); - AZ_RTTI(Multiplayer::NetworkPrefabProcessor, "{AF6C36DA-CBB9-4DF4-AE2D-7BC6CCE65176}", PrefabProcessor); + AZ_RTTI( + Multiplayer::NetworkPrefabProcessor, + "{AF6C36DA-CBB9-4DF4-AE2D-7BC6CCE65176}", + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessor); ~NetworkPrefabProcessor() override = default; - void Process(PrefabProcessorContext& context) override; + void Process(AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context) override; static void Reflect(AZ::ReflectContext* context); @@ -44,7 +44,10 @@ namespace Multiplayer AZ::DataStream::StreamType GetAzSerializationFormat() const; protected: - static void ProcessPrefab(PrefabProcessorContext& context, AZStd::string_view prefabName, PrefabDom& prefab, AZ::DataStream::StreamType serializationFormat); + static bool ProcessPrefab( + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext& context, + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabDocument& prefab, + AZ::DataStream::StreamType serializationFormat); SerializationFormats m_serializationFormat = SerializationFormats::Binary; }; diff --git a/Gems/Multiplayer/Code/Tests/PrefabProcessingTests.cpp b/Gems/Multiplayer/Code/Tests/PrefabProcessingTests.cpp index 42a817987e..aef13fbfe2 100644 --- a/Gems/Multiplayer/Code/Tests/PrefabProcessingTests.cpp +++ b/Gems/Multiplayer/Code/Tests/PrefabProcessingTests.cpp @@ -57,6 +57,7 @@ namespace UnitTest TEST_F(PrefabProcessingTestFixture, NetworkPrefabProcessor_ProcessPrefabTwoEntities_NetEntityGoesToNetSpawnable) { using AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext; + using AzToolsFramework::Prefab::PrefabConversionUtils::PrefabDocument; AZStd::vector entities; @@ -74,7 +75,9 @@ namespace UnitTest // Add the prefab into the Prefab Processor Context const AZStd::string prefabName = "testPrefab"; PrefabProcessorContext prefabProcessorContext{AZ::Uuid::CreateRandom()}; - prefabProcessorContext.AddPrefab(prefabName, AZStd::move(prefabDom)); + PrefabDocument document(prefabName); + ASSERT_TRUE(document.SetPrefabDom(AZStd::move(prefabDom))); + prefabProcessorContext.AddPrefab(AZStd::move(document)); // Request NetworkPrefabProcessor to process the prefab Multiplayer::NetworkPrefabProcessor processor; diff --git a/Gems/Multiplayer/gem.json b/Gems/Multiplayer/gem.json index f895c78c5d..2b412084af 100644 --- a/Gems/Multiplayer/gem.json +++ b/Gems/Multiplayer/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Multiplayer Gem provides a public API for multiplayer functionality such as connecting and hosting.", "canonical_tags": [ @@ -16,6 +17,7 @@ ], "icon_path": "preview.png", "requirements": "", + "documentation_url": "", "dependencies": [ "CertificateManager", "Atom_Feature_Common", diff --git a/Gems/MultiplayerCompression/gem.json b/Gems/MultiplayerCompression/gem.json index 98156cc404..a9cf3fa460 100644 --- a/Gems/MultiplayerCompression/gem.json +++ b/Gems/MultiplayerCompression/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Multiplayer Compression Gem provides an open source Compressor for use with AzNetworking's transport layer.", "canonical_tags": [ diff --git a/Gems/NvCloth/CMakeLists.txt b/Gems/NvCloth/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/NvCloth/CMakeLists.txt +++ b/Gems/NvCloth/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/NvCloth/Code/CMakeLists.txt b/Gems/NvCloth/Code/CMakeLists.txt index 5b5bba9d8b..76f5bcfeb8 100644 --- a/Gems/NvCloth/Code/CMakeLists.txt +++ b/Gems/NvCloth/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) #for PAL_TRAIT_NVCLOTH Traits diff --git a/Gems/NvCloth/gem.json b/Gems/NvCloth/gem.json index 86a70b9373..9494d65e82 100644 --- a/Gems/NvCloth/gem.json +++ b/Gems/NvCloth/gem.json @@ -2,8 +2,9 @@ "gem_name": "NvCloth", "display_name": "NVIDIA Cloth (NvCloth)", "license": "Apache-2.0 Or MIT", - "origin": "Open 3D Engine - o3de.org", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The NVIDIA Cloth Gem provides functionality to create fast, realistic cloth simulation with the NVIDIA Cloth library.", "canonical_tags": [ diff --git a/Gems/PhysX/CMakeLists.txt b/Gems/PhysX/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/PhysX/CMakeLists.txt +++ b/Gems/PhysX/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/PhysX/Code/CMakeLists.txt b/Gems/PhysX/Code/CMakeLists.txt index f045d6b00d..1cad877542 100644 --- a/Gems/PhysX/Code/CMakeLists.txt +++ b/Gems/PhysX/Code/CMakeLists.txt @@ -8,7 +8,7 @@ add_subdirectory(NumericalMethods) -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # for PAL_TRAIT_PHYSX_SUPPORTED set(LY_PHYSX_ENABLE_RUNNING_BENCHMARKS OFF CACHE BOOL "Adds a target to allow running of the physx benchmarks.") diff --git a/Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp b/Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp index f4cdd01889..1151c0ffff 100644 --- a/Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp +++ b/Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp @@ -73,6 +73,7 @@ namespace PhysX::Utils::Characters physx::PxMaterial* pxMaterial = static_cast(materials.front()->GetNativePointer()); controllerDesc.material = pxMaterial; + controllerDesc.position = PxMathConvertExtended(characterConfig.m_position); controllerDesc.slopeLimit = cosf(AZ::DegToRad(characterConfig.m_maximumSlopeAngle)); controllerDesc.stepOffset = characterConfig.m_stepHeight; controllerDesc.upDirection = characterConfig.m_upDirection.IsZero() diff --git a/Gems/PhysX/Code/Source/System/PhysXSystem.cpp b/Gems/PhysX/Code/Source/System/PhysXSystem.cpp index 168adc8910..39c0dfc686 100644 --- a/Gems/PhysX/Code/Source/System/PhysXSystem.cpp +++ b/Gems/PhysX/Code/Source/System/PhysXSystem.cpp @@ -103,15 +103,13 @@ namespace PhysX if (auto* settingsRegistry = AZ::SettingsRegistry::Get(); settingsRegistry != nullptr) { - // Automatically register the event if it's not registered, because - // this system is initialized before the settings registry has loaded the event list. AZ::ComponentApplicationLifecycle::RegisterHandler( *settingsRegistry, m_componentApplicationLifecycleHandler, [this]([[maybe_unused]] AZStd::string_view path, [[maybe_unused]] AZ::SettingsRegistryInterface::Type type) { InitializeMaterialLibrary(); }, - "LegacySystemInterfaceCreated"); // LegacySystemInterfaceCreated is signaled after critical assets have been processed + "CriticalAssetsCompiled"); } m_state = State::Initialized; diff --git a/Gems/PhysX/Code/Source/WindProvider.cpp b/Gems/PhysX/Code/Source/WindProvider.cpp index c7d5d0863b..3646687ad7 100644 --- a/Gems/PhysX/Code/Source/WindProvider.cpp +++ b/Gems/PhysX/Code/Source/WindProvider.cpp @@ -159,6 +159,12 @@ namespace PhysX AZStd::swap(m_entityTransformHandlers[index], m_entityTransformHandlers.back()); m_entityTransformHandlers.pop_back(); + // When deleting entity from handler's m_entities, the AABB should be appended to m_pendingAabbUpdates + // for local wind handler to broadcast OnWindChanged to notify relative entities of wind changes in OnTick(). + m_pendingAabbUpdates.push_back(); + ColliderShapeRequestBus::EventResult(m_pendingAabbUpdates.back(), + entityId, &ColliderShapeRequestBus::Events::GetColliderShapeAabb); + m_changed = true; } } diff --git a/Gems/PhysXDebug/CMakeLists.txt b/Gems/PhysXDebug/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/PhysXDebug/CMakeLists.txt +++ b/Gems/PhysXDebug/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/PhysXDebug/Code/CMakeLists.txt b/Gems/PhysXDebug/Code/CMakeLists.txt index 3ddec9d105..0886f2bf34 100644 --- a/Gems/PhysXDebug/Code/CMakeLists.txt +++ b/Gems/PhysXDebug/Code/CMakeLists.txt @@ -6,7 +6,11 @@ # # -ly_get_list_relative_pal_filename(physx_pal_source_dir ${LY_ROOT_FOLDER}/Gems/PhysX/Code/Source/Platform/${PAL_PLATFORM_NAME}) +# This gem relies on the PhysX gem +o3de_find_gem("PhysX" physx_gem_path) +set(physx_gem_json ${physx_gem_path}/gem.json) +o3de_restricted_path(${physx_gem_json} physx_gem_restricted_path physx_gem_parent_relative_path) +o3de_pal_dir(physx_pal_source_dir ${physx_gem_path}/Code/Source/Platform/${PAL_PLATFORM_NAME} ${physx_gem_restricted_path} ${physx_gem_path} ${physx_gem_parent_relative_path}) include(${physx_pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # for PAL_TRAIT_PHYSX_SUPPORTED diff --git a/Gems/PhysXDebug/gem.json b/Gems/PhysXDebug/gem.json index 2d9f4dc24d..1087eefad4 100644 --- a/Gems/PhysXDebug/gem.json +++ b/Gems/PhysXDebug/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The PhysX Debug Gem provides debugging functionality and visualizations for NVIDIA PhysX in Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/Prefab/PrefabBuilder/PrefabBuilderComponent.cpp b/Gems/Prefab/PrefabBuilder/PrefabBuilderComponent.cpp index 6107226783..71464501ba 100644 --- a/Gems/Prefab/PrefabBuilder/PrefabBuilderComponent.cpp +++ b/Gems/Prefab/PrefabBuilder/PrefabBuilderComponent.cpp @@ -237,7 +237,7 @@ namespace AZ::Prefab bool PrefabBuilderComponent::ProcessPrefab( const AZ::PlatformTagSet& platformTags, const char* filePath, AZ::IO::PathView tempDirPath, const AZ::Uuid& sourceFileUuid, - AzToolsFramework::Prefab::PrefabDom& mutableRootDom, AZStd::vector& jobProducts) + AzToolsFramework::Prefab::PrefabDom&& rootDom, AZStd::vector& jobProducts) { AzToolsFramework::Prefab::PrefabConversionUtils::PrefabProcessorContext context(sourceFileUuid); AZStd::string rootPrefabName; @@ -247,7 +247,9 @@ namespace AZ::Prefab filePath); return false; } - context.AddPrefab(AZStd::move(rootPrefabName), AZStd::move(mutableRootDom)); + AzToolsFramework::Prefab::PrefabConversionUtils::PrefabDocument rootDocument(AZStd::move(rootPrefabName)); + rootDocument.SetPrefabDom(AZStd::move(rootDom)); + context.AddPrefab(AZStd::move(rootDocument)); context.SetPlatformTags(AZStd::move(platformTags)); @@ -319,8 +321,8 @@ namespace AZ::Prefab }); if (ProcessPrefab( - platformTags, request.m_fullPath.c_str(), request.m_tempDirPath.c_str(), request.m_sourceFileUUID, mutableRootDom, - response.m_outputProducts)) + platformTags, request.m_fullPath.c_str(), request.m_tempDirPath.c_str(), request.m_sourceFileUUID, + AZStd::move(mutableRootDom), response.m_outputProducts)) { response.m_resultCode = AssetBuilderSDK::ProcessJobResult_Success; } diff --git a/Gems/Prefab/PrefabBuilder/PrefabBuilderComponent.h b/Gems/Prefab/PrefabBuilder/PrefabBuilderComponent.h index 9ebdd690f5..73ef6b0426 100644 --- a/Gems/Prefab/PrefabBuilder/PrefabBuilderComponent.h +++ b/Gems/Prefab/PrefabBuilder/PrefabBuilderComponent.h @@ -53,7 +53,7 @@ namespace AZ::Prefab const AzToolsFramework::Prefab::PrefabDom& genericDocument); bool ProcessPrefab( const AZ::PlatformTagSet& platformTags, const char* filePath, AZ::IO::PathView tempDirPath, const AZ::Uuid& sourceFileUuid, - AzToolsFramework::Prefab::PrefabDom& mutableRootDom, + AzToolsFramework::Prefab::PrefabDom&& rootDom, AZStd::vector& jobProducts); protected: diff --git a/Gems/Prefab/PrefabBuilder/PrefabBuilderTests.cpp b/Gems/Prefab/PrefabBuilder/PrefabBuilderTests.cpp index 2ed05b4dfe..5ee23a9e3c 100644 --- a/Gems/Prefab/PrefabBuilder/PrefabBuilderTests.cpp +++ b/Gems/Prefab/PrefabBuilder/PrefabBuilderTests.cpp @@ -106,7 +106,8 @@ namespace UnitTest AzToolsFramework::Prefab::PrefabDom prefabDom; prefabDom.CopyFrom(prefabSystemComponentInterface->FindTemplateDom(parentInstance->GetTemplateId()), prefabDom.GetAllocator(), false); - ASSERT_TRUE(prefabBuilderComponent.ProcessPrefab({AZ::Crc32("pc")}, "parent.prefab", "unused", AZ::Uuid(), prefabDom, jobProducts)); + ASSERT_TRUE(prefabBuilderComponent.ProcessPrefab( + { AZ::Crc32("pc") }, "parent.prefab", "unused", AZ::Uuid(), AZStd::move(prefabDom), jobProducts)); ASSERT_EQ(jobProducts.size(), 1); ASSERT_EQ(jobProducts[0].m_dependencies.size(), 1); diff --git a/Gems/Prefab/PrefabBuilder/gem.json b/Gems/Prefab/PrefabBuilder/gem.json index 2233a7235e..1c0dcd9a72 100644 --- a/Gems/Prefab/PrefabBuilder/gem.json +++ b/Gems/Prefab/PrefabBuilder/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Prefab Builder Gem provides an Asset Processor module for prefabs, which are complex assets built by combining smaller entities.", "canonical_tags": [ diff --git a/Gems/Presence/CMakeLists.txt b/Gems/Presence/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Presence/CMakeLists.txt +++ b/Gems/Presence/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Presence/Code/CMakeLists.txt b/Gems/Presence/Code/CMakeLists.txt index c1c807d432..cc84771201 100644 --- a/Gems/Presence/Code/CMakeLists.txt +++ b/Gems/Presence/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME Presence.Headers HEADERONLY diff --git a/Gems/Presence/gem.json b/Gems/Presence/gem.json index 624af2e62d..48d9dd5ef0 100644 --- a/Gems/Presence/gem.json +++ b/Gems/Presence/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Presence Gem provides a target platform agnostic interface for Presence services.", "canonical_tags": [ diff --git a/Gems/PrimitiveAssets/gem.json b/Gems/PrimitiveAssets/gem.json index 0e4c4689dc..7669477220 100644 --- a/Gems/PrimitiveAssets/gem.json +++ b/Gems/PrimitiveAssets/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "The Primitive Assets Gem provides primitive shape mesh assets with physics enabled.", "canonical_tags": [ diff --git a/Gems/Profiler/gem.json b/Gems/Profiler/gem.json index b160bc4b3c..40478deae1 100644 --- a/Gems/Profiler/gem.json +++ b/Gems/Profiler/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "A collection of utilities for capturing performance data", "canonical_tags": [ diff --git a/Gems/PythonAssetBuilder/gem.json b/Gems/PythonAssetBuilder/gem.json index 8046104f03..54fbb949f9 100644 --- a/Gems/PythonAssetBuilder/gem.json +++ b/Gems/PythonAssetBuilder/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Python Asset Builder Gem provides functionality to implement custom asset builders in Python for Asset Processor.", "canonical_tags": [ diff --git a/Gems/QtForPython/Code/CMakeLists.txt b/Gems/QtForPython/Code/CMakeLists.txt index da763978a6..d63c71492d 100644 --- a/Gems/QtForPython/Code/CMakeLists.txt +++ b/Gems/QtForPython/Code/CMakeLists.txt @@ -9,7 +9,7 @@ if(NOT PAL_TRAIT_BUILD_HOST_TOOLS) return() endif() -ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) include(${CMAKE_CURRENT_SOURCE_DIR}/Source/Platform/${PAL_PLATFORM_NAME}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/Gems/QtForPython/gem.json b/Gems/QtForPython/gem.json index 17d3a26f21..63805a5bc7 100644 --- a/Gems/QtForPython/gem.json +++ b/Gems/QtForPython/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Qt for Python Gem provides the PySide2 Python libraries to manage Qt widgets.", "canonical_tags": [ diff --git a/Gems/SaveData/CMakeLists.txt b/Gems/SaveData/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/SaveData/CMakeLists.txt +++ b/Gems/SaveData/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/SaveData/Code/CMakeLists.txt b/Gems/SaveData/Code/CMakeLists.txt index 38d145f8e5..5d4eb361cc 100644 --- a/Gems/SaveData/Code/CMakeLists.txt +++ b/Gems/SaveData/Code/CMakeLists.txt @@ -6,7 +6,7 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) ly_add_target( NAME SaveData.Static STATIC diff --git a/Gems/SaveData/gem.json b/Gems/SaveData/gem.json index 1ee5a54cec..3a686242d7 100644 --- a/Gems/SaveData/gem.json +++ b/Gems/SaveData/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Save Data Gem provides a platform independent API to save and load persistent user data in Open 3D Engine projects.", "canonical_tags": [ diff --git a/Gems/SceneLoggingExample/gem.json b/Gems/SceneLoggingExample/gem.json index ad950f3992..dc6b5179b6 100644 --- a/Gems/SceneLoggingExample/gem.json +++ b/Gems/SceneLoggingExample/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "The Scene Logging Example Gem demonstrates the basics of extending the Open 3D Engine Scene API by adding additional logging to the pipeline.", "canonical_tags": [ diff --git a/Gems/SceneProcessing/gem.json b/Gems/SceneProcessing/gem.json index 576460d0a9..3689c2500a 100644 --- a/Gems/SceneProcessing/gem.json +++ b/Gems/SceneProcessing/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Scene Processing Gem provides Scene Settings, a tool you can use to specify the default settings for processing asset files for actors, meshes, motions, and PhysX.", "canonical_tags": [ diff --git a/Gems/ScriptCanvas/Assets/TranslationAssets/EBus/Senders/CameraRequestBus.names b/Gems/ScriptCanvas/Assets/TranslationAssets/EBus/Senders/CameraRequestBus.names index 6c0112bfc2..ad2127c2a1 100644 --- a/Gems/ScriptCanvas/Assets/TranslationAssets/EBus/Senders/CameraRequestBus.names +++ b/Gems/ScriptCanvas/Assets/TranslationAssets/EBus/Senders/CameraRequestBus.names @@ -31,6 +31,66 @@ } ] }, + { + "base": "WorldToScreen", + "entry": { + "name": "In", + "tooltip": "When signaled, this will invoke World To Screen" + }, + "exit": { + "name": "Out", + "tooltip": "Signaled after World To Screen is invoked" + }, + "details": { + "name": "World To Screen" + }, + "params": [ + { + "typeid": "{8379EB7D-01FA-4538-B64B-A6543B4BE73D}", + "details": { + "name": "World Position" + } + } + ], + "results": [ + { + "typeid": "{3D80F623-C85C-4741-90D0-E4E66164E6BF}", + "details": { + "name": "Screen Position" + } + } + ] + }, + { + "base": "WorldToScreenNdc", + "entry": { + "name": "In", + "tooltip": "When signaled, this will invoke World To Screen Ndc" + }, + "exit": { + "name": "Out", + "tooltip": "Signaled after World To Screen Ndc is invoked" + }, + "details": { + "name": "World To Screen NDC" + }, + "params": [ + { + "typeid": "{8379EB7D-01FA-4538-B64B-A6543B4BE73D}", + "details": { + "name": "World Position" + } + } + ], + "results": [ + { + "typeid": "{3D80F623-C85C-4741-90D0-E4E66164E6BF}", + "details": { + "name": "Screen NDC Position" + } + } + ] + }, { "base": "GetFov", "entry": { @@ -53,6 +113,78 @@ } ] }, + { + "base": "ScreenToWorld", + "entry": { + "name": "In", + "tooltip": "When signaled, this will invoke Screen To World" + }, + "exit": { + "name": "Out", + "tooltip": "Signaled after Screen To World is invoked" + }, + "details": { + "name": "Screen To World" + }, + "params": [ + { + "typeid": "{3D80F623-C85C-4741-90D0-E4E66164E6BF}", + "details": { + "name": "Screen Position" + } + }, + { + "typeid": "{EA2C3E90-AFBE-44D4-A90D-FAAF79BAF93D}", + "details": { + "name": "Depth" + } + } + ], + "results": [ + { + "typeid": "{8379EB7D-01FA-4538-B64B-A6543B4BE73D}", + "details": { + "name": "World Position" + } + } + ] + }, + { + "base": "ScreenNdcToWorld", + "entry": { + "name": "In", + "tooltip": "When signaled, this will invoke Screen Ndc To World" + }, + "exit": { + "name": "Out", + "tooltip": "Signaled after Screen Ndc To World is invoked" + }, + "details": { + "name": "Screen NDC To World" + }, + "params": [ + { + "typeid": "{3D80F623-C85C-4741-90D0-E4E66164E6BF}", + "details": { + "name": "Screen NDC Position" + } + }, + { + "typeid": "{EA2C3E90-AFBE-44D4-A90D-FAAF79BAF93D}", + "details": { + "name": "Depth" + } + } + ], + "results": [ + { + "typeid": "{8379EB7D-01FA-4538-B64B-A6543B4BE73D}", + "details": { + "name": "World Position" + } + } + ] + }, { "base": "SetFovRadians", "entry": { @@ -356,4 +488,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/Gems/ScriptCanvas/Assets/TranslationAssets/EBus/Senders/UiFlipbookAnimationBus.names b/Gems/ScriptCanvas/Assets/TranslationAssets/EBus/Senders/UiFlipbookAnimationBus.names index c0f62a816b..e869048b0c 100644 --- a/Gems/ScriptCanvas/Assets/TranslationAssets/EBus/Senders/UiFlipbookAnimationBus.names +++ b/Gems/ScriptCanvas/Assets/TranslationAssets/EBus/Senders/UiFlipbookAnimationBus.names @@ -21,7 +21,8 @@ }, "details": { "name": "Get Loop Type", - "tooltip": "Gets the type of looping behavior for the animation" + "tooltip": "Gets the type of looping behavior for the animation", + "subtitle": "UI Flipbook" }, "results": [ { @@ -44,7 +45,8 @@ }, "details": { "name": "Get Reverse Delay", - "tooltip": "Gets the delay (in seconds) before playing the reverse loop sequence (PingPong loop types only)" + "tooltip": "Gets the delay (in seconds) before playing the reverse loop sequence (PingPong loop types only)", + "subtitle": "UI Flipbook" }, "results": [ { @@ -67,7 +69,8 @@ }, "details": { "name": "Set Is Auto Play Enabled", - "tooltip": "Sets whether the animation will begin playing as soon as the element is activated" + "tooltip": "Sets whether the animation will begin playing as soon as the element is activated", + "subtitle": "UI Flipbook" }, "params": [ { @@ -91,7 +94,8 @@ }, "details": { "name": "Set Current Frame", - "tooltip": "Sets the frame to immediately display for the animation" + "tooltip": "Sets the frame to immediately display for the animation", + "subtitle": "UI Flipbook" }, "params": [ { @@ -115,7 +119,8 @@ }, "details": { "name": "Get Loop Start Frame", - "tooltip": "Gets the first frame that is displayed within an animation loop. Applicable only when the \"Loop Type\" is set to anything other than \"None\"" + "tooltip": "Gets the first frame that is displayed within an animation loop. Applicable only when the \"Loop Type\" is set to anything other than \"None\"", + "subtitle": "UI Flipbook" }, "results": [ { @@ -138,7 +143,8 @@ }, "details": { "name": "Set Loop Type", - "tooltip": "Sets the type of looping behavior for this animation" + "tooltip": "Sets the type of looping behavior for this animation", + "subtitle": "UI Flipbook" }, "params": [ { @@ -162,7 +168,8 @@ }, "details": { "name": "Get Start Delay", - "tooltip": "Gets the delay (in seconds) before playing the flipbook (applied only once during playback)" + "tooltip": "Gets the delay (in seconds) before playing the flipbook (applied only once during playback)", + "subtitle": "UI Flipbook" }, "results": [ { @@ -185,7 +192,8 @@ }, "details": { "name": "Set Start Delay", - "tooltip": "Sets the delay (in seconds) before playing the flipbook (applied only once during playback)" + "tooltip": "Sets the delay (in seconds) before playing the flipbook (applied only once during playback)", + "subtitle": "UI Flipbook" }, "params": [ { @@ -209,7 +217,8 @@ }, "details": { "name": "Get Current Frame", - "tooltip": "Gets the frame of the animation currently displayed" + "tooltip": "Gets the frame of the animation currently displayed", + "subtitle": "UI Flipbook" }, "results": [ { @@ -232,7 +241,8 @@ }, "details": { "name": "Get Framerate", - "tooltip": "Gets the speed used to determine when to transition to the next frame. Framerate is defined relative to unit of time, specified by FramerateUnits" + "tooltip": "Gets the speed used to determine when to transition to the next frame. Framerate is defined relative to unit of time, specified by FramerateUnits", + "subtitle": "UI Flipbook" }, "results": [ { @@ -255,7 +265,8 @@ }, "details": { "name": "Set Loop Delay", - "tooltip": "Sets the delay (in seconds) before playing the loop sequence" + "tooltip": "Sets the delay (in seconds) before playing the loop sequence", + "subtitle": "UI Flipbook" }, "params": [ { @@ -279,7 +290,8 @@ }, "details": { "name": "Get Start Frame", - "tooltip": "Gets the first frame to display when starting the animation" + "tooltip": "Gets the first frame to display when starting the animation", + "subtitle": "UI Flipbook" }, "results": [ { @@ -302,7 +314,8 @@ }, "details": { "name": "Set Framerate Unit", - "tooltip": "Sets the framerate unit (0 = Frames per second, 1 = Seconds per frame)" + "tooltip": "Sets the framerate unit (0 = Frames per second, 1 = Seconds per frame)", + "subtitle": "UI Flipbook" }, "params": [ { @@ -326,7 +339,8 @@ }, "details": { "name": "Is Playing", - "tooltip": "Returns whether the animation is currently playing" + "tooltip": "Returns whether the animation is currently playing", + "subtitle": "UI Flipbook" }, "results": [ { @@ -349,7 +363,8 @@ }, "details": { "name": "Set End Frame", - "tooltip": "Sets the last frame to display for the animation" + "tooltip": "Sets the last frame to display for the animation", + "subtitle": "UI Flipbook" }, "params": [ { @@ -373,7 +388,8 @@ }, "details": { "name": "Set Loop Start Frame", - "tooltip": "Sets the first frame that is displayed within an animation loop. Applicable only when the \"Loop Type\" is set to anything other than \"None\"" + "tooltip": "Sets the first frame that is displayed within an animation loop. Applicable only when the \"Loop Type\" is set to anything other than \"None\"", + "subtitle": "UI Flipbook" }, "params": [ { @@ -397,7 +413,8 @@ }, "details": { "name": "Set Reverse Delay", - "tooltip": "Sets the delay (in seconds) before playing the reverse loop sequence (PingPong loop types only)" + "tooltip": "Sets the delay (in seconds) before playing the reverse loop sequence (PingPong loop types only)", + "subtitle": "UI Flipbook" }, "params": [ { @@ -421,7 +438,8 @@ }, "details": { "name": "Stop", - "tooltip": "Ends the animation" + "tooltip": "Ends the animation", + "subtitle": "UI Flipbook" } }, { @@ -436,7 +454,8 @@ }, "details": { "name": "Set Framerate", - "tooltip": "Sets the speed used to determine when to transition to the next frame. Framerate is defined relative to unit of time, specified by FramerateUnits" + "tooltip": "Sets the speed used to determine when to transition to the next frame. Framerate is defined relative to unit of time, specified by FramerateUnits", + "subtitle": "UI Flipbook" }, "params": [ { @@ -460,7 +479,8 @@ }, "details": { "name": "Is Auto Play Enabled", - "tooltip": "Returns whether the animation will begin playing as soon as the element is activated" + "tooltip": "Returns whether the animation will begin playing as soon as the element is activated", + "subtitle": "UI Flipbook" }, "results": [ { @@ -483,7 +503,8 @@ }, "details": { "name": "Start", - "tooltip": "Begins playing the flipbook animation" + "tooltip": "Begins playing the flipbook animation", + "subtitle": "UI Flipbook" } }, { @@ -498,7 +519,8 @@ }, "details": { "name": "Set Start Frame", - "tooltip": "Sets the first frame to display when starting the animation" + "tooltip": "Sets the first frame to display when starting the animation", + "subtitle": "UI Flipbook" }, "params": [ { @@ -522,7 +544,8 @@ }, "details": { "name": "Get End Frame", - "tooltip": "Gets the last frame to display for the animation" + "tooltip": "Gets the last frame to display for the animation", + "subtitle": "UI Flipbook" }, "results": [ { @@ -545,7 +568,8 @@ }, "details": { "name": "Get Framerate Unit", - "tooltip": "Gets the framerate unit (0 = Frames per second, 1 = Seconds per frame)" + "tooltip": "Gets the framerate unit (0 = Frames per second, 1 = Seconds per frame)", + "subtitle": "UI Flipbook" }, "results": [ { @@ -568,7 +592,8 @@ }, "details": { "name": "Get Loop Delay", - "tooltip": "Gets the delay (in seconds) before playing the loop sequence" + "tooltip": "Gets the delay (in seconds) before playing the loop sequence", + "subtitle": "UI Flipbook" }, "results": [ { diff --git a/Gems/ScriptCanvas/Assets/TranslationAssets/Nodes/PhysXWorld_RayCastFromScreenWithGroup.names b/Gems/ScriptCanvas/Assets/TranslationAssets/Nodes/PhysXWorld_RayCastFromScreenWithGroup.names new file mode 100644 index 0000000000..447866ae44 --- /dev/null +++ b/Gems/ScriptCanvas/Assets/TranslationAssets/Nodes/PhysXWorld_RayCastFromScreenWithGroup.names @@ -0,0 +1,88 @@ +{ + "entries": [ + { + "base": "{B164D87F-6620-5A1D-A2BC-CC09BA18C9B1}", + "context": "ScriptCanvas::Node", + "variant": "", + "details": { + "name": "Ray Cast From Screen With Group", + "category": "PhysX/World", + "tooltip": "Returns the first entity hit by a ray cast from the provided absolute 2D screen position." + }, + "slots": [ + { + "base": "Input_In_0", + "details": { + "name": "In" + } + }, + { + "base": "Output_Out_0", + "details": { + "name": "Out" + } + }, + { + "base": "DataInput_Screen Position_0", + "details": { + "name": "Screen Position" + } + }, + { + "base": "DataInput_Distance_1", + "details": { + "name": "Distance" + } + }, + { + "base": "DataInput_Collision group_2", + "details": { + "name": "Collision group" + } + }, + { + "base": "DataInput_Ignore_3", + "details": { + "name": "Ignore" + } + }, + { + "base": "DataOutput_Object hit_0", + "details": { + "name": "Object hit" + } + }, + { + "base": "DataOutput_Position_1", + "details": { + "name": "Position" + } + }, + { + "base": "DataOutput_Normal_2", + "details": { + "name": "Normal" + } + }, + { + "base": "DataOutput_Distance_3", + "details": { + "name": "Distance" + } + }, + { + "base": "DataOutput_EntityId_4", + "details": { + "name": "EntityId" + } + }, + { + "base": "DataOutput_Surface_5", + "details": { + "name": "Surface" + } + } + ] + } + ] +} \ No newline at end of file diff --git a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilder.cpp b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilder.cpp index d62ebb9c3a..fbacfd8c32 100644 --- a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilder.cpp +++ b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilder.cpp @@ -246,6 +246,16 @@ namespace ScriptCanvasBuilder } } + void BuildVariableOverrides::SetHandlesToDescription() + { + m_source = m_source.Describe(); + + for (auto& dependency : m_dependencies) + { + dependency.SetHandlesToDescription(); + } + } + ScriptCanvas::RuntimeDataOverrides ConvertToRuntime(const BuildVariableOverrides& buildOverrides) { ScriptCanvas::RuntimeDataOverrides runtimeOverrides; diff --git a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilder.h b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilder.h index 6e8e176145..1770e48dfa 100644 --- a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilder.h +++ b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilder.h @@ -38,6 +38,8 @@ namespace ScriptCanvasBuilder // use this to initialize the new data, and make sure they have a editor graph variable for proper editor display void PopulateFromParsedResults(ScriptCanvas::Grammar::AbstractCodeModelConstPtr abstractCodeModel, const ScriptCanvas::VariableData& variables); + void SetHandlesToDescription(); + // #functions2 provide an identifier for the node/variable in the source that caused the dependency. the root will not have one. ScriptCanvasEditor::SourceHandle m_source; diff --git a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorker.cpp b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorker.cpp index 62d5febe91..a1a2d1d20f 100644 --- a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorker.cpp +++ b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorker.cpp @@ -62,7 +62,6 @@ namespace ScriptCanvasBuilder } // in terms of job creation, assert on anything but smooth sailing from this point - AZ_Assert(sourceGraph, "Graph component is missing from entity."); AZ_Assert(graphData, "GraphData is missing from entity"); diff --git a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorker.h b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorker.h index d0196d5f5c..142886f98c 100644 --- a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorker.h +++ b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorker.h @@ -59,7 +59,7 @@ namespace ScriptCanvasBuilder CorrectGraphVariableVersion, ReflectEntityIdNodes, FixExecutionStateNodeableConstruction, - + SwitchAssetsToBinary, // add new entries above Current, }; diff --git a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorkerUtility.cpp b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorkerUtility.cpp index fb4bb0a386..64e73de9b9 100644 --- a/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorkerUtility.cpp +++ b/Gems/ScriptCanvas/Code/Builder/ScriptCanvasBuilderWorkerUtility.cpp @@ -521,7 +521,7 @@ namespace ScriptCanvasBuilder { AZ::Data::Asset runtimeAsset; runtimeAsset.Create(AZ::Data::AssetId(input.assetID.m_guid, AZ_CRC("SubgraphInterface", 0xdfe6dc72))); - runtimeAsset.Get()->SetData(subgraphInterface); + runtimeAsset.Get()->m_interfaceData = subgraphInterface; AZStd::vector byteBuffer; AZ::IO::ByteContainerStream byteStream(&byteBuffer); @@ -557,7 +557,7 @@ namespace ScriptCanvasBuilder { AZ::Data::Asset runtimeAsset; runtimeAsset.Create(AZ::Data::AssetId(input.assetID.m_guid, AZ_CRC("RuntimeData", 0x163310ae))); - runtimeAsset.Get()->SetData(runtimeData); + runtimeAsset.Get()->m_runtimeData = runtimeData; AZStd::vector byteBuffer; AZ::IO::ByteContainerStream byteStream(&byteBuffer); diff --git a/Gems/ScriptCanvas/Code/Editor/Components/EditorScriptCanvasComponent.cpp b/Gems/ScriptCanvas/Code/Editor/Components/EditorScriptCanvasComponent.cpp index bb9e829bf5..f8f867d7e3 100644 --- a/Gems/ScriptCanvas/Code/Editor/Components/EditorScriptCanvasComponent.cpp +++ b/Gems/ScriptCanvas/Code/Editor/Components/EditorScriptCanvasComponent.cpp @@ -41,6 +41,7 @@ namespace EditorScriptCanvasComponentCpp PrefabIntegration = 10, InternalDev, AddSourceHandle, + RefactorAssets, // add description above Current }; @@ -241,16 +242,16 @@ namespace ScriptCanvasEditor SetName(m_sourceHandle.Path().Filename().Native()); } - void EditorScriptCanvasComponent::OpenEditor(const AZ::Data::AssetId&, const AZ::Data::AssetType&) + void EditorScriptCanvasComponent::OpenEditor([[maybe_unused]] const AZ::Data::AssetId& assetId, const AZ::Data::AssetType&) { AzToolsFramework::OpenViewPane(LyViewPane::ScriptCanvas); - + AZ::Outcome openOutcome = AZ::Failure(AZStd::string()); - + if (m_sourceHandle.IsDescriptionValid()) { GeneralRequestBus::BroadcastResult(openOutcome, &GeneralRequests::OpenScriptCanvasAsset, m_sourceHandle, Tracker::ScriptCanvasFileState::UNMODIFIED, -1); - + if (!openOutcome) { AZ_Warning("Script Canvas", openOutcome, "%s", openOutcome.GetError().data()); @@ -260,7 +261,7 @@ namespace ScriptCanvasEditor { AzToolsFramework::EntityIdList selectedEntityIds; AzToolsFramework::ToolsApplicationRequestBus::BroadcastResult(selectedEntityIds, &AzToolsFramework::ToolsApplicationRequests::GetSelectedEntities); - + // Going to bypass the multiple selected entities flow for right now. if (selectedEntityIds.size() == 1) { @@ -278,7 +279,7 @@ namespace ScriptCanvasEditor void EditorScriptCanvasComponent::InitializeSource(const SourceHandle& sourceHandle) { - m_sourceHandle = sourceHandle; + m_sourceHandle = sourceHandle.Describe(); } //========================================================================= @@ -344,6 +345,7 @@ namespace ScriptCanvasEditor } m_variableOverrides = parseOutcome.TakeValue(); + m_variableOverrides.SetHandlesToDescription(); m_runtimeDataIsValid = true; } @@ -372,13 +374,7 @@ namespace ScriptCanvasEditor void EditorScriptCanvasComponent::SetPrimaryAsset(const AZ::Data::AssetId& assetId) { m_sourceHandle = SourceHandle(nullptr, assetId.m_guid, {}); - - auto completeAsset = CompleteDescription(m_sourceHandle); - if (completeAsset) - { - m_sourceHandle = *completeAsset; - } - + CompleteDescriptionInPlace(m_sourceHandle); OnScriptCanvasAssetChanged(SourceChangeDescription::SelectionChanged); SetName(m_sourceHandle.Path().Filename().Native()); AzToolsFramework::ToolsApplicationEvents::Bus::Broadcast(&AzToolsFramework::ToolsApplicationEvents::InvalidatePropertyDisplay, AzToolsFramework::Refresh_AttributesAndValues); @@ -398,7 +394,7 @@ namespace ScriptCanvasEditor OnScriptCanvasAssetChanged(SourceChangeDescription::SelectionChanged); return AZ::Edit::PropertyRefreshLevels::EntireTree; } - + void EditorScriptCanvasComponent::OnScriptCanvasAssetChanged(SourceChangeDescription changeDescription) { ScriptCanvas::GraphIdentifier newIdentifier = GetGraphIdentifier(); @@ -416,20 +412,11 @@ namespace ScriptCanvasEditor ClearVariables(); } + m_sourceHandle = m_previousHandle; + if (m_sourceHandle.IsDescriptionValid()) { - if (!m_sourceHandle.Get()) - { - if (auto loaded = LoadFromFile(m_sourceHandle.Path().c_str()); loaded.IsSuccess()) - { - m_sourceHandle = SourceHandle(loaded.TakeValue(), m_sourceHandle.Id(), m_sourceHandle.Path().c_str()); - } - } - - if (m_sourceHandle.Get()) - { - UpdatePropertyDisplay(m_sourceHandle); - } + UpdatePropertyDisplay(); } AzToolsFramework::ToolsApplicationNotificationBus::Broadcast(&AzToolsFramework::ToolsApplicationEvents::InvalidatePropertyDisplay, AzToolsFramework::Refresh_EntireTree_NewContent); @@ -491,14 +478,11 @@ namespace ScriptCanvasEditor return ScriptCanvas::GraphIdentifier(m_sourceHandle.Id(), 0); } - void EditorScriptCanvasComponent::UpdatePropertyDisplay(const SourceHandle& sourceHandle) + void EditorScriptCanvasComponent::UpdatePropertyDisplay() { - if (sourceHandle.IsGraphValid()) - { - BuildGameEntityData(); - UpdateName(); - AzToolsFramework::ToolsApplicationNotificationBus::Broadcast(&AzToolsFramework::ToolsApplicationEvents::InvalidatePropertyDisplay, AzToolsFramework::Refresh_EntireTree_NewContent); - } + BuildGameEntityData(); + UpdateName(); + AzToolsFramework::ToolsApplicationNotificationBus::Broadcast(&AzToolsFramework::ToolsApplicationEvents::InvalidatePropertyDisplay, AzToolsFramework::Refresh_EntireTree_NewContent); } void EditorScriptCanvasComponent::ClearVariables() diff --git a/Gems/ScriptCanvas/Code/Editor/Components/EditorUtils.cpp b/Gems/ScriptCanvas/Code/Editor/Components/EditorUtils.cpp index 2cd2dda89e..363f477fbf 100644 --- a/Gems/ScriptCanvas/Code/Editor/Components/EditorUtils.cpp +++ b/Gems/ScriptCanvas/Code/Editor/Components/EditorUtils.cpp @@ -33,11 +33,6 @@ namespace ScriptCanvasEditor { AZStd::optional CompleteDescription(const SourceHandle& source) { - if (source.IsDescriptionValid()) - { - return source; - } - AzToolsFramework::AssetSystemRequestBus::Events* assetSystem = AzToolsFramework::AssetSystemRequestBus::FindFirstHandler(); if (assetSystem) { diff --git a/Gems/ScriptCanvas/Code/Editor/Framework/ScriptCanvasGraphUtilities.inl b/Gems/ScriptCanvas/Code/Editor/Framework/ScriptCanvasGraphUtilities.inl index 51fef7efcf..f4e97600bc 100644 --- a/Gems/ScriptCanvas/Code/Editor/Framework/ScriptCanvasGraphUtilities.inl +++ b/Gems/ScriptCanvas/Code/Editor/Framework/ScriptCanvasGraphUtilities.inl @@ -30,8 +30,8 @@ namespace ScriptCanvasEditor // over to the override data to simulate build step that does this when building prefabs AZ_INLINE void CopyAssetEntityIdsToOverrides(RuntimeDataOverrides& runtimeDataOverrides) { - runtimeDataOverrides.m_entityIds.reserve(runtimeDataOverrides.m_runtimeAsset->GetData().m_input.m_entityIds.size()); - for (auto& varEntityPar : runtimeDataOverrides.m_runtimeAsset->GetData().m_input.m_entityIds) + runtimeDataOverrides.m_entityIds.reserve(runtimeDataOverrides.m_runtimeAsset->m_runtimeData.m_input.m_entityIds.size()); + for (auto& varEntityPar : runtimeDataOverrides.m_runtimeAsset->m_runtimeData.m_input.m_entityIds) { runtimeDataOverrides.m_entityIds.push_back(varEntityPar.second); } @@ -281,14 +281,14 @@ namespace ScriptCanvasEditor #endif ////////////////////////////////////////////////////////////////////////////////////// loadResult.m_scriptAsset = luaAssetResult.m_scriptAsset; - loadResult.m_runtimeAsset.Get()->GetData().m_script = loadResult.m_scriptAsset; - loadResult.m_runtimeAsset.Get()->GetData().m_input = luaAssetResult.m_runtimeInputs; - loadResult.m_runtimeAsset.Get()->GetData().m_debugMap = luaAssetResult.m_debugMap; + loadResult.m_runtimeAsset.Get()->m_runtimeData.m_script = loadResult.m_scriptAsset; + loadResult.m_runtimeAsset.Get()->m_runtimeData.m_input = luaAssetResult.m_runtimeInputs; + loadResult.m_runtimeAsset.Get()->m_runtimeData.m_debugMap = luaAssetResult.m_debugMap; loadResult.m_runtimeComponent = loadResult.m_entity->CreateComponent(); CopyAssetEntityIdsToOverrides(runtimeDataOverrides); loadResult.m_runtimeComponent->TakeRuntimeDataOverrides(AZStd::move(runtimeDataOverrides)); - Execution::Context::InitializeActivationData(loadResult.m_runtimeAsset->GetData()); - Execution::InitializeInterpretedStatics(loadResult.m_runtimeAsset->GetData()); + Execution::Context::InitializeActivationData(loadResult.m_runtimeAsset->m_runtimeData); + Execution::InitializeInterpretedStatics(loadResult.m_runtimeAsset->m_runtimeData); } else { diff --git a/Gems/ScriptCanvas/Code/Editor/Include/ScriptCanvas/Components/EditorScriptCanvasComponent.h b/Gems/ScriptCanvas/Code/Editor/Include/ScriptCanvas/Components/EditorScriptCanvasComponent.h index ca381445ea..b86df2d9c2 100644 --- a/Gems/ScriptCanvas/Code/Editor/Include/ScriptCanvas/Components/EditorScriptCanvasComponent.h +++ b/Gems/ScriptCanvas/Code/Editor/Include/ScriptCanvas/Components/EditorScriptCanvasComponent.h @@ -121,7 +121,7 @@ namespace ScriptCanvasEditor void UpdateName(); //===================================================================== - void UpdatePropertyDisplay(const SourceHandle& sourceHandle); + void UpdatePropertyDisplay(); //===================================================================== void BuildGameEntityData(); diff --git a/Gems/ScriptCanvas/Code/Editor/Nodes/NodeDisplayUtils.cpp b/Gems/ScriptCanvas/Code/Editor/Nodes/NodeDisplayUtils.cpp index 8e273fd2fc..60eaba24f8 100644 --- a/Gems/ScriptCanvas/Code/Editor/Nodes/NodeDisplayUtils.cpp +++ b/Gems/ScriptCanvas/Code/Editor/Nodes/NodeDisplayUtils.cpp @@ -376,60 +376,60 @@ namespace ScriptCanvasEditor::Nodes int paramIndex = 0; int outputIndex = 0; + int slotIndex = 0; auto busId = methodNode->GetBusSlotId(); for (const auto& slot : methodNode->GetSlots()) { GraphCanvas::TranslationKey slotKey = key; - int& index = (slot.IsData() && slot.IsInput()) ? paramIndex : outputIndex; + int& inputOutputIndex = slot.IsInput() ? paramIndex : outputIndex; + const bool isBusIdSlot = + methodNode->HasBusID() && busId == slot.GetId() && slot.GetDescriptor() == ScriptCanvas::SlotDescriptors::DataIn(); if (slot.IsVisible()) { - AZ::EntityId graphCanvasSlotId = DisplayScriptCanvasSlot(graphCanvasNodeId, slot, index); + AZ::EntityId graphCanvasSlotId = DisplayScriptCanvasSlot(graphCanvasNodeId, slot, slotIndex); details.m_name = slot.GetName(); details.m_tooltip = slot.GetToolTip(); - if (methodNode->HasBusID() && busId == slot.GetId() && slot.GetDescriptor() == ScriptCanvas::SlotDescriptors::DataIn()) + if (isBusIdSlot) { key = ::Translation::GlobalKeys::EBusSenderIDKey; - GraphCanvas::TranslationRequestBus::BroadcastResult(details, &GraphCanvas::TranslationRequests::GetDetails, key + ".details", details); + GraphCanvas::TranslationRequestBus::BroadcastResult( + details, &GraphCanvas::TranslationRequests::GetDetails, key + ".details", details); } - else + else if (slot.IsData()) { - - - if (slot.IsData()) + key.clear(); + key << context << className << "methods" << updatedMethodName; + if (slot.IsInput()) { - key.clear(); - key << context << className << "methods" << updatedMethodName; - if (slot.IsData() && slot.IsInput()) - { - key << "params"; - } - else - { - key << "results"; - } - key << index; - - GraphCanvas::TranslationRequestBus::BroadcastResult(details, &GraphCanvas::TranslationRequests::GetDetails, key + ".details", details); + key << "params"; } - - if (slot.IsData()) - { - index++; + else + { + key << "results"; } + key << inputOutputIndex; + + GraphCanvas::TranslationRequestBus::BroadcastResult( + details, &GraphCanvas::TranslationRequests::GetDetails, key + ".details", details); } - GraphCanvas::SlotRequestBus::Event(graphCanvasSlotId, &GraphCanvas::SlotRequests::SetDetails, details.m_name, details.m_tooltip); + GraphCanvas::SlotRequestBus::Event( + graphCanvasSlotId, &GraphCanvas::SlotRequests::SetDetails, details.m_name, details.m_tooltip); UpdateSlotDatumLabel(graphCanvasNodeId, slot.GetId(), details.m_name); - } - ++index; + ++slotIndex; + + if (!isBusIdSlot && slot.IsData()) + { + ++inputOutputIndex; + } } // Set the name @@ -485,9 +485,6 @@ namespace ScriptCanvasEditor::Nodes AZStd::vector< ScriptCanvas::SlotId > scriptCanvasSlots = busNode->GetNonEventSlotIds(); - int paramIndex = 0; - int outputIndex = 0; - for (const auto& slotId : scriptCanvasSlots) { ScriptCanvas::Slot* slot = busNode->GetSlot(slotId); @@ -501,8 +498,6 @@ namespace ScriptCanvasEditor::Nodes if (slot->IsVisible()) { - int& index = (slot->IsData() && slot->IsInput()) ? paramIndex : outputIndex; - AZ::EntityId gcSlotId = DisplayScriptCanvasSlot(graphCanvasNodeId, (*slot), group); if (busNode->IsIDRequired() && slot->GetDescriptor() == ScriptCanvas::SlotDescriptors::DataIn()) @@ -516,8 +511,6 @@ namespace ScriptCanvasEditor::Nodes GraphCanvas::SlotRequestBus::Event(gcSlotId, &GraphCanvas::SlotRequests::SetDetails, details.m_name, details.m_tooltip); } - - ++index; } } @@ -615,17 +608,12 @@ namespace ScriptCanvasEditor::Nodes *graphCanvasUserData = azEventNode->GetEntityId(); } - int paramIndex = 0; - int outputIndex = 0; - for (const ScriptCanvas::Slot& slot: azEventNode->GetSlots()) { GraphCanvas::SlotGroup group = GraphCanvas::SlotGroups::Invalid; if (slot.IsVisible()) { - int& index = (slot.IsData() && slot.IsInput()) ? paramIndex : outputIndex; - AZ::EntityId gcSlotId = DisplayScriptCanvasSlot(graphCanvasNodeId, slot, group); GraphCanvas::TranslationKey key; @@ -636,8 +624,6 @@ namespace ScriptCanvasEditor::Nodes GraphCanvas::SlotRequestBus::Event(gcSlotId, &GraphCanvas::SlotRequests::SetName, details.m_name); GraphCanvas::SlotRequestBus::Event(gcSlotId, &GraphCanvas::SlotRequests::SetTooltip, details.m_tooltip);; - - ++index; } } @@ -703,9 +689,6 @@ namespace ScriptCanvasEditor::Nodes AZStd::vector< ScriptCanvas::SlotId > scriptCanvasSlots = busNode->GetNonEventSlotIds(); - int paramIndex = 0; - int outputIndex = 0; - for (const auto& slotId : scriptCanvasSlots) { ScriptCanvas::Slot* slot = busNode->GetSlot(slotId); @@ -719,8 +702,6 @@ namespace ScriptCanvasEditor::Nodes if (slot->IsVisible()) { - int& index = (slot->IsData() && slot->IsInput()) ? paramIndex : outputIndex; - AZ::EntityId gcSlotId = DisplayScriptCanvasSlot(graphCanvasNodeId, (*slot), group); if (busNode->IsIDRequired() && slot->GetDescriptor() == ScriptCanvas::SlotDescriptors::DataIn()) @@ -731,8 +712,6 @@ namespace ScriptCanvasEditor::Nodes GraphCanvas::TranslationRequestBus::BroadcastResult(details, &GraphCanvas::TranslationRequests::GetDetails, key, details); GraphCanvas::SlotRequestBus::Event(gcSlotId, &GraphCanvas::SlotRequests::SetDetails, details.m_name, details.m_tooltip); } - - ++index; } } @@ -932,7 +911,7 @@ namespace ScriptCanvasEditor::Nodes if (asset) { - GraphCanvas::NodeTitleRequestBus::Event(graphCanvasNodeId, &GraphCanvas::NodeTitleRequests::SetTitle, asset->GetData().m_name); + GraphCanvas::NodeTitleRequestBus::Event(graphCanvasNodeId, &GraphCanvas::NodeTitleRequests::SetTitle, asset->m_interfaceData.m_name); } GraphCanvas::NodeTitleRequestBus::Event(graphCanvasNodeId, &GraphCanvas::NodeTitleRequests::SetPaletteOverride, "MethodNodeTitlePalette"); diff --git a/Gems/ScriptCanvas/Code/Editor/SystemComponent.cpp b/Gems/ScriptCanvas/Code/Editor/SystemComponent.cpp index 9bbdddfedb..1b5e97ba36 100644 --- a/Gems/ScriptCanvas/Code/Editor/SystemComponent.cpp +++ b/Gems/ScriptCanvas/Code/Editor/SystemComponent.cpp @@ -265,11 +265,13 @@ namespace ScriptCanvasEditor action = entityMenu->addAction(QString("%1").arg(QString(displayName.c_str()))); - QObject::connect(action, &QAction::triggered, [assetId] + QObject::connect(action, &QAction::triggered, [assetInfo] { AzToolsFramework::OpenViewPane(LyViewPane::ScriptCanvas); + SourceHandle sourceHandle(nullptr, assetInfo.m_assetId.m_guid, ""); + CompleteDescriptionInPlace(sourceHandle); GeneralRequestBus::Broadcast(&GeneralRequests::OpenScriptCanvasAsset - , SourceHandle(nullptr, assetId.m_guid, "") + , sourceHandle , Tracker::ScriptCanvasFileState::UNMODIFIED, -1); }); } diff --git a/Gems/ScriptCanvas/Code/Editor/View/Widgets/GraphTabBar.cpp b/Gems/ScriptCanvas/Code/Editor/View/Widgets/GraphTabBar.cpp index c5f808d5f4..0213765737 100644 --- a/Gems/ScriptCanvas/Code/Editor/View/Widgets/GraphTabBar.cpp +++ b/Gems/ScriptCanvas/Code/Editor/View/Widgets/GraphTabBar.cpp @@ -430,7 +430,7 @@ namespace ScriptCanvasEditor void GraphTabBar::UpdateFileState(const ScriptCanvasEditor::SourceHandle& assetId, Tracker::ScriptCanvasFileState fileState) { auto tabData = GetTabData(assetId); - if (tabData && tabData->m_fileState != fileState) + if (tabData && tabData->m_fileState != Tracker::ScriptCanvasFileState::NEW && tabData->m_fileState != fileState) { int index = FindTab(assetId); tabData->m_fileState = fileState; diff --git a/Gems/ScriptCanvas/Code/Editor/View/Widgets/NodePalette/NodePaletteModel.cpp b/Gems/ScriptCanvas/Code/Editor/View/Widgets/NodePalette/NodePaletteModel.cpp index 0efdf071f5..113c43682f 100644 --- a/Gems/ScriptCanvas/Code/Editor/View/Widgets/NodePalette/NodePaletteModel.cpp +++ b/Gems/ScriptCanvas/Code/Editor/View/Widgets/NodePalette/NodePaletteModel.cpp @@ -1159,7 +1159,7 @@ namespace ScriptCanvasEditor , AZStd::string_view eventName , const ScriptCanvas::EBusBusId& busId , const ScriptCanvas::EBusEventId& eventId - , const AZ::BehaviorEBusEventSender& + , const AZ::BehaviorEBusEventSender& sender , ScriptCanvas::PropertyStatus propertyStatus , bool isOverload) { @@ -1193,6 +1193,17 @@ namespace ScriptCanvasEditor senderInformation->m_displayName = details.m_name.empty() ? eventName : details.m_name.c_str(); senderInformation->m_toolTip = details.m_tooltip.empty() ? "" : details.m_tooltip; + auto safeRegister = [](AZ::BehaviorMethod* method) + { + if (method && AZ::MethodReturnsAzEventByReferenceOrPointer(*method)) + { + const AZ::BehaviorParameter* resultParameter = method->GetResult(); + ScriptCanvas::ReflectEventTypeOnDemand(resultParameter->m_typeId, resultParameter->m_name, resultParameter->m_azRtti); + } + }; + + safeRegister(sender.m_event); + safeRegister(sender.m_broadcast); m_registeredNodes.emplace(AZStd::make_pair(nodeIdentifier, senderInformation)); } } diff --git a/Gems/ScriptCanvas/Code/Editor/View/Widgets/ScriptCanvasNodePaletteDockWidget.cpp b/Gems/ScriptCanvas/Code/Editor/View/Widgets/ScriptCanvasNodePaletteDockWidget.cpp index 25f38afbae..60d903d748 100644 --- a/Gems/ScriptCanvas/Code/Editor/View/Widgets/ScriptCanvasNodePaletteDockWidget.cpp +++ b/Gems/ScriptCanvas/Code/Editor/View/Widgets/ScriptCanvasNodePaletteDockWidget.cpp @@ -456,7 +456,7 @@ namespace ScriptCanvasEditor return; } - if (!data->m_runtimeData.m_interface.HasAnyFunctionality()) + if (!data->m_interfaceData.m_interface.HasAnyFunctionality()) { // check for deleting the old entry return; @@ -517,7 +517,7 @@ namespace ScriptCanvasEditor return; } - const ScriptCanvas::Grammar::SubgraphInterface& graphInterface = data->m_runtimeData.m_interface; + const ScriptCanvas::Grammar::SubgraphInterface& graphInterface = data->m_interfaceData.m_interface; if (!graphInterface.HasAnyFunctionality()) { return; @@ -566,7 +566,7 @@ namespace ScriptCanvasEditor return; } - const ScriptCanvas::Grammar::SubgraphInterface& graphInterface = data->m_runtimeData.m_interface; + const ScriptCanvas::Grammar::SubgraphInterface& graphInterface = data->m_interfaceData.m_interface; if (!graphInterface.HasAnyFunctionality()) { return; diff --git a/Gems/ScriptCanvas/Code/Editor/View/Windows/MainWindow.cpp b/Gems/ScriptCanvas/Code/Editor/View/Windows/MainWindow.cpp index abffec231e..1176df61dc 100644 --- a/Gems/ScriptCanvas/Code/Editor/View/Windows/MainWindow.cpp +++ b/Gems/ScriptCanvas/Code/Editor/View/Windows/MainWindow.cpp @@ -151,6 +151,7 @@ #include #include +#include namespace ScriptCanvasEditor { @@ -1135,23 +1136,20 @@ namespace ScriptCanvasEditor return AZ::Success(outTabIndex); } - auto loadedGraph = LoadFromFile(fileAssetId.Path().c_str()); - if (!loadedGraph.IsSuccess()) + auto loadedGraphOutcome = LoadFromFile(fileAssetId.Path().c_str()); + if (!loadedGraphOutcome.IsSuccess()) { - return AZ::Failure(AZStd::string("Failed to load graph at %s", fileAssetId.Path().c_str())); + return AZ::Failure(AZStd::string::format("Failed to load graph at %s", fileAssetId.Path().c_str())); } - outTabIndex = CreateAssetTab(loadedGraph.GetValue(), fileState); - - if (!m_isRestoringWorkspace) - { - SetActiveAsset(loadedGraph.GetValue()); - } + auto loadedGraph = loadedGraphOutcome.TakeValue(); + CompleteDescriptionInPlace(loadedGraph); + outTabIndex = CreateAssetTab(loadedGraph, fileState); if (outTabIndex >= 0) { - AddRecentFile(loadedGraph.GetValue().Path().c_str()); - OpenScriptCanvasAssetImplementation(loadedGraph.GetValue(), fileState); + AddRecentFile(loadedGraph.Path().c_str()); + OpenScriptCanvasAssetImplementation(loadedGraph, fileState); return AZ::Success(outTabIndex); } else @@ -1168,6 +1166,11 @@ namespace ScriptCanvasEditor return AZ::Failure(AZStd::string("Unable to open asset with invalid asset id")); } + if (!m_isRestoringWorkspace) + { + SetActiveAsset(scriptCanvasAsset); + } + if (!scriptCanvasAsset.IsDescriptionValid()) { if (!m_isRestoringWorkspace) @@ -1344,9 +1347,11 @@ namespace ScriptCanvasEditor AZ::Outcome outcome = LoadFromFile(fullPath); if (!outcome.IsSuccess()) { - QMessageBox::warning(this, "Invalid Source File", QString("'%1' failed to load properly.").arg(fullPath), QMessageBox::Ok); + QMessageBox::warning(this, "Invalid Source File" + , QString("'%1' failed to load properly.\nFailure: %2").arg(fullPath).arg(outcome.GetError().c_str()), QMessageBox::Ok); m_errorFilePath = fullPath; - AZ_Warning("ScriptCanvas", false, "Unable to open file as a ScriptCanvas graph: %s", fullPath); + AZ_Warning("ScriptCanvas", false, "Unable to open file as a ScriptCanvas graph: %s. Failure: %s" + , fullPath, outcome.GetError().c_str()); return; } @@ -1595,7 +1600,14 @@ namespace ScriptCanvasEditor bool MainWindow::OnFileSave() { - return SaveAssetImpl(m_activeGraph, Save::InPlace); + if (auto metaData = m_tabBar->GetTabData(m_activeGraph); metaData && metaData->m_fileState == Tracker::ScriptCanvasFileState::NEW) + { + return SaveAssetImpl(m_activeGraph, Save::As); + } + else + { + return SaveAssetImpl(m_activeGraph, Save::InPlace); + } } bool MainWindow::OnFileSaveAs() diff --git a/Gems/ScriptCanvas/Code/Editor/View/Windows/MainWindow.h b/Gems/ScriptCanvas/Code/Editor/View/Windows/MainWindow.h index 2d2c32be18..75c798a0d3 100644 --- a/Gems/ScriptCanvas/Code/Editor/View/Windows/MainWindow.h +++ b/Gems/ScriptCanvas/Code/Editor/View/Windows/MainWindow.h @@ -50,7 +50,6 @@ #include #include - #include #include diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAsset.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAsset.cpp index d55fcf7838..faa1d06b63 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAsset.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAsset.cpp @@ -11,7 +11,7 @@ #include #include -namespace ScriptCanvasRuntimeAssetCpp +namespace DoNotVersionRuntimeAssetsBumpTheBuilderVersionInstead { enum class RuntimeDataVersion { @@ -72,7 +72,7 @@ namespace ScriptCanvas if (auto serializeContext = azrtti_cast(reflectContext)) { serializeContext->Class() - ->Version(static_cast(ScriptCanvasRuntimeAssetCpp::RuntimeDataVersion::Current)) + ->Version(static_cast(DoNotVersionRuntimeAssetsBumpTheBuilderVersionInstead::RuntimeDataVersion::Current)) ->Field("input", &RuntimeData::m_input) ->Field("debugMap", &RuntimeData::m_debugMap) ->Field("script", &RuntimeData::m_script) @@ -146,7 +146,7 @@ namespace ScriptCanvas if (auto serializeContext = azrtti_cast(context)) { serializeContext->Class() - ->Version(static_cast(ScriptCanvasRuntimeAssetCpp::RuntimeDataOverridesVersion::Current)) + ->Version(static_cast(DoNotVersionRuntimeAssetsBumpTheBuilderVersionInstead::RuntimeDataOverridesVersion::Current)) ->Field("runtimeAsset", &RuntimeDataOverrides::m_runtimeAsset) ->Field("variables", &RuntimeDataOverrides::m_variables) ->Field("variableIndices", &RuntimeDataOverrides::m_variableIndices) @@ -195,7 +195,7 @@ namespace ScriptCanvas if (auto serializeContext = azrtti_cast(reflectContext)) { serializeContext->Class() - ->Version(static_cast(ScriptCanvasRuntimeAssetCpp::FunctionRuntimeDataVersion::Current)) + ->Version(static_cast(DoNotVersionRuntimeAssetsBumpTheBuilderVersionInstead::FunctionRuntimeDataVersion::Current)) ->Field("name", &SubgraphInterfaceData::m_name) ->Field("interface", &SubgraphInterfaceData::m_interface) ; diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAsset.h b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAsset.h index 8c5da5ac07..ad6f7c07b4 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAsset.h +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAsset.h @@ -106,65 +106,20 @@ namespace ScriptCanvas void EnforcePreloadBehavior(); }; - class RuntimeAssetBase + class RuntimeAsset : public AZ::Data::AssetData { public: - - AZ_RTTI(RuntimeAssetBase, "{19BAD220-E505-4443-AA95-743106748F37}", AZ::Data::AssetData); - AZ_CLASS_ALLOCATOR(RuntimeAssetBase, AZ::SystemAllocator, 0); - RuntimeAssetBase(const AZ::Data::AssetId& assetId = AZ::Data::AssetId(), AZ::Data::AssetData::AssetStatus status = AZ::Data::AssetData::AssetStatus::NotLoaded) - : AZ::Data::AssetData(assetId, status) - { - - } - }; - template - class RuntimeAssetTyped - : public RuntimeAssetBase - { - public: - AZ_RTTI(RuntimeAssetBase, "{C925213E-A1FA-4487-831F-9551A984700E}", RuntimeAssetBase); - AZ_CLASS_ALLOCATOR(RuntimeAssetBase, AZ::SystemAllocator, 0); - - RuntimeAssetTyped(const AZ::Data::AssetId& assetId = AZ::Data::AssetId(), AZ::Data::AssetData::AssetStatus status = AZ::Data::AssetData::AssetStatus::NotLoaded) - : RuntimeAssetBase(assetId, status) - { - - } + AZ_RTTI(RuntimeAsset, "{3E2AC8CD-713F-453E-967F-29517F331784}", AZ::Data::AssetData); static const char* GetFileExtension() { return "scriptcanvas_compiled"; } static const char* GetFileFilter() { return "*.scriptcanvas_compiled"; } - const DataType& GetData() const { return m_runtimeData; } - DataType& GetData() { return m_runtimeData; } - void SetData(const DataType& runtimeData) - { - m_runtimeData = runtimeData; - // When setting data instead of serializing, immediately mark the asset as ready. - m_status = AZ::Data::AssetData::AssetStatus::Ready; - } - - DataType m_runtimeData; - - protected: - friend class RuntimeAssetHandler; - RuntimeAssetTyped(const RuntimeAssetTyped&) = delete; - - }; - - class RuntimeAsset : public RuntimeAssetTyped - { - public: - - AZ_RTTI(RuntimeAsset, "{3E2AC8CD-713F-453E-967F-29517F331784}", RuntimeAssetTyped); + RuntimeData m_runtimeData; RuntimeAsset(const AZ::Data::AssetId& assetId = AZ::Data::AssetId(), AZ::Data::AssetData::AssetStatus status = AZ::Data::AssetData::AssetStatus::NotLoaded) - : RuntimeAssetTyped(assetId, status) - { - - } - + : AZ::Data::AssetData(assetId, status) + {} }; class SubgraphInterfaceAsset; @@ -212,24 +167,19 @@ namespace ScriptCanvas }; class SubgraphInterfaceAsset - : public RuntimeAssetTyped + : public AZ::Data::AssetData { public: - AZ_RTTI(SubgraphInterfaceAsset, "{E22967AC-7673-4778-9125-AF49D82CAF9F}", RuntimeAssetTyped); + AZ_RTTI(SubgraphInterfaceAsset, "{E22967AC-7673-4778-9125-AF49D82CAF9F}", AZ::Data::AssetData); AZ_CLASS_ALLOCATOR(SubgraphInterfaceAsset, AZ::SystemAllocator, 0); - SubgraphInterfaceAsset(const AZ::Data::AssetId& assetId = AZ::Data::AssetId(), AZ::Data::AssetData::AssetStatus status = AZ::Data::AssetData::AssetStatus::NotLoaded) - : RuntimeAssetTyped(assetId, status) - {} - - void SetData(const SubgraphInterfaceData& runtimeData) - { - m_runtimeData = runtimeData; - } - static const char* GetFileExtension() { return "scriptcanvas_fn_compiled"; } static const char* GetFileFilter() { return "*.scriptcanvas_fn_compiled"; } - friend class SubgraphInterfaceAssetHandler; + SubgraphInterfaceData m_interfaceData; + + SubgraphInterfaceAsset(const AZ::Data::AssetId& assetId = AZ::Data::AssetId(), AZ::Data::AssetData::AssetStatus status = AZ::Data::AssetData::AssetStatus::NotLoaded) + : AZ::Data::AssetData(assetId, status) + {} }; } diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAssetHandler.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAssetHandler.cpp index 05b6f4397b..0b94fb370a 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAssetHandler.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/RuntimeAssetHandler.cpp @@ -81,7 +81,6 @@ namespace ScriptCanvas { (void)type; AZ_Assert(type == AZ::AzTypeInfo::Uuid(), "This handler deals only with the Script Canvas Runtime Asset type!"); - return aznew RuntimeAsset(id); } @@ -93,7 +92,7 @@ namespace ScriptCanvas { RuntimeAsset* runtimeAsset = asset.GetAs(); AZ_Assert(runtimeAsset, "RuntimeAssetHandler::InitAsset This should be a Script Canvas runtime asset, as this is the only type this handler processes!"); - Execution::Context::InitializeActivationData(runtimeAsset->GetData()); + Execution::Context::InitializeActivationData(runtimeAsset->m_runtimeData); } } @@ -116,7 +115,10 @@ namespace ScriptCanvas AZ_Assert(runtimeAsset, "This should be a Script Canvas runtime asset, as this is the only type we process!"); if (runtimeAsset && m_serializeContext) { - AZ::ObjectStream* binaryObjStream = AZ::ObjectStream::Create(stream, *m_serializeContext, AZ::ObjectStream::ST_XML); + AZ::ObjectStream* binaryObjStream = AZ::ObjectStream::Create(stream, *m_serializeContext + , g_saveRuntimeAssetsAsPlainTextForDebug + ? AZ::ObjectStream::ST_XML + : AZ::ObjectStream::ST_BINARY); bool graphSaved = binaryObjStream->WriteClass(&runtimeAsset->m_runtimeData); binaryObjStream->Finalize(); return graphSaved; @@ -128,7 +130,7 @@ namespace ScriptCanvas void RuntimeAssetHandler::DestroyAsset(AZ::Data::AssetPtr ptr) { RuntimeAsset* runtimeAsset = azrtti_cast(ptr); - Execution::Context::UnloadData(runtimeAsset->GetData()); + Execution::Context::UnloadData(runtimeAsset->m_runtimeData); delete ptr; } diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/SubgraphInterfaceAssetHandler.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/SubgraphInterfaceAssetHandler.cpp index 451e0dfc47..d0371bb88f 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/SubgraphInterfaceAssetHandler.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Asset/SubgraphInterfaceAssetHandler.cpp @@ -93,7 +93,7 @@ namespace ScriptCanvas if (runtimeFunctionAsset && m_serializeContext) { stream->Seek(0U, AZ::IO::GenericStream::ST_SEEK_BEGIN); - bool loadSuccess = AZ::Utils::LoadObjectFromStreamInPlace(*stream, runtimeFunctionAsset->m_runtimeData, m_serializeContext, AZ::ObjectStream::FilterDescriptor(assetLoadFilterCB)); + bool loadSuccess = AZ::Utils::LoadObjectFromStreamInPlace(*stream, runtimeFunctionAsset->m_interfaceData, m_serializeContext, AZ::ObjectStream::FilterDescriptor(assetLoadFilterCB)); return loadSuccess ? AZ::Data::AssetHandler::LoadResult::LoadComplete : AZ::Data::AssetHandler::LoadResult::Error; } return AZ::Data::AssetHandler::LoadResult::Error; @@ -105,8 +105,11 @@ namespace ScriptCanvas AZ_Assert(runtimeFunctionAsset, "This should be a Script Canvas runtime asset, as this is the only type we process!"); if (runtimeFunctionAsset && m_serializeContext) { - AZ::ObjectStream* binaryObjStream = AZ::ObjectStream::Create(stream, *m_serializeContext, AZ::ObjectStream::ST_XML); - bool graphSaved = binaryObjStream->WriteClass(&runtimeFunctionAsset->m_runtimeData); + AZ::ObjectStream* binaryObjStream = AZ::ObjectStream::Create(stream, *m_serializeContext + , ScriptCanvas::g_saveEditorAssetsAsPlainTextForDebug + ? AZ::ObjectStream::ST_XML + : AZ::ObjectStream::ST_BINARY); + bool graphSaved = binaryObjStream->WriteClass(&runtimeFunctionAsset->m_interfaceData); binaryObjStream->Finalize(); return graphSaved; } diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Core/Core.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Core/Core.cpp index 4a1d5d94c1..1e00e70075 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Core/Core.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Core/Core.cpp @@ -20,6 +20,12 @@ namespace ScriptCanvas { + AZ_CVAR(bool, g_saveRuntimeAssetsAsPlainTextForDebug, false, {}, AZ::ConsoleFunctorFlags::Null + , "Save runtime assets as plain text rather than binary for debug purposes."); + + AZ_CVAR(bool, g_saveEditorAssetsAsPlainTextForDebug, false, {}, AZ::ConsoleFunctorFlags::Null + , "Save editor assets as plain text rather than binary for debug purposes."); + ScopedAuxiliaryEntityHandler::ScopedAuxiliaryEntityHandler(AZ::Entity* buildEntity) : m_buildEntity(buildEntity) , m_wasAdded(false) diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Core/Core.h b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Core/Core.h index 1a644d312e..c29a648eca 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Core/Core.h +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Core/Core.h @@ -24,6 +24,7 @@ #include #include #include +#include #define OBJECT_STREAM_EDITOR_ASSET_LOADING_SUPPORT_ENABLED @@ -42,6 +43,9 @@ namespace AZ namespace ScriptCanvas { + AZ_CVAR_EXTERNED(bool, g_saveRuntimeAssetsAsPlainTextForDebug); + AZ_CVAR_EXTERNED(bool, g_saveEditorAssetsAsPlainTextForDebug); + // A place holder identifier for the AZ::Entity that owns the graph. // The actual value in each location initialized to GraphOwnerId is populated with the owning entity at editor-time, Asset Processor-time, or runtime, as soon as the owning entity is known. using GraphOwnerIdType = AZ::EntityId; diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/ExecutionContext.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/ExecutionContext.cpp index f7ae4a931e..8c3c3d6da2 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/ExecutionContext.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/ExecutionContext.cpp @@ -41,7 +41,7 @@ namespace ScriptCanvas { ActivationData::ActivationData(const RuntimeDataOverrides& variableOverrides, ActivationInputArray& storage) : variableOverrides(variableOverrides) - , runtimeData(variableOverrides.m_runtimeAsset->GetData()) + , runtimeData(variableOverrides.m_runtimeAsset->m_runtimeData) , storage(storage) {} diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/ExecutionState.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/ExecutionState.cpp index 81f0528b45..882003e7a4 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/ExecutionState.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/ExecutionState.cpp @@ -22,7 +22,7 @@ namespace ScriptCanvas ExecutionStateConfig::ExecutionStateConfig(AZ::Data::Asset runtimeAsset, RuntimeComponent& component) : asset(runtimeAsset) , component(component) - , runtimeData(runtimeAsset.Get()->GetData()) + , runtimeData(runtimeAsset.Get()->m_runtimeData) {} ExecutionState::ExecutionState(const ExecutionStateConfig& config) diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/Interpreted/ExecutionInterpretedAPI.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/Interpreted/ExecutionInterpretedAPI.cpp index 561708dea1..eb856963f7 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/Interpreted/ExecutionInterpretedAPI.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/Interpreted/ExecutionInterpretedAPI.cpp @@ -509,9 +509,9 @@ namespace ScriptCanvas for (auto& dependency : runtimeData.m_requiredAssets) { - if (!dependency.Get()->GetData().m_areStaticsInitialized) + if (!dependency.Get()->m_runtimeData.m_areStaticsInitialized) { - InitializeInterpretedStatics(dependency.Get()->GetData()); + InitializeInterpretedStatics(dependency.Get()->m_runtimeData); } } diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/Interpreted/ExecutionStateInterpreted.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/Interpreted/ExecutionStateInterpreted.cpp index 3b963317ec..f0288fb279 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/Interpreted/ExecutionStateInterpreted.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/Interpreted/ExecutionStateInterpreted.cpp @@ -49,9 +49,9 @@ namespace ScriptCanvas , config.asset.GetId().ToString().data()); #endif - if (!runtimeAsset->GetData().m_areStaticsInitialized) + if (!runtimeAsset->m_runtimeData.m_areStaticsInitialized) { - Execution::InitializeInterpretedStatics(runtimeAsset->GetData()); + Execution::InitializeInterpretedStatics(runtimeAsset->m_runtimeData); } } @@ -70,8 +70,8 @@ namespace ScriptCanvas const Grammar::DebugExecution* ExecutionStateInterpreted::GetDebugSymbolIn(size_t index, const AZ::Data::AssetId& id) const { auto asset = ExecutionStateInterpretedCpp::GetSubgraphAssetForDebug(id); - return asset && asset.Get() && index < asset.Get()->GetData().m_debugMap.m_ins.size() - ? &(asset.Get()->GetData().m_debugMap.m_ins[index]) + return asset && asset.Get() && index < asset.Get()->m_runtimeData.m_debugMap.m_ins.size() + ? &(asset.Get()->m_runtimeData.m_debugMap.m_ins[index]) : nullptr; } @@ -85,8 +85,8 @@ namespace ScriptCanvas const Grammar::DebugExecution* ExecutionStateInterpreted::GetDebugSymbolOut(size_t index, const AZ::Data::AssetId& id) const { auto asset = ExecutionStateInterpretedCpp::GetSubgraphAssetForDebug(id); - return asset && asset.Get() && index < asset.Get()->GetData().m_debugMap.m_outs.size() - ? &(asset.Get()->GetData().m_debugMap.m_outs[index]) + return asset && asset.Get() && index < asset.Get()->m_runtimeData.m_debugMap.m_outs.size() + ? &(asset.Get()->m_runtimeData.m_debugMap.m_outs[index]) : nullptr; } @@ -100,8 +100,8 @@ namespace ScriptCanvas const Grammar::DebugExecution* ExecutionStateInterpreted::GetDebugSymbolReturn(size_t index, const AZ::Data::AssetId& id) const { auto asset = ExecutionStateInterpretedCpp::GetSubgraphAssetForDebug(id); - return asset && asset.Get() && index < asset.Get()->GetData().m_debugMap.m_returns.size() - ? &(asset.Get()->GetData().m_debugMap.m_returns[index]) + return asset && asset.Get() && index < asset.Get()->m_runtimeData.m_debugMap.m_returns.size() + ? &(asset.Get()->m_runtimeData.m_debugMap.m_returns[index]) : nullptr; } @@ -115,8 +115,8 @@ namespace ScriptCanvas const Grammar::DebugDataSource* ExecutionStateInterpreted::GetDebugSymbolVariableChange(size_t index, const AZ::Data::AssetId& id) const { auto asset = ExecutionStateInterpretedCpp::GetSubgraphAssetForDebug(id); - return asset && asset.Get() && index < asset.Get()->GetData().m_debugMap.m_variables.size() - ? &(asset.Get()->GetData().m_debugMap.m_variables[index]) + return asset && asset.Get() && index < asset.Get()->m_runtimeData.m_debugMap.m_variables.size() + ? &(asset.Get()->m_runtimeData.m_debugMap.m_variables[index]) : nullptr; } diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/RuntimeComponent.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/RuntimeComponent.cpp index 930b84abe4..23eba22524 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/RuntimeComponent.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Execution/RuntimeComponent.cpp @@ -71,7 +71,7 @@ namespace ScriptCanvas const RuntimeData& RuntimeComponent::GetRuntimeAssetData() const { - return m_runtimeOverrides.m_runtimeAsset->GetData(); + return m_runtimeOverrides.m_runtimeAsset->m_runtimeData; } ExecutionMode RuntimeComponent::GetExecutionMode() const diff --git a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Core/FunctionCallNode.cpp b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Core/FunctionCallNode.cpp index 225949d833..551b9b4002 100644 --- a/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Core/FunctionCallNode.cpp +++ b/Gems/ScriptCanvas/Code/Include/ScriptCanvas/Libraries/Core/FunctionCallNode.cpp @@ -261,11 +261,11 @@ namespace ScriptCanvas , const ScriptCanvas::Grammar::FunctionSourceId& sourceId , const SlotExecution::Map& previousMap) { - const Grammar::SubgraphInterface& subgraphInterface = runtimeAsset.Get()->m_runtimeData.m_interface; + const Grammar::SubgraphInterface& subgraphInterface = runtimeAsset.Get()->m_interfaceData.m_interface; if (subgraphInterface.IsUserNodeable() && Grammar::IsFunctionSourceIdNodeable(sourceId) && subgraphInterface.HasIn(sourceId)) { - m_prettyName = runtimeAsset.Get()->m_runtimeData.m_name; + m_prettyName = runtimeAsset.Get()->m_interfaceData.m_name; BuildUserNodeableNode(subgraphInterface, previousMap); } else if ((!Grammar::IsFunctionSourceIdNodeable(sourceId)) && subgraphInterface.HasIn(sourceId)) @@ -477,7 +477,7 @@ namespace ScriptCanvas return true; } - const Grammar::SubgraphInterface* latestAssetInterface = asset ? &asset.Get()->GetData().m_interface : nullptr; + const Grammar::SubgraphInterface* latestAssetInterface = asset ? &asset.Get()->m_interfaceData.m_interface : nullptr; if (!latestAssetInterface) { AZ_Warning("ScriptCanvas", false, "FunctionCallNode %s failed to load latest interface from the source asset.", m_prettyName.data()); @@ -517,7 +517,7 @@ namespace ScriptCanvas DataSlotMap dataSlotMap; if (m_slotExecutionMap.IsEmpty()) { - const Grammar::SubgraphInterface& subgraphInterface = assetData.Get()->m_runtimeData.m_interface; + const Grammar::SubgraphInterface& subgraphInterface = assetData.Get()->m_interfaceData.m_interface; RemoveInsFromInterface(subgraphInterface.GetIns(), executionSlotMap, dataSlotMap, k_DoNotRemoveConnections, k_DoNotWarnOnMissingDataSlots); RemoveOutsFromInterface(subgraphInterface.GetLatentOuts(), executionSlotMap, dataSlotMap, k_DoNotRemoveConnections, k_DoNotWarnOnMissingDataSlots); } @@ -806,7 +806,7 @@ namespace ScriptCanvas return; } - m_prettyName = assetData.Get()->m_runtimeData.m_name; + m_prettyName = assetData.Get()->m_interfaceData.m_name; } } } diff --git a/Gems/ScriptCanvas/Code/Tests/ScriptCanvasBuilderTests.cpp b/Gems/ScriptCanvas/Code/Tests/ScriptCanvasBuilderTests.cpp index 33982bbcd7..cac26eff95 100644 --- a/Gems/ScriptCanvas/Code/Tests/ScriptCanvasBuilderTests.cpp +++ b/Gems/ScriptCanvas/Code/Tests/ScriptCanvasBuilderTests.cpp @@ -153,11 +153,10 @@ TEST_F(ScriptCanvasBuilderTests, ScriptCanvasWithAssetReference_GatherProductDep graphEntity->AddComponent(assetComponent); ScriptCanvas::RuntimeData runtimeData; - //runtimeData.m_graphData.m_nodes.emplace(graphEntity); - + AZ::Data::Asset runtimeAsset; runtimeAsset.Create(AZ::Uuid::CreateRandom()); - runtimeAsset.Get()->SetData(runtimeData); + runtimeAsset.Get()->m_runtimeData = runtimeData; AZStd::vector productDependencies; AssetBuilderSDK::ProductPathDependencySet productPathDependencySet; diff --git a/Gems/ScriptCanvas/Code/scriptcanvasgem_common_files.cmake b/Gems/ScriptCanvas/Code/scriptcanvasgem_common_files.cmake index 34b2c4d326..c0dcc04838 100644 --- a/Gems/ScriptCanvas/Code/scriptcanvasgem_common_files.cmake +++ b/Gems/ScriptCanvas/Code/scriptcanvasgem_common_files.cmake @@ -206,9 +206,4 @@ set(FILES Include/ScriptCanvas/Utils/VersioningUtils.cpp Include/ScriptCanvas/Utils/VersioningUtils.cpp Include/ScriptCanvas/Utils/BehaviorContextUtils.cpp -) - -set(SKIP_UNITY_BUILD_INCLUSION_FILES - Include/ScriptCanvas/Libraries/Core/FunctionCallNode.cpp - Include/ScriptCanvas/Libraries/Core/FunctionCallNodeIsOutOfDate.cpp -) +) \ No newline at end of file diff --git a/Gems/ScriptCanvas/gem.json b/Gems/ScriptCanvas/gem.json index fc8a504917..ace6bca50c 100644 --- a/Gems/ScriptCanvas/gem.json +++ b/Gems/ScriptCanvas/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Script Canvas Gem provides Open 3D Engine's visual scripting environment, Script Canvas.", "canonical_tags": [ diff --git a/Gems/ScriptCanvasDeveloper/Code/Editor/Source/TSGenerateAction.cpp b/Gems/ScriptCanvasDeveloper/Code/Editor/Source/TSGenerateAction.cpp index 56168f6f56..75cf7e5392 100644 --- a/Gems/ScriptCanvasDeveloper/Code/Editor/Source/TSGenerateAction.cpp +++ b/Gems/ScriptCanvasDeveloper/Code/Editor/Source/TSGenerateAction.cpp @@ -11,6 +11,9 @@ #include #include #include +#include +#include +#include #endif #include @@ -34,6 +37,26 @@ namespace ScriptCanvasDeveloperEditor qAction->setShortcut(QAction::tr("Ctrl+Alt+R", "Developer|Reload Text")); QObject::connect(qAction, &QAction::triggered, [mainWindow]() { ReloadText(mainWindow); }); + qAction = mainMenu->addAction(QAction::tr("Dump Translation Database")); + qAction->setAutoRepeat(false); + qAction->setShortcut(QAction::tr("Ctrl+Alt+L", "Developer|Dump Translation Database")); + QObject::connect( + qAction, &QAction::triggered, + [mainWindow]() + { + QString defaultPath = QStandardPaths::writableLocation(QStandardPaths::DocumentsLocation); + QString directory = QFileDialog::getExistingDirectory(mainWindow, + QObject::tr("Select output folder for sc_translation.log file"), defaultPath); + if (!directory.isEmpty()) + { + const QString path = QDir::toNativeSeparators(directory + "/sc_translation.log"); + GraphCanvas::TranslationRequestBus::Broadcast(&GraphCanvas::TranslationRequests::DumpDatabase, path.toUtf8().constData()); + QMessageBox::information( + mainWindow, QObject::tr("Finished writing translation database"), + QObject::tr("Translation database written to:
%1").arg(path)); + } + }); + } return qAction; diff --git a/Gems/ScriptCanvasDeveloper/gem.json b/Gems/ScriptCanvasDeveloper/gem.json index 51aed9d9fa..c7e23dab9a 100644 --- a/Gems/ScriptCanvasDeveloper/gem.json +++ b/Gems/ScriptCanvasDeveloper/gem.json @@ -1,9 +1,10 @@ { - "gem_name": "ScriptCanvasDeveloperGem", + "gem_name": "ScriptCanvasDeveloper", "display_name": "Script Canvas Developer", "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Script Canvas Developer Gem provides a suite of utility features for the development and debugging of Script Canvas systems.", "canonical_tags": [ diff --git a/Gems/ScriptCanvasPhysics/Code/Source/WorldNodes.h b/Gems/ScriptCanvasPhysics/Code/Source/WorldNodes.h index 96a15a9d29..1b03bd1851 100644 --- a/Gems/ScriptCanvasPhysics/Code/Source/WorldNodes.h +++ b/Gems/ScriptCanvasPhysics/Code/Source/WorldNodes.h @@ -16,6 +16,7 @@ #include #include #include +#include #include #include @@ -120,6 +121,43 @@ namespace ScriptCanvasPhysics "EntityId", "Surface"); + AZ_INLINE Result RayCastFromScreenWithGroup( + const AZ::Vector2& screenPosition, + float distance, + const AZStd::string& collisionGroup, + AZ::EntityId ignore) + { + AZ::EntityId camera; + Camera::CameraSystemRequestBus::BroadcastResult(camera, &Camera::CameraSystemRequestBus::Events::GetActiveCamera); + if (camera.IsValid()) + { + AZ::Vector3 origin = AZ::Vector3::CreateZero(); + Camera::CameraRequestBus::EventResult(origin, camera, &Camera::CameraRequestBus::Events::ScreenToWorld, screenPosition, 0.f); + AZ::Vector3 offset = AZ::Vector3::CreateZero(); + Camera::CameraRequestBus::EventResult(offset, camera, &Camera::CameraRequestBus::Events::ScreenToWorld, screenPosition, 1.f); + const AZ::Vector3 direction = (offset - origin).GetNormalized(); + return RayCastWorldSpaceWithGroup(origin, direction, distance, collisionGroup, ignore); + } + + // fallback in the rare case there is no active camera + return AZStd::make_tuple(false, AZ::Vector3::CreateZero(), AZ::Vector3::CreateZero(), 0.0f, AZ::EntityId(), AZ::Crc32()); + } + + SCRIPT_CANVAS_GENERIC_FUNCTION_NODE(RayCastFromScreenWithGroup, + k_categoryName, + "{8F98A766-A93F-4DA7-B281-482C3DB20649}", + "Returns the first entity hit by a ray cast from the provided absolute 2D screen position.", + "Screen Position", + "Distance", + "Collision group", + "Ignore", + "Object hit", + "Position", + "Normal", + "Distance", + "EntityId", + "Surface"); + AZ_INLINE Result RayCastLocalSpaceWithGroup(const AZ::EntityId& fromEntityId, const AZ::Vector3& direction, float distance, @@ -389,6 +427,7 @@ namespace ScriptCanvasPhysics -#include +#include namespace SurfaceData { namespace Constants { static const char* s_unassignedTagName = AzFramework::SurfaceData::Constants::s_unassignedTagName; - static const char* s_terrainHoleTagName = "terrainHole"; - static const char* s_terrainTagName = "terrain"; static const AZ::Crc32 s_unassignedTagCrc = AZ::Crc32(s_unassignedTagName); - static const AZ::Crc32 s_terrainHoleTagCrc = AZ::Crc32(s_terrainHoleTagName); - static const AZ::Crc32 s_terrainTagCrc = AZ::Crc32(s_terrainTagName); - - static const char* s_allTagNames[] = - { - s_unassignedTagName, - s_terrainHoleTagName, - s_terrainTagName, - }; } } diff --git a/Gems/SurfaceData/Code/Source/Editor/EditorSurfaceDataSystemComponent.cpp b/Gems/SurfaceData/Code/Source/Editor/EditorSurfaceDataSystemComponent.cpp index a5bf51d0fe..a847da4347 100644 --- a/Gems/SurfaceData/Code/Source/Editor/EditorSurfaceDataSystemComponent.cpp +++ b/Gems/SurfaceData/Code/Source/Editor/EditorSurfaceDataSystemComponent.cpp @@ -12,7 +12,6 @@ #include #include - namespace SurfaceData { namespace Details @@ -124,10 +123,7 @@ namespace SurfaceData void EditorSurfaceDataSystemComponent::GetRegisteredSurfaceTagNames(SurfaceTagNameSet& masks) const { - for (const auto& tagName : Constants::s_allTagNames) - { - masks.insert(tagName); - } + masks.insert(Constants::s_unassignedTagName); for (const auto& assetPair : m_surfaceTagNameAssets) { diff --git a/Gems/SurfaceData/Code/Source/Editor/EditorSurfaceDataSystemComponent.h b/Gems/SurfaceData/Code/Source/Editor/EditorSurfaceDataSystemComponent.h index 603cffc56d..466da8482e 100644 --- a/Gems/SurfaceData/Code/Source/Editor/EditorSurfaceDataSystemComponent.h +++ b/Gems/SurfaceData/Code/Source/Editor/EditorSurfaceDataSystemComponent.h @@ -47,7 +47,6 @@ namespace SurfaceData static void GetRequiredServices(AZ::ComponentDescriptor::DependencyArrayType& required); private: - void LoadAsset(const AZ::Data::AssetId& assetId); void AddAsset(AZ::Data::Asset& asset); diff --git a/Gems/SurfaceData/Code/Tests/SurfaceDataTest.cpp b/Gems/SurfaceData/Code/Tests/SurfaceDataTest.cpp index d5384161ad..9d182312a4 100644 --- a/Gems/SurfaceData/Code/Tests/SurfaceDataTest.cpp +++ b/Gems/SurfaceData/Code/Tests/SurfaceDataTest.cpp @@ -281,15 +281,17 @@ public: TEST_F(SurfaceDataTestApp, SurfaceData_TestRegisteredTags) { + // Check that only the unassigned tag exists if no other providers are registered. AZStd::vector> registeredTags = SurfaceData::SurfaceTag::GetRegisteredTags(); - for (const auto& searchTerm : SurfaceData::Constants::s_allTagNames) - { - ASSERT_TRUE(AZStd::find_if(registeredTags.begin(), registeredTags.end(), [searchTerm](decltype(registeredTags)::value_type pair) + const auto& searchTerm = SurfaceData::Constants::s_unassignedTagName; + + ASSERT_TRUE(AZStd::find_if( + registeredTags.begin(), registeredTags.end(), + [=](decltype(registeredTags)::value_type pair) { return pair.second == searchTerm; })); - } } #if AZ_TRAIT_DISABLE_FAILED_SURFACE_DATA_TESTS diff --git a/Gems/SurfaceData/gem.json b/Gems/SurfaceData/gem.json index d16254040f..10100e3b90 100644 --- a/Gems/SurfaceData/gem.json +++ b/Gems/SurfaceData/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Surface Data Gem provides functionality to emit signals or tags from surfaces such as meshes and terrain.", "canonical_tags": [ diff --git a/Gems/Terrain/Assets/Materials/Terrain/DefaultPbrTerrain.material b/Gems/Terrain/Assets/Materials/Terrain/DefaultPbrTerrain.material index 53f6fd5b9e..da2fc95293 100644 --- a/Gems/Terrain/Assets/Materials/Terrain/DefaultPbrTerrain.material +++ b/Gems/Terrain/Assets/Materials/Terrain/DefaultPbrTerrain.material @@ -5,7 +5,7 @@ "propertyLayoutVersion": 1, "properties": { "baseColor": { - "color": [ 0.18, 0.18, 0.18 ] + "color": [ 0.18, 0.18, 0.18 ] } } } diff --git a/Gems/Terrain/Assets/Materials/Terrain/PbrTerrain.materialtype b/Gems/Terrain/Assets/Materials/Terrain/PbrTerrain.materialtype index 1e7305cc11..836e85661d 100644 --- a/Gems/Terrain/Assets/Materials/Terrain/PbrTerrain.materialtype +++ b/Gems/Terrain/Assets/Materials/Terrain/PbrTerrain.materialtype @@ -107,7 +107,7 @@ "displayName": "Detail Texture UV Multiplier", "description": "How many times to repeat the detail texture per sector", "type": "Float", - "defaultValue": 8.0, + "defaultValue": 0.5, "connection": { "type": "ShaderInput", "id": "m_detailTextureMultiplier" diff --git a/Gems/Terrain/Assets/Shaders/Terrain/SceneSrg.azsli b/Gems/Terrain/Assets/Shaders/Terrain/SceneSrg.azsli new file mode 100644 index 0000000000..2545db7c93 --- /dev/null +++ b/Gems/Terrain/Assets/Shaders/Terrain/SceneSrg.azsli @@ -0,0 +1,35 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#ifndef AZ_COLLECTING_PARTIAL_SRGS +#error Do not include this file directly. Include the main .srgi file instead. +#endif + +partial ShaderResourceGroup SceneSrg +{ + Sampler HeightmapSampler + { + MinFilter = Linear; + MagFilter = Linear; + MipFilter = Point; + AddressU = Clamp; + AddressV = Clamp; + AddressW = Clamp; + }; + + struct TerrainWorldData + { + float3 m_min; + float m_padding1; + float3 m_max; + float m_padding2; + }; + + Texture2D m_heightmapImage; + TerrainWorldData m_terrainWorldData; +} diff --git a/Gems/Terrain/Assets/Shaders/Terrain/TerrainCommon.azsli b/Gems/Terrain/Assets/Shaders/Terrain/TerrainCommon.azsli index 770f877ea8..ee3e9b2a5f 100644 --- a/Gems/Terrain/Assets/Shaders/Terrain/TerrainCommon.azsli +++ b/Gems/Terrain/Assets/Shaders/Terrain/TerrainCommon.azsli @@ -15,34 +15,13 @@ ShaderResourceGroup ObjectSrg : SRG_PerObject { - struct TerrainData + struct PatchData { - float2 m_uvMin; - float2 m_uvMax; - float2 m_uvStep; - float m_sampleSpacing; - float m_heightScale; + float2 m_xyTranslation; + float m_xyScale; }; - struct MacroMaterialData - { - float2 m_uvMin; - float2 m_uvMax; - float m_normalFactor; - bool m_flipNormalX; - bool m_flipNormalY; - uint m_mapsInUse; - }; - - row_major float3x4 m_modelToWorld; - - TerrainData m_terrainData; - - MacroMaterialData m_macroMaterialData[4]; - uint m_macroMaterialCount; - - Texture2D m_macroColorMap[4]; - Texture2D m_macroNormalMap[4]; + PatchData m_patchData; // The below shouldn't be in this SRG but needs to be for now because the lighting functions depend on them. @@ -117,109 +96,137 @@ option bool o_useTerrainSmoothing = false; struct VertexInput { float2 m_position : POSITION; - float2 m_uv : UV; }; -// Sample a texture with a 5 tap B-Spline. Consider ripping this out and putting in a more general location. -// This function samples a 4x4 neighborhood around the uv. Normally this would take 16 samples, but by taking -// advantage of bilinear filtering this can be done with 9 taps on the edges between pixels. The cost is further -// reduced by dropping the diagonals. -float SampleBSpline5Tap(Texture2D texture, SamplerState textureSampler, float2 uv, float2 textureSize, float2 rcpTextureSize) +// This class is used to calculate heights and normals for terrain. Using a class for this was the easiest way to +// de-duplicate code between the forward and depth shaders. +class HeightContext { - // Think of sample locations in the 4x4 neighborhood as having a top left coordinate of 0,0 and - // a bottom right coordinate of 3,3. - - // Find the position in texture space then round it to get the center of the 1,1 pixel (tc1) - float2 texelPos = uv * textureSize; - float2 tc1= floor(texelPos - 0.5) + 0.5; - - // Offset from center position to texel - float2 f = texelPos - tc1; - - // Compute B-Spline weights based on the offset - float2 OneMinusF = (1.0 - f); - float2 OneMinusF2 = OneMinusF * OneMinusF; - float2 OneMinusF3 = OneMinusF2 * OneMinusF; - float2 w0 = OneMinusF3; - float2 w1 = 4.0 + 3.0 * f * f * f - 6.0 * f * f; - float2 w2 = 4.0 + 3.0 * OneMinusF3 - 6.0 * OneMinusF2; - float2 w3 = f * f * f; - - float2 w12 = w1 + w2; - - // Compute uv coordinates for sampling the texture - float2 tc0 = (tc1 - 1.0f) * rcpTextureSize; - float2 tc3 = (tc1 + 2.0f) * rcpTextureSize; - float2 tc12 = (tc1 + w2 / w12) * rcpTextureSize; - - // Compute sample weights - float sw0 = w12.x * w12.y; // middle - float sw1 = w12.x * w0.y; // top - float sw2 = w0.x * w12.y; // left - float sw3 = w12.x * w3.y; // bottom - float sw4 = w3.x * w12.y; // right - - // total weight of samples to normalize result. - float totalWeight = sw0 + sw1 + sw2 + sw3 + sw4; - - float result = 0.0f; - result += texture.SampleLevel(textureSampler, float2(tc12.x, tc12.y), 0.0).r * sw0; - result += texture.SampleLevel(textureSampler, float2(tc12.x, tc0.y), 0.0).r * sw1; - result += texture.SampleLevel(textureSampler, float2( tc0.x, tc12.y), 0.0).r * sw2; - result += texture.SampleLevel(textureSampler, float2(tc12.x, tc3.y), 0.0).r * sw3; - result += texture.SampleLevel(textureSampler, float2( tc3.x, tc12.y), 0.0).r * sw4; - - return result / totalWeight; -} + float3 m_worldMin; + float3 m_worldMax; + float2 m_xyPosition; -float4x4 GetObject_WorldMatrix() -{ - float4x4 modelToWorld = float4x4( - float4(1, 0, 0, 0), - float4(0, 1, 0, 0), - float4(0, 0, 1, 0), - float4(0, 0, 0, 1)); - - modelToWorld[0] = ObjectSrg::m_modelToWorld[0]; - modelToWorld[1] = ObjectSrg::m_modelToWorld[1]; - modelToWorld[2] = ObjectSrg::m_modelToWorld[2]; - return modelToWorld; -} + float2 m_textureSize; + float2 m_rcpTextureSize; + float2 m_sampleSpacing; + float2 m_rcpSampleSpacing; -float GetHeight(float2 origUv) -{ - float2 halfStep = ObjectSrg::m_terrainData.m_uvStep * 0.5; - float2 uv = origUv * (1.0 - ObjectSrg::m_terrainData.m_uvStep) + halfStep; + float m_heightScale; + int2 m_heightmapCoord; - float height = 0.0f; - if (o_useTerrainSmoothing) + + // Sample a texture with a 5 tap B-Spline. Consider ripping this out and putting in a more general location. + // This function samples a 4x4 neighborhood around the uv. Normally this would take 16 samples, but by taking + // advantage of bilinear filtering this can be done with 9 taps on the edges between pixels. The cost is further + // reduced by dropping the diagonals. + float SampleBSpline5Tap(Texture2D texture, SamplerState textureSampler, float2 uv, float2 textureSize, float2 rcpTextureSize) { - float2 textureSize; - ViewSrg::m_heightmapImage.GetDimensions(textureSize.x, textureSize.y); - height = SampleBSpline5Tap(ViewSrg::m_heightmapImage, ViewSrg::HeightmapSampler, uv, textureSize, rcp(textureSize)); + // Think of sample locations in the 4x4 neighborhood as having a top left coordinate of 0,0 and + // a bottom right coordinate of 3,3. + + // Find the position in texture space then round it to get the center of the 1,1 pixel (tc1) + float2 texelPos = uv * textureSize; + float2 tc1= floor(texelPos - 0.5) + 0.5; + + // Offset from center position to texel + float2 f = texelPos - tc1; + + // Compute B-Spline weights based on the offset + float2 OneMinusF = (1.0 - f); + float2 OneMinusF2 = OneMinusF * OneMinusF; + float2 OneMinusF3 = OneMinusF2 * OneMinusF; + float2 w0 = OneMinusF3; + float2 w1 = 4.0 + 3.0 * f * f * f - 6.0 * f * f; + float2 w2 = 4.0 + 3.0 * OneMinusF3 - 6.0 * OneMinusF2; + float2 w3 = f * f * f; + + float2 w12 = w1 + w2; + + // Compute uv coordinates for sampling the texture + float2 tc0 = (tc1 - 1.0f) * rcpTextureSize; + float2 tc3 = (tc1 + 2.0f) * rcpTextureSize; + float2 tc12 = (tc1 + w2 / w12) * rcpTextureSize; + + // Compute sample weights + float sw0 = w12.x * w12.y; // middle + float sw1 = w12.x * w0.y; // top + float sw2 = w0.x * w12.y; // left + float sw3 = w12.x * w3.y; // bottom + float sw4 = w3.x * w12.y; // right + + // total weight of samples to normalize result. + float totalWeight = sw0 + sw1 + sw2 + sw3 + sw4; + + float result = 0.0f; + result += texture.SampleLevel(textureSampler, float2(tc12.x, tc12.y), 0.0).r * sw0; + result += texture.SampleLevel(textureSampler, float2(tc12.x, tc0.y), 0.0).r * sw1; + result += texture.SampleLevel(textureSampler, float2( tc0.x, tc12.y), 0.0).r * sw2; + result += texture.SampleLevel(textureSampler, float2(tc12.x, tc3.y), 0.0).r * sw3; + result += texture.SampleLevel(textureSampler, float2( tc3.x, tc12.y), 0.0).r * sw4; + + return result / totalWeight; } - else + + float2 GetWorldXYPosition(in ObjectSrg::PatchData patchData, in float2 vertexPosition) { - height = ViewSrg::m_heightmapImage.SampleLevel(ViewSrg::HeightmapSampler, uv, 0).r; + return float2(patchData.m_xyTranslation + vertexPosition * patchData.m_xyScale); } - return ObjectSrg::m_terrainData.m_heightScale * (height - 0.5f); -} + float2 GetHeightmapUv(in float2 position, in float2 worldMin, in float2 worldMax) + { + return (position - worldMin) / (worldMax - worldMin); + } -float3 GetTerrainWorldPosition(ObjectSrg::TerrainData terrainData, float2 vertexPosition, float2 uv) -{ - // Remove all vertices outside our bounds by turning them into NaN positions. - if (any(uv > 1.0) || any (uv < 0.0)) + int2 GetHeightmapCoord(in float2 position, in float2 rcpSampleSpacing, in float2 worldMin) { - return asfloat(0x7fc00000); // NaN + return int2((position - worldMin) * rcpSampleSpacing); } - // Loop up the height and calculate our final position. - float height = GetHeight(uv); - return mul(GetObject_WorldMatrix(), float4(vertexPosition, height, 1.0f)).xyz; -} + float GetHeight(Texture2D heightmapImage, int2 offset = int2(0, 0)) + { + float height = heightmapImage.Load(int3(m_heightmapCoord + offset, 0)).r; + return m_worldMin.z + height * m_heightScale; + } -float4 GetTerrainProjectedPosition(ObjectSrg::TerrainData terrainData, float2 vertexPosition, float2 uv) -{ - return mul(ViewSrg::m_viewProjectionMatrix, float4(GetTerrainWorldPosition(terrainData, vertexPosition, uv), 1.0)); -} + float GetSmoothedHeight(Texture2D heightmapImage, SamplerState heightmapSampler) + { + float2 uv = GetHeightmapUv(m_xyPosition, m_worldMin.xy, m_worldMax.xy); + float2 halfStep = m_rcpTextureSize * 0.5; + uv = uv * (1.0 - m_rcpTextureSize) + halfStep; + float height = SampleBSpline5Tap(heightmapImage, heightmapSampler, uv, m_textureSize, m_rcpTextureSize); + return m_worldMin.z + height * (m_worldMax.z - m_worldMin.z); + } + + float3 CalculateNormal(Texture2D heightmapImage) + { + float up = GetHeight(heightmapImage, int2( 0, -1)); + float right = GetHeight(heightmapImage, int2( 1, 0)); + float down = GetHeight(heightmapImage, int2( 0, 1)); + float left = GetHeight(heightmapImage, int2(-1, 0)); + + float3 bitangent = normalize(float3(0.0, m_sampleSpacing.y * 2.0f, down - up)); + float3 tangent = normalize(float3(m_sampleSpacing.x * 2.0f, 0.0, right - left)); + return normalize(cross(tangent, bitangent)); + } + + bool IsVertexOutsideOfTerrainBounds() + { + return (any(m_xyPosition < m_worldMin.xy) || + any(m_xyPosition > m_worldMax.xy)); + } + + void Initialize(Texture2D heightmapImage, float2 vertexPosition, ObjectSrg::PatchData patchData, float3 worldMin, float3 worldMax) + { + m_worldMin = worldMin; + m_worldMax = worldMax; + m_xyPosition = GetWorldXYPosition(patchData, vertexPosition); + + heightmapImage.GetDimensions(m_textureSize.x, m_textureSize.y); + m_rcpTextureSize = rcp(m_textureSize); + m_sampleSpacing = (worldMax.xy - worldMin.xy) * m_rcpTextureSize; + m_rcpSampleSpacing = rcp(m_sampleSpacing); + + m_heightScale = worldMax.z - worldMin.z; + m_heightmapCoord = GetHeightmapCoord(m_xyPosition, m_rcpSampleSpacing, worldMin.xy); + } +}; diff --git a/Gems/Terrain/Assets/Shaders/Terrain/TerrainDetailHelpers.azsli b/Gems/Terrain/Assets/Shaders/Terrain/TerrainDetailHelpers.azsli index 33c817c0f9..b18f2885db 100644 --- a/Gems/Terrain/Assets/Shaders/Terrain/TerrainDetailHelpers.azsli +++ b/Gems/Terrain/Assets/Shaders/Terrain/TerrainDetailHelpers.azsli @@ -123,7 +123,7 @@ float3 GetDetailColor(TerrainSrg::DetailMaterialData materialData, float2 uv, fl float3 color = materialData.m_baseColor; if ((materialData.m_flags & DetailTextureFlags::UseTextureBaseColor) > 0) { - color = TerrainSrg::m_detailTextures[GetDetailColorIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).rgb; + color = TerrainSrg::m_textures[GetDetailColorIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).rgb; } return color * materialData.m_baseColorFactor; } @@ -133,7 +133,7 @@ float3 GetDetailNormal(TerrainSrg::DetailMaterialData materialData, float2 uv, f float2 normal = float2(0.0, 0.0); if ((materialData.m_flags & DetailTextureFlags::UseTextureNormal) > 0) { - normal = TerrainSrg::m_detailTextures[GetDetailNormalIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).rg; + normal = TerrainSrg::m_textures[GetDetailNormalIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).rg; } // X and Y are inverted here to be consistent with SampleNormalXY in NormalInput.azsli. @@ -153,7 +153,7 @@ float GetDetailRoughness(TerrainSrg::DetailMaterialData materialData, float2 uv, float roughness = materialData.m_roughnessScale; if ((materialData.m_flags & DetailTextureFlags::UseTextureRoughness) > 0) { - roughness = TerrainSrg::m_detailTextures[GetDetailRoughnessIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; + roughness = TerrainSrg::m_textures[GetDetailRoughnessIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; roughness = materialData.m_roughnessBias + roughness * materialData.m_roughnessScale; } return roughness; @@ -164,7 +164,7 @@ float GetDetailMetalness(TerrainSrg::DetailMaterialData materialData, float2 uv, float metalness = 1.0; if ((materialData.m_flags & DetailTextureFlags::UseTextureMetallic) > 0) { - metalness = TerrainSrg::m_detailTextures[GetDetailMetalnessIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; + metalness = TerrainSrg::m_textures[GetDetailMetalnessIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; } return metalness * materialData.m_metalFactor; } @@ -174,7 +174,7 @@ float GetDetailSpecularF0(TerrainSrg::DetailMaterialData materialData, float2 uv float specularF0 = 1.0; if ((materialData.m_flags & DetailTextureFlags::UseTextureSpecularF0) > 0) { - specularF0 = TerrainSrg::m_detailTextures[GetDetailSpecularF0Index(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; + specularF0 = TerrainSrg::m_textures[GetDetailSpecularF0Index(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; } return specularF0 * materialData.m_specularF0Factor; } @@ -184,7 +184,7 @@ float GetDetailOcclusion(TerrainSrg::DetailMaterialData materialData, float2 uv, float occlusion = 1.0; if ((materialData.m_flags & DetailTextureFlags::UseTextureOcclusion) > 0) { - occlusion = TerrainSrg::m_detailTextures[GetDetailOcclusionIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; + occlusion = TerrainSrg::m_textures[GetDetailOcclusionIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; } return occlusion * materialData.m_occlusionFactor; } @@ -194,7 +194,7 @@ float GetDetailHeight(TerrainSrg::DetailMaterialData materialData, float2 uv, fl float height = materialData.m_heightFactor; if ((materialData.m_flags & DetailTextureFlags::UseTextureHeight) > 0) { - height = TerrainSrg::m_detailTextures[GetDetailHeightIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; + height = TerrainSrg::m_textures[GetDetailHeightIndex(materialData)].SampleGrad(TerrainMaterialSrg::m_sampler, uv, ddx, ddy).r; height = materialData.m_heightOffset + height * materialData.m_heightFactor; } return height; diff --git a/Gems/Terrain/Assets/Shaders/Terrain/TerrainPBR_ForwardPass.azsl b/Gems/Terrain/Assets/Shaders/Terrain/TerrainPBR_ForwardPass.azsl index ab9064e740..741f45d775 100644 --- a/Gems/Terrain/Assets/Shaders/Terrain/TerrainPBR_ForwardPass.azsl +++ b/Gems/Terrain/Assets/Shaders/Terrain/TerrainPBR_ForwardPass.azsl @@ -8,6 +8,7 @@ #include +#include #include #include #include @@ -26,7 +27,6 @@ struct VSOutput float4 m_position : SV_Position; float3 m_normal: NORMAL; float3 m_worldPosition : UV0; - float2 m_uv : UV1; float3 m_shadowCoords[ViewSrg::MaxCascadeCount] : UV2; }; @@ -34,24 +34,30 @@ VSOutput TerrainPBR_MainPassVS(VertexInput IN) { VSOutput OUT; - ObjectSrg::TerrainData terrainData = ObjectSrg::m_terrainData; + HeightContext heightContext; + heightContext.Initialize(SceneSrg::m_heightmapImage, IN.m_position, ObjectSrg::m_patchData, SceneSrg::m_terrainWorldData.m_min, SceneSrg::m_terrainWorldData.m_max); - float2 uv = IN.m_uv; - float2 origUv = lerp(terrainData.m_uvMin, terrainData.m_uvMax, uv); - float3 worldPosition = GetTerrainWorldPosition(terrainData, IN.m_position, origUv); - OUT.m_position = mul(ViewSrg::m_viewProjectionMatrix, float4(worldPosition, 1.0)); - OUT.m_worldPosition = worldPosition; + if (heightContext.IsVertexOutsideOfTerrainBounds()) + { + // Output a NaN to remove this vertex. + OUT.m_position = 1.0 / 0.0; + return OUT; + } - // Calculate normal - float up = GetHeight(origUv + terrainData.m_uvStep * float2( 0.0f, -1.0f)); - float right = GetHeight(origUv + terrainData.m_uvStep * float2( 1.0f, 0.0f)); - float down = GetHeight(origUv + terrainData.m_uvStep * float2( 0.0f, 1.0f)); - float left = GetHeight(origUv + terrainData.m_uvStep * float2(-1.0f, 0.0f)); + float height = 0.0; - float3 bitangent = normalize(float3(0.0, terrainData.m_sampleSpacing * 2.0f, down - up)); - float3 tangent = normalize(float3(terrainData.m_sampleSpacing * 2.0f, 0.0, right - left)); - OUT.m_normal = normalize(cross(tangent, bitangent)); - OUT.m_uv = uv; + if (o_useTerrainSmoothing) + { + height = heightContext.GetSmoothedHeight(SceneSrg::m_heightmapImage, SceneSrg::HeightmapSampler); + } + else + { + height = heightContext.GetHeight(SceneSrg::m_heightmapImage); + } + + OUT.m_worldPosition = float3(heightContext.m_xyPosition, height); + OUT.m_position = mul(ViewSrg::m_viewProjectionMatrix, float4(OUT.m_worldPosition, 1.0)); + OUT.m_normal = heightContext.CalculateNormal(SceneSrg::m_heightmapImage); // directional light shadow const uint shadowIndex = ViewSrg::m_shadowIndexDirectionalLight; @@ -59,7 +65,7 @@ VSOutput TerrainPBR_MainPassVS(VertexInput IN) { DirectionalLightShadow::GetShadowCoords( shadowIndex, - worldPosition, + OUT.m_worldPosition, OUT.m_normal, OUT.m_shadowCoords); } @@ -76,7 +82,7 @@ ForwardPassOutput TerrainPBR_MainPassPS(VSOutput IN) float viewDistance = length(ViewSrg::m_worldPosition - surface.position); float detailFactor = saturate((viewDistance - TerrainMaterialSrg::m_detailFadeDistance) / max(TerrainMaterialSrg::m_detailFadeLength, EPSILON)); - float2 detailUv = IN.m_uv * TerrainMaterialSrg::m_detailTextureMultiplier; + float2 detailUv = IN.m_worldPosition.xy * TerrainMaterialSrg::m_detailTextureMultiplier; // ------- Normal ------- float3 macroNormal = normalize(IN.m_normal); @@ -84,39 +90,54 @@ ForwardPassOutput TerrainPBR_MainPassPS(VSOutput IN) // ------- Macro Color / Normal ------- float3 macroColor = TerrainMaterialSrg::m_baseColor.rgb; - // There's a bug that shows up with an NVidia GTX 1660 Super card happening on driver versions as recent as 496.49 (10/26/21) in which - // the IN.m_uv values will intermittently "flicker" to 0.0 after entering and exiting game mode. - // (See https://github.com/o3de/o3de/issues/5014) - // This bug has only shown up on PCs when using the DX12 RHI. It doesn't show up with Vulkan or when capturing frames with PIX or - // RenderDoc. Our best guess is that it is a driver bug. The workaround is to use the IN.m_uv values in a calculation prior to the - // point that we actually use them for macroUv below. The "if(any(!isnan(IN.m_uv)))" seems to be sufficient for the workaround. The - // if statement will always be true, but just the act of reading these values in the if statement makes the values stable. Removing - // the if statement causes the flickering to occur using the steps documented in the bug. - if (any(!isnan(IN.m_uv))) + uint2 macroGridResolution = uint2(TerrainSrg::m_macroMaterialGrid.m_resolution >> 16, TerrainSrg::m_macroMaterialGrid.m_resolution & 0xFFFF); + float macroTileSize = TerrainSrg::m_macroMaterialGrid.m_tileSize; + float2 macroGridOffset = TerrainSrg::m_macroMaterialGrid.m_offset; + uint2 macroGridPosition = (surface.position.xy - macroGridOffset) / macroTileSize; + + uint macroTileIndex = macroGridResolution.x * macroGridPosition.y + macroGridPosition.x; + static const uint NumMacroMaterialsPerTile = 4; + macroTileIndex *= NumMacroMaterialsPerTile; + + [unroll] for (uint i = 0; i < NumMacroMaterialsPerTile; ++i) { - [unroll] for (uint i = 0; i < 4 && (i < ObjectSrg::m_macroMaterialCount); ++i) + TerrainSrg::MacroMaterialData macroMaterialData = TerrainSrg::m_macroMaterialData[macroTileIndex + i]; + if ((macroMaterialData.m_flags & 1) == 0) + { + break; // No more macro materials for this tile + } + + if (any(surface.position.xy < macroMaterialData.m_boundsMin) || any (surface.position.xy > macroMaterialData.m_boundsMax)) + { + continue; // Macro material exists for this tile but is out of the bounds of this particular position + } + + float2 macroUvSize = macroMaterialData.m_boundsMax - macroMaterialData.m_boundsMin; + macroUvSize.x = -macroUvSize.x; + float2 macroUv = (macroMaterialData.m_boundsMin - surface.position.xy) / macroUvSize; + + // The macro uv gradient can vary massively over the quad because different pixels may choose different macro materials with different UVs. + // To fix, we use the world position scaled by the macro uv scale which should be fairly uniform across macro materials. + float2 macroUvScale = IN.m_worldPosition.xy / macroUvSize; + float2 ddx_macroUv = ddx(macroUvScale); + float2 ddy_macroUv = ddy(macroUvScale); + + if (macroMaterialData.m_colorMapId != 0xFFFF) + { + macroColor = TerrainSrg::m_textures[macroMaterialData.m_colorMapId].SampleGrad(TerrainMaterialSrg::m_sampler, macroUv, ddx_macroUv, ddy_macroUv).rgb; + macroColor = TransformColor(macroColor, ColorSpaceId::LinearSRGB, ColorSpaceId::ACEScg); + } + + if (macroMaterialData.m_normalMapId != 0xFFFF) { - float2 macroUvMin = ObjectSrg::m_macroMaterialData[i].m_uvMin; - float2 macroUvMax = ObjectSrg::m_macroMaterialData[i].m_uvMax; - float2 macroUv = lerp(macroUvMin, macroUvMax, IN.m_uv); - if (macroUv.x >= 0.0 && macroUv.x <= 1.0 && macroUv.y >= 0.0 && macroUv.y <= 1.0) - { - if ((ObjectSrg::m_macroMaterialData[i].m_mapsInUse & 1) > 0) - { - macroColor = GetBaseColorInput(ObjectSrg::m_macroColorMap[i], TerrainMaterialSrg::m_sampler, macroUv, macroColor, true); - } - if ((ObjectSrg::m_macroMaterialData[i].m_mapsInUse & 2) > 0) - { - bool flipX = ObjectSrg::m_macroMaterialData[i].m_flipNormalX; - bool flipY = ObjectSrg::m_macroMaterialData[i].m_flipNormalY; - float factor = ObjectSrg::m_macroMaterialData[i].m_normalFactor; - - float2 sampledValue = SampleNormalXY(ObjectSrg::m_macroNormalMap[i], TerrainMaterialSrg::m_sampler, macroUv, flipX, flipY); - macroNormal = normalize(GetTangentSpaceNormal_Unnormalized(sampledValue.xy, factor)); - } - break; - } + bool flipX = macroMaterialData.m_flags & 2; + bool flipY = macroMaterialData.m_flags & 4; + float factor = macroMaterialData.m_normalFactor; + + float2 sampledValue = SampleNormalXY(TerrainSrg::m_textures[macroMaterialData.m_normalMapId], TerrainMaterialSrg::m_sampler, macroUv, flipX, flipY); + macroNormal = normalize(GetTangentSpaceNormal_Unnormalized(sampledValue, factor)); } + break; } // ------- Base Color ------- diff --git a/Gems/Terrain/Assets/Shaders/Terrain/TerrainSrg.azsli b/Gems/Terrain/Assets/Shaders/Terrain/TerrainSrg.azsli index f980e02b9d..3fcf8d75ca 100644 --- a/Gems/Terrain/Assets/Shaders/Terrain/TerrainSrg.azsli +++ b/Gems/Terrain/Assets/Shaders/Terrain/TerrainSrg.azsli @@ -53,12 +53,38 @@ ShaderResourceGroup TerrainSrg : SRG_Terrain uint2 m_padding; }; + struct MacroMaterialData + { + // bit 1 : Is this macro material used. + // bit 2 : flip normal x + // bit 3 : flip normal y + uint m_flags; + + uint m_colorMapId; + uint m_normalMapId; + float m_normalFactor; + float2 m_boundsMin; + float2 m_boundsMax; + }; + + struct MacroMaterialGrid + { + uint m_resolution; // How many x/y tiles in grid. x & y stored in 16 bits each. Total number of entries in m_macroMaterialData will be x * y + float m_tileSize; // Size of a tile in meters. + float2 m_offset; // x/y offset of min x/y corner of grid. + }; + Texture2D m_detailMaterialIdImage; StructuredBuffer m_detailMaterialData; - Texture2D m_detailTextures[]; // bindless array of all textures for detail materials + StructuredBuffer m_macroMaterialData; + MacroMaterialGrid m_macroMaterialGrid; + + Texture2D m_textures[]; // bindless array of all textures for detail and macro materials float2 m_detailMaterialIdImageCenter; float m_detailHalfPixelUv; float4 m_detailAabb; } + +static const float MacroMaterialsPerTile = 4; diff --git a/Gems/Terrain/Assets/Shaders/Terrain/Terrain_DepthPass.azsl b/Gems/Terrain/Assets/Shaders/Terrain/Terrain_DepthPass.azsl index fd855a1bcd..c74a0646ee 100644 --- a/Gems/Terrain/Assets/Shaders/Terrain/Terrain_DepthPass.azsl +++ b/Gems/Terrain/Assets/Shaders/Terrain/Terrain_DepthPass.azsl @@ -6,6 +6,7 @@ */ #include +#include #include #include "TerrainCommon.azsli" #include @@ -18,9 +19,30 @@ struct VSDepthOutput VSDepthOutput MainVS(in VertexInput input) { VSDepthOutput output; - ObjectSrg::TerrainData terrainData = ObjectSrg::m_terrainData; - float2 origUv = lerp(terrainData.m_uvMin, terrainData.m_uvMax, input.m_uv); - output.m_position = GetTerrainProjectedPosition(terrainData, input.m_position, origUv); + HeightContext heightContext; + heightContext.Initialize(SceneSrg::m_heightmapImage, input.m_position, ObjectSrg::m_patchData, SceneSrg::m_terrainWorldData.m_min, SceneSrg::m_terrainWorldData.m_max); + + if (heightContext.IsVertexOutsideOfTerrainBounds()) + { + // Output a NaN to remove this vertex. + output.m_position = 1.0 / 0.0; + return output; + } + + float height = 0.0; + + if (o_useTerrainSmoothing) + { + height = heightContext.GetSmoothedHeight(SceneSrg::m_heightmapImage, SceneSrg::HeightmapSampler); + } + else + { + height = heightContext.GetHeight(SceneSrg::m_heightmapImage); + } + + float3 worldPosition = float3(heightContext.m_xyPosition, height); + output.m_position = mul(ViewSrg::m_viewProjectionMatrix, float4(worldPosition, 1.0)); + return output; } diff --git a/Gems/Terrain/Assets/Shaders/Terrain/ViewSrg.azsli b/Gems/Terrain/Assets/Shaders/Terrain/ViewSrg.azsli deleted file mode 100644 index 144f2abf6b..0000000000 --- a/Gems/Terrain/Assets/Shaders/Terrain/ViewSrg.azsli +++ /dev/null @@ -1,80 +0,0 @@ -/* - * Copyright (c) Contributors to the Open 3D Engine Project. - * For complete copyright and license terms please see the LICENSE at the root of this distribution. - * - * SPDX-License-Identifier: Apache-2.0 OR MIT - * - */ - -#ifndef AZ_COLLECTING_PARTIAL_SRGS -#error Do not include this file directly. Include the main .srgi file instead. -#endif - -partial ShaderResourceGroup ViewSrg -{ - Sampler HeightmapSampler - { - MinFilter = Linear; - MagFilter = Linear; - MipFilter = Point; - AddressU = Clamp; - AddressV = Clamp; - AddressW = Clamp; - }; - - Sampler DetailSampler - { - AddressU = Wrap; - AddressV = Wrap; - MinFilter = Point; - MagFilter = Point; - MipFilter = Point; - }; - - struct DetailMaterialData - { - // Uv - row_major float3x4 m_uvTransform; - - float3 m_baseColor; - - // Factor / Scale / Bias for input textures - float m_baseColorFactor; - - float m_normalFactor; - float m_metalFactor; - float m_roughnessScale; - float m_roughnessBias; - - float m_specularF0Factor; - float m_occlusionFactor; - float m_heightFactor; - float m_heightOffset; - - float m_heightBlendFactor; - - // Flags - uint m_flags; // see DetailTextureFlags - - // Image indices - uint m_colorNormalImageIndices; - uint m_roughnessMetalnessImageIndices; - - uint m_specularF0OcclusionImageIndices; - uint m_heightImageIndex; // only first 16 bits used - - // 16 byte aligned - uint2 m_padding; - }; - - Texture2D m_heightmapImage; - Texture2D m_detailMaterialIdImage; - StructuredBuffer m_detailMaterialData; - - Texture2D m_detailTextures[]; // bindless array of all textures for detail materials - - float2 m_detailMaterialIdImageCenter; - float m_detailHalfPixelUv; - - float4 m_detailAabb; -} diff --git a/Gems/Terrain/Code/CMakeLists.txt b/Gems/Terrain/Code/CMakeLists.txt index d532284350..69a1bef3c0 100644 --- a/Gems/Terrain/Code/CMakeLists.txt +++ b/Gems/Terrain/Code/CMakeLists.txt @@ -119,6 +119,11 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) NAME Gem::Terrain.Tests ) + ly_add_googlebenchmark( + NAME Gem::Terrain.Benchmarks + TARGET Gem::Terrain.Tests + ) + # If we are a host platform we want to add tools test like editor tests here if(PAL_TRAIT_BUILD_HOST_TOOLS) # We support Terrain.Editor.Tests on this platform, add Terrain.Editor.Tests target which depends on Terrain.Editor diff --git a/Gems/Terrain/Code/Include/Terrain/TerrainDataConstants.h b/Gems/Terrain/Code/Include/Terrain/TerrainDataConstants.h new file mode 100644 index 0000000000..e125e41ccf --- /dev/null +++ b/Gems/Terrain/Code/Include/Terrain/TerrainDataConstants.h @@ -0,0 +1,24 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include + +namespace Terrain +{ + namespace Constants + { + static const char* s_terrainHoleTagName = "terrainHole"; + static const char* s_terrainTagName = "terrain"; + + static const AZ::Crc32 s_terrainHoleTagCrc = AZ::Crc32(s_terrainHoleTagName); + static const AZ::Crc32 s_terrainTagCrc = AZ::Crc32(s_terrainTagName); + } +} diff --git a/Gems/Terrain/Code/Source/Components/TerrainHeightGradientListComponent.cpp b/Gems/Terrain/Code/Source/Components/TerrainHeightGradientListComponent.cpp index 108ae70632..b9055375d4 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainHeightGradientListComponent.cpp +++ b/Gems/Terrain/Code/Source/Components/TerrainHeightGradientListComponent.cpp @@ -160,7 +160,7 @@ namespace Terrain { float maxSample = 0.0f; terrainExists = false; - AZ_WarningOnce("Terrain", !m_isRequestInProgress, "Detected cyclic dependences with terrain height entity references"); + AZ_WarningOnce("Terrain", !m_isRequestInProgress, "Detected cyclic dependencies with terrain height entity references"); if (!m_isRequestInProgress) { m_isRequestInProgress = true; diff --git a/Gems/Terrain/Code/Source/Components/TerrainPhysicsColliderComponent.cpp b/Gems/Terrain/Code/Source/Components/TerrainPhysicsColliderComponent.cpp index 1299403659..c51728a5c3 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainPhysicsColliderComponent.cpp +++ b/Gems/Terrain/Code/Source/Components/TerrainPhysicsColliderComponent.cpp @@ -17,6 +17,7 @@ #include #include +#include #include namespace Terrain @@ -43,11 +44,25 @@ namespace Terrain AZ::Edit::UIHandlers::ComboBox, &TerrainPhysicsSurfaceMaterialMapping::m_surfaceTag, "Surface Tag", "Surface type to map to a physics material.") ->DataElement(AZ::Edit::UIHandlers::Default, &TerrainPhysicsSurfaceMaterialMapping::m_materialId, "Material ID", "") + ->ElementAttribute(Physics::Attributes::MaterialLibraryAssetId, &TerrainPhysicsSurfaceMaterialMapping::GetMaterialLibraryId) ->Attribute(AZ::Edit::Attributes::AutoExpand, true) ->Attribute(AZ::Edit::Attributes::ShowProductAssetFileName, true); } } } + + AZ::Data::AssetId TerrainPhysicsSurfaceMaterialMapping::GetMaterialLibraryId() + { + if (const auto* physicsSystem = AZ::Interface::Get()) + { + if (const auto* physicsConfiguration = physicsSystem->GetConfiguration()) + { + return physicsConfiguration->m_materialLibraryAsset.GetId(); + } + } + return {}; + } + void TerrainPhysicsColliderConfig::Reflect(AZ::ReflectContext* context) { TerrainPhysicsSurfaceMaterialMapping::Reflect(context); @@ -255,6 +270,8 @@ namespace Terrain void TerrainPhysicsColliderComponent::GenerateHeightsInBounds(AZStd::vector& heights) const { + AZ_PROFILE_FUNCTION(Entity); + const AZ::Vector2 gridResolution = GetHeightfieldGridSpacing(); AZ::Aabb worldSize = GetHeightfieldAabb(); @@ -315,6 +332,8 @@ namespace Terrain void TerrainPhysicsColliderComponent::GenerateHeightsAndMaterialsInBounds( AZStd::vector& heightMaterials) const { + AZ_PROFILE_FUNCTION(Entity); + const AZ::Vector2 gridResolution = GetHeightfieldGridSpacing(); AZ::Aabb worldSize = GetHeightfieldAabb(); diff --git a/Gems/Terrain/Code/Source/Components/TerrainPhysicsColliderComponent.h b/Gems/Terrain/Code/Source/Components/TerrainPhysicsColliderComponent.h index 1a7fbf9c72..8a70f282d0 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainPhysicsColliderComponent.h +++ b/Gems/Terrain/Code/Source/Components/TerrainPhysicsColliderComponent.h @@ -36,6 +36,9 @@ namespace Terrain SurfaceData::SurfaceTag m_surfaceTag; Physics::MaterialId m_materialId; + + private: + static AZ::Data::AssetId GetMaterialLibraryId(); }; class TerrainPhysicsColliderConfig diff --git a/Gems/Terrain/Code/Source/Components/TerrainSurfaceDataSystemComponent.cpp b/Gems/Terrain/Code/Source/Components/TerrainSurfaceDataSystemComponent.cpp index 65e8600d62..dbaae0118a 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainSurfaceDataSystemComponent.cpp +++ b/Gems/Terrain/Code/Source/Components/TerrainSurfaceDataSystemComponent.cpp @@ -7,6 +7,7 @@ */ #include +#include #include #include #include @@ -14,6 +15,7 @@ #include #include #include +#include namespace Terrain { @@ -96,6 +98,7 @@ namespace Terrain { m_providerHandle = SurfaceData::InvalidSurfaceDataRegistryHandle; AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusConnect(); + SurfaceData::SurfaceDataTagProviderRequestBus::Handler::BusConnect(); UpdateTerrainData(AZ::Aabb::CreateNull()); } @@ -110,6 +113,7 @@ namespace Terrain } SurfaceData::SurfaceDataProviderRequestBus::Handler::BusDisconnect(); + SurfaceData::SurfaceDataTagProviderRequestBus::Handler::BusDisconnect(); AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusDisconnect(); // Clear the cached terrain bounds data @@ -162,8 +166,7 @@ namespace Terrain point.m_normal = terrainSurfacePoint.m_normal; // Always add a "terrain" or "terrainHole" tag. - const AZ::Crc32 terrainTag = - isHole ? SurfaceData::Constants::s_terrainHoleTagCrc : SurfaceData::Constants::s_terrainTagCrc; + const AZ::Crc32 terrainTag = isHole ? Constants::s_terrainHoleTagCrc : Constants::s_terrainTagCrc; SurfaceData::AddMaxValueForMasks(point.m_masks, terrainTag, 1.0f); // Add all of the surface tags that the terrain has at this point. @@ -189,8 +192,8 @@ namespace Terrain SurfaceData::SurfaceTagVector TerrainSurfaceDataSystemComponent::GetSurfaceTags() const { SurfaceData::SurfaceTagVector tags; - tags.push_back(SurfaceData::Constants::s_terrainHoleTagCrc); - tags.push_back(SurfaceData::Constants::s_terrainTagCrc); + tags.push_back(Constants::s_terrainHoleTagCrc); + tags.push_back(Constants::s_terrainTagCrc); return tags; } @@ -248,7 +251,6 @@ namespace Terrain SurfaceData::SurfaceDataSystemRequestBus::Broadcast( &SurfaceData::SurfaceDataSystemRequestBus::Events::UnregisterSurfaceDataProvider, m_providerHandle); m_providerHandle = SurfaceData::InvalidSurfaceDataRegistryHandle; - SurfaceData::SurfaceDataProviderRequestBus::Handler::BusDisconnect(); } else @@ -263,4 +265,10 @@ namespace Terrain { UpdateTerrainData(dirtyRegion); } + + void TerrainSurfaceDataSystemComponent::GetRegisteredSurfaceTagNames(SurfaceData::SurfaceTagNameSet& names) const + { + names.insert(Constants::s_terrainHoleTagName); + names.insert(Constants::s_terrainTagName); + } } diff --git a/Gems/Terrain/Code/Source/Components/TerrainSurfaceDataSystemComponent.h b/Gems/Terrain/Code/Source/Components/TerrainSurfaceDataSystemComponent.h index d9c7893c77..4d9a5b7481 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainSurfaceDataSystemComponent.h +++ b/Gems/Terrain/Code/Source/Components/TerrainSurfaceDataSystemComponent.h @@ -13,6 +13,7 @@ #include #include #include +#include namespace Terrain { @@ -32,6 +33,7 @@ namespace Terrain : public AZ::Component , private SurfaceData::SurfaceDataProviderRequestBus::Handler , private AzFramework::Terrain::TerrainDataNotificationBus::Handler + , private SurfaceData::SurfaceDataTagProviderRequestBus::Handler { friend class EditorTerrainSurfaceDataSystemComponent; TerrainSurfaceDataSystemComponent(const TerrainSurfaceDataSystemConfig&); @@ -72,5 +74,9 @@ namespace Terrain AZ::Aabb m_terrainBounds = AZ::Aabb::CreateNull(); AZStd::atomic_bool m_terrainBoundsIsValid{ false }; + + ////////////////////////////////////////////////////////////////////////// + // SurfaceData::SurfaceDataTagProviderRequestBus + void GetRegisteredSurfaceTagNames(SurfaceData::SurfaceTagNameSet& names) const override; }; } diff --git a/Gems/Terrain/Code/Source/Components/TerrainSurfaceGradientListComponent.h b/Gems/Terrain/Code/Source/Components/TerrainSurfaceGradientListComponent.h index 20851c127f..8a3c097b6c 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainSurfaceGradientListComponent.h +++ b/Gems/Terrain/Code/Source/Components/TerrainSurfaceGradientListComponent.h @@ -32,6 +32,13 @@ namespace Terrain AZ_RTTI(TerrainSurfaceGradientMapping, "{473AD2CE-F22A-45A9-803F-2192F3D9F2BF}"); static void Reflect(AZ::ReflectContext* context); + TerrainSurfaceGradientMapping() = default; + TerrainSurfaceGradientMapping(const AZ::EntityId& entityId, const SurfaceData::SurfaceTag& surfaceTag) + : m_gradientEntityId(entityId) + , m_surfaceTag(surfaceTag) + { + } + AZ::EntityId m_gradientEntityId; SurfaceData::SurfaceTag m_surfaceTag; }; diff --git a/Gems/Terrain/Code/Source/Components/TerrainWorldComponent.cpp b/Gems/Terrain/Code/Source/Components/TerrainWorldComponent.cpp index 8d6bf8e4b0..8b612b86ce 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainWorldComponent.cpp +++ b/Gems/Terrain/Code/Source/Components/TerrainWorldComponent.cpp @@ -139,8 +139,8 @@ namespace Terrain AZ::Outcome TerrainWorldConfig::DetermineMessage(float numSamples) { - const float maximumSamplesAllowed = 8.0f * 1024.0f * 1024.0f; - if (numSamples < maximumSamplesAllowed) + const float maximumSamplesAllowed = 16.0f * 1024.0f * 1024.0f; + if (numSamples <= maximumSamplesAllowed) { return AZ::Success(); } diff --git a/Gems/Terrain/Code/Source/Components/TerrainWorldDebuggerComponent.cpp b/Gems/Terrain/Code/Source/Components/TerrainWorldDebuggerComponent.cpp index 79fd5509f2..f3e0d59537 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainWorldDebuggerComponent.cpp +++ b/Gems/Terrain/Code/Source/Components/TerrainWorldDebuggerComponent.cpp @@ -90,13 +90,28 @@ namespace Terrain void TerrainWorldDebuggerComponent::Activate() { - m_wireframeBounds = AZ::Aabb::CreateNull(); + // Given the AuxGeom vertex limits, MaxSectorsToDraw is the max number of wireframe sectors we can draw without exceeding the + // limits. Since we want an N x N sector grid, take the square root to get the number of sectors in each direction. + m_sectorGridSize = aznumeric_cast(sqrtf(MaxSectorsToDraw)); + + // We're always going to keep the camera in the center square, so "round" downwards to an odd number of sectors if we currently + // have an even number. (If we added a sector, we'll go above the max sectors that we can draw with our vertex limits) + m_sectorGridSize = (m_sectorGridSize & 0x01) ? m_sectorGridSize : m_sectorGridSize - 1; + + // Create our fixed set of sectors that we'll draw. By default, they'll all be constructed as dirty, so they'll get refreshed + // the first time we try to draw them. (If wireframe drawing is disabled, we'll never refresh them) + m_wireframeSectors.clear(); + m_wireframeSectors.resize(m_sectorGridSize * m_sectorGridSize); AzFramework::EntityDebugDisplayEventBus::Handler::BusConnect(GetEntityId()); AzFramework::BoundsRequestBus::Handler::BusConnect(GetEntityId()); AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusConnect(); - RefreshCachedWireframeGrid(AZ::Aabb::CreateNull()); + // Any time the world bounds potentially changes, notify that the terrain debugger's visibility bounds also changed. + // Otherwise, DisplayEntityViewport() won't get called at the appropriate times, since the visibility could get incorrectly + // culled out. + AzFramework::IEntityBoundsUnionRequestBus::Broadcast( + &AzFramework::IEntityBoundsUnionRequestBus::Events::RefreshEntityLocalBoundsUnion, GetEntityId()); } void TerrainWorldDebuggerComponent::Deactivate() @@ -105,7 +120,6 @@ namespace Terrain AzFramework::BoundsRequestBus::Handler::BusDisconnect(); AzFramework::EntityDebugDisplayEventBus::Handler::BusDisconnect(); - m_wireframeBounds = AZ::Aabb::CreateNull(); m_wireframeSectors.clear(); } @@ -144,169 +158,238 @@ namespace Terrain return GetWorldBounds(); } - void TerrainWorldDebuggerComponent::DisplayEntityViewport( - const AzFramework::ViewportInfo& viewportInfo, AzFramework::DebugDisplayRequests& debugDisplay) + void TerrainWorldDebuggerComponent::MarkDirtySectors(const AZ::Aabb& dirtyRegion) { - // Draw a wireframe box around the entire terrain world bounds - if (m_configuration.m_drawWorldBounds) + // Create a 2D version of dirtyRegion that has Z set to min/max float values, so that we can just check for XY overlap with + // each sector. + const AZ::Aabb dirtyRegion2D = AZ::Aabb::CreateFromMinMaxValues( + dirtyRegion.GetMin().GetX(), dirtyRegion.GetMin().GetY(), AZStd::numeric_limits::lowest(), + dirtyRegion.GetMax().GetX(), dirtyRegion.GetMax().GetY(), AZStd::numeric_limits::max()); + + // For each sector that overlaps the dirty region (or all of them if the region is invalid), mark them as dirty so that + // they'll get refreshed the next time we need to draw them. + for (auto& sector : m_wireframeSectors) { - AZ::Color outlineColor(1.0f, 0.0f, 0.0f, 1.0f); - AZ::Aabb aabb = GetWorldBounds(); + if (!dirtyRegion2D.IsValid() || dirtyRegion2D.Overlaps(sector.m_aabb)) + { + sector.m_isDirty = true; + } + } + } - debugDisplay.SetColor(outlineColor); - debugDisplay.DrawWireBox(aabb.GetMin(), aabb.GetMax()); + void TerrainWorldDebuggerComponent::DrawWorldBounds(AzFramework::DebugDisplayRequests& debugDisplay) + { + if (!m_configuration.m_drawWorldBounds) + { + return; } - // Draw a wireframe representation of the terrain surface - if (m_configuration.m_drawWireframe && !m_wireframeSectors.empty()) + // Draw a wireframe box around the entire terrain world bounds + AZ::Color outlineColor(1.0f, 0.0f, 0.0f, 1.0f); + AZ::Aabb aabb = GetWorldBounds(); + + debugDisplay.SetColor(outlineColor); + debugDisplay.DrawWireBox(aabb.GetMin(), aabb.GetMax()); + } + + void TerrainWorldDebuggerComponent::DrawWireframe( + const AzFramework::ViewportInfo& viewportInfo, AzFramework::DebugDisplayRequests& debugDisplay) + { + AZ_PROFILE_FUNCTION(Entity); + + if (!m_configuration.m_drawWireframe) { - // Start by assuming we'll draw the entire world. - AZ::Aabb drawingAabb = GetWorldBounds(); + return; + } - // Assuming we can get the camera, reduce the drawing bounds to a fixed distance around the camera. - if (auto viewportContextRequests = AZ::RPI::ViewportContextRequests::Get(); viewportContextRequests) - { - // Get the current camera position. - AZ::RPI::ViewportContextPtr viewportContext = viewportContextRequests->GetViewportContextById(viewportInfo.m_viewportId); - AZ::Vector3 cameraPos = viewportContext->GetCameraTransform().GetTranslation(); + /* This draws a wireframe centered on the camera that extends out to a certain distance at all times. To reduce the amount of + * recalculations we need to do on each camera movement, we divide the world into a conceptual grid of sectors, where each sector + * contains a fixed number of terrain height points. So for example, if the terrain has height data at 1 m spacing, the sectors + * might be 10 m x 10 m in size. If the height data is spaced at 0.5 m, the sectors might be 5 m x 5 m in size. The wireframe + * draws N x N sectors centered around the camera, as determined by m_sectorGridSize. So a gridSize of 7 with a sector size of + * 10 m means that we'll be drawing 7 x 7 sectors, or 70 m x 70 m, centered around the camera. Each time the camera moves into + * a new sector, we refresh the changed sectors before drawing them. + * + * The only tricky bit to this design is the way the sectors are stored and indexed. They're stored in a single vector as NxN + * entries, so they would normally be indexed as (y * N) + x. Since we want this to be centered on the camera, the easy answer + * would be to take the camera position - (N / 2) (since we're centering) as the relative offset to the first entry. But this + * would mean that the entire set of entries would change every time we move the camera. For example, if we had 5 entries, + * they might map to 0-4, 1-5, 2-6, 3-7, etc as the camera moves. + * + * Instead, we use mod (%) to rotate our indices around, so it would go (0 1 2 3 4), (5 1 2 3 4), (5 6 2 3 4), (5 6 7 3 4), etc + * as the camera moves. For negative entries, we rotate the indices in reverse, so that we get results like (0 1 2 3 4), + * (0 1 2 3 -1), (0 1 2 -2 -1), (0 1 -3 -2 -1), etc. This way we always have the correct range of sectors, and sectors that have + * remained visible are left alone and don't need to be updated again. + */ + + // Get the terrain world bounds + AZ::Aabb worldBounds = GetWorldBounds(); + float worldMinZ = worldBounds.GetMin().GetZ(); - // Determine how far to draw in each direction in world space based on our MaxSectorsToDraw - AZ::Vector2 queryResolution = AZ::Vector2(1.0f); - AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( - queryResolution, &AzFramework::Terrain::TerrainDataRequests::GetTerrainHeightQueryResolution); - AZ::Vector3 viewDistance( - queryResolution.GetX() * SectorSizeInGridPoints * sqrtf(MaxSectorsToDraw), - queryResolution.GetY() * SectorSizeInGridPoints * sqrtf(MaxSectorsToDraw), - 0.0f); - - // Create an AABB around the camera based on how far we want to be able to draw in each direction and clamp the - // drawing AABB to it. - AZ::Aabb cameraAabb = AZ::Aabb::CreateFromMinMax( - AZ::Vector3( - cameraPos.GetX() - viewDistance.GetX(), cameraPos.GetY() - viewDistance.GetY(), drawingAabb.GetMin().GetZ()), - AZ::Vector3( - cameraPos.GetX() + viewDistance.GetX(), cameraPos.GetY() + viewDistance.GetY(), drawingAabb.GetMin().GetZ())); - drawingAabb.Clamp(cameraAabb); - } + // Get the terrain height data resolution + AZ::Vector2 heightDataResolution = AZ::Vector2(1.0f); + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + heightDataResolution, &AzFramework::Terrain::TerrainDataRequests::GetTerrainHeightQueryResolution); + + // Get the size of a wireframe sector in world space + const AZ::Vector2 sectorSize = heightDataResolution * SectorSizeInGridPoints; + + // Try to get the current camera position, or default to (0,0) if we can't. + AZ::Vector3 cameraPos = AZ::Vector3::CreateZero(); + if (auto viewportContextRequests = AZ::RPI::ViewportContextRequests::Get(); viewportContextRequests) + { + AZ::RPI::ViewportContextPtr viewportContext = viewportContextRequests->GetViewportContextById(viewportInfo.m_viewportId); + cameraPos = viewportContext->GetCameraTransform().GetTranslation(); + } - // For each sector, if it appears within our view distance, draw it. - for (auto& sector : m_wireframeSectors) + // Convert our camera position to a wireframe grid sector. We first convert from world space to sector space by dividing by + // sectorSize, so that integer values are sectors, and fractional values are the distance within the sector. Then we get the + // floor, so that we consistently get the next lowest integer - i.e. 2.3 -> 2, and -2.3 -> -3. This gives us consistent behavior + // across both positive and negative positions. + AZ::Vector2 gridPosition = AZ::Vector2(cameraPos.GetX(), cameraPos.GetY()) / sectorSize; + int32_t cameraSectorX = aznumeric_cast(gridPosition.GetFloor().GetX()); + int32_t cameraSectorY = aznumeric_cast(gridPosition.GetFloor().GetY()); + + // Loop through each sector that we *want* to draw, based on camera position. If the current sector at that index in + // m_wireframeSectors doesn't match the world position we want, update its world position and mark it as dirty. + // (We loop from -gridSize/2 to gridSize/2 so that the camera is always in the center sector.) + for (int32_t sectorY = cameraSectorY - (m_sectorGridSize / 2); sectorY <= cameraSectorY + (m_sectorGridSize / 2); sectorY++) + { + for (int32_t sectorX = cameraSectorX - (m_sectorGridSize / 2); sectorX <= cameraSectorX + (m_sectorGridSize / 2); sectorX++) { - if (drawingAabb.Overlaps(sector.m_aabb)) + + // Calculate the index in m_wireframeSectors for this sector. Our indices should rotate through 0 - gridSize, but just + // using a single mod will produce a negative result for negative sector indices. Using abs() will give us incorrect + // "backwards" indices for negative numbers, so instead we add the grid size and mod a second time. + // Ex: For a grid size of 5, we want the indices to map like this: + // Index 0 1 2 3 4 + // Values -10 -9 -8 -7 -6 + // -5 -4 -3 -2 -1 + // 0 1 2 3 4 + // 5 6 7 8 9 + // For -9, (-9 % 5) = -4, then (-4 + 5) % 5 = 1. If we used abs(), we'd get 4, which is backwards from what we want. + int32_t sectorYIndex = ((sectorY % m_sectorGridSize) + m_sectorGridSize) % m_sectorGridSize; + int32_t sectorXIndex = ((sectorX % m_sectorGridSize) + m_sectorGridSize) % m_sectorGridSize; + int32_t sectorIndex = (sectorYIndex * m_sectorGridSize) + sectorXIndex; + + WireframeSector& sector = m_wireframeSectors[sectorIndex]; + + // Calculate the new world space box for this sector. + AZ::Aabb sectorAabb = AZ::Aabb::CreateFromMinMax( + AZ::Vector3(sectorX * sectorSize.GetX(), sectorY * sectorSize.GetY(), worldMinZ), + AZ::Vector3((sectorX + 1) * sectorSize.GetX(), (sectorY + 1) * sectorSize.GetY(), worldMinZ)); + + // Clamp it to the terrain world bounds. + sectorAabb.Clamp(worldBounds); + + // If the world space box for the sector doesn't match, set it and mark the sector as dirty so we refresh the height data. + if (sector.m_aabb != sectorAabb) { - if (!sector.m_lineVertices.empty()) - { - const AZ::Color primaryColor = AZ::Color(0.25f, 0.25f, 0.25f, 1.0f); - debugDisplay.DrawLines(sector.m_lineVertices, primaryColor); - } - else - { - AZ_Warning("Debug", false, "empty sector!"); - } + sector.m_aabb = sectorAabb; + sector.m_isDirty = true; } } } + + // Finally, for each sector, rebuild the data if it's dirty, then draw it assuming it has valid data. + // (Sectors that are outside the world bounds won't have any valid data, so they'll get skipped) + for (auto& sector : m_wireframeSectors) + { + if (sector.m_isDirty) + { + RebuildSectorWireframe(sector, heightDataResolution, worldMinZ); + } + + if (!sector.m_lineVertices.empty()) + { + const AZ::Color primaryColor = AZ::Color(0.25f, 0.25f, 0.25f, 1.0f); + debugDisplay.DrawLines(sector.m_lineVertices, primaryColor); + } + } } - void TerrainWorldDebuggerComponent::RefreshCachedWireframeGrid(const AZ::Aabb& dirtyRegion) + + void TerrainWorldDebuggerComponent::DisplayEntityViewport( + const AzFramework::ViewportInfo& viewportInfo, AzFramework::DebugDisplayRequests& debugDisplay) { - // Get the terrain world bounds and grid resolution. + DrawWorldBounds(debugDisplay); + DrawWireframe(viewportInfo, debugDisplay); - AZ::Aabb worldBounds = GetWorldBounds(); + } - AZ::Vector2 queryResolution = AZ::Vector2(1.0f); - AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( - queryResolution, &AzFramework::Terrain::TerrainDataRequests::GetTerrainHeightQueryResolution); - - // Take the dirty region and adjust the Z values to the world min/max so that even if the dirty region falls outside the current - // world bounds, we still update the wireframe accordingly. - AZ::Aabb dirtyRegion2D = AZ::Aabb::CreateFromMinMaxValues( - dirtyRegion.GetMin().GetX(), dirtyRegion.GetMin().GetY(), worldBounds.GetMin().GetZ(), - dirtyRegion.GetMax().GetX(), dirtyRegion.GetMax().GetY(), worldBounds.GetMax().GetZ()); - - // Calculate the world size of each sector. Note that this size actually ends at the last point, not the last square. - // So for example, the sector size for 3 points will go from (*--*--*) even though it will be used to draw (*--*--*--). - const float xSectorSize = (queryResolution.GetX() * SectorSizeInGridPoints); - const float ySectorSize = (queryResolution.GetY() * SectorSizeInGridPoints); - - // Calculate the total number of sectors to cache. The world bounds might not be evenly divisible by sector bounds, so we add - // an extra sector's worth of size in each direction so that clamping down to an integer still accounts for that fractional sector. - const int32_t numSectorsX = aznumeric_cast((worldBounds.GetXExtent() + xSectorSize) / xSectorSize); - const int32_t numSectorsY = aznumeric_cast((worldBounds.GetYExtent() + ySectorSize) / ySectorSize); - - // If we haven't cached anything before, or if the world bounds has changed, clear our cache structure and repopulate it - // with WireframeSector entries with the proper AABB sizes. - if (!m_wireframeBounds.IsValid() || !dirtyRegion2D.IsValid() || !m_wireframeBounds.IsClose(worldBounds)) + void TerrainWorldDebuggerComponent::RebuildSectorWireframe(WireframeSector& sector, const AZ::Vector2& gridResolution, float worldMinZ) + { + if (!sector.m_isDirty) { - m_wireframeBounds = worldBounds; + return; + } - m_wireframeSectors.clear(); - m_wireframeSectors.reserve(numSectorsX * numSectorsY); + sector.m_isDirty = false; - for (int32_t ySector = 0; ySector < numSectorsY; ySector++) - { - for (int32_t xSector = 0; xSector < numSectorsX; xSector++) - { - // For each sector, set up the AABB for the sector and reserve memory for the line vertices. - WireframeSector sector; - sector.m_lineVertices.reserve(VerticesPerSector); - sector.m_aabb = AZ::Aabb::CreateFromMinMax( - AZ::Vector3( - worldBounds.GetMin().GetX() + (xSector * xSectorSize), worldBounds.GetMin().GetY() + (ySector * ySectorSize), - worldBounds.GetMin().GetZ()), - AZ::Vector3( - worldBounds.GetMin().GetX() + ((xSector + 1) * xSectorSize), - worldBounds.GetMin().GetY() + ((ySector + 1) * ySectorSize), worldBounds.GetMax().GetZ())); - - sector.m_aabb.Clamp(worldBounds); - - m_wireframeSectors.push_back(AZStd::move(sector)); - } - } + // To rebuild the wireframe, we walk through the sector by X, then by Y. For each point, we add two lines in a _| shape. + // To do that, we'll need to cache the height from the previous point to draw the _ line, and from the previous row to draw + // the | line. - // Notify the visibility system that our bounds have changed. - AzFramework::IEntityBoundsUnionRequestBus::Broadcast( - &AzFramework::IEntityBoundsUnionRequestBus::Events::RefreshEntityLocalBoundsUnion, GetEntityId()); - } + // When walking through the bounding box, the loops will be inclusive on one side, and exclusive on the other. However, since + // our box is exactly aligned with grid points, we want to get the grid points on both sides in each direction, so we need to + // expand our query region by one extra point. + // For example, if our AABB is 2 m and our grid resolution is 1 m, we'll want to query (*--*--*--), not (*--*--). + // Since we're processing lines based on the grid points and going backwards, this will give us (*--*--*). - // For each sector, if it overlaps with the dirty region, clear it out and recache the wireframe line data. - for (auto& sector : m_wireframeSectors) + AZ::Aabb region = sector.m_aabb; + region.SetMax(region.GetMax() + AZ::Vector3(gridResolution.GetX(), gridResolution.GetY(), 0.0f)); + + // We need 4 vertices for each grid point in our sector to hold the _| shape. + const size_t numSamplesX = aznumeric_cast(ceil(region.GetExtents().GetX() / gridResolution.GetX())); + const size_t numSamplesY = aznumeric_cast(ceil(region.GetExtents().GetY() / gridResolution.GetY())); + sector.m_lineVertices.clear(); + sector.m_lineVertices.reserve(numSamplesX * numSamplesY * 4); + + // This keeps track of the height from the previous point for the _ line. + float previousHeight = 0.0f; + + // This keeps track of the heights from the previous row for the | line. + AZStd::vector rowHeights(numSamplesX); + + // For each terrain height value in the region, create the _| grid lines for that point and cache off the height value + // for use with subsequent grid line calculations. + auto ProcessHeightValue = [gridResolution, &previousHeight, &rowHeights, §or] + (uint32_t xIndex, uint32_t yIndex, const AZ::Vector3& position, [[maybe_unused]] bool terrainExists) { - if (dirtyRegion2D.IsValid() && !dirtyRegion2D.Overlaps(sector.m_aabb)) + // Don't add any vertices for the first column or first row. These grid lines will be handled by an adjacent sector, if + // there is one. + if ((xIndex > 0) && (yIndex > 0)) { - continue; + float x = position.GetX() - gridResolution.GetX(); + float y = position.GetY() - gridResolution.GetY(); + + sector.m_lineVertices.emplace_back(AZ::Vector3(x, position.GetY(), previousHeight)); + sector.m_lineVertices.emplace_back(position); + + sector.m_lineVertices.emplace_back(AZ::Vector3(position.GetX(), y, rowHeights[xIndex])); + sector.m_lineVertices.emplace_back(position); } - sector.m_lineVertices.clear(); + // Save off the heights so that we can use them to draw subsequent columns and rows. + previousHeight = position.GetZ(); + rowHeights[xIndex] = position.GetZ(); + }; - for (float y = sector.m_aabb.GetMin().GetY(); y < sector.m_aabb.GetMax().GetY(); y += queryResolution.GetY()) + // This set of nested loops will get replaced with a call to ProcessHeightsFromRegion once the API exists. + for (size_t yIndex = 0; yIndex < numSamplesY; yIndex++) + { + float y = region.GetMin().GetY() + (gridResolution.GetY() * yIndex); + for (size_t xIndex = 0; xIndex < numSamplesX; xIndex++) { - for (float x = sector.m_aabb.GetMin().GetX(); x < sector.m_aabb.GetMax().GetX(); x += queryResolution.GetX()) - { - float x1 = x + queryResolution.GetX(); - float y1 = y + queryResolution.GetY(); - - float z00 = 0.0f; - float z01 = 0.0f; - float z10 = 0.0f; - bool terrainExists; - - AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( - z00, &AzFramework::Terrain::TerrainDataRequests::GetHeightFromFloats, x, y, - AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT, &terrainExists); - AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( - z01, &AzFramework::Terrain::TerrainDataRequests::GetHeightFromFloats, x, y1, - AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT, &terrainExists); - AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( - z10, &AzFramework::Terrain::TerrainDataRequests::GetHeightFromFloats, x1, y, - AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT, &terrainExists); - - sector.m_lineVertices.push_back(AZ::Vector3(x, y, z00)); - sector.m_lineVertices.push_back(AZ::Vector3(x1, y, z10)); - - sector.m_lineVertices.push_back(AZ::Vector3(x, y, z00)); - sector.m_lineVertices.push_back(AZ::Vector3(x, y1, z01)); - } + float x = region.GetMin().GetX() + (gridResolution.GetX() * xIndex); + + float height = worldMinZ; + bool terrainExists = false; + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + height, &AzFramework::Terrain::TerrainDataRequests::GetHeightFromFloats, x, y, + AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT, &terrainExists); + ProcessHeightValue( + aznumeric_cast(xIndex), aznumeric_cast(yIndex), AZ::Vector3(x, y, height), terrainExists); } } } @@ -315,7 +398,14 @@ namespace Terrain { if (dataChangedMask & (TerrainDataChangedMask::Settings | TerrainDataChangedMask::HeightData)) { - RefreshCachedWireframeGrid(dirtyRegion); + MarkDirtySectors(dirtyRegion); + } + + if (dataChangedMask & TerrainDataChangedMask::Settings) + { + // Any time the world bounds potentially changes, notify that the terrain debugger's visibility bounds also changed. + AzFramework::IEntityBoundsUnionRequestBus::Broadcast( + &AzFramework::IEntityBoundsUnionRequestBus::Events::RefreshEntityLocalBoundsUnion, GetEntityId()); } } diff --git a/Gems/Terrain/Code/Source/Components/TerrainWorldDebuggerComponent.h b/Gems/Terrain/Code/Source/Components/TerrainWorldDebuggerComponent.h index 5ec831c038..f3bcead8c3 100644 --- a/Gems/Terrain/Code/Source/Components/TerrainWorldDebuggerComponent.h +++ b/Gems/Terrain/Code/Source/Components/TerrainWorldDebuggerComponent.h @@ -82,33 +82,40 @@ namespace Terrain private: + TerrainWorldDebuggerConfig m_configuration; + // Cache our debug wireframe representation in "sectors" of data so that we can easily control how far out we draw // the wireframe representation in each direction. struct WireframeSector { - AZ::Aabb m_aabb; + AZ::Aabb m_aabb{ AZ::Aabb::CreateNull() }; AZStd::vector m_lineVertices; + bool m_isDirty{ true }; }; + void RebuildSectorWireframe(WireframeSector& sector, const AZ::Vector2& gridResolution, float worldMinZ); + void MarkDirtySectors(const AZ::Aabb& dirtyRegion); + void DrawWorldBounds(AzFramework::DebugDisplayRequests& debugDisplay); + void DrawWireframe(const AzFramework::ViewportInfo& viewportInfo, AzFramework::DebugDisplayRequests& debugDisplay); + // Each sector contains an N x N grid of squares that it will draw. Since this is a count of the number of terrain grid points // in each direction, the actual world size will depend on the terrain grid resolution in each direction. static constexpr int32_t SectorSizeInGridPoints = 10; - // For each grid point we will draw half a square (left-right, top-down), so we need 4 vertices for the two lines. + // For each grid point we will draw half a square ( _| ), so we need 4 vertices for the two lines. static constexpr int32_t VerticesPerGridPoint = 4; - // Pre-calculate the total number of vertices per sector. - static constexpr int32_t VerticesPerSector = - (SectorSizeInGridPoints * VerticesPerGridPoint) * (SectorSizeInGridPoints * VerticesPerGridPoint); + // Pre-calculate the total number of vertices per sector (N x N grid points, with 4 vertices per grid point) + static constexpr int32_t VerticesPerSector = (SectorSizeInGridPoints * SectorSizeInGridPoints) * VerticesPerGridPoint; // AuxGeom has limits to the number of lines it can draw in a frame, so we'll cap how many total sectors to draw. static constexpr int32_t MaxVerticesToDraw = 500000; static constexpr int32_t MaxSectorsToDraw = MaxVerticesToDraw / VerticesPerSector; - void RefreshCachedWireframeGrid(const AZ::Aabb& dirtyRegion); - - TerrainWorldDebuggerConfig m_configuration; + // Structure to keep track of all our current wireframe sectors, so that we don't have to recalculate them every frame. AZStd::vector m_wireframeSectors; - AZ::Aabb m_wireframeBounds; + + // The size in sectors of our wireframe grid in each direction (i.e. a 5 x 5 sector grid has a sectorGridSize of 5) + int32_t m_sectorGridSize{ 0 }; }; } diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/Aabb2i.cpp b/Gems/Terrain/Code/Source/TerrainRenderer/Aabb2i.cpp new file mode 100644 index 0000000000..c38651f296 --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/Aabb2i.cpp @@ -0,0 +1,44 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include + +namespace Terrain +{ + Aabb2i::Aabb2i(const Vector2i& min, const Vector2i& max) + : m_min(min) + , m_max(max) + {} + + Aabb2i Aabb2i::operator+(const Vector2i& rhs) const + { + return { m_min + rhs, m_max + rhs }; + } + + Aabb2i Aabb2i::operator-(const Vector2i& rhs) const + { + return *this + -rhs; + } + + Aabb2i Aabb2i::GetClamped(Aabb2i rhs) const + { + Aabb2i ret; + ret.m_min.m_x = AZ::GetMax(m_min.m_x, rhs.m_min.m_x); + ret.m_min.m_y = AZ::GetMax(m_min.m_y, rhs.m_min.m_y); + ret.m_max.m_x = AZ::GetMin(m_max.m_x, rhs.m_max.m_x); + ret.m_max.m_y = AZ::GetMin(m_max.m_y, rhs.m_max.m_y); + return ret; + } + + bool Aabb2i::IsValid() const + { + // Intentionally strict, equal min/max not valid. + return m_min.m_x < m_max.m_x && m_min.m_y < m_max.m_y; + } +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/Aabb2i.h b/Gems/Terrain/Code/Source/TerrainRenderer/Aabb2i.h new file mode 100644 index 0000000000..88f735564d --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/Aabb2i.h @@ -0,0 +1,34 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include + +namespace Terrain +{ + class Aabb2i + { + public: + + Aabb2i() = default; + Aabb2i(const Vector2i& min, const Vector2i& max); + + Aabb2i operator+(const Vector2i& offset) const; + Aabb2i operator-(const Vector2i& offset) const; + + Aabb2i GetClamped(Aabb2i rhs) const; + bool IsValid() const; + + + Vector2i m_min{AZStd::numeric_limits::min(), AZStd::numeric_limits::min()}; + Vector2i m_max{AZStd::numeric_limits::max(), AZStd::numeric_limits::max()}; + + }; +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/BindlessImageArrayHandler.cpp b/Gems/Terrain/Code/Source/TerrainRenderer/BindlessImageArrayHandler.cpp new file mode 100644 index 0000000000..595877c88b --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/BindlessImageArrayHandler.cpp @@ -0,0 +1,101 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include +#include + +namespace AZ::Render +{ + namespace + { + [[maybe_unused]] const char* BindlessImageArrayHandlerName = "TerrainFeatureProcessor"; + } + + void BindlessImageArrayHandler::Initialize(AZ::Data::Instance& srg, const AZ::Name& propertyName) + { + if (!m_isInitialized) + { + m_isInitialized = UpdateSrgIndices(srg, propertyName); + } + else + { + AZ_Error(BindlessImageArrayHandlerName, false, "Already initialized."); + } + } + + void BindlessImageArrayHandler::Reset() + { + m_texturesIndex = {}; + m_isInitialized = false; + } + + bool BindlessImageArrayHandler::IsInitialized() const + { + return m_isInitialized; + } + + bool BindlessImageArrayHandler::UpdateSrgIndices(AZ::Data::Instance& srg, const AZ::Name& propertyName) + { + if (srg) + { + m_texturesIndex = srg->GetLayout()->FindShaderInputImageUnboundedArrayIndex(propertyName); + AZ_Error(BindlessImageArrayHandlerName, m_texturesIndex.IsValid(), "Failed to find srg input constant %s.", propertyName.GetCStr()); + } + else + { + AZ_Error(BindlessImageArrayHandlerName, false, "Cannot initialize using a null shader resource group."); + } + return m_texturesIndex.IsValid(); + } + + uint16_t BindlessImageArrayHandler::AppendBindlessImage(const AZ::RHI::ImageView* imageView) + { + uint16_t imageIndex = 0xFFFF; + + AZStd::unique_lock lock(m_updateMutex); + if (m_bindlessImageViewFreeList.size() > 0) + { + imageIndex = m_bindlessImageViewFreeList.back(); + m_bindlessImageViewFreeList.pop_back(); + m_bindlessImageViews.at(imageIndex) = imageView; + } + else + { + imageIndex = aznumeric_cast(m_bindlessImageViews.size()); + m_bindlessImageViews.push_back(imageView); + } + return imageIndex; + } + + void BindlessImageArrayHandler::UpdateBindlessImage(uint16_t index, const AZ::RHI::ImageView* imageView) + { + AZStd::shared_lock lock(m_updateMutex); + m_bindlessImageViews.at(index) = imageView; + } + + void BindlessImageArrayHandler::RemoveBindlessImage(uint16_t index) + { + AZStd::unique_lock lock(m_updateMutex); + m_bindlessImageViews.at(index) = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::Magenta)->GetImageView(); + m_bindlessImageViewFreeList.push_back(index); + } + + bool BindlessImageArrayHandler::UpdateSrg(AZ::Data::Instance& srg) const + { + if (!m_isInitialized) + { + AZ_Error("BindlessImageArrayHandler", false, "BindlessImageArrayHandler not initialized") + return false; + } + + AZStd::array_view imageViews(m_bindlessImageViews.data(), m_bindlessImageViews.size()); + return srg->SetImageViewUnboundedArray(m_texturesIndex, imageViews); + } + +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/BindlessImageArrayHandler.h b/Gems/Terrain/Code/Source/TerrainRenderer/BindlessImageArrayHandler.h new file mode 100644 index 0000000000..5315e8526d --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/BindlessImageArrayHandler.h @@ -0,0 +1,48 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include + +#include +#include +#include + +namespace AZ::Render +{ + class BindlessImageArrayHandler + { + public: + + static constexpr uint16_t InvalidImageIndex = 0xFFFF; + + BindlessImageArrayHandler() = default; + ~BindlessImageArrayHandler() = default; + + void Initialize(AZ::Data::Instance& srg, const AZ::Name& propertyName); + void Reset(); + bool IsInitialized() const; + bool UpdateSrgIndices(AZ::Data::Instance& srg, const AZ::Name& propertyName); + + uint16_t AppendBindlessImage(const RHI::ImageView* imageView); + void UpdateBindlessImage(uint16_t index, const RHI::ImageView* imageView); + void RemoveBindlessImage(uint16_t index); + + bool UpdateSrg(AZ::Data::Instance& srg) const; + + private: + + AZStd::vector m_bindlessImageViews; + AZStd::vector m_bindlessImageViewFreeList; + RHI::ShaderInputImageUnboundedArrayIndex m_texturesIndex; + AZStd::shared_mutex m_updateMutex; + bool m_isInitialized{ false }; + }; +} + diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainDetailMaterialManager.cpp b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainDetailMaterialManager.cpp new file mode 100644 index 0000000000..2bc9e42bff --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainDetailMaterialManager.cpp @@ -0,0 +1,912 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include +#include + +#include + +#include +#include +#include + +#include + +namespace Terrain +{ + namespace + { + [[maybe_unused]] static const char* TerrainDetailMaterialManagerName = "TerrainDetailMaterialManager"; + static const char* TerrainDetailChars = "TerrainDetail"; + } + + namespace DetailMaterialInputs + { + static const char* const BaseColorColor("baseColor.color"); + static const char* const BaseColorMap("baseColor.textureMap"); + static const char* const BaseColorUseTexture("baseColor.useTexture"); + static const char* const BaseColorFactor("baseColor.factor"); + static const char* const BaseColorBlendMode("baseColor.textureBlendMode"); + static const char* const MetallicMap("metallic.textureMap"); + static const char* const MetallicUseTexture("metallic.useTexture"); + static const char* const MetallicFactor("metallic.factor"); + static const char* const RoughnessMap("roughness.textureMap"); + static const char* const RoughnessUseTexture("roughness.useTexture"); + static const char* const RoughnessFactor("roughness.factor"); + static const char* const RoughnessLowerBound("roughness.lowerBound"); + static const char* const RoughnessUpperBound("roughness.upperBound"); + static const char* const SpecularF0Map("specularF0.textureMap"); + static const char* const SpecularF0UseTexture("specularF0.useTexture"); + static const char* const SpecularF0Factor("specularF0.factor"); + static const char* const NormalMap("normal.textureMap"); + static const char* const NormalUseTexture("normal.useTexture"); + static const char* const NormalFactor("normal.factor"); + static const char* const NormalFlipX("normal.flipX"); + static const char* const NormalFlipY("normal.flipY"); + static const char* const DiffuseOcclusionMap("occlusion.diffuseTextureMap"); + static const char* const DiffuseOcclusionUseTexture("occlusion.diffuseUseTexture"); + static const char* const DiffuseOcclusionFactor("occlusion.diffuseFactor"); + static const char* const HeightMap("parallax.textureMap"); + static const char* const HeightUseTexture("parallax.useTexture"); + static const char* const HeightFactor("parallax.factor"); + static const char* const HeightOffset("parallax.offset"); + static const char* const HeightBlendFactor("parallax.blendFactor"); + } + + namespace TerrainSrgInputs + { + static const char* const DetailMaterialIdImage("m_detailMaterialIdImage"); + static const char* const DetailMaterialData("m_detailMaterialData"); + static const char* const DetailMaterialIdImageCenter("m_detailMaterialIdImageCenter"); + static const char* const DetailHalfPixelUv("m_detailHalfPixelUv"); + static const char* const DetailAabb("m_detailAabb"); + } + + AZ_CVAR(bool, + r_terrainDebugDetailMaterials, + false, + [](const bool& value) + { + AZ::RPI::ShaderSystemInterface::Get()->SetGlobalShaderOption(AZ::Name{ "o_debugDetailMaterialIds" }, AZ::RPI::ShaderOptionValue{ value }); + }, + AZ::ConsoleFunctorFlags::Null, + "Turns on debugging for detail material ids for terrain." + ); + + AZ_CVAR(bool, + r_terrainDebugDetailImageUpdates, + false, + nullptr, + AZ::ConsoleFunctorFlags::Null, + "Turns on debugging for detail material update regions for terrain." + ); + + void TerrainDetailMaterialManager::Initialize( + const AZStd::shared_ptr& bindlessImageHandler, + AZ::Data::Instance& terrainSrg) + { + AZ_Error(TerrainDetailMaterialManagerName, bindlessImageHandler, "bindlessImageHandler must not be null."); + AZ_Error(TerrainDetailMaterialManagerName, terrainSrg, "terrainSrg must not be null."); + AZ_Error(TerrainDetailMaterialManagerName, !m_isInitialized, "Already initialized."); + + if (!bindlessImageHandler || !terrainSrg || m_isInitialized) + { + return; + } + + if (UpdateSrgIndices(terrainSrg)) + { + m_bindlessImageHandler = bindlessImageHandler; + + // Find any detail material areas that have already been created. + TerrainAreaMaterialRequestBus::EnumerateHandlers( + [&](TerrainAreaMaterialRequests* handler) + { + const AZ::Aabb& bounds = handler->GetTerrainSurfaceMaterialRegion(); + const AZStd::vector materialMappings = handler->GetSurfaceMaterialMappings(); + AZ::EntityId entityId = *(Terrain::TerrainAreaMaterialRequestBus::GetCurrentBusId()); + + DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); + materialRegion.m_region = bounds; + + for (const auto& materialMapping : materialMappings) + { + if (materialMapping.m_materialInstance) + { + OnTerrainSurfaceMaterialMappingCreated(entityId, materialMapping.m_surfaceTag, materialMapping.m_materialInstance); + } + } + return true; + } + ); + TerrainAreaMaterialNotificationBus::Handler::BusConnect(); + + AZ::Aabb worldBounds = AZ::Aabb::CreateNull(); + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + worldBounds, &AzFramework::Terrain::TerrainDataRequests::GetTerrainAabb); + + OnTerrainDataChanged(worldBounds, TerrainDataChangedMask::SurfaceData); + AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusConnect(); + + m_isInitialized = true; + } + } + + bool TerrainDetailMaterialManager::UpdateSrgIndices(AZ::Data::Instance& terrainSrg) + { + const AZ::RHI::ShaderResourceGroupLayout* terrainSrgLayout = terrainSrg->GetLayout(); + + m_detailMaterialIdPropertyIndex = terrainSrgLayout->FindShaderInputImageIndex(AZ::Name(TerrainSrgInputs::DetailMaterialIdImage)); + AZ_Error(TerrainDetailMaterialManagerName, m_detailMaterialIdPropertyIndex.IsValid(), "Failed to find terrain srg input constant %s.", TerrainSrgInputs::DetailMaterialIdImage); + + m_detailCenterPropertyIndex = terrainSrgLayout->FindShaderInputConstantIndex(AZ::Name(TerrainSrgInputs::DetailMaterialIdImageCenter)); + AZ_Error(TerrainDetailMaterialManagerName, m_detailCenterPropertyIndex.IsValid(), "Failed to find terrain srg input constant %s.", TerrainSrgInputs::DetailMaterialIdImageCenter); + + m_detailHalfPixelUvPropertyIndex = terrainSrgLayout->FindShaderInputConstantIndex(AZ::Name(TerrainSrgInputs::DetailHalfPixelUv)); + AZ_Error(TerrainDetailMaterialManagerName, m_detailHalfPixelUvPropertyIndex.IsValid(), "Failed to find terrain srg input constant %s.", TerrainSrgInputs::DetailHalfPixelUv); + + m_detailAabbPropertyIndex = terrainSrgLayout->FindShaderInputConstantIndex(AZ::Name(TerrainSrgInputs::DetailAabb)); + AZ_Error(TerrainDetailMaterialManagerName, m_detailAabbPropertyIndex.IsValid(), "Failed to find terrain srg input constant %s.", TerrainSrgInputs::DetailAabb); + + // Set up the gpu buffer for detail material data + AZ::Render::GpuBufferHandler::Descriptor desc; + desc.m_bufferName = "Detail Material Data"; + desc.m_bufferSrgName = TerrainSrgInputs::DetailMaterialData; + desc.m_elementSize = sizeof(DetailMaterialShaderData); + desc.m_srgLayout = terrainSrgLayout; + m_detailMaterialDataBuffer = AZ::Render::GpuBufferHandler(desc); + + bool IndicesValid = + m_detailMaterialIdPropertyIndex.IsValid() && + m_detailCenterPropertyIndex.IsValid() && + m_detailHalfPixelUvPropertyIndex.IsValid() && + m_detailAabbPropertyIndex.IsValid(); + + m_detailImageNeedsUpdate = true; + m_detailMaterialBufferNeedsUpdate = true; + + return IndicesValid && m_detailMaterialDataBuffer.IsValid(); + } + + void TerrainDetailMaterialManager::RemoveAllImages() + { + for (const DetailMaterialData& materialData: m_detailMaterials.GetDataVector()) + { + DetailMaterialShaderData& shaderData = m_detailMaterialShaderData.GetElement(materialData.m_detailMaterialBufferIndex); + + auto checkRemoveImage = [&](uint16_t index) + { + if (index != 0xFFFF) + { + m_bindlessImageHandler->RemoveBindlessImage(index); + } + }; + + checkRemoveImage(shaderData.m_colorImageIndex); + checkRemoveImage(shaderData.m_normalImageIndex); + checkRemoveImage(shaderData.m_roughnessImageIndex); + checkRemoveImage(shaderData.m_metalnessImageIndex); + checkRemoveImage(shaderData.m_specularF0ImageIndex); + checkRemoveImage(shaderData.m_occlusionImageIndex); + checkRemoveImage(shaderData.m_heightImageIndex); + } + } + + bool TerrainDetailMaterialManager::IsInitialized() const + { + return m_isInitialized; + } + + void TerrainDetailMaterialManager::Reset() + { + RemoveAllImages(); + m_bindlessImageHandler.reset(); + + m_detailTextureImage = {}; + m_detailMaterials.Clear(); + m_detailMaterialRegions.Clear(); + m_detailMaterialShaderData.Clear(); + m_detailMaterialDataBuffer.Release(); + + m_dirtyDetailRegion = AZ::Aabb::CreateNull(); + m_previousCameraPosition = AZ::Vector3(AZStd::numeric_limits::max(), 0.0, 0.0); + m_detailTextureBounds = {}; + m_detailTextureCenter = {}; + + m_detailMaterialBufferNeedsUpdate = false; + m_detailImageNeedsUpdate = false; + + TerrainAreaMaterialNotificationBus::Handler::BusDisconnect(); + AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusDisconnect(); + + m_isInitialized = false; + } + + void TerrainDetailMaterialManager::Update(const AZ::Vector3& cameraPosition, AZ::Data::Instance& terrainSrg) + { + if (m_detailMaterialBufferNeedsUpdate) + { + m_detailMaterialBufferNeedsUpdate = false; + m_detailMaterialDataBuffer.UpdateBuffer(m_detailMaterialShaderData.GetRawData(), aznumeric_cast(m_detailMaterialShaderData.GetSize())); + } + + if (m_dirtyDetailRegion.IsValid() || !cameraPosition.IsClose(m_previousCameraPosition) || m_detailImageNeedsUpdate) + { + if (r_terrainDebugDetailImageUpdates) + { + AZ_Printf("TerrainDetailMaterialManager", "Previous Camera: (%f, %f, %f) New Cameara: (%f, %f, %f)", + m_previousCameraPosition.GetX(), m_previousCameraPosition.GetY(), m_previousCameraPosition.GetZ(), + cameraPosition.GetX(), cameraPosition.GetY(), cameraPosition.GetZ()); + } + int32_t newDetailTexturePosX = aznumeric_cast(AZStd::roundf(cameraPosition.GetX() / DetailTextureScale)); + int32_t newDetailTexturePosY = aznumeric_cast(AZStd::roundf(cameraPosition.GetY() / DetailTextureScale)); + + Aabb2i newBounds; + newBounds.m_min.m_x = newDetailTexturePosX - DetailTextureSizeHalf; + newBounds.m_min.m_y = newDetailTexturePosY - DetailTextureSizeHalf; + newBounds.m_max.m_x = newDetailTexturePosX + DetailTextureSizeHalf; + newBounds.m_max.m_y = newDetailTexturePosY + DetailTextureSizeHalf; + + // Use modulo to find the center point in texture space. Care must be taken so negative values are + // handled appropriately (ie, we want -1 % 1024 to equal 1023, not -1) + Vector2i newCenter; + newCenter.m_x = (DetailTextureSize + (newDetailTexturePosX % DetailTextureSize)) % DetailTextureSize; + newCenter.m_y = (DetailTextureSize + (newDetailTexturePosY % DetailTextureSize)) % DetailTextureSize; + + CheckUpdateDetailTexture(newBounds, newCenter); + + m_detailTextureBounds = newBounds; + m_dirtyDetailRegion = AZ::Aabb::CreateNull(); + + m_previousCameraPosition = cameraPosition; + + AZ::Vector4 detailAabb = AZ::Vector4( + m_detailTextureBounds.m_min.m_x * DetailTextureScale, + m_detailTextureBounds.m_min.m_y * DetailTextureScale, + m_detailTextureBounds.m_max.m_x * DetailTextureScale, + m_detailTextureBounds.m_max.m_y * DetailTextureScale + ); + AZ::Vector2 detailUvOffset = AZ::Vector2(float(newCenter.m_x) / DetailTextureSize, float(newCenter.m_y) / DetailTextureSize); + + terrainSrg->SetConstant(m_detailAabbPropertyIndex, detailAabb); + terrainSrg->SetConstant(m_detailHalfPixelUvPropertyIndex, 0.5f / DetailTextureSize); + terrainSrg->SetConstant(m_detailCenterPropertyIndex, detailUvOffset); + terrainSrg->SetImage(m_detailMaterialIdPropertyIndex, m_detailTextureImage); + + m_detailMaterialDataBuffer.UpdateSrg(terrainSrg.get()); + } + + m_detailImageNeedsUpdate = false; + } + + void TerrainDetailMaterialManager::OnTerrainDataChanged(const AZ::Aabb& dirtyRegion, TerrainDataChangedMask dataChangedMask) + { + if ((dataChangedMask & TerrainDataChangedMask::SurfaceData) != 0) + { + m_dirtyDetailRegion.AddAabb(dirtyRegion); + } + } + + void TerrainDetailMaterialManager::OnTerrainSurfaceMaterialMappingCreated(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag, MaterialInstance material) + { + DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); + + // Validate that the surface tag is new + for (DetailMaterialSurface& surface : materialRegion.m_materialsForSurfaces) + { + if (surface.m_surfaceTag == surfaceTag) + { + AZ_Error(TerrainDetailMaterialManagerName, false, "Already have a surface material mapping for this surface tag."); + return; + } + } + + uint16_t detailMaterialId = CreateOrUpdateDetailMaterial(material); + materialRegion.m_materialsForSurfaces.push_back({ surfaceTag, detailMaterialId }); + m_detailMaterials.GetData(detailMaterialId).refCount++; + m_dirtyDetailRegion.AddAabb(materialRegion.m_region); + } + + void TerrainDetailMaterialManager::OnTerrainSurfaceMaterialMappingDestroyed(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag) + { + DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); + + for (DetailMaterialSurface& surface : materialRegion.m_materialsForSurfaces) + { + if (surface.m_surfaceTag == surfaceTag) + { + CheckDetailMaterialForDeletion(surface.m_detailMaterialId); + + if (surface.m_surfaceTag != materialRegion.m_materialsForSurfaces.back().m_surfaceTag) + { + AZStd::swap(surface, materialRegion.m_materialsForSurfaces.back()); + } + materialRegion.m_materialsForSurfaces.pop_back(); + m_dirtyDetailRegion.AddAabb(materialRegion.m_region); + return; + } + } + AZ_Error(TerrainDetailMaterialManagerName, false, "Could not find surface tag to destroy for OnTerrainSurfaceMaterialMappingDestroyed()."); + } + + void TerrainDetailMaterialManager::OnTerrainSurfaceMaterialMappingChanged(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag, MaterialInstance material) + { + DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); + + bool found = false; + uint16_t materialId = CreateOrUpdateDetailMaterial(material); + for (DetailMaterialSurface& surface : materialRegion.m_materialsForSurfaces) + { + if (surface.m_surfaceTag == surfaceTag) + { + found = true; + if (surface.m_detailMaterialId != materialId) + { + ++m_detailMaterials.GetData(materialId).refCount; + CheckDetailMaterialForDeletion(surface.m_detailMaterialId); + surface.m_detailMaterialId = materialId; + } + break; + } + } + + if (!found) + { + ++m_detailMaterials.GetData(materialId).refCount; + materialRegion.m_materialsForSurfaces.push_back({ surfaceTag, materialId }); + } + m_dirtyDetailRegion.AddAabb(materialRegion.m_region); + } + + void TerrainDetailMaterialManager::OnTerrainSurfaceMaterialMappingRegionChanged(AZ::EntityId entityId, const AZ::Aabb& oldRegion, const AZ::Aabb& newRegion) + { + DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); + materialRegion.m_region = newRegion; + m_dirtyDetailRegion.AddAabb(oldRegion); + m_dirtyDetailRegion.AddAabb(newRegion); + } + + void TerrainDetailMaterialManager::CheckDetailMaterialForDeletion(uint16_t detailMaterialId) + { + auto& detailMaterialData = m_detailMaterials.GetData(detailMaterialId); + if (--detailMaterialData.refCount == 0) + { + uint16_t bufferIndex = detailMaterialData.m_detailMaterialBufferIndex; + DetailMaterialShaderData& shaderData = m_detailMaterialShaderData.GetElement(bufferIndex); + + for (uint16_t imageIndex : + { + shaderData.m_colorImageIndex, + shaderData.m_normalImageIndex, + shaderData.m_roughnessImageIndex, + shaderData.m_metalnessImageIndex, + shaderData.m_specularF0ImageIndex, + shaderData.m_occlusionImageIndex, + shaderData.m_heightImageIndex + }) + { + if (imageIndex != InvalidImageIndex) + { + m_bindlessImageHandler->RemoveBindlessImage(imageIndex); + } + } + + m_detailMaterialShaderData.Release(bufferIndex); + m_detailMaterials.RemoveIndex(detailMaterialId); + + m_detailMaterialBufferNeedsUpdate = true; + } + } + + uint16_t TerrainDetailMaterialManager::CreateOrUpdateDetailMaterial(MaterialInstance material) + { + static constexpr uint16_t InvalidDetailMaterial = 0xFFFF; + uint16_t detailMaterialId = InvalidDetailMaterial; + + for (auto& detailMaterialData : m_detailMaterials.GetDataVector()) + { + if (detailMaterialData.m_assetId == material->GetAssetId()) + { + detailMaterialId = m_detailMaterials.GetIndexForData(&detailMaterialData); + UpdateDetailMaterialData(detailMaterialId, material); + break; + } + } + + AZ_Assert(m_detailMaterialShaderData.GetSize() < 0xFF, "Only 255 detail materials supported."); + + if (detailMaterialId == InvalidDetailMaterial && m_detailMaterialShaderData.GetSize() < 0xFF) + { + detailMaterialId = m_detailMaterials.GetFreeSlotIndex(); + auto& detailMaterialData = m_detailMaterials.GetData(detailMaterialId); + detailMaterialData.m_detailMaterialBufferIndex = aznumeric_cast(m_detailMaterialShaderData.Reserve()); + UpdateDetailMaterialData(detailMaterialId, material); + } + return detailMaterialId; + } + + void TerrainDetailMaterialManager::UpdateDetailMaterialData(uint16_t detailMaterialIndex, MaterialInstance material) + { + DetailMaterialData& materialData = m_detailMaterials.GetData(detailMaterialIndex); + DetailMaterialShaderData& shaderData = m_detailMaterialShaderData.GetElement(materialData.m_detailMaterialBufferIndex); + + if (materialData.m_materialChangeId == material->GetCurrentChangeId()) + { + return; // material hasn't changed, nothing to do + } + + materialData.m_materialChangeId = material->GetCurrentChangeId(); + materialData.m_assetId = material->GetAssetId(); + + DetailTextureFlags& flags = shaderData.m_flags; + + auto getIndex = [&](const char* const indexName) -> AZ::RPI::MaterialPropertyIndex + { + const AZ::RPI::MaterialPropertyIndex index = material->FindPropertyIndex(AZ::Name(indexName)); + AZ_Warning(TerrainDetailMaterialManagerName, index.IsValid(), "Failed to find shader input constant %s.", indexName); + return index; + }; + + auto applyProperty = [&](const char* const indexName, auto& ref) -> void + { + const auto index = getIndex(indexName); + if (index.IsValid()) + { + // GetValue() expects the actaul type, not a reference type, so the reference needs to be removed. + using TypeRefRemoved = AZStd::remove_cvref_t; + ref = material->GetPropertyValue(index).GetValue(); + } + }; + + auto applyImage = [&](const char* const indexName, AZ::Data::Instance& ref, const char* const usingFlagName, DetailTextureFlags flagToSet, uint16_t& imageIndex) -> void + { + // Determine if an image exists and if its using flag allows it to be used. + const auto index = getIndex(indexName); + const auto useTextureIndex = getIndex(usingFlagName); + bool useTextureValue = true; + if (useTextureIndex.IsValid()) + { + useTextureValue = material->GetPropertyValue(useTextureIndex).GetValue(); + } + if (index.IsValid() && useTextureValue) + { + ref = material->GetPropertyValue(index).GetValue>(); + } + useTextureValue = useTextureValue && ref; + flags = DetailTextureFlags(useTextureValue ? (flags | flagToSet) : (flags & ~flagToSet)); + + // Update queues to add/remove textures depending on if the image is used + if (ref) + { + if (imageIndex == InvalidImageIndex) + { + imageIndex = m_bindlessImageHandler->AppendBindlessImage(ref->GetImageView()); + } + else + { + m_bindlessImageHandler->UpdateBindlessImage(imageIndex, ref->GetImageView()); + } + } + else if (imageIndex != InvalidImageIndex) + { + m_bindlessImageHandler->RemoveBindlessImage(imageIndex); + imageIndex = InvalidImageIndex; + } + }; + + auto applyFlag = [&](const char* const indexName, DetailTextureFlags flagToSet) -> void + { + const auto index = getIndex(indexName); + if (index.IsValid()) + { + bool flagValue = material->GetPropertyValue(index).GetValue(); + flags = DetailTextureFlags(flagValue ? flags | flagToSet : flags); + } + }; + + auto getEnumName = [&](const char* const indexName) -> const AZStd::string_view + { + const auto index = getIndex(indexName); + if (index.IsValid()) + { + uint32_t enumIndex = material->GetPropertyValue(index).GetValue(); + const AZ::Name& enumName = material->GetMaterialPropertiesLayout()->GetPropertyDescriptor(index)->GetEnumName(enumIndex); + return enumName.GetStringView(); + } + return ""; + }; + + using namespace DetailMaterialInputs; + applyImage(BaseColorMap, materialData.m_colorImage, BaseColorUseTexture, DetailTextureFlags::UseTextureBaseColor, shaderData.m_colorImageIndex); + applyProperty(BaseColorFactor, shaderData.m_baseColorFactor); + + const auto index = getIndex(BaseColorColor); + if (index.IsValid()) + { + AZ::Color baseColor = material->GetPropertyValue(index).GetValue(); + shaderData.m_baseColorRed = baseColor.GetR(); + shaderData.m_baseColorGreen = baseColor.GetG(); + shaderData.m_baseColorBlue = baseColor.GetB(); + } + + const AZStd::string_view& blendModeString = getEnumName(BaseColorBlendMode); + if (blendModeString == "Multiply") + { + flags = DetailTextureFlags(flags | DetailTextureFlags::BlendModeMultiply); + } + else if (blendModeString == "LinearLight") + { + flags = DetailTextureFlags(flags | DetailTextureFlags::BlendModeLinearLight); + } + else if (blendModeString == "Lerp") + { + flags = DetailTextureFlags(flags | DetailTextureFlags::BlendModeLerp); + } + else if (blendModeString == "Overlay") + { + flags = DetailTextureFlags(flags | DetailTextureFlags::BlendModeOverlay); + } + + applyImage(MetallicMap, materialData.m_metalnessImage, MetallicUseTexture, DetailTextureFlags::UseTextureMetallic, shaderData.m_metalnessImageIndex); + applyProperty(MetallicFactor, shaderData.m_metalFactor); + + applyImage(RoughnessMap, materialData.m_roughnessImage, RoughnessUseTexture, DetailTextureFlags::UseTextureRoughness, shaderData.m_roughnessImageIndex); + + if ((flags & DetailTextureFlags::UseTextureRoughness) > 0) + { + float lowerBound = 0.0; + float upperBound = 1.0; + applyProperty(RoughnessLowerBound, lowerBound); + applyProperty(RoughnessUpperBound, upperBound); + shaderData.m_roughnessBias = lowerBound; + shaderData.m_roughnessScale = upperBound - lowerBound; + } + else + { + shaderData.m_roughnessBias = 0.0; + applyProperty(RoughnessFactor, shaderData.m_roughnessScale); + } + + applyImage(SpecularF0Map, materialData.m_specularF0Image, SpecularF0UseTexture, DetailTextureFlags::UseTextureSpecularF0, shaderData.m_specularF0ImageIndex); + applyProperty(SpecularF0Factor, shaderData.m_specularF0Factor); + + applyImage(NormalMap, materialData.m_normalImage, NormalUseTexture, DetailTextureFlags::UseTextureNormal, shaderData.m_normalImageIndex); + applyProperty(NormalFactor, shaderData.m_normalFactor); + applyFlag(NormalFlipX, DetailTextureFlags::FlipNormalX); + applyFlag(NormalFlipY, DetailTextureFlags::FlipNormalY); + + applyImage(DiffuseOcclusionMap, materialData.m_occlusionImage, DiffuseOcclusionUseTexture, DetailTextureFlags::UseTextureOcclusion, shaderData.m_occlusionImageIndex); + applyProperty(DiffuseOcclusionFactor, shaderData.m_occlusionFactor); + + applyImage(HeightMap, materialData.m_heightImage, HeightUseTexture, DetailTextureFlags::UseTextureHeight, shaderData.m_heightImageIndex); + applyProperty(HeightFactor, shaderData.m_heightFactor); + applyProperty(HeightOffset, shaderData.m_heightOffset); + applyProperty(HeightBlendFactor, shaderData.m_heightBlendFactor); + + m_detailMaterialBufferNeedsUpdate = true; + } + + void TerrainDetailMaterialManager::CheckUpdateDetailTexture(const Aabb2i& newBounds, const Vector2i& newCenter) + { + if (r_terrainDebugDetailImageUpdates) + { + AZ_Printf("TerrainDetailMaterialManager", "Old Bounds: m(%i, %i)M(%i, %i) New Bounds: m(%i, %i)M(%i, %i)", + m_detailTextureBounds.m_min.m_x, m_detailTextureBounds.m_min.m_y, m_detailTextureBounds.m_max.m_x, m_detailTextureBounds.m_max.m_y, + newBounds.m_min.m_x, newBounds.m_min.m_y, newBounds.m_max.m_x, newBounds.m_max.m_y + ); + } + if (!m_detailTextureImage) + { + // If the m_detailTextureImage doesn't exist, create it and populate the entire texture + + const AZ::Data::Instance imagePool = AZ::RPI::ImageSystemInterface::Get()->GetSystemAttachmentPool(); + AZ::RHI::ImageDescriptor imageDescriptor = AZ::RHI::ImageDescriptor::Create2D( + AZ::RHI::ImageBindFlags::ShaderRead, DetailTextureSize, DetailTextureSize, AZ::RHI::Format::R8G8B8A8_UINT + ); + const AZ::Name TerrainDetailName = AZ::Name(TerrainDetailChars); + m_detailTextureImage = AZ::RPI::AttachmentImage::Create(*imagePool.get(), imageDescriptor, TerrainDetailName, nullptr, nullptr); + AZ_Error(TerrainDetailMaterialManagerName, m_detailTextureImage, "Failed to initialize the detail texture image."); + + UpdateDetailTexture(newBounds, newBounds, newCenter); + } + else + { + // If the new bounds of the detail texture are different than the old bounds, then the edges of the texture need to be updated. + + int32_t offsetX = m_detailTextureBounds.m_min.m_x - newBounds.m_min.m_x; + + // Horizontal edge update + if (newBounds.m_min.m_x != m_detailTextureBounds.m_min.m_x) + { + Aabb2i updateBounds; + if (newBounds.m_min.m_x < m_detailTextureBounds.m_min.m_x) + { + updateBounds.m_min.m_x = newBounds.m_min.m_x; + updateBounds.m_max.m_x = m_detailTextureBounds.m_min.m_x; + } + else + { + updateBounds.m_min.m_x = m_detailTextureBounds.m_max.m_x; + updateBounds.m_max.m_x = newBounds.m_max.m_x; + } + updateBounds.m_min.m_y = newBounds.m_min.m_y; + updateBounds.m_max.m_y = newBounds.m_max.m_y; + + if (r_terrainDebugDetailImageUpdates) + { + AZ_Printf("TerrainDetailMaterialManager", "Updating horizontal edge: m(%i, %i)M(%i, %i)", + updateBounds.m_min.m_x, updateBounds.m_min.m_y, updateBounds.m_max.m_x, updateBounds.m_max.m_y); + } + UpdateDetailTexture(updateBounds, newBounds, newCenter); + } + + // Vertical edge update + if (newBounds.m_min.m_y != m_detailTextureBounds.m_min.m_y) + { + Aabb2i updateBounds; + // Don't update areas that have already been updated in the horizontal update. + updateBounds.m_min.m_x = newBounds.m_min.m_x + AZ::GetMax(0, offsetX); + updateBounds.m_max.m_x = newBounds.m_max.m_x + AZ::GetMin(0, offsetX); + if (newBounds.m_min.m_y < m_detailTextureBounds.m_min.m_y) + { + updateBounds.m_min.m_y = newBounds.m_min.m_y; + updateBounds.m_max.m_y = m_detailTextureBounds.m_min.m_y; + } + else + { + updateBounds.m_min.m_y = m_detailTextureBounds.m_max.m_y; + updateBounds.m_max.m_y = newBounds.m_max.m_y; + } + + if (r_terrainDebugDetailImageUpdates) + { + AZ_Printf("TerrainDetailMaterialManager", "Updating vertical edge: m(%i, %i)M(%i, %i)", + updateBounds.m_min.m_x, updateBounds.m_min.m_y, updateBounds.m_max.m_x, updateBounds.m_max.m_y); + } + UpdateDetailTexture(updateBounds, newBounds, newCenter); + } + + if (m_dirtyDetailRegion.IsValid()) + { + if (r_terrainDebugDetailImageUpdates) + { + AZ_Printf("TerrainDetailMaterialManager", "m_dirtyDetailRegion: m(%f, %f)M(%f, %f)", + m_dirtyDetailRegion.GetMin().GetX(), m_dirtyDetailRegion.GetMin().GetY(), m_dirtyDetailRegion.GetMax().GetX(), m_dirtyDetailRegion.GetMax().GetY()); + } + // If any regions are marked as dirty, then they should be updated. + + AZ::Vector3 currentMin = AZ::Vector3(newBounds.m_min.m_x * DetailTextureScale, newBounds.m_min.m_y * DetailTextureScale, -0.5f); + AZ::Vector3 currentMax = AZ::Vector3(newBounds.m_max.m_x * DetailTextureScale, newBounds.m_max.m_y * DetailTextureScale, 0.5f); + AZ::Aabb detailTextureCoverage = AZ::Aabb::CreateFromMinMax(currentMin, currentMax); + AZ::Vector3 previousMin = AZ::Vector3(m_detailTextureBounds.m_min.m_x * DetailTextureScale, m_detailTextureBounds.m_min.m_y * DetailTextureScale, -0.5f); + AZ::Vector3 previousMax = AZ::Vector3(m_detailTextureBounds.m_max.m_x * DetailTextureScale, m_detailTextureBounds.m_max.m_y * DetailTextureScale, 0.5f); + AZ::Aabb previousCoverage = AZ::Aabb::CreateFromMinMax(previousMin, previousMax); + + // Area of texture not already updated by camera movement above. + AZ::Aabb clampedCoverage = previousCoverage.GetClamped(detailTextureCoverage); + + // Clamp the dirty region to the area of the detail texture that is visible and not already updated. + clampedCoverage.Clamp(m_dirtyDetailRegion); + + if (clampedCoverage.IsValid()) + { + Aabb2i updateBounds; + updateBounds.m_min.m_x = aznumeric_cast(AZStd::roundf(clampedCoverage.GetMin().GetX() / DetailTextureScale)); + updateBounds.m_min.m_y = aznumeric_cast(AZStd::roundf(clampedCoverage.GetMin().GetY() / DetailTextureScale)); + updateBounds.m_max.m_x = aznumeric_cast(AZStd::roundf(clampedCoverage.GetMax().GetX() / DetailTextureScale)); + updateBounds.m_max.m_y = aznumeric_cast(AZStd::roundf(clampedCoverage.GetMax().GetY() / DetailTextureScale)); + if (updateBounds.m_min.m_x < updateBounds.m_max.m_x && updateBounds.m_min.m_y < updateBounds.m_max.m_y) + { + + if (r_terrainDebugDetailImageUpdates) + { + AZ_Printf("TerrainDetailMaterialManager", "Updating dirty region: m(%i, %i)M(%i, %i)", + updateBounds.m_min.m_x, updateBounds.m_min.m_y, updateBounds.m_max.m_x, updateBounds.m_max.m_y); + } + UpdateDetailTexture(updateBounds, newBounds, newCenter); + } + } + } + } + } + + void TerrainDetailMaterialManager::UpdateDetailTexture(const Aabb2i& updateArea, const Aabb2i& textureBounds, const Vector2i& centerPixel) + { + if (!m_detailTextureImage) + { + return; + } + + struct DetailMaterialPixel + { + uint8_t m_material1{ 255 }; + uint8_t m_material2{ 255 }; + uint8_t m_blend{ 0 }; // 0 = full weight on material1, 255 = full weight on material2 + uint8_t m_padding{ 0 }; + }; + + // Because the center of the detail texture may be offset, each update area may actually need to be split into + // up to 4 separate update areas in each sector of the quadrant. + AZStd::array textureSpaceAreas; + AZStd::array scaledWorldSpaceAreas; + uint8_t updateAreaCount = CalculateUpdateRegions(updateArea, textureBounds, centerPixel, textureSpaceAreas, scaledWorldSpaceAreas); + + if (updateAreaCount > 0) + { + m_detailImageNeedsUpdate = true; + } + + // Pull the data for each area updated and use it to construct an update for the detail material id texture. + for (uint8_t i = 0; i < updateAreaCount; ++i) + { + const Aabb2i& quadrantTextureArea = textureSpaceAreas[i]; + const Aabb2i& quadrantWorldArea = scaledWorldSpaceAreas[i]; + + AZStd::vector pixels; + pixels.resize((quadrantWorldArea.m_max.m_x - quadrantWorldArea.m_min.m_x) * (quadrantWorldArea.m_max.m_y - quadrantWorldArea.m_min.m_y)); + uint32_t index = 0; + + for (int yPos = quadrantWorldArea.m_min.m_y; yPos < quadrantWorldArea.m_max.m_y; ++yPos) + { + for (int xPos = quadrantWorldArea.m_min.m_x; xPos < quadrantWorldArea.m_max.m_x; ++xPos) + { + AZ::Vector2 position = AZ::Vector2(xPos * DetailTextureScale, yPos * DetailTextureScale); + AzFramework::SurfaceData::SurfaceTagWeightList surfaceWeights; + AzFramework::Terrain::TerrainDataRequestBus::Broadcast(&AzFramework::Terrain::TerrainDataRequests::GetSurfaceWeightsFromVector2, position, surfaceWeights, AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT, nullptr); + + // Store the top two surface weights in the texture with m_blend storing the relative weight. + bool isFirstMaterial = true; + float firstWeight = 0.0f; + for (const auto& surfaceTagWeight : surfaceWeights) + { + if (surfaceTagWeight.m_weight > 0.0f) + { + AZ::Crc32 surfaceType = surfaceTagWeight.m_surfaceType; + uint16_t materialId = GetDetailMaterialForSurfaceTypeAndPosition(surfaceType, position); + if (materialId != m_detailMaterials.NoFreeSlot && materialId < 255) + { + if (isFirstMaterial) + { + pixels.at(index).m_material1 = aznumeric_cast(materialId); + firstWeight = surfaceTagWeight.m_weight; + // m_blend only needs to be calculated is material 2 is found, otherwise the initial value of 0 is correct. + isFirstMaterial = false; + } + else + { + pixels.at(index).m_material2 = aznumeric_cast(materialId); + float totalWeight = firstWeight + surfaceTagWeight.m_weight; + float blendWeight = 1.0f - (firstWeight / totalWeight); + pixels.at(index).m_blend = aznumeric_cast(AZStd::round(blendWeight * 255.0f)); + break; + } + } + } + else + { + break; // since the list is ordered, no other materials are in the list with positive weights. + } + } + ++index; + } + } + + const int32_t left = quadrantTextureArea.m_min.m_x; + const int32_t top = quadrantTextureArea.m_min.m_y; + const int32_t width = quadrantTextureArea.m_max.m_x - quadrantTextureArea.m_min.m_x; + const int32_t height = quadrantTextureArea.m_max.m_y - quadrantTextureArea.m_min.m_y; + + AZ::RHI::ImageUpdateRequest imageUpdateRequest; + imageUpdateRequest.m_imageSubresourcePixelOffset.m_left = aznumeric_cast(left); + imageUpdateRequest.m_imageSubresourcePixelOffset.m_top = aznumeric_cast(top); + imageUpdateRequest.m_sourceSubresourceLayout.m_bytesPerRow = width * sizeof(DetailMaterialPixel); + imageUpdateRequest.m_sourceSubresourceLayout.m_bytesPerImage = width * height * sizeof(DetailMaterialPixel); + imageUpdateRequest.m_sourceSubresourceLayout.m_rowCount = height; + imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_width = width; + imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_height = height; + imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_depth = 1; + imageUpdateRequest.m_sourceData = pixels.data(); + imageUpdateRequest.m_image = m_detailTextureImage->GetRHIImage(); + + m_detailTextureImage->UpdateImageContents(imageUpdateRequest); + } + } + + uint8_t TerrainDetailMaterialManager::CalculateUpdateRegions(const Aabb2i& updateArea, const Aabb2i& textureBounds, const Vector2i& centerPixel, + AZStd::array& textureSpaceAreas, AZStd::array& scaledWorldSpaceAreas) + { + Vector2i centerOffset = { centerPixel.m_x - DetailTextureSizeHalf, centerPixel.m_y - DetailTextureSizeHalf }; + + int32_t quadrantXOffset = centerPixel.m_x < DetailTextureSizeHalf ? DetailTextureSize : -DetailTextureSize; + int32_t quadrantYOffset = centerPixel.m_y < DetailTextureSizeHalf ? DetailTextureSize : -DetailTextureSize; + + uint8_t numQuadrants = 0; + + // For each of the 4 quadrants: + auto calculateQuadrant = [&](Vector2i quadrantOffset) + { + Aabb2i offsetUpdateArea = updateArea + centerOffset + quadrantOffset; + Aabb2i updateSectionBounds = textureBounds.GetClamped(offsetUpdateArea); + if (updateSectionBounds.IsValid()) + { + textureSpaceAreas[numQuadrants] = updateSectionBounds - textureBounds.m_min; + scaledWorldSpaceAreas[numQuadrants] = updateSectionBounds - centerOffset - quadrantOffset; + ++numQuadrants; + } + }; + + calculateQuadrant({ 0, 0 }); + calculateQuadrant({ quadrantXOffset, 0 }); + calculateQuadrant({ 0, quadrantYOffset }); + calculateQuadrant({ quadrantXOffset, quadrantYOffset }); + + return numQuadrants; + } + + uint16_t TerrainDetailMaterialManager::GetDetailMaterialForSurfaceTypeAndPosition(AZ::Crc32 surfaceType, const AZ::Vector2& position) + { + for (const auto& materialRegion : m_detailMaterialRegions.GetDataVector()) + { + if (materialRegion.m_region.Contains(AZ::Vector3(position.GetX(), position.GetY(), 0.0f))) + { + for (const auto& materialSurface : materialRegion.m_materialsForSurfaces) + { + if (materialSurface.m_surfaceTag == surfaceType) + { + return m_detailMaterials.GetData(materialSurface.m_detailMaterialId).m_detailMaterialBufferIndex; + } + } + } + } + return m_detailMaterials.NoFreeSlot; + } + + auto TerrainDetailMaterialManager::FindByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container) + -> DetailMaterialListRegion* + { + for (DetailMaterialListRegion& data : container.GetDataVector()) + { + if (data.m_entityId == entityId) + { + return &data; + } + } + return nullptr; + } + + auto TerrainDetailMaterialManager::FindOrCreateByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container) + -> DetailMaterialListRegion& + { + DetailMaterialListRegion* dataPtr = FindByEntityId(entityId, container); + if (dataPtr != nullptr) + { + return *dataPtr; + } + + const uint16_t slotId = container.GetFreeSlotIndex(); + AZ_Assert(slotId != AZ::Render::IndexedDataVector::NoFreeSlot, "Ran out of indices"); + + DetailMaterialListRegion& data = container.GetData(slotId); + data.m_entityId = entityId; + return data; + } + + void TerrainDetailMaterialManager::RemoveByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container) + { + for (DetailMaterialListRegion& data : container.GetDataVector()) + { + if (data.m_entityId == entityId) + { + container.RemoveData(&data); + return; + } + } + AZ_Assert(false, "Entity Id not found in container.") + } + +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainDetailMaterialManager.h b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainDetailMaterialManager.h new file mode 100644 index 0000000000..98f2c26dd8 --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainDetailMaterialManager.h @@ -0,0 +1,226 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include + +#include + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +namespace Terrain +{ + class TerrainDetailMaterialManager + : private AzFramework::Terrain::TerrainDataNotificationBus::Handler + , private TerrainAreaMaterialNotificationBus::Handler + { + public: + + AZ_RTTI(TerrainDetailMaterialManager, "{3CBAF88F-E3B1-43B8-97A5-999133188BCC}"); + AZ_DISABLE_COPY_MOVE(TerrainDetailMaterialManager); + + TerrainDetailMaterialManager() = default; + ~TerrainDetailMaterialManager() = default; + + void Initialize( + const AZStd::shared_ptr& bindlessImageHandler, + AZ::Data::Instance& terrainSrg); + bool IsInitialized() const; + void Reset(); + bool UpdateSrgIndices(AZ::Data::Instance& srg); + + void Update(const AZ::Vector3& cameraPosition, AZ::Data::Instance& terrainSrg); + + private: + + using MaterialInstance = AZ::Data::Instance; + static constexpr auto InvalidImageIndex = AZ::Render::BindlessImageArrayHandler::InvalidImageIndex; + + enum DetailTextureFlags : uint32_t + { + UseTextureBaseColor = 0b0000'0000'0000'0000'0000'0000'0000'0001, + UseTextureNormal = 0b0000'0000'0000'0000'0000'0000'0000'0010, + UseTextureMetallic = 0b0000'0000'0000'0000'0000'0000'0000'0100, + UseTextureRoughness = 0b0000'0000'0000'0000'0000'0000'0000'1000, + UseTextureOcclusion = 0b0000'0000'0000'0000'0000'0000'0001'0000, + UseTextureHeight = 0b0000'0000'0000'0000'0000'0000'0010'0000, + UseTextureSpecularF0 = 0b0000'0000'0000'0000'0000'0000'0100'0000, + + FlipNormalX = 0b0000'0000'0000'0001'0000'0000'0000'0000, + FlipNormalY = 0b0000'0000'0000'0010'0000'0000'0000'0000, + + BlendModeMask = 0b0000'0000'0000'1100'0000'0000'0000'0000, + BlendModeLerp = 0b0000'0000'0000'0000'0000'0000'0000'0000, + BlendModeLinearLight = 0b0000'0000'0000'0100'0000'0000'0000'0000, + BlendModeMultiply = 0b0000'0000'0000'1000'0000'0000'0000'0000, + BlendModeOverlay = 0b0000'0000'0000'1100'0000'0000'0000'0000, + }; + + struct DetailMaterialShaderData + { + // Uv + AZStd::array m_uvTransform + { + 1.0, 0.0, 0.0, 0.0, + 0.0, 1.0, 0.0, 0.0, + 0.0, 0.0, 1.0, 0.0, + }; + + float m_baseColorRed{ 1.0f }; + float m_baseColorGreen{ 1.0f }; + float m_baseColorBlue{ 1.0f }; + + // Factor / Scale / Bias for input textures + float m_baseColorFactor{ 1.0f }; + + float m_normalFactor{ 1.0f }; + float m_metalFactor{ 1.0f }; + float m_roughnessScale{ 1.0f }; + float m_roughnessBias{ 0.0f }; + + float m_specularF0Factor{ 1.0f }; + float m_occlusionFactor{ 1.0f }; + float m_heightFactor{ 1.0f }; + float m_heightOffset{ 0.0f }; + + float m_heightBlendFactor{ 0.5f }; + + // Flags + DetailTextureFlags m_flags{ 0 }; + + // Image indices + uint16_t m_colorImageIndex{ InvalidImageIndex }; + uint16_t m_normalImageIndex{ InvalidImageIndex }; + uint16_t m_roughnessImageIndex{ InvalidImageIndex }; + uint16_t m_metalnessImageIndex{ InvalidImageIndex }; + + uint16_t m_specularF0ImageIndex{ InvalidImageIndex }; + uint16_t m_occlusionImageIndex{ InvalidImageIndex }; + uint16_t m_heightImageIndex{ InvalidImageIndex }; + + // 16 byte aligned + uint16_t m_padding1; + uint32_t m_padding2; + uint32_t m_padding3; + }; + static_assert(sizeof(DetailMaterialShaderData) % 16 == 0, "DetailMaterialShaderData must be 16 byte aligned."); + + struct DetailMaterialData + { + AZ::Data::AssetId m_assetId; + AZ::RPI::Material::ChangeId m_materialChangeId{AZ::RPI::Material::DEFAULT_CHANGE_ID}; + uint32_t refCount = 0; + uint16_t m_detailMaterialBufferIndex{ 0xFFFF }; + + AZ::Data::Instance m_colorImage; + AZ::Data::Instance m_normalImage; + AZ::Data::Instance m_roughnessImage; + AZ::Data::Instance m_metalnessImage; + AZ::Data::Instance m_specularF0Image; + AZ::Data::Instance m_occlusionImage; + AZ::Data::Instance m_heightImage; + }; + + struct DetailMaterialSurface + { + AZ::Crc32 m_surfaceTag; + uint16_t m_detailMaterialId; + }; + + struct DetailMaterialListRegion + { + AZ::EntityId m_entityId; + AZ::Aabb m_region{AZ::Aabb::CreateNull()}; + AZStd::vector m_materialsForSurfaces; + }; + + // System-level parameters + static constexpr int32_t DetailTextureSize{ 1024 }; + static constexpr int32_t DetailTextureSizeHalf{ DetailTextureSize / 2 }; + static constexpr float DetailTextureScale{ 0.5f }; + + // AzFramework::Terrain::TerrainDataNotificationBus overrides... + void OnTerrainDataChanged(const AZ::Aabb& dirtyRegion, TerrainDataChangedMask dataChangedMask) override; + + // TerrainAreaMaterialNotificationBus overrides... + void OnTerrainSurfaceMaterialMappingCreated(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag, MaterialInstance material) override; + void OnTerrainSurfaceMaterialMappingDestroyed(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag) override; + void OnTerrainSurfaceMaterialMappingChanged(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag, MaterialInstance material) override; + void OnTerrainSurfaceMaterialMappingRegionChanged(AZ::EntityId entityId, const AZ::Aabb& oldRegion, const AZ::Aabb& newRegion) override; + + //! Removes all images from all detail materials from the bindless image array + void RemoveAllImages(); + + //! Creates or updates an existing detail material with settings from a material instance + uint16_t CreateOrUpdateDetailMaterial(MaterialInstance material); + + //! Decrements the ref count on a detail material and removes it if it reaches 0 + void CheckDetailMaterialForDeletion(uint16_t detailMaterialId); + + //! Updates a specific detail material with settings from a material instance + void UpdateDetailMaterialData(uint16_t detailMaterialIndex, MaterialInstance material); + + //! Checks to see if the detail material id texture needs to update based on new center and bounds. Any + //! required updates are then executed. + void CheckUpdateDetailTexture(const Aabb2i& newBounds, const Vector2i& newCenter); + + //! Updates the detail texture in a given area + void UpdateDetailTexture(const Aabb2i& updateArea, const Aabb2i& textureBounds, const Vector2i& centerPixel); + + //! Finds the detail material Id for a surface type and position + uint16_t GetDetailMaterialForSurfaceTypeAndPosition(AZ::Crc32 surfaceType, const AZ::Vector2& position); + + //! Calculates which regions of the detail material id texture need to be updated based on the update area. Since + //! the "center" of the detail material id texture can move, a single update region in contiguous world space may + //! map to up to 4 different areas on teh detail material id texture. + uint8_t CalculateUpdateRegions(const Aabb2i& updateArea, const Aabb2i& textureBounds, const Vector2i& centerPixel, + AZStd::array& textureSpaceAreas, AZStd::array& scaledWorldSpaceAreas); + + DetailMaterialListRegion* FindByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container); + DetailMaterialListRegion& FindOrCreateByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container); + void RemoveByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container); + + AZStd::shared_ptr m_bindlessImageHandler; + + AZ::Data::Instance m_detailTextureImage; + + AZ::Render::IndexedDataVector m_detailMaterials; + AZ::Render::IndexedDataVector m_detailMaterialRegions; + AZ::Render::SparseVector m_detailMaterialShaderData; + AZ::Render::GpuBufferHandler m_detailMaterialDataBuffer; + + AZ::Aabb m_dirtyDetailRegion{ AZ::Aabb::CreateNull() }; + AZ::Vector3 m_previousCameraPosition = AZ::Vector3(AZStd::numeric_limits::max(), 0.0, 0.0); + Aabb2i m_detailTextureBounds; + Vector2i m_detailTextureCenter; + + AZ::RHI::ShaderInputImageIndex m_detailMaterialIdPropertyIndex; + AZ::RHI::ShaderInputBufferIndex m_detailMaterialDataIndex; + AZ::RHI::ShaderInputConstantIndex m_detailCenterPropertyIndex; + AZ::RHI::ShaderInputConstantIndex m_detailAabbPropertyIndex; + AZ::RHI::ShaderInputConstantIndex m_detailHalfPixelUvPropertyIndex; + + bool m_isInitialized{ false }; + bool m_detailMaterialBufferNeedsUpdate{ false }; + bool m_detailImageNeedsUpdate{ false }; + + }; +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainFeatureProcessor.cpp b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainFeatureProcessor.cpp index 9f83844243..351c34308a 100644 --- a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainFeatureProcessor.cpp +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainFeatureProcessor.cpp @@ -7,38 +7,22 @@ */ #include -#include - -#include -#include -#include -#include -#include #include -#include -#include -#include #include #include #include #include -#include -#include #include #include -#include #include #include #include #include #include -#include -#include -#include #include @@ -50,79 +34,19 @@ namespace Terrain { [[maybe_unused]] const char* TerrainFPName = "TerrainFeatureProcessor"; const char* TerrainHeightmapChars = "TerrainHeightmap"; - const char* TerrainDetailChars = "TerrainDetail"; } - namespace ViewSrgInputs + namespace SceneSrgInputs { static const char* const HeightmapImage("m_heightmapImage"); + static const char* const TerrainWorldData("m_terrainWorldData"); } namespace TerrainSrgInputs { - static const char* const DetailMaterialIdImage("m_detailMaterialIdImage"); - static const char* const DetailMaterialData("m_detailMaterialData"); - static const char* const DetailMaterialIdImageCenter("m_detailMaterialIdImageCenter"); - static const char* const DetailHalfPixelUv("m_detailHalfPixelUv"); - static const char* const DetailAabb("m_detailAabb"); - static const char* const DetailTextures("m_detailTextures"); - } - - namespace DetailMaterialInputs - { - static const char* const BaseColorColor("baseColor.color"); - static const char* const BaseColorMap("baseColor.textureMap"); - static const char* const BaseColorUseTexture("baseColor.useTexture"); - static const char* const BaseColorFactor("baseColor.factor"); - static const char* const BaseColorBlendMode("baseColor.textureBlendMode"); - static const char* const MetallicMap("metallic.textureMap"); - static const char* const MetallicUseTexture("metallic.useTexture"); - static const char* const MetallicFactor("metallic.factor"); - static const char* const RoughnessMap("roughness.textureMap"); - static const char* const RoughnessUseTexture("roughness.useTexture"); - static const char* const RoughnessFactor("roughness.factor"); - static const char* const RoughnessLowerBound("roughness.lowerBound"); - static const char* const RoughnessUpperBound("roughness.upperBound"); - static const char* const SpecularF0Map("specularF0.textureMap"); - static const char* const SpecularF0UseTexture("specularF0.useTexture"); - static const char* const SpecularF0Factor("specularF0.factor"); - static const char* const NormalMap("normal.textureMap"); - static const char* const NormalUseTexture("normal.useTexture"); - static const char* const NormalFactor("normal.factor"); - static const char* const NormalFlipX("normal.flipX"); - static const char* const NormalFlipY("normal.flipY"); - static const char* const DiffuseOcclusionMap("occlusion.diffuseTextureMap"); - static const char* const DiffuseOcclusionUseTexture("occlusion.diffuseUseTexture"); - static const char* const DiffuseOcclusionFactor("occlusion.diffuseFactor"); - static const char* const HeightMap("parallax.textureMap"); - static const char* const HeightUseTexture("parallax.useTexture"); - static const char* const HeightFactor("parallax.factor"); - static const char* const HeightOffset("parallax.offset"); - static const char* const HeightBlendFactor("parallax.blendFactor"); + static const char* const Textures("m_textures"); } - namespace ShaderInputs - { - static const char* const ModelToWorld("m_modelToWorld"); - static const char* const TerrainData("m_terrainData"); - static const char* const MacroMaterialData("m_macroMaterialData"); - static const char* const MacroMaterialCount("m_macroMaterialCount"); - static const char* const MacroColorMap("m_macroColorMap"); - static const char* const MacroNormalMap("m_macroNormalMap"); - } - - AZ_CVAR(bool, - r_terrainDebugDetailMaterials, - false, - [](const bool& value) - { - AZ::RPI::ShaderSystemInterface::Get()->SetGlobalShaderOption(AZ::Name{ "o_debugDetailMaterialIds" }, AZ::RPI::ShaderOptionValue{ value }); - }, - AZ::ConsoleFunctorFlags::Null, - "Turns on debugging for detail material ids for terrain." - ); - - void TerrainFeatureProcessor::Reflect(AZ::ReflectContext* context) { if (AZ::SerializeContext* serialize = azrtti_cast(context)) @@ -150,13 +74,17 @@ namespace Terrain void TerrainFeatureProcessor::Initialize() { - // Load indices for the View Srg. + m_meshManager.Initialize(); + m_imageArrayHandler = AZStd::make_shared(); - auto viewSrgLayout = AZ::RPI::RPISystemInterface::Get()->GetViewSrgLayout(); + auto sceneSrgLayout = AZ::RPI::RPISystemInterface::Get()->GetSceneSrgLayout(); - m_heightmapPropertyIndex = viewSrgLayout->FindShaderInputImageIndex(AZ::Name(ViewSrgInputs::HeightmapImage)); - AZ_Error(TerrainFPName, m_heightmapPropertyIndex.IsValid(), "Failed to find view srg input constant %s.", ViewSrgInputs::HeightmapImage); + m_heightmapPropertyIndex = sceneSrgLayout->FindShaderInputImageIndex(AZ::Name(SceneSrgInputs::HeightmapImage)); + AZ_Error(TerrainFPName, m_heightmapPropertyIndex.IsValid(), "Failed to find scene srg input constant %s.", SceneSrgInputs::HeightmapImage); + m_worldDataIndex = sceneSrgLayout->FindShaderInputConstantIndex(AZ::Name(SceneSrgInputs::TerrainWorldData)); + AZ_Error(TerrainFPName, m_worldDataIndex.IsValid(), "Failed to find scene srg input constant %s.", SceneSrgInputs::TerrainWorldData); + // Load the terrain material asynchronously const AZStd::string materialFilePath = "Materials/Terrain/DefaultPbrTerrain.azmaterial"; m_materialAssetLoader = AZStd::make_unique(); @@ -179,31 +107,24 @@ namespace Terrain } } ); - if (!InitializePatchModel()) - { - AZ_Error(TerrainFPName, false, "Failed to create Terrain render buffers!"); - return; - } OnTerrainDataChanged(AZ::Aabb::CreateNull(), TerrainDataChangedMask::HeightData); } void TerrainFeatureProcessor::Deactivate() { - TerrainMacroMaterialNotificationBus::Handler::BusDisconnect(); AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusDisconnect(); AZ::RPI::MaterialReloadNotificationBus::Handler::BusDisconnect(); DisableSceneNotification(); + OnTerrainDataDestroyBegin(); - m_patchModel = {}; - m_areaData = {}; - m_dirtyRegion = AZ::Aabb::CreateNull(); - m_sectorData.clear(); - m_macroMaterials.Clear(); m_materialAssetLoader = {}; m_materialInstance = {}; + m_meshManager.Reset(); + m_macroMaterialManager.Reset(); + m_detailMaterialManager.Reset(); } void TerrainFeatureProcessor::Render(const AZ::RPI::FeatureProcessor::RenderPacket& packet) @@ -213,7 +134,10 @@ namespace Terrain void TerrainFeatureProcessor::OnTerrainDataDestroyBegin() { - m_areaData = {}; + m_heightmapImage = {}; + m_terrainBounds = AZ::Aabb::CreateNull(); + m_dirtyRegion = AZ::Aabb::CreateNull(); + m_heightmapNeedsUpdate = false; } void TerrainFeatureProcessor::OnTerrainDataChanged(const AZ::Aabb& dirtyRegion, TerrainDataChangedMask dataChangedMask) @@ -222,10 +146,6 @@ namespace Terrain { TerrainHeightOrSettingsUpdated(dirtyRegion); } - if ((dataChangedMask & TerrainDataChangedMask::SurfaceData) != 0) - { - TerrainSurfaceDataUpdated(dirtyRegion); - } } void TerrainFeatureProcessor::TerrainHeightOrSettingsUpdated(const AZ::Aabb& dirtyRegion) @@ -239,1335 +159,263 @@ namespace Terrain m_dirtyRegion.AddAabb(regionToUpdate); m_dirtyRegion.Clamp(worldBounds); - const AZ::Transform transform = AZ::Transform::CreateTranslation(worldBounds.GetCenter()); - AZ::Vector2 queryResolution2D = AZ::Vector2(1.0f); AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( queryResolution2D, &AzFramework::Terrain::TerrainDataRequests::GetTerrainHeightQueryResolution); // Currently query resolution is multidimensional but the rendering system only supports this changing in one dimension. float queryResolution = queryResolution2D.GetX(); - // Sectors need to be rebuilt if the world bounds change in the x/y, or the sample spacing changes. - m_areaData.m_rebuildSectors = m_areaData.m_rebuildSectors || - m_areaData.m_terrainBounds.GetMin().GetX() != worldBounds.GetMin().GetX() || - m_areaData.m_terrainBounds.GetMin().GetY() != worldBounds.GetMin().GetY() || - m_areaData.m_terrainBounds.GetMax().GetX() != worldBounds.GetMax().GetX() || - m_areaData.m_terrainBounds.GetMax().GetY() != worldBounds.GetMax().GetY() || - m_areaData.m_sampleSpacing != queryResolution; - - m_areaData.m_transform = transform; - m_areaData.m_terrainBounds = worldBounds; - m_areaData.m_sampleSpacing = queryResolution; - m_areaData.m_heightmapUpdated = true; + m_terrainBounds = worldBounds; + m_sampleSpacing = queryResolution; + m_heightmapNeedsUpdate = true; } - void TerrainFeatureProcessor::TerrainSurfaceDataUpdated(const AZ::Aabb& dirtyRegion) + void TerrainFeatureProcessor::OnRenderPipelinePassesChanged([[maybe_unused]] AZ::RPI::RenderPipeline* renderPipeline) { - m_dirtyDetailRegion.AddAabb(dirtyRegion); + CacheForwardPass(); } - void TerrainFeatureProcessor::OnTerrainMacroMaterialCreated(AZ::EntityId entityId, const MacroMaterialData& newMaterialData) + void TerrainFeatureProcessor::UpdateHeightmapImage() { - MacroMaterialData& materialData = FindOrCreateByEntityId(entityId, m_macroMaterials); - - UpdateMacroMaterialData(materialData, newMaterialData); + int32_t heightmapImageXStart = aznumeric_cast(AZStd::ceilf(m_terrainBounds.GetMin().GetX() / m_sampleSpacing)); + int32_t heightmapImageXEnd = aznumeric_cast(AZStd::floorf(m_terrainBounds.GetMax().GetX() / m_sampleSpacing)) + 1; + int32_t heightmapImageYStart = aznumeric_cast(AZStd::ceilf(m_terrainBounds.GetMin().GetY() / m_sampleSpacing)); + int32_t heightmapImageYEnd = aznumeric_cast(AZStd::floorf(m_terrainBounds.GetMax().GetY() / m_sampleSpacing)) + 1; + uint32_t heightmapImageWidth = heightmapImageXEnd - heightmapImageXStart; + uint32_t heightmapImageHeight = heightmapImageYEnd - heightmapImageYStart; - // Update all sectors in region. - ForOverlappingSectors(materialData.m_bounds, - [&](SectorData& sectorData) { - if (sectorData.m_macroMaterials.size() < sectorData.m_macroMaterials.max_size()) - { - sectorData.m_macroMaterials.push_back(m_macroMaterials.GetIndexForData(&materialData)); - } - } - ); - } + const AZ::RHI::Size heightmapSize = AZ::RHI::Size(heightmapImageWidth, heightmapImageHeight, 1); - void TerrainFeatureProcessor::OnTerrainMacroMaterialChanged(AZ::EntityId entityId, const MacroMaterialData& newMaterialData) - { - MacroMaterialData& data = FindOrCreateByEntityId(entityId, m_macroMaterials); - UpdateMacroMaterialData(data, newMaterialData); - } - - void TerrainFeatureProcessor::OnTerrainMacroMaterialRegionChanged( - AZ::EntityId entityId, [[maybe_unused]] const AZ::Aabb& oldRegion, const AZ::Aabb& newRegion) - { - MacroMaterialData& materialData = FindOrCreateByEntityId(entityId, m_macroMaterials); - for (SectorData& sectorData : m_sectorData) + if (!m_heightmapImage || m_heightmapImage->GetDescriptor().m_size != heightmapSize) { - bool overlapsOld = sectorData.m_aabb.Overlaps(materialData.m_bounds); - bool overlapsNew = sectorData.m_aabb.Overlaps(newRegion); - if (overlapsOld && !overlapsNew) - { - // Remove the macro material from this sector - for (uint16_t& idx : sectorData.m_macroMaterials) - { - if (m_macroMaterials.GetData(idx).m_entityId == entityId) - { - idx = sectorData.m_macroMaterials.back(); - sectorData.m_macroMaterials.pop_back(); - } - } - } - else if (overlapsNew && !overlapsOld) - { - // Add the macro material to this sector - if (sectorData.m_macroMaterials.size() < MaxMaterialsPerSector) - { - sectorData.m_macroMaterials.push_back(m_macroMaterials.GetIndexForData(&materialData)); - } - } - } - m_areaData.m_macroMaterialsUpdated = true; - materialData.m_bounds = newRegion; - } + const AZ::Data::Instance imagePool = AZ::RPI::ImageSystemInterface::Get()->GetSystemAttachmentPool(); + AZ::RHI::ImageDescriptor imageDescriptor = AZ::RHI::ImageDescriptor::Create2D( + AZ::RHI::ImageBindFlags::ShaderRead, heightmapSize.m_width, heightmapSize.m_height, AZ::RHI::Format::R16_UNORM + ); - void TerrainFeatureProcessor::OnTerrainMacroMaterialDestroyed(AZ::EntityId entityId) - { - const MacroMaterialData* materialData = FindByEntityId(entityId, m_macroMaterials); + const AZ::Name TerrainHeightmapName = AZ::Name(TerrainHeightmapChars); + m_heightmapImage = AZ::RPI::AttachmentImage::Create(*imagePool.get(), imageDescriptor, TerrainHeightmapName, nullptr, nullptr); + AZ_Error(TerrainFPName, m_heightmapImage, "Failed to initialize the heightmap image."); + + // World size changed, so the whole height map needs updating. + m_dirtyRegion = m_terrainBounds; + m_imageBindingsNeedUpdate = true; + } - if (materialData) + if (!m_dirtyRegion.IsValid()) { - uint16_t destroyedMaterialIndex = m_macroMaterials.GetIndexForData(materialData); - ForOverlappingSectors(materialData->m_bounds, - [&](SectorData& sectorData) { - for (uint16_t& idx : sectorData.m_macroMaterials) - { - if (idx == destroyedMaterialIndex) - { - idx = sectorData.m_macroMaterials.back(); - sectorData.m_macroMaterials.pop_back(); - } - } - }); + return; } - m_areaData.m_macroMaterialsUpdated = true; - RemoveByEntityId(entityId, m_macroMaterials); - } - - void TerrainFeatureProcessor::OnTerrainSurfaceMaterialMappingCreated(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag, MaterialInstance material) - { - DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); + int32_t xStart = aznumeric_cast(AZStd::ceilf(m_dirtyRegion.GetMin().GetX() / m_sampleSpacing)); + int32_t xEnd = aznumeric_cast(AZStd::floorf(m_dirtyRegion.GetMax().GetX() / m_sampleSpacing)) + 1; + int32_t yStart = aznumeric_cast(AZStd::ceilf(m_dirtyRegion.GetMin().GetY() / m_sampleSpacing)); + int32_t yEnd = aznumeric_cast(AZStd::floorf(m_dirtyRegion.GetMax().GetY() / m_sampleSpacing)) + 1; + uint32_t updateWidth = xEnd - xStart; + uint32_t updateHeight = yEnd - yStart; - // Validate that the surface tag is new - for (DetailMaterialSurface& surface : materialRegion.m_materialsForSurfaces) + AZStd::vector pixels; + pixels.reserve(updateWidth * updateHeight); { - if (surface.m_surfaceTag == surfaceTag) - { - AZ_Error(TerrainFPName, false, "Already have a surface material mapping for this surface tag."); - return; - } - } - - uint16_t detailMaterialId = CreateOrUpdateDetailMaterial(material); - materialRegion.m_materialsForSurfaces.push_back({ surfaceTag, detailMaterialId }); - m_detailMaterials.GetData(detailMaterialId).refCount++; - m_dirtyDetailRegion.AddAabb(materialRegion.m_region); - } - - void TerrainFeatureProcessor::OnRenderPipelinePassesChanged([[maybe_unused]] AZ::RPI::RenderPipeline* renderPipeline) - { - CacheForwardPass(); - } + // Block other threads from accessing the surface data bus while we are in GetHeightFromFloats (which may call into the SurfaceData bus). + // We lock our surface data mutex *before* checking / setting "isRequestInProgress" so that we prevent race conditions + // that create false detection of cyclic dependencies when multiple requests occur on different threads simultaneously. + // (One case where this was previously able to occur was in rapid updating of the Preview widget on the + // GradientSurfaceDataComponent in the Editor when moving the threshold sliders back and forth rapidly) - void TerrainFeatureProcessor::CheckDetailMaterialForDeletion(uint16_t detailMaterialId) - { - auto& detailMaterialData = m_detailMaterials.GetData(detailMaterialId); - if (--detailMaterialData.refCount == 0) - { - uint16_t bufferIndex = detailMaterialData.m_detailMaterialBufferIndex; - DetailMaterialShaderData& shaderData = m_detailMaterialShaderData.GetElement(bufferIndex); + auto& surfaceDataContext = SurfaceData::SurfaceDataSystemRequestBus::GetOrCreateContext(false); + typename SurfaceData::SurfaceDataSystemRequestBus::Context::DispatchLockGuard scopeLock(surfaceDataContext.m_contextMutex); - for (uint16_t imageIndex : - { - shaderData.m_colorImageIndex, - shaderData.m_normalImageIndex, - shaderData.m_roughnessImageIndex, - shaderData.m_metalnessImageIndex, - shaderData.m_specularF0ImageIndex, - shaderData.m_occlusionImageIndex, - shaderData.m_heightImageIndex - }) + for (int32_t y = yStart; y < yEnd; y++) { - if (imageIndex != InvalidDetailImageIndex) + for (int32_t x = xStart; x < xEnd; x++) { - m_detailImageViews.at(imageIndex) = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::Magenta)->GetImageView(); - m_detailImageViewFreeList.push_back(imageIndex); - m_detailImagesNeedUpdate = true; - } - } - - m_detailMaterialShaderData.Release(bufferIndex); - m_detailMaterials.RemoveIndex(detailMaterialId); - } - } - - void TerrainFeatureProcessor::OnTerrainSurfaceMaterialMappingDestroyed(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag) - { - DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); + bool terrainExists = true; + float terrainHeight = 0.0f; + float xPos = x * m_sampleSpacing; + float yPos = y * m_sampleSpacing; + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + terrainHeight, &AzFramework::Terrain::TerrainDataRequests::GetHeightFromFloats, + xPos, yPos, AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT, &terrainExists); - for (DetailMaterialSurface& surface : materialRegion.m_materialsForSurfaces) - { - if (surface.m_surfaceTag == surfaceTag) - { - CheckDetailMaterialForDeletion(surface.m_detailMaterialId); + const float clampedHeight = AZ::GetClamp((terrainHeight - m_terrainBounds.GetMin().GetZ()) / m_terrainBounds.GetExtents().GetZ(), 0.0f, 1.0f); + const float expandedHeight = AZStd::roundf(clampedHeight * AZStd::numeric_limits::max()); + const uint16_t uint16Height = aznumeric_cast(expandedHeight); - if (surface.m_surfaceTag != materialRegion.m_materialsForSurfaces.back().m_surfaceTag) - { - AZStd::swap(surface, materialRegion.m_materialsForSurfaces.back()); + pixels.push_back(uint16Height); } - materialRegion.m_materialsForSurfaces.pop_back(); - m_dirtyDetailRegion.AddAabb(materialRegion.m_region); - return; } } - AZ_Error(TerrainFPName, false, "Could not find surface tag to destroy for OnTerrainSurfaceMaterialMappingDestroyed()."); - } - - void TerrainFeatureProcessor::OnTerrainSurfaceMaterialMappingChanged(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag, MaterialInstance material) - { - DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); - bool found = false; - uint16_t materialId = CreateOrUpdateDetailMaterial(material); - for (DetailMaterialSurface& surface : materialRegion.m_materialsForSurfaces) + if (m_heightmapImage) { - if (surface.m_surfaceTag == surfaceTag) - { - found = true; - if (surface.m_detailMaterialId != materialId) - { - ++m_detailMaterials.GetData(materialId).refCount; - CheckDetailMaterialForDeletion(surface.m_detailMaterialId); - surface.m_detailMaterialId = materialId; - } - break; - } - } + constexpr uint32_t BytesPerPixel = sizeof(uint16_t); + const float left = xStart - (m_terrainBounds.GetMin().GetX() / m_sampleSpacing); + const float top = yStart - (m_terrainBounds.GetMin().GetY() / m_sampleSpacing); - if (!found) - { - ++m_detailMaterials.GetData(materialId).refCount; - materialRegion.m_materialsForSurfaces.push_back({ surfaceTag, materialId }); - } - m_dirtyDetailRegion.AddAabb(materialRegion.m_region); - } + AZ::RHI::ImageUpdateRequest imageUpdateRequest; + imageUpdateRequest.m_imageSubresourcePixelOffset.m_left = aznumeric_cast(left); + imageUpdateRequest.m_imageSubresourcePixelOffset.m_top = aznumeric_cast(top); + imageUpdateRequest.m_sourceSubresourceLayout.m_bytesPerRow = updateWidth * BytesPerPixel; + imageUpdateRequest.m_sourceSubresourceLayout.m_bytesPerImage = updateWidth * updateHeight * BytesPerPixel; + imageUpdateRequest.m_sourceSubresourceLayout.m_rowCount = updateHeight; + imageUpdateRequest.m_sourceSubresourceLayout.m_size = AZ::RHI::Size(updateWidth, updateHeight, 1); + imageUpdateRequest.m_sourceData = pixels.data(); + imageUpdateRequest.m_image = m_heightmapImage->GetRHIImage(); - void TerrainFeatureProcessor::OnTerrainSurfaceMaterialMappingRegionChanged(AZ::EntityId entityId, const AZ::Aabb& oldRegion, const AZ::Aabb& newRegion) - { - DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); - materialRegion.m_region = newRegion; - m_dirtyDetailRegion.AddAabb(oldRegion); - m_dirtyDetailRegion.AddAabb(newRegion); + m_heightmapImage->UpdateImageContents(imageUpdateRequest); + } + + m_dirtyRegion = AZ::Aabb::CreateNull(); } - uint16_t TerrainFeatureProcessor::CreateOrUpdateDetailMaterial(MaterialInstance material) + void TerrainFeatureProcessor::PrepareMaterialData() { - static constexpr uint16_t InvalidDetailMaterial = 0xFFFF; - uint16_t detailMaterialId = InvalidDetailMaterial; + m_terrainSrg = {}; - for (auto& detailMaterialData : m_detailMaterials.GetDataVector()) + for (auto& shaderItem : m_materialInstance->GetShaderCollection()) { - if (detailMaterialData.m_assetId == material->GetAssetId()) + if (shaderItem.GetShaderAsset()->GetDrawListName() == AZ::Name("forward")) { - detailMaterialId = m_detailMaterials.GetIndexForData(&detailMaterialData); - UpdateDetailMaterialData(detailMaterialId, material); + const auto& shaderAsset = shaderItem.GetShaderAsset(); + m_terrainSrg = AZ::RPI::ShaderResourceGroup::Create(shaderItem.GetShaderAsset(), shaderAsset->GetSupervariantIndex(AZ::Name()), AZ::Name{"TerrainSrg"}); + AZ_Error(TerrainFPName, m_terrainSrg, "Failed to create Terrain shader resource group"); break; } } - AZ_Assert(m_detailMaterialShaderData.GetSize() < 0xFF, "Only 255 detail materials supported."); - - if (detailMaterialId == InvalidDetailMaterial && m_detailMaterialShaderData.GetSize() < 0xFF) - { - detailMaterialId = m_detailMaterials.GetFreeSlotIndex(); - auto& detailMaterialData = m_detailMaterials.GetData(detailMaterialId); - detailMaterialData.m_detailMaterialBufferIndex = aznumeric_cast(m_detailMaterialShaderData.Reserve()); - UpdateDetailMaterialData(detailMaterialId, material); - } - return detailMaterialId; - } - - void TerrainFeatureProcessor::UpdateDetailMaterialData(uint16_t detailMaterialIndex, MaterialInstance material) - { - DetailMaterialData& materialData = m_detailMaterials.GetData(detailMaterialIndex); - DetailMaterialShaderData& shaderData = m_detailMaterialShaderData.GetElement(materialData.m_detailMaterialBufferIndex); - - if (materialData.m_materialChangeId == material->GetCurrentChangeId()) - { - return; // material hasn't changed, nothing to do - } - - materialData.m_materialChangeId = material->GetCurrentChangeId(); - materialData.m_assetId = material->GetAssetId(); - - DetailTextureFlags& flags = shaderData.m_flags; - - auto getIndex = [&](const char* const indexName) -> AZ::RPI::MaterialPropertyIndex - { - const AZ::RPI::MaterialPropertyIndex index = material->FindPropertyIndex(AZ::Name(indexName)); - AZ_Warning(TerrainFPName, index.IsValid(), "Failed to find shader input constant %s.", indexName); - return index; - }; - - auto applyProperty = [&](const char* const indexName, auto& ref) -> void - { - const auto index = getIndex(indexName); - if (index.IsValid()) - { - // GetValue() expects the actaul type, not a reference type, so the reference needs to be removed. - using TypeRefRemoved = AZStd::remove_cvref_t; - ref = material->GetPropertyValue(index).GetValue(); - } - }; + AZ_Error(TerrainFPName, m_terrainSrg, "Terrain Srg not found on any shader in the terrain material"); - auto applyImage = [&](const char* const indexName, AZ::Data::Instance& ref, const char* const usingFlagName, DetailTextureFlags flagToSet, uint16_t& imageIndex) -> void + if (m_terrainSrg) { - // Determine if an image exists and if its using flag allows it to be used. - const auto index = getIndex(indexName); - const auto useTextureIndex = getIndex(usingFlagName); - bool useTextureValue = true; - if (useTextureIndex.IsValid()) + if (m_imageArrayHandler->IsInitialized()) { - useTextureValue = material->GetPropertyValue(useTextureIndex).GetValue(); + m_imageArrayHandler->UpdateSrgIndices(m_terrainSrg, AZ::Name(TerrainSrgInputs::Textures)); } - if (index.IsValid() && useTextureValue) + else { - ref = material->GetPropertyValue(index).GetValue>(); + m_imageArrayHandler->Initialize(m_terrainSrg, AZ::Name(TerrainSrgInputs::Textures)); } - useTextureValue = useTextureValue && ref; - flags = DetailTextureFlags(useTextureValue ? (flags | flagToSet) : (flags & ~flagToSet)); - // Update queues to add/remove textures depending on if the image is used - if (ref) + if (m_macroMaterialManager.IsInitialized()) { - if (imageIndex == InvalidDetailImageIndex) - { - if (m_detailImageViewFreeList.size() > 0) - { - imageIndex = m_detailImageViewFreeList.back(); - m_detailImageViewFreeList.pop_back(); - } - else - { - imageIndex = aznumeric_cast(m_detailImageViews.size()); - m_detailImageViews.push_back(); - } - } - m_detailImageViews.at(imageIndex) = ref->GetImageView(); - m_detailImagesNeedUpdate = true; + m_macroMaterialManager.UpdateSrgIndices(m_terrainSrg); } - else if (imageIndex != InvalidDetailImageIndex) + else { - m_detailImageViews.at(imageIndex) = AZ::RPI::ImageSystemInterface::Get()->GetSystemImage(AZ::RPI::SystemImage::Magenta)->GetImageView(); - m_detailImageViewFreeList.push_back(imageIndex); - m_detailImagesNeedUpdate = true; - imageIndex = InvalidDetailImageIndex; + m_macroMaterialManager.Initialize(m_imageArrayHandler, m_terrainSrg); } - }; - auto applyFlag = [&](const char* const indexName, DetailTextureFlags flagToSet) -> void - { - const auto index = getIndex(indexName); - if (index.IsValid()) + if (m_detailMaterialManager.IsInitialized()) { - bool flagValue = material->GetPropertyValue(index).GetValue(); - flags = DetailTextureFlags(flagValue ? flags | flagToSet : flags); + m_detailMaterialManager.UpdateSrgIndices(m_terrainSrg); } - }; - - auto getEnumName = [&](const char* const indexName) -> const AZStd::string_view - { - const auto index = getIndex(indexName); - if (index.IsValid()) + else { - uint32_t enumIndex = material->GetPropertyValue(index).GetValue(); - const AZ::Name& enumName = material->GetMaterialPropertiesLayout()->GetPropertyDescriptor(index)->GetEnumName(enumIndex); - return enumName.GetStringView(); + m_detailMaterialManager.Initialize(m_imageArrayHandler, m_terrainSrg); } - return ""; - }; - - using namespace DetailMaterialInputs; - applyImage(BaseColorMap, materialData.m_colorImage, BaseColorUseTexture, DetailTextureFlags::UseTextureBaseColor, shaderData.m_colorImageIndex); - applyProperty(BaseColorFactor, shaderData.m_baseColorFactor); - - const auto index = getIndex(BaseColorColor); - if (index.IsValid()) - { - AZ::Color baseColor = material->GetPropertyValue(index).GetValue(); - shaderData.m_baseColorRed = baseColor.GetR(); - shaderData.m_baseColorGreen = baseColor.GetG(); - shaderData.m_baseColorBlue = baseColor.GetB(); - } - - const AZStd::string_view& blendModeString = getEnumName(BaseColorBlendMode); - if (blendModeString == "Multiply") - { - flags = DetailTextureFlags(flags | DetailTextureFlags::BlendModeMultiply); - } - else if (blendModeString == "LinearLight") - { - flags = DetailTextureFlags(flags | DetailTextureFlags::BlendModeLinearLight); - } - else if (blendModeString == "Lerp") - { - flags = DetailTextureFlags(flags | DetailTextureFlags::BlendModeLerp); - } - else if (blendModeString == "Overlay") - { - flags = DetailTextureFlags(flags | DetailTextureFlags::BlendModeOverlay); - } - - applyImage(MetallicMap, materialData.m_metalnessImage, MetallicUseTexture, DetailTextureFlags::UseTextureMetallic, shaderData.m_metalnessImageIndex); - applyProperty(MetallicFactor, shaderData.m_metalFactor); - - applyImage(RoughnessMap, materialData.m_roughnessImage, RoughnessUseTexture, DetailTextureFlags::UseTextureRoughness, shaderData.m_roughnessImageIndex); - - if ((flags & DetailTextureFlags::UseTextureRoughness) > 0) - { - float lowerBound = 0.0; - float upperBound = 1.0; - applyProperty(RoughnessLowerBound, lowerBound); - applyProperty(RoughnessUpperBound, upperBound); - shaderData.m_roughnessBias = lowerBound; - shaderData.m_roughnessScale = upperBound - lowerBound; } else { - shaderData.m_roughnessBias = 0.0; - applyProperty(RoughnessFactor, shaderData.m_roughnessScale); + m_imageArrayHandler->Reset(); + m_macroMaterialManager.Reset(); + m_detailMaterialManager.Reset(); } - - applyImage(SpecularF0Map, materialData.m_specularF0Image, SpecularF0UseTexture, DetailTextureFlags::UseTextureSpecularF0, shaderData.m_specularF0ImageIndex); - applyProperty(SpecularF0Factor, shaderData.m_specularF0Factor); - - applyImage(NormalMap, materialData.m_normalImage, NormalUseTexture, DetailTextureFlags::UseTextureNormal, shaderData.m_normalImageIndex); - applyProperty(NormalFactor, shaderData.m_normalFactor); - applyFlag(NormalFlipX, DetailTextureFlags::FlipNormalX); - applyFlag(NormalFlipY, DetailTextureFlags::FlipNormalY); - - applyImage(DiffuseOcclusionMap, materialData.m_occlusionImage, DiffuseOcclusionUseTexture, DetailTextureFlags::UseTextureOcclusion, shaderData.m_occlusionImageIndex); - applyProperty(DiffuseOcclusionFactor, shaderData.m_occlusionFactor); - - applyImage(HeightMap, materialData.m_heightImage, HeightUseTexture, DetailTextureFlags::UseTextureHeight, shaderData.m_heightImageIndex); - applyProperty(HeightFactor, shaderData.m_heightFactor); - applyProperty(HeightOffset, shaderData.m_heightOffset); - applyProperty(HeightBlendFactor, shaderData.m_heightBlendFactor); - - m_updateDetailMaterialBuffer = true; } - void TerrainFeatureProcessor::CheckUpdateDetailTexture(const Aabb2i& newBounds, const Vector2i& newCenter) + void TerrainFeatureProcessor::ProcessSurfaces(const FeatureProcessor::RenderPacket& process) { - if (!m_detailTextureImage) + AZ_PROFILE_FUNCTION(AzRender); + + if (!m_terrainBounds.IsValid()) { - // If the m_detailTextureImage doesn't exist, create it and populate the entire texture - - const AZ::Data::Instance imagePool = AZ::RPI::ImageSystemInterface::Get()->GetSystemAttachmentPool(); - AZ::RHI::ImageDescriptor imageDescriptor = AZ::RHI::ImageDescriptor::Create2D( - AZ::RHI::ImageBindFlags::ShaderRead, DetailTextureSize, DetailTextureSize, AZ::RHI::Format::R8G8B8A8_UINT - ); - const AZ::Name TerrainDetailName = AZ::Name(TerrainDetailChars); - m_detailTextureImage = AZ::RPI::AttachmentImage::Create(*imagePool.get(), imageDescriptor, TerrainDetailName, nullptr, nullptr); - AZ_Error(TerrainFPName, m_detailTextureImage, "Failed to initialize the detail texture image."); - - UpdateDetailTexture(newBounds, newBounds, newCenter); + return; } - else - { - // If the new bounds of the detail texture are different than the old bounds, then the edges of the texture need to be updated. - int32_t offsetX = m_detailTextureBounds.m_min.m_x - newBounds.m_min.m_x; - - // Horizontal edge update - if (newBounds.m_min.m_x != m_detailTextureBounds.m_min.m_x) + if (m_materialInstance && m_materialInstance->CanCompile()) + { + AZ::Vector3 cameraPosition = AZ::Vector3::CreateZero(); + for (auto& view : process.m_views) { - Aabb2i updateBounds; - if (newBounds.m_min.m_x < m_detailTextureBounds.m_min.m_x) + if ((view->GetUsageFlags() & AZ::RPI::View::UsageFlags::UsageCamera) > 0) { - updateBounds.m_min.m_x = newBounds.m_min.m_x; - updateBounds.m_max.m_x = m_detailTextureBounds.m_min.m_x; + cameraPosition = view->GetCameraTransform().GetTranslation(); + break; } - else - { - updateBounds.m_min.m_x = m_detailTextureBounds.m_max.m_x; - updateBounds.m_max.m_x = newBounds.m_max.m_x; + } + + if (m_meshManager.IsInitialized()) + { + bool surfacesRebuilt = false; + surfacesRebuilt = m_meshManager.CheckRebuildSurfaces(m_materialInstance, *GetParentScene()); + if (m_forceRebuildDrawPackets && !surfacesRebuilt) + { + m_meshManager.RebuildDrawPackets(*GetParentScene()); } - updateBounds.m_min.m_y = newBounds.m_min.m_y; - updateBounds.m_max.m_y = newBounds.m_max.m_y; - UpdateDetailTexture(updateBounds, newBounds, newCenter); + m_forceRebuildDrawPackets = false; } - // Vertical edge update - if (newBounds.m_min.m_y != m_detailTextureBounds.m_min.m_y) + if (m_terrainSrg) { - Aabb2i updateBounds; - // Don't update areas that have already been updated in the horizontal update. - updateBounds.m_min.m_x = newBounds.m_min.m_x + AZ::GetMax(0, offsetX); - updateBounds.m_max.m_x = newBounds.m_max.m_x + AZ::GetMin(0, offsetX); - if (newBounds.m_min.m_y < m_detailTextureBounds.m_min.m_y) + if (m_macroMaterialManager.IsInitialized()) { - updateBounds.m_min.m_y = newBounds.m_min.m_y; - updateBounds.m_max.m_y = m_detailTextureBounds.m_min.m_y; + m_macroMaterialManager.Update(m_terrainSrg); } - else + + if (m_detailMaterialManager.IsInitialized()) { - updateBounds.m_min.m_y = m_detailTextureBounds.m_max.m_y; - updateBounds.m_max.m_y = newBounds.m_max.m_y; + m_detailMaterialManager.Update(cameraPosition, m_terrainSrg); } - UpdateDetailTexture(updateBounds, newBounds, newCenter); } - if (m_dirtyDetailRegion.IsValid()) + if (m_heightmapNeedsUpdate) { - // If any regions are marked as dirty, then they should be updated. - - AZ::Vector3 currentMin = AZ::Vector3(newBounds.m_min.m_x * DetailTextureScale, newBounds.m_min.m_y * DetailTextureScale, -0.5f); - AZ::Vector3 currentMax = AZ::Vector3(newBounds.m_max.m_x * DetailTextureScale, newBounds.m_max.m_y * DetailTextureScale, 0.5f); - AZ::Aabb detailTextureCoverage = AZ::Aabb::CreateFromMinMax(currentMin, currentMax); - AZ::Vector3 previousMin = AZ::Vector3(m_detailTextureBounds.m_min.m_x * DetailTextureScale, m_detailTextureBounds.m_min.m_y * DetailTextureScale, -0.5f); - AZ::Vector3 previousMax = AZ::Vector3(m_detailTextureBounds.m_max.m_x * DetailTextureScale, m_detailTextureBounds.m_max.m_y * DetailTextureScale, 0.5f); - AZ::Aabb previousCoverage = AZ::Aabb::CreateFromMinMax(previousMin, previousMax); - - // Area of texture not already updated by camera movement above. - AZ::Aabb clampedCoverage = previousCoverage.GetClamped(detailTextureCoverage); - - // Clamp the dirty region to the area of the detail texture that is visible and not already updated. - clampedCoverage.Clamp(m_dirtyDetailRegion); - - if (clampedCoverage.IsValid()) - { - Aabb2i updateBounds; - updateBounds.m_min.m_x = aznumeric_cast(AZStd::roundf(clampedCoverage.GetMin().GetX() / DetailTextureScale)); - updateBounds.m_min.m_y = aznumeric_cast(AZStd::roundf(clampedCoverage.GetMin().GetY() / DetailTextureScale)); - updateBounds.m_max.m_x = aznumeric_cast(AZStd::roundf(clampedCoverage.GetMax().GetX() / DetailTextureScale)); - updateBounds.m_max.m_y = aznumeric_cast(AZStd::roundf(clampedCoverage.GetMax().GetY() / DetailTextureScale)); - if (updateBounds.m_min.m_x < updateBounds.m_max.m_x && updateBounds.m_min.m_y < updateBounds.m_max.m_y) - { - UpdateDetailTexture(updateBounds, newBounds, newCenter); - } - } + UpdateHeightmapImage(); + m_heightmapNeedsUpdate = false; + } + + if (m_imageArrayHandler->IsInitialized()) + { + bool result [[maybe_unused]] = m_imageArrayHandler->UpdateSrg(m_terrainSrg); + AZ_Error(TerrainFPName, result, "Failed to set image view unbounded array into shader resource group."); } } + + if (m_meshManager.IsInitialized()) + { + m_meshManager.DrawMeshes(process); + } - } - - uint8_t TerrainFeatureProcessor::CalculateUpdateRegions(const Aabb2i& updateArea, const Aabb2i& textureBounds, const Vector2i& centerPixel, - AZStd::array& textureSpaceAreas, AZStd::array& scaledWorldSpaceAreas) - { - Vector2i centerOffset = { centerPixel.m_x - DetailTextureSizeHalf, centerPixel.m_y - DetailTextureSizeHalf }; - - int32_t quadrantXOffset = centerPixel.m_x < DetailTextureSizeHalf ? DetailTextureSize : -DetailTextureSize; - int32_t quadrantYOffset = centerPixel.m_y < DetailTextureSizeHalf ? DetailTextureSize : -DetailTextureSize; - - uint8_t numQuadrants = 0; - - // For each of the 4 quadrants: - auto calculateQuadrant = [&](Vector2i quadrantOffset) + if (m_heightmapImage && m_imageBindingsNeedUpdate) { - Aabb2i offsetUpdateArea = updateArea + centerOffset + quadrantOffset; - Aabb2i updateSectionBounds = textureBounds.GetClamped(offsetUpdateArea); - if (updateSectionBounds.IsValid()) - { - textureSpaceAreas[numQuadrants] = updateSectionBounds - textureBounds.m_min; - scaledWorldSpaceAreas[numQuadrants] = updateSectionBounds - centerOffset - quadrantOffset; - ++numQuadrants; - } - }; + WorldShaderData worldData; + m_terrainBounds.GetMin().StoreToFloat3(worldData.m_min.data()); + m_terrainBounds.GetMax().StoreToFloat3(worldData.m_max.data()); - calculateQuadrant({ 0, 0 }); - calculateQuadrant({ quadrantXOffset, 0 }); - calculateQuadrant({ 0, quadrantYOffset }); - calculateQuadrant({ quadrantXOffset, quadrantYOffset }); + m_imageBindingsNeedUpdate = false; - return numQuadrants; - } + auto sceneSrg = GetParentScene()->GetShaderResourceGroup(); + sceneSrg->SetImage(m_heightmapPropertyIndex, m_heightmapImage); + sceneSrg->SetConstant(m_worldDataIndex, worldData); + } - void TerrainFeatureProcessor::UpdateDetailTexture(const Aabb2i& updateArea, const Aabb2i& textureBounds, const Vector2i& centerPixel) - { - if (!m_detailTextureImage) + if (m_materialInstance) { - return; + m_materialInstance->Compile(); } - struct DetailMaterialPixel + if (m_terrainSrg && m_forwardPass) { - uint8_t m_material1{ 255 }; - uint8_t m_material2{ 255 }; - uint8_t m_blend{ 0 }; // 0 = full weight on material1, 255 = full weight on material2 - uint8_t m_padding{ 0 }; - }; + m_terrainSrg->Compile(); + m_forwardPass->BindSrg(m_terrainSrg->GetRHIShaderResourceGroup()); + } + } - // Because the center of the detail texture may be offset, each update area may actually need to be split into - // up to 4 separate update areas in each sector of the quadrant. - AZStd::array textureSpaceAreas; - AZStd::array scaledWorldSpaceAreas; - uint8_t updateAreaCount = CalculateUpdateRegions(updateArea, textureBounds, centerPixel, textureSpaceAreas, scaledWorldSpaceAreas); - - // Pull the data for each area updated and use it to construct an update for the detail material id texture. - for (uint8_t i = 0; i < updateAreaCount; ++i) - { - const Aabb2i& quadrantTextureArea = textureSpaceAreas[i]; - const Aabb2i& quadrantWorldArea = scaledWorldSpaceAreas[i]; - - AZStd::vector pixels; - pixels.resize((quadrantWorldArea.m_max.m_x - quadrantWorldArea.m_min.m_x) * (quadrantWorldArea.m_max.m_y - quadrantWorldArea.m_min.m_y)); - uint32_t index = 0; - - for (int yPos = quadrantWorldArea.m_min.m_y; yPos < quadrantWorldArea.m_max.m_y; ++yPos) - { - for (int xPos = quadrantWorldArea.m_min.m_x; xPos < quadrantWorldArea.m_max.m_x; ++xPos) - { - AZ::Vector2 position = AZ::Vector2(xPos * DetailTextureScale, yPos * DetailTextureScale); - AzFramework::SurfaceData::SurfaceTagWeightList surfaceWeights; - AzFramework::Terrain::TerrainDataRequestBus::Broadcast(&AzFramework::Terrain::TerrainDataRequests::GetSurfaceWeightsFromVector2, position, surfaceWeights, AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT, nullptr); - - // Store the top two surface weights in the texture with m_blend storing the relative weight. - bool isFirstMaterial = true; - float firstWeight = 0.0f; - for (const auto& surfaceTagWeight : surfaceWeights) - { - if (surfaceTagWeight.m_weight > 0.0f) - { - AZ::Crc32 surfaceType = surfaceTagWeight.m_surfaceType; - uint16_t materialId = GetDetailMaterialForSurfaceTypeAndPosition(surfaceType, position); - if (materialId != m_detailMaterials.NoFreeSlot && materialId < 255) - { - if (isFirstMaterial) - { - pixels.at(index).m_material1 = aznumeric_cast(materialId); - firstWeight = surfaceTagWeight.m_weight; - // m_blend only needs to be calculated is material 2 is found, otherwise the initial value of 0 is correct. - isFirstMaterial = false; - } - else - { - pixels.at(index).m_material2 = aznumeric_cast(materialId); - float totalWeight = firstWeight + surfaceTagWeight.m_weight; - float blendWeight = 1.0f - (firstWeight / totalWeight); - pixels.at(index).m_blend = aznumeric_cast(AZStd::round(blendWeight * 255.0f)); - break; - } - } - } - else - { - break; // since the list is ordered, no other materials are in the list with positive weights. - } - } - ++index; - } - } - - const int32_t left = quadrantTextureArea.m_min.m_x; - const int32_t top = quadrantTextureArea.m_min.m_y; - const int32_t width = quadrantTextureArea.m_max.m_x - quadrantTextureArea.m_min.m_x; - const int32_t height = quadrantTextureArea.m_max.m_y - quadrantTextureArea.m_min.m_y; - - AZ::RHI::ImageUpdateRequest imageUpdateRequest; - imageUpdateRequest.m_imageSubresourcePixelOffset.m_left = aznumeric_cast(left); - imageUpdateRequest.m_imageSubresourcePixelOffset.m_top = aznumeric_cast(top); - imageUpdateRequest.m_sourceSubresourceLayout.m_bytesPerRow = width * sizeof(DetailMaterialPixel); - imageUpdateRequest.m_sourceSubresourceLayout.m_bytesPerImage = width * height * sizeof(DetailMaterialPixel); - imageUpdateRequest.m_sourceSubresourceLayout.m_rowCount = height; - imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_width = width; - imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_height = height; - imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_depth = 1; - imageUpdateRequest.m_sourceData = pixels.data(); - imageUpdateRequest.m_image = m_detailTextureImage->GetRHIImage(); - - m_detailTextureImage->UpdateImageContents(imageUpdateRequest); - } - } - - uint16_t TerrainFeatureProcessor::GetDetailMaterialForSurfaceTypeAndPosition(AZ::Crc32 surfaceType, const AZ::Vector2& position) - { - for (const auto& materialRegion : m_detailMaterialRegions.GetDataVector()) - { - if (materialRegion.m_region.Contains(AZ::Vector3(position.GetX(), position.GetY(), 0.0f))) - { - for (const auto& materialSurface : materialRegion.m_materialsForSurfaces) - { - if (materialSurface.m_surfaceTag == surfaceType) - { - return m_detailMaterials.GetData(materialSurface.m_detailMaterialId).m_detailMaterialBufferIndex; - } - } - } - } - return m_detailMaterials.NoFreeSlot; - } - - void TerrainFeatureProcessor::UpdateTerrainData() - { - - const float queryResolution = m_areaData.m_sampleSpacing; - const AZ::Aabb& worldBounds = m_areaData.m_terrainBounds; - - int32_t heightmapImageXStart = aznumeric_cast(AZStd::ceilf(worldBounds.GetMin().GetX() / queryResolution)); - int32_t heightmapImageXEnd = aznumeric_cast(AZStd::floorf(worldBounds.GetMax().GetX() / queryResolution)) + 1; - int32_t heightmapImageYStart = aznumeric_cast(AZStd::ceilf(worldBounds.GetMin().GetY() / queryResolution)); - int32_t heightmapImageYEnd = aznumeric_cast(AZStd::floorf(worldBounds.GetMax().GetY() / queryResolution)) + 1; - uint32_t heightmapImageWidth = heightmapImageXEnd - heightmapImageXStart; - uint32_t heightmapImageHeight = heightmapImageYEnd - heightmapImageYStart; - - const AZ::RHI::Size heightmapSize = AZ::RHI::Size(heightmapImageWidth, heightmapImageHeight, 1); - - if (!m_areaData.m_heightmapImage || m_areaData.m_heightmapImage->GetDescriptor().m_size != heightmapSize) - { - const AZ::Data::Instance imagePool = AZ::RPI::ImageSystemInterface::Get()->GetSystemAttachmentPool(); - AZ::RHI::ImageDescriptor imageDescriptor = AZ::RHI::ImageDescriptor::Create2D( - AZ::RHI::ImageBindFlags::ShaderRead, heightmapSize.m_width, heightmapSize.m_height, AZ::RHI::Format::R16_UNORM - ); - - const AZ::Name TerrainHeightmapName = AZ::Name(TerrainHeightmapChars); - m_areaData.m_heightmapImage = AZ::RPI::AttachmentImage::Create(*imagePool.get(), imageDescriptor, TerrainHeightmapName, nullptr, nullptr); - AZ_Error(TerrainFPName, m_areaData.m_heightmapImage, "Failed to initialize the heightmap image."); - - // World size changed, so the whole height map needs updating. - m_dirtyRegion = worldBounds; - m_imagesNeedUpdate = true; - } - - int32_t xStart = aznumeric_cast(AZStd::ceilf(m_dirtyRegion.GetMin().GetX() / queryResolution)); - int32_t xEnd = aznumeric_cast(AZStd::floorf(m_dirtyRegion.GetMax().GetX() / queryResolution)) + 1; - int32_t yStart = aznumeric_cast(AZStd::ceilf(m_dirtyRegion.GetMin().GetY() / queryResolution)); - int32_t yEnd = aznumeric_cast(AZStd::floorf(m_dirtyRegion.GetMax().GetY() / queryResolution)) + 1; - uint32_t updateWidth = xEnd - xStart; - uint32_t updateHeight = yEnd - yStart; - - AZStd::vector pixels; - pixels.reserve(updateWidth * updateHeight); - - { - // Block other threads from accessing the surface data bus while we are in GetHeightFromFloats (which may call into the SurfaceData bus). - // We lock our surface data mutex *before* checking / setting "isRequestInProgress" so that we prevent race conditions - // that create false detection of cyclic dependencies when multiple requests occur on different threads simultaneously. - // (One case where this was previously able to occur was in rapid updating of the Preview widget on the - // GradientSurfaceDataComponent in the Editor when moving the threshold sliders back and forth rapidly) - - auto& surfaceDataContext = SurfaceData::SurfaceDataSystemRequestBus::GetOrCreateContext(false); - typename SurfaceData::SurfaceDataSystemRequestBus::Context::DispatchLockGuard scopeLock(surfaceDataContext.m_contextMutex); - - for (int32_t y = yStart; y < yEnd; y++) - { - for (int32_t x = xStart; x < xEnd; x++) - { - bool terrainExists = true; - float terrainHeight = 0.0f; - float xPos = x * queryResolution; - float yPos = y * queryResolution; - AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( - terrainHeight, &AzFramework::Terrain::TerrainDataRequests::GetHeightFromFloats, - xPos, yPos, AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT, &terrainExists); - - const float clampedHeight = AZ::GetClamp((terrainHeight - worldBounds.GetMin().GetZ()) / worldBounds.GetExtents().GetZ(), 0.0f, 1.0f); - const float expandedHeight = AZStd::roundf(clampedHeight * AZStd::numeric_limits::max()); - const uint16_t uint16Height = aznumeric_cast(expandedHeight); - - pixels.push_back(uint16Height); - } - } - } - - if (m_areaData.m_heightmapImage) - { - constexpr uint32_t BytesPerPixel = sizeof(uint16_t); - const float left = xStart - (worldBounds.GetMin().GetX() / queryResolution); - const float top = yStart - (worldBounds.GetMin().GetY() / queryResolution); - - AZ::RHI::ImageUpdateRequest imageUpdateRequest; - imageUpdateRequest.m_imageSubresourcePixelOffset.m_left = aznumeric_cast(left); - imageUpdateRequest.m_imageSubresourcePixelOffset.m_top = aznumeric_cast(top); - imageUpdateRequest.m_sourceSubresourceLayout.m_bytesPerRow = updateWidth * BytesPerPixel; - imageUpdateRequest.m_sourceSubresourceLayout.m_bytesPerImage = updateWidth * updateHeight * BytesPerPixel; - imageUpdateRequest.m_sourceSubresourceLayout.m_rowCount = updateHeight; - imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_width = updateWidth; - imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_height = updateHeight; - imageUpdateRequest.m_sourceSubresourceLayout.m_size.m_depth = 1; - imageUpdateRequest.m_sourceData = pixels.data(); - imageUpdateRequest.m_image = m_areaData.m_heightmapImage->GetRHIImage(); - - m_areaData.m_heightmapImage->UpdateImageContents(imageUpdateRequest); - } - - m_dirtyRegion = AZ::Aabb::CreateNull(); - } - - void TerrainFeatureProcessor::PrepareMaterialData() - { - const auto layout = m_materialInstance->GetAsset()->GetObjectSrgLayout(); - - m_modelToWorldIndex = layout->FindShaderInputConstantIndex(AZ::Name(ShaderInputs::ModelToWorld)); - AZ_Error(TerrainFPName, m_modelToWorldIndex.IsValid(), "Failed to find shader input constant %s.", ShaderInputs::ModelToWorld); - - m_terrainDataIndex = layout->FindShaderInputConstantIndex(AZ::Name(ShaderInputs::TerrainData)); - AZ_Error(TerrainFPName, m_terrainDataIndex.IsValid(), "Failed to find shader input constant %s.", ShaderInputs::TerrainData); - - m_macroMaterialDataIndex = layout->FindShaderInputConstantIndex(AZ::Name(ShaderInputs::MacroMaterialData)); - AZ_Error(TerrainFPName, m_macroMaterialDataIndex.IsValid(), "Failed to find shader input constant %s.", ShaderInputs::MacroMaterialData); - - m_macroMaterialCountIndex = layout->FindShaderInputConstantIndex(AZ::Name(ShaderInputs::MacroMaterialCount)); - AZ_Error(TerrainFPName, m_macroMaterialCountIndex.IsValid(), "Failed to find shader input constant %s.", ShaderInputs::MacroMaterialCount); - - m_macroColorMapIndex = layout->FindShaderInputImageIndex(AZ::Name(ShaderInputs::MacroColorMap)); - AZ_Error(TerrainFPName, m_macroColorMapIndex.IsValid(), "Failed to find shader input constant %s.", ShaderInputs::MacroColorMap); - - m_macroNormalMapIndex = layout->FindShaderInputImageIndex(AZ::Name(ShaderInputs::MacroNormalMap)); - AZ_Error(TerrainFPName, m_macroNormalMapIndex.IsValid(), "Failed to find shader input constant %s.", ShaderInputs::MacroNormalMap); - - m_terrainSrg = {}; - for (auto& shaderItem : m_materialInstance->GetShaderCollection()) - { - if (shaderItem.GetShaderAsset()->GetDrawListName() == AZ::Name("forward")) - { - const auto& shaderAsset = shaderItem.GetShaderAsset(); - m_terrainSrg = AZ::RPI::ShaderResourceGroup::Create(shaderItem.GetShaderAsset(), shaderAsset->GetSupervariantIndex(AZ::Name()), AZ::Name{"TerrainSrg"}); - AZ_Error(TerrainFPName, m_terrainSrg, "Failed to create Terrain shader resource group"); - break; - } - } - - AZ_Error(TerrainFPName, m_terrainSrg, "Terrain Srg not found on any shader in the terrain material"); - - if (m_terrainSrg) - { - const AZ::RHI::ShaderResourceGroupLayout* terrainSrgLayout = m_terrainSrg->GetLayout(); - - m_detailMaterialIdPropertyIndex = terrainSrgLayout->FindShaderInputImageIndex(AZ::Name(TerrainSrgInputs::DetailMaterialIdImage)); - AZ_Error(TerrainFPName, m_detailMaterialIdPropertyIndex.IsValid(), "Failed to find view srg input constant %s.", TerrainSrgInputs::DetailMaterialIdImage); - - m_detailCenterPropertyIndex = terrainSrgLayout->FindShaderInputConstantIndex(AZ::Name(TerrainSrgInputs::DetailMaterialIdImageCenter)); - AZ_Error(TerrainFPName, m_detailCenterPropertyIndex.IsValid(), "Failed to find view srg input constant %s.", TerrainSrgInputs::DetailMaterialIdImageCenter); - - m_detailHalfPixelUvPropertyIndex = terrainSrgLayout->FindShaderInputConstantIndex(AZ::Name(TerrainSrgInputs::DetailHalfPixelUv)); - AZ_Error(TerrainFPName, m_detailHalfPixelUvPropertyIndex.IsValid(), "Failed to find view srg input constant %s.", TerrainSrgInputs::DetailHalfPixelUv); - - m_detailAabbPropertyIndex = terrainSrgLayout->FindShaderInputConstantIndex(AZ::Name(TerrainSrgInputs::DetailAabb)); - AZ_Error(TerrainFPName, m_detailAabbPropertyIndex.IsValid(), "Failed to find view srg input constant %s.", TerrainSrgInputs::DetailAabb); - - m_detailTexturesIndex = terrainSrgLayout->FindShaderInputImageUnboundedArrayIndex(AZ::Name(TerrainSrgInputs::DetailTextures)); - AZ_Error(TerrainFPName, m_detailTexturesIndex.IsValid(), "Failed to find view srg input constant %s.", TerrainSrgInputs::DetailTextures); - - // Set up the gpu buffer for detail material data - AZ::Render::GpuBufferHandler::Descriptor desc; - desc.m_bufferName = "Detail Material Data"; - desc.m_bufferSrgName = TerrainSrgInputs::DetailMaterialData; - desc.m_elementSize = sizeof(DetailMaterialShaderData); - desc.m_srgLayout = terrainSrgLayout; - m_detailMaterialDataBuffer = AZ::Render::GpuBufferHandler(desc); - } - - // Find any macro materials that have already been created. - TerrainMacroMaterialRequestBus::EnumerateHandlers( - [&](TerrainMacroMaterialRequests* handler) - { - MacroMaterialData macroMaterial = handler->GetTerrainMacroMaterialData(); - AZ::EntityId entityId = *(Terrain::TerrainMacroMaterialRequestBus::GetCurrentBusId()); - OnTerrainMacroMaterialCreated(entityId, macroMaterial); - return true; - } - ); - TerrainMacroMaterialNotificationBus::Handler::BusConnect(); - - // Find any detail material areas that have already been created. - TerrainAreaMaterialRequestBus::EnumerateHandlers( - [&](TerrainAreaMaterialRequests* handler) - { - const AZ::Aabb& bounds = handler->GetTerrainSurfaceMaterialRegion(); - const AZStd::vector materialMappings = handler->GetSurfaceMaterialMappings(); - AZ::EntityId entityId = *(Terrain::TerrainAreaMaterialRequestBus::GetCurrentBusId()); - - DetailMaterialListRegion& materialRegion = FindOrCreateByEntityId(entityId, m_detailMaterialRegions); - materialRegion.m_region = bounds; - - for (const auto& materialMapping : materialMappings) - { - if (materialMapping.m_materialInstance) - { - OnTerrainSurfaceMaterialMappingCreated(entityId, materialMapping.m_surfaceTag, materialMapping.m_materialInstance); - } - } - return true; - } - ); - TerrainAreaMaterialNotificationBus::Handler::BusConnect(); - - } - - void TerrainFeatureProcessor::UpdateMacroMaterialData(MacroMaterialData& macroMaterialData, const MacroMaterialData& newMaterialData) - { - macroMaterialData = newMaterialData; - - if (macroMaterialData.m_bounds.IsValid()) - { - m_areaData.m_macroMaterialsUpdated = true; - } - } - - void TerrainFeatureProcessor::ProcessSurfaces(const FeatureProcessor::RenderPacket& process) - { - AZ_PROFILE_FUNCTION(AzRender); - - const AZ::Aabb& terrainBounds = m_areaData.m_terrainBounds; - - if (!terrainBounds.IsValid()) - { - return; - } - - if (m_materialInstance && m_materialInstance->CanCompile()) - { - if (m_areaData.m_rebuildSectors) - { - // Something about the whole world changed, so the sectors need to be rebuilt - - m_areaData.m_rebuildSectors = false; - - m_sectorData.clear(); - const float xFirstPatchStart = AZStd::floorf(terrainBounds.GetMin().GetX() / GridMeters) * GridMeters; - const float xLastPatchStart = AZStd::floorf(terrainBounds.GetMax().GetX() / GridMeters) * GridMeters; - const float yFirstPatchStart = AZStd::floorf(terrainBounds.GetMin().GetY() / GridMeters) * GridMeters; - const float yLastPatchStart = AZStd::floorf(terrainBounds.GetMax().GetY() / GridMeters) * GridMeters; - - const auto& materialAsset = m_materialInstance->GetAsset(); - const auto& shaderAsset = materialAsset->GetMaterialTypeAsset()->GetShaderAssetForObjectSrg(); - - for (float yPatch = yFirstPatchStart; yPatch <= yLastPatchStart; yPatch += GridMeters) - { - for (float xPatch = xFirstPatchStart; xPatch <= xLastPatchStart; xPatch += GridMeters) - { - auto objectSrg = AZ::RPI::ShaderResourceGroup::Create(shaderAsset, materialAsset->GetObjectSrgLayout()->GetName()); - if (!objectSrg) - { - AZ_Warning(TerrainFPName, false, "Failed to create a new shader resource group, skipping."); - continue; - } - - m_sectorData.push_back(); - SectorData& sectorData = m_sectorData.back(); - - for (auto& lod : m_patchModel->GetLods()) - { - AZ::RPI::ModelLod& modelLod = *lod.get(); - sectorData.m_drawPackets.emplace_back(modelLod, 0, m_materialInstance, objectSrg); - AZ::RPI::MeshDrawPacket& drawPacket = sectorData.m_drawPackets.back(); - - // set the shader option to select forward pass IBL specular if necessary - if (!drawPacket.SetShaderOption(AZ::Name("o_meshUseForwardPassIBLSpecular"), AZ::RPI::ShaderOptionValue{ false })) - { - AZ_Warning(TerrainFPName, false, "Failed to set o_meshUseForwardPassIBLSpecular on mesh draw packet"); - } - const uint8_t stencilRef = AZ::Render::StencilRefs::UseDiffuseGIPass | AZ::Render::StencilRefs::UseIBLSpecularPass; - drawPacket.SetStencilRef(stencilRef); - drawPacket.Update(*GetParentScene(), true); - } - - sectorData.m_aabb = - AZ::Aabb::CreateFromMinMax( - AZ::Vector3(xPatch, yPatch, terrainBounds.GetMin().GetZ()), - AZ::Vector3(xPatch + GridMeters, yPatch + GridMeters, terrainBounds.GetMax().GetZ()) - ); - sectorData.m_srg = objectSrg; - } - } - - if (m_areaData.m_macroMaterialsUpdated) - { - // sectors were rebuilt, so any cached macro material data needs to be regenerated - for (SectorData& sectorData : m_sectorData) - { - for (MacroMaterialData& macroMaterialData : m_macroMaterials.GetDataVector()) - { - if (macroMaterialData.m_bounds.Overlaps(sectorData.m_aabb)) - { - sectorData.m_macroMaterials.push_back(m_macroMaterials.GetIndexForData(¯oMaterialData)); - if (sectorData.m_macroMaterials.size() == MaxMaterialsPerSector) - { - break; - } - } - } - } - } - } - else if (m_forceRebuildDrawPackets) - { - for (auto& sectorData : m_sectorData) - { - for (auto& drawPacket : sectorData.m_drawPackets) - { - drawPacket.Update(*GetParentScene(), true); - } - } - } - m_forceRebuildDrawPackets = false; - - if (m_areaData.m_heightmapUpdated) - { - UpdateTerrainData(); - } - - if (m_updateDetailMaterialBuffer) - { - m_updateDetailMaterialBuffer = false; - m_detailMaterialDataBuffer.UpdateBuffer(m_detailMaterialShaderData.GetRawData(), aznumeric_cast(m_detailMaterialShaderData.GetSize())); - } - - AZ::Vector3 cameraPosition = AZ::Vector3::CreateZero(); - for (auto& view : process.m_views) - { - if ((view->GetUsageFlags() & AZ::RPI::View::UsageFlags::UsageCamera) > 0) - { - cameraPosition = view->GetCameraTransform().GetTranslation(); - break; - } - } - - if (m_dirtyDetailRegion.IsValid() || !cameraPosition.IsClose(m_previousCameraPosition) || m_detailImagesNeedUpdate) - { - int32_t newDetailTexturePosX = aznumeric_cast(AZStd::roundf(cameraPosition.GetX() / DetailTextureScale)); - int32_t newDetailTexturePosY = aznumeric_cast(AZStd::roundf(cameraPosition.GetY() / DetailTextureScale)); - - Aabb2i newBounds; - newBounds.m_min.m_x = newDetailTexturePosX - DetailTextureSizeHalf; - newBounds.m_min.m_y = newDetailTexturePosY - DetailTextureSizeHalf; - newBounds.m_max.m_x = newDetailTexturePosX + DetailTextureSizeHalf; - newBounds.m_max.m_y = newDetailTexturePosY + DetailTextureSizeHalf; - - // Use modulo to find the center point in texture space. Care must be taken so negative values are - // handled appropriately (ie, we want -1 % 1024 to equal 1023, not -1) - Vector2i newCenter; - newCenter.m_x = (DetailTextureSize + (newDetailTexturePosX % DetailTextureSize)) % DetailTextureSize; - newCenter.m_y = (DetailTextureSize + (newDetailTexturePosY % DetailTextureSize)) % DetailTextureSize; - - CheckUpdateDetailTexture(newBounds, newCenter); - - m_detailTextureBounds = newBounds; - m_dirtyDetailRegion = AZ::Aabb::CreateNull(); - - m_previousCameraPosition = cameraPosition; - - AZ::Vector4 detailAabb = AZ::Vector4( - m_detailTextureBounds.m_min.m_x * DetailTextureScale, - m_detailTextureBounds.m_min.m_y * DetailTextureScale, - m_detailTextureBounds.m_max.m_x * DetailTextureScale, - m_detailTextureBounds.m_max.m_y * DetailTextureScale - ); - AZ::Vector2 detailUvOffset = AZ::Vector2(float(newCenter.m_x) / DetailTextureSize, float(newCenter.m_y) / DetailTextureSize); - - if (m_terrainSrg) - { - m_terrainSrg->SetConstant(m_detailAabbPropertyIndex, detailAabb); - m_terrainSrg->SetConstant(m_detailHalfPixelUvPropertyIndex, 0.5f / DetailTextureSize); - m_terrainSrg->SetConstant(m_detailCenterPropertyIndex, detailUvOffset); - - m_detailMaterialDataBuffer.UpdateSrg(m_terrainSrg.get()); - } - } - - if (m_areaData.m_heightmapUpdated || m_areaData.m_macroMaterialsUpdated) - { - // Currently when anything in the heightmap changes we're updating all the srgs, but this could probably - // be optimized to only update the srgs that changed. - - m_areaData.m_heightmapUpdated = false; - m_areaData.m_macroMaterialsUpdated = false; - - AZStd::array uvStep = - { - 1.0f / aznumeric_cast(m_areaData.m_terrainBounds.GetXExtent() / m_areaData.m_sampleSpacing), - 1.0f / aznumeric_cast(m_areaData.m_terrainBounds.GetYExtent() / m_areaData.m_sampleSpacing), - }; - - for (SectorData& sectorData : m_sectorData) - { - ShaderTerrainData terrainDataForSrg; - - const float xPatch = sectorData.m_aabb.GetMin().GetX(); - const float yPatch = sectorData.m_aabb.GetMin().GetY(); - - terrainDataForSrg.m_uvMin = { - (xPatch - terrainBounds.GetMin().GetX()) / terrainBounds.GetXExtent(), - (yPatch - terrainBounds.GetMin().GetY()) / terrainBounds.GetYExtent() - }; - - terrainDataForSrg.m_uvMax = { - ((xPatch + GridMeters) - terrainBounds.GetMin().GetX()) / terrainBounds.GetXExtent(), - ((yPatch + GridMeters) - terrainBounds.GetMin().GetY()) / terrainBounds.GetYExtent() - }; - - terrainDataForSrg.m_uvStep = uvStep; - - AZ::Transform transform = m_areaData.m_transform; - transform.SetTranslation(xPatch, yPatch, m_areaData.m_transform.GetTranslation().GetZ()); - - terrainDataForSrg.m_sampleSpacing = m_areaData.m_sampleSpacing; - terrainDataForSrg.m_heightScale = terrainBounds.GetZExtent(); - - sectorData.m_srg->SetConstant(m_terrainDataIndex, terrainDataForSrg); - - AZStd::array macroMaterialData; - - uint32_t i = 0; - for (; i < sectorData.m_macroMaterials.size(); ++i) - { - const MacroMaterialData& materialData = m_macroMaterials.GetData(sectorData.m_macroMaterials.at(i)); - ShaderMacroMaterialData& shaderData = macroMaterialData.at(i); - const AZ::Aabb& materialBounds = materialData.m_bounds; - - // Use reverse coordinates (1 - y) for the y direction so that the lower left corner of the macro material images - // map to the lower left corner in world space. This will match up with the height uv coordinate mapping. - shaderData.m_uvMin = { - (xPatch - materialBounds.GetMin().GetX()) / materialBounds.GetXExtent(), - 1.0f - ((yPatch - materialBounds.GetMin().GetY()) / materialBounds.GetYExtent()) - }; - shaderData.m_uvMax = { - ((xPatch + GridMeters) - materialBounds.GetMin().GetX()) / materialBounds.GetXExtent(), - 1.0f - (((yPatch + GridMeters) - materialBounds.GetMin().GetY()) / materialBounds.GetYExtent()) - }; - shaderData.m_normalFactor = materialData.m_normalFactor; - shaderData.m_flipNormalX = materialData.m_normalFlipX; - shaderData.m_flipNormalY = materialData.m_normalFlipY; - - const AZ::RHI::ImageView* colorImageView = materialData.m_colorImage ? materialData.m_colorImage->GetImageView() : nullptr; - sectorData.m_srg->SetImageView(m_macroColorMapIndex, colorImageView, i); - - const AZ::RHI::ImageView* normalImageView = materialData.m_normalImage ? materialData.m_normalImage->GetImageView() : nullptr; - sectorData.m_srg->SetImageView(m_macroNormalMapIndex, normalImageView, i); - - // set flags for which images are used. - shaderData.m_mapsInUse = (colorImageView ? ColorImageUsed : 0) | (normalImageView ? NormalImageUsed : 0); - } - for (; i < sectorData.m_macroMaterials.capacity(); ++i) - { - sectorData.m_srg->SetImageView(m_macroColorMapIndex, nullptr, i); - sectorData.m_srg->SetImageView(m_macroNormalMapIndex, nullptr, i); - } - - sectorData.m_srg->SetConstantArray(m_macroMaterialDataIndex, macroMaterialData); - sectorData.m_srg->SetConstant(m_macroMaterialCountIndex, aznumeric_cast(sectorData.m_macroMaterials.size())); - - const AZ::Matrix3x4 matrix3x4 = AZ::Matrix3x4::CreateFromTransform(transform); - sectorData.m_srg->SetConstant(m_modelToWorldIndex, matrix3x4); - - sectorData.m_srg->Compile(); - } - } - - // Currently there seems to be a bug in unbounded image arrays where flickering can occur if this isn't updated every frame. - if (m_terrainSrg/* && m_detailImagesUpdated*/) - { - AZStd::array_view imageViews(m_detailImageViews.data(), m_detailImageViews.size()); - [[maybe_unused]] bool result = m_terrainSrg->SetImageViewUnboundedArray(m_detailTexturesIndex, imageViews); - AZ_Error(TerrainFPName, result, "Failed to set image view unbounded array into shader resource group."); - m_detailImagesNeedUpdate = false; - } - } - - for (auto& sectorData : m_sectorData) - { - uint8_t lodChoice = AZ::RPI::ModelLodAsset::LodCountMax; - - // Go through all cameras and choose an LOD based on the closest camera. - for (auto& view : process.m_views) - { - if ((view->GetUsageFlags() & AZ::RPI::View::UsageFlags::UsageCamera) > 0) - { - const AZ::Vector3 cameraPosition = view->GetCameraTransform().GetTranslation(); - const AZ::Vector2 cameraPositionXY = AZ::Vector2(cameraPosition.GetX(), cameraPosition.GetY()); - const AZ::Vector2 sectorCenterXY = AZ::Vector2(sectorData.m_aabb.GetCenter().GetX(), sectorData.m_aabb.GetCenter().GetY()); - - const float sectorDistance = sectorCenterXY.GetDistance(cameraPositionXY); - - // This will be configurable later - const float minDistanceForLod0 = (GridMeters * 4.0f); - - // For every distance doubling beyond a minDistanceForLod0, we only need half the mesh density. Each LOD - // is exactly half the resolution of the last. - const float lodForCamera = AZStd::floorf(AZ::GetMax(0.0f, log2f(sectorDistance / minDistanceForLod0))); - - // All cameras should render the same LOD so effects like shadows are consistent. - lodChoice = AZ::GetMin(lodChoice, aznumeric_cast(lodForCamera)); - } - } - - // Add the correct LOD draw packet for visible sectors. - for (auto& view : process.m_views) - { - AZ::Frustum viewFrustum = AZ::Frustum::CreateFromMatrixColumnMajor(view->GetWorldToClipMatrix()); - if (viewFrustum.IntersectAabb(sectorData.m_aabb) != AZ::IntersectResult::Exterior) - { - const uint8_t lodToRender = AZ::GetMin(lodChoice, aznumeric_cast(sectorData.m_drawPackets.size() - 1)); - view->AddDrawPacket(sectorData.m_drawPackets.at(lodToRender).GetRHIDrawPacket()); - } - } - } - - if (m_detailTextureImage && m_areaData.m_heightmapImage && m_imagesNeedUpdate) - { - m_imagesNeedUpdate = false; - for (auto& view : process.m_views) - { - auto viewSrg = view->GetShaderResourceGroup(); - viewSrg->SetImage(m_heightmapPropertyIndex, m_areaData.m_heightmapImage); - } - if (m_terrainSrg) - { - m_terrainSrg->SetImage(m_detailMaterialIdPropertyIndex, m_detailTextureImage); - } - } - - if (m_materialInstance) - { - m_materialInstance->Compile(); - } - - if (m_terrainSrg && m_forwardPass) - { - m_terrainSrg->Compile(); - m_forwardPass->BindSrg(m_terrainSrg->GetRHIShaderResourceGroup()); - } - } - - void TerrainFeatureProcessor::InitializeTerrainPatch(uint16_t gridSize, float gridSpacing, PatchData& patchdata) - { - patchdata.m_positions.clear(); - patchdata.m_uvs.clear(); - patchdata.m_indices.clear(); - - const uint16_t gridVertices = gridSize + 1; // For m_gridSize quads, (m_gridSize + 1) vertices are needed. - const size_t size = gridVertices * gridVertices; - - patchdata.m_positions.reserve(size); - patchdata.m_uvs.reserve(size); - - for (uint16_t y = 0; y < gridVertices; ++y) - { - for (uint16_t x = 0; x < gridVertices; ++x) - { - patchdata.m_positions.push_back({ aznumeric_cast(x) * gridSpacing, aznumeric_cast(y) * gridSpacing }); - patchdata.m_uvs.push_back({ aznumeric_cast(x) / gridSize, aznumeric_cast(y) / gridSize }); - } - } - - patchdata.m_indices.reserve(gridSize * gridSize * 6); // total number of quads, 2 triangles with 6 indices per quad. - - for (uint16_t y = 0; y < gridSize; ++y) - { - for (uint16_t x = 0; x < gridSize; ++x) - { - const uint16_t topLeft = y * gridVertices + x; - const uint16_t topRight = topLeft + 1; - const uint16_t bottomLeft = (y + 1) * gridVertices + x; - const uint16_t bottomRight = bottomLeft + 1; - - patchdata.m_indices.emplace_back(topLeft); - patchdata.m_indices.emplace_back(topRight); - patchdata.m_indices.emplace_back(bottomLeft); - patchdata.m_indices.emplace_back(bottomLeft); - patchdata.m_indices.emplace_back(topRight); - patchdata.m_indices.emplace_back(bottomRight); - } - } - } - - AZ::Outcome> TerrainFeatureProcessor::CreateBufferAsset( - const void* data, const AZ::RHI::BufferViewDescriptor& bufferViewDescriptor, const AZStd::string& bufferName) - { - AZ::RPI::BufferAssetCreator creator; - creator.Begin(AZ::Uuid::CreateRandom()); - - AZ::RHI::BufferDescriptor bufferDescriptor; - bufferDescriptor.m_bindFlags = AZ::RHI::BufferBindFlags::InputAssembly | AZ::RHI::BufferBindFlags::ShaderRead; - bufferDescriptor.m_byteCount = static_cast(bufferViewDescriptor.m_elementSize) * static_cast(bufferViewDescriptor.m_elementCount); - - creator.SetBuffer(data, bufferDescriptor.m_byteCount, bufferDescriptor); - creator.SetBufferViewDescriptor(bufferViewDescriptor); - creator.SetUseCommonPool(AZ::RPI::CommonBufferPoolType::StaticInputAssembly); - - AZ::Data::Asset bufferAsset; - if (creator.End(bufferAsset)) - { - bufferAsset.SetHint(bufferName); - return AZ::Success(bufferAsset); - } - - return AZ::Failure(); - } - - bool TerrainFeatureProcessor::InitializePatchModel() - { - AZ::RPI::ModelAssetCreator modelAssetCreator; - modelAssetCreator.Begin(AZ::Uuid::CreateRandom()); - - uint16_t gridSize = GridSize; - float gridSpacing = GridSpacing; - - for (uint32_t i = 0; i < AZ::RPI::ModelLodAsset::LodCountMax && gridSize > 0; ++i) - { - PatchData patchData; - InitializeTerrainPatch(gridSize, gridSpacing, patchData); - - const auto positionBufferViewDesc = AZ::RHI::BufferViewDescriptor::CreateTyped(0, aznumeric_cast(patchData.m_positions.size()), AZ::RHI::Format::R32G32_FLOAT); - const auto positionsOutcome = CreateBufferAsset(patchData.m_positions.data(), positionBufferViewDesc, "TerrainPatchPositions"); - - const auto uvBufferViewDesc = AZ::RHI::BufferViewDescriptor::CreateTyped(0, aznumeric_cast(patchData.m_uvs.size()), AZ::RHI::Format::R32G32_FLOAT); - const auto uvsOutcome = CreateBufferAsset(patchData.m_uvs.data(), uvBufferViewDesc, "TerrainPatchUvs"); - - const auto indexBufferViewDesc = AZ::RHI::BufferViewDescriptor::CreateTyped(0, aznumeric_cast(patchData.m_indices.size()), AZ::RHI::Format::R16_UINT); - const auto indicesOutcome = CreateBufferAsset(patchData.m_indices.data(), indexBufferViewDesc, "TerrainPatchIndices"); - - if (!positionsOutcome.IsSuccess() || !uvsOutcome.IsSuccess() || !indicesOutcome.IsSuccess()) - { - AZ_Error(TerrainFPName, false, "Failed to create GPU buffers for Terrain"); - return false; - } - - AZ::RPI::ModelLodAssetCreator modelLodAssetCreator; - modelLodAssetCreator.Begin(AZ::Uuid::CreateRandom()); - - modelLodAssetCreator.BeginMesh(); - modelLodAssetCreator.AddMeshStreamBuffer(AZ::RHI::ShaderSemantic{ "POSITION" }, AZ::Name(), {positionsOutcome.GetValue(), positionBufferViewDesc}); - modelLodAssetCreator.AddMeshStreamBuffer(AZ::RHI::ShaderSemantic{ "UV" }, AZ::Name(), {uvsOutcome.GetValue(), uvBufferViewDesc}); - modelLodAssetCreator.SetMeshIndexBuffer({indicesOutcome.GetValue(), indexBufferViewDesc}); - - AZ::Aabb aabb = AZ::Aabb::CreateFromMinMax(AZ::Vector3(0.0, 0.0, 0.0), AZ::Vector3(GridMeters, GridMeters, 0.0)); - modelLodAssetCreator.SetMeshAabb(AZStd::move(aabb)); - modelLodAssetCreator.SetMeshName(AZ::Name("Terrain Patch")); - modelLodAssetCreator.EndMesh(); - - AZ::Data::Asset modelLodAsset; - modelLodAssetCreator.End(modelLodAsset); - - modelAssetCreator.AddLodAsset(AZStd::move(modelLodAsset)); - - gridSize = gridSize / 2; - gridSpacing *= 2.0f; - } - - AZ::Data::Asset modelAsset; - bool success = modelAssetCreator.End(modelAsset); - - m_patchModel = AZ::RPI::Model::FindOrCreate(modelAsset); - - return success; - } - void TerrainFeatureProcessor::OnMaterialReinitialized([[maybe_unused]] const MaterialInstance& material) { PrepareMaterialData(); - for (auto& sectorData : m_sectorData) - { - for (auto& drawPacket : sectorData.m_drawPackets) - { - drawPacket.Update(*GetParentScene()); - } - } - m_imagesNeedUpdate = true; - m_detailImagesNeedUpdate = true; + m_forceRebuildDrawPackets = true; + m_imageBindingsNeedUpdate = true; } void TerrainFeatureProcessor::SetWorldSize([[maybe_unused]] AZ::Vector2 sizeInMeters) @@ -1576,62 +424,6 @@ namespace Terrain // larger but this will limit how much is rendered. } - template - T* TerrainFeatureProcessor::FindByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container) - { - for (T& data : container.GetDataVector()) - { - if (data.m_entityId == entityId) - { - return &data; - } - } - return nullptr; - } - - template - T& TerrainFeatureProcessor::FindOrCreateByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container) - { - T* dataPtr = FindByEntityId(entityId, container); - if (dataPtr != nullptr) - { - return *dataPtr; - } - - const uint16_t slotId = container.GetFreeSlotIndex(); - AZ_Assert(slotId != AZ::Render::IndexedDataVector::NoFreeSlot, "Ran out of indices"); - - T& data = container.GetData(slotId); - data.m_entityId = entityId; - return data; - } - - template - void TerrainFeatureProcessor::RemoveByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container) - { - for (T& data : container.GetDataVector()) - { - if (data.m_entityId == entityId) - { - container.RemoveData(&data); - return; - } - } - AZ_Assert(false, "Entity Id not found in container.") - } - - template - void TerrainFeatureProcessor::ForOverlappingSectors(const AZ::Aabb& bounds, Callback callback) - { - for (SectorData& sectorData : m_sectorData) - { - if (sectorData.m_aabb.Overlaps(bounds)) - { - callback(sectorData); - } - } - } - void TerrainFeatureProcessor::CacheForwardPass() { auto rasterPassFilter = AZ::RPI::PassFilter::CreateWithPassClass(); @@ -1653,59 +445,5 @@ namespace Terrain ); } - auto TerrainFeatureProcessor::Vector2i::operator+(const Vector2i& rhs) const -> Vector2i - { - Vector2i offsetPoint = *this; - offsetPoint += rhs; - return offsetPoint; - } - - auto TerrainFeatureProcessor::Vector2i::operator+=(const Vector2i& rhs) -> Vector2i& - { - m_x += rhs.m_x; - m_y += rhs.m_y; - return *this; - } - - auto TerrainFeatureProcessor::Vector2i::operator-(const Vector2i& rhs) const -> Vector2i - { - return *this + -rhs; - } - - auto TerrainFeatureProcessor::Vector2i::operator-=(const Vector2i& rhs) -> Vector2i& - { - return *this += -rhs; - } - - auto TerrainFeatureProcessor::Vector2i::operator-() const -> Vector2i - { - return {-m_x, -m_y}; - } - - auto TerrainFeatureProcessor::Aabb2i::operator+(const Vector2i& rhs) const -> Aabb2i - { - return { m_min + rhs, m_max + rhs }; - } - - auto TerrainFeatureProcessor::Aabb2i::operator-(const Vector2i& rhs) const -> Aabb2i - { - return *this + -rhs; - } - - auto TerrainFeatureProcessor::Aabb2i::GetClamped(Aabb2i rhs) const -> Aabb2i - { - Aabb2i ret; - ret.m_min.m_x = AZ::GetMax(m_min.m_x, rhs.m_min.m_x); - ret.m_min.m_y = AZ::GetMax(m_min.m_y, rhs.m_min.m_y); - ret.m_max.m_x = AZ::GetMin(m_max.m_x, rhs.m_max.m_x); - ret.m_max.m_y = AZ::GetMin(m_max.m_y, rhs.m_max.m_y); - return ret; - } - - bool TerrainFeatureProcessor::Aabb2i::IsValid() const - { - // Intentionally strict, equal min/max not valid. - return m_min.m_x < m_max.m_x && m_min.m_y < m_max.m_y; - } } diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainFeatureProcessor.h b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainFeatureProcessor.h index 7d68e6b185..016c0d478a 100644 --- a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainFeatureProcessor.h +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainFeatureProcessor.h @@ -8,20 +8,17 @@ #pragma once -#include - #include -#include -#include + +#include +#include +#include +#include #include #include -#include #include #include -#include -#include -#include namespace AZ::RPI { @@ -30,9 +27,7 @@ namespace AZ::RPI class AsyncAssetLoader; } class Material; - class Model; class RenderPass; - class StreamingImage; } namespace Terrain @@ -41,8 +36,6 @@ namespace Terrain : public AZ::RPI::FeatureProcessor , private AZ::RPI::MaterialReloadNotificationBus::Handler , private AzFramework::Terrain::TerrainDataNotificationBus::Handler - , private TerrainMacroMaterialNotificationBus::Handler - , private TerrainAreaMaterialNotificationBus::Handler { public: AZ_RTTI(TerrainFeatureProcessor, "{D7DAC1F9-4A9F-4D3C-80AE-99579BF8AB1C}", AZ::RPI::FeatureProcessor); @@ -62,189 +55,16 @@ namespace Terrain void SetWorldSize(AZ::Vector2 sizeInMeters); private: - - using MaterialInstance = AZ::Data::Instance; - static constexpr uint32_t MaxMaterialsPerSector = 4; - - enum MacroMaterialFlags - { - ColorImageUsed = 0b01, - NormalImageUsed = 0b10, - }; - - struct ShaderTerrainData // Must align with struct in Object Srg - { - AZStd::array m_uvMin{ 0.0f, 0.0f }; - AZStd::array m_uvMax{ 1.0f, 1.0f }; - AZStd::array m_uvStep{ 1.0f, 1.0f }; - float m_sampleSpacing{ 1.0f }; - float m_heightScale{ 1.0f }; - }; - - struct ShaderMacroMaterialData // Must align with struct in Object Srg - { - AZStd::array m_uvMin{ 0.0f, 0.0f }; - AZStd::array m_uvMax{ 1.0f, 1.0f }; - float m_normalFactor{ 0.0f }; - uint32_t m_flipNormalX{ 0 }; // bool in shader - uint32_t m_flipNormalY{ 0 }; // bool in shader - uint32_t m_mapsInUse{ 0b00 }; // 0b01 = color, 0b10 = normal - }; - - struct VertexPosition - { - float m_posx; - float m_posy; - }; - - struct VertexUv - { - float m_u; - float m_v; - }; - - struct PatchData - { - AZStd::vector m_positions; - AZStd::vector m_uvs; - AZStd::vector m_indices; - }; - - struct SectorData - { - AZ::Data::Instance m_srg; // Hold on to ref so it's not dropped - AZ::Aabb m_aabb; - AZStd::fixed_vector m_drawPackets; - AZStd::fixed_vector m_macroMaterials; - }; - - enum DetailTextureFlags : uint32_t - { - UseTextureBaseColor = 0b0000'0000'0000'0000'0000'0000'0000'0001, - UseTextureNormal = 0b0000'0000'0000'0000'0000'0000'0000'0010, - UseTextureMetallic = 0b0000'0000'0000'0000'0000'0000'0000'0100, - UseTextureRoughness = 0b0000'0000'0000'0000'0000'0000'0000'1000, - UseTextureOcclusion = 0b0000'0000'0000'0000'0000'0000'0001'0000, - UseTextureHeight = 0b0000'0000'0000'0000'0000'0000'0010'0000, - UseTextureSpecularF0 = 0b0000'0000'0000'0000'0000'0000'0100'0000, - - FlipNormalX = 0b0000'0000'0000'0001'0000'0000'0000'0000, - FlipNormalY = 0b0000'0000'0000'0010'0000'0000'0000'0000, - - BlendModeMask = 0b0000'0000'0000'1100'0000'0000'0000'0000, - BlendModeLerp = 0b0000'0000'0000'0000'0000'0000'0000'0000, - BlendModeLinearLight = 0b0000'0000'0000'0100'0000'0000'0000'0000, - BlendModeMultiply = 0b0000'0000'0000'1000'0000'0000'0000'0000, - BlendModeOverlay = 0b0000'0000'0000'1100'0000'0000'0000'0000, - }; - - static constexpr uint16_t InvalidDetailImageIndex = 0xFFFF; - - struct DetailMaterialShaderData - { - // Uv - AZStd::array m_uvTransform - { - 1.0, 0.0, 0.0, 0.0, - 0.0, 1.0, 0.0, 0.0, - 0.0, 0.0, 1.0, 0.0, - }; - - float m_baseColorRed{ 1.0f }; - float m_baseColorGreen{ 1.0f }; - float m_baseColorBlue{ 1.0f }; - - // Factor / Scale / Bias for input textures - float m_baseColorFactor{ 1.0f }; - - float m_normalFactor{ 1.0f }; - float m_metalFactor{ 1.0f }; - float m_roughnessScale{ 1.0f }; - float m_roughnessBias{ 0.0f }; - - float m_specularF0Factor{ 1.0f }; - float m_occlusionFactor{ 1.0f }; - float m_heightFactor{ 1.0f }; - float m_heightOffset{ 0.0f }; - - float m_heightBlendFactor{ 0.5f }; - - // Flags - DetailTextureFlags m_flags{ 0 }; - - // Image indices - uint16_t m_colorImageIndex{ InvalidDetailImageIndex }; - uint16_t m_normalImageIndex{ InvalidDetailImageIndex }; - uint16_t m_roughnessImageIndex{ InvalidDetailImageIndex }; - uint16_t m_metalnessImageIndex{ InvalidDetailImageIndex }; - - uint16_t m_specularF0ImageIndex{ InvalidDetailImageIndex }; - uint16_t m_occlusionImageIndex{ InvalidDetailImageIndex }; - uint16_t m_heightImageIndex{ InvalidDetailImageIndex }; - // 16 byte aligned - uint16_t m_padding1; - uint32_t m_padding2; - uint32_t m_padding3; - }; - - struct DetailMaterialData - { - AZ::Data::AssetId m_assetId; - AZ::RPI::Material::ChangeId m_materialChangeId{AZ::RPI::Material::DEFAULT_CHANGE_ID}; - uint32_t refCount = 0; - uint16_t m_detailMaterialBufferIndex{ 0xFFFF }; - - AZ::Data::Instance m_colorImage; - AZ::Data::Instance m_normalImage; - AZ::Data::Instance m_roughnessImage; - AZ::Data::Instance m_metalnessImage; - AZ::Data::Instance m_specularF0Image; - AZ::Data::Instance m_occlusionImage; - AZ::Data::Instance m_heightImage; - }; - - struct DetailMaterialSurface - { - AZ::Crc32 m_surfaceTag; - uint16_t m_detailMaterialId; - }; - - struct DetailMaterialListRegion - { - AZ::EntityId m_entityId; - AZ::Aabb m_region{AZ::Aabb::CreateNull()}; - AZStd::vector m_materialsForSurfaces; - }; - - struct Vector2i - { - int32_t m_x{ 0 }; - int32_t m_y{ 0 }; - - Vector2i operator+(const Vector2i& rhs) const; - Vector2i& operator+=(const Vector2i& rhs); - Vector2i operator-(const Vector2i& rhs) const; - Vector2i& operator-=(const Vector2i& rhs); - Vector2i operator-() const; - }; - - struct Aabb2i - { - Vector2i m_min; - Vector2i m_max; - - Aabb2i operator+(const Vector2i& offset) const; - Aabb2i operator-(const Vector2i& offset) const; - - Aabb2i GetClamped(Aabb2i rhs) const; - bool IsValid() const; - }; + static constexpr auto InvalidImageIndex = AZ::Render::BindlessImageArrayHandler::InvalidImageIndex; + using MaterialInstance = AZ::Data::Instance; - struct DetailTextureLocation + struct WorldShaderData { - uint16_t m_index; - AZ::Data::Instance m_image; + AZStd::array m_min{ 0.0f, 0.0f, 0.0f }; + float padding1{ 0.0f }; + AZStd::array m_max{ 0.0f, 0.0f, 0.0f }; + float padding2{ 0.0f }; }; // AZ::RPI::MaterialReloadNotificationBus::Handler overrides... @@ -254,122 +74,46 @@ namespace Terrain void OnTerrainDataDestroyBegin() override; void OnTerrainDataChanged(const AZ::Aabb& dirtyRegion, TerrainDataChangedMask dataChangedMask) override; - // TerrainMacroMaterialNotificationBus overrides... - void OnTerrainMacroMaterialCreated(AZ::EntityId entityId, const MacroMaterialData& material) override; - void OnTerrainMacroMaterialChanged(AZ::EntityId entityId, const MacroMaterialData& material) override; - void OnTerrainMacroMaterialRegionChanged(AZ::EntityId entityId, const AZ::Aabb& oldRegion, const AZ::Aabb& newRegion) override; - void OnTerrainMacroMaterialDestroyed(AZ::EntityId entityId) override; - - // TerrainAreaMaterialNotificationBus overrides... - void OnTerrainSurfaceMaterialMappingCreated(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag, MaterialInstance material) override; - void OnTerrainSurfaceMaterialMappingDestroyed(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag) override; - void OnTerrainSurfaceMaterialMappingChanged(AZ::EntityId entityId, SurfaceData::SurfaceTag surfaceTag, MaterialInstance material) override; - void OnTerrainSurfaceMaterialMappingRegionChanged(AZ::EntityId entityId, const AZ::Aabb& oldRegion, const AZ::Aabb& newRegion) override; - // AZ::RPI::SceneNotificationBus overrides... void OnRenderPipelinePassesChanged(AZ::RPI::RenderPipeline* renderPipeline) override; void Initialize(); - void InitializeTerrainPatch(uint16_t gridSize, float gridSpacing, PatchData& patchdata); - bool InitializePatchModel(); - void UpdateTerrainData(); + void UpdateHeightmapImage(); void PrepareMaterialData(); - void UpdateMacroMaterialData(MacroMaterialData& macroMaterialData, const MacroMaterialData& newMaterialData); - - void TerrainHeightOrSettingsUpdated(const AZ::Aabb& dirtyRegion); - void TerrainSurfaceDataUpdated(const AZ::Aabb& dirtyRegion); - uint16_t CreateOrUpdateDetailMaterial(MaterialInstance material); - void CheckDetailMaterialForDeletion(uint16_t detailMaterialId); - void UpdateDetailMaterialData(uint16_t detailMaterialIndex, MaterialInstance material); - void CheckUpdateDetailTexture(const Aabb2i& newBounds, const Vector2i& newCenter); - void UpdateDetailTexture(const Aabb2i& updateArea, const Aabb2i& textureBounds, const Vector2i& centerPixel); - uint16_t GetDetailMaterialForSurfaceTypeAndPosition(AZ::Crc32 surfaceType, const AZ::Vector2& position); - uint8_t CalculateUpdateRegions(const Aabb2i& updateArea, const Aabb2i& textureBounds, const Vector2i& centerPixel, - AZStd::array& textureSpaceAreas, AZStd::array& scaledWorldSpaceAreas); + void TerrainHeightOrSettingsUpdated(const AZ::Aabb& dirtyRegion); void ProcessSurfaces(const FeatureProcessor::RenderPacket& process); - template - T* FindByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container); - template - T& FindOrCreateByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container); - template - void RemoveByEntityId(AZ::EntityId entityId, AZ::Render::IndexedDataVector& container); - - template - void ForOverlappingSectors(const AZ::Aabb& bounds, Callback callback); - - AZ::Outcome> CreateBufferAsset( - const void* data, const AZ::RHI::BufferViewDescriptor& bufferViewDescriptor, const AZStd::string& bufferName); - void CacheForwardPass(); - // System-level parameters - static constexpr float GridSpacing{ 1.0f }; - static constexpr int32_t GridSize{ 64 }; // number of terrain quads (vertices are m_gridSize + 1) - static constexpr float GridMeters{ GridSpacing * GridSize }; - static constexpr int32_t DetailTextureSize{ 1024 }; - static constexpr int32_t DetailTextureSizeHalf{ DetailTextureSize / 2 }; - static constexpr float DetailTextureScale{ 0.5f }; + TerrainMeshManager m_meshManager; + TerrainMacroMaterialManager m_macroMaterialManager; + TerrainDetailMaterialManager m_detailMaterialManager; + + AZStd::shared_ptr m_imageArrayHandler; AZStd::unique_ptr m_materialAssetLoader; MaterialInstance m_materialInstance; + AZ::Data::Instance m_terrainSrg; + AZ::Data::Instance m_heightmapImage; - AZ::RHI::ShaderInputConstantIndex m_modelToWorldIndex; - AZ::RHI::ShaderInputConstantIndex m_terrainDataIndex; - AZ::RHI::ShaderInputConstantIndex m_macroMaterialDataIndex; - AZ::RHI::ShaderInputConstantIndex m_macroMaterialCountIndex; - AZ::RHI::ShaderInputImageIndex m_macroColorMapIndex; - AZ::RHI::ShaderInputImageIndex m_macroNormalMapIndex; AZ::RHI::ShaderInputImageIndex m_heightmapPropertyIndex; - AZ::RHI::ShaderInputImageIndex m_detailMaterialIdPropertyIndex; - AZ::RHI::ShaderInputBufferIndex m_detailMaterialDataIndex; - AZ::RHI::ShaderInputConstantIndex m_detailCenterPropertyIndex; - AZ::RHI::ShaderInputConstantIndex m_detailAabbPropertyIndex; - AZ::RHI::ShaderInputConstantIndex m_detailHalfPixelUvPropertyIndex; - AZ::RHI::ShaderInputImageUnboundedArrayIndex m_detailTexturesIndex; + AZ::RHI::ShaderInputConstantIndex m_worldDataIndex; - AZ::Data::Instance m_patchModel; - AZ::Vector3 m_previousCameraPosition = AZ::Vector3(AZStd::numeric_limits::max(), 0.0, 0.0); - - // Per-area data - struct TerrainAreaData - { - AZ::Transform m_transform{ AZ::Transform::CreateIdentity() }; - AZ::Aabb m_terrainBounds{ AZ::Aabb::CreateNull() }; - AZ::Data::Instance m_heightmapImage; - float m_sampleSpacing{ 0.0f }; - bool m_heightmapUpdated{ true }; - bool m_macroMaterialsUpdated{ true }; - bool m_rebuildSectors{ true }; - }; - - TerrainAreaData m_areaData; + AZ::Aabb m_terrainBounds{ AZ::Aabb::CreateNull() }; AZ::Aabb m_dirtyRegion{ AZ::Aabb::CreateNull() }; - AZ::Aabb m_dirtyDetailRegion{ AZ::Aabb::CreateNull() }; - bool m_updateDetailMaterialBuffer{ false }; - - Aabb2i m_detailTextureBounds; - Vector2i m_detailTextureCenter; - AZ::Data::Instance m_detailTextureImage; - AZ::RPI::ShaderSystemInterface::GlobalShaderOptionUpdatedEvent::Handler m_handleGlobalShaderOptionUpdate; + + float m_sampleSpacing{ 0.0f }; + + bool m_heightmapNeedsUpdate{ false }; bool m_forceRebuildDrawPackets{ false }; - bool m_imagesNeedUpdate{ false }; + bool m_imageBindingsNeedUpdate{ false }; - AZStd::vector m_sectorData; + AZ::RPI::ShaderSystemInterface::GlobalShaderOptionUpdatedEvent::Handler m_handleGlobalShaderOptionUpdate; - AZ::Render::IndexedDataVector m_macroMaterials; - AZ::Render::IndexedDataVector m_detailMaterials; - AZ::Render::IndexedDataVector m_detailMaterialRegions; - AZ::Render::SparseVector m_detailMaterialShaderData; - AZ::Render::GpuBufferHandler m_detailMaterialDataBuffer; AZ::RPI::RenderPass* m_forwardPass; - - AZStd::vector m_detailImageViews; - AZStd::vector m_detailImageViewFreeList; - bool m_detailImagesNeedUpdate{ false }; }; } diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialBus.cpp b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialBus.cpp index b1c6f2d54b..7f84874e63 100644 --- a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialBus.cpp +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialBus.cpp @@ -66,8 +66,27 @@ namespace Terrain } }; + void MacroMaterialData::Reflect(AZ::ReflectContext* context) + { + if (AZ::BehaviorContext* behaviorContext = azrtti_cast(context)) + { + behaviorContext->Class() + ->Attribute(AZ::Script::Attributes::Scope, AZ::Script::Attributes::ScopeFlags::Common) + ->Attribute(AZ::Script::Attributes::Category, "Terrain") + ->Attribute(AZ::Script::Attributes::Module, "terrain") + ->Property("EntityId", BehaviorValueProperty(&MacroMaterialData::m_entityId)) + ->Property("Bounds", BehaviorValueProperty(&MacroMaterialData::m_bounds)) + ->Property("NormalFlipX", BehaviorValueProperty(&MacroMaterialData::m_normalFlipX)) + ->Property("NormalFlipY", BehaviorValueProperty(&MacroMaterialData::m_normalFlipY)) + ->Property("NormalFactor", BehaviorValueProperty(&MacroMaterialData::m_normalFactor)) + ; + } + } + void TerrainMacroMaterialRequests::Reflect(AZ::ReflectContext* context) { + MacroMaterialData::Reflect(context); + if (AZ::BehaviorContext* behaviorContext = azrtti_cast(context)) { behaviorContext->EBus("TerrainMacroMaterialRequestBus") diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialBus.h b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialBus.h index 9a7151da56..abcf4d4df0 100644 --- a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialBus.h +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialBus.h @@ -18,8 +18,10 @@ namespace Terrain { struct MacroMaterialData final { - AZ_RTTI(MacroMaterialData, "{DC68E20A-3251-4E4E-8BC7-F6A2521FEF46}"); - + AZ_TYPE_INFO(MacroMaterialData, "{DC68E20A-3251-4E4E-8BC7-F6A2521FEF46}"); + + static void Reflect(AZ::ReflectContext* context); + AZ::EntityId m_entityId; AZ::Aabb m_bounds = AZ::Aabb::CreateNull(); diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialManager.cpp b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialManager.cpp new file mode 100644 index 0000000000..82349cdcdb --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialManager.cpp @@ -0,0 +1,412 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include + +namespace Terrain +{ + namespace + { + [[maybe_unused]] static const char* TerrainMacroMaterialManagerName = "TerrainMacroMaterialManager"; + } + + namespace TerrainSrgInputs + { + static const char* const MacroMaterialData("m_macroMaterialData"); + static const char* const MacroMaterialGrid("m_macroMaterialGrid"); + } + + void TerrainMacroMaterialManager::Initialize( + const AZStd::shared_ptr& bindlessImageHandler, + AZ::Data::Instance& terrainSrg) + { + AZ_Error(TerrainMacroMaterialManagerName, bindlessImageHandler, "bindlessImageHandler must not be null."); + AZ_Error(TerrainMacroMaterialManagerName, terrainSrg, "terrainSrg must not be null."); + AZ_Error(TerrainMacroMaterialManagerName, !m_isInitialized, "Already initialized."); + + if (!bindlessImageHandler || !terrainSrg || m_isInitialized) + { + return; + } + + if (UpdateSrgIndices(terrainSrg)) + { + m_bindlessImageHandler = bindlessImageHandler; + + OnTerrainDataChanged(AZ::Aabb::CreateNull(), TerrainDataChangedMask::Settings); + AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusConnect(); + TerrainMacroMaterialNotificationBus::Handler::BusConnect(); + + m_terrainSizeChanged = true; + m_isInitialized = true; + } + } + + void TerrainMacroMaterialManager::Reset() + { + m_isInitialized = false; + + m_macroMaterialDataBuffer = {}; + + m_macroMaterialShaderData.clear(); + m_macroMaterialEntities.clear(); + + RemoveAllImages(); + m_macroMaterials.clear(); + + m_bindlessImageHandler = {}; + + AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusDisconnect(); + TerrainMacroMaterialNotificationBus::Handler::BusDisconnect(); + } + + bool TerrainMacroMaterialManager::IsInitialized() + { + return m_isInitialized; + } + + bool TerrainMacroMaterialManager::UpdateSrgIndices(AZ::Data::Instance& terrainSrg) + { + const AZ::RHI::ShaderResourceGroupLayout* terrainSrgLayout = terrainSrg->GetLayout(); + + m_macroMaterialGridIndex = terrainSrgLayout->FindShaderInputConstantIndex(AZ::Name(TerrainSrgInputs::MacroMaterialGrid)); + AZ_Error(TerrainMacroMaterialManagerName, m_macroMaterialGridIndex.IsValid(), "Failed to find terrain srg input constant %s.", TerrainSrgInputs::MacroMaterialGrid); + + AZ::Render::GpuBufferHandler::Descriptor desc; + + // Set up the gpu buffer for macro material data + desc.m_bufferName = "Macro Material Data"; + desc.m_bufferSrgName = TerrainSrgInputs::MacroMaterialData; + desc.m_elementSize = sizeof(MacroMaterialShaderData); + desc.m_srgLayout = terrainSrgLayout; + m_macroMaterialDataBuffer = AZ::Render::GpuBufferHandler(desc); + + m_bufferNeedsUpdate = true; + + return m_macroMaterialDataBuffer.IsValid() && m_macroMaterialGridIndex.IsValid(); + } + + void TerrainMacroMaterialManager::OnTerrainDataChanged(const AZ::Aabb& dirtyRegion [[maybe_unused]], TerrainDataChangedMask dataChangedMask) + { + if ((dataChangedMask & TerrainDataChangedMask::Settings) != 0) + { + AZ::Aabb worldBounds = AZ::Aabb::CreateNull(); + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + worldBounds, &AzFramework::Terrain::TerrainDataRequests::GetTerrainAabb); + + m_terrainSizeChanged = m_terrainSizeChanged || m_terrainBounds != worldBounds; + m_terrainBounds = worldBounds; + } + } + + void TerrainMacroMaterialManager::OnTerrainMacroMaterialCreated(AZ::EntityId entityId, const MacroMaterialData& newMaterialData) + { + AZ_Assert(!m_macroMaterials.contains(entityId), + "OnTerrainMacroMaterialCreated called for a macro material that already exists. This indicates that either the bus is incorrectly sending out " + "OnCreated announcements for existing materials, or the terrain feature processor isn't properly cleaning up macro materials."); + + MacroMaterial& macroMaterial = m_macroMaterials[entityId]; + macroMaterial.m_data = newMaterialData; + if (newMaterialData.m_colorImage) + { + macroMaterial.m_colorIndex = m_bindlessImageHandler->AppendBindlessImage(newMaterialData.m_colorImage->GetImageView()); + } + if (newMaterialData.m_normalImage) + { + macroMaterial.m_normalIndex = m_bindlessImageHandler->AppendBindlessImage(newMaterialData.m_normalImage->GetImageView()); + } + + ForMacroMaterialsInBounds(newMaterialData.m_bounds, + [&](uint16_t idx, [[maybe_unused]] const AZ::Vector2& corner) + { + for (uint16_t offset = 0; offset < MacroMaterialsPerTile; ++offset) + { + MacroMaterialShaderData& macroMaterialShaderData = m_macroMaterialShaderData.at(idx + offset); + if ((macroMaterialShaderData.m_flags & MacroMaterialShaderFlags::IsUsed) == 0) + { + UpdateMacroMaterialShaderEntry(idx + offset, macroMaterial); + break; + } + AZ_Assert(m_macroMaterialEntities.at(idx + offset) != entityId, "Found existing macro material tile for what should be a completely new macro material."); + } + } + ); + + m_bufferNeedsUpdate = true; + } + + void TerrainMacroMaterialManager::OnTerrainMacroMaterialChanged(AZ::EntityId entityId, const MacroMaterialData& newMaterialData) + { + AZ_Assert(m_macroMaterials.contains(entityId), + "OnTerrainMacroMaterialChanged called for a macro material that TerrainFeatureProcessor isn't tracking. This indicates that either the bus is sending out " + "Changed announcements for materials that haven't had a OnCreated event sent, or the terrain feature processor isn't properly tracking macro materials."); + + MacroMaterial& macroMaterial = m_macroMaterials[entityId]; + macroMaterial.m_data = newMaterialData; + + auto UpdateImageIndex = [&](uint16_t& indexRef, const AZ::Data::Instance& imageView) + { + if (indexRef) + { + if (imageView) + { + m_bindlessImageHandler->UpdateBindlessImage(indexRef, imageView->GetImageView()); + } + else + { + m_bindlessImageHandler->RemoveBindlessImage(indexRef); + indexRef = 0xFFFF; + } + } + else if (imageView) + { + indexRef = m_bindlessImageHandler->AppendBindlessImage(imageView->GetImageView()); + } + }; + + UpdateImageIndex(macroMaterial.m_colorIndex, newMaterialData.m_colorImage); + UpdateImageIndex(macroMaterial.m_normalIndex, newMaterialData.m_normalImage); + + ForMacroMaterialsInBounds(newMaterialData.m_bounds, + [&](uint16_t idx, [[maybe_unused]] const AZ::Vector2& corner) + { + for (uint16_t offset = 0; offset < MacroMaterialsPerTile; ++offset) + { + if (m_macroMaterialEntities.at(idx + offset) == entityId) + { + UpdateMacroMaterialShaderEntry(idx + offset, macroMaterial); + break; + } + } + } + ); + + m_bufferNeedsUpdate = true; + } + + void TerrainMacroMaterialManager::OnTerrainMacroMaterialRegionChanged( + AZ::EntityId entityId, [[maybe_unused]] const AZ::Aabb& oldRegion, const AZ::Aabb& newRegion) + { + AZ_Assert(m_macroMaterials.contains(entityId), + "OnTerrainMacroMaterialChanged called for a macro material that TerrainFeatureProcessor isn't tracking. This indicates that either the bus is sending out " + "Changed announcements for materials that haven't had a OnCreated event sent, or the terrain feature processor isn't properly tracking macro materials."); + + MacroMaterial& macroMaterial = m_macroMaterials[entityId]; + macroMaterial.m_data.m_bounds = newRegion; + + AZ::Aabb changedRegion = oldRegion; + changedRegion.AddAabb(newRegion); + + ForMacroMaterialsInBounds(changedRegion, + [&](uint16_t idx, const AZ::Vector2& corner) + { + AZ::Aabb tileAabb = AZ::Aabb::CreateFromMinMaxValues( + corner.GetX(), corner.GetY(), m_terrainBounds.GetMin().GetZ(), + corner.GetX() + MacroMaterialGridSize, corner.GetY() + MacroMaterialGridSize, m_terrainBounds.GetMax().GetZ()); + + bool overlapsNew = tileAabb.Overlaps(newRegion); + uint16_t end = idx + MacroMaterialsPerTile; + + for (; idx < end; ++idx) + { + if (m_macroMaterialEntities.at(idx) == entityId) + { + if (overlapsNew) + { + // Update the macro material entry from this tile. + UpdateMacroMaterialShaderEntry(idx, macroMaterial); + } + else + { + // Remove the macro material entry from this tile. + RemoveMacroMaterialShaderEntry(idx); + } + break; + } + else if (overlapsNew && (m_macroMaterialShaderData.at(idx).m_flags & MacroMaterialShaderFlags::IsUsed) == 0) + { + // Add a macro material entry from this tile. (!overlapsOld && overlapsNew) + UpdateMacroMaterialShaderEntry(idx, macroMaterial); + break; + } + } + } + ); + + m_bufferNeedsUpdate = true; + } + + void TerrainMacroMaterialManager::OnTerrainMacroMaterialDestroyed(AZ::EntityId entityId) + { + AZ_Assert(m_macroMaterials.contains(entityId), + "OnTerrainMacroMaterialChanged called for a macro material that TerrainFeatureProcessor isn't tracking. This indicates that either the bus is sending out " + "Changed announcements for materials that haven't had a OnCreated event sent, or the terrain feature processor isn't properly tracking macro materials."); + + const MacroMaterial& macroMaterial = m_macroMaterials[entityId]; + + ForMacroMaterialsInBounds(macroMaterial.m_data.m_bounds, + [&](uint16_t idx, [[maybe_unused]] const AZ::Vector2& corner) + { + uint16_t end = idx + MacroMaterialsPerTile; + + for (; idx < end; ++idx) + { + if (m_macroMaterialEntities.at(idx) == entityId) + { + RemoveMacroMaterialShaderEntry(idx); + } + } + } + ); + + if (macroMaterial.m_colorIndex != 0xFFFF) + { + m_bindlessImageHandler->RemoveBindlessImage(macroMaterial.m_colorIndex); + } + if (macroMaterial.m_normalIndex != 0xFFFF) + { + m_bindlessImageHandler->RemoveBindlessImage(macroMaterial.m_normalIndex); + } + + m_macroMaterials.erase(entityId); + m_bufferNeedsUpdate = true; + } + + void TerrainMacroMaterialManager::UpdateMacroMaterialShaderEntry(uint16_t shaderDataIdx, const MacroMaterial& macroMaterial) + { + m_macroMaterialEntities.at(shaderDataIdx) = macroMaterial.m_data.m_entityId; + MacroMaterialShaderData& macroMaterialShaderData = m_macroMaterialShaderData.at(shaderDataIdx); + + macroMaterialShaderData.m_flags = (MacroMaterialShaderFlags)( + MacroMaterialShaderFlags::IsUsed | + (macroMaterial.m_data.m_normalFlipX ? MacroMaterialShaderFlags::FlipMacroNormalX : 0) | + (macroMaterial.m_data.m_normalFlipY ? MacroMaterialShaderFlags::FlipMacroNormalY : 0) + ); + + macroMaterialShaderData.m_normalFactor = macroMaterial.m_data.m_normalFactor; + macroMaterialShaderData.m_boundsMin = { macroMaterial.m_data.m_bounds.GetMin().GetX(), macroMaterial.m_data.m_bounds.GetMin().GetY() }; + macroMaterialShaderData.m_boundsMax = { macroMaterial.m_data.m_bounds.GetMax().GetX(), macroMaterial.m_data.m_bounds.GetMax().GetY() }; + macroMaterialShaderData.m_colorMapId = macroMaterial.m_colorIndex; + macroMaterialShaderData.m_normalMapId = macroMaterial.m_normalIndex; + } + + void TerrainMacroMaterialManager::RemoveMacroMaterialShaderEntry(uint16_t shaderDataIdx) + { + // Remove the macro material entry from this tile by copying the remaining entries on top. + for (++shaderDataIdx; shaderDataIdx % MacroMaterialsPerTile != 0; ++shaderDataIdx) + { + m_macroMaterialEntities.at(shaderDataIdx - 1) = m_macroMaterialEntities.at(shaderDataIdx); + m_macroMaterialShaderData.at(shaderDataIdx - 1) = m_macroMaterialShaderData.at(shaderDataIdx); + } + // Disable the last entry. + m_macroMaterialEntities.at(shaderDataIdx - 1) = AZ::EntityId(); + m_macroMaterialShaderData.at(shaderDataIdx - 1).m_flags = MacroMaterialShaderFlags(0); + } + + template + void TerrainMacroMaterialManager::ForMacroMaterialsInBounds(const AZ::Aabb& bounds, Callback callback) + { + // Get the macro material bounds relative to the terrain + float yStart = bounds.GetMin().GetY() - m_terrainBounds.GetMin().GetY(); + float yEnd = bounds.GetMax().GetY() - m_terrainBounds.GetMin().GetY(); + float xStart = bounds.GetMin().GetX() - m_terrainBounds.GetMin().GetX(); + float xEnd = bounds.GetMax().GetX() - m_terrainBounds.GetMin().GetX(); + + // Clamp the bounds to the terrain + uint16_t yStartIdx = yStart > 0.0f ? uint16_t(yStart / MacroMaterialGridSize) : 0; + uint16_t yEndIdx = yEnd > 0.0f ? AZStd::GetMin(uint16_t(yEnd / MacroMaterialGridSize) + 1, m_tilesY) : 0; + uint16_t xStartIdx = xStart > 0.0f ? uint16_t(xStart / MacroMaterialGridSize) : 0; + uint16_t xEndIdx = xEnd > 0.0f ? AZStd::GetMin(uint16_t(xEnd / MacroMaterialGridSize) + 1, m_tilesX) : 0; + + AZ::Vector2 gridCorner = AZ::Vector2( + floor(m_terrainBounds.GetMin().GetX() / MacroMaterialGridSize) * MacroMaterialGridSize, + floor(m_terrainBounds.GetMin().GetY() / MacroMaterialGridSize) * MacroMaterialGridSize); + + for (uint16_t y = yStartIdx; y < yEndIdx; ++y) + { + for (uint16_t x = xStartIdx; x < xEndIdx; ++x) + { + uint16_t idx = (y * m_tilesX + x) * MacroMaterialsPerTile; + const AZ::Vector2 corner = gridCorner + AZ::Vector2(x * MacroMaterialGridSize, y * MacroMaterialGridSize); + callback(idx, corner); + } + } + } + + void TerrainMacroMaterialManager::Update(AZ::Data::Instance& terrainSrg) + { + if (m_terrainSizeChanged) + { + m_terrainSizeChanged = false; + + // Rebuild the macro material tiles from scratch when the world size changes. This could be made more efficient + // but is fine for now since world resizes are rare. + + RemoveAllImages(); + m_macroMaterials.clear(); + + m_macroMaterialShaderData.clear(); + m_macroMaterialEntities.clear(); + + m_tilesX = aznumeric_cast(m_terrainBounds.GetXExtent() / MacroMaterialGridSize) + 1; + m_tilesY = aznumeric_cast(m_terrainBounds.GetYExtent() / MacroMaterialGridSize) + 1; + const uint32_t macroMaterialTileCount = m_tilesX * m_tilesY * MacroMaterialsPerTile; + + m_macroMaterialShaderData.resize(macroMaterialTileCount); + m_macroMaterialEntities.resize(macroMaterialTileCount); + + TerrainMacroMaterialRequestBus::EnumerateHandlers( + [&](TerrainMacroMaterialRequests* handler) + { + MacroMaterialData macroMaterial = handler->GetTerrainMacroMaterialData(); + AZ::EntityId entityId = *(Terrain::TerrainMacroMaterialRequestBus::GetCurrentBusId()); + OnTerrainMacroMaterialCreated(entityId, macroMaterial); + return true; + } + ); + } + + if (m_bufferNeedsUpdate) + { + m_bufferNeedsUpdate = false; + m_macroMaterialDataBuffer.UpdateBuffer(m_macroMaterialShaderData.data(), aznumeric_cast(m_macroMaterialShaderData.size())); + + MacroMaterialGridShaderData macroMaterialGridShaderData; + macroMaterialGridShaderData.m_offset = { m_terrainBounds.GetMin().GetX(), m_terrainBounds.GetMin().GetY() }; + macroMaterialGridShaderData.m_resolution = (m_tilesX << 16) | m_tilesY; + macroMaterialGridShaderData.m_tileSize = MacroMaterialGridSize; + + if (terrainSrg) + { + m_macroMaterialDataBuffer.UpdateSrg(terrainSrg.get()); + terrainSrg->SetConstant(m_macroMaterialGridIndex, macroMaterialGridShaderData); + } + } + } + + void TerrainMacroMaterialManager::RemoveAllImages() + { + for (const auto& [entity, macroMaterial] : m_macroMaterials) + { + RemoveImagesForMaterial(macroMaterial); + } + } + + void TerrainMacroMaterialManager::RemoveImagesForMaterial(const MacroMaterial& macroMaterial) + { + if (macroMaterial.m_colorIndex != 0xFFFF) + { + m_bindlessImageHandler->RemoveBindlessImage(macroMaterial.m_colorIndex); + } + if (macroMaterial.m_normalIndex != 0xFFFF) + { + m_bindlessImageHandler->RemoveBindlessImage(macroMaterial.m_normalIndex); + } + } + +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialManager.h b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialManager.h new file mode 100644 index 0000000000..6a603eeced --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMacroMaterialManager.h @@ -0,0 +1,116 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include +#include +#include + +namespace Terrain +{ + class TerrainMacroMaterialManager + : private TerrainMacroMaterialNotificationBus::Handler + , private AzFramework::Terrain::TerrainDataNotificationBus::Handler + { + public: + + TerrainMacroMaterialManager() = default; + ~TerrainMacroMaterialManager() = default; + + void Initialize( + const AZStd::shared_ptr& bindlessImageHandler, + AZ::Data::Instance& terrainSrg); + void Reset(); + bool IsInitialized(); + bool UpdateSrgIndices(AZ::Data::Instance& terrainSrg); + + void Update(AZ::Data::Instance& terrainSrg); + + private: + + static constexpr auto InvalidImageIndex = AZ::Render::BindlessImageArrayHandler::InvalidImageIndex; + static constexpr float MacroMaterialGridSize = 64.0f; + static constexpr uint16_t MacroMaterialsPerTile = 4; + + enum MacroMaterialShaderFlags : uint32_t + { + IsUsed = 0b0000'0000'0000'0000'0000'0000'0000'0001, + FlipMacroNormalX = 0b0000'0000'0000'0000'0000'0000'0000'0010, + FlipMacroNormalY = 0b0000'0000'0000'0000'0000'0000'0000'0100, + }; + + struct MacroMaterialShaderData + { + MacroMaterialShaderFlags m_flags; + uint32_t m_colorMapId{InvalidImageIndex}; + uint32_t m_normalMapId{InvalidImageIndex}; + float m_normalFactor; + + // macro material bounds in world space + AZStd::array m_boundsMin{ 0.0f, 0.0f }; + AZStd::array m_boundsMax{ 0.0f, 0.0f }; + }; + static_assert(sizeof(MacroMaterialShaderData) % 16 == 0, "MacroMaterialShaderData must be 16 byte aligned."); + + struct MacroMaterial + { + MacroMaterialData m_data; + uint16_t m_colorIndex{ 0xFFFF }; + uint16_t m_normalIndex{ 0xFFFF }; + }; + + struct MacroMaterialGridShaderData + { + uint32_t m_resolution; // How many x/y tiles in grid. x & y stored in 16 bits each. Total number of entries in m_macroMaterialData will be x * y + float m_tileSize; // Size of a tile in meters. + AZStd::array m_offset; // x/y offset of min x/y corner of grid. + }; + static_assert(sizeof(MacroMaterialGridShaderData) % 16 == 0, "MacroMaterialGridShaderData must be 16 byte aligned."); + + // AzFramework::Terrain::TerrainDataNotificationBus overrides... + void OnTerrainDataChanged(const AZ::Aabb& dirtyRegion [[maybe_unused]], TerrainDataChangedMask dataChangedMask) override; + + // TerrainMacroMaterialNotificationBus overrides... + void OnTerrainMacroMaterialCreated(AZ::EntityId entityId, const MacroMaterialData& material) override; + void OnTerrainMacroMaterialChanged(AZ::EntityId entityId, const MacroMaterialData& material) override; + void OnTerrainMacroMaterialRegionChanged(AZ::EntityId entityId, const AZ::Aabb& oldRegion, const AZ::Aabb& newRegion) override; + void OnTerrainMacroMaterialDestroyed(AZ::EntityId entityId) override; + + void UpdateMacroMaterialShaderEntry(uint16_t shaderDataIdx, const MacroMaterial& macroMaterialData); + void RemoveMacroMaterialShaderEntry(uint16_t shaderDataIdx); + + template + void ForMacroMaterialsInBounds(const AZ::Aabb& bounds, Callback callback); + + void RemoveAllImages(); + void RemoveImagesForMaterial(const MacroMaterial& macroMaterial); + + AZ::Aabb m_terrainBounds{ AZ::Aabb::CreateNull() }; + + // Macro materials stored in a grid of (MacroMaterialGridCount * MacroMaterialGridCount) where each tile in the grid covers + // an area of (MacroMaterialGridSize * MacroMaterialGridSize) and each tile can hold MacroMaterialsPerTile macro materials + AZStd::vector m_macroMaterialShaderData; + AZStd::vector m_macroMaterialEntities; // Same as above, but used to track entity ids which aren't needed by the shader. + AZStd::map m_macroMaterials; // Used for looking up macro materials by entity id when the data isn't provided by a bus. + uint16_t m_tilesX{ 0 }; + uint16_t m_tilesY{ 0 }; + + AZStd::shared_ptr m_bindlessImageHandler; + AZ::Render::GpuBufferHandler m_macroMaterialDataBuffer; + + AZ::RHI::ShaderInputConstantIndex m_macroMaterialGridIndex; + + bool m_terrainSizeChanged{ false }; + bool m_bufferNeedsUpdate{ false }; + bool m_isInitialized{ false }; + + }; +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMeshManager.cpp b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMeshManager.cpp new file mode 100644 index 0000000000..d689d2635c --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMeshManager.cpp @@ -0,0 +1,354 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include + +#include + +#include + +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include + +namespace Terrain +{ + namespace + { + [[maybe_unused]] static const char* TerrainMeshManagerName = "TerrainMeshManager"; + } + + namespace ShaderInputs + { + static const char* const PatchData("m_patchData"); + } + + void TerrainMeshManager::Initialize() + { + if (!InitializePatchModel()) + { + AZ_Error(TerrainMeshManagerName, false, "Failed to create Terrain render buffers!"); + return; + } + + OnTerrainDataChanged(AZ::Aabb::CreateNull(), TerrainDataChangedMask::HeightData); + AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusConnect(); + + m_isInitialized = true; + } + + bool TerrainMeshManager::IsInitialized() const + { + return m_isInitialized; + } + + void TerrainMeshManager::Reset() + { + AzFramework::Terrain::TerrainDataNotificationBus::Handler::BusDisconnect(); + m_patchModel = {}; + m_sectorData.clear(); + m_rebuildSectors = true; + m_isInitialized = false; + } + + bool TerrainMeshManager::CheckRebuildSurfaces(MaterialInstance materialInstance, AZ::RPI::Scene& parentScene) + { + if (!m_rebuildSectors) + { + return false; + } + + m_rebuildSectors = false; + m_sectorData.clear(); + + const auto layout = materialInstance->GetAsset()->GetObjectSrgLayout(); + + AZ::RHI::ShaderInputConstantIndex patchDataIndex = layout->FindShaderInputConstantIndex(AZ::Name(ShaderInputs::PatchData)); + AZ_Error(TerrainMeshManagerName, patchDataIndex.IsValid(), "Failed to find shader input constant %s.", ShaderInputs::PatchData); + + const float xFirstPatchStart = AZStd::floorf(m_worldBounds.GetMin().GetX() / GridMeters) * GridMeters; + const float xLastPatchStart = AZStd::floorf(m_worldBounds.GetMax().GetX() / GridMeters) * GridMeters; + const float yFirstPatchStart = AZStd::floorf(m_worldBounds.GetMin().GetY() / GridMeters) * GridMeters; + const float yLastPatchStart = AZStd::floorf(m_worldBounds.GetMax().GetY() / GridMeters) * GridMeters; + + const auto& materialAsset = materialInstance->GetAsset(); + const auto& shaderAsset = materialAsset->GetMaterialTypeAsset()->GetShaderAssetForObjectSrg(); + + for (float yPatch = yFirstPatchStart; yPatch <= yLastPatchStart; yPatch += GridMeters) + { + for (float xPatch = xFirstPatchStart; xPatch <= xLastPatchStart; xPatch += GridMeters) + { + ShaderTerrainData objectSrgData; + objectSrgData.m_xyTranslation = { xPatch, yPatch }; + + m_sectorData.push_back(); + SectorData& sectorData = m_sectorData.back(); + + for (auto& lod : m_patchModel->GetLods()) + { + objectSrgData.m_xyScale = m_sampleSpacing * GridSize; + + auto objectSrg = AZ::RPI::ShaderResourceGroup::Create(shaderAsset, materialAsset->GetObjectSrgLayout()->GetName()); + if (!objectSrg) + { + AZ_WarningOnce(TerrainMeshManagerName, false, "Failed to create a new shader resource group, skipping."); + continue; + } + objectSrg->SetConstant(patchDataIndex, objectSrgData); + objectSrg->Compile(); + + AZ::RPI::ModelLod& modelLod = *lod.get(); + sectorData.m_drawPackets.emplace_back(modelLod, 0, materialInstance, objectSrg); + AZ::RPI::MeshDrawPacket& drawPacket = sectorData.m_drawPackets.back(); + + sectorData.m_srgs.emplace_back(objectSrg); + + // set the shader option to select forward pass IBL specular if necessary + if (!drawPacket.SetShaderOption(AZ::Name("o_meshUseForwardPassIBLSpecular"), AZ::RPI::ShaderOptionValue{ false })) + { + AZ_Warning(TerrainMeshManagerName, false, "Failed to set o_meshUseForwardPassIBLSpecular on mesh draw packet"); + } + const uint8_t stencilRef = AZ::Render::StencilRefs::UseDiffuseGIPass | AZ::Render::StencilRefs::UseIBLSpecularPass; + drawPacket.SetStencilRef(stencilRef); + drawPacket.Update(parentScene, true); + } + + sectorData.m_aabb = + AZ::Aabb::CreateFromMinMax( + AZ::Vector3(xPatch, yPatch, m_worldBounds.GetMin().GetZ()), + AZ::Vector3(xPatch + GridMeters, yPatch + GridMeters, m_worldBounds.GetMax().GetZ()) + ); + } + } + return true; + } + + void TerrainMeshManager::DrawMeshes(const AZ::RPI::FeatureProcessor::RenderPacket& process) + { + for (auto& sectorData : m_sectorData) + { + uint8_t lodChoice = AZ::RPI::ModelLodAsset::LodCountMax; + + // Go through all cameras and choose an LOD based on the closest camera. + for (auto& view : process.m_views) + { + if ((view->GetUsageFlags() & AZ::RPI::View::UsageFlags::UsageCamera) > 0) + { + const AZ::Vector3 cameraPosition = view->GetCameraTransform().GetTranslation(); + const AZ::Vector2 cameraPositionXY = AZ::Vector2(cameraPosition.GetX(), cameraPosition.GetY()); + const AZ::Vector2 sectorCenterXY = AZ::Vector2(sectorData.m_aabb.GetCenter().GetX(), sectorData.m_aabb.GetCenter().GetY()); + + const float sectorDistance = sectorCenterXY.GetDistance(cameraPositionXY); + + // This will be configurable later + const float minDistanceForLod0 = (GridMeters * 4.0f); + + // For every distance doubling beyond a minDistanceForLod0, we only need half the mesh density. Each LOD + // is exactly half the resolution of the last. + const float lodForCamera = AZStd::floorf(AZ::GetMax(0.0f, log2f(sectorDistance / minDistanceForLod0))); + + // All cameras should render the same LOD so effects like shadows are consistent. + lodChoice = AZ::GetMin(lodChoice, aznumeric_cast(lodForCamera)); + } + } + + // Add the correct LOD draw packet for visible sectors. + for (auto& view : process.m_views) + { + AZ::Frustum viewFrustum = AZ::Frustum::CreateFromMatrixColumnMajor(view->GetWorldToClipMatrix()); + if (viewFrustum.IntersectAabb(sectorData.m_aabb) != AZ::IntersectResult::Exterior) + { + const uint8_t lodToRender = AZ::GetMin(lodChoice, aznumeric_cast(sectorData.m_drawPackets.size() - 1)); + view->AddDrawPacket(sectorData.m_drawPackets.at(lodToRender).GetRHIDrawPacket()); + } + } + } + } + + void TerrainMeshManager::RebuildDrawPackets(AZ::RPI::Scene& scene) + { + for (auto& sectorData : m_sectorData) + { + for (auto& drawPacket : sectorData.m_drawPackets) + { + drawPacket.Update(scene, true); + } + } + } + + void TerrainMeshManager::OnTerrainDataDestroyBegin() + { + Reset(); + } + + void TerrainMeshManager::OnTerrainDataChanged([[maybe_unused]] const AZ::Aabb& dirtyRegion, TerrainDataChangedMask dataChangedMask) + { + if ((dataChangedMask & (TerrainDataChangedMask::HeightData | TerrainDataChangedMask::Settings)) != 0) + { + AZ::Aabb worldBounds = AZ::Aabb::CreateNull(); + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + worldBounds, &AzFramework::Terrain::TerrainDataRequests::GetTerrainAabb); + + AZ::Vector2 queryResolution2D = AZ::Vector2(1.0f); + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + queryResolution2D, &AzFramework::Terrain::TerrainDataRequests::GetTerrainHeightQueryResolution); + // Currently query resolution is multidimensional but the rendering system only supports this changing in one dimension. + float queryResolution = queryResolution2D.GetX(); + + // Sectors need to be rebuilt if the world bounds change in the x/y, or the sample spacing changes. + m_rebuildSectors = m_rebuildSectors || + m_worldBounds.GetMin().GetX() != worldBounds.GetMin().GetX() || + m_worldBounds.GetMin().GetY() != worldBounds.GetMin().GetY() || + m_worldBounds.GetMax().GetX() != worldBounds.GetMax().GetX() || + m_worldBounds.GetMax().GetY() != worldBounds.GetMax().GetY() || + m_sampleSpacing != queryResolution; + + m_worldBounds = worldBounds; + m_sampleSpacing = queryResolution; + } + } + + void TerrainMeshManager::InitializeTerrainPatch(uint16_t gridSize, PatchData& patchdata) + { + patchdata.m_positions.clear(); + patchdata.m_indices.clear(); + + const uint16_t gridVertices = gridSize + 1; // For m_gridSize quads, (m_gridSize + 1) vertices are needed. + const size_t size = gridVertices * gridVertices; + + patchdata.m_positions.reserve(size); + + for (uint16_t y = 0; y < gridVertices; ++y) + { + for (uint16_t x = 0; x < gridVertices; ++x) + { + patchdata.m_positions.push_back({ aznumeric_cast(x) / gridSize, aznumeric_cast(y) / gridSize }); + } + } + + patchdata.m_indices.reserve(gridSize * gridSize * 6); // total number of quads, 2 triangles with 6 indices per quad. + + for (uint16_t y = 0; y < gridSize; ++y) + { + for (uint16_t x = 0; x < gridSize; ++x) + { + const uint16_t topLeft = y * gridVertices + x; + const uint16_t topRight = topLeft + 1; + const uint16_t bottomLeft = (y + 1) * gridVertices + x; + const uint16_t bottomRight = bottomLeft + 1; + + patchdata.m_indices.emplace_back(topLeft); + patchdata.m_indices.emplace_back(topRight); + patchdata.m_indices.emplace_back(bottomLeft); + patchdata.m_indices.emplace_back(bottomLeft); + patchdata.m_indices.emplace_back(topRight); + patchdata.m_indices.emplace_back(bottomRight); + } + } + } + + AZ::Outcome> TerrainMeshManager::CreateBufferAsset( + const void* data, const AZ::RHI::BufferViewDescriptor& bufferViewDescriptor, const AZStd::string& bufferName) + { + AZ::RPI::BufferAssetCreator creator; + creator.Begin(AZ::Uuid::CreateRandom()); + + AZ::RHI::BufferDescriptor bufferDescriptor; + bufferDescriptor.m_bindFlags = AZ::RHI::BufferBindFlags::InputAssembly | AZ::RHI::BufferBindFlags::ShaderRead; + bufferDescriptor.m_byteCount = static_cast(bufferViewDescriptor.m_elementSize) * static_cast(bufferViewDescriptor.m_elementCount); + + creator.SetBuffer(data, bufferDescriptor.m_byteCount, bufferDescriptor); + creator.SetBufferViewDescriptor(bufferViewDescriptor); + creator.SetUseCommonPool(AZ::RPI::CommonBufferPoolType::StaticInputAssembly); + + AZ::Data::Asset bufferAsset; + if (creator.End(bufferAsset)) + { + bufferAsset.SetHint(bufferName); + return AZ::Success(bufferAsset); + } + + return AZ::Failure(); + } + + bool TerrainMeshManager::InitializePatchModel() + { + AZ::RPI::ModelAssetCreator modelAssetCreator; + modelAssetCreator.Begin(AZ::Uuid::CreateRandom()); + + uint16_t gridSize = GridSize; + float gridSpacing = GridSpacing; + + for (uint32_t i = 0; i < AZ::RPI::ModelLodAsset::LodCountMax && gridSize > 0; ++i) + { + PatchData patchData; + InitializeTerrainPatch(gridSize, patchData); + + const auto positionBufferViewDesc = AZ::RHI::BufferViewDescriptor::CreateTyped(0, aznumeric_cast(patchData.m_positions.size()), AZ::RHI::Format::R32G32_FLOAT); + const auto positionsOutcome = CreateBufferAsset(patchData.m_positions.data(), positionBufferViewDesc, "TerrainPatchPositions"); + + const auto indexBufferViewDesc = AZ::RHI::BufferViewDescriptor::CreateTyped(0, aznumeric_cast(patchData.m_indices.size()), AZ::RHI::Format::R16_UINT); + const auto indicesOutcome = CreateBufferAsset(patchData.m_indices.data(), indexBufferViewDesc, "TerrainPatchIndices"); + + if (!positionsOutcome.IsSuccess() || !indicesOutcome.IsSuccess()) + { + AZ_Error(TerrainMeshManagerName, false, "Failed to create GPU buffers for Terrain"); + return false; + } + + AZ::RPI::ModelLodAssetCreator modelLodAssetCreator; + modelLodAssetCreator.Begin(AZ::Uuid::CreateRandom()); + + modelLodAssetCreator.BeginMesh(); + modelLodAssetCreator.AddMeshStreamBuffer(AZ::RHI::ShaderSemantic{ "POSITION" }, AZ::Name(), {positionsOutcome.GetValue(), positionBufferViewDesc}); + modelLodAssetCreator.SetMeshIndexBuffer({indicesOutcome.GetValue(), indexBufferViewDesc}); + + AZ::Aabb aabb = AZ::Aabb::CreateFromMinMax(AZ::Vector3(0.0, 0.0, 0.0), AZ::Vector3(GridMeters, GridMeters, 0.0)); + modelLodAssetCreator.SetMeshAabb(AZStd::move(aabb)); + modelLodAssetCreator.SetMeshName(AZ::Name("Terrain Patch")); + modelLodAssetCreator.EndMesh(); + + AZ::Data::Asset modelLodAsset; + modelLodAssetCreator.End(modelLodAsset); + + modelAssetCreator.AddLodAsset(AZStd::move(modelLodAsset)); + + gridSize = gridSize / 2; + gridSpacing *= 2.0f; + } + + AZ::Data::Asset modelAsset; + bool success = modelAssetCreator.End(modelAsset); + + m_patchModel = AZ::RPI::Model::FindOrCreate(modelAsset); + + return success; + } + + template + void TerrainMeshManager::ForOverlappingSectors(const AZ::Aabb& bounds, Callback callback) + { + for (SectorData& sectorData : m_sectorData) + { + if (sectorData.m_aabb.Overlaps(bounds)) + { + callback(sectorData); + } + } + } + +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMeshManager.h b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMeshManager.h new file mode 100644 index 0000000000..7252a85686 --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/TerrainMeshManager.h @@ -0,0 +1,117 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include +#include +#include +#include + +#include + +#include + +#include +#include +#include + +#include + + +namespace AZ::RPI +{ + class BufferAsset; +} + +namespace AZ::RHI +{ + struct BufferViewDescriptor; +} + +namespace Terrain +{ + class TerrainMeshManager + : private AzFramework::Terrain::TerrainDataNotificationBus::Handler + { + private: + + using MaterialInstance = AZ::Data::Instance; + + public: + + AZ_RTTI(TerrainMeshManager, "{62C84AD8-05FE-4C78-8501-A2DB6731B9B7}"); + AZ_DISABLE_COPY_MOVE(TerrainMeshManager); + + TerrainMeshManager() = default; + ~TerrainMeshManager() = default; + + void Initialize(); + bool IsInitialized() const; + void Reset(); + + bool CheckRebuildSurfaces(MaterialInstance materialInstance, AZ::RPI::Scene& parentScene); + void DrawMeshes(const AZ::RPI::FeatureProcessor::RenderPacket& process); + void RebuildDrawPackets(AZ::RPI::Scene& scene); + + static constexpr float GridSpacing{ 1.0f }; + static constexpr int32_t GridSize{ 64 }; // number of terrain quads (vertices are m_gridSize + 1) + static constexpr float GridMeters{ GridSpacing * GridSize }; + static constexpr uint32_t MaxMaterialsPerSector = 4; + + private: + + struct VertexPosition + { + float m_posx; + float m_posy; + }; + + struct PatchData + { + AZStd::vector m_positions; + AZStd::vector m_indices; + }; + + struct SectorData + { + AZStd::fixed_vector m_drawPackets; + AZStd::fixed_vector, AZ::RPI::ModelLodAsset::LodCountMax> m_srgs; // Hold on to refs so it's not dropped + AZ::Aabb m_aabb; + }; + + struct ShaderTerrainData // Must align with struct in Object Srg + { + AZStd::array m_xyTranslation{ 0.0f, 0.0f }; + float m_xyScale{ 1.0f }; + }; + + // AzFramework::Terrain::TerrainDataNotificationBus overrides... + void OnTerrainDataDestroyBegin() override; + void OnTerrainDataChanged(const AZ::Aabb& dirtyRegion, TerrainDataChangedMask dataChangedMask) override; + + AZ::Outcome> CreateBufferAsset( + const void* data, const AZ::RHI::BufferViewDescriptor& bufferViewDescriptor, const AZStd::string& bufferName); + + void InitializeTerrainPatch(uint16_t gridSize, PatchData& patchdata); + bool InitializePatchModel(); + + template + void ForOverlappingSectors(const AZ::Aabb& bounds, Callback callback); + + AZStd::vector m_sectorData; + AZ::Data::Instance m_patchModel; + + AZ::Aabb m_worldBounds{ AZ::Aabb::CreateNull() }; + float m_sampleSpacing = 1.0f; + + bool m_isInitialized{ false }; + bool m_rebuildSectors{ true }; + + }; +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/Vector2i.cpp b/Gems/Terrain/Code/Source/TerrainRenderer/Vector2i.cpp new file mode 100644 index 0000000000..1df945b88c --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/Vector2i.cpp @@ -0,0 +1,41 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#include + +namespace Terrain +{ + auto Vector2i::operator+(const Vector2i& rhs) const -> Vector2i + { + Vector2i offsetPoint = *this; + offsetPoint += rhs; + return offsetPoint; + } + + auto Vector2i::operator+=(const Vector2i& rhs) -> Vector2i& + { + m_x += rhs.m_x; + m_y += rhs.m_y; + return *this; + } + + auto Vector2i::operator-(const Vector2i& rhs) const -> Vector2i + { + return *this + -rhs; + } + + auto Vector2i::operator-=(const Vector2i& rhs) -> Vector2i& + { + return *this += -rhs; + } + + auto Vector2i::operator-() const -> Vector2i + { + return {-m_x, -m_y}; + } +} diff --git a/Gems/Terrain/Code/Source/TerrainRenderer/Vector2i.h b/Gems/Terrain/Code/Source/TerrainRenderer/Vector2i.h new file mode 100644 index 0000000000..1244972fe9 --- /dev/null +++ b/Gems/Terrain/Code/Source/TerrainRenderer/Vector2i.h @@ -0,0 +1,29 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#pragma once + +#include + +namespace Terrain +{ + class Vector2i + { + public: + + Vector2i operator+(const Vector2i& rhs) const; + Vector2i& operator+=(const Vector2i& rhs); + Vector2i operator-(const Vector2i& rhs) const; + Vector2i& operator-=(const Vector2i& rhs); + Vector2i operator-() const; + + int32_t m_x{ 0 }; + int32_t m_y{ 0 }; + + }; +} diff --git a/Gems/Terrain/Code/Source/TerrainSystem/TerrainSystem.cpp b/Gems/Terrain/Code/Source/TerrainSystem/TerrainSystem.cpp index bc951f7c48..2ecd13b5ad 100644 --- a/Gems/Terrain/Code/Source/TerrainSystem/TerrainSystem.cpp +++ b/Gems/Terrain/Code/Source/TerrainSystem/TerrainSystem.cpp @@ -25,10 +25,12 @@ bool TerrainLayerPriorityComparator::operator()(const AZ::EntityId& layer1id, co { // Comparator for insertion/keylookup. // Sorts into layer/priority order, highest priority first. - AZ::u32 priority1, layer1; + AZ::u32 priority1 = 0; + AZ::u32 layer1 = 0; Terrain::TerrainSpawnerRequestBus::Event(layer1id, &Terrain::TerrainSpawnerRequestBus::Events::GetPriority, layer1, priority1); - AZ::u32 priority2, layer2; + AZ::u32 priority2 = 0; + AZ::u32 layer2 = 0; Terrain::TerrainSpawnerRequestBus::Event(layer2id, &Terrain::TerrainSpawnerRequestBus::Events::GetPriority, layer2, priority2); if (layer1 < layer2) @@ -80,7 +82,7 @@ void TerrainSystem::Activate() m_requestedSettings.m_systemActive = true; { - AZStd::shared_lock lock(m_areaMutex); + AZStd::unique_lock lock(m_areaMutex); m_registeredAreas.clear(); } @@ -103,13 +105,15 @@ void TerrainSystem::Activate() void TerrainSystem::Deactivate() { + // Stop listening to the bus even before we signal DestroyBegin so that way any calls to the terrain system as a *result* of + // calling DestroyBegin will fail to reach the terrain system. + AzFramework::Terrain::TerrainDataRequestBus::Handler::BusDisconnect(); + AzFramework::Terrain::TerrainDataNotificationBus::Broadcast( &AzFramework::Terrain::TerrainDataNotificationBus::Events::OnTerrainDataDestroyBegin); - AzFramework::Terrain::TerrainDataRequestBus::Handler::BusDisconnect(); - { - AZStd::shared_lock lock(m_areaMutex); + AZStd::unique_lock lock(m_areaMutex); m_registeredAreas.clear(); } @@ -163,8 +167,7 @@ void TerrainSystem::ClampPosition(float x, float y, AZ::Vector2& outPosition, AZ bool TerrainSystem::InWorldBounds(float x, float y) const { - const float zTestValue = m_currentSettings.m_worldBounds.GetMin().GetX() + - ((m_currentSettings.m_worldBounds.GetMax().GetX() - m_currentSettings.m_worldBounds.GetMin().GetX()) / 2.0f); + const float zTestValue = m_currentSettings.m_worldBounds.GetMin().GetZ(); const AZ::Vector3 testValue{ x, y, zTestValue }; if (m_currentSettings.m_worldBounds.Contains(testValue)) { @@ -527,40 +530,201 @@ const char* TerrainSystem::GetMaxSurfaceName( return ""; } -/* +void TerrainSystem::ProcessHeightsFromList( + const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + if (!perPositionCallback) + { + return; + } + + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (const auto& position : inPositions) + { + bool terrainExists = false; + surfacePoint.m_position = position; + surfacePoint.m_position.SetZ(GetHeight(position, sampleFilter, &terrainExists)); + perPositionCallback(surfacePoint, terrainExists); + } +} -void TerrainSystem::ProcessHeightsFromRegion(const AZ::Aabb& inRegion, const AZ::Vector2 stepSize, Sampler sampleFilter, SurfacePointRegionFillCallback perPositionCallback, TerrainDataReadyCallback onComplete) +void TerrainSystem::ProcessNormalsFromList( + const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter) const { - // Don't bother processing if we don't have a callback if (!perPositionCallback) { return; } - uint32_t numSamplesX = static_cast((inRegion.GetMax().GetX() - inRegion.GetMin().GetX()) / stepSize.GetX()); - uint32_t numSamplesY = static_cast((inRegion.GetMax().GetY() - inRegion.GetMin().GetY()) / stepSize.GetY()); + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (const auto& position : inPositions) + { + bool terrainExists = false; + surfacePoint.m_position = position; + surfacePoint.m_normal = GetNormal(position, sampleFilter, &terrainExists); + perPositionCallback(surfacePoint, terrainExists); + } +} - for (uint32_t y = 0; y < numSamplesY; y++) +void TerrainSystem::ProcessSurfaceWeightsFromList( + const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + if (!perPositionCallback) { - for (uint32_t x = 0; x < numSamplesX; x++) - { - float fx = (float)(inRegion.GetMin().GetX() + (x * stepSize.GetX())); - float fy = (float)(inRegion.GetMin().GetY() + (y * stepSize.GetY())); + return; + } - SurfaceData::SurfacePoint surfacePoint; - GetHeight(AZ::Vector3(fx, fy, 0.0f), sampleFilter, surfacePoint.m_position); - perPositionCallback(surfacePoint, x, y); - } + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (const auto& position : inPositions) + { + bool terrainExists = false; + surfacePoint.m_position = position; + GetSurfaceWeights(position, surfacePoint.m_surfaceTags, sampleFilter, &terrainExists); + perPositionCallback(surfacePoint, terrainExists); + } +} + +void TerrainSystem::ProcessSurfacePointsFromList( + const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + if (!perPositionCallback) + { + return; + } + + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (const auto& position : inPositions) + { + bool terrainExists = false; + surfacePoint.m_position = position; + GetSurfacePoint(position, surfacePoint, sampleFilter, &terrainExists); + perPositionCallback(surfacePoint, terrainExists); + } +} + +void TerrainSystem::ProcessHeightsFromListOfVector2( + const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + if (!perPositionCallback) + { + return; + } + + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (const auto& position : inPositions) + { + bool terrainExists = false; + surfacePoint.m_position.Set(position.GetX(), position.GetY(), 0.0f); + surfacePoint.m_position.SetZ(GetHeightFromVector2(position, sampleFilter, &terrainExists)); + perPositionCallback(surfacePoint, terrainExists); + } +} + +void TerrainSystem::ProcessNormalsFromListOfVector2( + const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + if (!perPositionCallback) + { + return; + } + + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (const auto& position : inPositions) + { + bool terrainExists = false; + surfacePoint.m_position.Set(position.GetX(), position.GetY(), 0.0f); + surfacePoint.m_normal = GetNormalFromVector2(position, sampleFilter, &terrainExists); + perPositionCallback(surfacePoint, terrainExists); + } +} + +void TerrainSystem::ProcessSurfaceWeightsFromListOfVector2( + const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + if (!perPositionCallback) + { + return; } - if (onComplete) + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (const auto& position : inPositions) { - onComplete(); + bool terrainExists = false; + surfacePoint.m_position.Set(position.GetX(), position.GetY(), 0.0f); + GetSurfaceWeightsFromVector2(position, surfacePoint.m_surfaceTags, sampleFilter, &terrainExists); + perPositionCallback(surfacePoint, terrainExists); } } +void TerrainSystem::ProcessSurfacePointsFromListOfVector2( + const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + if (!perPositionCallback) + { + return; + } + + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (const auto& position : inPositions) + { + bool terrainExists = false; + surfacePoint.m_position.Set(position.GetX(), position.GetY(), 0.0f); + GetSurfacePointFromVector2(position, surfacePoint, sampleFilter, &terrainExists); + perPositionCallback(surfacePoint, terrainExists); + } +} + +void TerrainSystem::ProcessHeightsFromRegion( + const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + AzFramework::Terrain::SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + // Don't bother processing if we don't have a callback + if (!perPositionCallback) + { + return; + } + + const size_t numSamplesX = aznumeric_cast(ceil(inRegion.GetExtents().GetX() / stepSize.GetX())); + const size_t numSamplesY = aznumeric_cast(ceil(inRegion.GetExtents().GetY() / stepSize.GetY())); + + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (size_t y = 0; y < numSamplesY; y++) + { + float fy = aznumeric_cast(inRegion.GetMin().GetY() + (y * stepSize.GetY())); + for (size_t x = 0; x < numSamplesX; x++) + { + bool terrainExists = false; + float fx = aznumeric_cast(inRegion.GetMin().GetX() + (x * stepSize.GetX())); + surfacePoint.m_position.Set(fx, fy, 0.0f); + surfacePoint.m_position.SetZ(GetHeight(surfacePoint.m_position, sampleFilter, &terrainExists)); + perPositionCallback(x, y, surfacePoint, terrainExists); + } + } +} -void TerrainSystem::ProcessSurfacePointsFromRegion(const AZ::Aabb& inRegion, const AZ::Vector2 stepSize, Sampler sampleFilter, SurfacePointRegionFillCallback perPositionCallback, TerrainDataReadyCallback onComplete) +void TerrainSystem::ProcessNormalsFromRegion( + const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + AzFramework::Terrain::SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter) const { // Don't bother processing if we don't have a callback if (!perPositionCallback) @@ -568,28 +732,83 @@ void TerrainSystem::ProcessSurfacePointsFromRegion(const AZ::Aabb& inRegion, con return; } - uint32_t numSamplesX = static_cast((inRegion.GetMax().GetX() - inRegion.GetMin().GetX()) / stepSize.GetX()); - uint32_t numSamplesY = static_cast((inRegion.GetMax().GetY() - inRegion.GetMin().GetY()) / stepSize.GetY()); + const size_t numSamplesX = aznumeric_cast(ceil(inRegion.GetExtents().GetX() / stepSize.GetX())); + const size_t numSamplesY = aznumeric_cast(ceil(inRegion.GetExtents().GetY() / stepSize.GetY())); - for (uint32_t y = 0; y < numSamplesY; y++) + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (size_t y = 0; y < numSamplesY; y++) { - for (uint32_t x = 0; x < numSamplesX; x++) + float fy = aznumeric_cast(inRegion.GetMin().GetY() + (y * stepSize.GetY())); + for (size_t x = 0; x < numSamplesX; x++) { - float fx = (float)(inRegion.GetMin().GetX() + (x * stepSize.GetX())); - float fy = (float)(inRegion.GetMin().GetY() + (y * stepSize.GetY())); + bool terrainExists = false; + float fx = aznumeric_cast(inRegion.GetMin().GetX() + (x * stepSize.GetX())); + surfacePoint.m_position.Set(fx, fy, 0.0f); + surfacePoint.m_normal = GetNormal(surfacePoint.m_position, sampleFilter, &terrainExists); + perPositionCallback(x, y, surfacePoint, terrainExists); + } + } +} + +void TerrainSystem::ProcessSurfaceWeightsFromRegion( + const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + AzFramework::Terrain::SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + // Don't bother processing if we don't have a callback + if (!perPositionCallback) + { + return; + } + + const size_t numSamplesX = aznumeric_cast(ceil(inRegion.GetExtents().GetX() / stepSize.GetX())); + const size_t numSamplesY = aznumeric_cast(ceil(inRegion.GetExtents().GetY() / stepSize.GetY())); - SurfaceData::SurfacePoint surfacePoint; - GetSurfacePoint(AZ::Vector3(fx, fy, inRegion.GetMin().GetZ()), sampleFilter, surfacePoint); - perPositionCallback(surfacePoint, x, y); + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (size_t y = 0; y < numSamplesY; y++) + { + float fy = aznumeric_cast(inRegion.GetMin().GetY() + (y * stepSize.GetY())); + for (size_t x = 0; x < numSamplesX; x++) + { + bool terrainExists = false; + float fx = aznumeric_cast(inRegion.GetMin().GetX() + (x * stepSize.GetX())); + surfacePoint.m_position.Set(fx, fy, 0.0f); + GetSurfaceWeights(surfacePoint.m_position, surfacePoint.m_surfaceTags, sampleFilter, &terrainExists); + perPositionCallback(x, y, surfacePoint, terrainExists); } } +} - if (onComplete) +void TerrainSystem::ProcessSurfacePointsFromRegion( + const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + AzFramework::Terrain::SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter) const +{ + // Don't bother processing if we don't have a callback + if (!perPositionCallback) { - onComplete(); + return; + } + + const size_t numSamplesX = aznumeric_cast(ceil(inRegion.GetExtents().GetX() / stepSize.GetX())); + const size_t numSamplesY = aznumeric_cast(ceil(inRegion.GetExtents().GetY() / stepSize.GetY())); + + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (size_t y = 0; y < numSamplesY; y++) + { + float fy = aznumeric_cast(inRegion.GetMin().GetY() + (y * stepSize.GetY())); + for (size_t x = 0; x < numSamplesX; x++) + { + bool terrainExists = false; + float fx = aznumeric_cast(inRegion.GetMin().GetX() + (x * stepSize.GetX())); + surfacePoint.m_position.Set(fx, fy, 0.0f); + GetSurfacePoint(surfacePoint.m_position, surfacePoint, sampleFilter, &terrainExists); + perPositionCallback(x, y, surfacePoint, terrainExists); + } } } -*/ void TerrainSystem::RegisterArea(AZ::EntityId areaId) { diff --git a/Gems/Terrain/Code/Source/TerrainSystem/TerrainSystem.h b/Gems/Terrain/Code/Source/TerrainSystem/TerrainSystem.h index d7267476ed..7c6e0cd91e 100644 --- a/Gems/Terrain/Code/Source/TerrainSystem/TerrainSystem.h +++ b/Gems/Terrain/Code/Source/TerrainSystem/TerrainSystem.h @@ -14,6 +14,7 @@ #include #include #include +#include #include #include @@ -135,6 +136,52 @@ namespace Terrain Sampler sampleFilter = Sampler::DEFAULT, bool* terrainExistsPtr = nullptr) const override; + //! Given a list of XY coordinates, call the provided callback function with surface data corresponding to each + //! XY coordinate in the list. + virtual void ProcessHeightsFromList(const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessNormalsFromList(const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessSurfaceWeightsFromList(const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessSurfacePointsFromList(const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessHeightsFromListOfVector2(const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessNormalsFromListOfVector2(const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessSurfaceWeightsFromListOfVector2(const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessSurfacePointsFromListOfVector2(const AZStd::span& inPositions, + AzFramework::Terrain::SurfacePointListFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + + //! Given a region(aabb) and a step size, call the provided callback function with surface data corresponding to the + //! coordinates in the region. + virtual void ProcessHeightsFromRegion(const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + AzFramework::Terrain::SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessNormalsFromRegion(const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + AzFramework::Terrain::SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessSurfaceWeightsFromRegion(const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + AzFramework::Terrain::SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + virtual void ProcessSurfacePointsFromRegion(const AZ::Aabb& inRegion, + const AZ::Vector2& stepSize, + AzFramework::Terrain::SurfacePointRegionFillCallback perPositionCallback, + Sampler sampleFilter = Sampler::DEFAULT) const override; + private: void ClampPosition(float x, float y, AZ::Vector2& outPosition, AZ::Vector2& normalizedDelta) const; diff --git a/Gems/Terrain/Code/Tests/TerrainSystemBenchmarks.cpp b/Gems/Terrain/Code/Tests/TerrainSystemBenchmarks.cpp new file mode 100644 index 0000000000..85dd5dc0c4 --- /dev/null +++ b/Gems/Terrain/Code/Tests/TerrainSystemBenchmarks.cpp @@ -0,0 +1,683 @@ +/* + * Copyright (c) Contributors to the Open 3D Engine Project. + * For complete copyright and license terms please see the LICENSE at the root of this distribution. + * + * SPDX-License-Identifier: Apache-2.0 OR MIT + * + */ + +#ifdef HAVE_BENCHMARK + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include + +#include +#include + +#include +#include +#include +#include + +#include + +namespace UnitTest +{ + using ::testing::NiceMock; + using ::testing::Return; + + class TerrainSystemBenchmarkFixture + : public UnitTest::AllocatorsBenchmarkFixture + , public UnitTest::TraceBusRedirector + { + public: + void SetUp(const benchmark::State& state) override + { + InternalSetUp(state); + } + void SetUp(benchmark::State& state) override + { + InternalSetUp(state); + } + + void TearDown(const benchmark::State& state) override + { + InternalTearDown(state); + } + void TearDown(benchmark::State& state) override + { + InternalTearDown(state); + } + + void InternalSetUp(const benchmark::State& state) + { + AZ::Debug::TraceMessageBus::Handler::BusConnect(); + UnitTest::AllocatorsBenchmarkFixture::SetUp(state); + + m_app = AZStd::make_unique(); + ASSERT_TRUE(m_app != nullptr); + + AZ::ComponentApplication::Descriptor componentAppDesc; + + AZ::Entity* systemEntity = m_app->Create(componentAppDesc); + ASSERT_TRUE(systemEntity != nullptr); + m_app->AddEntity(systemEntity); + + AZ::AllocatorInstance::Create(); + } + + void InternalTearDown(const benchmark::State& state) + { + AZ::AllocatorInstance::Destroy(); + + m_app->Destroy(); + m_app.reset(); + + UnitTest::AllocatorsBenchmarkFixture::TearDown(state); + AZ::Debug::TraceMessageBus::Handler::BusDisconnect(); + } + + AZStd::unique_ptr CreateEntity() + { + return AZStd::make_unique(); + } + + void ActivateEntity(AZ::Entity* entity) + { + entity->Init(); + entity->Activate(); + } + + template + Component* CreateComponent(AZ::Entity* entity, const Configuration& config) + { + m_app->RegisterComponentDescriptor(Component::CreateDescriptor()); + return entity->CreateComponent(config); + } + + template + Component* CreateComponent(AZ::Entity* entity) + { + m_app->RegisterComponentDescriptor(Component::CreateDescriptor()); + return entity->CreateComponent(); + } + + // Create a terrain system with reasonable defaults for testing, but with the ability to override the defaults + // on a test-by-test basis. + AZStd::unique_ptr CreateAndActivateTerrainSystem( + AZ::Vector2 queryResolution = AZ::Vector2(1.0f), + AZ::Aabb worldBounds = AZ::Aabb::CreateFromMinMax(AZ::Vector3(-128.0f), AZ::Vector3(128.0f))) + { + // Create the terrain system and give it one tick to fully initialize itself. + auto terrainSystem = AZStd::make_unique(); + terrainSystem->SetTerrainAabb(worldBounds); + terrainSystem->SetTerrainHeightQueryResolution(queryResolution); + terrainSystem->Activate(); + AZ::TickBus::Broadcast(&AZ::TickBus::Events::OnTick, 0.f, AZ::ScriptTimePoint{}); + return terrainSystem; + } + + // Create a mock shape bus listener that will listen to the given EntityId for shape requests and returns the following: + // - GetEncompassingAabb - returns the given Aabb + // - GetTransformAndLocalBounds - returns the center of the Aabb as the transform, and the size of the Aabb as the local bounds + // - IsPointInside - true if the point is in the Aabb, false if not + AZStd::unique_ptr> CreateMockShape( + const AZ::Aabb& spawnerBox, const AZ::EntityId& shapeEntityId) + { + AZStd::unique_ptr> mockShape = + AZStd::make_unique>(shapeEntityId); + + ON_CALL(*mockShape, GetEncompassingAabb).WillByDefault(Return(spawnerBox)); + ON_CALL(*mockShape, GetTransformAndLocalBounds) + .WillByDefault( + [spawnerBox](AZ::Transform& transform, AZ::Aabb& bounds) + { + transform = AZ::Transform::CreateTranslation(spawnerBox.GetCenter()); + bounds = spawnerBox.GetTranslated(-spawnerBox.GetCenter()); + }); + ON_CALL(*mockShape, IsPointInside) + .WillByDefault( + [spawnerBox](const AZ::Vector3& point) -> bool + { + return spawnerBox.Contains(point); + }); + + return mockShape; + } + + // Create an entity with a Random Gradient on it that can be used for gradient queries. + AZStd::unique_ptr CreateTestRandomGradientEntity(const AZ::Aabb& spawnerBox, uint32_t randomSeed) + { + // Create the base entity + AZStd::unique_ptr testGradientEntity = CreateEntity(); + + // Add a mock AABB Shape so that the shape requirement is fulfilled. + CreateComponent(testGradientEntity.get()); + + // Create the Random Gradient Component with some default parameters. + GradientSignal::RandomGradientConfig config; + config.m_randomSeed = randomSeed; + CreateComponent(testGradientEntity.get(), config); + + // Create the Gradient Transform Component with some default parameters. + GradientSignal::GradientTransformConfig gradientTransformConfig; + gradientTransformConfig.m_wrappingType = GradientSignal::WrappingType::None; + CreateComponent(testGradientEntity.get(), gradientTransformConfig); + + // Set the transform to match the given spawnerBox + auto transform = CreateComponent(testGradientEntity.get()); + transform->SetLocalTM(AZ::Transform::CreateTranslation(spawnerBox.GetCenter())); + transform->SetWorldTM(AZ::Transform::CreateTranslation(spawnerBox.GetCenter())); + + return testGradientEntity; + } + + AZStd::unique_ptr CreateTestLayerSpawnerEntity( + const AZ::Aabb& spawnerBox, const AZ::EntityId& heightGradientEntityId, + const Terrain::TerrainSurfaceGradientListConfig& surfaceConfig) + { + // Create the base entity + AZStd::unique_ptr testLayerSpawnerEntity = CreateEntity(); + + // Add a mock AABB Shape so that the shape requirement is fulfilled. + CreateComponent(testLayerSpawnerEntity.get()); + + // Add a Terrain Layer Spawner + CreateComponent(testLayerSpawnerEntity.get()); + + // Add a Terrain Height Gradient List with one entry pointing to the given gradient entity + Terrain::TerrainHeightGradientListConfig heightConfig; + heightConfig.m_gradientEntities.emplace_back(heightGradientEntityId); + CreateComponent(testLayerSpawnerEntity.get(), heightConfig); + + // Add a Terrain Surface Gradient List with however many entries we were given + CreateComponent(testLayerSpawnerEntity.get(), surfaceConfig); + + // Set the transform to match the given spawnerBox + auto transform = CreateComponent(testLayerSpawnerEntity.get()); + transform->SetLocalTM(AZ::Transform::CreateTranslation(spawnerBox.GetCenter())); + transform->SetWorldTM(AZ::Transform::CreateTranslation(spawnerBox.GetCenter())); + + return testLayerSpawnerEntity; + } + + void RunTerrainApiBenchmark( + benchmark::State& state, + AZStd::function ApiCaller) + { + // Get the ranges for querying from our benchmark parameters + float boundsRange = aznumeric_cast(state.range(0)); + uint32_t numSurfaces = aznumeric_cast(state.range(1)); + AzFramework::Terrain::TerrainDataRequests::Sampler sampler = + static_cast(state.range(2)); + + // Set up our world bounds and query resolution + AZ::Aabb worldBounds = AZ::Aabb::CreateFromMinMax(AZ::Vector3(-boundsRange / 2.0f), AZ::Vector3(boundsRange / 2.0f)); + AZ::Vector2 queryResolution = AZ::Vector2(1.0f); + + // Create a Random Gradient to use as our height provider + const uint32_t heightRandomSeed = 12345; + auto heightGradientEntity = CreateTestRandomGradientEntity(worldBounds, heightRandomSeed); + auto heightGradientShapeRequests = CreateMockShape(worldBounds, heightGradientEntity->GetId()); + ActivateEntity(heightGradientEntity.get()); + + + // Create a set of Random Gradients to use as our surface providers + Terrain::TerrainSurfaceGradientListConfig surfaceConfig; + AZStd::vector> surfaceGradientEntities; + AZStd::vector>> surfaceGradientShapeRequests; + for (uint32_t surfaces = 0; surfaces < numSurfaces; surfaces++) + { + const uint32_t surfaceRandomSeed = 23456 + surfaces; + auto surfaceGradientEntity = CreateTestRandomGradientEntity(worldBounds, surfaceRandomSeed); + auto shapeRequests = CreateMockShape(worldBounds, surfaceGradientEntity->GetId()); + ActivateEntity(surfaceGradientEntity.get()); + + // Give each gradient a new surface tag + surfaceConfig.m_gradientSurfaceMappings.emplace_back( + surfaceGradientEntity->GetId(), SurfaceData::SurfaceTag(AZStd::string::format("test%u", surfaces))); + + surfaceGradientEntities.emplace_back(AZStd::move(surfaceGradientEntity)); + surfaceGradientShapeRequests.emplace_back(AZStd::move(shapeRequests)); + } + + // Create a single Terrain Layer Spawner that covers the entire terrain world bounds + // (Do this *after* creating and activating the height and surface gradients) + auto testLayerSpawnerEntity = CreateTestLayerSpawnerEntity(worldBounds, heightGradientEntity->GetId(), surfaceConfig); + auto spawnerShapeRequests = CreateMockShape(worldBounds, testLayerSpawnerEntity->GetId()); + ActivateEntity(testLayerSpawnerEntity.get()); + + // Create the terrain system (do this after creating the terrain layer entity to ensure that we don't need any data refreshes) + auto terrainSystem = CreateAndActivateTerrainSystem(queryResolution, worldBounds); + + // Call the terrain API we're testing for every height and width in our ranges. + for (auto stateIterator : state) + { + ApiCaller(queryResolution, worldBounds, sampler); + } + + testLayerSpawnerEntity.reset(); + spawnerShapeRequests.reset(); + + heightGradientEntity.reset(); + heightGradientShapeRequests.reset(); + + surfaceGradientEntities.clear(); + surfaceGradientShapeRequests.clear(); + } + + void GenerateInputPositionsList(const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, AZStd::vector& positions) + { + const size_t numSamplesX = aznumeric_cast(ceil(worldBounds.GetExtents().GetX() / queryResolution.GetX())); + const size_t numSamplesY = aznumeric_cast(ceil(worldBounds.GetExtents().GetY() / queryResolution.GetY())); + + for (size_t y = 0; y < numSamplesY; y++) + { + float fy = aznumeric_cast(worldBounds.GetMin().GetY() + (y * queryResolution.GetY())); + for (size_t x = 0; x < numSamplesX; x++) + { + float fx = aznumeric_cast(worldBounds.GetMin().GetX() + (x * queryResolution.GetX())); + positions.emplace_back(fx, fy, 0.0f); + } + } + } + + protected: + AZStd::unique_ptr m_app; + }; + + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_GetHeight)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + []([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + float worldMinZ = worldBounds.GetMin().GetZ(); + + for (float y = worldBounds.GetMin().GetY(); y < worldBounds.GetMax().GetY(); y += 1.0f) + { + for (float x = worldBounds.GetMin().GetX(); x < worldBounds.GetMax().GetX(); x += 1.0f) + { + float terrainHeight = worldMinZ; + bool terrainExists = false; + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + terrainHeight, &AzFramework::Terrain::TerrainDataRequests::GetHeightFromFloats, x, y, sampler, &terrainExists); + benchmark::DoNotOptimize(terrainHeight); + } + } + }); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_GetHeight) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_ProcessHeightsRegion)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + []([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + auto perPositionCallback = []([[maybe_unused]] size_t xIndex, [[maybe_unused]] size_t yIndex, + const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + benchmark::DoNotOptimize(surfacePoint.m_position.GetZ()); + }; + + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::ProcessHeightsFromRegion, worldBounds, queryResolution, perPositionCallback, sampler); + } + ); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_ProcessHeightsRegion) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_ProcessHeightsList)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + [this]([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + AZStd::vector inPositions; + GenerateInputPositionsList(queryResolution, worldBounds, inPositions); + + auto perPositionCallback = [](const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + benchmark::DoNotOptimize(surfacePoint.m_position.GetZ()); + }; + + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::ProcessHeightsFromList, inPositions, perPositionCallback, sampler); + } + ); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_ProcessHeightsList) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 4096, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_GetNormal)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + []([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + for (float y = worldBounds.GetMin().GetY(); y < worldBounds.GetMax().GetY(); y += 1.0f) + { + for (float x = worldBounds.GetMin().GetX(); x < worldBounds.GetMax().GetX(); x += 1.0f) + { + AZ::Vector3 terrainNormal; + bool terrainExists = false; + AzFramework::Terrain::TerrainDataRequestBus::BroadcastResult( + terrainNormal, &AzFramework::Terrain::TerrainDataRequests::GetNormalFromFloats, x, y, sampler, &terrainExists); + benchmark::DoNotOptimize(terrainNormal); + } + } + }); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_GetNormal) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_ProcessNormalsRegion)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + []([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + auto perPositionCallback = []([[maybe_unused]] size_t xIndex, [[maybe_unused]] size_t yIndex, + const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + benchmark::DoNotOptimize(surfacePoint.m_normal); + }; + + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::ProcessNormalsFromRegion, worldBounds, queryResolution, perPositionCallback, sampler); + } + ); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_ProcessNormalsRegion) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_ProcessNormalsList)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + [this]([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + AZStd::vector inPositions; + GenerateInputPositionsList(queryResolution, worldBounds, inPositions); + + auto perPositionCallback = [](const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + benchmark::DoNotOptimize(surfacePoint.m_normal); + }; + + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::ProcessNormalsFromList, inPositions, perPositionCallback, sampler); + } + ); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_ProcessNormalsList) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_GetSurfaceWeights)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + []([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + AzFramework::SurfaceData::SurfaceTagWeightList surfaceWeights; + for (float y = worldBounds.GetMin().GetY(); y < worldBounds.GetMax().GetY(); y += 1.0f) + { + for (float x = worldBounds.GetMin().GetX(); x < worldBounds.GetMax().GetX(); x += 1.0f) + { + bool terrainExists = false; + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::GetSurfaceWeightsFromFloats, x, y, surfaceWeights, sampler, + &terrainExists); + benchmark::DoNotOptimize(surfaceWeights); + } + } + }); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_GetSurfaceWeights) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 1024, 2, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 2, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 1024, 4, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 4, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_ProcessSurfaceWeightsRegion)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + []([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + auto perPositionCallback = []([[maybe_unused]] size_t xIndex, [[maybe_unused]] size_t yIndex, + const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + benchmark::DoNotOptimize(surfacePoint.m_surfaceTags); + }; + + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::ProcessSurfaceWeightsFromRegion, worldBounds, queryResolution, perPositionCallback, sampler); + } + ); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_ProcessSurfaceWeightsRegion) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 1024, 2, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 2, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 1024, 4, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 4, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_ProcessSurfaceWeightsList)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + [this]([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + AZStd::vector inPositions; + GenerateInputPositionsList(queryResolution, worldBounds, inPositions); + + auto perPositionCallback = [](const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + benchmark::DoNotOptimize(surfacePoint.m_surfaceTags); + }; + + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::ProcessSurfaceWeightsFromList, inPositions, perPositionCallback, sampler); + } + ); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_ProcessSurfaceWeightsList) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 1024, 2, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 2, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 1024, 4, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 4, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_GetSurfacePoints)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + []([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + AzFramework::SurfaceData::SurfacePoint surfacePoint; + for (float y = worldBounds.GetMin().GetY(); y < worldBounds.GetMax().GetY(); y += 1.0f) + { + for (float x = worldBounds.GetMin().GetX(); x < worldBounds.GetMax().GetX(); x += 1.0f) + { + bool terrainExists = false; + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::GetSurfacePointFromFloats, x, y, surfacePoint, sampler, + &terrainExists); + benchmark::DoNotOptimize(surfacePoint); + } + } + }); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_GetSurfacePoints) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_ProcessSurfacePointsRegion)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + []([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + auto perPositionCallback = []([[maybe_unused]] size_t xIndex, [[maybe_unused]] size_t yIndex, + const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + benchmark::DoNotOptimize(surfacePoint); + }; + + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::ProcessSurfacePointsFromRegion, worldBounds, queryResolution, perPositionCallback, sampler); + } + ); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_ProcessSurfacePointsRegion) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); + + BENCHMARK_DEFINE_F(TerrainSystemBenchmarkFixture, BM_ProcessSurfacePointsList)(benchmark::State& state) + { + // Run the benchmark + RunTerrainApiBenchmark( + state, + [this]([[maybe_unused]] const AZ::Vector2& queryResolution, const AZ::Aabb& worldBounds, + AzFramework::Terrain::TerrainDataRequests::Sampler sampler) + { + AZStd::vector inPositions; + GenerateInputPositionsList(queryResolution, worldBounds, inPositions); + + auto perPositionCallback = [](const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + benchmark::DoNotOptimize(surfacePoint); + }; + + AzFramework::Terrain::TerrainDataRequestBus::Broadcast( + &AzFramework::Terrain::TerrainDataRequests::ProcessSurfacePointsFromList, inPositions, perPositionCallback, sampler); + } + ); + } + + BENCHMARK_REGISTER_F(TerrainSystemBenchmarkFixture, BM_ProcessSurfacePointsList) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::CLAMP) }) + ->Args({ 1024, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Args({ 2048, 1, static_cast(AzFramework::Terrain::TerrainDataRequests::Sampler::EXACT) }) + ->Unit(::benchmark::kMillisecond); +#endif + +} diff --git a/Gems/Terrain/Code/Tests/TerrainSystemTest.cpp b/Gems/Terrain/Code/Tests/TerrainSystemTest.cpp index e5434c0a1d..a5798a3dad 100644 --- a/Gems/Terrain/Code/Tests/TerrainSystemTest.cpp +++ b/Gems/Terrain/Code/Tests/TerrainSystemTest.cpp @@ -41,6 +41,28 @@ namespace UnitTest float m_expectedHeight = 0.0f; }; + struct NormalTestPoint + { + AZ::Vector2 m_testLocation = AZ::Vector2::CreateZero(); + AZ::Vector3 m_expectedNormal = AZ::Vector3::CreateZero(); + }; + + struct HeightTestRegionPoints + { + size_t m_xIndex; + size_t m_yIndex; + float m_expectedHeight; + AZ::Vector2 m_testLocation = AZ::Vector2::CreateZero(); + }; + + struct NormalTestRegionPoints + { + size_t m_xIndex; + size_t m_yIndex; + AZ::Vector3 m_expectedNormal = AZ::Vector3::CreateZero(); + AZ::Vector2 m_testLocation = AZ::Vector2::CreateZero(); + }; + AZ::ComponentApplication m_app; AZStd::unique_ptr> m_boxShapeRequests; @@ -572,4 +594,312 @@ namespace UnitTest EXPECT_EQ(tagWeight.m_surfaceType, tagWeight1.m_surfaceType); EXPECT_NEAR(tagWeight.m_weight, tagWeight1.m_weight, 0.01f); } + + TEST_F(TerrainSystemTest, TerrainProcessHeightsFromListWithBilinearSamplers) + { + // This repeats the same test as TerrainHeightQueriesWithBilinearSamplersUseQueryGridToInterpolate + // The difference is that it tests the ProcessHeightsFromList variation. + + const AZ::Aabb spawnerBox = AZ::Aabb::CreateFromMinMaxValues(-10.0f, -10.0f, -5.0f, 10.0f, 10.0f, 15.0f); + const float amplitudeMeters = 10.0f; + const float frequencyMeters = 1.0f; + auto entity = CreateAndActivateMockTerrainLayerSpawner( + spawnerBox, + [amplitudeMeters, frequencyMeters](AZ::Vector3& position, bool& terrainExists) + { + // Our generated height will be X + Y. + float expectedHeight = position.GetX() + position.GetY(); + + // If either X or Y aren't evenly divisible by the query frequency, add a scaled value to our generated height. + // This will show up as an unexpected height "spike" if it gets used in any bilinear filter queries. + float unexpectedVariance = + amplitudeMeters * (fmodf(position.GetX(), frequencyMeters) + fmodf(position.GetY(), frequencyMeters)); + position.SetZ(expectedHeight + unexpectedVariance); + terrainExists = true; + }); + + // Create and activate the terrain system with our testing defaults for world bounds, and a query resolution at 1 meter intervals. + const AZ::Vector2 queryResolution(frequencyMeters); + auto terrainSystem = CreateAndActivateTerrainSystem(queryResolution); + + // Test some points and verify that the results are the expected bilinear filtered result, + // whether they're in positive or negative space. + // (Z contains the the expected result for convenience). + const HeightTestPoint testPoints[] = { + + // Queries directly on grid points. These should return values of X + Y. + { AZ::Vector2(0.0f, 0.0f), 0.0f }, // Should return a height of 0 + 0 + { AZ::Vector2(1.0f, 0.0f), 1.0f }, // Should return a height of 1 + 0 + { AZ::Vector2(0.0f, 1.0f), 1.0f }, // Should return a height of 0 + 1 + { AZ::Vector2(1.0f, 1.0f), 2.0f }, // Should return a height of 1 + 1 + { AZ::Vector2(3.0f, 5.0f), 8.0f }, // Should return a height of 3 + 5 + + { AZ::Vector2(-1.0f, 0.0f), -1.0f }, // Should return a height of -1 + 0 + { AZ::Vector2(0.0f, -1.0f), -1.0f }, // Should return a height of 0 + -1 + { AZ::Vector2(-1.0f, -1.0f), -2.0f }, // Should return a height of -1 + -1 + { AZ::Vector2(-3.0f, -5.0f), -8.0f }, // Should return a height of -3 + -5 + + // Queries that are on a grid edge (one axis on the grid, the other somewhere in-between). + // These should just be a linear interpolation of the points, so it should still be X + Y. + + { AZ::Vector2(0.25f, 0.0f), 0.25f }, // Should return a height of -0.25 + 0 + { AZ::Vector2(3.75f, 0.0f), 3.75f }, // Should return a height of -3.75 + 0 + { AZ::Vector2(0.0f, 0.25f), 0.25f }, // Should return a height of 0 + -0.25 + { AZ::Vector2(0.0f, 3.75f), 3.75f }, // Should return a height of 0 + -3.75 + + { AZ::Vector2(2.0f, 3.75f), 5.75f }, // Should return a height of -2 + -3.75 + { AZ::Vector2(2.25f, 4.0f), 6.25f }, // Should return a height of -2.25 + -4 + + { AZ::Vector2(-0.25f, 0.0f), -0.25f }, // Should return a height of -0.25 + 0 + { AZ::Vector2(-3.75f, 0.0f), -3.75f }, // Should return a height of -3.75 + 0 + { AZ::Vector2(0.0f, -0.25f), -0.25f }, // Should return a height of 0 + -0.25 + { AZ::Vector2(0.0f, -3.75f), -3.75f }, // Should return a height of 0 + -3.75 + + { AZ::Vector2(-2.0f, -3.75f), -5.75f }, // Should return a height of -2 + -3.75 + { AZ::Vector2(-2.25f, -4.0f), -6.25f }, // Should return a height of -2.25 + -4 + + // Queries inside a grid square (both axes are in-between grid points) + // This is a full bilinear interpolation, but because we're using X + Y for our heights, the interpolated values + // should *still* be X + Y assuming the points were sampled correctly from the grid points. + + { AZ::Vector2(3.25f, 5.25f), 8.5f }, // Should return a height of 3.25 + 5.25 + { AZ::Vector2(7.71f, 9.74f), 17.45f }, // Should return a height of 7.71 + 9.74 + + { AZ::Vector2(-3.25f, -5.25f), -8.5f }, // Should return a height of -3.25 + -5.25 + { AZ::Vector2(-7.71f, -9.74f), -17.45f }, // Should return a height of -7.71 + -9.74 + }; + + auto perPositionCallback = [&testPoints](const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists){ + bool found = false; + for (auto& testPoint : testPoints) + { + if (testPoint.m_testLocation.GetX() == surfacePoint.m_position.GetX() && testPoint.m_testLocation.GetY() == surfacePoint.m_position.GetY()) + { + constexpr float epsilon = 0.0001f; + EXPECT_NEAR(surfacePoint.m_position.GetZ(), testPoint.m_expectedHeight, epsilon); + found = true; + break; + } + } + EXPECT_EQ(found, true); + }; + + AZStd::vector inPositions; + for (auto& testPoint : testPoints) + { + AZ::Vector3 position(testPoint.m_testLocation.GetX(), testPoint.m_testLocation.GetY(), 0.0f); + inPositions.push_back(position); + } + + terrainSystem->ProcessHeightsFromList(inPositions, perPositionCallback, AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR); + } + + TEST_F(TerrainSystemTest, TerrainProcessNormalsFromListWithBilinearSamplers) + { + // Similar to TerrainProcessHeightsFromListWithBilinearSamplers but for normals + + const AZ::Aabb spawnerBox = AZ::Aabb::CreateFromMinMaxValues(-10.0f, -10.0f, -5.0f, 10.0f, 10.0f, 15.0f); + const float amplitudeMeters = 10.0f; + const float frequencyMeters = 1.0f; + auto entity = CreateAndActivateMockTerrainLayerSpawner( + spawnerBox, + [amplitudeMeters, frequencyMeters](AZ::Vector3& position, bool& terrainExists) + { + // Our generated height will be X + Y. + float expectedHeight = position.GetX() + position.GetY(); + + // If either X or Y aren't evenly divisible by the query frequency, add a scaled value to our generated height. + // This will show up as an unexpected height "spike" if it gets used in any bilinear filter queries. + float unexpectedVariance = + amplitudeMeters * (fmodf(position.GetX(), frequencyMeters) + fmodf(position.GetY(), frequencyMeters)); + position.SetZ(expectedHeight + unexpectedVariance); + terrainExists = true; + }); + + // Create and activate the terrain system with our testing defaults for world bounds, and a query resolution at 1 meter intervals. + const AZ::Vector2 queryResolution(frequencyMeters); + auto terrainSystem = CreateAndActivateTerrainSystem(queryResolution); + + const NormalTestPoint testPoints[] = { + + { AZ::Vector2(0.0f, 0.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(1.0f, 0.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(0.0f, 1.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(1.0f, 1.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(3.0f, 5.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + + { AZ::Vector2(-1.0f, 0.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(0.0f, -1.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(-1.0f, -1.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(-3.0f, -5.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + + { AZ::Vector2(0.25f, 0.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(3.75f, 0.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(0.0f, 0.25f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(0.0f, 3.75f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + + { AZ::Vector2(2.0f, 3.75f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(2.25f, 4.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + + { AZ::Vector2(-0.25f, 0.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(-3.75f, 0.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(0.0f, -0.25f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(0.0f, -3.75f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + + { AZ::Vector2(-2.0f, -3.75f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(-2.25f, -4.0f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + + { AZ::Vector2(3.25f, 5.25f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(7.71f, 9.74f), AZ::Vector3(-0.0292f, 0.9991f, 0.0292f) }, + + { AZ::Vector2(-3.25f, -5.25f), AZ::Vector3(-0.5773f, -0.5773f, 0.5773f) }, + { AZ::Vector2(-7.71f, -9.74f), AZ::Vector3(-0.0366f, -0.9986f, 0.0366f) }, + }; + + auto perPositionCallback = [&testPoints](const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists){ + bool found = false; + for (auto& testPoint : testPoints) + { + if (testPoint.m_testLocation.GetX() == surfacePoint.m_position.GetX() && testPoint.m_testLocation.GetY() == surfacePoint.m_position.GetY()) + { + constexpr float epsilon = 0.0001f; + EXPECT_NEAR(surfacePoint.m_normal.GetX(), testPoint.m_expectedNormal.GetX(), epsilon); + EXPECT_NEAR(surfacePoint.m_normal.GetY(), testPoint.m_expectedNormal.GetY(), epsilon); + EXPECT_NEAR(surfacePoint.m_normal.GetZ(), testPoint.m_expectedNormal.GetZ(), epsilon); + found = true; + break; + } + } + EXPECT_EQ(found, true); + }; + + AZStd::vector inPositions; + for (auto& testPoint : testPoints) + { + AZ::Vector3 position(testPoint.m_testLocation.GetX(), testPoint.m_testLocation.GetY(), 0.0f); + inPositions.push_back(position); + } + + terrainSystem->ProcessNormalsFromList(inPositions, perPositionCallback, AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR); + } + + TEST_F(TerrainSystemTest, TerrainProcessHeightsFromRegionWithBilinearSamplers) + { + // This repeats the same test as TerrainHeightQueriesWithBilinearSamplersUseQueryGridToInterpolate + // The difference is that it tests the ProcessHeightsFromList variation. + + const AZ::Aabb spawnerBox = AZ::Aabb::CreateFromMinMaxValues(-10.0f, -10.0f, -5.0f, 10.0f, 10.0f, 15.0f); + const float amplitudeMeters = 10.0f; + const float frequencyMeters = 1.0f; + auto entity = CreateAndActivateMockTerrainLayerSpawner( + spawnerBox, + [amplitudeMeters, frequencyMeters](AZ::Vector3& position, bool& terrainExists) + { + // Our generated height will be X + Y. + float expectedHeight = position.GetX() + position.GetY(); + + // If either X or Y aren't evenly divisible by the query frequency, add a scaled value to our generated height. + // This will show up as an unexpected height "spike" if it gets used in any bilinear filter queries. + float unexpectedVariance = + amplitudeMeters * (fmodf(position.GetX(), frequencyMeters) + fmodf(position.GetY(), frequencyMeters)); + position.SetZ(expectedHeight + unexpectedVariance); + terrainExists = true; + }); + + // Create and activate the terrain system with our testing defaults for world bounds, and a query resolution at 1 meter intervals. + const AZ::Vector2 queryResolution(frequencyMeters); + auto terrainSystem = CreateAndActivateTerrainSystem(queryResolution); + + const AZ::Aabb testRegionBox = AZ::Aabb::CreateFromMinMaxValues(-1.0f, -1.0f, -1.0f, 1.0f, 1.0f, 1.0f); + const AZ::Vector2 stepSize(1.0f); + + const HeightTestRegionPoints testPoints[] = { + { 0, 0, -2.0f, AZ::Vector2(-1.0f, -1.0f) }, + { 1, 0, -1.0f, AZ::Vector2(0.0f, -1.0f) }, + { 0, 1, -1.0f, AZ::Vector2(-1.0f, 0.0f) }, + { 1, 1, 0.0f, AZ::Vector2(0.0f, 0.0f) }, + }; + + auto perPositionCallback = [&testPoints](size_t xIndex, size_t yIndex, + const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + bool found = false; + for (auto& testPoint : testPoints) + { + if (testPoint.m_xIndex == xIndex && testPoint.m_yIndex == yIndex + && testPoint.m_testLocation.GetX() == surfacePoint.m_position.GetX() + && testPoint.m_testLocation.GetY() == surfacePoint.m_position.GetY()) + { + constexpr float epsilon = 0.0001f; + EXPECT_NEAR(surfacePoint.m_position.GetZ(), testPoint.m_expectedHeight, epsilon); + found = true; + break; + } + } + EXPECT_EQ(found, true); + }; + + terrainSystem->ProcessHeightsFromRegion(testRegionBox, stepSize, perPositionCallback, AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR); + } + + TEST_F(TerrainSystemTest, TerrainProcessNormalsFromRegionWithBilinearSamplers) + { + // This repeats the same test as TerrainHeightQueriesWithBilinearSamplersUseQueryGridToInterpolate + // The difference is that it tests the ProcessHeightsFromList variation. + + const AZ::Aabb spawnerBox = AZ::Aabb::CreateFromMinMaxValues(-10.0f, -10.0f, -5.0f, 10.0f, 10.0f, 15.0f); + const float amplitudeMeters = 10.0f; + const float frequencyMeters = 1.0f; + auto entity = CreateAndActivateMockTerrainLayerSpawner( + spawnerBox, + [amplitudeMeters, frequencyMeters](AZ::Vector3& position, bool& terrainExists) + { + // Our generated height will be X + Y. + float expectedHeight = position.GetX() + position.GetY(); + + // If either X or Y aren't evenly divisible by the query frequency, add a scaled value to our generated height. + // This will show up as an unexpected height "spike" if it gets used in any bilinear filter queries. + float unexpectedVariance = + amplitudeMeters * (fmodf(position.GetX(), frequencyMeters) + fmodf(position.GetY(), frequencyMeters)); + position.SetZ(expectedHeight + unexpectedVariance); + terrainExists = true; + }); + + // Create and activate the terrain system with our testing defaults for world bounds, and a query resolution at 1 meter intervals. + const AZ::Vector2 queryResolution(frequencyMeters); + auto terrainSystem = CreateAndActivateTerrainSystem(queryResolution); + + const AZ::Aabb testRegionBox = AZ::Aabb::CreateFromMinMaxValues(-1.0f, -1.0f, -1.0f, 1.0f, 1.0f, 1.0f); + const AZ::Vector2 stepSize(1.0f); + + const NormalTestRegionPoints testPoints[] = { + { 0, 0, AZ::Vector3(-0.5773f, -0.5773f, 0.5773f), AZ::Vector2(-1.0f, -1.0f) }, + { 1, 0, AZ::Vector3(-0.5773f, -0.5773f, 0.5773f), AZ::Vector2(0.0f, -1.0f) }, + { 0, 1, AZ::Vector3(-0.5773f, -0.5773f, 0.5773f), AZ::Vector2(-1.0f, 0.0f) }, + { 1, 1, AZ::Vector3(-0.5773f, -0.5773f, 0.5773f), AZ::Vector2(0.0f, 0.0f) }, + }; + + auto perPositionCallback = [&testPoints](size_t xIndex, size_t yIndex, + const AzFramework::SurfaceData::SurfacePoint& surfacePoint, [[maybe_unused]] bool terrainExists) + { + bool found = false; + for (auto& testPoint : testPoints) + { + if (testPoint.m_xIndex == xIndex && testPoint.m_yIndex == yIndex + && testPoint.m_testLocation.GetX() == surfacePoint.m_position.GetX() + && testPoint.m_testLocation.GetY() == surfacePoint.m_position.GetY()) + { + constexpr float epsilon = 0.0001f; + EXPECT_NEAR(surfacePoint.m_normal.GetX(), testPoint.m_expectedNormal.GetX(), epsilon); + EXPECT_NEAR(surfacePoint.m_normal.GetY(), testPoint.m_expectedNormal.GetY(), epsilon); + EXPECT_NEAR(surfacePoint.m_normal.GetZ(), testPoint.m_expectedNormal.GetZ(), epsilon); + found = true; + break; + } + } + EXPECT_EQ(found, true); + }; + + terrainSystem->ProcessNormalsFromRegion(testRegionBox, stepSize, perPositionCallback, AzFramework::Terrain::TerrainDataRequests::Sampler::BILINEAR); + } } // namespace UnitTest diff --git a/Gems/Terrain/Code/terrain_files.cmake b/Gems/Terrain/Code/terrain_files.cmake index 3feacf6254..ab19d33618 100644 --- a/Gems/Terrain/Code/terrain_files.cmake +++ b/Gems/Terrain/Code/terrain_files.cmake @@ -8,6 +8,7 @@ set(FILES Include/Terrain/Ebuses/TerrainAreaSurfaceRequestBus.h + Include/Terrain/TerrainDataConstants.h Source/Components/TerrainHeightGradientListComponent.cpp Source/Components/TerrainHeightGradientListComponent.h Source/Components/TerrainLayerSpawnerComponent.cpp @@ -30,11 +31,23 @@ set(FILES Source/TerrainRenderer/Components/TerrainSurfaceMaterialsListComponent.h Source/TerrainRenderer/Components/TerrainMacroMaterialComponent.cpp Source/TerrainRenderer/Components/TerrainMacroMaterialComponent.h + Source/TerrainRenderer/Aabb2i.cpp + Source/TerrainRenderer/Aabb2i.h Source/TerrainRenderer/TerrainFeatureProcessor.cpp Source/TerrainRenderer/TerrainFeatureProcessor.h + Source/TerrainRenderer/TerrainDetailMaterialManager.cpp + Source/TerrainRenderer/TerrainDetailMaterialManager.h + Source/TerrainRenderer/TerrainMacroMaterialManager.cpp + Source/TerrainRenderer/TerrainMacroMaterialManager.h + Source/TerrainRenderer/TerrainMeshManager.cpp + Source/TerrainRenderer/TerrainMeshManager.h + Source/TerrainRenderer/BindlessImageArrayHandler.cpp + Source/TerrainRenderer/BindlessImageArrayHandler.h Source/TerrainRenderer/TerrainAreaMaterialRequestBus.h Source/TerrainRenderer/TerrainMacroMaterialBus.cpp Source/TerrainRenderer/TerrainMacroMaterialBus.h + Source/TerrainRenderer/Vector2i.cpp + Source/TerrainRenderer/Vector2i.h Source/TerrainSystem/TerrainSystem.cpp Source/TerrainSystem/TerrainSystem.h Source/TerrainSystem/TerrainSystemBus.h diff --git a/Gems/Terrain/Code/terrain_tests_files.cmake b/Gems/Terrain/Code/terrain_tests_files.cmake index 88de53f8cf..1a46fdd203 100644 --- a/Gems/Terrain/Code/terrain_tests_files.cmake +++ b/Gems/Terrain/Code/terrain_tests_files.cmake @@ -16,4 +16,5 @@ set(FILES Tests/TerrainHeightGradientListTests.cpp Tests/TerrainMacroMaterialTests.cpp Tests/TerrainSurfaceGradientListTests.cpp + Tests/TerrainSystemBenchmarks.cpp ) diff --git a/Gems/Terrain/Registry/Platform/Mac/AssetProcessorPlatformConfig.setreg b/Gems/Terrain/Registry/Platform/Mac/AssetProcessorPlatformConfig.setreg new file mode 100644 index 0000000000..ac0c854b19 --- /dev/null +++ b/Gems/Terrain/Registry/Platform/Mac/AssetProcessorPlatformConfig.setreg @@ -0,0 +1,16 @@ +{ + "Amazon": { + "AssetProcessor": { + "Settings": { + // The terrain shader doesn't work on mac due to unbounded arrays, so disable problematic materials and material types + // in the terrain gem to prevent dependencies from failing. + "Exclude Terrain DefaultPbrTerrain.material": { + "pattern": "^Materials/Terrain/DefaultPbrTerrain.material" + }, + "Exclude Terrain PbrTerrain.materialtype": { + "pattern": "^Materials/Terrain/PbrTerrain.materialtype" + } + } + } + } +} diff --git a/Gems/Terrain/gem.json b/Gems/Terrain/gem.json index 0ca470c4d3..f038eb4d90 100644 --- a/Gems/Terrain/gem.json +++ b/Gems/Terrain/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "summary": "The Terrain Gem is an experimental terrain system. The terrain system maps height, color, and surface data to regions of the world, provides gradient-based and shape-based authoring tools and workflows, includes specialized rendering for efficient display, and integrates with physics for physical simulation.", "canonical_tags": [ "Gem" diff --git a/Gems/TestAssetBuilder/gem.json b/Gems/TestAssetBuilder/gem.json index 68ed706499..96c3bb4ffb 100644 --- a/Gems/TestAssetBuilder/gem.json +++ b/Gems/TestAssetBuilder/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Test Asset Builder Gem is used to feature test Asset Processor.", "canonical_tags": [ diff --git a/Gems/TextureAtlas/Code/Source/TextureAtlasImpl.h b/Gems/TextureAtlas/Code/Source/TextureAtlasImpl.h index ce2f4826da..bb0ed650e5 100644 --- a/Gems/TextureAtlas/Code/Source/TextureAtlasImpl.h +++ b/Gems/TextureAtlas/Code/Source/TextureAtlasImpl.h @@ -33,7 +33,7 @@ namespace TextureAtlasNamespace struct hash_case_insensitive : public AZStd::hash { AZ_TYPE_INFO(hash_case_insensitive, "{FE0F4349-D80D-4286-8874-733966A32B29}"); - inline result_type operator()(const AZStd::string& value) const + inline size_t operator()(const AZStd::string& value) const { AZStd::string lowerStr = value; AZStd::to_lower(lowerStr.begin(), lowerStr.end()); diff --git a/Gems/TextureAtlas/gem.json b/Gems/TextureAtlas/gem.json index 142f0fb082..970982fb48 100644 --- a/Gems/TextureAtlas/gem.json +++ b/Gems/TextureAtlas/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Texture Atlas Gem provides the formatting for texture atlases from 2D textures for LyShine.", "canonical_tags": [ diff --git a/Gems/TickBusOrderViewer/gem.json b/Gems/TickBusOrderViewer/gem.json index a6a6fd23ac..78b4d96c5c 100644 --- a/Gems/TickBusOrderViewer/gem.json +++ b/Gems/TickBusOrderViewer/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The Tick Bus Order Viewer Gem provides a console variable that displays the order of runtime tick events.", "canonical_tags": [ diff --git a/Gems/Twitch/CMakeLists.txt b/Gems/Twitch/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/Twitch/CMakeLists.txt +++ b/Gems/Twitch/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/Twitch/Code/CMakeLists.txt b/Gems/Twitch/Code/CMakeLists.txt index 80c74e5bd4..75b18627cf 100644 --- a/Gems/Twitch/Code/CMakeLists.txt +++ b/Gems/Twitch/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/Common) ly_add_target( NAME Twitch.Static STATIC diff --git a/Gems/Twitch/gem.json b/Gems/Twitch/gem.json index 42ec1b971e..70386e057f 100644 --- a/Gems/Twitch/gem.json +++ b/Gems/Twitch/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Twitch Gem provides access to the Twitch API v5 SDK including social functions, channels, and other APIs.", "canonical_tags": [ @@ -12,7 +13,8 @@ "user_tags": [ "Network", "SDK", - "Multiplayer" + "Multiplayer", + "Twitch" ], "icon_path": "preview.png", "requirements": "", diff --git a/Gems/UiBasics/CMakeLists.txt b/Gems/UiBasics/CMakeLists.txt index 8d71bd08c7..9c3cf01d26 100644 --- a/Gems/UiBasics/CMakeLists.txt +++ b/Gems/UiBasics/CMakeLists.txt @@ -9,4 +9,5 @@ # This will export its "SourcePaths" to the generated "cmake_dependencies..assetbuilder.setreg" if(PAL_TRAIT_BUILD_HOST_TOOLS) ly_create_alias(NAME UiBasics.Builders NAMESPACE Gem) + ly_create_alias(NAME UiBasics.Tools NAMESPACE Gem) endif() diff --git a/Gems/UiBasics/gem.json b/Gems/UiBasics/gem.json index bb2416c235..4734aef779 100644 --- a/Gems/UiBasics/gem.json +++ b/Gems/UiBasics/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Asset", "summary": "The UI Basics Gem provides a collection of basic UI prefabs such as image, text, and button, that can be used with LyShine, the Open 3D Engine runtime User Interface system and editor.", "canonical_tags": [ diff --git a/Gems/Vegetation/Code/CMakeLists.txt b/Gems/Vegetation/Code/CMakeLists.txt index 53fa6bd59f..c5e2accc9e 100644 --- a/Gems/Vegetation/Code/CMakeLists.txt +++ b/Gems/Vegetation/Code/CMakeLists.txt @@ -24,6 +24,7 @@ ly_add_target( PRIVATE Gem::LmbrCentral Gem::SurfaceData + Legacy::CryCommon PUBLIC Gem::AtomLyIntegration_CommonFeatures.Static RUNTIME_DEPENDENCIES @@ -43,6 +44,7 @@ ly_add_target( BUILD_DEPENDENCIES PRIVATE Gem::Vegetation.Static + Legacy::CryCommon RUNTIME_DEPENDENCIES Gem::LmbrCentral Gem::GradientSignal @@ -72,6 +74,7 @@ if(PAL_TRAIT_BUILD_HOST_TOOLS) PRIVATE Gem::Vegetation.Static AZ::AzToolsFramework + Legacy::CryCommon RUNTIME_DEPENDENCIES Gem::LmbrCentral.Editor Gem::GradientSignal.Editor @@ -104,6 +107,7 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) AZ::AzFrameworkTestShared Gem::Vegetation.Static Gem::LmbrCentral.Mocks + Legacy::CryCommon ) ly_add_googletest( NAME Gem::Vegetation.Tests diff --git a/Gems/Vegetation/Code/Source/Components/AreaBlenderComponent.cpp b/Gems/Vegetation/Code/Source/Components/AreaBlenderComponent.cpp index 8bf48de58e..2025ed059f 100644 --- a/Gems/Vegetation/Code/Source/Components/AreaBlenderComponent.cpp +++ b/Gems/Vegetation/Code/Source/Components/AreaBlenderComponent.cpp @@ -224,7 +224,7 @@ namespace Vegetation bool result = true; - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependencies with vegetation entity references"); if (!m_isRequestInProgress) { m_isRequestInProgress = true; @@ -264,7 +264,7 @@ namespace Vegetation return; } - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependencies with vegetation entity references"); if (!m_isRequestInProgress) { m_isRequestInProgress = true; @@ -295,7 +295,7 @@ namespace Vegetation { AZ_PROFILE_FUNCTION(Entity); - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependencies with vegetation entity references"); if (!m_isRequestInProgress) { m_isRequestInProgress = true; @@ -320,7 +320,7 @@ namespace Vegetation LmbrCentral::ShapeComponentRequestsBus::EventResult(bounds, GetEntityId(), &LmbrCentral::ShapeComponentRequestsBus::Events::GetEncompassingAabb); } - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependencies with vegetation entity references"); if (!m_isRequestInProgress) { m_isRequestInProgress = true; @@ -344,7 +344,7 @@ namespace Vegetation AZ::u32 count = 0; - AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependences with vegetation entity references"); + AZ_WarningOnce("Vegetation", !m_isRequestInProgress, "Detected cyclic dependencies with vegetation entity references"); if (!m_isRequestInProgress) { m_isRequestInProgress = true; diff --git a/Gems/Vegetation/Code/Source/PrefabInstanceSpawner.cpp b/Gems/Vegetation/Code/Source/PrefabInstanceSpawner.cpp index b386f17cab..c7c0ef5d3d 100644 --- a/Gems/Vegetation/Code/Source/PrefabInstanceSpawner.cpp +++ b/Gems/Vegetation/Code/Source/PrefabInstanceSpawner.cpp @@ -342,7 +342,7 @@ namespace Vegetation // Create the EntitySpawnTicket here. This pointer is going to get handed off to the vegetation system as opaque instance data, // where it will be tracked and held onto for the lifetime of the vegetation instance. The vegetation system will pass it back // in to DestroyInstance at the end of the lifetime, so that's the one place where we will delete the ticket pointers. - AzFramework::EntitySpawnTicket* ticket = new AzFramework::EntitySpawnTicket(m_spawnableAsset); + AzFramework::EntitySpawnTicket* ticket = aznew AzFramework::EntitySpawnTicket(m_spawnableAsset); if (ticket->IsValid()) { // Track the ticket that we've created. diff --git a/Gems/Vegetation/Code/Tests/VegetationComponentFilterTests.cpp b/Gems/Vegetation/Code/Tests/VegetationComponentFilterTests.cpp index 221a2da432..bb1efb5ebd 100644 --- a/Gems/Vegetation/Code/Tests/VegetationComponentFilterTests.cpp +++ b/Gems/Vegetation/Code/Tests/VegetationComponentFilterTests.cpp @@ -108,7 +108,7 @@ namespace UnitTest Vegetation::SurfaceMaskDepthFilterConfig config; config.m_lowerDistance = -1000.0f; config.m_upperDistance = -0.5f; - config.m_depthComparisonTags.push_back(SurfaceData::Constants::s_terrainTagCrc); + config.m_depthComparisonTags.push_back(SurfaceData::Constants::s_unassignedTagCrc); Vegetation::SurfaceMaskDepthFilterComponent* component = nullptr; auto entity = CreateEntity(config, &component, [](AZ::Entity* e) @@ -120,7 +120,7 @@ namespace UnitTest mockSurfaceHandler.m_outPosition = AZ::Vector3::CreateZero(); mockSurfaceHandler.m_outNormal = AZ::Vector3::CreateAxisZ(); mockSurfaceHandler.m_outMasks.clear(); - mockSurfaceHandler.m_outMasks[SurfaceData::Constants::s_terrainTagCrc] = 1.0f; + mockSurfaceHandler.m_outMasks[SurfaceData::Constants::s_unassignedTagCrc] = 1.0f; // passes { diff --git a/Gems/Vegetation/gem.json b/Gems/Vegetation/gem.json index 75416933f0..8dfd3b3a59 100644 --- a/Gems/Vegetation/gem.json +++ b/Gems/Vegetation/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Vegetation Gem provides tools to place natural-looking vegetation in Open 3D Engine.", "canonical_tags": [ diff --git a/Gems/VideoPlaybackFramework/gem.json b/Gems/VideoPlaybackFramework/gem.json index 381738ab4b..9115148c50 100644 --- a/Gems/VideoPlaybackFramework/gem.json +++ b/Gems/VideoPlaybackFramework/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Video Playback Framework Gem provides the interface to play back video.", "canonical_tags": [ diff --git a/Gems/VirtualGamepad/Code/CMakeLists.txt b/Gems/VirtualGamepad/Code/CMakeLists.txt index d32834633f..6700004a30 100644 --- a/Gems/VirtualGamepad/Code/CMakeLists.txt +++ b/Gems/VirtualGamepad/Code/CMakeLists.txt @@ -21,7 +21,7 @@ ly_add_target( AZ::AzCore AZ::AzFramework Legacy::CryCommon - Gem::LyShine + Gem::LyShine.Clients.API ) ly_add_target( @@ -42,4 +42,4 @@ ly_add_target( # the virtual gamepad is needed everywhere except servers: ly_create_alias(NAME VirtualGamepad.Clients NAMESPACE Gem TARGETS Gem::VirtualGamepad) ly_create_alias(NAME VirtualGamepad.Tools NAMESPACE Gem TARGETS Gem::VirtualGamepad) -ly_create_alias(NAME VirtualGamepad.Builders NAMESPACE Gem TARGETS Gem::VirtualGamepad) +ly_create_alias(NAME VirtualGamepad.Builders NAMESPACE Gem TARGETS Gem::VirtualGamepad Gem::UiBasics.Builders) diff --git a/Gems/VirtualGamepad/gem.json b/Gems/VirtualGamepad/gem.json index 637776ac85..a2a669bb11 100644 --- a/Gems/VirtualGamepad/gem.json +++ b/Gems/VirtualGamepad/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "The Virtual Gamepad Gem provides controls that emulate a gamepad on touch screen devices.", "canonical_tags": [ diff --git a/Gems/WhiteBox/CMakeLists.txt b/Gems/WhiteBox/CMakeLists.txt index 2bb380fae3..50f9e78c74 100644 --- a/Gems/WhiteBox/CMakeLists.txt +++ b/Gems/WhiteBox/CMakeLists.txt @@ -6,4 +6,8 @@ # # +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + add_subdirectory(Code) diff --git a/Gems/WhiteBox/Code/CMakeLists.txt b/Gems/WhiteBox/Code/CMakeLists.txt index ee76031beb..91536503ac 100644 --- a/Gems/WhiteBox/Code/CMakeLists.txt +++ b/Gems/WhiteBox/Code/CMakeLists.txt @@ -6,8 +6,8 @@ # # -ly_get_list_relative_pal_filename(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME}) -ly_get_list_relative_pal_filename(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) +o3de_pal_dir(pal_source_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) +set(common_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/Common) include(${pal_source_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) @@ -29,7 +29,6 @@ if(NOT PAL_TRAIT_WHITEBOX_SUPPORTED) if(PAL_TRAIT_BUILD_HOST_TOOLS) ly_add_target( NAME WhiteBox.Editor GEM_MODULE - NAMESPACE Gem FILES_CMAKE whitebox_unsupported_files.cmake @@ -44,6 +43,8 @@ if(NOT PAL_TRAIT_WHITEBOX_SUPPORTED) BUILD_DEPENDENCIES PRIVATE AZ::AzCore + RUNTIME_DEPENDENCIES + Gem::EditorPythonBindings.Editor ) endif() return() diff --git a/Gems/WhiteBox/Code/Source/Components/EditorWhiteBoxColliderComponent.cpp b/Gems/WhiteBox/Code/Source/Components/EditorWhiteBoxColliderComponent.cpp index c245f60fed..17d374fab1 100644 --- a/Gems/WhiteBox/Code/Source/Components/EditorWhiteBoxColliderComponent.cpp +++ b/Gems/WhiteBox/Code/Source/Components/EditorWhiteBoxColliderComponent.cpp @@ -73,6 +73,7 @@ namespace WhiteBox void EditorWhiteBoxColliderComponent::GetIncompatibleServices(AZ::ComponentDescriptor::DependencyArrayType& incompatible) { incompatible.push_back(AZ_CRC_CE("NonUniformScaleService")); + incompatible.push_back(AZ_CRC_CE("WhiteBoxColliderService")); } void EditorWhiteBoxColliderComponent::Activate() diff --git a/Gems/WhiteBox/Code/Source/EditorWhiteBoxComponent.cpp b/Gems/WhiteBox/Code/Source/EditorWhiteBoxComponent.cpp index c29305e1f4..dd64eee58a 100644 --- a/Gems/WhiteBox/Code/Source/EditorWhiteBoxComponent.cpp +++ b/Gems/WhiteBox/Code/Source/EditorWhiteBoxComponent.cpp @@ -265,6 +265,7 @@ namespace WhiteBox { incompatible.push_back(AZ_CRC_CE("NonUniformScaleService")); incompatible.push_back(AZ_CRC_CE("MeshService")); + incompatible.push_back(AZ_CRC_CE("WhiteBoxService")); } EditorWhiteBoxComponent::EditorWhiteBoxComponent() = default; diff --git a/Gems/WhiteBox/gem.json b/Gems/WhiteBox/gem.json index 41865efc56..18a3022b74 100644 --- a/Gems/WhiteBox/gem.json +++ b/Gems/WhiteBox/gem.json @@ -4,6 +4,7 @@ "license": "Apache-2.0 Or MIT", "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Tool", "summary": "The White Box Gem provides White Box rapid design components for Open 3D Engine.", "canonical_tags": [ @@ -20,6 +21,7 @@ "dependencies": [ "Atom_RPI", "Atom_Feature_Common", - "CommonFeaturesAtom" + "CommonFeaturesAtom", + "EditorPythonBindings" ] } diff --git a/Registry/application_lifecycle_events.setreg b/Registry/application_lifecycle_events.setreg index 0d9cd0f170..c52c93c0c0 100644 --- a/Registry/application_lifecycle_events.setreg +++ b/Registry/application_lifecycle_events.setreg @@ -23,7 +23,8 @@ "GemsUnloaded": {}, "FileIOAvailable": {}, "FileIOUnavailable": {}, - "LegacySystemInterfaceCreated": {} + "LegacySystemInterfaceCreated": {}, + "CriticalAssetsCompiled": {} } } } diff --git a/Registry/bootstrap.setreg b/Registry/bootstrap.setreg index b2bcdd7f3f..5fdb8e0941 100644 --- a/Registry/bootstrap.setreg +++ b/Registry/bootstrap.setreg @@ -12,6 +12,7 @@ "android_assets": "android", "ios_assets": "ios", "mac_assets": "mac", + "salem_assets": "salem", "allowed_list": "", "remote_ip": "127.0.0.1", "remote_port": 45643, diff --git a/Templates/AssetGem/Template/gem.json b/Templates/AssetGem/Template/gem.json index 2a02362256..b04ecf9dd8 100644 --- a/Templates/AssetGem/Template/gem.json +++ b/Templates/AssetGem/Template/gem.json @@ -1,18 +1,21 @@ { "gem_name": "${Name}", "display_name": "${Name}", - "license": "What license ${Name} uses goes here: i.e. Apache-2.0 Or MIT", - "license_url": "", - "origin": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", + "license": "What license ${Name} uses goes here: i.e. Apache-2.0 or MIT", + "license_url": "Link to the license web site goes here: i.e. https://opensource.org/licenses/Apache-2.0 Or https://opensource.org/licenses/MIT", + "origin": "The name of the originator goes here. i.e. XYZ Inc.", + "origin_url": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", "type": "Asset", - "summary": "A short description of ${Name}.", + "summary": "A short description of ${Name} goes here.", "canonical_tags": [ "Gem" ], "user_tags": [ - "Assets", "${Name}" ], "icon_path": "preview.png", - "requirements": "" + "requirements": "Notice of any requirements ${Name} has goes here. i.e. This requires X other gem", + "documentation_url": "Link to any documentation of ${Name} goes here: i.e. https://o3de.org/docs/user-guide/gems/reference/design/white-box/", + "dependencies": [ + ] } diff --git a/Templates/AssetGem/template.json b/Templates/AssetGem/template.json index e858dc526d..2f390f2077 100644 --- a/Templates/AssetGem/template.json +++ b/Templates/AssetGem/template.json @@ -1,10 +1,17 @@ { "template_name": "AssetGem", - "origin": "The primary repo for AssetGem goes here: i.e. http://www.mydomain.com", - "license": "What license AssetGem uses goes here: i.e. https://opensource.org/licenses/MIT", - "display_name": "AssetGem", - "summary": "A short description of AssetGem template.", - "canonical_tags": [], + "template_restricted_platform_relative_path": "Templates/AssetGem", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", + "license": "Apache-2.0 or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", + "display_name": "Asset Gem Template", + "summary": "Use this gem template to create the minimal gem needed for adding asset(s).", + "canonical_tags": [ + "Template", + "Gem", + "Asset" + ], "user_tags": [ "AssetGem" ], @@ -12,27 +19,20 @@ "copyFiles": [ { "file": "CMakeLists.txt", - "origin": "CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "gem.json", - "origin": "gem.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "preview.png", - "origin": "preview.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false } ], "createDirectories": [ { - "dir": "Assets", - "origin": "Assets" + "dir": "Assets" } ] } diff --git a/Templates/CppToolGem/Template/gem.json b/Templates/CppToolGem/Template/gem.json index 079b7152ff..05be122226 100644 --- a/Templates/CppToolGem/Template/gem.json +++ b/Templates/CppToolGem/Template/gem.json @@ -1,11 +1,12 @@ { "gem_name": "${Name}", "display_name": "${Name}", - "license": "What license ${Name} uses goes here: i.e. Apache-2.0 Or MIT", - "license_url": "", - "origin": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", + "license": "What license ${Name} uses goes here: i.e. Apache-2.0 or MIT", + "license_url": "Link to the license web site goes here: i.e. https://opensource.org/licenses/Apache-2.0 Or https://opensource.org/licenses/MIT", + "origin": "The name of the originator goes here. i.e. XYZ Inc.", + "origin_url": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", "type": "Code", - "summary": "A short description of ${Name}.", + "summary": "A short description of ${Name} goes here.", "canonical_tags": [ "Gem" ], @@ -13,6 +14,8 @@ "${Name}" ], "icon_path": "preview.png", - "requirements": "", - "restricted_name": "gems" + "requirements": "Notice of any requirements ${Name} has goes here. i.e. This requires X other gem", + "documentation_url": "Link to any documentation of ${Name} goes here: i.e. https://o3de.org/docs/user-guide/gems/reference/design/white-box/", + "dependencies": [ + ] } diff --git a/Templates/CppToolGem/template.json b/Templates/CppToolGem/template.json index b516dbaec3..16874326ef 100644 --- a/Templates/CppToolGem/template.json +++ b/Templates/CppToolGem/template.json @@ -1,10 +1,16 @@ { "template_name": "CppToolGem", - "origin": "The primary repo for CppToolGem goes here: i.e. http://www.mydomain.com", - "license": "What license CppToolGem uses goes here: i.e. https://opensource.org/licenses/MIT", + "template_restricted_platform_relative_path": "Templates/CppToolGem", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", + "license": "Apache-2.0 or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "display_name": "CppToolGem", "summary": "A gem template for a custom tool in C++ that gets registered with the Editor.", - "canonical_tags": [], + "canonical_tags": [ + "Template", + "Gem" + ], "user_tags": [ "CppToolGem" ], @@ -12,371 +18,255 @@ "copyFiles": [ { "file": "CMakeLists.txt", - "origin": "CMakeLists.txt", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Code/${NameLower}_editor_files.cmake", - "origin": "Code/${NameLower}_editor_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_editor_shared_files.cmake", - "origin": "Code/${NameLower}_editor_shared_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_editor_tests_files.cmake", - "origin": "Code/${NameLower}_editor_tests_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_files.cmake", - "origin": "Code/${NameLower}_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_shared_files.cmake", - "origin": "Code/${NameLower}_shared_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_tests_files.cmake", - "origin": "Code/${NameLower}_tests_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/CMakeLists.txt", - "origin": "Code/CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Include/${Name}/${Name}Bus.h", - "origin": "Code/Include/${Name}/${Name}Bus.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Android/${NameLower}_android_files.cmake", - "origin": "Code/Platform/Android/${NameLower}_android_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Android/${NameLower}_shared_android_files.cmake", - "origin": "Code/Platform/Android/${NameLower}_shared_android_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Android/PAL_android.cmake", - "origin": "Code/Platform/Android/PAL_android.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/PAL_linux.cmake", - "origin": "Code/Platform/Linux/PAL_linux.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/PAL_mac.cmake", - "origin": "Code/Platform/Mac/PAL_mac.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/PAL_windows.cmake", - "origin": "Code/Platform/Windows/PAL_windows.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/iOS/${NameLower}_ios_files.cmake", - "origin": "Code/Platform/iOS/${NameLower}_ios_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/iOS/${NameLower}_shared_ios_files.cmake", - "origin": "Code/Platform/iOS/${NameLower}_shared_ios_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/iOS/PAL_ios.cmake", - "origin": "Code/Platform/iOS/PAL_ios.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}.qrc", - "origin": "Code/Source/${Name}.qrc", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorModule.cpp", - "origin": "Code/Source/${Name}EditorModule.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorSystemComponent.cpp", - "origin": "Code/Source/${Name}EditorSystemComponent.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorSystemComponent.h", - "origin": "Code/Source/${Name}EditorSystemComponent.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}Module.cpp", - "origin": "Code/Source/${Name}Module.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}ModuleInterface.h", - "origin": "Code/Source/${Name}ModuleInterface.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}SystemComponent.cpp", - "origin": "Code/Source/${Name}SystemComponent.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}SystemComponent.h", - "origin": "Code/Source/${Name}SystemComponent.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}Widget.cpp", - "origin": "Code/Source/${Name}Widget.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}Widget.h", - "origin": "Code/Source/${Name}Widget.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/toolbar_icon.svg", - "origin": "Code/Source/toolbar_icon.svg", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Code/Tests/${Name}EditorTest.cpp", - "origin": "Code/Tests/${Name}EditorTest.cpp", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Code/Tests/${Name}Test.cpp", - "origin": "Code/Tests/${Name}Test.cpp", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Android/android_gem.cmake", - "origin": "Platform/Android/android_gem.cmake", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Android/android_gem.json", - "origin": "Platform/Android/android_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Linux/linux_gem.cmake", - "origin": "Platform/Linux/linux_gem.cmake", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Linux/linux_gem.json", - "origin": "Platform/Linux/linux_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Mac/mac_gem.cmake", - "origin": "Platform/Mac/mac_gem.cmake", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Mac/mac_gem.json", - "origin": "Platform/Mac/mac_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Windows/windows_gem.cmake", - "origin": "Platform/Windows/windows_gem.cmake", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Windows/windows_gem.json", - "origin": "Platform/Windows/windows_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/iOS/ios_gem.cmake", - "origin": "Platform/iOS/ios_gem.cmake", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/iOS/ios_gem.json", - "origin": "Platform/iOS/ios_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "gem.json", - "origin": "gem.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "preview.png", - "origin": "preview.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false } ], "createDirectories": [ { - "dir": "Assets", - "origin": "Assets" + "dir": "Assets" }, { - "dir": "Code", - "origin": "Code" + "dir": "Code" }, { - "dir": "Code/Include", - "origin": "Code/Include" + "dir": "Code/Include" }, { - "dir": "Code/Include/${Name}", - "origin": "Code/Include/${Name}" + "dir": "Code/Include/${Name}" }, { - "dir": "Code/Platform", - "origin": "Code/Platform" + "dir": "Code/Platform" }, { - "dir": "Code/Platform/Android", - "origin": "Code/Platform/Android" + "dir": "Code/Platform/Android" }, { - "dir": "Code/Platform/Linux", - "origin": "Code/Platform/Linux" + "dir": "Code/Platform/Linux" }, { - "dir": "Code/Platform/Mac", - "origin": "Code/Platform/Mac" + "dir": "Code/Platform/Mac" }, { - "dir": "Code/Platform/Windows", - "origin": "Code/Platform/Windows" + "dir": "Code/Platform/Windows" }, { - "dir": "Code/Platform/iOS", - "origin": "Code/Platform/iOS" + "dir": "Code/Platform/iOS" }, { - "dir": "Code/Source", - "origin": "Code/Source" + "dir": "Code/Source" }, { - "dir": "Code/Tests", - "origin": "Code/Tests" + "dir": "Code/Tests" }, { - "dir": "Platform", - "origin": "Platform" + "dir": "Platform" }, { - "dir": "Platform/Android", - "origin": "Platform/Android" + "dir": "Platform/Android" }, { - "dir": "Platform/Linux", - "origin": "Platform/Linux" + "dir": "Platform/Linux" }, { - "dir": "Platform/Mac", - "origin": "Platform/Mac" + "dir": "Platform/Mac" }, { - "dir": "Platform/Windows", - "origin": "Platform/Windows" + "dir": "Platform/Windows" }, { - "dir": "Platform/iOS", - "origin": "Platform/iOS" + "dir": "Platform/iOS" } ] } diff --git a/Templates/DefaultGem/Template/CMakeLists.txt b/Templates/DefaultGem/Template/CMakeLists.txt index b19ea2edce..f4c55dd1a5 100644 --- a/Templates/DefaultGem/Template/CMakeLists.txt +++ b/Templates/DefaultGem/Template/CMakeLists.txt @@ -6,12 +6,11 @@ # # {END_LICENSE} -set(o3de_gem_path ${CMAKE_CURRENT_LIST_DIR}) -set(o3de_gem_json ${o3de_gem_path}/gem.json) -o3de_read_json_key(o3de_gem_name ${o3de_gem_json} "gem_name") -o3de_restricted_path(${o3de_gem_json} o3de_gem_restricted_path) +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} "${o3de_gem_restricted_path}" ${o3de_gem_path} ${o3de_gem_name}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) # Now that we have the platform abstraction layer (PAL) folder for this folder, thats where we will find the # project cmake for this platform. diff --git a/Templates/DefaultGem/Template/Code/CMakeLists.txt b/Templates/DefaultGem/Template/Code/CMakeLists.txt index f462e7f2d4..c5ff305b2a 100644 --- a/Templates/DefaultGem/Template/Code/CMakeLists.txt +++ b/Templates/DefaultGem/Template/Code/CMakeLists.txt @@ -8,11 +8,11 @@ # Currently we are in the Code folder: ${CMAKE_CURRENT_LIST_DIR} # Get the platform specific folder ${pal_dir} for the current folder: ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} -# Note: ly_get_list_relative_pal_filename will take care of the details for us, as this may be a restricted platform +# Note: o3de_pal_dir will take care of the details for us, as this may be a restricted platform # in which case it will see if that platform is present here or in the restricted folder. # i.e. It could here in our gem : Gems/${Name}/Code/Platform/ or # //Gems/${Name}/Code -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${o3de_gem_restricted_path} ${o3de_gem_path} ${o3de_gem_name}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${o3de_gem_restricted_path} ${o3de_gem_path} ${o3de_gem_name}) # Now that we have the platform abstraction layer (PAL) folder for this folder, thats where we will find the # traits for this platform. Traits for a platform are defines for things like whether or not something in this gem diff --git a/Templates/DefaultGem/Template/gem.json b/Templates/DefaultGem/Template/gem.json index d4ff637bee..05be122226 100644 --- a/Templates/DefaultGem/Template/gem.json +++ b/Templates/DefaultGem/Template/gem.json @@ -1,11 +1,12 @@ { "gem_name": "${Name}", "display_name": "${Name}", - "license": "What license ${Name} uses goes here: i.e. Apache-2.0 Or MIT", - "license_url": "", - "origin": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", + "license": "What license ${Name} uses goes here: i.e. Apache-2.0 or MIT", + "license_url": "Link to the license web site goes here: i.e. https://opensource.org/licenses/Apache-2.0 Or https://opensource.org/licenses/MIT", + "origin": "The name of the originator goes here. i.e. XYZ Inc.", + "origin_url": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", "type": "Code", - "summary": "A short description of ${Name}.", + "summary": "A short description of ${Name} goes here.", "canonical_tags": [ "Gem" ], @@ -13,5 +14,8 @@ "${Name}" ], "icon_path": "preview.png", - "requirements": "" + "requirements": "Notice of any requirements ${Name} has goes here. i.e. This requires X other gem", + "documentation_url": "Link to any documentation of ${Name} goes here: i.e. https://o3de.org/docs/user-guide/gems/reference/design/white-box/", + "dependencies": [ + ] } diff --git a/Templates/DefaultGem/template.json b/Templates/DefaultGem/template.json index e24632d6a0..e5dc570cbe 100644 --- a/Templates/DefaultGem/template.json +++ b/Templates/DefaultGem/template.json @@ -1,12 +1,16 @@ { "template_name": "DefaultGem", + "template_restricted_platform_relative_path": "Templates/DefaultGem", "restricted_name": "o3de", - "restricted_platform_relative_path": "Templates", - "origin": "The primary repo for DefaultGem goes here: i.e. http://www.mydomain.com", - "license": "What license DefaultGem uses goes here: i.e. https://opensource.org/licenses/MIT", - "display_name": "DefaultGem", - "summary": "A short description of DefaultGem.", - "canonical_tags": [], + "restricted_platform_relative_path": "Templates/DefaultGem", + "license": "Apache-2.0 or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", + "display_name": "Default Gem Template", + "summary": "This is the gem template that will be used if no gem template is specified during gem creation.", + "canonical_tags": [ + "Template", + "Gem" + ], "user_tags": [ "DefaultGem" ], @@ -14,347 +18,239 @@ "copyFiles": [ { "file": "CMakeLists.txt", - "origin": "CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_editor_files.cmake", - "origin": "Code/${NameLower}_editor_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_editor_shared_files.cmake", - "origin": "Code/${NameLower}_editor_shared_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_editor_tests_files.cmake", - "origin": "Code/${NameLower}_editor_tests_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_files.cmake", - "origin": "Code/${NameLower}_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_shared_files.cmake", - "origin": "Code/${NameLower}_shared_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_tests_files.cmake", - "origin": "Code/${NameLower}_tests_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/CMakeLists.txt", - "origin": "Code/CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Include/${Name}/${Name}Bus.h", - "origin": "Code/Include/${Name}/${Name}Bus.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Android/${NameLower}_android_files.cmake", - "origin": "Code/Platform/Android/${NameLower}_android_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Android/${NameLower}_shared_android_files.cmake", - "origin": "Code/Platform/Android/${NameLower}_shared_android_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Android/PAL_android.cmake", - "origin": "Code/Platform/Android/PAL_android.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/PAL_linux.cmake", - "origin": "Code/Platform/Linux/PAL_linux.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/PAL_mac.cmake", - "origin": "Code/Platform/Mac/PAL_mac.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/PAL_windows.cmake", - "origin": "Code/Platform/Windows/PAL_windows.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/iOS/${NameLower}_ios_files.cmake", - "origin": "Code/Platform/iOS/${NameLower}_ios_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/iOS/${NameLower}_shared_ios_files.cmake", - "origin": "Code/Platform/iOS/${NameLower}_shared_ios_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/iOS/PAL_ios.cmake", - "origin": "Code/Platform/iOS/PAL_ios.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorModule.cpp", - "origin": "Code/Source/${Name}EditorModule.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorSystemComponent.cpp", - "origin": "Code/Source/${Name}EditorSystemComponent.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorSystemComponent.h", - "origin": "Code/Source/${Name}EditorSystemComponent.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}Module.cpp", - "origin": "Code/Source/${Name}Module.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}ModuleInterface.h", - "origin": "Code/Source/${Name}ModuleInterface.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}SystemComponent.cpp", - "origin": "Code/Source/${Name}SystemComponent.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}SystemComponent.h", - "origin": "Code/Source/${Name}SystemComponent.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Tests/${Name}EditorTest.cpp", - "origin": "Code/Tests/${Name}EditorTest.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Tests/${Name}Test.cpp", - "origin": "Code/Tests/${Name}Test.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Android/android_gem.cmake", - "origin": "Platform/Android/android_gem.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Android/android_gem.json", - "origin": "Platform/Android/android_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Linux/linux_gem.cmake", - "origin": "Platform/Linux/linux_gem.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Linux/linux_gem.json", - "origin": "Platform/Linux/linux_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Mac/mac_gem.cmake", - "origin": "Platform/Mac/mac_gem.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Mac/mac_gem.json", - "origin": "Platform/Mac/mac_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Windows/windows_gem.cmake", - "origin": "Platform/Windows/windows_gem.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Windows/windows_gem.json", - "origin": "Platform/Windows/windows_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/iOS/ios_gem.cmake", - "origin": "Platform/iOS/ios_gem.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/iOS/ios_gem.json", - "origin": "Platform/iOS/ios_gem.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "gem.json", - "origin": "gem.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "preview.png", - "origin": "preview.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false } ], "createDirectories": [ { - "dir": "Assets", - "origin": "Assets" + "dir": "Assets" }, { - "dir": "Code", - "origin": "Code" + "dir": "Code" }, { - "dir": "Code/Include", - "origin": "Code/Include" + "dir": "Code/Include" }, { - "dir": "Code/Include/${Name}", - "origin": "Code/Include/${Name}" + "dir": "Code/Include/${Name}" }, { - "dir": "Code/Platform", - "origin": "Code/Platform" + "dir": "Code/Platform" }, { - "dir": "Code/Platform/Android", - "origin": "Code/Platform/Android" + "dir": "Code/Platform/Android" }, { - "dir": "Code/Platform/Linux", - "origin": "Code/Platform/Linux" + "dir": "Code/Platform/Linux" }, { - "dir": "Code/Platform/Mac", - "origin": "Code/Platform/Mac" + "dir": "Code/Platform/Mac" }, { - "dir": "Code/Platform/Windows", - "origin": "Code/Platform/Windows" + "dir": "Code/Platform/Windows" }, { - "dir": "Code/Platform/iOS", - "origin": "Code/Platform/iOS" + "dir": "Code/Platform/iOS" }, { - "dir": "Code/Source", - "origin": "Code/Source" + "dir": "Code/Source" }, { - "dir": "Code/Tests", - "origin": "Code/Tests" + "dir": "Code/Tests" }, { - "dir": "Platform", - "origin": "Platform" + "dir": "Platform" }, { - "dir": "Platform/Android", - "origin": "Platform/Android" + "dir": "Platform/Android" }, { - "dir": "Platform/Linux", - "origin": "Platform/Linux" + "dir": "Platform/Linux" }, { - "dir": "Platform/Mac", - "origin": "Platform/Mac" + "dir": "Platform/Mac" }, { - "dir": "Platform/Windows", - "origin": "Platform/Windows" + "dir": "Platform/Windows" }, { - "dir": "Platform/iOS", - "origin": "Platform/iOS" + "dir": "Platform/iOS" } ] } diff --git a/Templates/DefaultProject/Template/CMakeLists.txt b/Templates/DefaultProject/Template/CMakeLists.txt index ae4bb662a3..420a92948d 100644 --- a/Templates/DefaultProject/Template/CMakeLists.txt +++ b/Templates/DefaultProject/Template/CMakeLists.txt @@ -29,5 +29,4 @@ else() set_property(GLOBAL APPEND PROPERTY LY_PROJECTS_TARGET_NAME ${project_target_name}) - add_subdirectory(Code) endif() diff --git a/Templates/DefaultProject/Template/Code/${NameLower}_files.cmake b/Templates/DefaultProject/Template/Gem/${NameLower}_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/${NameLower}_files.cmake rename to Templates/DefaultProject/Template/Gem/${NameLower}_files.cmake diff --git a/Templates/DefaultProject/Template/Code/${NameLower}_shared_files.cmake b/Templates/DefaultProject/Template/Gem/${NameLower}_shared_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/${NameLower}_shared_files.cmake rename to Templates/DefaultProject/Template/Gem/${NameLower}_shared_files.cmake diff --git a/Templates/MinimalProject/Template/Code/CMakeLists.txt b/Templates/DefaultProject/Template/Gem/CMakeLists.txt similarity index 87% rename from Templates/MinimalProject/Template/Code/CMakeLists.txt rename to Templates/DefaultProject/Template/Gem/CMakeLists.txt index 5e646c0704..fc3eab6535 100644 --- a/Templates/MinimalProject/Template/Code/CMakeLists.txt +++ b/Templates/DefaultProject/Template/Gem/CMakeLists.txt @@ -6,13 +6,17 @@ # # {END_LICENSE} +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + # Currently we are in the ${Name}/Code folder: ${CMAKE_CURRENT_LIST_DIR} # Get the platform specific folder ${pal_dir} for the current folder: ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} -# Note: ly_get_list_relative_pal_filename will take care of the details for us, as this may be a restricted platform +# Note: o3de_pal_dir will take care of the details for us, as this may be a restricted platform # in which case it will see if that platform is present here or in the restricted folder. -# i.e. It could here : ${Name}/Code/Platform/ or +# i.e. It could here : ${Name}/Code/Platform/ or # //${Name}/Code -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${o3de_project_restricted_path} ${o3de_project_path} ${o3de_project_name}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) # Now that we have the platform abstraction layer (PAL) folder for this folder, thats where we will find the # traits for this platform. Traits for a platform are defines for things like whether or not something in this project @@ -71,7 +75,6 @@ ly_create_alias(NAME ${Name}.Servers NAMESPACE Gem TARGETS Gem::${Name}) # Enable the specified list of gems from GEM_FILE or GEMS list for this specific project: ly_enable_gems(PROJECT_NAME ${Name} GEM_FILE enabled_gems.cmake) - if(PAL_TRAIT_BUILD_SERVER_SUPPORTED) # this property causes it to actually make a ServerLauncher. # if you don't want a Server application, you can remove this and the diff --git a/Templates/DefaultProject/Template/Code/Include/${Name}/${Name}Bus.h b/Templates/DefaultProject/Template/Gem/Include/${Name}/${Name}Bus.h similarity index 99% rename from Templates/DefaultProject/Template/Code/Include/${Name}/${Name}Bus.h rename to Templates/DefaultProject/Template/Gem/Include/${Name}/${Name}Bus.h index d09bb2b009..d72b5785c3 100644 --- a/Templates/DefaultProject/Template/Code/Include/${Name}/${Name}Bus.h +++ b/Templates/DefaultProject/Template/Gem/Include/${Name}/${Name}Bus.h @@ -22,7 +22,7 @@ namespace ${SanitizedCppName} virtual ~${SanitizedCppName}Requests() = default; // Put your public methods here }; - + class ${SanitizedCppName}BusTraits : public AZ::EBusTraits { diff --git a/Templates/DefaultProject/Template/Code/Platform/Android/${NameLower}_android_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/Android/${NameLower}_android_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Android/${NameLower}_android_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Android/${NameLower}_android_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Android/${NameLower}_shared_android_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/Android/${NameLower}_shared_android_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Android/${NameLower}_shared_android_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Android/${NameLower}_shared_android_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Android/PAL_android.cmake b/Templates/DefaultProject/Template/Gem/Platform/Android/PAL_android.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Android/PAL_android.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Android/PAL_android.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Linux/${NameLower}_linux_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/Linux/${NameLower}_linux_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Linux/${NameLower}_linux_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Linux/${NameLower}_linux_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Linux/${NameLower}_shared_linux_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/Linux/${NameLower}_shared_linux_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Linux/${NameLower}_shared_linux_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Linux/${NameLower}_shared_linux_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Linux/PAL_linux.cmake b/Templates/DefaultProject/Template/Gem/Platform/Linux/PAL_linux.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Linux/PAL_linux.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Linux/PAL_linux.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Mac/${NameLower}_mac_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/Mac/${NameLower}_mac_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Mac/${NameLower}_mac_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Mac/${NameLower}_mac_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Mac/${NameLower}_shared_mac_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/Mac/${NameLower}_shared_mac_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Mac/${NameLower}_shared_mac_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Mac/${NameLower}_shared_mac_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Mac/PAL_mac.cmake b/Templates/DefaultProject/Template/Gem/Platform/Mac/PAL_mac.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Mac/PAL_mac.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Mac/PAL_mac.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Windows/${NameLower}_shared_windows_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/Windows/${NameLower}_shared_windows_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Windows/${NameLower}_shared_windows_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Windows/${NameLower}_shared_windows_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Windows/${NameLower}_windows_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/Windows/${NameLower}_windows_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Windows/${NameLower}_windows_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Windows/${NameLower}_windows_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/Windows/PAL_windows.cmake b/Templates/DefaultProject/Template/Gem/Platform/Windows/PAL_windows.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/Windows/PAL_windows.cmake rename to Templates/DefaultProject/Template/Gem/Platform/Windows/PAL_windows.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/iOS/${NameLower}_ios_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/iOS/${NameLower}_ios_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/iOS/${NameLower}_ios_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/iOS/${NameLower}_ios_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/iOS/${NameLower}_shared_ios_files.cmake b/Templates/DefaultProject/Template/Gem/Platform/iOS/${NameLower}_shared_ios_files.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/iOS/${NameLower}_shared_ios_files.cmake rename to Templates/DefaultProject/Template/Gem/Platform/iOS/${NameLower}_shared_ios_files.cmake diff --git a/Templates/DefaultProject/Template/Code/Platform/iOS/PAL_ios.cmake b/Templates/DefaultProject/Template/Gem/Platform/iOS/PAL_ios.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/Platform/iOS/PAL_ios.cmake rename to Templates/DefaultProject/Template/Gem/Platform/iOS/PAL_ios.cmake diff --git a/Templates/DefaultProject/Template/Code/Source/${Name}Module.cpp b/Templates/DefaultProject/Template/Gem/Source/${Name}Module.cpp similarity index 100% rename from Templates/DefaultProject/Template/Code/Source/${Name}Module.cpp rename to Templates/DefaultProject/Template/Gem/Source/${Name}Module.cpp diff --git a/Templates/DefaultProject/Template/Code/Source/${Name}SystemComponent.cpp b/Templates/DefaultProject/Template/Gem/Source/${Name}SystemComponent.cpp similarity index 99% rename from Templates/DefaultProject/Template/Code/Source/${Name}SystemComponent.cpp rename to Templates/DefaultProject/Template/Gem/Source/${Name}SystemComponent.cpp index cfb6ae3c42..487391c716 100644 --- a/Templates/DefaultProject/Template/Code/Source/${Name}SystemComponent.cpp +++ b/Templates/DefaultProject/Template/Gem/Source/${Name}SystemComponent.cpp @@ -52,7 +52,7 @@ namespace ${SanitizedCppName} void ${SanitizedCppName}SystemComponent::GetDependentServices([[maybe_unused]] AZ::ComponentDescriptor::DependencyArrayType& dependent) { } - + ${SanitizedCppName}SystemComponent::${SanitizedCppName}SystemComponent() { if (${SanitizedCppName}Interface::Get() == nullptr) diff --git a/Templates/DefaultProject/Template/Code/Source/${Name}SystemComponent.h b/Templates/DefaultProject/Template/Gem/Source/${Name}SystemComponent.h similarity index 100% rename from Templates/DefaultProject/Template/Code/Source/${Name}SystemComponent.h rename to Templates/DefaultProject/Template/Gem/Source/${Name}SystemComponent.h diff --git a/Templates/DefaultProject/Template/Code/enabled_gems.cmake b/Templates/DefaultProject/Template/Gem/enabled_gems.cmake similarity index 100% rename from Templates/DefaultProject/Template/Code/enabled_gems.cmake rename to Templates/DefaultProject/Template/Gem/enabled_gems.cmake diff --git a/Templates/DefaultProject/Template/Gem/gem.json b/Templates/DefaultProject/Template/Gem/gem.json new file mode 100644 index 0000000000..b60f512006 --- /dev/null +++ b/Templates/DefaultProject/Template/Gem/gem.json @@ -0,0 +1,21 @@ +{ + "gem_name": "${Name}", + "display_name": "${Name}", + "license": "What license ${Name} uses goes here: i.e. Apache-2.0 or MIT", + "license_url": "Link to the license web site goes here: i.e. https://opensource.org/licenses/Apache-2.0 Or https://opensource.org/licenses/MIT", + "origin": "The name of the originator goes here. i.e. XYZ Inc.", + "origin_url": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", + "type": "", + "summary": "A short description of ${Name}.", + "canonical_tags": [ + "Gem" + ], + "user_tags": [ + "${Name}" + ], + "icon_path": "preview.png", + "requirements": "", + "documentation_url": "", + "dependencies": [ + ] +} diff --git a/Templates/DefaultProject/Template/project.json b/Templates/DefaultProject/Template/project.json index f8d4643ce9..6d1875fcaa 100644 --- a/Templates/DefaultProject/Template/project.json +++ b/Templates/DefaultProject/Template/project.json @@ -2,7 +2,7 @@ "project_name": "${Name}", "project_id": "${ProjectId}", "origin": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", - "license": "What license ${Name} uses goes here: i.e. https://opensource.org/licenses/MIT", + "license": "What license ${Name} uses goes here: i.e. https://opensource.org/licenses/Apache-2.0 Or https://opensource.org/licenses/MIT etc.", "display_name": "${Name}", "summary": "A short description of ${Name}.", "canonical_tags": [ @@ -13,5 +13,8 @@ ], "icon_path": "preview.png", "engine": "o3de", - "external_subdirectories": [] + "external_subdirectories": [ + "Gem" + ], + "restricted": "${Name}" } diff --git a/Templates/DefaultProject/template.json b/Templates/DefaultProject/template.json index fcffafcb34..203e1ec4ef 100644 --- a/Templates/DefaultProject/template.json +++ b/Templates/DefaultProject/template.json @@ -1,12 +1,18 @@ { "template_name": "DefaultProject", + "template_restricted_platform_relative_path": "Templates/DefaultProject", "restricted_name": "o3de", - "restricted_platform_relative_path": "Templates", - "origin": "The primary repo for DefaultProject goes here: i.e. http://www.mydomain.com", - "license": "What license DefaultProject uses goes here: i.e. https://opensource.org/licenses/MIT", - "display_name": "Standard", - "summary": "This template has everything you need to build a full online 3D game or application.", - "canonical_tags": [], + "restricted_platform_relative_path": "Templates/DefaultProject", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", + "license": "Apache-2.0 or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", + "display_name": "Default Project Template", + "summary": "This is the project template that will be used if no project template is specified during project creation.", + "canonical_tags": [ + "Template", + "Project" + ], "user_tags": [ "DefaultProject" ], @@ -14,657 +20,459 @@ "copyFiles": [ { "file": ".gitignore", - "origin": ".gitignore", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "CMakeLists.txt", - "origin": "CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { - "file": "Code/${NameLower}_files.cmake", - "origin": "Code/${NameLower}_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "cmake/EngineFinder.cmake", + "isTemplated": true }, { - "file": "Code/${NameLower}_shared_files.cmake", - "origin": "Code/${NameLower}_shared_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "cmake/CompilerSettings.cmake", + "isTemplated": false }, { - "file": "Code/CMakeLists.txt", - "origin": "Code/CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "file": "cmake/Platform/Linux/CompilerSettings_linux.cmake", + "isTemplated": false }, { - "file": "Code/Include/${Name}/${Name}Bus.h", - "origin": "Code/Include/${Name}/${Name}Bus.h", - "isTemplated": true, - "isOptional": false + "file": "Config/default_aws_resource_mappings.json", + "isTemplated": false }, { - "file": "Code/Platform/Android/${NameLower}_android_files.cmake", - "origin": "Code/Platform/Android/${NameLower}_android_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Config/shader_global_build_options.json", + "isTemplated": false }, { - "file": "Code/Platform/Android/${NameLower}_shared_android_files.cmake", - "origin": "Code/Platform/Android/${NameLower}_shared_android_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/${NameLower}_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Android/PAL_android.cmake", - "origin": "Code/Platform/Android/PAL_android.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/${NameLower}_shared_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/CMakeLists.txt", + "isTemplated": true }, { - "file": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Include/${Name}/${Name}Bus.h", + "isTemplated": true }, { - "file": "Code/Platform/Linux/PAL_linux.cmake", - "origin": "Code/Platform/Linux/PAL_linux.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Android/${NameLower}_android_files.cmake", + "isTemplated": false }, { - "file": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Android/${NameLower}_shared_android_files.cmake", + "isTemplated": false }, { - "file": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Android/PAL_android.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Mac/PAL_mac.cmake", - "origin": "Code/Platform/Mac/PAL_mac.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Linux/${NameLower}_linux_files.cmake", + "isTemplated": false }, { - "file": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Linux/${NameLower}_shared_linux_files.cmake", + "isTemplated": false }, { - "file": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Linux/PAL_linux.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Windows/PAL_windows.cmake", - "origin": "Code/Platform/Windows/PAL_windows.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Mac/${NameLower}_mac_files.cmake", + "isTemplated": false }, { - "file": "Code/Platform/iOS/${NameLower}_ios_files.cmake", - "origin": "Code/Platform/iOS/${NameLower}_ios_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Mac/${NameLower}_shared_mac_files.cmake", + "isTemplated": false }, { - "file": "Code/Platform/iOS/${NameLower}_shared_ios_files.cmake", - "origin": "Code/Platform/iOS/${NameLower}_shared_ios_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Mac/PAL_mac.cmake", + "isTemplated": true }, { - "file": "Code/Platform/iOS/PAL_ios.cmake", - "origin": "Code/Platform/iOS/PAL_ios.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Windows/${NameLower}_shared_windows_files.cmake", + "isTemplated": false }, { - "file": "Code/Source/${Name}Module.cpp", - "origin": "Code/Source/${Name}Module.cpp", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Windows/${NameLower}_windows_files.cmake", + "isTemplated": false }, { - "file": "Code/Source/${Name}SystemComponent.cpp", - "origin": "Code/Source/${Name}SystemComponent.cpp", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Windows/PAL_windows.cmake", + "isTemplated": true }, { - "file": "Code/Source/${Name}SystemComponent.h", - "origin": "Code/Source/${Name}SystemComponent.h", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/iOS/${NameLower}_ios_files.cmake", + "isTemplated": false }, { - "file": "Code/enabled_gems.cmake", - "origin": "Code/enabled_gems.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/iOS/${NameLower}_shared_ios_files.cmake", + "isTemplated": false }, { - "file": "Code/gem.json", - "origin": "Code/gem.json", - "isTemplated": true, - "isOptional": true + "file": "Gem/Platform/iOS/PAL_ios.cmake", + "isTemplated": true }, { - "file": "Config/shader_global_build_options.json", - "origin": "Config/shader_global_build_options.json", - "isTemplated": false, - "isOptional": false + "file": "Gem/Source/${Name}Module.cpp", + "isTemplated": true }, { - "file": "Config/default_aws_resource_mappings.json", - "origin": "Config/default_aws_resource_mappings.json", - "isTemplated": false, - "isOptional": false + "file": "Gem/Source/${Name}SystemComponent.cpp", + "isTemplated": true }, { - "file": "cmake/EngineFinder.cmake", - "origin": "cmake/EngineFinder.cmake", - "isTemplated": false, - "isOptional": false + "file": "Gem/Source/${Name}SystemComponent.h", + "isTemplated": true }, { - "file": "cmake/CompilerSettings.cmake", - "origin": "cmake/CompilerSettings.cmake", - "isTemplated": false, - "isOptional": false + "file": "Gem/enabled_gems.cmake", + "isTemplated": true }, { - "file": "cmake/Platform/Linux/CompilerSettings_linux.cmake", - "origin": "cmake/Platform/Linux/CompilerSettings_linux.cmake", - "isTemplated": false, - "isOptional": false + "file": "Gem/gem.json", + "isTemplated": true }, { "file": "Platform/Android/android_project.cmake", - "origin": "Platform/Android/android_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Android/android_project.json", - "origin": "Platform/Android/android_project.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Linux/linux_project.cmake", - "origin": "Platform/Linux/linux_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Linux/linux_project.json", - "origin": "Platform/Linux/linux_project.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Mac/mac_project.cmake", - "origin": "Platform/Mac/mac_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Mac/mac_project.json", - "origin": "Platform/Mac/mac_project.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Windows/windows_project.cmake", - "origin": "Platform/Windows/windows_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Windows/windows_project.json", - "origin": "Platform/Windows/windows_project.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/iOS/ios_project.cmake", - "origin": "Platform/iOS/ios_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": false }, { "file": "Platform/iOS/ios_project.json", - "origin": "Platform/iOS/ios_project.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Registry/assets_scan_folders.setreg", - "origin": "Registry/assets_scan_folders.setreg", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Registry/awscoreconfiguration.setreg", - "origin": "Registry/awscoreconfiguration.setreg", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { - "file": "Resources/LegacyLogoLauncher.bmp", - "origin": "Resources/LegacyLogoLauncher.bmp", - "isTemplated": false, - "isOptional": false + "file": "Resources/GameSDK.ico", + "isTemplated": false }, { - "file": "Resources/GameSDK.ico", - "origin": "Resources/GameSDK.ico", - "isTemplated": false, - "isOptional": false + "file": "Resources/LegacyLogoLauncher.bmp", + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/Contents.json", - "origin": "Resources/Platform/Mac/Images.xcassets/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/Contents.json", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { - "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128_2x.png", - "isTemplated": false, - "isOptional": false + "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128.png", + "isTemplated": false }, { - "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128.png", - "isTemplated": false, - "isOptional": false + "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128_2x.png", + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_16.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_16.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_16_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_16_2x.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { - "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256_2x.png", - "isTemplated": false, - "isOptional": false + "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256.png", + "isTemplated": false }, { - "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256.png", - "isTemplated": false, - "isOptional": false + "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256_2x.png", + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_32.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_32.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_32_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_32_2x.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_512.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_512.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_512_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_512_2x.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Info.plist", - "origin": "Resources/Platform/Mac/Info.plist", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Resources/Platform/iOS/Images.xcassets/Contents.json", - "origin": "Resources/Platform/iOS/Images.xcassets/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/Contents.json", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage1024x768.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage1024x768.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage1536x2048.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage1536x2048.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage2048x1536.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage2048x1536.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage768x1024.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage768x1024.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPhoneLaunchImage640x1136.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPhoneLaunchImage640x1136.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPhoneLaunchImage640x960.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPhoneLaunchImage640x960.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/Contents.json", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadAppIcon152x152.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadAppIcon152x152.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadAppIcon76x76.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadAppIcon76x76.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadProAppIcon167x167.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadProAppIcon167x167.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSettingsIcon29x29.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSettingsIcon29x29.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSettingsIcon58x58.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSettingsIcon58x58.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSpotlightIcon40x40.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSpotlightIcon40x40.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSpotlightIcon80x80.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSpotlightIcon80x80.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneAppIcon120x120.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneAppIcon120x120.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneAppIcon180x180.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneAppIcon180x180.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSettingsIcon58x58.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSettingsIcon58x58.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSettingsIcon87x87.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSettingsIcon87x87.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSpotlightIcon120x120.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSpotlightIcon120x120.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSpotlightIcon80x80.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSpotlightIcon80x80.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Info.plist", - "origin": "Resources/Platform/iOS/Info.plist", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "ShaderLib/README.md", - "origin": "ShaderLib/README.md", - "isTemplated": false, - "isOptional": true + "isTemplated": false }, { "file": "ShaderLib/scenesrg.srgi", - "origin": "ShaderLib/scenesrg.srgi", - "isTemplated": true, - "isOptional": false + "isTemplated": false }, { "file": "ShaderLib/viewsrg.srgi", - "origin": "ShaderLib/viewsrg.srgi", - "isTemplated": true, - "isOptional": false + "isTemplated": false }, { "file": "autoexec.cfg", - "origin": "autoexec.cfg", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "game.cfg", - "origin": "game.cfg", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "preview.png", - "origin": "preview.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "project.json", - "origin": "project.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true } ], "createDirectories": [ { - "dir": "Assets", - "origin": "Assets" + "dir": "Assets" + }, + { + "dir": "cmake" + }, + { + "dir": "cmake/Platform" + }, + { + "dir": "cmake/Platform/Linux" }, { - "dir": "Code", - "origin": "Code" + "dir": "Config" }, { - "dir": "Code/Include", - "origin": "Code/Include" + "dir": "Gem" }, { - "dir": "Code/Include/${Name}", - "origin": "Code/Include/${Name}" + "dir": "Gem/Include" }, { - "dir": "Code/Platform", - "origin": "Code/Platform" + "dir": "Gem/Include/${Name}" }, { - "dir": "Code/Platform/Android", - "origin": "Code/Platform/Android" + "dir": "Gem/Platform" }, { - "dir": "Code/Platform/Linux", - "origin": "Code/Platform/Linux" + "dir": "Gem/Platform/Android" }, { - "dir": "Code/Platform/Mac", - "origin": "Code/Platform/Mac" + "dir": "Gem/Platform/Linux" }, { - "dir": "Code/Platform/Windows", - "origin": "Code/Platform/Windows" + "dir": "Gem/Platform/Mac" }, { - "dir": "Code/Platform/iOS", - "origin": "Code/Platform/iOS" + "dir": "Gem/Platform/Windows" }, { - "dir": "Code/Source", - "origin": "Code/Source" + "dir": "Gem/Platform/iOS" }, { - "dir": "Config", - "origin": "Config" + "dir": "Gem/Source" }, { - "dir": "Platform", - "origin": "Platform" + "dir": "Platform" }, { - "dir": "Platform/Android", - "origin": "Platform/Android" + "dir": "Platform/Android" }, { - "dir": "Platform/Linux", - "origin": "Platform/Linux" + "dir": "Platform/Linux" }, { - "dir": "Platform/Mac", - "origin": "Platform/Mac" + "dir": "Platform/Mac" }, { - "dir": "Platform/Windows", - "origin": "Platform/Windows" + "dir": "Platform/Windows" }, { - "dir": "Platform/iOS", - "origin": "Platform/iOS" + "dir": "Platform/iOS" }, { - "dir": "Registry", - "origin": "Registry" + "dir": "Registry" }, { - "dir": "Resources", - "origin": "Resources" + "dir": "Resources" }, { - "dir": "Resources/Platform", - "origin": "Resources/Platform" + "dir": "Resources/Platform" }, { - "dir": "Resources/Platform/Mac", - "origin": "Resources/Platform/Mac" + "dir": "Resources/Platform/Mac" }, { - "dir": "Resources/Platform/Mac/Images.xcassets", - "origin": "Resources/Platform/Mac/Images.xcassets" + "dir": "Resources/Platform/Mac/Images.xcassets" }, { - "dir": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset" + "dir": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset" }, { - "dir": "Resources/Platform/iOS", - "origin": "Resources/Platform/iOS" + "dir": "Resources/Platform/iOS" }, { - "dir": "Resources/Platform/iOS/Images.xcassets", - "origin": "Resources/Platform/iOS/Images.xcassets" + "dir": "Resources/Platform/iOS/Images.xcassets" }, { - "dir": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage" + "dir": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage" }, { - "dir": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset" + "dir": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset" }, { - "dir": "ShaderLib", - "origin": "ShaderLib" + "dir": "ShaderLib" }, { - "dir": "Shaders", - "origin": "Shaders" + "dir": "Shaders" }, { - "dir": "Shaders/ShaderResourceGroups", - "origin": "Shaders/ShaderResourceGroups" + "dir": "Shaders/ShaderResourceGroups" } ] } diff --git a/Templates/GemRepo/Template/gem.json b/Templates/GemRepo/Template/gem.json index 292681b2b5..7ba555a127 100644 --- a/Templates/GemRepo/Template/gem.json +++ b/Templates/GemRepo/Template/gem.json @@ -1,19 +1,23 @@ { - "gem_name": "${Name}Gem", - "display_name": "${Name}Gem", - "license": "What license ${Name}Gem uses goes here: i.e. Apache-2.0 Or MIT", - "license_url": "", - "origin": "The primary repo for ${Name}Gem goes here: i.e. http://www.mydomain.com", - "summary": "A short description of ${Name}Gem which is zipped up in an archive named gem.zip in the root of the Gem Repo. Though not required, it is recommended that the sha256 of the gem.zip file should be placed in the sha256 field of this gem.json so the download can be verified.", + "gem_name": "${Name}", + "display_name": "${Name}", + "license": "What license ${Name} uses goes here: i.e. Apache-2.0 or MIT", + "license_url": "Link to the license web site goes here: i.e. https://opensource.org/licenses/Apache-2.0 Or https://opensource.org/licenses/MIT", + "origin": "The name of the originator goes here. i.e. XYZ Inc.", + "origin_url": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", + "type": "Code", + "summary": "A short description of ${Name} which is zipped up in an archive named gem.zip in the root of the Gem Repo. Though not required, it is recommended that the sha256 of the gem.zip file be placed in the sha256 field of this gem.json so the download can be verified.", "origin_uri": "${RepoURI}/gem.zip", "sha256": "", - "type": "Code", "canonical_tags": [ "Gem" ], "user_tags": [ - "${Name}Gem" + "${Name}" ], "icon_path": "preview.png", - "requirements": "" + "requirements": "", + "documentation_url": "", + "dependencies": [ + ] } diff --git a/Templates/GemRepo/template.json b/Templates/GemRepo/template.json index 88123a9dae..ca042329be 100644 --- a/Templates/GemRepo/template.json +++ b/Templates/GemRepo/template.json @@ -1,10 +1,14 @@ { "template_name": "GemRepo", - "origin": "The primary repo for GemRepo goes here: i.e. http://www.mydomain.com", - "license": "What license GemRepo uses goes here: i.e. https://opensource.org/licenses/MIT", + "origin_url": "https://github.com/o3de/o3de", + "license": "Apache-2.0 or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "display_name": "GemRepo", "summary": "A Gem Repository that contains a single Gem.", - "canonical_tags": [], + "canonical_tags": [ + "Gem", + "Repo" + ], "user_tags": [ "GemRepo" ], @@ -12,15 +16,11 @@ "copyFiles": [ { "file": "gem.json", - "origin": "gem.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "repo.json", - "origin": "repo.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true } ], "createDirectories": [] diff --git a/Templates/MinimalProject/Template/CMakeLists.txt b/Templates/MinimalProject/Template/CMakeLists.txt index ae4bb662a3..420a92948d 100644 --- a/Templates/MinimalProject/Template/CMakeLists.txt +++ b/Templates/MinimalProject/Template/CMakeLists.txt @@ -29,5 +29,4 @@ else() set_property(GLOBAL APPEND PROPERTY LY_PROJECTS_TARGET_NAME ${project_target_name}) - add_subdirectory(Code) endif() diff --git a/Templates/MinimalProject/Template/Code/${NameLower}_files.cmake b/Templates/MinimalProject/Template/Gem/${NameLower}_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/${NameLower}_files.cmake rename to Templates/MinimalProject/Template/Gem/${NameLower}_files.cmake diff --git a/Templates/MinimalProject/Template/Code/${NameLower}_shared_files.cmake b/Templates/MinimalProject/Template/Gem/${NameLower}_shared_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/${NameLower}_shared_files.cmake rename to Templates/MinimalProject/Template/Gem/${NameLower}_shared_files.cmake diff --git a/Templates/DefaultProject/Template/Code/CMakeLists.txt b/Templates/MinimalProject/Template/Gem/CMakeLists.txt similarity index 87% rename from Templates/DefaultProject/Template/Code/CMakeLists.txt rename to Templates/MinimalProject/Template/Gem/CMakeLists.txt index 7bbb9a0852..6b1dcf9172 100644 --- a/Templates/DefaultProject/Template/Code/CMakeLists.txt +++ b/Templates/MinimalProject/Template/Gem/CMakeLists.txt @@ -6,13 +6,17 @@ # # {END_LICENSE} +set(gem_path ${CMAKE_CURRENT_LIST_DIR}) +set(gem_json ${gem_path}/gem.json) +o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path) + # Currently we are in the ${Name}/Code folder: ${CMAKE_CURRENT_LIST_DIR} # Get the platform specific folder ${pal_dir} for the current folder: ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} -# Note: ly_get_list_relative_pal_filename will take care of the details for us, as this may be a restricted platform +# Note: o3de_pal_dir will take care of the details for us, as this may be a restricted platform # in which case it will see if that platform is present here or in the restricted folder. -# i.e. It could here : ${Name}/Code/Platform/ or +# i.e. It could here : ${Name}/Code/Platform/ or # //${Name}/Code -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${o3de_project_restricted_path} ${o3de_project_path} ${o3de_project_name}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${gem_restricted_path} ${gem_path} ${gem_parent_relative_path}) # Now that we have the platform abstraction layer (PAL) folder for this folder, thats where we will find the # traits for this platform. Traits for a platform are defines for things like whether or not something in this project @@ -71,6 +75,7 @@ ly_create_alias(NAME ${Name}.Servers NAMESPACE Gem TARGETS Gem::${Name}) # Enable the specified list of gems from GEM_FILE or GEMS list for this specific project: ly_enable_gems(PROJECT_NAME ${Name} GEM_FILE enabled_gems.cmake) + if(PAL_TRAIT_BUILD_SERVER_SUPPORTED) # this property causes it to actually make a ServerLauncher. # if you don't want a Server application, you can remove this and the diff --git a/Templates/MinimalProject/Template/Code/Include/${Name}/${Name}Bus.h b/Templates/MinimalProject/Template/Gem/Include/${Name}/${Name}Bus.h similarity index 100% rename from Templates/MinimalProject/Template/Code/Include/${Name}/${Name}Bus.h rename to Templates/MinimalProject/Template/Gem/Include/${Name}/${Name}Bus.h diff --git a/Templates/MinimalProject/Template/Code/Platform/Android/${NameLower}_android_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/Android/${NameLower}_android_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Android/${NameLower}_android_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Android/${NameLower}_android_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Android/${NameLower}_shared_android_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/Android/${NameLower}_shared_android_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Android/${NameLower}_shared_android_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Android/${NameLower}_shared_android_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Android/PAL_android.cmake b/Templates/MinimalProject/Template/Gem/Platform/Android/PAL_android.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Android/PAL_android.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Android/PAL_android.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Linux/${NameLower}_linux_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/Linux/${NameLower}_linux_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Linux/${NameLower}_linux_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Linux/${NameLower}_linux_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Linux/${NameLower}_shared_linux_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/Linux/${NameLower}_shared_linux_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Linux/${NameLower}_shared_linux_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Linux/${NameLower}_shared_linux_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Linux/PAL_linux.cmake b/Templates/MinimalProject/Template/Gem/Platform/Linux/PAL_linux.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Linux/PAL_linux.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Linux/PAL_linux.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Mac/${NameLower}_mac_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/Mac/${NameLower}_mac_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Mac/${NameLower}_mac_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Mac/${NameLower}_mac_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Mac/${NameLower}_shared_mac_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/Mac/${NameLower}_shared_mac_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Mac/${NameLower}_shared_mac_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Mac/${NameLower}_shared_mac_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Mac/PAL_mac.cmake b/Templates/MinimalProject/Template/Gem/Platform/Mac/PAL_mac.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Mac/PAL_mac.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Mac/PAL_mac.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Windows/${NameLower}_shared_windows_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/Windows/${NameLower}_shared_windows_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Windows/${NameLower}_shared_windows_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Windows/${NameLower}_shared_windows_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Windows/${NameLower}_windows_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/Windows/${NameLower}_windows_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Windows/${NameLower}_windows_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Windows/${NameLower}_windows_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/Windows/PAL_windows.cmake b/Templates/MinimalProject/Template/Gem/Platform/Windows/PAL_windows.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/Windows/PAL_windows.cmake rename to Templates/MinimalProject/Template/Gem/Platform/Windows/PAL_windows.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/iOS/${NameLower}_ios_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/iOS/${NameLower}_ios_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/iOS/${NameLower}_ios_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/iOS/${NameLower}_ios_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/iOS/${NameLower}_shared_ios_files.cmake b/Templates/MinimalProject/Template/Gem/Platform/iOS/${NameLower}_shared_ios_files.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/iOS/${NameLower}_shared_ios_files.cmake rename to Templates/MinimalProject/Template/Gem/Platform/iOS/${NameLower}_shared_ios_files.cmake diff --git a/Templates/MinimalProject/Template/Code/Platform/iOS/PAL_ios.cmake b/Templates/MinimalProject/Template/Gem/Platform/iOS/PAL_ios.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/Platform/iOS/PAL_ios.cmake rename to Templates/MinimalProject/Template/Gem/Platform/iOS/PAL_ios.cmake diff --git a/Templates/MinimalProject/Template/Code/Source/${Name}Module.cpp b/Templates/MinimalProject/Template/Gem/Source/${Name}Module.cpp similarity index 100% rename from Templates/MinimalProject/Template/Code/Source/${Name}Module.cpp rename to Templates/MinimalProject/Template/Gem/Source/${Name}Module.cpp diff --git a/Templates/MinimalProject/Template/Code/Source/${Name}SystemComponent.cpp b/Templates/MinimalProject/Template/Gem/Source/${Name}SystemComponent.cpp similarity index 100% rename from Templates/MinimalProject/Template/Code/Source/${Name}SystemComponent.cpp rename to Templates/MinimalProject/Template/Gem/Source/${Name}SystemComponent.cpp diff --git a/Templates/MinimalProject/Template/Code/Source/${Name}SystemComponent.h b/Templates/MinimalProject/Template/Gem/Source/${Name}SystemComponent.h similarity index 100% rename from Templates/MinimalProject/Template/Code/Source/${Name}SystemComponent.h rename to Templates/MinimalProject/Template/Gem/Source/${Name}SystemComponent.h diff --git a/Templates/MinimalProject/Template/Code/enabled_gems.cmake b/Templates/MinimalProject/Template/Gem/enabled_gems.cmake similarity index 100% rename from Templates/MinimalProject/Template/Code/enabled_gems.cmake rename to Templates/MinimalProject/Template/Gem/enabled_gems.cmake diff --git a/Templates/MinimalProject/Template/Gem/gem.json b/Templates/MinimalProject/Template/Gem/gem.json new file mode 100644 index 0000000000..b60f512006 --- /dev/null +++ b/Templates/MinimalProject/Template/Gem/gem.json @@ -0,0 +1,21 @@ +{ + "gem_name": "${Name}", + "display_name": "${Name}", + "license": "What license ${Name} uses goes here: i.e. Apache-2.0 or MIT", + "license_url": "Link to the license web site goes here: i.e. https://opensource.org/licenses/Apache-2.0 Or https://opensource.org/licenses/MIT", + "origin": "The name of the originator goes here. i.e. XYZ Inc.", + "origin_url": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", + "type": "", + "summary": "A short description of ${Name}.", + "canonical_tags": [ + "Gem" + ], + "user_tags": [ + "${Name}" + ], + "icon_path": "preview.png", + "requirements": "", + "documentation_url": "", + "dependencies": [ + ] +} diff --git a/Templates/MinimalProject/Template/cmake/CompilerSettings.cmake b/Templates/MinimalProject/Template/cmake/CompilerSettings.cmake index 60bda1d45b..4efaecd60f 100644 --- a/Templates/MinimalProject/Template/cmake/CompilerSettings.cmake +++ b/Templates/MinimalProject/Template/cmake/CompilerSettings.cmake @@ -1,10 +1,10 @@ -# +# {BEGIN_LICENSE} # Copyright (c) Contributors to the Open 3D Engine Project. # For complete copyright and license terms please see the LICENSE at the root of this distribution. # # SPDX-License-Identifier: Apache-2.0 OR MIT # -# +# {END_LICENSE} # File to tweak compiler settings before compiler detection happens (before project() is called) # We dont have PAL enabled at this point, so we can only use pure-CMake variables diff --git a/Templates/MinimalProject/Template/cmake/Platform/Linux/CompilerSettings_linux.cmake b/Templates/MinimalProject/Template/cmake/Platform/Linux/CompilerSettings_linux.cmake index 9bb629c53b..386117873f 100644 --- a/Templates/MinimalProject/Template/cmake/Platform/Linux/CompilerSettings_linux.cmake +++ b/Templates/MinimalProject/Template/cmake/Platform/Linux/CompilerSettings_linux.cmake @@ -1,10 +1,10 @@ -# +# {BEGIN_LICENSE} # Copyright (c) Contributors to the Open 3D Engine Project. # For complete copyright and license terms please see the LICENSE at the root of this distribution. # # SPDX-License-Identifier: Apache-2.0 OR MIT # -# +# {END_LICENSE} if(NOT CMAKE_C_COMPILER AND NOT CMAKE_CXX_COMPILER AND NOT "$ENV{CC}" AND NOT "$ENV{CXX}") set(path_search diff --git a/Templates/MinimalProject/Template/project.json b/Templates/MinimalProject/Template/project.json index f8d4643ce9..a303186a64 100644 --- a/Templates/MinimalProject/Template/project.json +++ b/Templates/MinimalProject/Template/project.json @@ -2,7 +2,7 @@ "project_name": "${Name}", "project_id": "${ProjectId}", "origin": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", - "license": "What license ${Name} uses goes here: i.e. https://opensource.org/licenses/MIT", + "license": "What license ${Name} uses goes here: i.e. https://opensource.org/licenses/Apache-2.0 Or https://opensource.org/licenses/MIT etc.", "display_name": "${Name}", "summary": "A short description of ${Name}.", "canonical_tags": [ @@ -13,5 +13,7 @@ ], "icon_path": "preview.png", "engine": "o3de", - "external_subdirectories": [] + "external_subdirectories": [ + "Gem" + ] } diff --git a/Templates/MinimalProject/template.json b/Templates/MinimalProject/template.json index 7d6a4f9b94..4cc3031ff5 100644 --- a/Templates/MinimalProject/template.json +++ b/Templates/MinimalProject/template.json @@ -1,10 +1,18 @@ { "template_name": "MinimalProject", - "origin": "The primary repo for MinimalProject goes here: i.e. http://www.mydomain.com", - "license": "What license MinimalProject uses goes here: i.e. https://opensource.org/licenses/MIT", - "display_name": "Minimal", - "summary": "This will be a good starting point for developers who are looking for building the game with the bare minimum of gems in O3DE, and adding more when needed. ", - "canonical_tags": [], + "template_restricted_platform_relative_path": "Templates/MinimalProject", + "restricted_name": "o3de", + "restricted_platform_relative_path": "Templates/MinimalProject", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", + "license": "Apache-2.0 or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", + "display_name": "Minimal Project Template", + "summary": "Use this project template to create project that is the absolute minimum needed to get started in O3DE.", + "canonical_tags": [ + "Template", + "Project" + ], "user_tags": [ "MinimalProject" ], @@ -12,645 +20,454 @@ "copyFiles": [ { "file": ".gitignore", - "origin": ".gitignore", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "CMakeLists.txt", - "origin": "CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { - "file": "Code/${NameLower}_files.cmake", - "origin": "Code/${NameLower}_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "cmake/EngineFinder.cmake", + "isTemplated": false }, { - "file": "Code/${NameLower}_shared_files.cmake", - "origin": "Code/${NameLower}_shared_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "cmake/CompilerSettings.cmake", + "isTemplated": false }, { - "file": "Code/CMakeLists.txt", - "origin": "Code/CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "file": "cmake/Platform/Linux/CompilerSettings_linux.cmake", + "isTemplated": false }, { - "file": "Code/Include/${Name}/${Name}Bus.h", - "origin": "Code/Include/${Name}/${Name}Bus.h", - "isTemplated": true, - "isOptional": false + "file": "Config/shader_global_build_options.json", + "isTemplated": false }, { - "file": "Code/Platform/Android/${NameLower}_android_files.cmake", - "origin": "Code/Platform/Android/${NameLower}_android_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/${NameLower}_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Android/${NameLower}_shared_android_files.cmake", - "origin": "Code/Platform/Android/${NameLower}_shared_android_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/${NameLower}_shared_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Android/PAL_android.cmake", - "origin": "Code/Platform/Android/PAL_android.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/CMakeLists.txt", + "isTemplated": true }, { - "file": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Include/${Name}/${Name}Bus.h", + "isTemplated": true }, { - "file": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Android/${NameLower}_android_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Linux/PAL_linux.cmake", - "origin": "Code/Platform/Linux/PAL_linux.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Android/${NameLower}_shared_android_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Android/PAL_android.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Linux/${NameLower}_linux_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Mac/PAL_mac.cmake", - "origin": "Code/Platform/Mac/PAL_mac.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Linux/${NameLower}_shared_linux_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Linux/PAL_linux.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Mac/${NameLower}_mac_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/Windows/PAL_windows.cmake", - "origin": "Code/Platform/Windows/PAL_windows.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Mac/${NameLower}_shared_mac_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/iOS/${NameLower}_ios_files.cmake", - "origin": "Code/Platform/iOS/${NameLower}_ios_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Mac/PAL_mac.cmake", + "isTemplated": true }, { - "file": "Code/Platform/iOS/${NameLower}_shared_ios_files.cmake", - "origin": "Code/Platform/iOS/${NameLower}_shared_ios_files.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Windows/${NameLower}_shared_windows_files.cmake", + "isTemplated": true }, { - "file": "Code/Platform/iOS/PAL_ios.cmake", - "origin": "Code/Platform/iOS/PAL_ios.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Windows/${NameLower}_windows_files.cmake", + "isTemplated": true }, { - "file": "Code/Source/${Name}Module.cpp", - "origin": "Code/Source/${Name}Module.cpp", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/Windows/PAL_windows.cmake", + "isTemplated": true }, { - "file": "Code/Source/${Name}SystemComponent.cpp", - "origin": "Code/Source/${Name}SystemComponent.cpp", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/iOS/${NameLower}_ios_files.cmake", + "isTemplated": true }, { - "file": "Code/Source/${Name}SystemComponent.h", - "origin": "Code/Source/${Name}SystemComponent.h", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/iOS/${NameLower}_shared_ios_files.cmake", + "isTemplated": true }, { - "file": "Code/enabled_gems.cmake", - "origin": "Code/enabled_gems.cmake", - "isTemplated": true, - "isOptional": false + "file": "Gem/Platform/iOS/PAL_ios.cmake", + "isTemplated": true }, { - "file": "Code/gem.json", - "origin": "Code/gem.json", - "isTemplated": true, - "isOptional": true + "file": "Gem/Source/${Name}Module.cpp", + "isTemplated": true }, { - "file": "Config/shader_global_build_options.json", - "origin": "Config/shader_global_build_options.json", - "isTemplated": false, - "isOptional": false + "file": "Gem/Source/${Name}SystemComponent.cpp", + "isTemplated": true }, { - "file": "cmake/EngineFinder.cmake", - "origin": "cmake/EngineFinder.cmake", - "isTemplated": false, - "isOptional": false + "file": "Gem/Source/${Name}SystemComponent.h", + "isTemplated": true }, { - "file": "cmake/CompilerSettings.cmake", - "origin": "cmake/CompilerSettings.cmake", - "isTemplated": false, - "isOptional": false + "file": "Gem/enabled_gems.cmake", + "isTemplated": true }, { - "file": "cmake/Platform/Linux/CompilerSettings_linux.cmake", - "origin": "cmake/Platform/Linux/CompilerSettings_linux.cmake", - "isTemplated": false, - "isOptional": false + "file": "Gem/gem.json", + "isTemplated": true }, { "file": "Platform/Android/android_project.cmake", - "origin": "Platform/Android/android_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Android/android_project.json", - "origin": "Platform/Android/android_project.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Linux/linux_project.cmake", - "origin": "Platform/Linux/linux_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Linux/linux_project.json", - "origin": "Platform/Linux/linux_project.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Mac/mac_project.cmake", - "origin": "Platform/Mac/mac_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Mac/mac_project.json", - "origin": "Platform/Mac/mac_project.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/Windows/windows_project.cmake", - "origin": "Platform/Windows/windows_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/Windows/windows_project.json", - "origin": "Platform/Windows/windows_project.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Platform/iOS/ios_project.cmake", - "origin": "Platform/iOS/ios_project.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Platform/iOS/ios_project.json", - "origin": "Platform/iOS/ios_project.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Registry/assets_scan_folders.setreg", - "origin": "Registry/assets_scan_folders.setreg", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Resources/LegacyLogoLauncher.bmp", - "origin": "Resources/LegacyLogoLauncher.bmp", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/GameSDK.ico", - "origin": "Resources/GameSDK.ico", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/Contents.json", - "origin": "Resources/Platform/Mac/Images.xcassets/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/Contents.json", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128_2x.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_128.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_16.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_16.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_16_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_16_2x.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256_2x.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_256.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_32.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_32.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_32_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_32_2x.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_512.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_512.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_512_2x.png", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset/icon_512_2x.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/Mac/Info.plist", - "origin": "Resources/Platform/Mac/Info.plist", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Resources/Platform/iOS/Images.xcassets/Contents.json", - "origin": "Resources/Platform/iOS/Images.xcassets/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/Contents.json", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage1024x768.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage1024x768.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage1536x2048.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage1536x2048.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage2048x1536.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage2048x1536.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage768x1024.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPadLaunchImage768x1024.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPhoneLaunchImage640x1136.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPhoneLaunchImage640x1136.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPhoneLaunchImage640x960.png", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage/iPhoneLaunchImage640x960.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/Contents.json", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/Contents.json", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadAppIcon152x152.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadAppIcon152x152.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadAppIcon76x76.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadAppIcon76x76.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadProAppIcon167x167.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadProAppIcon167x167.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSettingsIcon29x29.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSettingsIcon29x29.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSettingsIcon58x58.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSettingsIcon58x58.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSpotlightIcon40x40.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSpotlightIcon40x40.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSpotlightIcon80x80.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPadSpotlightIcon80x80.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneAppIcon120x120.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneAppIcon120x120.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneAppIcon180x180.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneAppIcon180x180.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSettingsIcon58x58.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSettingsIcon58x58.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSettingsIcon87x87.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSettingsIcon87x87.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSpotlightIcon120x120.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSpotlightIcon120x120.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSpotlightIcon80x80.png", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset/iPhoneSpotlightIcon80x80.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Resources/Platform/iOS/Info.plist", - "origin": "Resources/Platform/iOS/Info.plist", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "ShaderLib/README.md", - "origin": "ShaderLib/README.md", - "isTemplated": false, - "isOptional": true + "isTemplated": false }, { "file": "ShaderLib/scenesrg.srgi", - "origin": "ShaderLib/scenesrg.srgi", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "ShaderLib/viewsrg.srgi", - "origin": "ShaderLib/viewsrg.srgi", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "autoexec.cfg", - "origin": "autoexec.cfg", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "game.cfg", - "origin": "game.cfg", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "preview.png", - "origin": "preview.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "project.json", - "origin": "project.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true } ], "createDirectories": [ { - "dir": "Assets", - "origin": "Assets" + "dir": "Assets" + }, + { + "dir": "cmake" + }, + { + "dir": "cmake/Platform" + }, + { + "dir": "cmake/Platform/Linux" + }, + { + "dir": "Config" }, { - "dir": "Code", - "origin": "Code" + "dir": "Gem" }, { - "dir": "Code/Include", - "origin": "Code/Include" + "dir": "Gem/Include" }, { - "dir": "Code/Include/${Name}", - "origin": "Code/Include/${Name}" + "dir": "Gem/Include/${Name}" }, { - "dir": "Code/Platform", - "origin": "Code/Platform" + "dir": "Gem/Platform" }, { - "dir": "Code/Platform/Android", - "origin": "Code/Platform/Android" + "dir": "Gem/Platform/Android" }, { - "dir": "Code/Platform/Linux", - "origin": "Code/Platform/Linux" + "dir": "Gem/Platform/Linux" }, { - "dir": "Code/Platform/Mac", - "origin": "Code/Platform/Mac" + "dir": "Gem/Platform/Mac" }, { - "dir": "Code/Platform/Windows", - "origin": "Code/Platform/Windows" + "dir": "Gem/Platform/Windows" }, { - "dir": "Code/Platform/iOS", - "origin": "Code/Platform/iOS" + "dir": "Gem/Platform/iOS" }, { - "dir": "Code/Source", - "origin": "Code/Source" + "dir": "Gem/Source" }, { - "dir": "Config", - "origin": "Config" + "dir": "Config" }, { - "dir": "Platform", - "origin": "Platform" + "dir": "Platform" }, { - "dir": "Platform/Android", - "origin": "Platform/Android" + "dir": "Platform/Android" }, { - "dir": "Platform/Linux", - "origin": "Platform/Linux" + "dir": "Platform/Linux" }, { - "dir": "Platform/Mac", - "origin": "Platform/Mac" + "dir": "Platform/Mac" }, { - "dir": "Platform/Windows", - "origin": "Platform/Windows" + "dir": "Platform/Windows" }, { - "dir": "Platform/iOS", - "origin": "Platform/iOS" + "dir": "Platform/iOS" }, { - "dir": "Registry", - "origin": "Registry" + "dir": "Registry" }, { - "dir": "Resources", - "origin": "Resources" + "dir": "Resources" }, { - "dir": "Resources/Platform", - "origin": "Resources/Platform" + "dir": "Resources/Platform" }, { - "dir": "Resources/Platform/Mac", - "origin": "Resources/Platform/Mac" + "dir": "Resources/Platform/Mac" }, { - "dir": "Resources/Platform/Mac/Images.xcassets", - "origin": "Resources/Platform/Mac/Images.xcassets" + "dir": "Resources/Platform/Mac/Images.xcassets" }, { - "dir": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset", - "origin": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset" + "dir": "Resources/Platform/Mac/Images.xcassets/TestDPAppIcon.appiconset" }, { - "dir": "Resources/Platform/iOS", - "origin": "Resources/Platform/iOS" + "dir": "Resources/Platform/iOS" }, { - "dir": "Resources/Platform/iOS/Images.xcassets", - "origin": "Resources/Platform/iOS/Images.xcassets" + "dir": "Resources/Platform/iOS/Images.xcassets" }, { - "dir": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage", - "origin": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage" + "dir": "Resources/Platform/iOS/Images.xcassets/LaunchImage.launchimage" }, { - "dir": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset", - "origin": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset" + "dir": "Resources/Platform/iOS/Images.xcassets/TestDPAppIcon.appiconset" }, { - "dir": "ShaderLib", - "origin": "ShaderLib" + "dir": "ShaderLib" }, { - "dir": "Shaders", - "origin": "Shaders" + "dir": "Shaders" }, { - "dir": "Shaders/ShaderResourceGroups", - "origin": "Shaders/ShaderResourceGroups" + "dir": "Shaders/ShaderResourceGroups" } ] } diff --git a/Templates/PythonToolGem/Template/gem.json b/Templates/PythonToolGem/Template/gem.json index 84f5b65a3e..3164c7b5b8 100644 --- a/Templates/PythonToolGem/Template/gem.json +++ b/Templates/PythonToolGem/Template/gem.json @@ -2,8 +2,9 @@ "gem_name": "${Name}", "display_name": "${Name}", "license": "What license ${Name} uses goes here: i.e. Apache-2.0 Or MIT", - "license_url": "", - "origin": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", + "origin": "The name of the originator goes here. i.e. XYZ Inc.", + "origin_url": "The primary repo for ${Name} goes here: i.e. http://www.mydomain.com", "type": "Code", "summary": "A short description of ${Name}.", "canonical_tags": [ @@ -14,6 +15,7 @@ ], "icon_path": "preview.png", "requirements": "", + "documentation_url": "", "dependencies": [ "QtForPython" ] diff --git a/Templates/PythonToolGem/template.json b/Templates/PythonToolGem/template.json index 6dc68de3fc..3af74eb49f 100644 --- a/Templates/PythonToolGem/template.json +++ b/Templates/PythonToolGem/template.json @@ -1,12 +1,18 @@ { "template_name": "PythonToolGem", + "template_restricted_platform_relative_path": "Templates/PythonToolGem", "restricted_name": "o3de", - "restricted_platform_relative_path": "Templates", - "origin": "The primary repo for PythonToolGem goes here: i.e. http://www.mydomain.com", - "license": "What license PythonToolGem uses goes here: i.e. https://opensource.org/licenses/MIT", + "restricted_platform_relative_path": "Templates/PythonToolGem", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", + "license": "Apache-2.0 or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "display_name": "PythonToolGem", "summary": "A gem template for a custom tool in Python that gets registered with the Editor.", - "canonical_tags": [], + "canonical_tags": [ + "Python", + "Gem" + ], "user_tags": [ "PythonToolGem" ], @@ -14,221 +20,153 @@ "copyFiles": [ { "file": ".gitignore", - "origin": ".gitignore", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "CMakeLists.txt", - "origin": "CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_editor_files.cmake", - "origin": "Code/${NameLower}_editor_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_editor_shared_files.cmake", - "origin": "Code/${NameLower}_editor_shared_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/${NameLower}_editor_tests_files.cmake", - "origin": "Code/${NameLower}_editor_tests_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/CMakeLists.txt", - "origin": "Code/CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Include/${Name}/${Name}Bus.h", - "origin": "Code/Include/${Name}/${Name}Bus.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "origin": "Code/Platform/Linux/${NameLower}_shared_linux_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Linux/PAL_linux.cmake", - "origin": "Code/Platform/Linux/PAL_linux.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "origin": "Code/Platform/Mac/${NameLower}_shared_mac_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Mac/PAL_mac.cmake", - "origin": "Code/Platform/Mac/PAL_mac.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_shared_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "origin": "Code/Platform/Windows/${NameLower}_windows_files.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Platform/Windows/PAL_windows.cmake", - "origin": "Code/Platform/Windows/PAL_windows.cmake", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}.qrc", - "origin": "Code/Source/${Name}.qrc", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorModule.cpp", - "origin": "Code/Source/${Name}EditorModule.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorSystemComponent.cpp", - "origin": "Code/Source/${Name}EditorSystemComponent.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}EditorSystemComponent.h", - "origin": "Code/Source/${Name}EditorSystemComponent.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/${Name}ModuleInterface.h", - "origin": "Code/Source/${Name}ModuleInterface.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Code/Source/toolbar_icon.svg", - "origin": "Code/Source/toolbar_icon.svg", - "isTemplated": false, - "isOptional": false + "isTemplated": false }, { "file": "Code/Tests/${Name}EditorTest.cpp", - "origin": "Code/Tests/${Name}EditorTest.cpp", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Editor/Scripts/__init__.py", - "origin": "Editor/Scripts/__init__.py", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Editor/Scripts/bootstrap.py", - "origin": "Editor/Scripts/bootstrap.py", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "Editor/Scripts/${NameLower}_dialog.py", - "origin": "Editor/Scripts/${NameLower}_dialog.py", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "gem.json", - "origin": "gem.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "preview.png", - "origin": "preview.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false } ], "createDirectories": [ { - "dir": "Assets", - "origin": "Assets" + "dir": "Assets" }, { - "dir": "Code", - "origin": "Code" + "dir": "Code" }, { - "dir": "Editor", - "origin": "Editor" + "dir": "Editor" }, { - "dir": "Editor/Scripts", - "origin": "Editor/Scripts" + "dir": "Editor/Scripts" }, { - "dir": "Code/Include", - "origin": "Code/Include" + "dir": "Code/Include" }, { - "dir": "Code/Include/${Name}", - "origin": "Code/Include/${Name}" + "dir": "Code/Include/${Name}" }, { - "dir": "Code/Platform", - "origin": "Code/Platform" + "dir": "Code/Platform" }, { - "dir": "Code/Platform/Linux", - "origin": "Code/Platform/Linux" + "dir": "Code/Platform/Linux" }, { - "dir": "Code/Platform/Mac", - "origin": "Code/Platform/Mac" + "dir": "Code/Platform/Mac" }, { - "dir": "Code/Platform/Windows", - "origin": "Code/Platform/Windows" + "dir": "Code/Platform/Windows" }, { - "dir": "Code/Source", - "origin": "Code/Source" + "dir": "Code/Source" }, { - "dir": "Code/Tests", - "origin": "Code/Tests" + "dir": "Code/Tests" } ] } diff --git a/Tools/LyTestTools/ly_test_tools/_internal/pytest_plugin/test_tools_fixtures.py b/Tools/LyTestTools/ly_test_tools/_internal/pytest_plugin/test_tools_fixtures.py index af29064766..1c17d6d519 100755 --- a/Tools/LyTestTools/ly_test_tools/_internal/pytest_plugin/test_tools_fixtures.py +++ b/Tools/LyTestTools/ly_test_tools/_internal/pytest_plugin/test_tools_fixtures.py @@ -413,7 +413,7 @@ def crash_log_watchdog(request, workspace): def _crash_log_watchdog(request, workspace, raise_on_crash): """Separate implementation to call directly during unit tests""" - error_log = os.path.join(workspace.paths.project_log(), 'error.log') + error_log = workspace.paths.crash_log() crash_log_watchdog = ly_test_tools.environment.watchdog.CrashLogWatchdog( error_log, raise_on_condition=raise_on_crash) diff --git a/Tools/LyTestTools/ly_test_tools/o3de/editor_test.py b/Tools/LyTestTools/ly_test_tools/o3de/editor_test.py index fd2157d1cc..8bd4fbe29a 100644 --- a/Tools/LyTestTools/ly_test_tools/o3de/editor_test.py +++ b/Tools/LyTestTools/ly_test_tools/o3de/editor_test.py @@ -762,7 +762,7 @@ class EditorTestSuite(): cmdline = [ "--runpythontest", test_filename, "-logfile", f"@log@/{log_name}", - "-project-log-path", ly_test_tools._internal.pytest_plugin.output_path] + test_cmdline_args + "-project-log-path", editor_utils.retrieve_log_path(run_id, workspace)] + test_cmdline_args editor.args.extend(cmdline) editor.start(backupFiles = False, launch_ap = False, configure_settings=False) @@ -771,7 +771,8 @@ class EditorTestSuite(): output = editor.get_output() return_code = editor.get_returncode() editor_log_content = editor_utils.retrieve_editor_log_content(run_id, log_name, workspace) - + # Save the editor log + workspace.artifact_manager.save_artifact(os.path.join(editor_utils.retrieve_log_path(run_id, workspace), log_name)) if return_code == 0: test_result = Result.Pass.create(test_spec, output, editor_log_content) else: @@ -779,6 +780,9 @@ class EditorTestSuite(): if has_crashed: test_result = Result.Crash.create(test_spec, output, return_code, editor_utils.retrieve_crash_output (run_id, workspace, self._TIMEOUT_CRASH_LOG), None) + # Save the crash log + crash_file_name = os.path.basename(workspace.paths.crash_log()) + workspace.artifact_manager.save_artifact(os.path.join(editor_utils.retrieve_log_path(run_id, workspace), crash_file_name)) editor_utils.cycle_crash_report(run_id, workspace) else: test_result = Result.Fail.create(test_spec, output, editor_log_content) @@ -830,7 +834,7 @@ class EditorTestSuite(): cmdline = [ "--runpythontest", test_filenames_str, "-logfile", f"@log@/{log_name}", - "-project-log-path", ly_test_tools._internal.pytest_plugin.output_path] + test_cmdline_args + "-project-log-path", editor_utils.retrieve_log_path(run_id, workspace)] + test_cmdline_args editor.args.extend(cmdline) editor.start(backupFiles = False, launch_ap = False, configure_settings=False) @@ -842,7 +846,8 @@ class EditorTestSuite(): output = editor.get_output() return_code = editor.get_returncode() editor_log_content = editor_utils.retrieve_editor_log_content(run_id, log_name, workspace) - + # Save the editor log + workspace.artifact_manager.save_artifact(os.path.join(editor_utils.retrieve_log_path(run_id, workspace), log_name)) if return_code == 0: # No need to scrap the output, as all the tests have passed for test_spec in test_spec_list: @@ -863,6 +868,10 @@ class EditorTestSuite(): # The first test with "Unknown" result (no data in output) is likely the one that crashed crash_error = editor_utils.retrieve_crash_output(run_id, workspace, self._TIMEOUT_CRASH_LOG) + # Save the crash log + crash_file_name = os.path.basename(workspace.paths.crash_log()) + workspace.artifact_manager.save_artifact( + os.path.join(editor_utils.retrieve_log_path(run_id, workspace), crash_file_name)) editor_utils.cycle_crash_report(run_id, workspace) results[test_spec_name] = Result.Crash.create(result.test_spec, output, return_code, crash_error, result.editor_log) diff --git a/Tools/LyTestTools/ly_test_tools/o3de/editor_test_utils.py b/Tools/LyTestTools/ly_test_tools/o3de/editor_test_utils.py index 9f1e01342c..7b36a82c07 100644 --- a/Tools/LyTestTools/ly_test_tools/o3de/editor_test_utils.py +++ b/Tools/LyTestTools/ly_test_tools/o3de/editor_test_utils.py @@ -24,7 +24,7 @@ def kill_all_ly_processes(include_asset_processor: bool = True) -> None: :return: None """ LY_PROCESSES = [ - 'Editor', 'Profiler', 'RemoteConsole', + 'Editor', 'Profiler', 'RemoteConsole', 'o3de' ] AP_PROCESSES = [ 'AssetProcessor', 'AssetProcessorBatch', 'AssetBuilder' @@ -71,7 +71,9 @@ def retrieve_crash_output(run_id: int, workspace: AbstractWorkspaceManager, time :return str: The contents of the editor crash file (error.log) """ crash_info = "-- No crash log available --" - crash_log = os.path.join(retrieve_log_path(run_id, workspace), 'error.log') + # Grab the file name of the crash log which can be different depending on platform + crash_file_name = os.path.basename(workspace.paths.crash_log()) + crash_log = os.path.join(retrieve_log_path(run_id, workspace), crash_file_name) try: waiter.wait_for(lambda: os.path.exists(crash_log), timeout=timeout) except AssertionError: @@ -92,7 +94,7 @@ def cycle_crash_report(run_id: int, workspace: AbstractWorkspaceManager) -> None :param workspace: Workspace fixture """ log_path = retrieve_log_path(run_id, workspace) - files_to_cycle = ['error.log', 'error.dmp'] + files_to_cycle = ['crash.log', 'error.log', 'error.dmp'] for filename in files_to_cycle: filepath = os.path.join(log_path, filename) name, ext = os.path.splitext(filename) diff --git a/Tools/LyTestTools/tests/unit/test_editor_test_utils.py b/Tools/LyTestTools/tests/unit/test_editor_test_utils.py index cd361d9e8a..f81d2fd8e6 100644 --- a/Tools/LyTestTools/tests/unit/test_editor_test_utils.py +++ b/Tools/LyTestTools/tests/unit/test_editor_test_utils.py @@ -17,14 +17,15 @@ class TestEditorTestUtils(unittest.TestCase): @mock.patch('ly_test_tools.environment.process_utils.kill_processes_named') def test_KillAllLyProcesses_IncludeAP_CallsCorrectly(self, mock_kill_processes_named): - process_list = ['Editor', 'Profiler', 'RemoteConsole', 'AssetProcessor', 'AssetProcessorBatch', 'AssetBuilder'] + process_list = ['Editor', 'Profiler', 'RemoteConsole', 'o3de', 'AssetProcessor', 'AssetProcessorBatch', + 'AssetBuilder'] editor_test_utils.kill_all_ly_processes(include_asset_processor=True) mock_kill_processes_named.assert_called_once_with(process_list, ignore_extensions=True) @mock.patch('ly_test_tools.environment.process_utils.kill_processes_named') def test_KillAllLyProcesses_NotIncludeAP_CallsCorrectly(self, mock_kill_processes_named): - process_list = ['Editor', 'Profiler', 'RemoteConsole'] + process_list = ['Editor', 'Profiler', 'RemoteConsole', 'o3de'] ap_process_list = ['AssetProcessor', 'AssetProcessorBatch', 'AssetBuilder'] editor_test_utils.kill_all_ly_processes(include_asset_processor=False) @@ -59,22 +60,31 @@ class TestEditorTestUtils(unittest.TestCase): assert expected == editor_test_utils.retrieve_log_path(0, mock_workspace) + @mock.patch('os.listdir') @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') + @mock.patch('os.path.join', mock.MagicMock()) + @mock.patch('os.path.basename', mock.MagicMock()) + @mock.patch('os.path.isfile', mock.MagicMock()) @mock.patch('ly_test_tools.environment.waiter.wait_for', mock.MagicMock()) - def test_RetrieveCrashOutput_CrashLogExists_ReturnsLogInfo(self, mock_retrieve_log_path): - mock_retrieve_log_path.return_value = 'mock_log_path' + def test_RetrieveCrashOutput_CrashLogExists_ReturnsLogInfo(self, mock_retrieve_log_path, mock_listdir): + mock_retrieve_log_path.return_value = 'mock_path' mock_workspace = mock.MagicMock() mock_log = 'mock crash info' + mock_listdir.return_value = ['mock_error_log.log'] with mock.patch('builtins.open', mock.mock_open(read_data=mock_log)) as mock_file: assert mock_log == editor_test_utils.retrieve_crash_output(0, mock_workspace, 0) + @mock.patch('os.listdir') @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') + @mock.patch('os.path.isfile', mock.MagicMock()) @mock.patch('ly_test_tools.environment.waiter.wait_for', mock.MagicMock()) - def test_RetrieveCrashOutput_CrashLogNotExists_ReturnsError(self, mock_retrieve_log_path): + def test_RetrieveCrashOutput_CrashLogNotExists_ReturnsError(self, mock_retrieve_log_path, mock_listdir): mock_retrieve_log_path.return_value = 'mock_log_path' mock_workspace = mock.MagicMock() + mock_workspace.paths.crash_log.return_value = 'mock_file.log' error_message = "No crash log available" + mock_listdir.return_value = ['mock_file.log'] assert error_message in editor_test_utils.retrieve_crash_output(0, mock_workspace, 0) @@ -85,7 +95,7 @@ class TestEditorTestUtils(unittest.TestCase): @mock.patch('os.path.exists') def test_CycleCrashReport_DmpExists_NamedCorrectly(self, mock_exists, mock_retrieve_log_path, mock_strftime, mock_rename): - mock_exists.side_effect = [False, True] + mock_exists.side_effect = [False, False, True] mock_retrieve_log_path.return_value = 'mock_log_path' mock_workspace = mock.MagicMock() mock_strftime.return_value = 'mock_strftime' @@ -101,7 +111,7 @@ class TestEditorTestUtils(unittest.TestCase): @mock.patch('os.path.exists') def test_CycleCrashReport_LogExists_NamedCorrectly(self, mock_exists, mock_retrieve_log_path, mock_strftime, mock_rename): - mock_exists.side_effect = [True, False] + mock_exists.side_effect = [False, True, False] mock_retrieve_log_path.return_value = 'mock_log_path' mock_workspace = mock.MagicMock() mock_strftime.return_value = 'mock_strftime' diff --git a/Tools/LyTestTools/tests/unit/test_fixtures.py b/Tools/LyTestTools/tests/unit/test_fixtures.py index 32dc204bd2..eb36cf6998 100755 --- a/Tools/LyTestTools/tests/unit/test_fixtures.py +++ b/Tools/LyTestTools/tests/unit/test_fixtures.py @@ -323,20 +323,19 @@ class TestFixtures(object): @mock.patch('ly_test_tools.environment.watchdog.CrashLogWatchdog') def test_CrashLogWatchdog_Instantiates_CreatesWatchdog(self, under_test): mock_workspace = mock.MagicMock() - mock_path = 'C:/foo' - mock_workspace.paths.project_log.return_value = mock_path + mock_workspace.paths.crash_log.return_value = mock.MagicMock() mock_request = mock.MagicMock() mock_request.addfinalizer = mock.MagicMock() mock_raise_on_crash = mock.MagicMock() mock_watchdog = test_tools_fixtures._crash_log_watchdog(mock_request, mock_workspace, mock_raise_on_crash) - under_test.assert_called_once_with(os.path.join(mock_path, 'error.log'), raise_on_condition=mock_raise_on_crash) + under_test.assert_called_once_with(mock_workspace.paths.crash_log.return_value, raise_on_condition=mock_raise_on_crash) @mock.patch('ly_test_tools.environment.watchdog.CrashLogWatchdog.start') def test_CrashLogWatchdog_Instantiates_StartsThread(self, under_test): mock_workspace = mock.MagicMock() mock_path = 'C:/foo' - mock_workspace.paths.project_log.return_value = mock_path + mock_workspace.paths.crash_log.return_value = mock_path mock_request = mock.MagicMock() mock_request.addfinalizer = mock.MagicMock() mock_raise_on_crash = mock.MagicMock() @@ -348,7 +347,7 @@ class TestFixtures(object): def test_CrashLogWatchdog_Instantiates_AddsTeardown(self): mock_workspace = mock.MagicMock() mock_path = 'C:/foo' - mock_workspace.paths.project_log.return_value = mock_path + mock_workspace.paths.crash_log.return_value = mock_path mock_request = mock.MagicMock() mock_request.addfinalizer = mock.MagicMock() mock_raise_on_crash = mock.MagicMock() @@ -361,7 +360,7 @@ class TestFixtures(object): def test_CrashLogWatchdog_Teardown_CallsStop(self, mock_stop): mock_workspace = mock.MagicMock() mock_path = 'C:/foo' - mock_workspace.paths.project_log.return_value = mock_path + mock_workspace.paths.crash_log.return_value = mock_path mock_request = mock.MagicMock() mock_request.addfinalizer = mock.MagicMock() mock_raise_condition = mock.MagicMock() diff --git a/Tools/LyTestTools/tests/unit/test_o3de_editor_test.py b/Tools/LyTestTools/tests/unit/test_o3de_editor_test.py index 2b6ae5b471..054159cd16 100644 --- a/Tools/LyTestTools/tests/unit/test_o3de_editor_test.py +++ b/Tools/LyTestTools/tests/unit/test_o3de_editor_test.py @@ -589,6 +589,7 @@ class TestRunningTests(unittest.TestCase): @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') @mock.patch('ly_test_tools.o3de.editor_test_utils.get_testcase_module_filepath') @mock.patch('ly_test_tools.o3de.editor_test_utils.cycle_crash_report') + @mock.patch('os.path.join', mock.MagicMock()) def test_ExecEditorTest_TestSucceeds_ReturnsPass(self, mock_cycle_crash, mock_get_testcase_filepath, mock_retrieve_log, mock_retrieve_editor_log, mock_get_output_results, mock_create): @@ -616,6 +617,7 @@ class TestRunningTests(unittest.TestCase): @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') @mock.patch('ly_test_tools.o3de.editor_test_utils.get_testcase_module_filepath') @mock.patch('ly_test_tools.o3de.editor_test_utils.cycle_crash_report') + @mock.patch('os.path.join', mock.MagicMock()) def test_ExecEditorTest_TestFails_ReturnsFail(self, mock_cycle_crash, mock_get_testcase_filepath, mock_retrieve_log, mock_retrieve_editor_log, mock_get_output_results, mock_create): @@ -644,6 +646,8 @@ class TestRunningTests(unittest.TestCase): @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') @mock.patch('ly_test_tools.o3de.editor_test_utils.get_testcase_module_filepath') @mock.patch('ly_test_tools.o3de.editor_test_utils.cycle_crash_report') + @mock.patch('os.path.join', mock.MagicMock()) + @mock.patch('os.path.basename', mock.MagicMock()) def test_ExecEditorTest_TestCrashes_ReturnsCrash(self, mock_cycle_crash, mock_get_testcase_filepath, mock_retrieve_log, mock_retrieve_editor_log, mock_get_output_results, mock_retrieve_crash, mock_create): @@ -699,10 +703,14 @@ class TestRunningTests(unittest.TestCase): @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') @mock.patch('ly_test_tools.o3de.editor_test_utils.get_testcase_module_filepath') @mock.patch('ly_test_tools.o3de.editor_test_utils.cycle_crash_report') + @mock.patch('os.path.join', mock.MagicMock()) def test_ExecEditorMultitest_AllTestsPass_ReturnsPasses(self, mock_cycle_crash, mock_get_testcase_filepath, mock_retrieve_log, mock_retrieve_editor_log, mock_create): mock_test_suite = ly_test_tools.o3de.editor_test.EditorTestSuite() mock_workspace = mock.MagicMock() + mock_artifact_manager = mock.MagicMock() + mock_artifact_manager.save_artifact.return_value = mock.MagicMock() + mock_workspace.artifact_manager = mock_artifact_manager mock_workspace.paths.engine_root.return_value = "" mock_editor = mock.MagicMock() mock_editor.get_returncode.return_value = 0 @@ -727,6 +735,7 @@ class TestRunningTests(unittest.TestCase): @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') @mock.patch('ly_test_tools.o3de.editor_test_utils.get_testcase_module_filepath') @mock.patch('ly_test_tools.o3de.editor_test_utils.cycle_crash_report') + @mock.patch('os.path.join', mock.MagicMock()) def test_ExecEditorMultitest_OneFailure_CallsCorrectFunc(self, mock_cycle_crash, mock_get_testcase_filepath, mock_retrieve_log, mock_retrieve_editor_log, mock_get_results): mock_test_suite = ly_test_tools.o3de.editor_test.EditorTestSuite() @@ -752,6 +761,8 @@ class TestRunningTests(unittest.TestCase): @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') @mock.patch('ly_test_tools.o3de.editor_test_utils.get_testcase_module_filepath') @mock.patch('ly_test_tools.o3de.editor_test_utils.cycle_crash_report') + @mock.patch('os.path.join', mock.MagicMock()) + @mock.patch('os.path.basename', mock.MagicMock()) def test_ExecEditorMultitest_OneCrash_ReportsOnUnknownResult(self, mock_cycle_crash, mock_get_testcase_filepath, mock_retrieve_log, mock_retrieve_editor_log, mock_get_results, mock_retrieve_crash, mock_create): @@ -787,6 +798,8 @@ class TestRunningTests(unittest.TestCase): @mock.patch('ly_test_tools.o3de.editor_test_utils.retrieve_log_path') @mock.patch('ly_test_tools.o3de.editor_test_utils.get_testcase_module_filepath') @mock.patch('ly_test_tools.o3de.editor_test_utils.cycle_crash_report') + @mock.patch('os.path.join', mock.MagicMock()) + @mock.patch('os.path.basename', mock.MagicMock()) def test_ExecEditorMultitest_ManyUnknown_ReportsUnknownResults(self, mock_cycle_crash, mock_get_testcase_filepath, mock_retrieve_log, mock_retrieve_editor_log, mock_get_results, mock_retrieve_crash, mock_create): diff --git a/cmake/3rdParty.cmake b/cmake/3rdParty.cmake index 7d98c3ea3e..1bea5f4f67 100644 --- a/cmake/3rdParty.cmake +++ b/cmake/3rdParty.cmake @@ -186,7 +186,7 @@ function(ly_add_external_target) endif() # Check if there is a pal file - ly_get_absolute_pal_filename(pal_file ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}/${ly_add_external_target_PACKAGE}_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) + o3de_pal_dir(pal_file ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}/${ly_add_external_target_PACKAGE}_${PAL_PLATFORM_NAME_LOWERCASE}.cmake ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) if(NOT EXISTS ${pal_file}) set(pal_file ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}/${ly_add_external_target_PACKAGE}_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) endif() @@ -357,12 +357,12 @@ endfunction() # Add the 3rdParty folder to find the modules list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR}/3rdParty) -ly_get_absolute_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/3rdParty/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/3rdParty/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) list(APPEND CMAKE_MODULE_PATH ${pal_dir}) if(NOT INSTALLED_ENGINE) # Add the 3rdParty cmake files to the IDE ly_include_cmake_file_list(cmake/3rdParty/cmake_files.cmake) - ly_get_absolute_pal_filename(pal_3rdparty_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/3rdParty/Platform/${PAL_PLATFORM_NAME}) + o3de_pal_dir(pal_3rdparty_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/3rdParty/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) ly_include_cmake_file_list(${pal_3rdparty_dir}/cmake_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake) endif() diff --git a/cmake/3rdParty/BuiltInPackages.cmake b/cmake/3rdParty/BuiltInPackages.cmake index 743e2e983e..e81cfffe01 100644 --- a/cmake/3rdParty/BuiltInPackages.cmake +++ b/cmake/3rdParty/BuiltInPackages.cmake @@ -12,9 +12,9 @@ # cmake/3rdParty/Platform/Windows/BuiltInPackages_windows.cmake #include the platform-specific 3rd party packages. -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) -set(LY_PAL_PACKAGE_FILE_NAME ${CMAKE_CURRENT_LIST_DIR}/${pal_dir}/BuiltInPackages_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) +set(LY_PAL_PACKAGE_FILE_NAME ${pal_dir}/BuiltInPackages_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) include(${LY_PAL_PACKAGE_FILE_NAME}) # add the above file to the ALLFILES list, so that they show up in IDEs diff --git a/cmake/3rdParty/Platform/Android/BuiltInPackages_android.cmake b/cmake/3rdParty/Platform/Android/BuiltInPackages_android.cmake index 6bd50861c7..c6a262926c 100644 --- a/cmake/3rdParty/Platform/Android/BuiltInPackages_android.cmake +++ b/cmake/3rdParty/Platform/Android/BuiltInPackages_android.cmake @@ -14,7 +14,7 @@ ly_associate_package(PACKAGE_NAME cityhash-1.1-multiplatform TARGETS cit ly_associate_package(PACKAGE_NAME expat-2.1.0-multiplatform TARGETS expat PACKAGE_HASH 452256acd1fd699cef24162575b3524fccfb712f5321c83f1df1ce878de5b418) ly_associate_package(PACKAGE_NAME zstd-1.35-multiplatform TARGETS zstd PACKAGE_HASH 45d466c435f1095898578eedde85acf1fd27190e7ea99aeaa9acfd2f09e12665) ly_associate_package(PACKAGE_NAME glad-2.0.0-beta-rev2-multiplatform TARGETS glad PACKAGE_HASH ff97ee9664e97d0854b52a3734c2289329d9f2b4cd69478df6d0ca1f1c9392ee) -ly_associate_package(PACKAGE_NAME lux_core-2.2-rev5-multiplatform TARGETS lux_core PACKAGE_HASH c8c13cf7bc351643e1abd294d0841b24dee60e51647dff13db7aec396ad1e0b5) + # platform-specific: ly_associate_package(PACKAGE_NAME tiff-4.2.0.15-rev4-android TARGETS TIFF PACKAGE_HASH 2c62cdf34a8ee6c7eb091d05d98f60b4da7634c74054d4dbb8736886182f4589) ly_associate_package(PACKAGE_NAME freetype-2.10.4.16-android TARGETS freetype PACKAGE_HASH df9e4d559ea0f03b0666b48c79813b1cd4d9624429148a249865de9f5c2c11cd) diff --git a/cmake/3rdParty/Platform/Linux/BuiltInPackages_linux.cmake b/cmake/3rdParty/Platform/Linux/BuiltInPackages_linux.cmake index 5c84fc3198..f1e8fdc950 100644 --- a/cmake/3rdParty/Platform/Linux/BuiltInPackages_linux.cmake +++ b/cmake/3rdParty/Platform/Linux/BuiltInPackages_linux.cmake @@ -8,7 +8,6 @@ # shared by other platforms: ly_associate_package(PACKAGE_NAME ilmbase-2.3.0-rev4-multiplatform TARGETS ilmbase PACKAGE_HASH 97547fdf1fbc4d81b8ccf382261f8c25514ed3b3c4f8fd493f0a4fa873bba348) -ly_associate_package(PACKAGE_NAME assimp-5.0.1-rev11-multiplatform TARGETS assimplib PACKAGE_HASH 1a9113788b893ef4a2ee63ac01eb71b981a92894a5a51175703fa225f5804dec) ly_associate_package(PACKAGE_NAME md5-2.0-multiplatform TARGETS md5 PACKAGE_HASH 29e52ad22c78051551f78a40c2709594f0378762ae03b417adca3f4b700affdf) ly_associate_package(PACKAGE_NAME RapidJSON-1.1.0-rev1-multiplatform TARGETS RapidJSON PACKAGE_HASH 2f5e26ecf86c3b7a262753e7da69ac59928e78e9534361f3d00c1ad5879e4023) ly_associate_package(PACKAGE_NAME RapidXML-1.13-rev1-multiplatform TARGETS RapidXML PACKAGE_HASH 4b7b5651e47cfd019b6b295cc17bb147b65e53073eaab4a0c0d20a37ab74a246) @@ -18,14 +17,14 @@ ly_associate_package(PACKAGE_NAME expat-2.1.0-multiplatform ly_associate_package(PACKAGE_NAME zstd-1.35-multiplatform TARGETS zstd PACKAGE_HASH 45d466c435f1095898578eedde85acf1fd27190e7ea99aeaa9acfd2f09e12665) ly_associate_package(PACKAGE_NAME SQLite-3.32.2-rev3-multiplatform TARGETS SQLite PACKAGE_HASH dd4d3de6cbb4ce3d15fc504ba0ae0587e515dc89a25228037035fc0aef4831f4) ly_associate_package(PACKAGE_NAME glad-2.0.0-beta-rev2-multiplatform TARGETS glad PACKAGE_HASH ff97ee9664e97d0854b52a3734c2289329d9f2b4cd69478df6d0ca1f1c9392ee) -ly_associate_package(PACKAGE_NAME lux_core-2.2-rev5-multiplatform TARGETS lux_core PACKAGE_HASH c8c13cf7bc351643e1abd294d0841b24dee60e51647dff13db7aec396ad1e0b5) ly_associate_package(PACKAGE_NAME xxhash-0.7.4-rev1-multiplatform TARGETS xxhash PACKAGE_HASH e81f3e6c4065975833996dd1fcffe46c3cf0f9e3a4207ec5f4a1b564ba75861e) # platform-specific: +ly_associate_package(PACKAGE_NAME assimp-5.0.1-rev12-linux TARGETS assimplib PACKAGE_HASH 49d32e11c594e58a9079972ad63570dd895ac61e6148e428b9c39a62feb676ee) ly_associate_package(PACKAGE_NAME AWSGameLiftServerSDK-3.4.1-rev1-linux TARGETS AWSGameLiftServerSDK PACKAGE_HASH a8149a95bd100384af6ade97e2b21a56173740d921e6c3da8188cd51554d39af) ly_associate_package(PACKAGE_NAME tiff-4.2.0.15-rev3-linux TARGETS TIFF PACKAGE_HASH 2377f48b2ebc2d1628d9f65186c881544c92891312abe478a20d10b85877409a) ly_associate_package(PACKAGE_NAME freetype-2.10.4.16-linux TARGETS freetype PACKAGE_HASH 3f10c703d9001ecd2bb51a3bd003d3237c02d8f947ad0161c0252fdc54cbcf97) -ly_associate_package(PACKAGE_NAME AWSNativeSDK-1.7.167-rev6-linux TARGETS AWSNativeSDK PACKAGE_HASH 490291e4c8057975c3ab86feb971b8a38871c58bac5e5d86abdd1aeb7141eec4) +ly_associate_package(PACKAGE_NAME AWSNativeSDK-1.9.50-rev1-linux TARGETS AWSNativeSDK PACKAGE_HASH f30b6969c6732a7c1a23a59d205a150633a7f219dcb60d837b543888d2c63ea1) ly_associate_package(PACKAGE_NAME Lua-5.3.5-rev5-linux TARGETS Lua PACKAGE_HASH 1adc812abe3dd0dbb2ca9756f81d8f0e0ba45779ac85bf1d8455b25c531a38b0) ly_associate_package(PACKAGE_NAME PhysX-4.1.2.29882248-rev5-linux TARGETS PhysX PACKAGE_HASH fa72365df409376aef02d1763194dc91d255bdfcb4e8febcfbb64d23a3e50b96) ly_associate_package(PACKAGE_NAME mcpp-2.7.2_az.2-rev1-linux TARGETS mcpp PACKAGE_HASH df7a998d0bc3fedf44b5bdebaf69ddad6033355b71a590e8642445ec77bc6c41) diff --git a/cmake/3rdParty/Platform/Mac/BuiltInPackages_mac.cmake b/cmake/3rdParty/Platform/Mac/BuiltInPackages_mac.cmake index 994f42e983..575a2dd70e 100644 --- a/cmake/3rdParty/Platform/Mac/BuiltInPackages_mac.cmake +++ b/cmake/3rdParty/Platform/Mac/BuiltInPackages_mac.cmake @@ -8,7 +8,6 @@ # shared by other platforms: ly_associate_package(PACKAGE_NAME ilmbase-2.3.0-rev4-multiplatform TARGETS ilmbase PACKAGE_HASH 97547fdf1fbc4d81b8ccf382261f8c25514ed3b3c4f8fd493f0a4fa873bba348) -ly_associate_package(PACKAGE_NAME assimp-5.0.1-rev11-multiplatform TARGETS assimplib PACKAGE_HASH 1a9113788b893ef4a2ee63ac01eb71b981a92894a5a51175703fa225f5804dec) ly_associate_package(PACKAGE_NAME md5-2.0-multiplatform TARGETS md5 PACKAGE_HASH 29e52ad22c78051551f78a40c2709594f0378762ae03b417adca3f4b700affdf) ly_associate_package(PACKAGE_NAME RapidJSON-1.1.0-rev1-multiplatform TARGETS RapidJSON PACKAGE_HASH 2f5e26ecf86c3b7a262753e7da69ac59928e78e9534361f3d00c1ad5879e4023) ly_associate_package(PACKAGE_NAME RapidXML-1.13-rev1-multiplatform TARGETS RapidXML PACKAGE_HASH 4b7b5651e47cfd019b6b295cc17bb147b65e53073eaab4a0c0d20a37ab74a246) @@ -18,15 +17,15 @@ ly_associate_package(PACKAGE_NAME expat-2.1.0-multiplatform ly_associate_package(PACKAGE_NAME zstd-1.35-multiplatform TARGETS zstd PACKAGE_HASH 45d466c435f1095898578eedde85acf1fd27190e7ea99aeaa9acfd2f09e12665) ly_associate_package(PACKAGE_NAME SQLite-3.32.2-rev3-multiplatform TARGETS SQLite PACKAGE_HASH dd4d3de6cbb4ce3d15fc504ba0ae0587e515dc89a25228037035fc0aef4831f4) ly_associate_package(PACKAGE_NAME glad-2.0.0-beta-rev2-multiplatform TARGETS glad PACKAGE_HASH ff97ee9664e97d0854b52a3734c2289329d9f2b4cd69478df6d0ca1f1c9392ee) -ly_associate_package(PACKAGE_NAME lux_core-2.2-rev5-multiplatform TARGETS lux_core PACKAGE_HASH c8c13cf7bc351643e1abd294d0841b24dee60e51647dff13db7aec396ad1e0b5) ly_associate_package(PACKAGE_NAME xxhash-0.7.4-rev1-multiplatform TARGETS xxhash PACKAGE_HASH e81f3e6c4065975833996dd1fcffe46c3cf0f9e3a4207ec5f4a1b564ba75861e) # platform-specific: +ly_associate_package(PACKAGE_NAME assimp-5.0.1-rev12-mac TARGETS assimplib PACKAGE_HASH 12db03817553f607bee0d65b690bcaae748014f3ed9266b70384f463bc98c9d1) ly_associate_package(PACKAGE_NAME DirectXShaderCompilerDxc-1.6.2104-o3de-rev3-mac TARGETS DirectXShaderCompilerDxc PACKAGE_HASH 3f77367dbb0342136ec4ebbd44bc1fedf7198089a0f83c5631248530769b2be6) ly_associate_package(PACKAGE_NAME SPIRVCross-2021.04.29-rev1-mac TARGETS SPIRVCross PACKAGE_HASH 78c6376ed2fd195b9b1f5fb2b56e5267a32c3aa21fb399e905308de470eb4515) ly_associate_package(PACKAGE_NAME tiff-4.2.0.15-rev3-mac TARGETS TIFF PACKAGE_HASH c2615ccdadcc0e1d6c5ed61e5965c4d3a82193d206591b79b805c3b3ff35a4bf) ly_associate_package(PACKAGE_NAME freetype-2.10.4.16-mac TARGETS freetype PACKAGE_HASH f159b346ac3251fb29cb8dd5f805c99b0015ed7fdb3887f656945ca701a61d0d) -ly_associate_package(PACKAGE_NAME AWSNativeSDK-1.7.167-rev6-mac TARGETS AWSNativeSDK PACKAGE_HASH 9b058376dec042ace98e198e902b399739adeb9e9398a6c210171fb530164577) +ly_associate_package(PACKAGE_NAME AWSNativeSDK-1.9.50-rev1-mac TARGETS AWSNativeSDK PACKAGE_HASH 6c27a49376870c606144e4639e15867f9db7e4a1ee5f1a726f152d3bd8459966) ly_associate_package(PACKAGE_NAME Lua-5.3.5-rev6-mac TARGETS Lua PACKAGE_HASH b9079fd35634774c9269028447562c6b712dbc83b9c64975c095fd423ff04c08) ly_associate_package(PACKAGE_NAME PhysX-4.1.2.29882248-rev5-mac TARGETS PhysX PACKAGE_HASH 83940b3876115db82cd8ffcb9e902278e75846d6ad94a41e135b155cee1ee186) ly_associate_package(PACKAGE_NAME mcpp-2.7.2_az.2-rev1-mac TARGETS mcpp PACKAGE_HASH be9558905c9c49179ef3d7d84f0a5472415acdf7fe2d76eb060d9431723ddf2e) diff --git a/cmake/3rdParty/Platform/Windows/BuiltInPackages_windows.cmake b/cmake/3rdParty/Platform/Windows/BuiltInPackages_windows.cmake index 6e2d2a92e2..7fd07927cc 100644 --- a/cmake/3rdParty/Platform/Windows/BuiltInPackages_windows.cmake +++ b/cmake/3rdParty/Platform/Windows/BuiltInPackages_windows.cmake @@ -8,7 +8,6 @@ # shared by other platforms: ly_associate_package(PACKAGE_NAME ilmbase-2.3.0-rev4-multiplatform TARGETS ilmbase PACKAGE_HASH 97547fdf1fbc4d81b8ccf382261f8c25514ed3b3c4f8fd493f0a4fa873bba348) -ly_associate_package(PACKAGE_NAME assimp-5.0.1-rev11-multiplatform TARGETS assimplib PACKAGE_HASH 1a9113788b893ef4a2ee63ac01eb71b981a92894a5a51175703fa225f5804dec) ly_associate_package(PACKAGE_NAME md5-2.0-multiplatform TARGETS md5 PACKAGE_HASH 29e52ad22c78051551f78a40c2709594f0378762ae03b417adca3f4b700affdf) ly_associate_package(PACKAGE_NAME RapidJSON-1.1.0-rev1-multiplatform TARGETS RapidJSON PACKAGE_HASH 2f5e26ecf86c3b7a262753e7da69ac59928e78e9534361f3d00c1ad5879e4023) ly_associate_package(PACKAGE_NAME RapidXML-1.13-rev1-multiplatform TARGETS RapidXML PACKAGE_HASH 4b7b5651e47cfd019b6b295cc17bb147b65e53073eaab4a0c0d20a37ab74a246) @@ -18,16 +17,16 @@ ly_associate_package(PACKAGE_NAME expat-2.1.0-multiplatform ly_associate_package(PACKAGE_NAME zstd-1.35-multiplatform TARGETS zstd PACKAGE_HASH 45d466c435f1095898578eedde85acf1fd27190e7ea99aeaa9acfd2f09e12665) ly_associate_package(PACKAGE_NAME SQLite-3.32.2-rev3-multiplatform TARGETS SQLite PACKAGE_HASH dd4d3de6cbb4ce3d15fc504ba0ae0587e515dc89a25228037035fc0aef4831f4) ly_associate_package(PACKAGE_NAME glad-2.0.0-beta-rev2-multiplatform TARGETS glad PACKAGE_HASH ff97ee9664e97d0854b52a3734c2289329d9f2b4cd69478df6d0ca1f1c9392ee) -ly_associate_package(PACKAGE_NAME lux_core-2.2-rev5-multiplatform TARGETS lux_core PACKAGE_HASH c8c13cf7bc351643e1abd294d0841b24dee60e51647dff13db7aec396ad1e0b5) ly_associate_package(PACKAGE_NAME xxhash-0.7.4-rev1-multiplatform TARGETS xxhash PACKAGE_HASH e81f3e6c4065975833996dd1fcffe46c3cf0f9e3a4207ec5f4a1b564ba75861e) # platform-specific: +ly_associate_package(PACKAGE_NAME assimp-5.0.1-rev12-windows TARGETS assimplib PACKAGE_HASH 5273b7661a7a247bb18e8bc928d25c9cd1bd8ce9dfcc56c50742bac8fa02f0f2) ly_associate_package(PACKAGE_NAME AWSGameLiftServerSDK-3.4.1-rev1-windows TARGETS AWSGameLiftServerSDK PACKAGE_HASH a0586b006e4def65cc25f388de17dc475e417dc1e6f9d96749777c88aa8271b0) ly_associate_package(PACKAGE_NAME DirectXShaderCompilerDxc-1.6.2104-o3de-rev3-windows TARGETS DirectXShaderCompilerDxc PACKAGE_HASH 803e10b94006b834cbbdd30f562a8ddf04174c2cb6956c8399ec164ef8418d1f) ly_associate_package(PACKAGE_NAME SPIRVCross-2021.04.29-rev1-windows TARGETS SPIRVCross PACKAGE_HASH 7d601ea9d625b1d509d38bd132a1f433d7e895b16adab76bac6103567a7a6817) ly_associate_package(PACKAGE_NAME tiff-4.2.0.15-rev3-windows TARGETS TIFF PACKAGE_HASH c6000a906e6d2a0816b652e93dfbeab41c9ed73cdd5a613acd53e553d0510b60) ly_associate_package(PACKAGE_NAME freetype-2.10.4.16-windows TARGETS freetype PACKAGE_HASH 9809255f1c59b07875097aa8d8c6c21c97c47a31fb35e30f2bb93188e99a85ff) -ly_associate_package(PACKAGE_NAME AWSNativeSDK-1.7.167-rev4-windows TARGETS AWSNativeSDK PACKAGE_HASH a900e80f7259e43aed5c847afee2599ada37f29db70505481397675bcbb6c76c) +ly_associate_package(PACKAGE_NAME AWSNativeSDK-1.9.50-rev2-windows TARGETS AWSNativeSDK PACKAGE_HASH 047de23fa57d33196666c22f45afc9c628bae354a6c39d774cbeee8054b2eb53) ly_associate_package(PACKAGE_NAME Lua-5.3.5-rev5-windows TARGETS Lua PACKAGE_HASH 136faccf1f73891e3fa3b95f908523187792e56f5b92c63c6a6d7e72d1158d40) ly_associate_package(PACKAGE_NAME PhysX-4.1.2.29882248-rev5-windows TARGETS PhysX PACKAGE_HASH 4e31a3e1f5bf3952d8af8e28d1a29f04167995a6362fc3a7c20c25f74bf01e23) ly_associate_package(PACKAGE_NAME mcpp-2.7.2_az.2-rev1-windows TARGETS mcpp PACKAGE_HASH 794789aba639bfe2f4e8fcb4424d679933dd6290e523084aa0a4e287ac44acb2) diff --git a/cmake/3rdParty/Platform/iOS/BuiltInPackages_ios.cmake b/cmake/3rdParty/Platform/iOS/BuiltInPackages_ios.cmake index 1eea5082da..4b99efc9d0 100644 --- a/cmake/3rdParty/Platform/iOS/BuiltInPackages_ios.cmake +++ b/cmake/3rdParty/Platform/iOS/BuiltInPackages_ios.cmake @@ -14,12 +14,11 @@ ly_associate_package(PACKAGE_NAME cityhash-1.1-multiplatform TARGETS cit ly_associate_package(PACKAGE_NAME expat-2.1.0-multiplatform TARGETS expat PACKAGE_HASH 452256acd1fd699cef24162575b3524fccfb712f5321c83f1df1ce878de5b418) ly_associate_package(PACKAGE_NAME zstd-1.35-multiplatform TARGETS zstd PACKAGE_HASH 45d466c435f1095898578eedde85acf1fd27190e7ea99aeaa9acfd2f09e12665) ly_associate_package(PACKAGE_NAME glad-2.0.0-beta-rev2-multiplatform TARGETS glad PACKAGE_HASH ff97ee9664e97d0854b52a3734c2289329d9f2b4cd69478df6d0ca1f1c9392ee) -ly_associate_package(PACKAGE_NAME lux_core-2.2-rev5-multiplatform TARGETS lux_core PACKAGE_HASH c8c13cf7bc351643e1abd294d0841b24dee60e51647dff13db7aec396ad1e0b5) # platform-specific: ly_associate_package(PACKAGE_NAME tiff-4.2.0.15-rev3-ios TARGETS TIFF PACKAGE_HASH e9067e88649fb6e93a926d9ed38621a9fae360a2e6f6eb24ebca63c1bc7761ea) ly_associate_package(PACKAGE_NAME freetype-2.10.4.16-ios TARGETS freetype PACKAGE_HASH 3ac3c35e056ae4baec2e40caa023d76a7a3320895ef172b6655e9261b0dc2e29) -ly_associate_package(PACKAGE_NAME AWSNativeSDK-1.7.167-rev4-ios TARGETS AWSNativeSDK PACKAGE_HASH d10e7496ca705577032821011beaf9f2507689f23817bfa0ed4d2a2758afcd02) +ly_associate_package(PACKAGE_NAME AWSNativeSDK-1.9.50-rev1-ios TARGETS AWSNativeSDK PACKAGE_HASH c3c9478c259ecb569fb2ce6fcfa733647adc3b6bd2854e8eff9de64bcd18c745) ly_associate_package(PACKAGE_NAME Lua-5.3.5-rev5-ios TARGETS Lua PACKAGE_HASH c2d3c4e67046c293049292317a7d60fdb8f23effeea7136aefaef667163e5ffe) ly_associate_package(PACKAGE_NAME PhysX-4.1.2.29882248-rev5-ios TARGETS PhysX PACKAGE_HASH 4a5e38b385837248590018eb133444b4e440190414e6756191200a10c8fa5615) ly_associate_package(PACKAGE_NAME mikkelsen-1.0.0.4-ios TARGETS mikkelsen PACKAGE_HASH 976aaa3ccd8582346132a10af253822ccc5d5bcc9ea5ba44d27848f65ee88a8a) diff --git a/cmake/3rdPartyPackages.cmake b/cmake/3rdPartyPackages.cmake index a3f15bdb22..f9a72672c0 100644 --- a/cmake/3rdPartyPackages.cmake +++ b/cmake/3rdPartyPackages.cmake @@ -614,7 +614,7 @@ endfunction() # and ensure the path to the package root is added to the find_package search paths. # For example # ly_associate_package(TARGETS zlib PACKAGE_NAME zlib-1.2.8-multiplatform PACKAGE_HASH e6f34b8ac16acf881e3d666ef9fd0c1aee94c3f69283fb6524d35d6f858eebbb) -# - this waill cause it to automatically download and activate this package if it finds a target that +# - this will cause it to automatically download and activate this package if it finds a target that # depends on '3rdParty::zlib' in its runtime or its build time dependency list. # - note that '3rdParty' is implied, do not specify it in the TARGETS list. function(ly_associate_package) @@ -684,6 +684,7 @@ endmacro() # is associated with a package, as above. If it is, it makes sure that the package # is brought into scope (and if necessary, downloaded.) macro(ly_download_associated_package find_library_name) + unset(package_name) ly_get_package_association(${find_library_name} package_name) if (package_name) # it is an associated package. diff --git a/cmake/AzAutoGen.py b/cmake/AzAutoGen.py index 19b9711325..782419a6f2 100755 --- a/cmake/AzAutoGen.py +++ b/cmake/AzAutoGen.py @@ -287,8 +287,7 @@ def ProcessExpansionRule(sourceFiles, templateFiles, templateCache, outputDir, p else: # Process all matches in one batch # Due to the lack of wildcards in the output file, we've determined we'll glob all matching input files into the template conversion - for filename in fnmatch.filter(sourceFiles, inputFiles): - dataInputFiles = [os.path.abspath(file) for file in fnmatch.filter(sourceFiles, inputFiles)] + dataInputFiles = [os.path.abspath(file) for file in fnmatch.filter(sourceFiles, inputFiles)] outputFileAbsolute = outputFile.replace("$path", ComputeOutputPath(dataInputFiles, projectDir, outputDir)) outputFileAbsolute = SanitizePath(outputFileAbsolute) ProcessTemplateConversion(dataInputSet, dataInputFiles, templateFile, outputFileAbsolute, templateCache, dryrun, verbose) diff --git a/cmake/CommandExecution.cmake b/cmake/CommandExecution.cmake index 91f043ee9f..a8c21a22a2 100644 --- a/cmake/CommandExecution.cmake +++ b/cmake/CommandExecution.cmake @@ -38,13 +38,13 @@ endif() # Check for timestamp if(LY_TIMESTAMP_REFERENCE) - if(NOT EXISTS ${LY_TIMESTAMP_REFERENCE}) + if(NOT EXISTS "${LY_TIMESTAMP_REFERENCE}") message(FATAL_ERROR "File LY_TIMESTAMP_REFERENCE=${LY_TIMESTAMP_REFERENCE} does not exists") endif() if(NOT LY_TIMESTAMP_FILE) - set(LY_TIMESTAMP_FILE ${LY_TIMESTAMP_REFERENCE}.stamp) + set(LY_TIMESTAMP_FILE "${LY_TIMESTAMP_REFERENCE}.stamp") endif() - if(EXISTS ${LY_TIMESTAMP_FILE} AND NOT ${LY_TIMESTAMP_REFERENCE} IS_NEWER_THAN ${LY_TIMESTAMP_FILE}) + if(EXISTS "${LY_TIMESTAMP_FILE}" AND NOT "${LY_TIMESTAMP_REFERENCE}" IS_NEWER_THAN "${LY_TIMESTAMP_FILE}") # Stamp newer, nothing to do return() endif() @@ -52,7 +52,7 @@ endif() if(LY_LOCK_FILE) # Lock the file - file(LOCK ${LY_LOCK_FILE} TIMEOUT 1200 RESULT_VARIABLE lock_result) + file(LOCK "${LY_LOCK_FILE}" TIMEOUT 1200 RESULT_VARIABLE lock_result) if(NOT ${lock_result} EQUAL 0) message(FATAL_ERROR "Lock failure ${lock_result}") endif() @@ -83,5 +83,5 @@ endif() if(LY_TIMESTAMP_REFERENCE) # Touch the timestamp file - file(TOUCH ${LY_TIMESTAMP_FILE}) + file(TOUCH "${LY_TIMESTAMP_FILE}") endif() diff --git a/cmake/Configurations.cmake b/cmake/Configurations.cmake index 51dee2f07b..709c81e3d2 100644 --- a/cmake/Configurations.cmake +++ b/cmake/Configurations.cmake @@ -189,5 +189,5 @@ foreach(conf IN LISTS CMAKE_CONFIGURATION_TYPES) endforeach() # flags are defined per platform, follow platform files under Platform//Configurations_.cmake -ly_get_absolute_pal_filename(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/Configurations_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/cmake/FileUtil.cmake b/cmake/FileUtil.cmake index 4607e14452..5721cf452c 100644 --- a/cmake/FileUtil.cmake +++ b/cmake/FileUtil.cmake @@ -26,8 +26,16 @@ function(ly_include_cmake_file_list file) include(${file}) get_filename_component(file_path "${file}" PATH) if(file_path) - list(TRANSFORM FILES PREPEND ${file_path}/) + foreach(f ${FILES}) + cmake_path(IS_RELATIVE f is_relative) + if(is_relative) + string(PREPEND f ${file_path}/) + endif() + list(APPEND TRANSFORMED_FILES ${f}) + endforeach() + set(FILES ${TRANSFORMED_FILES}) endif() + foreach(f ${FILES}) get_filename_component(absolute_path ${f} ABSOLUTE) if(NOT EXISTS ${absolute_path}) @@ -41,12 +49,19 @@ function(ly_include_cmake_file_list file) list(APPEND UNITY_AUTO_EXCLUSIONS ${f}) endif() endif() - endforeach() + list(APPEND FILES ${file}) # Add the _files.cmake to the list so it shows in the IDE if(file_path) - list(TRANSFORM SKIP_UNITY_BUILD_INCLUSION_FILES PREPEND ${file_path}/) + foreach(f ${SKIP_UNITY_BUILD_INCLUSION_FILES}) + cmake_path(IS_RELATIVE f is_relative) + if(is_relative) + string(PREPEND f ${file_path}/) + endif() + list(APPEND SKIP_UNITY_BUILD_INCLUSION_TRANSFORMED_FILES ${f}) + endforeach() + set(SKIP_UNITY_BUILD_INCLUSION_FILES ${SKIP_UNITY_BUILD_INCLUSION_TRANSFORMED_FILES}) endif() # Check if there are any files to exclude from unity groupings diff --git a/cmake/Install.cmake b/cmake/Install.cmake index b558590b9e..55f56b05e8 100644 --- a/cmake/Install.cmake +++ b/cmake/Install.cmake @@ -30,7 +30,7 @@ function(ly_install) install(CODE "endif()\n" ALL_COMPONENTS) else() install(${ARGN}) - endif() + endif() endfunction() @@ -195,6 +195,6 @@ function(ly_install_run_script SCRIPT) endfunction() if(LY_INSTALL_ENABLED) - ly_get_absolute_pal_filename(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME}) + o3de_pal_dir(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/Install_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) endif() diff --git a/cmake/LYTestWrappers.cmake b/cmake/LYTestWrappers.cmake index 03146b6045..9f4cd41a47 100644 --- a/cmake/LYTestWrappers.cmake +++ b/cmake/LYTestWrappers.cmake @@ -141,7 +141,7 @@ function(ly_add_test) set(wrapper_file ${CMAKE_CURRENT_FUNCTION_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}/LYTestWrappers_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) if(NOT EXISTS ${wrapper_file}) - ly_get_absolute_pal_filename(wrapper_file ${wrapper_file}) + o3de_pal_dir(wrapper_file ${wrapper_file} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) endif() include(${wrapper_file}) diff --git a/cmake/LYWrappers.cmake b/cmake/LYWrappers.cmake index d4bf1d7423..a2f4359fd5 100644 --- a/cmake/LYWrappers.cmake +++ b/cmake/LYWrappers.cmake @@ -11,7 +11,7 @@ set(LY_UNITY_BUILD ON CACHE BOOL "UNITY builds") include(CMakeFindDependencyMacro) include(cmake/LyAutoGen.cmake) -ly_get_absolute_pal_filename(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/LYWrappers_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) # Not all platforms support unity builds diff --git a/cmake/PAL.cmake b/cmake/PAL.cmake index 67ed17b6d4..d0d1ad5396 100644 --- a/cmake/PAL.cmake +++ b/cmake/PAL.cmake @@ -15,67 +15,205 @@ # PAL_PLATFORM_NAME_LOWERCASE: name of the platform in lower case (part of filenames) # -file(GLOB detection_files "cmake/Platform/*/PALDetection_*.cmake") -foreach(detection_file ${detection_files}) - include(${detection_file}) -endforeach() +#! o3de_get_home_path: returns the home path +# +# \arg:o3de_manifest_path returns the path of the manifest +function(o3de_get_home_path o3de_home_path) + # The o3de_manifest.json is in the home directory / .o3de folder + file(TO_CMAKE_PATH "$ENV{USERPROFILE}" home_path) # Windows + if(NOT EXISTS ${home_path}) + file(TO_CMAKE_PATH "$ENV{HOME}" home_path) # Unix + if (NOT EXISTS ${home_path}) + message(FATAL_ERROR "o3de Home path not found") + endif() + endif() + set(${o3de_home_path} ${home_path} PARENT_SCOPE) +endfunction() +#! o3de_get_manifest_path: returns the path to the manifest +# +# \arg:o3de_manifest_path returns the path of the manifest +function(o3de_get_manifest_path o3de_manifest_path) + # The o3de_manifest.json is in the home directory / .o3de folder + o3de_get_home_path(o3de_home_path) + set(${o3de_manifest_path} ${o3de_home_path}/.o3de/o3de_manifest.json PARENT_SCOPE) +endfunction() -#! o3de_restricted_id: Reads the "restricted" key from the o3de manifest +#! o3de_read_manifest: returns the contents of the manifest # -# \arg:o3de_json_file name of the o3de json file to read the "restricted_name" key from -# \arg:restricted returns the restricted association element from an o3de json, otherwise engine 'o3de' is assumed -# \arg:o3de_json_file name of the o3de json file -function(o3de_restricted_id o3de_json_file restricted) - ly_file_read(${o3de_json_file} json_data) - string(JSON restricted_entry ERROR_VARIABLE json_error GET ${json_data} "restricted_name") +# \arg:restricted_subdirs returns the restricted elements from the manifest +function(o3de_read_manifest o3de_manifest_json_data) + #get the manifest path + o3de_get_manifest_path(o3de_manifest_path) + if(EXISTS ${o3de_manifest_path}) + ly_file_read(${o3de_manifest_path} json_data) + set(${o3de_manifest_json_data} ${json_data} PARENT_SCOPE) + endif() +endfunction() + +#! o3de_recurse_gems: returns the gem paths +# +# \arg:object json path +# \arg:gems returns the gems from the external subdirectory elements from the manifest +function(o3de_recurse_gems object_json_path gems) + get_filename_component(object_json_parent_path ${object_json_path} DIRECTORY) + ly_file_read(${object_json_path} json_data) + string(JSON external_subdirectories_count ERROR_VARIABLE json_error LENGTH ${json_data} "external_subdirectories") + if(NOT json_error) + if(external_subdirectories_count GREATER 0) + math(EXPR external_subdirectories_range "${external_subdirectories_count}-1") + foreach(external_subdirectories_index RANGE ${external_subdirectories_range}) + string(JSON external_subdirectories_entry ERROR_VARIABLE json_error GET ${json_data} "external_subdirectories" "${external_subdirectories_index}") + cmake_path(IS_RELATIVE external_subdirectories_entry is_relative) + if(${is_relative}) + cmake_path(ABSOLUTE_PATH external_subdirectories_entry BASE_DIRECTORY ${object_json_parent_path} NORMALIZE OUTPUT_VARIABLE external_subdirectories_entry) + endif() + if(EXISTS ${external_subdirectories_entry}/gem.json) + list(APPEND gem_entries ${external_subdirectories_entry}) + o3de_recurse_gems(${external_subdirectories_entry}/gem.json gem_entries) + endif() + endforeach() + endif() + endif() + set(${gems} ${gem_entries} PARENT_SCOPE) +endfunction() + +#! o3de_find_gem: returns the gem path +# +# \arg:gem_name the gem name to find +# \arg:the path of the gem +function(o3de_find_gem gem_name gem_path) + o3de_get_manifest_path(manifest_path) + if(EXISTS ${manifest_path}) + o3de_recurse_gems(${manifest_path} gems) + endif() + o3de_recurse_gems(${LY_ROOT_FOLDER}/engine.json gems) + foreach(gem ${gems}) + ly_file_read(${gem}/gem.json json_data) + string(JSON gem_json_name ERROR_VARIABLE json_error GET ${json_data} "gem_name") + if(gem_json_name STREQUAL gem_name) + set(${gem_path} ${gem} PARENT_SCOPE) + return() + endif() + endforeach() +endfunction() + +#! o3de_manifest_restricted: returns the manifests restricted paths +# +# \arg:restricted returns the restricted elements from the manifest +function(o3de_manifest_restricted restricted) + #read the manifest + o3de_read_manifest(o3de_manifest_json_data) + string(JSON restricted_count ERROR_VARIABLE json_error LENGTH ${o3de_manifest_json_data} "restricted") if(json_error) # Restricted fields can never be a requirement so no warning is issued return() endif() - if(restricted_entry) - set(${restricted} ${restricted_entry} PARENT_SCOPE) + if(restricted_count GREATER 0) + math(EXPR restricted_range "${restricted_count}-1") + foreach(restricted_index RANGE ${restricted_range}) + string(JSON restricted_entry ERROR_VARIABLE json_error GET ${o3de_manifest_json_data} "restricted" "${restricted_index}") + list(APPEND restricted_entries ${restricted_entry}) + endforeach() endif() + set(${restricted} ${restricted_entries} PARENT_SCOPE) endfunction() -#! o3de_find_restricted_folder: +#! o3de_json_restricted: returns the restricted element from a json # -# \arg:restricted_path returns the path of the o3de restricted folder with name restricted_name -# \arg:restricted_name name of the restricted -function(o3de_find_restricted_folder restricted_name restricted_path) - # Read the restricted path from engine.json if one EXISTS - ly_file_read(${LY_ROOT_FOLDER}/engine.json engine_json_data) - string(JSON restricted_subdirs_count ERROR_VARIABLE engine_json_error LENGTH ${engine_json_data} "restricted") - if(restricted_subdirs_count GREATER 0) - string(JSON restricted_subdir ERROR_VARIABLE engine_json_error GET ${engine_json_data} "restricted" "0") - set(${restricted_path} ${restricted_subdir} PARENT_SCOPE) +# \arg:restricted returns the restricted element of the json +function(o3de_json_restricted json_path restricted) + if(EXISTS ${json_path}) + ly_file_read(${json_path} json_data) + string(JSON restricted_entry ERROR_VARIABLE json_error GET ${json_data} "restricted") + if(json_error) + # Restricted fields can never be a requirement so no warning is issued + return() + endif() + set(${restricted} ${restricted_entry} PARENT_SCOPE) + endif() +endfunction() + +#! o3de_restricted_id: determines the restricted object for this json +# +# Find this objects restricted name. If the object has a "restricted" element +# If it does not have one it inherits its parents "restricted" element if it has one +# If the parent does not have one it inherits its parents parent "restricted" element is it has one and so on... +# We stop looking if the object or parent is in the manifest, as the manifest only has top level objects +# which means they have no children. +# +# \arg:o3de_json_file name of the o3de json file to read the "restricted" key from +# \arg:restricted returns the restricted association element from an o3de json, otherwise its doesnt change anything +# \arg:o3de_json_file name of the o3de json file +function(o3de_restricted_id o3de_json_file restricted parent_relative_path) + # read the passed in o3de json and see if "restricted" is set + o3de_json_restricted(${o3de_json_file} restricted_name) + if(restricted_name) + set(${parent_relative_path} "" PARENT_SCOPE) + set(${restricted} ${restricted_name} PARENT_SCOPE) return() endif() + # This object did not have a "restricted" set, now we must look at the parent + # Stop if this is a top level object + o3de_manifest_restricted(manifest_restricted_paths) + get_filename_component(o3de_json_file_parent ${o3de_json_file} DIRECTORY) + get_filename_component(relative_path ${o3de_json_file_parent} NAME) + get_filename_component(o3de_json_file_parent ${o3de_json_file_parent} DIRECTORY) + if(${o3de_json_file_parent} IN_LIST manifest_restricted_paths) + set(${parent_relative_path} "" PARENT_SCOPE) + set(${restricted} "" PARENT_SCOPE) + return() + endif() - file(TO_CMAKE_PATH "$ENV{USERPROFILE}" home_directory) # Windows - if(NOT EXISTS ${home_directory}) - file(TO_CMAKE_PATH "$ENV{HOME}" home_directory) # Unix - if (NOT EXISTS ${home_directory}) - return() + string(LENGTH ${o3de_json_file_parent} parent_len) + while(parent_len) + if(EXISTS ${o3de_json_file_parent}/engine.json) + o3de_json_restricted(${o3de_json_file_parent}/engine.json restricted_name) + if(restricted_name) + set(${parent_relative_path} ${relative_path} PARENT_SCOPE) + set(${restricted} ${restricted_name} PARENT_SCOPE) + return() + endif() + endif() + if(EXISTS ${o3de_json_file_parent}/project.json) + o3de_json_restricted(${o3de_json_file_parent}/project.json restricted_name) + if(restricted_name) + set(${parent_relative_path} ${relative_path} PARENT_SCOPE) + set(${restricted} ${restricted_name} PARENT_SCOPE) + return() + endif() + endif() + if(EXISTS ${o3de_json_file_parent}/gem.json) + o3de_json_restricted(${o3de_json_file_parent}/gem.json restricted_name) + if(restricted_name) + set(${parent_relative_path} ${relative_path} PARENT_SCOPE) + set(${restricted} ${restricted_name} PARENT_SCOPE) + return() + endif() endif() - endif() - # Examine the o3de manifest file for the list of restricted directories - set(o3de_manifest_path ${home_directory}/.o3de/o3de_manifest.json) - if(EXISTS ${o3de_manifest_path}) - ly_file_read(${o3de_manifest_path} o3de_manifest_json_data) - string(JSON restricted_subdirs_count ERROR_VARIABLE engine_json_error LENGTH ${o3de_manifest_json_data} "restricted") - if(restricted_subdirs_count GREATER 0) - math(EXPR restricted_subdirs_range "${restricted_subdirs_count}-1") - foreach(restricted_subdir_index RANGE ${restricted_subdirs_range}) - string(JSON restricted_subdir ERROR_VARIABLE engine_json_error GET ${o3de_manifest_json_data} "restricted" "${restricted_subdir_index}") - list(APPEND restricted_subdirs ${restricted_subdir}) - endforeach() + if(${o3de_json_file_parent} IN_LIST manifest_restricted_paths) + set(${parent_relative_path} "" PARENT_SCOPE) + set(${restricted} "" PARENT_SCOPE) + return() endif() - endif() + + get_filename_component(parent ${o3de_json_file_parent} NAME) + string(PREPEND relative_path ${parent}/) + get_filename_component(o3de_json_file_parent ${o3de_json_file_parent} DIRECTORY) + string(LENGTH ${o3de_json_file_parent} parent_len) + endwhile() +endfunction() + +#! o3de_find_restricted_folder: +# +# \arg:restricted_path returns the path of the o3de restricted folder using the restricted_name +# \arg:restricted_name name of the restricted +function(o3de_find_restricted_folder restricted_name restricted_path) + o3de_manifest_restricted(restricted_entries) # Iterate over the restricted directories from the manifest file - foreach(restricted_entry ${restricted_subdirs}) + foreach(restricted_entry ${restricted_entries}) set(restricted_json_file ${restricted_entry}/restricted.json) ly_file_read(${restricted_json_file} restricted_json) string(JSON this_restricted_name ERROR_VARIABLE json_error GET ${restricted_json} "restricted_name") @@ -95,30 +233,30 @@ endfunction() # # \arg:o3de_json_file json file to read restricted id from # \arg:restricted_name name of the restricted object -function(o3de_restricted_path o3de_json_file restricted_path) - o3de_restricted_id(${o3de_json_file} restricted_name) +function(o3de_restricted_path o3de_json_file restricted_path parent_relative_path) + o3de_restricted_id(${o3de_json_file} restricted_name parent_relative) + set(${parent_relative_path} ${parent_relative} PARENT_SCOPE) if(restricted_name) o3de_find_restricted_folder(${restricted_name} restricted_folder) if(restricted_folder) set(${restricted_path} ${restricted_folder} PARENT_SCOPE) + else() + get_filename_component(o3de_json_file_parent ${o3de_json_file} DIRECTORY) + set(${restricted_path} ${o3de_json_file_parent}/restricted PARENT_SCOPE) endif() endif() endfunction() -#! read_engine_restricted_path: Locates the restricted path within the engine from a json file -# -# \arg:output_restricted_path returns the path of the o3de restricted folder with name restricted_name -function(read_engine_restricted_path output_restricted_path) - # Set manifest path to path in the user home directory - set(manifest_path ${LY_ROOT_FOLDER}/engine.json) - if(EXISTS ${manifest_path}) - o3de_restricted_path(${manifest_path} read_restricted_path) - set(${output_restricted_path} ${read_restricted_path} PARENT_SCOPE) - endif() -endfunction() +# detect open platforms +file(GLOB detection_files "cmake/Platform/*/PALDetection_*.cmake") +foreach(detection_file ${detection_files}) + include(${detection_file}) +endforeach() -read_engine_restricted_path(O3DE_ENGINE_RESTRICTED_PATH) +# set the O3DE_ENGINE_RESTRICTED_PATH +o3de_restricted_path(${LY_ROOT_FOLDER}/engine.json O3DE_ENGINE_RESTRICTED_PATH engine_has_no_parent) +# detect platforms in the restricted path file(GLOB detection_files ${O3DE_ENGINE_RESTRICTED_PATH}/*/cmake/PALDetection_*.cmake) foreach(detection_file ${detection_files}) include(${detection_file}) @@ -146,21 +284,16 @@ foreach(pal_restricted_file ${pal_restricted_files}) string(TOLOWER ${platform} platform_lower) list(APPEND PAL_RESTRICTED_PLATFORMS ${platform_lower}) endforeach() +list(REMOVE_DUPLICATES PAL_RESTRICTED_PLATFORMS) + ly_set(PAL_RESTRICTED_PLATFORMS ${PAL_RESTRICTED_PLATFORMS}) function(ly_get_absolute_pal_filename out_name in_name) - set(full_name ${in_name}) + message(DEPRECATION "ly_get_list_relative_pal_filename is being deprecated, change your code to use o3de_pal_dir instead.") + # parent relative path is optional if(${ARGC} GREATER 4) - # The object name is used to resolve ambiguities when a PAL directory is requested from - # two different external subdirectory root paths - # Such as if a PAL directory for two root object paths with same relative structure was requested to be Palified - # i.e /Platform//IO and /Platform//IO - # Normally the restricted PAL path for both gems would be "//IO". - # The object name can be used to make this path unique - # "///IO" for gem 1 and - # "///IO" for gem 2 - set(object_name ${ARGV4}) + set(parent_relative_path ${ARGV4}) endif() # The Default object path for path is the LY_ROOT_FOLDER @@ -170,14 +303,30 @@ function(ly_get_absolute_pal_filename out_name in_name) cmake_path(SET object_path NORMALIZE ${ARGV3}) endif() - # The Default restricted object path is the result of the read_engine_restricted_path function + # The default restricted object path is O3DE_ENGINE_RESTRICTED_PATH cmake_path(SET object_restricted_path NORMALIZE "${O3DE_ENGINE_RESTRICTED_PATH}") if(${ARGC} GREATER 2) # The user has supplied an object restricted path cmake_path(SET object_restricted_path NORMALIZE ${ARGV2}) endif() - # The input path must exist in order to form a PAL path + if(${ARGC} GREATER 4) + o3de_pal_dir(abs_name ${in_name} ${object_restricted_path} ${object_path} ${parent_relative_path}) + else() + o3de_pal_dir(abs_name ${in_name} ${object_restricted_path} ${object_path}) + endif() + set(${out_name} ${abs_name} PARENT_SCOPE) +endfunction() + +function(o3de_pal_dir out_name in_name object_restricted_path object_path) #parent_relative_path) + set(full_name ${in_name}) + + # parent relative path is optional + if(${ARGC} GREATER 4) + set(parent_relative_path ${ARGV4}) + endif() + + # The input path must not exist in order to form a restricted PAL path if (NOT EXISTS ${full_name}) # if the file is not in the object path then we cannot determine a PAL file for it cmake_path(IS_PREFIX object_path ${full_name} is_input_path_in_root) @@ -222,7 +371,7 @@ function(ly_get_absolute_pal_filename out_name in_name) if(NOT EXISTS ${candidate_PAL_path}) string(TOLOWER ${candidate_platform_name} candidate_platform_name_lower) if("${candidate_platform_name_lower}" IN_LIST PAL_RESTRICTED_PLATFORMS) - cmake_path(APPEND object_restricted_path ${candidate_platform_name} ${object_name} + cmake_path(APPEND object_restricted_path ${candidate_platform_name} ${parent_relative_path} ${pre_platform_paths} OUTPUT_VARIABLE candidate_PAL_path) endif() endif() @@ -236,17 +385,43 @@ function(ly_get_absolute_pal_filename out_name in_name) endfunction() function(ly_get_list_relative_pal_filename out_name in_name) - ly_get_absolute_pal_filename(abs_name ${in_name} ${ARGN}) + message(DEPRECATION "ly_get_list_relative_pal_filename is being deprecated, change your code to use o3de_pal_dir instead.") + + # parent relative path is optional + if(${ARGC} GREATER 4) + set(parent_relative_path ${ARGV4}) + endif() + + # The Default object path for path is the LY_ROOT_FOLDER + cmake_path(SET object_path NORMALIZE "${LY_ROOT_FOLDER}") + if(${ARGC} GREATER 3) + # The user has supplied an object restricted path, the object path for consideration + cmake_path(SET object_path NORMALIZE ${ARGV3}) + endif() + + # The default restricted object path is O3DE_ENGINE_RESTRICTED_PATH + cmake_path(SET object_restricted_path NORMALIZE "${O3DE_ENGINE_RESTRICTED_PATH}") + if(${ARGC} GREATER 2) + # The user has supplied an object restricted path + cmake_path(SET object_restricted_path NORMALIZE ${ARGV2}) + endif() + + if(${ARGC} GREATER 4) + o3de_pal_dir(abs_name ${in_name} ${object_restricted_path} ${object_path} ${parent_relative_path}) + else() + o3de_pal_dir(abs_name ${in_name} ${object_restricted_path} ${object_path}) + endif() + cmake_path(RELATIVE_PATH abs_name BASE_DIRECTORY ${CMAKE_CURRENT_LIST_DIR} OUTPUT_VARIABLE relative_name) set(${out_name} ${relative_name} PARENT_SCOPE) endfunction() -ly_get_absolute_pal_filename(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_cmake_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) -ly_include_cmake_file_list(${pal_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake) +ly_include_cmake_file_list(${pal_cmake_dir}/platform_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake) -include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) -include(${pal_dir}/Toolchain_${PAL_PLATFORM_NAME_LOWERCASE}.cmake OPTIONAL) +include(${pal_cmake_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) +include(${pal_cmake_dir}/Toolchain_${PAL_PLATFORM_NAME_LOWERCASE}.cmake OPTIONAL) set(LY_DISABLE_TEST_MODULES FALSE CACHE BOOL "Option to forcibly disable the inclusion of test targets in the build") diff --git a/cmake/PALTools.cmake b/cmake/PALTools.cmake index 2204abf5ae..88e827f9c2 100644 --- a/cmake/PALTools.cmake +++ b/cmake/PALTools.cmake @@ -35,14 +35,14 @@ ly_set(LY_PAL_TOOLS_DEFINES ${LY_PAL_TOOLS_DEFINES}) # Include files to the CMakeFiles project foreach(enabled_platform ${LY_PAL_TOOLS_ENABLED}) string(TOLOWER ${enabled_platform} enabled_platform_lowercase) - ly_get_absolute_pal_filename(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${enabled_platform}) + o3de_pal_dir(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${enabled_platform}) ly_include_cmake_file_list(${pal_dir}/pal_tools_${enabled_platform_lowercase}_files.cmake) endforeach() function(ly_get_pal_tool_dirs out_list pal_path) set(pal_paths "") foreach(platform ${LY_PAL_TOOLS_ENABLED}) - ly_get_absolute_pal_filename(path ${pal_path}/${platform}) + o3d_pal_dir(path ${pal_path}/${platform} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) list(APPEND pal_paths ${path}) endforeach() set(${out_list} ${pal_paths} PARENT_SCOPE) diff --git a/cmake/Packaging.cmake b/cmake/Packaging.cmake index ecef5261b1..81409369dc 100644 --- a/cmake/Packaging.cmake +++ b/cmake/Packaging.cmake @@ -73,7 +73,7 @@ set(CPACK_PROJECT_CONFIG_FILE ${CPACK_SOURCE_DIR}/PackagingConfig.cmake) set(CPACK_AUTO_GEN_TAG ${LY_INSTALLER_AUTO_GEN_TAG}) # attempt to apply platform specific settings -ly_get_absolute_pal_filename(pal_dir ${CPACK_SOURCE_DIR}/Platform/${PAL_HOST_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CPACK_SOURCE_DIR}/Platform/${PAL_HOST_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/Packaging_${PAL_HOST_PLATFORM_NAME_LOWERCASE}.cmake) # if we get here and the generator hasn't been set, then a non fatal error occurred disabling packaging support diff --git a/cmake/Platform/Android/Toolchain_android.cmake b/cmake/Platform/Android/Toolchain_android.cmake index b5c4a56fd6..75ff4554fd 100644 --- a/cmake/Platform/Android/Toolchain_android.cmake +++ b/cmake/Platform/Android/Toolchain_android.cmake @@ -31,11 +31,10 @@ endif() if(NOT ANDROID_ABI) set(ANDROID_ABI arm64-v8a) endif() -if(NOT ANDROID_ARM_MODE) - set(ANDROID_ARM_MODE arm) -endif() -if(NOT ANDROID_ARM_NEON) - set(ANDROID_ARM_NEON FALSE) + +# Only the 64-bit ANDROID ABIs arm supported +if(NOT ANDROID_ABI MATCHES "^arm64-") + message(FATAL_ERROR "Only the 64-bit ANDROID_ABI's are supported. arm64-v8a can be used if not set") endif() if(NOT ANDROID_NATIVE_API_LEVEL) set(ANDROID_NATIVE_API_LEVEL 21) diff --git a/cmake/Platform/Common/runtime_dependencies_common.cmake.in b/cmake/Platform/Common/runtime_dependencies_common.cmake.in index 8717710a3b..a2c3e26ed0 100644 --- a/cmake/Platform/Common/runtime_dependencies_common.cmake.in +++ b/cmake/Platform/Common/runtime_dependencies_common.cmake.in @@ -13,7 +13,7 @@ function(ly_copy source_file target_directory) cmake_path(APPEND target_file "${target_directory}" "${target_filename}") cmake_path(COMPARE "${source_file}" EQUAL "${target_file}" same_location) if(NOT ${same_location}) - file(LOCK ${target_file}.lock GUARD FUNCTION TIMEOUT 300) + file(LOCK "${target_file}.lock" GUARD FUNCTION TIMEOUT 300) file(SIZE "${source_file}" source_file_size) if(EXISTS "${target_file}") file(SIZE "${target_file}" target_file_size) @@ -24,11 +24,11 @@ function(ly_copy source_file target_directory) message(STATUS "Copying \"${source_file}\" to \"${target_directory}\"...") file(MAKE_DIRECTORY "${full_target_directory}") file(COPY "${source_file}" DESTINATION "${target_directory}" FILE_PERMISSIONS @LY_COPY_PERMISSIONS@ FOLLOW_SYMLINK_CHAIN) - file(TOUCH_NOCREATE ${target_file}) + file(TOUCH_NOCREATE "${target_file}") endif() endif() endfunction() @LY_COPY_COMMANDS@ -file(TOUCH @STAMP_OUTPUT_FILE@) +file(TOUCH "@STAMP_OUTPUT_FILE@") diff --git a/cmake/Platform/Linux/CompilerSettings_linux.cmake b/cmake/Platform/Linux/CompilerSettings_linux.cmake index 9bb629c53b..a1a632e957 100644 --- a/cmake/Platform/Linux/CompilerSettings_linux.cmake +++ b/cmake/Platform/Linux/CompilerSettings_linux.cmake @@ -19,7 +19,7 @@ if(NOT CMAKE_C_COMPILER AND NOT CMAKE_CXX_COMPILER AND NOT "$ENV{CC}" AND NOT "$ file(GLOB clang_versions ${path_search}) if(clang_versions) # Find and pick the highest installed version - list(SORT clang_versions COMPARE NATURAL) + list(SORT clang_versions COMPARE NATURAL ORDER DESCENDING) list(GET clang_versions 0 clang_higher_version_path) string(REGEX MATCH "clang-([0-9.]*)" clang_higher_version ${clang_higher_version_path}) if(CMAKE_MATCH_1) diff --git a/cmake/Platform/Linux/runtime_dependencies_linux.cmake.in b/cmake/Platform/Linux/runtime_dependencies_linux.cmake.in index 16445ef8d9..e5d56d1b56 100644 --- a/cmake/Platform/Linux/runtime_dependencies_linux.cmake.in +++ b/cmake/Platform/Linux/runtime_dependencies_linux.cmake.in @@ -14,7 +14,7 @@ function(ly_copy source_file target_directory) cmake_path(APPEND target_file "${target_directory}" "${target_filename}") cmake_path(COMPARE "${source_file}" EQUAL "${target_file}" same_location) if(NOT ${same_location}) - file(LOCK ${target_file}.lock GUARD FUNCTION TIMEOUT 300) + file(LOCK "${target_file}.lock" GUARD FUNCTION TIMEOUT 300) file(SIZE "${source_file}" source_file_size) if(EXISTS "${target_file}") file(SIZE "${target_file}" target_file_size) @@ -39,4 +39,4 @@ endfunction() @LY_COPY_COMMANDS@ -file(TOUCH @STAMP_OUTPUT_FILE@) +file(TOUCH "@STAMP_OUTPUT_FILE@") diff --git a/cmake/Platform/Mac/InstallUtils_mac.cmake.in b/cmake/Platform/Mac/InstallUtils_mac.cmake.in index 89ce4a59f2..9be6338752 100644 --- a/cmake/Platform/Mac/InstallUtils_mac.cmake.in +++ b/cmake/Platform/Mac/InstallUtils_mac.cmake.in @@ -31,36 +31,36 @@ endfunction() function(fixup_python_framework framework_path) file(REMOVE_RECURSE - ${framework_path}/Versions/Current - ${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/Headers - ${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/lib/Python - ${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/lib/python@LY_PYTHON_VERSION_MAJOR_MINOR@/test - ${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/lib/python@LY_PYTHON_VERSION_MAJOR_MINOR@/site-packages/scipy/io/tests - ${framework_path}/Python - ${framework_path}/Resources - ${framework_path}/Headers + "${framework_path}/Versions/Current" + "${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/Headers" + "${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/lib/Python" + "${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/lib/python@LY_PYTHON_VERSION_MAJOR_MINOR@/test" + "${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/lib/python@LY_PYTHON_VERSION_MAJOR_MINOR@/site-packages/scipy/io/tests" + "${framework_path}/Python" + "${framework_path}/Resources" + "${framework_path}/Headers" ) file(GLOB_RECURSE exe_file_list "${framework_path}/**/*.exe") if(exe_file_list) file(REMOVE_RECURSE ${exe_file_list}) endif() - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink include/python@LY_PYTHON_VERSION_MAJOR_MINOR@m Headers - WORKING_DIRECTORY ${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@ + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink include/python@LY_PYTHON_VERSION_MAJOR_MINOR@m Headers + WORKING_DIRECTORY "${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@" ) - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink @LY_PYTHON_VERSION_MAJOR_MINOR@ Current - WORKING_DIRECTORY ${framework_path}/Versions/ + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink @LY_PYTHON_VERSION_MAJOR_MINOR@ Current + WORKING_DIRECTORY "${framework_path}/Versions/" ) - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink Versions/Current/Python Python - WORKING_DIRECTORY ${framework_path} + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink Versions/Current/Python Python + WORKING_DIRECTORY "${framework_path}" ) - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink Versions/Current/Headers Headers - WORKING_DIRECTORY ${framework_path} + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink Versions/Current/Headers Headers + WORKING_DIRECTORY "${framework_path}" ) - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink Versions/Current/Resources Resources - WORKING_DIRECTORY ${framework_path} + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink Versions/Current/Resources Resources + WORKING_DIRECTORY "${framework_path}" ) - file(CHMOD ${framework_path}/Versions/Current/Python + file(CHMOD "${framework_path}/Versions/Current/Python" PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_WRITE GROUP_EXECUTE WORLD_READ WORLD_EXECUTE ) @@ -72,7 +72,7 @@ function(codesign_file file entitlement_file) return() endif() - if(EXISTS ${entitlement_file}) + if(EXISTS "${entitlement_file}") execute_process(COMMAND "/usr/bin/codesign" "--force" "--sign" "@LY_CODE_SIGN_IDENTITY@" "--deep" "-o" "runtime" "--timestamp" "--entitlements" "${entitlement_file}" "${file}" TIMEOUT 300 @@ -108,8 +108,8 @@ function(codesign_python_framework_binaries framework_path) "${framework_path}/Versions/@LY_PYTHON_VERSION_MAJOR_MINOR@/Resources/**") foreach(file ${files}) - if(NOT EXISTS ${file}) - file(REMOVE ${file}) + if(NOT EXISTS "${file}") + file(REMOVE "${file}") continue() endif() cmake_path(SET path_var "${file}") @@ -164,16 +164,16 @@ function(ly_copy source_file target_directory) endfunction() function(ly_download_and_codesign_sdk_python) - execute_process(COMMAND ${CMAKE_COMMAND} -DPAL_PLATFORM_NAME=Mac -DLY_3RDPARTY_PATH=${CMAKE_INSTALL_PREFIX}/python -P ${CMAKE_INSTALL_PREFIX}/python/get_python.cmake - WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX} + execute_process(COMMAND "${CMAKE_COMMAND}" -DPAL_PLATFORM_NAME=Mac "-DLY_3RDPARTY_PATH=${CMAKE_INSTALL_PREFIX}/python" -P "${CMAKE_INSTALL_PREFIX}/python/get_python.cmake" + WORKING_DIRECTORY "${CMAKE_INSTALL_PREFIX}" ) - fixup_python_framework(${CMAKE_INSTALL_PREFIX}/python/runtime/@LY_PYTHON_PACKAGE_NAME@/Python.framework) - codesign_python_framework_binaries(${CMAKE_INSTALL_PREFIX}/python/runtime/@LY_PYTHON_PACKAGE_NAME@/Python.framework) - codesign_file(${CMAKE_INSTALL_PREFIX}/python/runtime/@LY_PYTHON_PACKAGE_NAME@/Python.framework @LY_ROOT_FOLDER@/python/Platform/Mac/PythonEntitlements.plist) + fixup_python_framework("${CMAKE_INSTALL_PREFIX}/python/runtime/@LY_PYTHON_PACKAGE_NAME@/Python.framework") + codesign_python_framework_binaries("${CMAKE_INSTALL_PREFIX}/python/runtime/@LY_PYTHON_PACKAGE_NAME@/Python.framework") + codesign_file("${CMAKE_INSTALL_PREFIX}/python/runtime/@LY_PYTHON_PACKAGE_NAME@/Python.framework" "@LY_ROOT_FOLDER@/python/Platform/Mac/PythonEntitlements.plist") endfunction() function(ly_codesign_sdk) - codesign_file(${LY_INSTALL_PATH_ORIGINAL}/O3DE_SDK.app "none") + codesign_file("${LY_INSTALL_PATH_ORIGINAL}/O3DE_SDK.app" "none") endfunction() diff --git a/cmake/Platform/Mac/runtime_dependencies_mac.cmake.in b/cmake/Platform/Mac/runtime_dependencies_mac.cmake.in index 892a90640f..fff816cb3e 100644 --- a/cmake/Platform/Mac/runtime_dependencies_mac.cmake.in +++ b/cmake/Platform/Mac/runtime_dependencies_mac.cmake.in @@ -127,7 +127,7 @@ function(ly_copy source_file target_directory) if(NOT is_framework) # if it is a bundle, there is no contention about the files in the destination, each bundle target will copy everything # we dont want these files to invalidate the bundle and cause a new signature - file(LOCK ${target_file}.lock GUARD FUNCTION TIMEOUT 300) + file(LOCK "${target_file}.lock" GUARD FUNCTION TIMEOUT 300) file(SIZE "${source_file}" source_file_size) if(EXISTS "${target_file}") file(SIZE "${target_file}" target_file_size) @@ -176,35 +176,35 @@ if(@target_file_dir@ MATCHES ".app/Contents/MacOS") message(STATUS "Fixing ${bundle_path}/Contents/Frameworks/Python.framework...") list(APPEND fixup_bundle_ignore Python python3.7m python3.7) file(REMOVE_RECURSE - ${bundle_path}/Contents/Frameworks/Python.framework/Versions/Current - ${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7/Headers - ${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7/lib/Python - ${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7/lib/python3.7/test - ${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/scipy/io/tests - ${bundle_path}/Contents/Frameworks/Python.framework/Python - ${bundle_path}/Contents/Frameworks/Python.framework/Resources - ${bundle_path}/Contents/Frameworks/Python.framework/Headers + "${bundle_path}/Contents/Frameworks/Python.framework/Versions/Current" + "${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7/Headers" + "${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7/lib/Python" + "${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7/lib/python3.7/test" + "${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/scipy/io/tests" + "${bundle_path}/Contents/Frameworks/Python.framework/Python" + "${bundle_path}/Contents/Frameworks/Python.framework/Resources" + "${bundle_path}/Contents/Frameworks/Python.framework/Headers" ) file(GLOB_RECURSE exe_file_list "${bundle_path}/Contents/Frameworks/Python.framework/**/*.exe") if(exe_file_list) file(REMOVE_RECURSE ${exe_file_list}) endif() - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink include/python3.7m Headers - WORKING_DIRECTORY ${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7 + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink include/python3.7m Headers + WORKING_DIRECTORY "${bundle_path}/Contents/Frameworks/Python.framework/Versions/3.7" ) - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink 3.7 Current - WORKING_DIRECTORY ${bundle_path}/Contents/Frameworks/Python.framework/Versions/ + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink 3.7 Current + WORKING_DIRECTORY "${bundle_path}/Contents/Frameworks/Python.framework/Versions/" ) - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink Versions/Current/Python Python - WORKING_DIRECTORY ${bundle_path}/Contents/Frameworks/Python.framework + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink Versions/Current/Python Python + WORKING_DIRECTORY "${bundle_path}/Contents/Frameworks/Python.framework" ) - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink Versions/Current/Headers Headers - WORKING_DIRECTORY ${bundle_path}/Contents/Frameworks/Python.framework + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink Versions/Current/Headers Headers + WORKING_DIRECTORY "${bundle_path}/Contents/Frameworks/Python.framework" ) - execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink Versions/Current/Resources Resources - WORKING_DIRECTORY ${bundle_path}/Contents/Frameworks/Python.framework + execute_process(COMMAND "${CMAKE_COMMAND}" -E create_symlink Versions/Current/Resources Resources + WORKING_DIRECTORY "${bundle_path}/Contents/Frameworks/Python.framework" ) - file(CHMOD ${bundle_path}/Contents/Frameworks/Python.framework/Versions/Current/Python + file(CHMOD "${bundle_path}/Contents/Frameworks/Python.framework/Versions/Current/Python" PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_WRITE GROUP_EXECUTE WORLD_READ WORLD_EXECUTE ) endif() @@ -215,8 +215,8 @@ if(@target_file_dir@ MATCHES ".app/Contents/MacOS") file(TOUCH "${fixup_timestamp_file}") # fixup bundle ends up removing the rpath of dxc (despite we exclude it) - if(EXISTS ${bundle_path}/Contents/MacOS/Builders/DirectXShaderCompiler/bin/dxc-3.7) - execute_process(COMMAND ${LY_INSTALL_NAME_TOOL} -add_rpath @executable_path/../lib ${bundle_path}/Contents/MacOS/Builders/DirectXShaderCompiler/bin/dxc-3.7) + if(EXISTS "${bundle_path}/Contents/MacOS/Builders/DirectXShaderCompiler/bin/dxc-3.7") + execute_process(COMMAND "${LY_INSTALL_NAME_TOOL}" -add_rpath @executable_path/../lib ${bundle_path}/Contents/MacOS/Builders/DirectXShaderCompiler/bin/dxc-3.7) endif() # misplaced .DS_Store files can cause signing to fail @@ -226,7 +226,7 @@ if(@target_file_dir@ MATCHES ".app/Contents/MacOS") "${bundle_path/}**/*.cstemp" ) if(remove_file_list) - file(REMOVE_RECURSE ${remove_file_list}) + file(REMOVE_RECURSE "${remove_file_list}") endif() endif() @@ -235,7 +235,7 @@ else() # Non-bundle case if(depends_on_python) # RPATH fix python - execute_process(COMMAND ${LY_INSTALL_NAME_TOOL} -change @rpath/Python @rpath/Python.framework/Versions/Current/Python @target_file@) + execute_process(COMMAND "${LY_INSTALL_NAME_TOOL}" -change @rpath/Python @rpath/Python.framework/Versions/Current/Python "@target_file@") endif() endif() diff --git a/cmake/Projects.cmake b/cmake/Projects.cmake index 13161c9e0f..c6aa6c382a 100644 --- a/cmake/Projects.cmake +++ b/cmake/Projects.cmake @@ -118,17 +118,27 @@ function(ly_generate_project_build_path_setreg project_real_path) file(GENERATE OUTPUT ${project_user_build_path_setreg_file} CONTENT ${project_build_path_setreg_content}) endfunction() +function(add_gem_json_external_subdirectories gem_path) + set(gem_json_path ${gem_path}/gem.json) + if(EXISTS ${gem_json_path}) + read_json_external_subdirs(gem_external_subdirs ${gem_path}/gem.json) + foreach(gem_external_subdir ${gem_external_subdirs}) + file(REAL_PATH ${gem_external_subdir} real_external_subdir BASE_DIRECTORY ${gem_path}) + set_property(GLOBAL APPEND PROPERTY LY_EXTERNAL_SUBDIRS ${real_external_subdir}) + add_gem_json_external_subdirectories(${real_external_subdir}) + endforeach() + endif() +endfunction() function(add_project_json_external_subdirectories project_path) set(project_json_path ${project_path}/project.json) if(EXISTS ${project_json_path}) - read_json_external_subdirs(external_subdirs ${project_path}/project.json) - foreach(external_subdir ${external_subdirs}) - file(REAL_PATH ${external_subdir} real_external_subdir BASE_DIRECTORY ${project_path}) - list(APPEND project_external_subdirs ${real_external_subdir}) + read_json_external_subdirs(project_external_subdirs ${project_path}/project.json) + foreach(project_external_subdir ${project_external_subdirs}) + file(REAL_PATH ${project_external_subdir} real_external_subdir BASE_DIRECTORY ${project_path}) + set_property(GLOBAL APPEND PROPERTY LY_EXTERNAL_SUBDIRS ${real_external_subdir}) + add_gem_json_external_subdirectories(${real_external_subdir}) endforeach() - - set_property(GLOBAL APPEND PROPERTY LY_EXTERNAL_SUBDIRS ${project_external_subdirs}) endif() endfunction() diff --git a/cmake/RuntimeDependencies.cmake b/cmake/RuntimeDependencies.cmake index 9cc7315b08..d36789791f 100644 --- a/cmake/RuntimeDependencies.cmake +++ b/cmake/RuntimeDependencies.cmake @@ -6,6 +6,6 @@ # # -ly_get_absolute_pal_filename(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/RuntimeDependencies_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) diff --git a/cmake/Tools/Platform/Android/android_support.py b/cmake/Tools/Platform/Android/android_support.py index f52cc2736c..657ef3b3e4 100755 --- a/cmake/Tools/Platform/Android/android_support.py +++ b/cmake/Tools/Platform/Android/android_support.py @@ -471,7 +471,8 @@ class AndroidProjectGenerator(object): def __init__(self, engine_root, build_dir, android_sdk_path, build_tool, android_sdk_platform, android_native_api_level, android_ndk, project_path, third_party_path, cmake_version, override_cmake_path, override_gradle_path, gradle_version, gradle_plugin_version, - override_ninja_path, include_assets_in_apk, asset_mode, asset_type, signing_config, native_build_path, vulkan_validation_path, is_test_project=False, + override_ninja_path, include_assets_in_apk, asset_mode, asset_type, signing_config, native_build_path, vulkan_validation_path, + extra_cmake_configure_args, is_test_project=False, overwrite_existing=True, unity_build_enabled=False): """ Initialize the object with all the required parameters needed to create an Android Project. The parameters should be verified before initializing this object @@ -497,6 +498,7 @@ class AndroidProjectGenerator(object): :param signing_config: Optional signing configuration arguments :param native_build_path: Override the native build staging path in gradle :param vulkan_validation_path: Override the path to where the Vulkan Validation Layers libraries are (required when using NDK r23+) + :param extra_cmake_configure_args Additional arguments to supply cmake when configuring a project :param is_test_project: Flag to indicate if this is a unit test runner project. (If true, project_path, asset_mode, asset_type, and include_assets_in_apk are ignored) :param overwrite_existing: Flag to overwrite existing project files when being generated, or skip if they already exist. """ @@ -539,6 +541,8 @@ class AndroidProjectGenerator(object): self.vulkan_validation_path = vulkan_validation_path + self.extra_cmake_configure_args = extra_cmake_configure_args + self.asset_mode = asset_mode self.asset_type = asset_type @@ -844,6 +848,9 @@ class AndroidProjectGenerator(object): if self.override_ninja_path: cmake_argument_list.append(f'"-DCMAKE_MAKE_PROGRAM={common.normalize_path_for_settings(self.override_ninja_path)}"') + if self.extra_cmake_configure_args: + cmake_argument_list.extend(map(json.dumps, self.extra_cmake_configure_args)) + # Query the project_path from the project.json file project_name = common.read_project_name_from_project_json(self.project_path) # Prepare the config-specific section to place the cmake argument list in the build.gradle for the app diff --git a/cmake/Tools/Platform/Android/generate_android_project.py b/cmake/Tools/Platform/Android/generate_android_project.py index fe0d787d38..5e414e7738 100755 --- a/cmake/Tools/Platform/Android/generate_android_project.py +++ b/cmake/Tools/Platform/Android/generate_android_project.py @@ -227,6 +227,9 @@ def main(args): help='Override path to where the Vulkan Validation Layers libraries are. Required for use with NDK r23+', default=None, required=False) + parser.add_argument('--extra-cmake-configure-args', + help='Extra arguments to supply to the cmake configure step', + nargs='*') # Asset Options parser.add_argument(INCLUDE_APK_ASSETS_ARGUMENT_NAME, @@ -415,7 +418,8 @@ def main(args): overwrite_existing=parsed_args.overwrite_existing, unity_build_enabled=parsed_args.enable_unity_build, native_build_path=parsed_args.native_build_path, - vulkan_validation_path=parsed_args.vulkan_validation_path) + vulkan_validation_path=parsed_args.vulkan_validation_path, + extra_cmake_configure_args=parsed_args.extra_cmake_configure_args) generator.execute() diff --git a/engine.json b/engine.json index 737ac24fea..51b6738001 100644 --- a/engine.json +++ b/engine.json @@ -1,6 +1,6 @@ { "engine_name": "o3de", - "restricted_name": "o3de", + "restricted": "o3de", "FileVersion": 1, "O3DEVersion": "0.0.0.0", "O3DECopyrightYear": 2021, diff --git a/python/python.cmd b/python/python.cmd index 70c79e6789..28138fd699 100644 --- a/python/python.cmd +++ b/python/python.cmd @@ -21,7 +21,8 @@ SET PYTHONHOME=%CMD_DIR%\runtime\python-3.7.10-rev2-windows\python IF EXIST "%PYTHONHOME%" GOTO PYTHONHOME_EXISTS -ECHO Could not find Python for Windows in %CMD_DIR%\.. +ECHO Python not found in %CMD_DIR% +ECHO Try running %CMD_DIR%\get_python.bat first. exit /B 1 :PYTHONHOME_EXISTS diff --git a/scripts/build/Jenkins/Jenkinsfile b/scripts/build/Jenkins/Jenkinsfile index 9e013fd816..51f89d7829 100644 --- a/scripts/build/Jenkins/Jenkinsfile +++ b/scripts/build/Jenkins/Jenkinsfile @@ -38,14 +38,17 @@ def pipelineParameters = [ booleanParam(defaultValue: false, description: 'Recreates the volume used for the workspace. The volume will be created out of a snapshot taken from main.', name: 'RECREATE_VOLUME') ] -def palSh(cmd, lbl = '', winSlashReplacement = true) { +def palSh(cmd, lbl = '', winSlashReplacement = true, winCharReplacement = true) { if (env.IS_UNIX) { sh label: lbl, script: cmd - } else if (winSlashReplacement) { - bat label: lbl, - script: cmd.replace('/','\\') } else { + if (winSlashReplacement) { + cmd = cmd.replace('/','\\') + } + if (winCharReplacement) { + cmd = cmd.replace('%', '%%') + } bat label: lbl, script: cmd } @@ -261,7 +264,7 @@ def CheckoutRepo(boolean disableSubmodules = false) { commitDateFmt = '%%cI' if (env.IS_UNIX) commitDateFmt = '%cI' - palSh("git show -s --format=${commitDateFmt} ${env.CHANGE_ID} > commitdate", 'Getting commit date') + palSh("git show -s --format=${commitDateFmt} ${env.CHANGE_ID} > commitdate", 'Getting commit date', winSlashReplacement=true, winCharReplacement=false) env.CHANGE_DATE = readFile file: 'commitdate' env.CHANGE_DATE = env.CHANGE_DATE.trim() palRm('commitdate') @@ -610,7 +613,7 @@ def CreateSingleNode(Map pipelineConfig, def platform, def build_job, Map envVar CreateUploadAPLogsStage(platform.key, build_job_name, envVars['WORKSPACE'], platform.value.build_types[build_job_name].PARAMETERS).call() } // Upload test artifacts only on builds that failed and ran test suites - if (env.IS_UPLOAD_TEST_ARTIFACTS?.toBoolean() && params.containsKey('CMAKE_TARGET') && params.CMAKE_TARGET.contains("TEST_SUITE")) { + if (env.IS_UPLOAD_TEST_ARTIFACTS?.toBoolean() && params.containsKey('CTEST_OPTIONS')) { CreateUploadTestArtifactStage(build_job_name, envVars['WORKSPACE'], params.OUTPUT_DIRECTORY).call() } // All other errors will be raised outside the retry block diff --git a/scripts/build/Platform/Android/build_config.json b/scripts/build/Platform/Android/build_config.json index 06fa1ffb5f..c505d8e940 100644 --- a/scripts/build/Platform/Android/build_config.json +++ b/scripts/build/Platform/Android/build_config.json @@ -35,22 +35,12 @@ "PARAMETERS": { "CONFIGURATION":"debug", "OUTPUT_DIRECTORY":"build\\android", - "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_ABI=arm64-v8a -DANDROID_ARM_MODE=arm -DANDROID_ARM_NEON=FALSE -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\"", + "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\"", "CMAKE_LY_PROJECTS":"AutomatedTesting", "CMAKE_TARGET":"all", "CMAKE_BUILD_ARGS":"-j!NUMBER_OF_PROCESSORS!" } }, - "android_packaging_all": { - "TAGS": [ - "packaging" - ], - "COMMAND": "../Windows/python_windows.cmd", - "PARAMETERS": { - "SCRIPT_PATH": "scripts/build/package/package.py", - "SCRIPT_PARAMETERS": "--platform Android --type all" - } - }, "profile": { "TAGS":[ "weekly-build-metrics", @@ -60,7 +50,7 @@ "PARAMETERS": { "CONFIGURATION":"profile", "OUTPUT_DIRECTORY":"build\\android", - "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_ABI=arm64-v8a -DANDROID_ARM_MODE=arm -DANDROID_ARM_NEON=FALSE -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\"", + "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\"", "CMAKE_LY_PROJECTS":"AutomatedTesting", "CMAKE_TARGET":"all", "CMAKE_BUILD_ARGS":"-j!NUMBER_OF_PROCESSORS!" @@ -76,7 +66,7 @@ "PARAMETERS": { "CONFIGURATION":"profile", "OUTPUT_DIRECTORY":"build\\android", - "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_ABI=arm64-v8a -DANDROID_ARM_MODE=arm -DANDROID_ARM_NEON=FALSE -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\" -DLY_UNITY_BUILD=FALSE", + "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\" -DLY_UNITY_BUILD=FALSE", "CMAKE_LY_PROJECTS":"AutomatedTesting", "CMAKE_TARGET":"all", "CMAKE_BUILD_ARGS":"-j!NUMBER_OF_PROCESSORS!" @@ -112,7 +102,7 @@ "PARAMETERS": { "CONFIGURATION":"release", "OUTPUT_DIRECTORY":"build\\android", - "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_ABI=arm64-v8a -DANDROID_ARM_MODE=arm -DANDROID_ARM_NEON=FALSE -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\"", + "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\"", "CMAKE_LY_PROJECTS":"AutomatedTesting", "CMAKE_TARGET":"all", "CMAKE_BUILD_ARGS":"-j!NUMBER_OF_PROCESSORS!" @@ -128,7 +118,7 @@ "PARAMETERS": { "CONFIGURATION":"release", "OUTPUT_DIRECTORY":"build\\mono_android", - "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_ABI=arm64-v8a -DANDROID_ARM_MODE=arm -DANDROID_ARM_NEON=FALSE -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\" -DLY_MONOLITHIC_GAME=TRUE", + "CMAKE_OPTIONS":"-G \"Ninja Multi-Config\" -DCMAKE_TOOLCHAIN_FILE=cmake\\Platform\\Android\\Toolchain_android.cmake -DANDROID_NATIVE_API_LEVEL=21 -DLY_NDK_DIR=\"!LY_NDK_DIR!\" -DLY_MONOLITHIC_GAME=TRUE", "CMAKE_LY_PROJECTS":"AutomatedTesting", "CMAKE_TARGET":"all", "CMAKE_BUILD_ARGS":"-j!NUMBER_OF_PROCESSORS!" diff --git a/scripts/build/Platform/Android/pipeline.json b/scripts/build/Platform/Android/pipeline.json index 230d5d3477..f0292f4501 100644 --- a/scripts/build/Platform/Android/pipeline.json +++ b/scripts/build/Platform/Android/pipeline.json @@ -12,9 +12,6 @@ "daily-pipeline-metrics": { "CLEAN_WORKSPACE": true }, - "packaging": { - "CLEAN_WORKSPACE": true - }, "nightly-clean": { "CLEAN_WORKSPACE": true } diff --git a/scripts/build/Platform/Linux/build_config.json b/scripts/build/Platform/Linux/build_config.json index 5290a32f6d..988cf23703 100644 --- a/scripts/build/Platform/Linux/build_config.json +++ b/scripts/build/Platform/Linux/build_config.json @@ -132,6 +132,35 @@ "ASSET_PROCESSOR_PLATFORMS": "linux,server" } }, + "awsi_test_profile_pipe": { + "TAGS": [ + "nightly-incremental", + "nightly-clean" + ], + "steps": [ + "awsi_deployment", + "awsi_test_profile", + "awsi_destruction" + ] + }, + "awsi_test_profile": { + "TAGS": [ + "weekly-build-metrics" + ], + "PIPELINE_ENV": { + "NONBLOCKING_STEP": "True" + }, + "COMMAND": "build_test_linux.sh", + "PARAMETERS": { + "CONFIGURATION": "profile", + "OUTPUT_DIRECTORY": "build\\linux", + "CMAKE_OPTIONS": "-G 'Ninja Multi-Config' -DLY_PARALLEL_LINK_JOBS=4", + "CMAKE_LY_PROJECTS": "AutomatedTesting", + "CMAKE_TARGET": "TEST_SUITE_awsi", + "CTEST_OPTIONS": "-L \"(SUITE_awsi)\" --no-tests=error", + "TEST_RESULTS": "True" + } + }, "periodic_test_profile": { "TAGS": [ "nightly-incremental", @@ -275,5 +304,25 @@ "CMAKE_OPTIONS": "-G 'Ninja Multi-Config' -DLY_PARALLEL_LINK_JOBS=4 -DCMAKE_MODULE_PATH=${WORKSPACE}/o3de/install/cmake", "CMAKE_TARGET": "all" } + }, + "awsi_deployment": { + "TAGS": [], + "PIPELINE_ENV": { + "NONBLOCKING_STEP": "True" + }, + "COMMAND": "deploy_cdk_applications.sh", + "PARAMETERS": { + "NVM_VERSION": "v0.39.1" + } + }, + "awsi_destruction": { + "TAGS": [], + "PIPELINE_ENV": { + "NONBLOCKING_STEP": "True" + }, + "COMMAND": "destroy_cdk_applications.sh", + "PARAMETERS": { + "NVM_VERSION": "v0.39.1" + } } } diff --git a/scripts/build/Platform/Linux/build_linux.sh b/scripts/build/Platform/Linux/build_linux.sh index 2f33827c5b..ce84ec1749 100755 --- a/scripts/build/Platform/Linux/build_linux.sh +++ b/scripts/build/Platform/Linux/build_linux.sh @@ -17,7 +17,7 @@ SOURCE_DIRECTORY=${PWD} pushd $OUTPUT_DIRECTORY LAST_CONFIGURE_CMD_FILE=ci_last_configure_cmd.txt -CONFIGURE_CMD="cmake ${SOURCE_DIRECTORY} ${CMAKE_OPTIONS} ${EXTRA_CMAKE_OPTIONS}" +CONFIGURE_CMD="cmake '${SOURCE_DIRECTORY}' ${CMAKE_OPTIONS} ${EXTRA_CMAKE_OPTIONS}" if [[ -n "$CMAKE_LY_PROJECTS" ]]; then CONFIGURE_CMD="${CONFIGURE_CMD} -DLY_PROJECTS='${CMAKE_LY_PROJECTS}'" fi diff --git a/scripts/build/Platform/Linux/deploy_cdk_applications.sh b/scripts/build/Platform/Linux/deploy_cdk_applications.sh new file mode 100755 index 0000000000..9a0a31397e --- /dev/null +++ b/scripts/build/Platform/Linux/deploy_cdk_applications.sh @@ -0,0 +1,111 @@ +#!/bin/bash + +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# + +# Deploy the CDK applications for AWS gems (Linux only) + +SOURCE_DIRECTORY=$(dirname "$0") +PATH=$SOURCE_DIRECTORY/python:$PATH +GEM_DIRECTORY=$SOURCE_DIRECTORY/Gems + +DeployCDKApplication() +{ + # Deploy the CDK application for a specific AWS gem + GEM_NAME=$1 + ADDITIONAL_ARGUMENTS=$2 + echo [cdk_deployment] Deploy the CDK application for the $GEM_NAME gem + pushd $GEM_DIRECTORY/$GEM_NAME/cdk + + # Revert the CDK application code to a stable state using the provided commit ID + if ! git checkout $COMMIT_ID -- .; + then + echo [git_checkout] Failed to checkout the CDK application for the $GEM_NAME gem using commit ID $COMMIT_ID + popd + exit 1 + fi + + # Install required packages for the CDK application + if ! python -m pip install -r requirements.txt; + then + echo [cdk_deployment] Failed to install required packages for the $GEM_NAME gem + popd + exit 1 + fi + + # Deploy the CDK application + if ! cdk deploy $ADDITIONAL_ARGUMENTS --require-approval never; + then + echo [cdk_deployment] Failed to deploy the CDK application for the $GEM_NAME gem + popd + exit 1 + fi + popd +} + +# Create and activate a virtualenv for the CDK deployment +if ! python/python.sh -m venv .env; +then + echo [cdk_bootstrap] Failed to create a virtualenv for the CDK deployment + exit 1 +fi +if ! source .env/bin/activate; +then + echo [cdk_bootstrap] Failed to activate the virtualenv for the CDK deployment + exit 1 +fi + +echo [cdk_installation] Install nvm $NVM_VERSION +curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/$NVM_VERSION/install.sh | bash +export NVM_DIR="$HOME/.nvm" +[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm +[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion +echo [cdk_installation] Install the current version of nodejs +nvm install node + +echo [cdk_installation] Install the latest version of CDK +if ! npm uninstall -g aws-cdk; +then + echo [cdk_bootstrap] Failed to uninstall the current version of CDK + exit 1 +fi +if ! npm install -g aws-cdk@latest; +then + echo [cdk_bootstrap] Failed to install the latest version of CDK + exit 1 +fi + +# Set temporary AWS credentials from the assume role +credentials=$(aws sts assume-role --query Credentials.[SecretAccessKey,SessionToken,AccessKeyId] --output text --role-arn $ASSUME_ROLE_ARN --role-session-name o3de-Automation-session) +AWS_SECRET_ACCESS_KEY=$(echo "$credentials" | cut -d' ' -f1) +AWS_SESSION_TOKEN=$(echo "$credentials" | cut -d' ' -f2) +AWS_ACCESS_KEY_ID=$(echo "$credentials" | cut -d' ' -f3) + +O3DE_AWS_DEPLOY_ACCOUNT=$(echo "$ASSUME_ROLE_ARN" | cut -d':' -f5) + +# Bootstrap and deploy the CDK applications +echo [cdk_bootstrap] Bootstrap CDK +if ! cdk bootstrap aws://$O3DE_AWS_DEPLOY_ACCOUNT/$O3DE_AWS_DEPLOY_REGION; +then + echo [cdk_bootstrap] Failed to bootstrap CDK + exit 1 +fi + +if ! DeployCDKApplication AWSCore "-c disable_access_log=true -c remove_all_storage_on_destroy=true --all"; +then + exit 1 +fi +if ! DeployCDKApplication AWSClientAuth; +then + exit 1 +fi +if ! DeployCDKApplication AWSMetrics "-c batch_processing=true"; +then + exit 1 +fi + +exit 0 + diff --git a/scripts/build/Platform/Linux/destroy_cdk_applications.sh b/scripts/build/Platform/Linux/destroy_cdk_applications.sh new file mode 100755 index 0000000000..54f84911a6 --- /dev/null +++ b/scripts/build/Platform/Linux/destroy_cdk_applications.sh @@ -0,0 +1,104 @@ +#!/bin/bash + +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# + +# Deploy the CDK applications for AWS gems (Linux only) +# Prerequisites: +# 1) Node.js is installed +# 2) Node.js version >= 10.13.0, except for versions 13.0.0 - 13.6.0. A version in active long-term support is recommended. + +SOURCE_DIRECTORY=$(dirname "$0") +PATH=$SOURCE_DIRECTORY/python:$PATH +GEM_DIRECTORY=$SOURCE_DIRECTORY/Gems + +DestroyCDKApplication() +{ +# Destroy the CDK application for a specific AWS gem +GEM_NAME=$1 +echo [cdk_destruction] Destroy the CDK application for the $GEM_NAME gem +pushd $GEM_DIRECTORY/$GEM_NAME/cdk + +# Revert the CDK application code to a stable state using the provided commit ID +if ! git checkout $COMMIT_ID -- .; +then + echo [git_checkout] Failed to checkout the CDK application for the $GEM_NAME gem using commit ID $COMMIT_ID + popd + return 1 +fi + +# Install required packages for the CDK application +if ! python -m pip install -r requirements.txt; +then + echo [cdk_destruction] Failed to install required packages for the $GEM_NAME gem + popd + return 1 +fi + +# Destroy the CDK application +if ! cdk destroy --all -f; +then + echo [cdk_destruction] Failed to destroy the CDK application for the $GEM_NAME gem + popd + return 1 +fi +popd +return 0 +} + +# Create and activate a virtualenv for the CDK deployment +if ! python/python.sh -m venv .env; +then + echo [cdk_bootstrap] Failed to create a virtualenv for the CDK deployment + return 1 +fi +if ! source .env/bin/activate; +then + echo [cdk_bootstrap] Failed to activate the virtualenv for the CDK deployment + exit 1 +fi + +echo [cdk_installation] Install nvm $NVM_VERSION +curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/$NVM_VERSION/install.sh | bash +export NVM_DIR="$HOME/.nvm" +[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm +[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion +echo [cdk_installation] Install the current version of nodejs +nvm install node + +echo [cdk_installation] Install the latest version of CDK +if ! sudo npm uninstall -g aws-cdk; +then + echo [cdk_bootstrap] Failed to uninstall the current version of CDK + exit 1 +fi +if ! sudo npm install -g aws-cdk@latest; +then + echo [cdk_bootstrap] Failed to install the latest version of CDK + exit 1 +fi + +# Set temporary AWS credentials from the assume role +credentials=$(aws sts assume-role --query Credentials.[SecretAccessKey,SessionToken,AccessKeyId] --output text --role-arn $ASSUME_ROLE_ARN --role-session-name o3de-Automation-session) +AWS_SECRET_ACCESS_KEY=$(echo "$credentials" | cut -d' ' -f1) +AWS_SESSION_TOKEN=$(echo "$credentials" | cut -d' ' -f2) +AWS_ACCESS_KEY_ID=$(echo "$credentials" | cut -d' ' -f3) + +ERROR_EXISTS=0 +DestroyCDKApplication AWSCore +ERROR_EXISTS=$? +DestroyCDKApplication AWSClientAuth +ERROR_EXISTS=$? +DestroyCDKApplication AWSMetrics +ERROR_EXISTS=$? + +if [ $ERROR_EXISTS -eq 1 ] +then + exit 1 +fi + +exit 0 + diff --git a/scripts/build/Platform/Linux/pipeline.json b/scripts/build/Platform/Linux/pipeline.json index f44ed5f9de..e9667d312d 100644 --- a/scripts/build/Platform/Linux/pipeline.json +++ b/scripts/build/Platform/Linux/pipeline.json @@ -10,11 +10,70 @@ "daily-pipeline-metrics": { "CLEAN_WORKSPACE": true }, - "packaging": { - "CLEAN_WORKSPACE": true - }, "nightly-clean": { "CLEAN_WORKSPACE": true } + }, + "PIPELINE_JENKINS_PARAMETERS": { + "nightly-incremental": [ + { + "parameter_name": "O3DE_AWS_PROJECT_NAME", + "parameter_type": "string", + "default_value": "", + "use_last_run_value": true, + "description": "The name of the O3DE project that stacks should be deployed for." + }, + { + "parameter_name": "O3DE_AWS_DEPLOY_REGION", + "parameter_type": "string", + "default_value": "", + "use_last_run_value": true, + "description": "The region to deploy the stacks into." + }, + { + "parameter_name": "ASSUME_ROLE_ARN", + "parameter_type": "string", + "default_value": "", + "use_last_run_value": true, + "description": "The ARN of the IAM role to assume to retrieve temporary AWS credentials." + }, + { + "parameter_name": "COMMIT_ID", + "parameter_type": "string", + "default_value": "", + "use_last_run_value": true, + "description": "The commit ID for locking the version of CDK applications to deploy." + } + ], + "nightly-clean": [ + { + "parameter_name": "O3DE_AWS_PROJECT_NAME", + "parameter_type": "string", + "default_value": "", + "use_last_run_value": true, + "description": "The name of the O3DE project that stacks should be deployed for." + }, + { + "parameter_name": "O3DE_AWS_DEPLOY_REGION", + "parameter_type": "string", + "default_value": "", + "use_last_run_value": true, + "description": "The region to deploy the stacks into." + }, + { + "parameter_name": "ASSUME_ROLE_ARN", + "parameter_type": "string", + "default_value": "", + "use_last_run_value": true, + "description": "The ARN of the IAM role to assume to retrieve temporary AWS credentials." + }, + { + "parameter_name": "COMMIT_ID", + "parameter_type": "string", + "default_value": "", + "use_last_run_value": true, + "description": "The commit ID for locking the version of CDK applications to deploy." + } + ] } } diff --git a/scripts/build/Platform/Mac/build_config.json b/scripts/build/Platform/Mac/build_config.json index fb960a96fa..6147f70f0c 100644 --- a/scripts/build/Platform/Mac/build_config.json +++ b/scripts/build/Platform/Mac/build_config.json @@ -14,7 +14,8 @@ ], "steps": [ "profile", - "asset_profile" + "asset_profile", + "test_profile" ] }, "metrics": { @@ -89,6 +90,22 @@ "ASSET_PROCESSOR_PLATFORMS": "mac" } }, + "test_profile": { + "TAGS": [ + "daily-pipeline-metrics", + "weekly-build-metrics" + ], + "COMMAND": "build_test_mac.sh", + "PARAMETERS": { + "CONFIGURATION": "profile", + "OUTPUT_DIRECTORY": "build/mac", + "CMAKE_OPTIONS": "-G Xcode", + "CMAKE_LY_PROJECTS": "AutomatedTesting", + "CMAKE_TARGET": "ALL_BUILD", + "CTEST_OPTIONS": "-L (SUITE_smoke|SUITE_main) -LE (REQUIRES_gpu) --no-tests=error", + "TEST_RESULTS": "False" + } + }, "periodic_test_profile": { "TAGS": [ "nightly-incremental", @@ -102,7 +119,7 @@ "CMAKE_OPTIONS": "-G Xcode", "CMAKE_LY_PROJECTS": "AutomatedTesting", "CMAKE_TARGET": "TEST_SUITE_periodic", - "CTEST_OPTIONS": "-L \"(SUITE_periodic)\"", + "CTEST_OPTIONS": "-L (SUITE_periodic)", "TEST_RESULTS": "False" } }, @@ -119,7 +136,7 @@ "CMAKE_OPTIONS": "-G Xcode", "CMAKE_LY_PROJECTS": "AutomatedTesting", "CMAKE_TARGET": "TEST_SUITE_benchmark", - "CTEST_OPTIONS": "-L \"(SUITE_benchmark)\"", + "CTEST_OPTIONS": "-L (SUITE_benchmark)", "TEST_RESULTS": "False" } }, @@ -153,16 +170,6 @@ "CMAKE_TARGET": "ALL_BUILD" } }, - "mac_packaging_all": { - "TAGS": [ - "packaging" - ], - "COMMAND": "python_mac.sh", - "PARAMETERS": { - "SCRIPT_PATH": "scripts/build/package/package.py", - "SCRIPT_PARAMETERS": "--platform Mac --type all" - } - }, "install_profile": { "TAGS": [], "COMMAND": "build_mac.sh", diff --git a/scripts/build/Platform/Mac/build_mac.sh b/scripts/build/Platform/Mac/build_mac.sh index 2ea5eeab8a..e0cb1ba889 100755 --- a/scripts/build/Platform/Mac/build_mac.sh +++ b/scripts/build/Platform/Mac/build_mac.sh @@ -17,7 +17,7 @@ SOURCE_DIRECTORY=${PWD} pushd $OUTPUT_DIRECTORY LAST_CONFIGURE_CMD_FILE=ci_last_configure_cmd.txt -CONFIGURE_CMD="cmake ${SOURCE_DIRECTORY} ${CMAKE_OPTIONS} ${EXTRA_CMAKE_OPTIONS}" +CONFIGURE_CMD="cmake '${SOURCE_DIRECTORY}' ${CMAKE_OPTIONS} ${EXTRA_CMAKE_OPTIONS}" if [[ -n "$CMAKE_LY_PROJECTS" ]]; then CONFIGURE_CMD="${CONFIGURE_CMD} -DLY_PROJECTS='${CMAKE_LY_PROJECTS}'" fi @@ -48,7 +48,7 @@ if [[ ! -z "$RUN_CONFIGURE" ]]; then echo "${CONFIGURE_CMD}" > ${LAST_CONFIGURE_CMD_FILE} fi -echo [ci_build] cmake --build . --target ${CMAKE_TARGET} --config ${CONFIGURATION} -j $(sysctl -n hw.ncpu) -- ${CMAKE_NATIVE_BUILD_ARGS} -cmake --build . --target ${CMAKE_TARGET} --config ${CONFIGURATION} -j $(sysctl -n hw.ncpu) -- ${CMAKE_NATIVE_BUILD_ARGS} +echo [ci_build] cmake --build . --target ${CMAKE_TARGET} --config ${CONFIGURATION} -j $(/usr/sbin/sysctl -n hw.ncpu) -- ${CMAKE_NATIVE_BUILD_ARGS} +cmake --build . --target ${CMAKE_TARGET} --config ${CONFIGURATION} -j $(/usr/sbin/sysctl -n hw.ncpu) -- ${CMAKE_NATIVE_BUILD_ARGS} popd diff --git a/scripts/build/Platform/Mac/pipeline.json b/scripts/build/Platform/Mac/pipeline.json index e8cea0f06d..24f42a0c69 100644 --- a/scripts/build/Platform/Mac/pipeline.json +++ b/scripts/build/Platform/Mac/pipeline.json @@ -10,9 +10,6 @@ "daily-pipeline-metrics": { "CLEAN_WORKSPACE": true }, - "packaging": { - "CLEAN_WORKSPACE": true - }, "nightly-clean": { "CLEAN_WORKSPACE": true } diff --git a/scripts/build/Platform/Mac/test_mac.sh b/scripts/build/Platform/Mac/test_mac.sh index e398de3061..46dffab84d 100755 --- a/scripts/build/Platform/Mac/test_mac.sh +++ b/scripts/build/Platform/Mac/test_mac.sh @@ -19,8 +19,9 @@ fi pushd $OUTPUT_DIRECTORY # Find the CTEST_RUN_FLAGS from the CMakeCache.txt file, then replace the $ with the current configuration -IFS='=' read -ra CTEST_RUN_FLAGS <<< $(cmake -N -LA . | grep "CTEST_RUN_FLAGS:STRING") -CTEST_RUN_FLAGS=${CTEST_RUN_FLAGS[1]/$/${CONFIGURATION}} +CTEST_RUN_FLAGS=$(cmake -N -LA . | grep "CTEST_RUN_FLAGS:STRING") +CTEST_RUN_FLAGS=${CTEST_RUN_FLAGS/CTEST_RUN_FLAGS:STRING=/} +CTEST_RUN_FLAGS=${CTEST_RUN_FLAGS/$/${CONFIGURATION}} # Run ctest echo [ci_build] ctest ${CTEST_RUN_FLAGS} ${CTEST_OPTIONS} diff --git a/scripts/build/Platform/Windows/build_config.json b/scripts/build/Platform/Windows/build_config.json index c591ca0eac..e3d5a4a3fc 100644 --- a/scripts/build/Platform/Windows/build_config.json +++ b/scripts/build/Platform/Windows/build_config.json @@ -59,26 +59,6 @@ "SCRIPT_PARAMETERS": "--platform=Windows --repository=%REPOSITORY_NAME% --jobname=%JOB_NAME% --jobnumber=%BUILD_NUMBER% --jobnode=%NODE_LABEL% --changelist=%CHANGE_ID%" } }, - "windows_packaging_all": { - "TAGS": [ - "packaging" - ], - "COMMAND": "python_windows.cmd", - "PARAMETERS": { - "SCRIPT_PATH": "scripts/build/package/package.py", - "SCRIPT_PARAMETERS": "--platform Windows --type all" - } - }, - "3rdParty_all": { - "TAGS": [ - "packaging" - ], - "COMMAND": "python_windows.cmd", - "PARAMETERS": { - "SCRIPT_PATH": "scripts/build/package/package.py", - "SCRIPT_PARAMETERS": "--platform 3rdParty --type 3rdParty_all" - } - }, "test_impact_analysis_profile": { "TAGS": [ ], diff --git a/scripts/build/Platform/Windows/build_windows.cmd b/scripts/build/Platform/Windows/build_windows.cmd index 9e9b124adb..798550370f 100644 --- a/scripts/build/Platform/Windows/build_windows.cmd +++ b/scripts/build/Platform/Windows/build_windows.cmd @@ -8,8 +8,7 @@ REM REM SETLOCAL EnableDelayedExpansion - -CALL %~dp0env_windows.cmd +CALL "%~dp0env_windows.cmd" IF NOT EXIST "%OUTPUT_DIRECTORY%" ( MKDIR %OUTPUT_DIRECTORY%. @@ -29,7 +28,7 @@ REM Compute half the amount of processors so some jobs can run SET /a HALF_PROCESSORS = NUMBER_OF_PROCESSORS / 2 SET LAST_CONFIGURE_CMD_FILE=ci_last_configure_cmd.txt -SET CONFIGURE_CMD=cmake %SOURCE_DIRECTORY% %CMAKE_OPTIONS% %EXTRA_CMAKE_OPTIONS% +SET CONFIGURE_CMD=cmake "%SOURCE_DIRECTORY%" %CMAKE_OPTIONS% %EXTRA_CMAKE_OPTIONS% IF NOT "%CMAKE_LY_PROJECTS%"=="" ( SET CONFIGURE_CMD=!CONFIGURE_CMD! -DLY_PROJECTS="%CMAKE_LY_PROJECTS%" ) diff --git a/scripts/build/Platform/Windows/pipeline.json b/scripts/build/Platform/Windows/pipeline.json index b18a1e8c63..28d8437408 100644 --- a/scripts/build/Platform/Windows/pipeline.json +++ b/scripts/build/Platform/Windows/pipeline.json @@ -10,9 +10,6 @@ "daily-pipeline-metrics": { "CLEAN_WORKSPACE": true }, - "packaging": { - "CLEAN_WORKSPACE": true - }, "nightly-clean": { "CLEAN_WORKSPACE": true } diff --git a/scripts/build/Platform/iOS/pipeline.json b/scripts/build/Platform/iOS/pipeline.json index a5e2ff710e..369152a7a4 100644 --- a/scripts/build/Platform/iOS/pipeline.json +++ b/scripts/build/Platform/iOS/pipeline.json @@ -10,9 +10,6 @@ "daily-pipeline-metrics": { "CLEAN_WORKSPACE": true }, - "packaging": { - "CLEAN_WORKSPACE": true - }, "nightly-clean": { "CLEAN_WORKSPACE": true } diff --git a/scripts/build/build_node/Platform/Common/requirements.txt b/scripts/build/build_node/Platform/Common/requirements.txt index 6fb767509e..7375d3e849 100644 --- a/scripts/build/build_node/Platform/Common/requirements.txt +++ b/scripts/build/build_node/Platform/Common/requirements.txt @@ -148,20 +148,28 @@ pywin32==228 \ pyxb==1.2.6 \ --hash=sha256:2a00f38dd1d87b88f92d79bc5a09718d730419b88e814545f472bbd5a3bf27b4 \ # via -r requirements.txt -pyyaml==5.3.1 \ - --hash=sha256:06a0d7ba600ce0b2d2fe2e78453a470b5a6e000a985dd4a4e54e436cc36b0e97 \ - --hash=sha256:240097ff019d7c70a4922b6869d8a86407758333f02203e0fc6ff79c5dcede76 \ - --hash=sha256:4f4b913ca1a7319b33cfb1369e91e50354d6f07a135f3b901aca02aa95940bd2 \ - --hash=sha256:6034f55dab5fea9e53f436aa68fa3ace2634918e8b5994d82f3621c04ff5ed2e \ - --hash=sha256:69f00dca373f240f842b2931fb2c7e14ddbacd1397d57157a9b005a6a9942648 \ - --hash=sha256:73f099454b799e05e5ab51423c7bcf361c58d3206fa7b0d555426b1f4d9a3eaf \ - --hash=sha256:74809a57b329d6cc0fdccee6318f44b9b8649961fa73144a98735b0aaf029f1f \ - --hash=sha256:7739fc0fa8205b3ee8808aea45e968bc90082c10aef6ea95e855e10abf4a37b2 \ - --hash=sha256:95f71d2af0ff4227885f7a6605c37fd53d3a106fcab511b8860ecca9fcf400ee \ - --hash=sha256:ad9c67312c84def58f3c04504727ca879cb0013b2517c85a9a253f0cb6380c0a \ - --hash=sha256:b8eac752c5e14d3eca0e6dd9199cd627518cb5ec06add0de9d32baeee6fe645d \ - --hash=sha256:cc8955cfbfc7a115fa81d85284ee61147059a753344bc51098f3ccd69b0d7e0c \ - --hash=sha256:d13155f591e6fcc1ec3b30685d50bf0711574e2c0dfffd7644babf8b5102ca1a \ +pyyaml==5.4 \ + --hash=sha256:f7a21e3d99aa3095ef0553e7ceba36fb693998fbb1226f1392ce33681047465f \ + --hash=sha256:5e7ac4e0e79a53451dc2814f6876c2fa6f71452de1498bbe29c0b54b69a986f4 \ + --hash=sha256:52bf0930903818e600ae6c2901f748bc4869c0c406056f679ab9614e5d21a166 \ + --hash=sha256:a36a48a51e5471513a5aea920cdad84cbd56d70a5057cca3499a637496ea379c \ + --hash=sha256:cc552b6434b90d9dbed6a4f13339625dc466fd82597119897e9489c953acbc22 \ + --hash=sha256:0dc9f2eb2e3c97640928dec63fd8dc1dd91e6b6ed236bd5ac00332b99b5c2ff9 \ + --hash=sha256:5a3f345acff76cad4aa9cb171ee76c590f37394186325d53d1aa25318b0d4a09 \ + --hash=sha256:f3790156c606299ff499ec44db422f66f05a7363b39eb9d5b064f17bd7d7c47b \ + --hash=sha256:124fd7c7bc1e95b1eafc60825f2daf67c73ce7b33f1194731240d24b0d1bf628 \ + --hash=sha256:8b818b6c5a920cbe4203b5a6b14256f0e5244338244560da89b7b0f1313ea4b6 \ + --hash=sha256:737bd70e454a284d456aa1fa71a0b429dd527bcbf52c5c33f7c8eee81ac16b89 \ + --hash=sha256:7242790ab6c20316b8e7bb545be48d7ed36e26bbe279fd56f2c4a12510e60b4b \ + --hash=sha256:cc547d3ead3754712223abb7b403f0a184e4c3eae18c9bb7fd15adef1597cc4b \ + --hash=sha256:8635d53223b1f561b081ff4adecb828fd484b8efffe542edcfdff471997f7c39 \ + --hash=sha256:26fcb33776857f4072601502d93e1a619f166c9c00befb52826e7b774efaa9db \ + --hash=sha256:b2243dd033fd02c01212ad5c601dafb44fbb293065f430b0d3dbf03f3254d615 \ + --hash=sha256:31ba07c54ef4a897758563e3a0fcc60077698df10180abe4b8165d9895c00ebf \ + --hash=sha256:02c78d77281d8f8d07a255e57abdbf43b02257f59f50cc6b636937d68efa5dd0 \ + --hash=sha256:fdc6b2cb4b19e431994f25a9160695cc59a4e861710cc6fc97161c5e845fc579 \ + --hash=sha256:8bf38641b4713d77da19e91f8b5296b832e4db87338d6aeffe422d42f1ca896d \ + --hash=sha256:3c49e39ac034fd64fd576d63bb4db53cda89b362768a67f07749d55f128ac18a \ # via -r requirements.txt requests==2.25.0 \ --hash=sha256:7f1a0b932f4a60a1a65caa4263921bb7d9ee911957e0ae4a23a6dd08185ad5f8 \ diff --git a/scripts/build/build_node/Platform/Linux/Dockerfile b/scripts/build/build_node/Platform/Linux/Dockerfile new file mode 100644 index 0000000000..0bbbcb3a5b --- /dev/null +++ b/scripts/build/build_node/Platform/Linux/Dockerfile @@ -0,0 +1,57 @@ +# +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# + +# This is a base Dockerfile to use for self-containing local or remote development environments +# +# Once docker is installed, build a local image with this command: +# `docker build /localDockerfilepath -t ubuntu-build:latest` +# +# To build using a local repo on disk, run this command: +# `docker run -it -v /localo3depath:/data/workspace/o3de -v /localbuildpath:/data/workspace/o3de/build -v /local3rdPartypath:/root/.o3de/3rdParty \ +# --name build-o3de -d ubuntu-build:latest /bin/sh -c 'cd /data/workspace/o3de && python/python.sh -u scripts/build/ci_build.py --platform Linux --type profile'` +# +# Attach to the running build to interact or view logs using this command: +# `docker attach build-o3de` + +FROM ubuntu:20.04 + +WORKDIR /data/workspace + +# Initilize apt cache +RUN apt-get clean && apt-get update + +# Setup time zone and locale data (necessary for SSL and HTTPS packages) +RUN DEBIAN_FRONTEND="noninteractive" apt-get -y install tzdata locales keyboard-configuration + +RUN sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && \ + dpkg-reconfigure --frontend=noninteractive locales && \ + update-locale LANG=en_US.UTF-8 + +ENV LANG=en_US.UTF-8 + +# Install common tools +RUN apt-get -y install tar sudo less vim lsof firewalld net-tools pciutils \ + file wget kmod xz-utils ca-certificates binutils kbd \ + python3-pip bind9-utils jq bc unzip git git-lfs lsb-release \ + software-properties-common + +# Install build and development tools +RUN git clone --no-checkout https://github.com/o3de/o3de.git .o3de && \ + cd .o3de && \ + git sparse-checkout init --cone && \ + git sparse-checkout set scripts/build/build_node && \ + cd scripts/build/build_node/Platform/Linux && \ + ./install-ubuntu.sh + +# Install supported version of cmake if build tool installation runs into issues +ENV CMAKE_VER=3.21.1-0kitware1ubuntu20.04.1 +RUN $(cmake --version) || apt-get -y install cmake=${CMAKE_VER} cmake-data=${CMAKE_VER} + +# Symlink clang version to non-versioned clang and set cc to clang +RUN find /usr/bin/ -name clang* | sed -E 's/^(\/usr\/bin\/.*)(\-[0-9]*)$/ln -s -v \1\2 \1/' | xargs -d '\n' -n 1 bash -c && \ + update-alternatives --install /usr/bin/cc cc /usr/bin/clang 100 && \ + update-alternatives --install /usr/bin/c++ c++ /usr/bin/clang++ 100 diff --git a/scripts/build/ci_build.py b/scripts/build/ci_build.py index c35a5e9dbf..78978349c3 100755 --- a/scripts/build/ci_build.py +++ b/scripts/build/ci_build.py @@ -88,7 +88,7 @@ def build(build_config_filename, build_platform, build_type): env_params[v] = build_params[v] print(' {} = {} {}'.format(v, env_params[v], '(environment override)' if existing_param else '')) print('--------------------------------------------------------------------------------', flush=True) - process_return = subprocess.run(build_cmd_path, cwd=cwd_dir, env=env_params) + process_return = subprocess.run([build_cmd_path], cwd=cwd_dir, env=env_params) print('--------------------------------------------------------------------------------') if process_return.returncode != 0: print('[ci_build] FAIL: Command {} returned {}'.format(build_cmd_path, process_return.returncode), flush=True) diff --git a/scripts/ctest/CMakeLists.txt b/scripts/ctest/CMakeLists.txt index 98ea21e938..064d27a9cf 100644 --- a/scripts/ctest/CMakeLists.txt +++ b/scripts/ctest/CMakeLists.txt @@ -17,7 +17,7 @@ endif() # Tests ################################################################################ -if(PAL_TRAIT_TEST_LYTESTTOOLS_SUPPORTED) +if(PAL_TRAIT_TEST_PYTEST_SUPPORTED) foreach(suite_name ${LY_TEST_GLOBAL_KNOWN_SUITE_NAMES}) ly_add_pytest( NAME pytest_sanity_${suite_name}_no_gpu @@ -32,16 +32,16 @@ if(PAL_TRAIT_TEST_LYTESTTOOLS_SUPPORTED) TEST_REQUIRES gpu ) endforeach() -endif() - -# add a custom test which makes sure that the test filtering works! - -ly_add_test( - NAME cli_test_driver - EXCLUDE_TEST_RUN_TARGET_FROM_IDE - TEST_COMMAND ${LY_PYTHON_CMD} ${CMAKE_CURRENT_LIST_DIR}/ctest_driver_test.py - -x ${CMAKE_CTEST_COMMAND} - --build-path ${CMAKE_BINARY_DIR} - TEST_LIBRARY pytest -) + # add a custom test which makes sure that the test filtering works! + ly_add_test( + NAME cli_test_driver + EXCLUDE_TEST_RUN_TARGET_FROM_IDE + TEST_COMMAND ${LY_PYTHON_CMD} ${CMAKE_CURRENT_LIST_DIR}/ctest_driver_test.py + -x ${CMAKE_CTEST_COMMAND} + --build-path ${CMAKE_BINARY_DIR} + --config $ + TEST_LIBRARY pytest + ) + +endif() \ No newline at end of file diff --git a/scripts/ctest/ctest_driver_test.py b/scripts/ctest/ctest_driver_test.py index 82d92ce098..b9a7283b25 100755 --- a/scripts/ctest/ctest_driver_test.py +++ b/scripts/ctest/ctest_driver_test.py @@ -15,10 +15,10 @@ import sys import argparse from ctest_driver import SUITES_AND_DESCRIPTIONS -def main(build_path, ctest_executable): +def main(build_path, ctest_executable, config): script_folder = os.path.dirname(__file__) # -N prevents tests from running, just lists them: - base_args = [sys.executable, os.path.join(script_folder,'ctest_driver.py'), "--build-path", build_path, '-N'] + base_args = [sys.executable, os.path.join(script_folder,'ctest_driver.py'), "--build-path", build_path, "--config", config, '-N'] if ctest_executable: base_args.append("--ctest-executable") base_args.append(ctest_executable) @@ -77,7 +77,10 @@ if __name__ == '__main__': parser.add_argument('-b', '--build-path', required=True, help="Path to a CMake build folder (generated by running cmake)") + parser.add_argument('-c', '--config', + required=True, + help="Configuration to run") args = parser.parse_args() - sys.exit(main(args.build_path, args.ctest_executable)) + sys.exit(main(args.build_path, args.ctest_executable, args.config)) diff --git a/scripts/o3de/CMakeLists.txt b/scripts/o3de/CMakeLists.txt index 79836305c0..fced0f7727 100644 --- a/scripts/o3de/CMakeLists.txt +++ b/scripts/o3de/CMakeLists.txt @@ -8,7 +8,7 @@ add_subdirectory(tests) -ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}) +o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${O3DE_ENGINE_RESTRICTED_PATH} ${LY_ROOT_FOLDER}) include(${pal_dir}/o3de_install_${PAL_PLATFORM_NAME_LOWERCASE}.cmake) ly_install_files(FILES ../o3de.py diff --git a/scripts/o3de/o3de/disable_gem.py b/scripts/o3de/o3de/disable_gem.py index 0b0e465d12..eecc765d32 100644 --- a/scripts/o3de/o3de/disable_gem.py +++ b/scripts/o3de/o3de/disable_gem.py @@ -98,9 +98,6 @@ def disable_gem_in_project(gem_name: str = None, def _run_disable_gem_in_project(args: argparse) -> int: - if args.override_home_folder: - manifest.override_home_folder = args.override_home_folder - return disable_gem_in_project(args.gem_name, args.gem_path, args.project_name, @@ -133,9 +130,6 @@ def add_parser_args(parser): help='The cmake enabled gem file in which gem names are to be removed from.' 'If not specified it will assume ') - parser.add_argument('-ohf', '--override-home-folder', type=pathlib.Path, required=False, - help='By default the home folder is the user folder, override it to this folder.') - parser.set_defaults(func=_run_disable_gem_in_project) diff --git a/scripts/o3de/o3de/download.py b/scripts/o3de/o3de/download.py index 8e28561e50..a7d5b56440 100644 --- a/scripts/o3de/o3de/download.py +++ b/scripts/o3de/o3de/download.py @@ -277,9 +277,6 @@ def is_o3de_restricted_update_available(restricted_name: str, local_last_updated return is_o3de_object_update_available(restricted_name, 'restricted_name', local_last_updated) def _run_download(args: argparse) -> int: - if args.override_home_folder: - manifest.override_home_folder = args.override_home_folder - if args.engine_name: return download_engine(args.engine_name, args.dest_path, @@ -331,8 +328,6 @@ def add_parser_args(parser): parser.add_argument('-f', '--force', action='store_true', required=False, default=False, help = 'Force overwrite the current object') - parser.add_argument('-ohf', '--override-home-folder', type=str, required=False, - help='By default the home folder is the user folder, override it to this folder.') parser.set_defaults(func=_run_download) diff --git a/scripts/o3de/o3de/enable_gem.py b/scripts/o3de/o3de/enable_gem.py index fc4dc6e9cf..ea79f6c73f 100644 --- a/scripts/o3de/o3de/enable_gem.py +++ b/scripts/o3de/o3de/enable_gem.py @@ -115,9 +115,6 @@ def enable_gem_in_project(gem_name: str = None, def _run_enable_gem_in_project(args: argparse) -> int: - if args.override_home_folder: - manifest.override_home_folder = args.override_home_folder - return enable_gem_in_project(args.gem_name, args.gem_path, args.project_name, @@ -150,9 +147,6 @@ def add_parser_args(parser): help='The cmake enabled_gem file in which the gem names are specified.' 'If not specified it will assume enabled_gems.cmake') - parser.add_argument('-ohf', '--override-home-folder', type=pathlib.Path, required=False, - help='By default the home folder is the user folder, override it to this folder.') - parser.set_defaults(func=_run_enable_gem_in_project) diff --git a/scripts/o3de/o3de/engine_template.py b/scripts/o3de/o3de/engine_template.py index 6b2e098cf0..d9993fb5d0 100755 --- a/scripts/o3de/o3de/engine_template.py +++ b/scripts/o3de/o3de/engine_template.py @@ -80,10 +80,20 @@ restricted_platforms = { 'Provo', 'Salem', 'Jasper', - 'Paris' + 'Paris', + 'Xenia', + 'Lancaster' } -template_file_name = 'template.json' +O3DE_LICENSE_TEXT = \ + """'# {BEGIN_LICENSE} +# Copyright (c) Contributors to the Open 3D Engine Project. +# For complete copyright and license terms please see the LICENSE at the root of this distribution. +# +# SPDX-License-Identifier: Apache-2.0 OR MIT +# {END_LICENSE} +""" + this_script_parent = pathlib.Path(os.path.dirname(os.path.realpath(__file__))) @@ -165,7 +175,8 @@ def _execute_template_json(json_data: dict, destination_path: pathlib.Path, template_path: pathlib.Path, replacements: list, - keep_license_text: bool = False) -> None: + keep_license_text: bool = False, + keep_restricted_in_instance: bool = False) -> None: # create dirs first # for each createDirectory entry, transform the folder name for create_directory in json_data['createDirectories']: @@ -174,6 +185,18 @@ def _execute_template_json(json_data: dict, # transform the folder name new_dir = _transform(new_dir.as_posix(), replacements, keep_license_text) + new_dir = pathlib.Path(new_dir) + + if not keep_restricted_in_instance and 'Platform' in new_dir.parts: + try: + # the name of the Platform should follow the '/Platform/' + pattern = r'/Platform/(?P[^/:*?\"<>|\r\n]+/?)' + found_platform = re.search(pattern, new_dir.as_posix()).group('Platform') + found_platform = found_platform.replace('/', '') + if found_platform in restricted_platforms: + continue + except Exception as e: + pass # create the folder os.makedirs(new_dir, exist_ok=True) @@ -184,16 +207,23 @@ def _execute_template_json(json_data: dict, # construct the input file name in_file = template_path / 'Template' / copy_file['file'] - # the file can be marked as optional, if it is and it does not exist skip - if copy_file['isOptional'] and copy_file['isOptional'] == 'true': - if not os.path.isfile(in_file): - continue - # construct the output file name out_file = destination_path / copy_file['file'] # transform the output file name out_file = _transform(out_file.as_posix(), replacements, keep_license_text) + out_file = pathlib.Path(out_file) + + if not keep_restricted_in_instance and 'Platform' in out_file.parts: + try: + # the name of the Platform should follow the '/Platform/' + pattern = r'/Platform/(?P[^/:*?\"<>|\r\n]+/?)' + found_platform = re.search(pattern, out_file.as_posix()).group('Platform') + found_platform = found_platform.replace('/', '') + if found_platform in restricted_platforms: + continue + except Exception as e: + pass # if for some reason the output folder for this file was not created above do it now os.makedirs(os.path.dirname(out_file), exist_ok=True) @@ -205,18 +235,20 @@ def _execute_template_json(json_data: dict, shutil.copy(in_file, out_file) -def _execute_restricted_template_json(json_data: dict, +def _execute_restricted_template_json(template_json_data: dict, + json_data: dict, restricted_platform: str, destination_name, - template_name, destination_path: pathlib.Path, destination_restricted_path: pathlib.Path, + template_path: pathlib.Path, template_restricted_path: pathlib.Path, destination_restricted_platform_relative_path: pathlib.Path, template_restricted_platform_relative_path: pathlib.Path, replacements: list, keep_restricted_in_instance: bool = False, keep_license_text: bool = False) -> None: + # if we are not keeping restricted in instance make restricted.json if not present if not keep_restricted_in_instance: restricted_json = destination_restricted_path / 'restricted.json' @@ -227,50 +259,96 @@ def _execute_restricted_template_json(json_data: dict, restricted_json_data.update({"restricted_name": destination_name}) s.write(json.dumps(restricted_json_data, indent=4) + '\n') + ################################################################################### + # for each createDirectories in the template copy any entries in the json_data that are for this platform + for create_directory in template_json_data['createDirectories']: + new_dir = pathlib.Path(create_directory['dir']) + if not keep_restricted_in_instance and 'Platform' in new_dir.parts: + try: + # the name of the Platform should follow the '/Platform/' + pattern = r'/Platform/(?P[^/:*?\"<>|\r\n]+/?)' + found_platform = re.search(pattern, new_dir.as_posix()).group('Platform') + except Exception as e: + pass + else: + found_platform = found_platform.replace('/', '') + if found_platform == restricted_platform: + create_dirs = [] + if 'createDirectories' in json_data.keys(): + create_dirs = json_data['createDirectories'] + create_dirs.append(create_directory) + json_data.update({'createDirectories': create_dirs}) + + # for each copyFiles in the template copy any entries in the json_data that are for this platform + for copy_file in template_json_data['copyFiles']: + new_file = pathlib.Path(copy_file['file']) + if not keep_restricted_in_instance and 'Platform' in new_file.parts: + try: + # the name of the Platform should follow the '/Platform/' + pattern = r'/Platform/(?P[^/:*?\"<>|\r\n]+/?)' + found_platform = re.search(pattern, new_file.as_posix()).group('Platform') + except Exception as e: + pass + else: + found_platform = found_platform.replace('/', '') + if found_platform == restricted_platform: + copy_files = [] + if 'copyFiles' in json_data.keys(): + copy_files = json_data['copyFiles'] + copy_files.append(copy_file) + json_data.update({'copyFiles': copy_files}) + + ################################################################################### + + # every entry is saved in its combined location, so if not keep_restricted_in_instance + # then we need to palify into the restricted folder + # create dirs first # for each createDirectory entry, transform the folder name - for create_directory in json_data['createDirectories']: - # construct the new folder name - new_dir = destination_restricted_path / restricted_platform / destination_restricted_platform_relative_path\ - / destination_name / create_directory['dir'] - if keep_restricted_in_instance: - new_dir = destination_path / create_directory['origin'] + if 'createDirectories' in json_data: + for create_directory in json_data['createDirectories']: + # construct the new folder name + if keep_restricted_in_instance: + new_dir = destination_path / create_directory['dir'] + else: + pal_dir = create_directory['dir'].replace(f'Platform/{restricted_platform}','') + new_dir = destination_restricted_path / restricted_platform / destination_restricted_platform_relative_path / pal_dir - # transform the folder name - new_dir = _transform(new_dir.as_posix(), replacements, keep_license_text) + # transform the folder name + new_dir = _transform(new_dir.as_posix(), replacements, keep_license_text) - # create the folder - os.makedirs(new_dir, exist_ok=True) + # create the folder + os.makedirs(new_dir, exist_ok=True) # for each copyFiles entry, _transformCopy the templated source file into a concrete instance file or # regular copy if not templated - for copy_file in json_data['copyFiles']: - # construct the input file name - in_file = template_restricted_path / restricted_platform / template_restricted_platform_relative_path\ - / template_name / 'Template' / copy_file['file'] + if 'copyFiles' in json_data: + for copy_file in json_data['copyFiles']: + # construct the input file name + if template_restricted_path: + pal_file = copy_file['file'].replace(f'Platform/{restricted_platform}/', '') + in_file = template_restricted_path / restricted_platform / template_restricted_platform_relative_path / 'Template' / pal_file + else: + in_file = template_path / 'Template' / copy_file['file'] - # the file can be marked as optional, if it is and it does not exist skip - if copy_file['isOptional'] and copy_file['isOptional'] == 'true': - if not os.path.isfile(in_file): - continue + # construct the output file name + if keep_restricted_in_instance: + out_file = destination_path / copy_file['file'] + else: + pal_file = copy_file['file'].replace(f'Platform/{restricted_platform}/', '') + out_file = destination_restricted_path / restricted_platform / destination_restricted_platform_relative_path / pal_file - # construct the output file name - out_file = destination_restricted_path / restricted_platform / destination_restricted_platform_relative_path\ - / destination_name / copy_file['file'] - if keep_restricted_in_instance: - out_file = destination_path / copy_file['origin'] + # transform the output file name + out_file = _transform(out_file.as_posix(), replacements, keep_license_text) - # transform the output file name - out_file = _transform(out_file.as_posix(), replacements, keep_license_text) - - # if for some reason the output folder for this file was not created above do it now - os.makedirs(os.path.dirname(out_file), exist_ok=True) + # if for some reason the output folder for this file was not created above do it now + os.makedirs(os.path.dirname(out_file), exist_ok=True) - # if templated _transformCopy the file, if not just copy it - if copy_file['isTemplated']: - _transform_copy(in_file, out_file, replacements, keep_license_text) - else: - shutil.copy(in_file, out_file) + # if templated _transformCopy the file, if not just copy it + if copy_file['isTemplated']: + _transform_copy(in_file, out_file, replacements, keep_license_text) + else: + shutil.copy(in_file, out_file) def _instantiate_template(template_json_data: dict, @@ -309,46 +387,51 @@ def _instantiate_template(template_json_data: dict, :return: 0 for success or non 0 failure code """ # execute the template json + # this will filter out any restricted platforms in the template _execute_template_json(template_json_data, destination_path, template_path, replacements, - keep_license_text) + keep_license_text, + keep_restricted_in_instance) - # execute restricted platform jsons if any - if template_restricted_path: - for restricted_platform in os.listdir(template_restricted_path): - if os.path.isfile(restricted_platform): - continue + # we execute the jason data again if there are any restricted platforms in the main template and + # execute any restricted platform jsons if separate + + for restricted_platform in restricted_platforms: + restricted_json_data = {} + if template_restricted_path: template_restricted_platform = template_restricted_path / restricted_platform - template_restricted_platform_path_rel = template_restricted_platform / template_restricted_platform_relative_path / template_name - platform_json = template_restricted_platform_path_rel / template_file_name + template_restricted_platform_path_rel = template_restricted_platform / template_restricted_platform_relative_path + platform_json = template_restricted_platform_path_rel / 'template.json' if os.path.isfile(platform_json): if not validation.valid_o3de_template_json(platform_json): logger.error(f'Template json {platform_json} is invalid.') return 1 - # load the template json and execute it + # load the template json with open(platform_json, 'r') as s: try: - json_data = json.load(s) + restricted_json_data = json.load(s) except json.JSONDecodeError as e: logger.error(f'Failed to load {platform_json}: ' + str(e)) return 1 - else: - _execute_restricted_template_json(json_data, - restricted_platform, - destination_name, - template_name, - destination_path, - destination_restricted_path, - template_restricted_path, - destination_restricted_platform_relative_path, - template_restricted_platform_relative_path, - replacements, - keep_restricted_in_instance, - keep_license_text) + + # execute for this restricted platform + _execute_restricted_template_json(template_json_data, + restricted_json_data, + restricted_platform, + destination_name, + destination_path, + destination_restricted_path, + template_path, + template_restricted_path, + destination_restricted_platform_relative_path, + template_restricted_platform_relative_path, + replacements, + keep_restricted_in_instance, + keep_license_text) return 0 @@ -365,7 +448,8 @@ def create_template(source_path: pathlib.Path, keep_restricted_in_template: bool = False, keep_license_text: bool = False, replace: list = None, - force: bool = False) -> int: + force: bool = False, + no_register: bool = False) -> int: """ Create a template from a source directory using replacement @@ -391,6 +475,7 @@ def create_template(source_path: pathlib.Path, this controls if you want to keep the license text from the template in the new instance. It is false by default because most people will not want license text in their instances. :param force Overrides existing files even if they exist + :param no_register: whether or not after completion that the new object is registered :return: 0 for success or non 0 failure code """ @@ -401,15 +486,19 @@ def create_template(source_path: pathlib.Path, if not source_path.is_dir(): logger.error(f'Src path {source_path} is not a folder.') return 1 - source_path = source_path.resolve() - # source_name is now the last component of the source_path + + # if not specified, source_name defaults to the last component of the source_path if not source_name: source_name = os.path.basename(source_path) sanitized_source_name = utils.sanitize_identifier_for_cpp(source_name) # if no template path, use default_templates_folder path if not template_path: + logger.info(f'Template path empty. Using source name {source_name}') + template_path = source_name + # if the template_path is not an absolute path, then it default to relative from the default template folder + if not template_path.is_absolute(): default_templates_folder = manifest.get_registered(default_folder='templates') template_path = default_templates_folder / source_name logger.info(f'Template path empty. Using default templates folder {template_path}') @@ -423,7 +512,8 @@ def create_template(source_path: pathlib.Path, except ValueError: pass else: - logger.error(f'Template output path {template_path} cannot be a subdirectory of the source_path {source_path}\n') + logger.error( + f'Template output path {template_path} cannot be a subdirectory of the source_path {source_path}\n') return 1 # template name is now the last component of the template_path @@ -434,69 +524,61 @@ def create_template(source_path: pathlib.Path, logger.error(f'Template path cannot be a restricted name. {template_name}') return 1 + # if the source restricted name was given and no source restricted path, look up the restricted name to fill + # in the path if source_restricted_name and not source_restricted_path: source_restricted_path = manifest.get_registered(restricted_name=source_restricted_name) - # source_restricted_path + # if we have a source restricted path, make sure its a real restricted object if source_restricted_path: - if not os.path.isabs(source_restricted_path): - engine_json = manifest.get_this_engine_path() / 'engine.json' - if not validation.valid_o3de_engine_json(engine_json): - logger.error(f"Engine json {engine_json} is not valid.") - return 1 - with open(engine_json) as s: - try: - engine_json_data = json.load(s) - except json.JSONDecodeError as e: - logger.error(f"Failed to read engine json {engine_json}: {str(e)}") - return 1 - try: - engine_restricted = engine_json_data['restricted_name'] - except KeyError as e: - logger.error(f"Engine json {engine_json} restricted not found.") - return 1 - engine_restricted_folder = manifest.get_registered(restricted_name=engine_restricted) - new_source_restricted_path = engine_restricted_folder / source_restricted_path - logger.info(f'Source restricted path {source_restricted_path} not a full path. We must assume this engines' - f' restricted folder {new_source_restricted_path}') - if not os.path.isdir(source_restricted_path): + if not source_restricted_path.is_dir(): logger.error(f'Source restricted path {source_restricted_path} is not a folder.') return 1 + restricted_json = source_restricted_path / 'restricted.json' + if not validation.valid_o3de_restricted_json(restricted_json): + logger.error(f"Restricted json {restricted_json} is not valid.") + return 1 + with open(restricted_json, 'r') as s: + try: + restricted_json_data = json.load(s) + except json.JSONDecodeError as e: + logger.error(f'Failed to load {restricted_json}: ' + str(e)) + return 1 + try: + source_restricted_name = restricted_json_data['restricted_name'] + except KeyError as e: + logger.error(f'Failed to read restricted_name from {restricted_json}') + return 1 + # if the template restricted name was given and no template restricted path, look up the restricted name to fill + # in the path if template_restricted_name and not template_restricted_path: template_restricted_path = manifest.get_registered(restricted_name=template_restricted_name) + # if we dont have a template restricted name then set it to the templates name if not template_restricted_name: template_restricted_name = template_name - # template_restricted_path + # if we have a template restricted path, it must either not exist yet or must be a restricted object already if template_restricted_path: - if not os.path.isabs(template_restricted_path): - default_templates_restricted_folder = manifest.get_registered(restricted_name='templates') - new_template_restricted_path = default_templates_restricted_folder / template_restricted_path - logger.info(f'Template restricted path {template_restricted_path} not a full path. We must assume the' - f' default templates restricted folder {new_template_restricted_path}') - template_restricted_path = new_template_restricted_path - - if os.path.isdir(template_restricted_path): + if template_restricted_path.is_dir(): # see if this is already a restricted path, if it is get the "restricted_name" from the restricted json # so we can set "restricted_name" to it for this template restricted_json = template_restricted_path / 'restricted.json' - if os.path.isfile(restricted_json): - if not validation.valid_o3de_restricted_json(restricted_json): - logger.error(f'{restricted_json} is not valid.') + if not validation.valid_o3de_restricted_json(restricted_json): + logger.error(f'{restricted_json} is not valid.') + return 1 + with open(restricted_json, 'r') as s: + try: + restricted_json_data = json.load(s) + except json.JSONDecodeError as e: + logger.error(f'Failed to load {restricted_json}: ' + str(e)) + return 1 + try: + template_restricted_name = restricted_json_data['restricted_name'] + except KeyError as e: + logger.error(f'Failed to read restricted_name from {restricted_json}') return 1 - with open(restricted_json, 'r') as s: - try: - restricted_json_data = json.load(s) - except json.JSONDecodeError as e: - logger.error(f'Failed to load {restricted_json}: ' + str(e)) - return 1 - try: - template_restricted_name = restricted_json_data['restricted_name'] - except KeyError as e: - logger.error(f'Failed to read restricted_name from {restricted_json}') - return 1 else: os.makedirs(template_restricted_path, exist_ok=True) @@ -610,36 +692,7 @@ def create_template(source_path: pathlib.Path, else: return False, t_data - def _transform_into_template_restricted_filename(s_data: object, - platform: str) -> (bool, object): - """ - Internal function to transform a restricted platform file name into restricted template file name - :param s_data: the input data, this could be file data or file name data - :return: bool: whether or not the returned data MAY need to be transformed to instantiate it - t_data: potentially transformed data 0 for success or non 0 failure code - """ - # copy the src data to the transformed data, then operate only on transformed data - t_data = s_data - - # run all the replacements - for replacement in replacements: - t_data = t_data.replace(replacement[0], replacement[1]) - - # the name of the Platform should follow the '/Platform/{platform}' - t_data = t_data.replace(f"Platform/{platform}", '') - - # we want to send back the transformed data and whether or not this file - # may require transformation when instantiated. So if the input data is not the - # same as the output, then we transformed it which means there may be a transformation - # needed to instance it. - if s_data != t_data: - return True, t_data - else: - return False, t_data - - def _transform_restricted_into_copyfiles_and_createdirs(source_path: pathlib.Path, - restricted_platform: str, - root_abs: pathlib.Path, + def _transform_restricted_into_copyfiles_and_createdirs(root_abs: pathlib.Path, path_abs: pathlib.Path = None) -> None: """ Internal function recursively called to transform any paths files into copyfiles and create dirs relative to @@ -657,70 +710,49 @@ def create_template(source_path: pathlib.Path, # create the absolute entry by joining the path_abs and the entry entry_abs = path_abs / entry + # report what file we are processing so we have a good idea if it breaks on what file it broke on + logger.info(f'Processing file: {entry_abs}') + # create the relative entry by removing the root_abs try: entry_rel = entry_abs.relative_to(root_abs) except ValueError as err: - logger.warning(f'Unable to create relative path: {str(err)}') + logger.fatal(f'Unable to create relative path: {str(err)}') - # report what file we are processing so we have a good idea if it breaks on what file it broke on - logger.info(f'Processing file: {entry_abs}') - - # this is a restricted file, so we need to transform it, unpalify it - # restricted///some/folders/ -> - # /some/folders/Platform// - # - # C:/repo/Lumberyard/restricted/Jasper/TestDP/CMakeLists.txt -> - # C:/repo/Lumberyard/TestDP/Platform/Jasper/CMakeLists.txt - # - _, origin_entry_rel = _transform_into_template(entry_rel.as_posix()) - components = list(origin_entry_rel.parts) - num_components = len(components) - - # see how far along the source path the restricted folder matches - # then hopefully there is a Platform folder, warn if there isn't - before = [] - after = [] - relative = '' - - if os.path.isdir(entry_abs): - for x in range(0, num_components): - relative += f'{components[x]}/' - if os.path.isdir(f'{source_path}/{relative}'): - before.append(components[x]) - else: - after.append(components[x]) - else: - for x in range(0, num_components - 1): - relative += f'{components[x]}/' - if os.path.isdir(f'{source_path}/{relative}'): - before.append(components[x]) - else: - after.append(components[x]) - - after.append(components[num_components - 1]) - - before.append("Platform") - warn_if_not_platform = source_path / pathlib.Path(*before) - before.append(restricted_platform) - before.extend(after) - - origin_entry_rel = pathlib.Path(*before) - - if not os.path.isdir(warn_if_not_platform): - logger.warning( - f'{entry_abs} -> {origin_entry_rel}: Other Platforms not found in {warn_if_not_platform}') - - destination_entry_rel = origin_entry_rel - destination_entry_abs = template_path / 'Template' / origin_entry_rel + # templatize the entry relative into the destination entry relative + _, destination_entry_rel = _transform_into_template(entry_rel.as_posix()) + destination_entry_rel = pathlib.Path(destination_entry_rel) # clean up any relative leading slashes - if origin_entry_rel.as_posix().startswith('/'): - origin_entry_rel = pathlib.Path(origin_entry_rel.as_posix().lstrip('/')) if destination_entry_rel.as_posix().startswith('/'): destination_entry_rel = pathlib.Path(destination_entry_rel.as_posix().lstrip('/')) + if isinstance(destination_entry_rel, pathlib.Path): + destination_entry_rel = destination_entry_rel.as_posix() - # make sure the dst folder may or may not exist yet, make sure it does exist before we transform + if template_restricted_path: + destination_entry_abs = template_restricted_path / restricted_platform / template_restricted_platform_relative_path / 'Template' / destination_entry_rel + destination_entry_rel = pathlib.Path(destination_entry_rel) + first = True + for component in destination_entry_rel.parts: + if first: + first = False + result = pathlib.Path(component) / 'Platform' / restricted_platform + else: + result = result / component + destination_entry_rel = result.as_posix() + else: + destination_entry_rel = pathlib.Path(destination_entry_rel) + first = True + for component in destination_entry_rel.parts: + if first: + first = False + result = pathlib.Path(component) / 'Platform' / restricted_platform + else: + result = result / component + destination_entry_rel = result.as_posix() + destination_entry_abs = template_path / 'Template' / destination_entry_rel + + # the destination folder may or may not exist yet, make sure it does exist before we transform # data into it os.makedirs(os.path.dirname(destination_entry_abs), exist_ok=True) @@ -730,8 +762,8 @@ def create_template(source_path: pathlib.Path, if os.path.isfile(entry_abs): # if this file is a known binary file, there is no transformation needed and just copy it - # if not a known binary file open it and try to transform the data. if it is an unknown binary - # type it will throw and we catch copy + # if not a known binary file open it and try to transform the data. + # if it is an unknown binary type it will throw and we catch copy # if we had no known binary type it would still work, but much slower name, ext = os.path.splitext(entry) if ext in binary_file_ext: @@ -743,7 +775,7 @@ def create_template(source_path: pathlib.Path, source_data = s.read() templated, source_data = _transform_into_template(source_data, _is_cpp_file(entry_abs)) - # if the file type is a file that we expect to fins license header and we don't find any + # if the file type is a file that we expect to find a license header and we don't find any # warn that the we didn't find the license info, this makes it easy to make sure we didn't # miss any files we want to have license info in. if keep_license_text and ext in expect_license_info_ext: @@ -761,19 +793,26 @@ def create_template(source_path: pathlib.Path, shutil.copy(entry_abs, destination_entry_abs) pass - copy_files.append({ - "file": destination_entry_rel, - "origin": origin_entry_rel, - "isTemplated": templated, - "isOptional": False - }) + if keep_restricted_in_template: + copy_files.append({ + "file": destination_entry_rel, + "isTemplated": templated + }) + else: + restricted_platform_entries[restricted_platform]['copyFiles'].append({ + "file": destination_entry_rel, + "isTemplated": templated + }) else: - create_dirs.append({ - "dir": destination_entry_rel, - "origin": origin_entry_rel - }) - _transform_restricted_into_copyfiles_and_createdirs(source_path, restricted_platform, root_abs, - entry_abs) + if keep_restricted_in_template: + create_dirs.append({ + "dir": destination_entry_rel + }) + else: + restricted_platform_entries[restricted_platform]['createDirs'].append({ + "dir": destination_entry_rel + }) + _transform_restricted_into_copyfiles_and_createdirs(root_abs, entry_abs) def _transform_dir_into_copyfiles_and_createdirs(root_abs: pathlib.Path, path_abs: pathlib.Path = None) -> None: @@ -793,18 +832,21 @@ def create_template(source_path: pathlib.Path, # create the absolute entry by joining the path_abs and the entry entry_abs = path_abs / entry + # report what file we are processing so we have a good idea if it breaks on what file it broke on + logger.info(f'Processing file: {entry_abs}') + # create the relative entry by removing the root_abs - entry_rel = entry_abs try: - entry_rel = entry_abs.relative_to(root_abs) + entry_rel = entry_abs.relative_to(root_abs).as_posix() except ValueError as err: - logger.warning(f'Unable to create relative path: {str(err)}') + logger.fatal(f'Unable to create relative path: {str(err)}') - # report what file we are processing so we have a good idea if it breaks on what file it broke on - logger.info(f'Processing file: {entry_abs}') + # templatize the entry relative into the origin entry relative + _, destination_entry_rel = _transform_into_template(entry_rel) + destination_entry_rel = pathlib.Path(destination_entry_rel) - # see if the entry is a platform file, if it is then we save its copyfile data in a platform specific list - # then at the end we can save the restricted ones separately + # see if the entry is a restricted platform file, if it is then we save its copyfile data in a + # platform specific list then at the end we can save the restricted ones separately found_platform = '' platform = False if not keep_restricted_in_template and 'Platform' in entry_abs.parts: @@ -812,7 +854,7 @@ def create_template(source_path: pathlib.Path, try: # the name of the Platform should follow the '/Platform/' pattern = r'/Platform/(?P[^/:*?\"<>|\r\n]+/?)' - found_platform = re.search(pattern, entry_abs).group('Platform') + found_platform = re.search(pattern, entry_abs.as_posix()).group('Platform') found_platform = found_platform.replace('/', '') except Exception as e: pass @@ -831,30 +873,35 @@ def create_template(source_path: pathlib.Path, # Now if we found a platform and still have a found_platform which is a restricted platform # then transform the entry relative name into a dst relative entry name and dst abs entry. # if not then create a normal relative and abs dst entry name - _, origin_entry_rel = _transform_into_template(entry_rel.as_posix()) if platform and found_platform in restricted_platforms: # if we don't have a template restricted path and we found restricted files... warn and skip # the file/dir if not template_restricted_path: - logger.warning("Restricted platform files found!!! {entry_rel}, {found_platform}") + logger.warning("Restricted platform file found!!! {destination_entry_rel}, {found_platform}") continue - _, destination_entry_rel = _transform_into_template_restricted_filename(entry_rel, found_platform) - destination_entry_abs = template_restricted_path / found_platform\ - / template_restricted_platform_relative_path / template_name / 'Template'\ - / destination_entry_rel + + # run all the replacements + for replacement in replacements: + destination_entry_rel = destination_entry_rel.replace(replacement[0], replacement[1]) + + # the name of the Platform should follow the '/Platform/{found_platform}' + destination_entry_rel = destination_entry_rel.replace(f"Platform/{found_platform}", '') + destination_entry_rel = destination_entry_rel.lstrip('/') + + # construct the absolute entry from the relative + if template_restricted_platform_relative_path: + destination_entry_abs = template_restricted_path / found_platform / template_restricted_platform_relative_path / template_name / 'Template' / destination_entry_rel + else: + destination_entry_abs = template_restricted_path / found_platform / 'Template' / destination_entry_rel else: - destination_entry_rel = origin_entry_rel + # construct the absolute entry from the relative destination_entry_abs = template_path / 'Template' / destination_entry_rel # clean up any relative leading slashes - if isinstance(origin_entry_rel, pathlib.Path): - origin_entry_rel = origin_entry_rel.as_posix() - if origin_entry_rel.startswith('/'): - origin_entry_rel = pathlib.Path(origin_entry_rel.lstrip('/')) if isinstance(destination_entry_rel, pathlib.Path): destination_entry_rel = destination_entry_rel.as_posix() if destination_entry_rel.startswith('/'): - destination_entry_rel = pathlib.Path(destination_entry_rel.lstrip('/')) + destination_entry_rel = destination_entry_rel.lstrip('/') # make sure the dst folder may or may not exist yet, make sure it does exist before we transform # data into it @@ -902,29 +949,23 @@ def create_template(source_path: pathlib.Path, if platform and found_platform in restricted_platforms: restricted_platform_entries[found_platform]['copyFiles'].append({ "file": destination_entry_rel, - "origin": origin_entry_rel, - "isTemplated": templated, - "isOptional": False + "isTemplated": templated }) else: copy_files.append({ "file": destination_entry_rel, - "origin": origin_entry_rel, - "isTemplated": templated, - "isOptional": False + "isTemplated": templated }) else: # if the folder was for a restricted platform add the entry to the restricted platform, otherwise add it # to the non restricted if platform and found_platform in restricted_platforms: restricted_platform_entries[found_platform]['createDirs'].append({ - "dir": destination_entry_rel, - "origin": origin_entry_rel + "dir": destination_entry_rel }) else: create_dirs.append({ - "dir": destination_entry_rel, - "origin": origin_entry_rel + "dir": destination_entry_rel }) # recurse using the same root and this folder @@ -937,11 +978,11 @@ def create_template(source_path: pathlib.Path, # when we run the transformation any restricted platforms entries we find will go in here restricted_platform_entries = {} - # Every project will have a unrestricted folder which is src_path_abs which MAY have restricted files in it, and - # each project MAY have a restricted folder which will only have restricted files in them. The process is the + # Every template will have a unrestricted folder which is src_path_abs which MAY have restricted files in it, and + # each template MAY have a restricted folder which will only have restricted files in them. The process is the # same for all of them and the result will be a separation of all restricted files from unrestricted files. We do - # this by running the transformation first over the src path abs and then on each restricted folder for this project - # we find. This will effectively combine all sources then separates all the restricted. + # this by running the transformation first over the src path abs and then on each restricted folder for this + # template we find. This will effectively combine all sources then separates all the restricted. # run the transformation on the src, which may or may not have restricted files _transform_dir_into_copyfiles_and_createdirs(source_path) @@ -950,11 +991,12 @@ def create_template(source_path: pathlib.Path, # run the transformation on each src restricted folder if source_restricted_path: for restricted_platform in os.listdir(source_restricted_path): - restricted_platform_src_path_abs = source_restricted_path / restricted_platform\ - / source_restricted_platform_relative_path / source_name + restricted_platform_src_path_abs = source_restricted_path / restricted_platform \ + / source_restricted_platform_relative_path if os.path.isdir(restricted_platform_src_path_abs): - _transform_restricted_into_copyfiles_and_createdirs(source_path, restricted_platform, - restricted_platform_src_path_abs) + if restricted_platform not in restricted_platform_entries: + restricted_platform_entries.update({restricted_platform: {'copyFiles': [], 'createDirs': []}}) + _transform_restricted_into_copyfiles_and_createdirs(restricted_platform_src_path_abs) # sort copy_files.sort(key=lambda x: x['file']) @@ -972,39 +1014,47 @@ def create_template(source_path: pathlib.Path, json_data.update({'canonical_tags': []}) json_data.update({'user_tags': [f"{template_name}"]}) json_data.update({'icon_path': "preview.png"}) - if template_restricted_path: + if not keep_restricted_in_template and template_restricted_path: json_data.update({'restricted_name': template_restricted_name}) if template_restricted_platform_relative_path != '': - json_data.update({'template_restricted_platform_relative_path': template_restricted_platform_relative_path}) + json_data.update({'template_restricted_platform_relative_path': template_restricted_platform_relative_path.as_posix()}) json_data.update({'copyFiles': copy_files}) json_data.update({'createDirectories': create_dirs}) - json_name = template_path / template_file_name + json_name = template_path / source_restricted_platform_relative_path / 'template.json' with json_name.open('w') as s: s.write(json.dumps(json_data, indent=4) + '\n') # copy the default preview.png preview_png_src = this_script_parent / 'resources' / 'preview.png' - preview_png_dst = template_path / 'Template' / 'preview.png' + preview_png_dst = template_path / 'preview.png' if not os.path.isfile(preview_png_dst): shutil.copy(preview_png_src, preview_png_dst) # if no restricted template path was given and restricted platform files were found - if not template_restricted_path and len(restricted_platform_entries): + if not keep_restricted_in_template and not template_restricted_path and len(restricted_platform_entries): logger.info(f'Restricted platform files found!!! and no template restricted path was found...') - if template_restricted_path: + if not keep_restricted_in_template and template_restricted_path: + json_name = template_restricted_path / 'restricted.json' + if not json_name.is_file(): + json_data = {} + json_data.update({'restricted_name': template_restricted_name}) + os.makedirs(os.path.dirname(json_name), exist_ok=True) + + with json_name.open('w') as s: + s.write(json.dumps(json_data, indent=4) + '\n') + # now write out each restricted platform template json separately for restricted_platform in restricted_platform_entries: - restricted_template_path = template_restricted_path / restricted_platform\ - / template_restricted_platform_relative_path / template_name - + restricted_template_path = template_restricted_path / restricted_platform / template_restricted_platform_relative_path # sort restricted_platform_entries[restricted_platform]['copyFiles'].sort(key=lambda x: x['file']) restricted_platform_entries[restricted_platform]['createDirs'].sort(key=lambda x: x['dir']) json_data = {} + json_data.update({'restricted_name': template_name}) json_data.update({'template_name': template_name}) json_data.update( {'origin': f'The primary repo for {template_name} goes here: i.e. http://www.mydomain.com'}) @@ -1012,23 +1062,25 @@ def create_template(source_path: pathlib.Path, {'license': f'What license {template_name} uses goes here: i.e. https://opensource.org/licenses/MIT'}) json_data.update({'display_name': template_name}) json_data.update({'summary': f"A short description of {template_name}."}) - json_data.update({'canonical_tags': []}) + json_data.update({'canonical_tags': [f'{restricted_platform}']}) json_data.update({'user_tags': [f'{template_name}']}) - json_data.update({'icon_path': "preview.png"}) json_data.update({'copyFiles': restricted_platform_entries[restricted_platform]['copyFiles']}) json_data.update({'createDirectories': restricted_platform_entries[restricted_platform]['createDirs']}) - json_name = restricted_template_path / template_file_name + json_name = restricted_template_path / 'template.json' os.makedirs(os.path.dirname(json_name), exist_ok=True) with json_name.open('w') as s: s.write(json.dumps(json_data, indent=4) + '\n') - preview_png_dst = restricted_template_path / 'Template' /' preview.png' - if not os.path.isfile(preview_png_dst): - shutil.copy(preview_png_src, preview_png_dst) + # Register the restricted + if not no_register: + if register.register(restricted_path=template_restricted_path): + logger.error(f'Failed to register the restricted {template_restricted_path}.') + return 1 - return 0 + # Register the template + return register.register(template_path=template_path) if not no_register else 0 def create_from_template(destination_path: pathlib.Path, @@ -1044,7 +1096,8 @@ def create_from_template(destination_path: pathlib.Path, keep_restricted_in_instance: bool = False, keep_license_text: bool = False, replace: list = None, - force: bool = False) -> int: + force: bool = False, + no_register: bool = False) -> int: """ Generic template instantiation for non o3de object templates. This function makes NO assumptions! Assumptions are made only for specializations like create_project or create_gem etc... So this function @@ -1251,17 +1304,18 @@ def create_from_template(destination_path: pathlib.Path, # destination restricted path elif destination_restricted_path: - if os.path.isabs(destination_restricted_path): + if not os.path.isabs(destination_restricted_path): restricted_default_path = manifest.get_registered(default_folder='restricted') - new_destination_restricted_path = restricted_default_path / destination_restricted_path + new_destination_restricted_path = restricted_default_path / "Templates" / destination_restricted_path logger.info(f'{destination_restricted_path} is not a full path, making it relative' f' to default restricted path = {new_destination_restricted_path}') destination_restricted_path = new_destination_restricted_path - elif template_restricted_path: - restricted_default_path = manifest.get_registered(restricted_name='restricted') - logger.info(f'--destination-restricted-path is not specified, using default restricted path / destination name' - f' = {restricted_default_path}') - destination_restricted_path = restricted_default_path + else: + restricted_default_path = manifest.get_registered(default_folder='restricted') + new_destination_restricted_path = restricted_default_path / "Templates" / destination_name + logger.info(f'--destination-restricted-path is not specified, using default restricted path' + f' / Templates / destination name = {new_destination_restricted_path}') + destination_restricted_path = new_destination_restricted_path # destination restricted relative if not destination_restricted_platform_relative_path: @@ -1306,7 +1360,7 @@ def create_from_template(destination_path: pathlib.Path, if destination_restricted_path: os.makedirs(destination_restricted_path, exist_ok=True) - # read the restricted_name from the destination restricted.json + # write the restricted_name to the destination restricted.json restricted_json = destination_restricted_path / 'restricted.json' if not os.path.isfile(restricted_json): with open(restricted_json, 'w') as s: @@ -1314,6 +1368,12 @@ def create_from_template(destination_path: pathlib.Path, restricted_json_data.update({'restricted_name': destination_name}) s.write(json.dumps(restricted_json_data, indent=4) + '\n') + # Register the restricted + if not no_register: + if register.register(restricted_path=destination_restricted_path): + logger.error(f'Failed to register the restricted {destination_restricted_path}.') + return 1 + logger.warning(f'Instantiation successful. NOTE: This is a generic instantiation of the template. If this' f' was a template of an o3de object like a project, gem, template, etc. then the create-project' f' or create-gem command can be used to register the object type via its project.json or gem.json, etc.' @@ -1364,6 +1424,7 @@ def create_project(project_path: pathlib.Path, Ex. ${Name},TestGem,${Player},TestGemPlayer This will cause all references to ${Name} be replaced by TestGem, and all ${Player} replaced by 'TestGemPlayer' :param force Overrides existing files even if they exist + :param no_register: whether or not after completion that the new object is registered :param system_component_class_id: optionally specify a uuid for the system component class, default is random uuid :param editor_system_component_class_id: optionally specify a uuid for the editor system component class, default is random uuid @@ -1422,12 +1483,10 @@ def create_project(project_path: pathlib.Path, # see if the template itself specifies a restricted name if not template_restricted_name and not template_restricted_path: try: - template_json_restricted_name = template_json_data['restricted_name'] + template_restricted_name = template_json_data['restricted_name'] except KeyError as e: # the template json doesn't have a 'restricted_name' element warn and use it logger.info(f'The template does not specify a "restricted_name".') - else: - template_restricted_name = template_json_restricted_name # if no restricted name or path we continue on as if there is no template restricted files. if template_restricted_name or template_restricted_path: @@ -1523,8 +1582,13 @@ def create_project(project_path: pathlib.Path, if not project_path: logger.error('Project path cannot be empty.') return 1 - project_path = project_path.resolve() + if not os.path.isabs(project_path): + default_projects_folder = manifest.get_registered(default_folder='projects') + new_project_path = default_projects_folder / project_path + logger.info(f'Project Path {project_path} is not a full path, we must assume its relative' + f' to default projects path = {new_project_path}') + project_path = new_project_path if not force and project_path.is_dir() and len(list(project_path.iterdir())): logger.error(f'Project path {project_path} already exists and is not empty.') return 1 @@ -1536,7 +1600,8 @@ def create_project(project_path: pathlib.Path, project_name = os.path.basename(project_path) if not utils.validate_identifier(project_name): - logger.error(f'Project name must be fewer than 64 characters, contain only alphanumeric, "_" or "-" characters, and start with a letter. {project_name}') + logger.error( + f'Project name must be fewer than 64 characters, contain only alphanumeric, "_" or "-" characters, and start with a letter. {project_name}') return 1 # project name cannot be the same as a restricted platform name @@ -1546,21 +1611,19 @@ def create_project(project_path: pathlib.Path, # project restricted name if project_restricted_name and not project_restricted_path: - project_restricted_path = manifest.get_registered(restricted_name=project_restricted_name) + gem_restricted_path = manifest.get_registered(restricted_name=project_restricted_name) + if not gem_restricted_path: + logger.error(f'Project Restricted Name {project_restricted_name} cannot be found.') + return 1 # project restricted path - elif project_restricted_path: + if project_restricted_path: if not os.path.isabs(project_restricted_path): - default_projects_restricted_folder = manifest.get_registered(restricted_name='projects') - new_project_restricted_path = default_projects_restricted_folder/ project_restricted_path - logger.info(f'Project restricted path {project_restricted_path} is not a full path, we must assume its' - f' relative to default projects restricted path = {new_project_restricted_path}') - project_restricted_path = new_project_restricted_path - elif template_restricted_path: - project_restricted_default_path = manifest.get_registered(restricted_name='projects') - logger.info(f'--project-restricted-path is not specified, using default project restricted path / project name' - f' = {project_restricted_default_path}') - project_restricted_path = project_restricted_default_path + logger.error(f'Project Restricted Path {project_restricted_path} is not an absolute path.') + return 1 + # neither put it in the default restricted projects + else: + project_restricted_path = manifest.get_o3de_restricted_folder() / 'Projects' / project_name # project restricted relative path if not project_restricted_platform_relative_path: @@ -1639,7 +1702,7 @@ def create_project(project_path: pathlib.Path, os.makedirs(project_restricted_path, exist_ok=True) # read the restricted_name from the projects restricted.json - restricted_json = project_restricted_path / 'restricted.json' + restricted_json = project_restricted_path / 'restricted.json' if os.path.isfile(restricted_json): if not validation.valid_o3de_restricted_json(restricted_json): logger.error(f'Restricted json {restricted_json} is not valid.') @@ -1663,7 +1726,8 @@ def create_project(project_path: pathlib.Path, logger.error(f'Failed to read "restricted_name" from restricted json {restricted_json}.') return 1 - # set the "restricted_name": "restricted_name" element of the project.json + # set the "restricted": element of the project.json + project_json = project_path / 'project.json' if not validation.valid_o3de_project_json(project_json): logger.error(f'Project json {project_json} is not valid.') return 1 @@ -1675,7 +1739,7 @@ def create_project(project_path: pathlib.Path, logger.error(f'Failed to load project json {project_json}.') return 1 - project_json_data.update({"restricted_name": restricted_name}) + project_json_data.update({"restricted": restricted_name}) os.unlink(project_json) with open(project_json, 'w') as s: try: @@ -1684,20 +1748,11 @@ def create_project(project_path: pathlib.Path, logger.error(f'Failed to write project json {project_json}.') return 1 - for restricted_platform in restricted_platforms: - restricted_project = project_restricted_path / restricted_platform / project_name - os.makedirs(restricted_project, exist_ok=True) - cmakelists_file_name = restricted_project/ 'CMakeLists.txt' - if not os.path.isfile(cmakelists_file_name): - with open(cmakelists_file_name, 'w') as d: - if keep_license_text: - d.write('# {BEGIN_LICENSE}\n') - d.write('# Copyright (c) Contributors to the Open 3D Engine Project.\n') - d.write('# For complete copyright and license terms please see the LICENSE at the root of this distribution.\n') - d.write('#\n') - d.write('# SPDX-License-Identifier: Apache-2.0 OR MIT\n') - d.write('# {END_LICENSE}\n') - + # Register the restricted + if not no_register: + if register.register(restricted_path=project_restricted_path): + logger.error(f'Failed to register the restricted {project_restricted_path}.') + return 1 # Register the project with the either o3de_manifest.json or engine.json # and set the project.json "engine" field to match the @@ -1906,10 +1961,15 @@ def create_gem(gem_path: pathlib.Path, if not gem_path: logger.error('Gem path cannot be empty.') return 1 - gem_path = gem_path.resolve() + if not os.path.isabs(gem_path): + default_gems_folder = manifest.get_registered(default_folder='gems') + new_gem_path = default_gems_folder / gem_path + logger.info(f'Gem Path {gem_path} is not a full path, we must assume its relative' + f' to default gems path = {new_gem_path}') + gem_path = new_gem_path if not force and gem_path.is_dir() and len(list(gem_path.iterdir())): - logger.error(f'Gem path {gem_path} already exists and is not empty.') + logger.error(f'Gem path {gem_path} already exists.') return 1 else: os.makedirs(gem_path, exist_ok=force) @@ -1930,22 +1990,18 @@ def create_gem(gem_path: pathlib.Path, # gem restricted name if gem_restricted_name and not gem_restricted_path: gem_restricted_path = manifest.get_registered(restricted_name=gem_restricted_name) + if not gem_restricted_path: + logger.error(f'Gem Restricted Name {gem_restricted_name} cannot be found.') + return 1 # gem restricted path - elif gem_restricted_path: + if gem_restricted_path: if not os.path.isabs(gem_restricted_path): - gem_restricted_default_path = manifest.get_registered(restricted_name='gems') - if gem_restricted_default_path: - new_gem_restricted_path = gem_restricted_default_path / gem_restricted_path - logger.info(f'Gem restricted path {gem_restricted_path} is not a full path, we must assume its' - f' relative to default gems restricted path = {new_gem_restricted_path}') - gem_restricted_path = new_gem_restricted_path + logger.error(f'Gem Restricted Path {gem_restricted_path} is not an absolute path.') + return 1 + # neither put it in the default restricted gems else: - gem_restricted_default_path = manifest.get_registered(restricted_name='gems') - if gem_restricted_default_path: - logger.info(f'--gem-restricted-path is not specified, using default / ' - f' = {gem_restricted_default_path}') - gem_restricted_path = gem_restricted_default_path / gem_name + gem_restricted_path = manifest.get_o3de_restricted_folder() / "Gems" / gem_name # gem restricted relative if not gem_restricted_platform_relative_path: @@ -2035,47 +2091,49 @@ def create_gem(gem_path: pathlib.Path, logger.error(f'Failed to load restricted json {restricted_json}.') return 1 + try: + restricted_name = restricted_json_data["restricted_name"] + except KeyError as e: + logger.error(f'Failed to read "restricted_name" from restricted json {restricted_json}.') + return 1 + + # set the "restricted_name": element of the gem.json + gem_json = gem_path / 'gem.json' + if not validation.valid_o3de_gem_json(gem_json): + logger.error(f'Gem json {gem_json} is not valid.') + return 1 + + with open(gem_json, 'r') as s: try: - restricted_name = restricted_json_data["restricted_name"] - except KeyError as e: - logger.error(f'Failed to read "restricted_name" from restricted json {restricted_json}.') + gem_json_data = json.load(s) + except json.JSONDecodeError as e: + logger.error(f'Failed to load gem json {gem_json}.') return 1 - # set the "restricted_name": "restricted_name" element of the gem.json - gem_json = gem_path / 'gem.json' - if not validation.valid_o3de_gem_json(gem_json): - logger.error(f'Gem json {gem_json} is not valid.') + gem_json_data.update({"restricted": restricted_name}) + os.unlink(gem_json) + with open(gem_json, 'w') as s: + try: + s.write(json.dumps(gem_json_data, indent=4) + '\n') + except OSError as e: + logger.error(f'Failed to write project json {gem_json}.') + return 1 + ''' + for restricted_platform in restricted_platforms: + restricted_gem = gem_restricted_path / restricted_platform / gem_name + os.makedirs(restricted_gem, exist_ok=True) + cmakelists_file_name = restricted_gem / 'CMakeLists.txt' + if not os.path.isfile(cmakelists_file_name): + with open(cmakelists_file_name, 'w') as d: + if keep_license_text: + d.write(O3DE_LICENSE_TEXT) + ''' + # Register the restricted + if not no_register: + if register.register(restricted_path=gem_restricted_path): + logger.error(f'Failed to register the restricted {gem_restricted_path}.') return 1 - with open(gem_json, 'r') as s: - try: - gem_json_data = json.load(s) - except json.JSONDecodeError as e: - logger.error(f'Failed to load gem json {gem_json}.') - return 1 - - gem_json_data.update({"restricted_name": restricted_name}) - os.unlink(gem_json) - with open(gem_json, 'w') as s: - try: - s.write(json.dumps(gem_json_data, indent=4) + '\n') - except OSError as e: - logger.error(f'Failed to write project json {gem_json}.') - return 1 - - for restricted_platform in restricted_platforms: - restricted_gem = gem_restricted_path / restricted_platform/ gem_name - os.makedirs(restricted_gem, exist_ok=True) - cmakelists_file_name = restricted_gem / 'CMakeLists.txt' - if not os.path.isfile(cmakelists_file_name): - with open(cmakelists_file_name, 'w') as d: - if keep_license_text: - d.write('# {BEGIN_LICENSE}\n') - d.write('# Copyright (c) Contributors to the Open 3D Engine Project.\n') - d.write('# For complete copyright and license terms please see the LICENSE at the root of this distribution.\n') - d.write('#\n') - d.write('# SPDX-License-Identifier: Apache-2.0 OR MIT\n') - d.write('# {END_LICENSE}\n') # Register the gem with the either o3de_manifest.json, engine.json or project.json based on the gem path return register.register(gem_path=gem_path) if not no_register else 0 @@ -2093,7 +2151,8 @@ def _run_create_template(args: argparse) -> int: args.keep_restricted_in_template, args.keep_license_text, args.replace, - args.force) + args.force, + args.no_register) def _run_create_from_template(args: argparse) -> int: @@ -2110,7 +2169,8 @@ def _run_create_from_template(args: argparse) -> int: args.keep_restricted_in_instance, args.keep_license_text, args.replace, - args.force) + args.force, + args.no_register) def _run_create_project(args: argparse) -> int: @@ -2166,7 +2226,6 @@ def add_args(subparsers) -> None: call add_args and execute: python o3de.py create-gem --gem-path TestGem :param subparsers: the caller instantiates subparsers and passes it in here """ - # turn a directory into a template create_template_subparser = subparsers.add_parser('create-template') @@ -2242,7 +2301,10 @@ def add_args(subparsers) -> None: ' Note: is automatically ${NameLower}' ' Note: is automatically ${NameUpper}') create_template_subparser.add_argument('-f', '--force', action='store_true', default=False, - help='Copies to new template directory even if it exist.') + help='Copies to new template directory even if it exist.') + create_template_subparser.add_argument('--no-register', action='store_true', default=False, + help='If the template is created successfully, it will not register the' + ' template with the global or engine manifest file.') create_template_subparser.set_defaults(func=_run_create_template) # create from template @@ -2268,11 +2330,11 @@ def add_args(subparsers) -> None: ' resolve the --template-path.') create_from_template_subparser.add_argument('-dn', '--destination-name', type=str, - help='The name to use when substituting the ${Name} placeholder in instantiated template,' - ' must be alphanumeric, ' - ' and can contain _ and - characters.' - ' If no name is provided, will use last component of destination path.' - ' Ex. New_Gem') + help='The name to use when substituting the ${Name} placeholder in instantiated template,' + ' must be alphanumeric, ' + ' and can contain _ and - characters.' + ' If no name is provided, will use last component of destination path.' + ' Ex. New_Gem') group = create_from_template_subparser.add_mutually_exclusive_group(required=False) group.add_argument('-drp', '--destination-restricted-path', type=pathlib.Path, required=False, @@ -2293,7 +2355,8 @@ def add_args(subparsers) -> None: help='The name of the registered restricted path to read from if any. If supplied this will' ' resolve the --template-restricted-path.') - create_from_template_subparser.add_argument('-drprp', '--destination-restricted-platform-relative-path', type=pathlib.Path, + create_from_template_subparser.add_argument('-drprp', '--destination-restricted-platform-relative-path', + type=pathlib.Path, required=False, default=None, help='Any path to append to the --destination-restricted-path/' @@ -2301,7 +2364,8 @@ def add_args(subparsers) -> None: ' --destination-restricted-path C:/instance' ' --destination-restricted-platform-relative-path some/folder' ' => C:/instance//some/folder/') - create_from_template_subparser.add_argument('-trprp', '--template-restricted-platform-relative-path', type=pathlib.Path, + create_from_template_subparser.add_argument('-trprp', '--template-restricted-platform-relative-path', + type=pathlib.Path, required=False, default=None, help='Any path to append to the --template-restricted-path/' @@ -2329,7 +2393,10 @@ def add_args(subparsers) -> None: ' Note: ${NameLower} is automatically ' ' Note: ${NameUpper} is automatically ') create_from_template_subparser.add_argument('-f', '--force', action='store_true', default=False, - help='Copies over instantiated template directory even if it exist.') + help='Copies over instantiated template directory even if it exist.') + create_from_template_subparser.add_argument('--no-register', action='store_true', default=False, + help='If the project template is instantiated successfully, it will not register the' + ' project with the global or engine manifest file.') create_from_template_subparser.set_defaults(func=_run_create_from_template) # creation of a project from a template (like create from template but makes project assumptions) @@ -2430,10 +2497,10 @@ def add_args(subparsers) -> None: help='The str id you want to associate with the project, default is a random uuid' ' Ex. {b60c92eb-3139-454b-a917-a9d3c5819594}') create_project_subparser.add_argument('-f', '--force', action='store_true', default=False, - help='Copies over instantiated template directory even if it exist.') + help='Copies over instantiated template directory even if it exist.') create_project_subparser.add_argument('--no-register', action='store_true', default=False, - help='If the project template is instantiated successfully, it will not register the' - ' project with the global or engine manifest file.') + help='If the project template is instantiated successfully, it will not register the' + ' project with the global or engine manifest file.') create_project_subparser.set_defaults(func=_run_create_project) # creation of a gem from a template (like create from template but makes gem assumptions) @@ -2445,11 +2512,11 @@ def add_args(subparsers) -> None: create_gem_subparser.add_argument('-gp', '--gem-path', type=pathlib.Path, required=True, help='The gem path, can be absolute or relative to the current working directory') create_gem_subparser.add_argument('-gn', '--gem-name', type=str, - help='The name to use when substituting the ${Name} placeholder for the gem,' - ' must be alphanumeric, ' - ' and can contain _ and - characters.' - ' If no name is provided, will use last component of gem path.' - ' Ex. New_Gem') + help='The name to use when substituting the ${Name} placeholder for the gem,' + ' must be alphanumeric, ' + ' and can contain _ and - characters.' + ' If no name is provided, will use last component of gem path.' + ' Ex. New_Gem') group = create_gem_subparser.add_mutually_exclusive_group(required=False) group.add_argument('-tp', '--template-path', type=pathlib.Path, required=False, @@ -2529,7 +2596,7 @@ def add_args(subparsers) -> None: help='The uuid you want to associate with the gem module,' ' default is a random uuid Ex. {b60c92eb-3139-454b-a917-a9d3c5819594}') create_gem_subparser.add_argument('-f', '--force', action='store_true', default=False, - help='Copies over instantiated template directory even if it exist.') + help='Copies over instantiated template directory even if it exist.') create_gem_subparser.add_argument('--no-register', action='store_true', default=False, help='If the gem template is instantiated successfully, it will not register the' ' gem with the global, project or engine manifest file.') diff --git a/scripts/o3de/o3de/get_registration.py b/scripts/o3de/o3de/get_registration.py index d64056e8b2..1271d56804 100644 --- a/scripts/o3de/o3de/get_registration.py +++ b/scripts/o3de/o3de/get_registration.py @@ -14,9 +14,6 @@ from o3de import manifest def _run_get_registered(args: argparse) -> int: - if args.override_home_folder: - manifest.override_home_folder = args.override_home_folder - registered_path = manifest.get_registered(args.engine_name, args.project_name, args.gem_name, @@ -55,9 +52,6 @@ def add_parser_args(parser): group.add_argument('-rsn', '--restricted-name', type=str, required=False, help='Restricted name.') - parser.add_argument('-ohf', '--override-home-folder', type=str, required=False, - help='By default the home folder is the user folder, override it to this folder.') - parser.set_defaults(func=_run_get_registered) diff --git a/scripts/o3de/o3de/manifest.py b/scripts/o3de/o3de/manifest.py index 7392637c99..88e6ae8229 100644 --- a/scripts/o3de/o3de/manifest.py +++ b/scripts/o3de/o3de/manifest.py @@ -22,18 +22,13 @@ logger = logging.getLogger('o3de.manifest') logging.basicConfig(format=utils.LOG_FORMAT) # Directory methods -override_home_folder = None - def get_this_engine_path() -> pathlib.Path: return pathlib.Path(os.path.realpath(__file__)).parents[3].resolve() def get_home_folder() -> pathlib.Path: - if override_home_folder: - return pathlib.Path(override_home_folder).resolve() - else: - return pathlib.Path(os.path.expanduser("~")).resolve() + return pathlib.Path(os.path.expanduser("~")).resolve() def get_o3de_folder() -> pathlib.Path: @@ -42,12 +37,6 @@ def get_o3de_folder() -> pathlib.Path: return o3de_folder -def get_o3de_user_folder() -> pathlib.Path: - o3de_user_folder = get_home_folder() / 'O3DE' - o3de_user_folder.mkdir(parents=True, exist_ok=True) - return o3de_user_folder - - def get_o3de_registry_folder() -> pathlib.Path: registry_folder = get_o3de_folder() / 'Registry' registry_folder.mkdir(parents=True, exist_ok=True) @@ -73,19 +62,19 @@ def get_o3de_engines_folder() -> pathlib.Path: def get_o3de_projects_folder() -> pathlib.Path: - projects_folder = get_o3de_user_folder() / 'Projects' + projects_folder = get_o3de_folder() / 'Projects' projects_folder.mkdir(parents=True, exist_ok=True) return projects_folder def get_o3de_gems_folder() -> pathlib.Path: - gems_folder = get_o3de_user_folder() / 'Gems' + gems_folder = get_o3de_folder() / 'Gems' gems_folder.mkdir(parents=True, exist_ok=True) return gems_folder def get_o3de_templates_folder() -> pathlib.Path: - templates_folder = get_o3de_user_folder() / 'Templates' + templates_folder = get_o3de_folder() / 'Templates' templates_folder.mkdir(parents=True, exist_ok=True) return templates_folder @@ -117,6 +106,10 @@ def get_default_o3de_manifest_json_data() -> dict: username = os.path.split(get_home_folder())[-1] o3de_folder = get_o3de_folder() + default_registry_folder = get_o3de_registry_folder() + default_cache_folder = get_o3de_cache_folder() + default_downloads_folder = get_o3de_download_folder() + default_logs_folder = get_o3de_logs_folder() default_engines_folder = get_o3de_engines_folder() default_projects_folder = get_o3de_projects_folder() default_gems_folder = get_o3de_gems_folder() @@ -124,12 +117,20 @@ def get_default_o3de_manifest_json_data() -> dict: default_restricted_folder = get_o3de_restricted_folder() default_third_party_folder = get_o3de_third_party_folder() - default_projects_restricted_folder = default_projects_folder / 'Restricted' - default_projects_restricted_folder.mkdir(parents=True, exist_ok=True) - default_gems_restricted_folder = default_gems_folder / 'Restricted' - default_gems_restricted_folder.mkdir(parents=True, exist_ok=True) - default_templates_restricted_folder = default_templates_folder / 'Restricted' - default_templates_restricted_folder.mkdir(parents=True, exist_ok=True) + default_restricted_projects_folder = default_restricted_folder / 'Projects' + default_restricted_projects_folder.mkdir(parents=True, exist_ok=True) + default_restricted_gems_folder = default_restricted_folder / 'Gems' + default_restricted_gems_folder.mkdir(parents=True, exist_ok=True) + default_restricted_engine_folder = default_restricted_folder / 'Engines' / 'o3de' + default_restricted_engine_folder.mkdir(parents=True, exist_ok=True) + default_restricted_templates_folder = default_restricted_folder / 'Templates' + default_restricted_templates_folder.mkdir(parents=True, exist_ok=True) + default_restricted_engine_folder_json = default_restricted_engine_folder / 'restricted.json' + if not default_restricted_engine_folder_json.is_file(): + with default_restricted_engine_folder_json.open('w') as s: + restricted_json_data = {} + restricted_json_data.update({'restricted_name': 'o3de'}) + s.write(json.dumps(restricted_json_data, indent=4) + '\n') json_data = {} json_data.update({'o3de_manifest_name': f'{username}'}) @@ -140,45 +141,14 @@ def get_default_o3de_manifest_json_data() -> dict: json_data.update({'default_templates_folder': default_templates_folder.as_posix()}) json_data.update({'default_restricted_folder': default_restricted_folder.as_posix()}) json_data.update({'default_third_party_folder': default_third_party_folder.as_posix()}) - - json_data.update({'engines': []}) json_data.update({'projects': []}) json_data.update({'external_subdirectories': []}) json_data.update({'templates': []}) - json_data.update({'restricted': []}) + json_data.update({'restricted': [default_restricted_engine_folder.as_posix()]}) json_data.update({'repos': []}) - - default_restricted_folder_json = default_restricted_folder / 'restricted.json' - if not default_restricted_folder_json.is_file(): - with default_restricted_folder_json.open('w') as s: - restricted_json_data = {} - restricted_json_data.update({'restricted_name': 'o3de'}) - s.write(json.dumps(restricted_json_data, indent=4) + '\n') - - default_projects_restricted_folder_json = default_projects_restricted_folder / 'restricted.json' - if not default_projects_restricted_folder_json.is_file(): - with default_projects_restricted_folder_json.open('w') as s: - restricted_json_data = {} - restricted_json_data.update({'restricted_name': 'projects'}) - s.write(json.dumps(restricted_json_data, indent=4) + '\n') - - default_gems_restricted_folder_json = default_gems_restricted_folder / 'restricted.json' - if not default_gems_restricted_folder_json.is_file(): - with default_gems_restricted_folder_json.open('w') as s: - restricted_json_data = {} - restricted_json_data.update({'restricted_name': 'gems'}) - s.write(json.dumps(restricted_json_data, indent=4) + '\n') - - default_templates_restricted_folder_json = default_templates_restricted_folder / 'restricted.json' - if not default_templates_restricted_folder_json.is_file(): - with default_templates_restricted_folder_json.open('w') as s: - restricted_json_data = {} - restricted_json_data.update({'restricted_name': 'templates'}) - s.write(json.dumps(restricted_json_data, indent=4) + '\n') - + json_data.update({'engines': []}) return json_data - def get_o3de_manifest() -> pathlib.Path: manifest_path = get_o3de_folder() / 'o3de_manifest.json' if not manifest_path.is_file(): @@ -229,12 +199,12 @@ def save_o3de_manifest(json_data: dict, manifest_path: pathlib.Path = None) -> b return False -def get_gems_from_subdirectories(external_subdirs: list) -> list: - """ +def get_gems_from_external_subdirectories(external_subdirs: list) -> list: + ''' Helper Method for scanning a set of external subdirectories for gem.json files - """ + ''' def is_gem_subdirectory(subdir_files): - for name in subdir_files: + for name in files: if name == 'gem.json': return True return False @@ -250,7 +220,8 @@ def get_gems_from_subdirectories(external_subdirs: list) -> list: return gem_directories -def get_engines() -> list: +# Data query methods +def get_manifest_engines() -> list: json_data = load_o3de_manifest() engine_list = json_data['engines'] if 'engines' in json_data else [] # Convert each engine dict entry into a string entry @@ -259,31 +230,31 @@ def get_engines() -> list: engine_list)) -def get_projects() -> list: +def get_manifest_projects() -> list: json_data = load_o3de_manifest() return json_data['projects'] if 'projects' in json_data else [] -def get_gems() -> list: - return get_gems_from_subdirectories(get_external_subdirectories()) +def get_manifest_gems() -> list: + return get_gems_from_external_subdirectories(get_manifest_external_subdirectories()) -def get_external_subdirectories() -> list: +def get_manifest_external_subdirectories() -> list: json_data = load_o3de_manifest() return json_data['external_subdirectories'] if 'external_subdirectories' in json_data else [] -def get_templates() -> list: +def get_manifest_templates() -> list: json_data = load_o3de_manifest() return json_data['templates'] if 'templates' in json_data else [] -def get_restricted() -> list: +def get_manifest_restricted() -> list: json_data = load_o3de_manifest() return json_data['restricted'] if 'restricted' in json_data else [] -def get_repos() -> list: +def get_manifest_repos() -> list: json_data = load_o3de_manifest() return json_data['repos'] if 'repos' in json_data else [] @@ -299,7 +270,7 @@ def get_engine_projects() -> list: def get_engine_gems() -> list: - return get_gems_from_subdirectories(get_engine_external_subdirectories()) + return get_gems_from_external_subdirectories(get_engine_external_subdirectories()) def get_engine_external_subdirectories() -> list: @@ -320,23 +291,9 @@ def get_engine_templates() -> list: return [] -def get_engine_restricted() -> list: - engine_path = get_this_engine_path() - engine_object = get_engine_json_data(engine_path=engine_path) - if engine_object: - return list(map(lambda rel_path: (pathlib.Path(engine_path) / rel_path).as_posix(), - engine_object['restricted'])) if 'restricted' in engine_object else [] - return [] - - # project.json queries -def get_project_engine_name(project_path: pathlib.Path) -> str or None: - project_object = get_project_json_data(project_path=project_path) - return project_object.get('engine', None) if project_object else None - - def get_project_gems(project_path: pathlib.Path) -> list: - return get_gems_from_subdirectories(get_project_external_subdirectories(project_path)) + return get_gems_from_external_subdirectories(get_project_external_subdirectories(project_path)) def get_project_external_subdirectories(project_path: pathlib.Path) -> list: @@ -355,74 +312,95 @@ def get_project_templates(project_path: pathlib.Path) -> list: return [] -def get_project_restricted(project_path: pathlib.Path) -> list: - project_object = get_project_json_data(project_path=project_path) - if project_object: - return list(map(lambda rel_path: (pathlib.Path(project_path) / rel_path).as_posix(), - project_object['restricted'])) if 'restricted' in project_object else [] +# gem.json queries +def get_gem_gems(gem_path: pathlib.Path) -> list: + return get_gems_from_external_subdirectories(get_gem_external_subdirectories(gem_path)) + + +def get_gem_external_subdirectories(gem_path: pathlib.Path) -> list: + gem_object = get_gem_json_data(gem_path=gem_path) + if gem_object: + return list(map(lambda rel_path: (pathlib.Path(gem_path) / rel_path).as_posix(), + gem_object[ + 'external_subdirectories'])) if 'external_subdirectories' in gem_object else [] + return [] + + +def get_gem_templates(gem_path: pathlib.Path) -> list: + gem_object = get_gem_json_data(gem_path=gem_path) + if gem_object: + return list(map(lambda rel_path: (pathlib.Path(gem_path) / rel_path).as_posix(), + gem_object['templates'])) if 'templates' in gem_object else [] return [] # Combined manifest queries def get_all_projects() -> list: - projects_data = get_projects() + projects_data = get_manifest_projects() projects_data.extend(get_engine_projects()) # Remove duplicates from the list return list(dict.fromkeys(projects_data)) def get_all_gems(project_path: pathlib.Path = None) -> list: - gems_data = get_gems() - gems_data.extend(get_engine_gems()) - if project_path: - gems_data.extend(get_project_gems(project_path)) - return list(dict.fromkeys(gems_data)) + return get_gems_from_external_subdirectories(get_all_external_subdirectories(project_path)) def get_all_external_subdirectories(project_path: pathlib.Path = None) -> list: - external_subdirectories_data = get_external_subdirectories() + external_subdirectories_data = get_manifest_external_subdirectories() external_subdirectories_data.extend(get_engine_external_subdirectories()) if project_path: external_subdirectories_data.extend(get_project_external_subdirectories(project_path)) + + def descend_gems(gem_path: pathlib.Path): + new_external_subdirectories_data = get_gem_external_subdirectories(gem_path) + external_subdirectories_data.extend(new_external_subdirectories_data) + new_gems_data = get_gems_from_external_subdirectories(new_external_subdirectories_data) + for new_gem in new_gems_data: + descend_gems(new_gem) + + gems_data = get_gems_from_external_subdirectories(external_subdirectories_data) + for gem in gems_data: + descend_gems(gem) + + # Remove duplicates from the list return list(dict.fromkeys(external_subdirectories_data)) def get_all_templates(project_path: pathlib.Path = None) -> list: - templates_data = get_templates() + templates_data = get_manifest_templates() templates_data.extend(get_engine_templates()) if project_path: templates_data.extend(get_project_templates(project_path)) - return list(dict.fromkeys(templates_data)) + gems_data = get_all_gems(project_path) + for gem_path in gems_data: + templates_data.extend(get_gem_templates(gem_path)) -def get_all_restricted(project_path: pathlib.Path = None) -> list: - restricted_data = get_restricted() - restricted_data.extend(get_engine_restricted()) - if project_path: - restricted_data.extend(get_project_restricted(project_path)) - return list(dict.fromkeys(restricted_data)) + # Remove duplicates from the list + return list(dict.fromkeys(templates_data)) # Template functions -def get_templates_for_project_creation(): +def get_templates_for_project_creation(project_path: pathlib.Path = None) -> list: project_templates = [] - for template_path in get_all_templates(): + for template_path in get_all_templates(project_path): template_path = pathlib.Path(template_path) - template_json_path = pathlib.Path(template_path) / 'template.json' + template_json_path = template_path / 'template.json' if not validation.valid_o3de_template_json(template_json_path): continue - project_json_path = template_path / 'Template' / 'project.json' if validation.valid_o3de_project_json(project_json_path): project_templates.append(template_path) + return project_templates -def get_templates_for_gem_creation(): +def get_templates_for_gem_creation(project_path: pathlib.Path = None) -> list: gem_templates = [] - for template_path in get_all_templates(): + for template_path in get_all_templates(project_path): template_path = pathlib.Path(template_path) - template_json_path = pathlib.Path(template_path) / 'template.json' + template_json_path = template_path / 'template.json' if not validation.valid_o3de_template_json(template_json_path): continue @@ -432,72 +410,55 @@ def get_templates_for_gem_creation(): return gem_templates -def get_templates_for_generic_creation(): # temporary until we have a better way to do this... maybe template_type element - def filter_project_and_gem_templates_out(template_path, - templates_for_project_creation = get_templates_for_project_creation(), - templates_for_gem_creation = get_templates_for_gem_creation()): +def get_templates_for_generic_creation(project_path: pathlib.Path = None) -> list: + generic_templates = [] + for template_path in get_all_templates(project_path): template_path = pathlib.Path(template_path) - return template_path not in templates_for_project_creation and template_path not in templates_for_gem_creation + template_json_path = template_path / 'template.json' + if not validation.valid_o3de_template_json(template_json_path): + continue + gem_json_path = template_path / 'Template' / 'gem.json' + project_json_path = template_path / 'Template' / 'project.json' + if not validation.valid_o3de_gem_json(gem_json_path) and\ + not validation.valid_o3de_project_json(project_json_path): + generic_templates.append(template_path) - return list(filter(filter_project_and_gem_templates_out, get_all_templates())) + return generic_templates -def get_json_file_path(object_typename: str, - object_path: str or pathlib.Path) -> pathlib.Path: - if not object_typename or not object_path: - logger.error('Must specify an object typename and object path.') +def get_engine_json_data(engine_name: str = None, + engine_path: str or pathlib.Path = None) -> dict or None: + if not engine_name and not engine_path: + logger.error('Must specify either a Engine name or Engine Path.') return None - object_path = pathlib.Path(object_path).resolve() - return object_path / f'{object_typename}.json' - + if engine_name and not engine_path: + engine_path = get_registered(engine_name=engine_name) -def get_json_data_file(object_json: pathlib.Path, - object_typename: str, - object_validator: callable) -> dict or None: - if not object_typename: - logger.error('Missing object typename.') + if not engine_path: + logger.error(f'Engine Path {engine_path} has not been registered.') return None - if not object_json or not object_json.is_file(): - logger.error(f'Invalid {object_typename} json {object_json} supplied or file missing.') + engine_path = pathlib.Path(engine_path).resolve() + engine_json = engine_path / 'engine.json' + if not engine_json.is_file(): + logger.error(f'Engine json {engine_json} is not present.') return None - - if not object_validator or not object_validator(object_json): - logger.error(f'{object_typename} json {object_json} is not valid or could not be validated.') + if not validation.valid_o3de_engine_json(engine_json): + logger.error(f'Engine json {engine_json} is not valid.') return None - with object_json.open('r') as f: + with engine_json.open('r') as f: try: - object_json_data = json.load(f) + engine_json_data = json.load(f) except json.JSONDecodeError as e: - logger.warning(f'{object_json} failed to load: {e}') + logger.warning(f'{engine_json} failed to load: {str(e)}') else: - return object_json_data + return engine_json_data return None -def get_json_data(object_typename: str, - object_path: str or pathlib.Path, - object_validator: callable) -> dict or None: - object_json = get_json_file_path(object_typename, object_path) - - return get_json_data_file(object_json, object_typename, object_validator) - - -def get_engine_json_data(engine_name: str = None, - engine_path: str or pathlib.Path = None) -> dict or None: - if not engine_name and not engine_path: - logger.error('Must specify either a Engine name or Engine Path.') - return None - - if engine_name and not engine_path: - engine_path = get_registered(engine_name=engine_name) - - return get_json_data('engine', engine_path, validation.valid_o3de_engine_json) - - def get_project_json_data(project_name: str = None, project_path: str or pathlib.Path = None) -> dict or None: if not project_name and not project_path: @@ -507,7 +468,28 @@ def get_project_json_data(project_name: str = None, if project_name and not project_path: project_path = get_registered(project_name=project_name) - return get_json_data('project', project_path, validation.valid_o3de_project_json) + if not project_path: + logger.error(f'Project Path {project_path} has not been registered.') + return None + + project_path = pathlib.Path(project_path).resolve() + project_json = project_path / 'project.json' + if not project_json.is_file(): + logger.error(f'Project json {project_json} is not present.') + return None + if not validation.valid_o3de_project_json(project_json): + logger.error(f'Project json {project_json} is not valid.') + return None + + with project_json.open('r') as f: + try: + project_json_data = json.load(f) + except json.JSONDecodeError as e: + logger.warning(f'{project_json} failed to load: {str(e)}') + else: + return project_json_data + + return None def get_gem_json_data(gem_name: str = None, gem_path: str or pathlib.Path = None, @@ -519,10 +501,28 @@ def get_gem_json_data(gem_name: str = None, gem_path: str or pathlib.Path = None if gem_name and not gem_path: gem_path = get_registered(gem_name=gem_name, project_path=project_path) - if pathlib.Path(gem_path).is_file(): - return get_json_data_file(gem_path, 'gem', validation.valid_o3de_gem_json) - else: - return get_json_data('gem', gem_path, validation.valid_o3de_gem_json) + if not gem_path: + logger.error(f'Gem Path {gem_path} has not been registered.') + return None + + gem_path = pathlib.Path(gem_path).resolve() + gem_json = gem_path / 'gem.json' + if not gem_json.is_file(): + logger.error(f'Gem json {gem_json} is not present.') + return None + if not validation.valid_o3de_gem_json(gem_json): + logger.error(f'Gem json {gem_json} is not valid.') + return None + + with gem_json.open('r') as f: + try: + gem_json_data = json.load(f) + except json.JSONDecodeError as e: + logger.warning(f'{gem_json} failed to load: {str(e)}') + else: + return gem_json_data + + return None def get_template_json_data(template_name: str = None, template_path: str or pathlib.Path = None, @@ -534,7 +534,28 @@ def get_template_json_data(template_name: str = None, template_path: str or path if template_name and not template_path: template_path = get_registered(template_name=template_name, project_path=project_path) - return get_json_data('template', template_path, validation.valid_o3de_template_json) + if not template_path: + logger.error(f'Template Path {template_path} has not been registered.') + return None + + template_path = pathlib.Path(template_path).resolve() + template_json = template_path / 'template.json' + if not template_json.is_file(): + logger.error(f'Template json {template_json} is not present.') + return None + if not validation.valid_o3de_template_json(template_json): + logger.error(f'Template json {template_json} is not valid.') + return None + + with template_json.open('r') as f: + try: + template_json_data = json.load(f) + except json.JSONDecodeError as e: + logger.warning(f'{template_json} failed to load: {str(e)}') + else: + return template_json_data + + return None def get_restricted_json_data(restricted_name: str = None, restricted_path: str or pathlib.Path = None, @@ -546,26 +567,28 @@ def get_restricted_json_data(restricted_name: str = None, restricted_path: str o if restricted_name and not restricted_path: restricted_path = get_registered(restricted_name=restricted_name, project_path=project_path) - return get_json_data('restricted', restricted_path, validation.valid_o3de_restricted_json) - - -def get_repo_json_data(repo_uri: str) -> dict or None: - if not repo_uri: - logger.error('Must specify a Repo Uri.') + if not restricted_path: + logger.error(f'Restricted Path {restricted_path} has not been registered.') return None - repo_json = get_repo_path(repo_uri=repo_uri) - - return get_json_data_file(repo_json, "Repo", validation.valid_o3de_repo_json) - + restricted_path = pathlib.Path(restricted_path).resolve() + restricted_json = restricted_path / 'restricted.json' + if not restricted_json.is_file(): + logger.error(f'Restricted json {restricted_json} is not present.') + return None + if not validation.valid_o3de_restricted_json(restricted_json): + logger.error(f'Restricted json {restricted_json} is not valid.') + return None -def get_repo_path(repo_uri: str, cache_folder: str or pathlib.Path = None) -> pathlib.Path: - if not cache_folder: - cache_folder = get_o3de_cache_folder() + with restricted_json.open('r') as f: + try: + restricted_json_data = json.load(f) + except json.JSONDecodeError as e: + logger.warning(f'{restricted_json} failed to load: {str(e)}') + else: + return restricted_json_data - repo_manifest = f'{repo_uri}/repo.json' - repo_sha256 = hashlib.sha256(repo_manifest.encode()) - return cache_folder / str(repo_sha256.hexdigest() + '.json') + return None def get_registered(engine_name: str = None, @@ -604,7 +627,7 @@ def get_registered(engine_name: str = None, # check global first then this engine if isinstance(engine_name, str): - engines = get_engines() + engines = get_manifest_engines() for engine in engines: if isinstance(engine, dict): engine_path = pathlib.Path(engine['path']).resolve() @@ -624,78 +647,69 @@ def get_registered(engine_name: str = None, this_engines_name = engine_json_data['engine_name'] if this_engines_name == engine_name: return engine_path + engines_path = json_data.get('engines_path', {}) + if engine_name in engines_path: + return pathlib.Path(engines_path[engine_name]).resolve() elif isinstance(project_name, str): projects = get_all_projects() for project_path in projects: project_path = pathlib.Path(project_path).resolve() project_json = project_path / 'project.json' - if not pathlib.Path(project_json).is_file(): - logger.warning(f'{project_json} does not exist') - else: - with project_json.open('r') as f: - try: - project_json_data = json.load(f) - except json.JSONDecodeError as e: - logger.warning(f'{project_json} failed to load: {str(e)}') - else: - this_projects_name = project_json_data['project_name'] - if this_projects_name == project_name: - return project_path + with project_json.open('r') as f: + try: + project_json_data = json.load(f) + except json.JSONDecodeError as e: + logger.warning(f'{project_json} failed to load: {str(e)}') + else: + this_projects_name = project_json_data['project_name'] + if this_projects_name == project_name: + return project_path elif isinstance(gem_name, str): gems = get_all_gems(project_path) for gem_path in gems: gem_path = pathlib.Path(gem_path).resolve() gem_json = gem_path / 'gem.json' - if not pathlib.Path(gem_json).is_file(): - logger.warning(f'{gem_json} does not exist') - else: - with gem_json.open('r') as f: - try: - gem_json_data = json.load(f) - except json.JSONDecodeError as e: - logger.warning(f'{gem_json} failed to load: {str(e)}') - else: - this_gems_name = gem_json_data['gem_name'] - if this_gems_name == gem_name: - return gem_path + with gem_json.open('r') as f: + try: + gem_json_data = json.load(f) + except json.JSONDecodeError as e: + logger.warning(f'{gem_json} failed to load: {str(e)}') + else: + this_gems_name = gem_json_data['gem_name'] + if this_gems_name == gem_name: + return gem_path elif isinstance(template_name, str): templates = get_all_templates(project_path) for template_path in templates: template_path = pathlib.Path(template_path).resolve() template_json = template_path / 'template.json' - if not pathlib.Path(template_json).is_file(): - logger.warning(f'{template_json} does not exist') - else: - with template_json.open('r') as f: - try: - template_json_data = json.load(f) - except json.JSONDecodeError as e: - logger.warning(f'{template_path} failed to load: {str(e)}') - else: - this_templates_name = template_json_data['template_name'] - if this_templates_name == template_name: - return template_path + with template_json.open('r') as f: + try: + template_json_data = json.load(f) + except json.JSONDecodeError as e: + logger.warning(f'{template_path} failed to load: {str(e)}') + else: + this_templates_name = template_json_data['template_name'] + if this_templates_name == template_name: + return template_path elif isinstance(restricted_name, str): - restricted = get_all_restricted(project_path) + restricted = get_manifest_restricted() for restricted_path in restricted: restricted_path = pathlib.Path(restricted_path).resolve() restricted_json = restricted_path / 'restricted.json' - if not pathlib.Path(restricted_json).is_file(): - logger.warning(f'{restricted_json} does not exist') - else: - with restricted_json.open('r') as f: - try: - restricted_json_data = json.load(f) - except json.JSONDecodeError as e: - logger.warning(f'{restricted_json} failed to load: {str(e)}') - else: - this_restricted_name = restricted_json_data['restricted_name'] - if this_restricted_name == restricted_name: - return restricted_path + with restricted_json.open('r') as f: + try: + restricted_json_data = json.load(f) + except json.JSONDecodeError as e: + logger.warning(f'{restricted_json} failed to load: {str(e)}') + else: + this_restricted_name = restricted_json_data['restricted_name'] + if this_restricted_name == restricted_name: + return restricted_path elif isinstance(default_folder, str): if default_folder == 'engines': @@ -717,7 +731,9 @@ def get_registered(engine_name: str = None, elif isinstance(repo_name, str): cache_folder = get_o3de_cache_folder() for repo_uri in json_data['repos']: - cache_file = get_repo_path(repo_uri=repo_uri, cache_folder=cache_folder) + repo_uri = pathlib.Path(repo_uri).resolve() + repo_sha256 = hashlib.sha256(repo_uri.encode()) + cache_file = cache_folder / str(repo_sha256.hexdigest() + '.json') if cache_file.is_file(): repo = pathlib.Path(cache_file).resolve() with repo.open('r') as f: diff --git a/scripts/o3de/o3de/print_registration.py b/scripts/o3de/o3de/print_registration.py index 77e098d0ba..2bd3202ca0 100644 --- a/scripts/o3de/o3de/print_registration.py +++ b/scripts/o3de/o3de/print_registration.py @@ -39,69 +39,68 @@ def get_project_path(project_path: pathlib.Path, project_name: str) -> pathlib.P return project_path -def print_this_engine(verbose: int) -> int: +def print_this_engine(verbose: int = 0) -> int: this_engine_path = manifest.get_this_engine_path() print(f'This Engine:\n{json.dumps(str(this_engine_path), indent=4)}') if verbose > 0: return print_manifest_json_data([this_engine_path], 'This Engine', - manifest.get_engine_json_data, 'engine_path') + manifest.get_engine_json_data, 'engine_path') return 0 -def print_engines(verbose: int) -> None: - engines_data = manifest.get_engines() +def print_engines(verbose: int = 0) -> int: + engines_data = manifest.get_manifest_engines() print(f'Engine Paths:\n{json.dumps(engines_data, indent=4)}') if verbose > 0: return print_manifest_json_data(engines_data, 'Engine Jsons', - manifest.get_engine_json_data, 'engine_path') + manifest.get_engine_json_data, 'engine_path') return 0 -def print_projects(verbose: int) -> int: - projects_data = manifest.get_projects() +def print_projects(verbose: int = 0) -> int: + projects_data = manifest.get_all_projects() print(f'Project Paths:\n{json.dumps(projects_data, indent=4)}') if verbose > 0: return print_manifest_json_data(projects_data, 'Project Jsons', - manifest.get_project_json_data, 'project_path') + manifest.get_project_json_data, 'project_path') return 0 -def print_gems(verbose: int) -> int: - gems_data = manifest.get_gems() +def print_gems(verbose: int = 0) -> int: + gems_data = manifest.get_all_gems() print(f'Gem Paths:\n{json.dumps(gems_data, indent=4)}') if verbose > 0: return print_manifest_json_data(gems_data, 'Gem Jsons', - manifest.get_gem_json_data, 'gem_path') + manifest.get_gem_json_data, 'gem_path') return 0 -def print_external_subdirectories(verbose: int) -> int: - external_subdirs_data = manifest.get_external_subdirectories() +def print_external_subdirectories(verbose: int = 0) -> int: + external_subdirs_data = manifest.get_all_external_subdirectories() print(f'External Subdirectories:\n{json.dumps(external_subdirs_data, indent=4)}') return 0 - def print_templates(verbose: int) -> int: - templates_data = manifest.get_templates() + templates_data = manifest.get_all_templates() print(f'Template Paths:\n{json.dumps(templates_data, indent=4)}') if verbose > 0: return print_manifest_json_data(templates_data, 'Template Jsons', - manifest.get_template_json_data, 'template_path') + manifest.get_template_json_data, 'template_path') return 0 def print_restricted(verbose: int) -> int: - restricted_data = manifest.get_restricted() + restricted_data = manifest.get_manifest_restricted() print(f'Restricted Paths:\n{json.dumps(restricted_data, indent=4)}') if verbose > 0: return print_manifest_json_data(restricted_data, 'Restricted Jsons', - manifest.get_restricted_json_data, 'restricted_path') + manifest.get_restricted_json_data, 'restricted_path') return 0 @@ -112,7 +111,7 @@ def print_engine_projects(verbose: int) -> int: if verbose > 0: return print_manifest_json_data(engine_projects_data, 'Project Jsons', - manifest.get_project_json_data, 'project_path') + manifest.get_project_json_data, 'project_path') return 0 @@ -122,7 +121,7 @@ def print_engine_gems(verbose: int) -> int: if verbose > 0: return print_manifest_json_data(engine_gems_data, 'Gem Jsons', - manifest.get_gem_json_data, 'gem_path') + manifest.get_gem_json_data, 'gem_path') return 0 @@ -132,17 +131,7 @@ def print_engine_templates(verbose: int) -> int: if verbose > 0: return print_manifest_json_data(engine_templates_data, 'Template Jsons', - manifest.get_template_json_data, 'template_path') - return 0 - - -def print_engine_restricted(verbose: int) -> int: - engine_restricted_data = manifest.get_engine_restricted() - print(f'Restricted Paths:\n{json.dumps(engine_restricted_data, indent=4)}') - - if verbose > 0: - return print_manifest_json_data(engine_restricted_data, 'Restricted Jsons', - manifest.get_restricted_json_data, 'restricted_path') + manifest.get_template_json_data, 'template_path') return 0 @@ -153,21 +142,6 @@ def print_engine_external_subdirectories(verbose: int) -> int: # Project output methods -def print_project_engine_name(verbose: int, project_path: pathlib.Path, project_name: str) -> int: - project_path = get_project_path(project_path, project_name) - if not project_path: - return 1 - - engine_name = manifest.get_project_engine_name(project_path) - if engine_name: - print(f'Project\'s engine name:\n{engine_name}') - return 0 - - if verbose > 0: - logger.info(f'project.json at path "{project_path}" contains no registered "engine" field') - return 1 - - def print_project_gems(verbose: int, project_path: pathlib.Path, project_name: str) -> int: project_path = get_project_path(project_path, project_name) if not project_path: @@ -178,7 +152,7 @@ def print_project_gems(verbose: int, project_path: pathlib.Path, project_name: s if verbose > 0: return print_manifest_json_data(project_gems_data, 'Gems Jsons', - manifest.get_gem_json_data, 'gem_path') + manifest.get_gem_json_data, 'gem_path') return 0 @@ -201,20 +175,7 @@ def print_project_templates(verbose: int, project_path: pathlib.Path, project_na print(f'Template Paths:\n{json.dumps(project_templates_data, indent=4)}') if verbose > 0: return print_manifest_json_data(project_templates_data, 'Template Jsons', - manifest.get_template_json_data, 'template_path') - return 0 - - -def print_project_restricted(verbose: int, project_path: pathlib.Path, project_name: str) -> int: - project_path = get_project_path(project_path, project_name) - if not project_path: - return 1 - - project_restricted_data = manifest.get_project_restricted(project_path) - print(f'Restricted Paths:\n{json.dumps(project_restricted_data, indent=4)}') - if verbose > 0: - return print_manifest_json_data(project_restricted_data, 'Restricted Jsons', - manifest.get_restricted_json_data, 'restricted_path') + manifest.get_template_json_data, 'template_path') return 0 @@ -224,12 +185,12 @@ def print_all_projects(verbose: int) -> int: if verbose > 0: return print_manifest_json_data(all_projects_data, 'Project Jsons', - manifest.get_project_json_data, 'project_path') + manifest.get_project_json_data, 'project_path') return 0 def print_all_gems(verbose: int, project_path: pathlib.Path = None, project_name: str = None) -> int: - all_gems = manifest.get_gems() + all_gems = manifest.get_manifest_gems() all_gems.extend(manifest.get_engine_gems()) # If a project path or project name is supplied query the gems from that project, otherwise query the gems from @@ -245,12 +206,12 @@ def print_all_gems(verbose: int, project_path: pathlib.Path = None, project_name if verbose > 0: return print_manifest_json_data(all_gems, 'Gem Jsons', - manifest.get_gem_json_data, 'gem_path') + manifest.get_gem_json_data, 'gem_path') return 0 def print_all_external_subdirectories(verbose: int, project_path: pathlib.Path = None, project_name: str = None) -> int: - all_external_subdirectories = manifest.get_external_subdirectories() + all_external_subdirectories = manifest.get_manifest_external_subdirectories() all_external_subdirectories.extend(manifest.get_engine_external_subdirectories()) # If a project path or project name is supplied query the external subdirectories from that project, @@ -267,7 +228,7 @@ def print_all_external_subdirectories(verbose: int, project_path: pathlib.Path = def print_all_templates(verbose: int, project_path: pathlib.Path = None, project_name: str = None) -> int: - all_templates = manifest.get_templates() + all_templates = manifest.get_manifest_templates() all_templates.extend(manifest.get_engine_templates()) # If a project path or project name is supplied query the templates from that project, @@ -283,31 +244,9 @@ def print_all_templates(verbose: int, project_path: pathlib.Path = None, project if verbose > 0: return print_manifest_json_data(all_templates, 'Template Jsons', - manifest.get_template_json_data, 'template_path') - return 0 - - -def print_all_restricted(verbose: int, project_path: pathlib.Path = None, project_name: str = None) -> int: - all_restricted = manifest.get_restricted() - all_restricted.extend(manifest.get_engine_restricted()) - - # If a project path or project name is supplied query the restricted from that project, - # otherwise query the restricted from all projects - project_path = get_project_path(project_path, project_name) if project_path or project_name else None - projects = [project_path] if project_path else manifest.get_all_projects() - for project in projects: - all_restricted.extend(manifest.get_project_restricted(project)) - - # Filter out duplicates - all_restricted = list(dict.fromkeys(all_restricted)) - print(f'Restricted Paths:\n{json.dumps(all_restricted, indent=4)}') - - if verbose > 0: - return print_manifest_json_data(all_restricted, 'Restricted Jsons', - manifest.get_restricted_json_data, 'restricted_path') + manifest.get_template_json_data, 'template_path') return 0 - def print_manifest_json_data(uri_json_data: list, print_prefix: str, get_json_func: callable, get_json_data_kw: str) -> int: print('\n') @@ -351,7 +290,7 @@ def print_repos_data(repos_data: dict) -> int: def print_repos(verbose: int) -> int: - repos_data = manifest.get_repos() + repos_data = manifest.get_manifest_repos() print(json.dumps(repos_data, indent=4)) if verbose > 0: @@ -370,16 +309,13 @@ def register_show(verbose: int, project_path: pathlib.Path = None, project_name: result = print_all_projects(verbose) or result result = print_all_gems(verbose, project_path, project_name) or result result = print_all_templates(verbose, project_path, project_name) or result - result = print_all_restricted(verbose, project_path, project_name) or result + result = print_restricted(verbose) or result result = print_repos(verbose) or result return result def _run_register_show(args: argparse) -> int: - if args.override_home_folder: - manifest.override_home_folder = args.override_home_folder - if args.this_engine: return print_this_engine(args.verbose) elif args.engines: @@ -393,7 +329,7 @@ def _run_register_show(args: argparse) -> int: elif args.templates: return print_templates(args.verbose) elif args.repos: - return register_show_repos(args.verbose) + return print_repos(args.verbose) elif args.restricted: return print_restricted(args.verbose) @@ -405,8 +341,6 @@ def _run_register_show(args: argparse) -> int: return print_engine_external_subdirectories(args.verbose) elif args.engine_templates: return print_engine_templates(args.verbose) - elif args.engine_restricted: - return print_engine_restricted(args.verbose) elif args.project_gems: return print_project_gems(args.verbose, args.project_path, args.project_name) @@ -414,8 +348,6 @@ def _run_register_show(args: argparse) -> int: return print_project_external_subdirectories(args.verbose, args.project_path, args.project_name) elif args.project_templates: return print_project_templates(args.verbose, args.project_path, args.project_name) - elif args.project_restricted: - return print_project_restricted(args.verbose, args.project_path, args.project_name) elif args.project_engine_name: return print_project_engine_name(args.verbose, args.project_path, args.project_name) @@ -427,8 +359,6 @@ def _run_register_show(args: argparse) -> int: return print_all_external_subdirectories(args.verbose, args.project_path, args.project_name) elif args.all_templates: return print_all_templates(args.verbose, args.project_path, args.project_name) - elif args.all_restricted: - return print_all_restricted(args.verbose, args.project_path, args.project_name) else: return register_show(args.verbose, args.project_path, args.project_name) @@ -538,9 +468,6 @@ def add_parser_args(parser): project_group.add_argument('-pn', '--project-name', type=str, help='The name of a project.') - parser.add_argument('-ohf', '--override-home-folder', type=str, required=False, - help='By default the home folder is the user folder, override it to this folder.') - parser.set_defaults(func=_run_register_show) diff --git a/scripts/o3de/o3de/register.py b/scripts/o3de/o3de/register.py index a175104997..926c413521 100644 --- a/scripts/o3de/o3de/register.py +++ b/scripts/o3de/o3de/register.py @@ -490,7 +490,7 @@ def register_repo(json_data: dict, repo_sha256 = hashlib.sha256(url.encode()) cache_file = manifest.get_o3de_cache_folder() / str(repo_sha256.hexdigest() + '.json') - result = utils.download_file(parsed_uri, cache_file, True) + result = utils.download_file(url, cache_file, True) if result == 0: json_data.setdefault('repos', []).insert(0, repo_uri) @@ -793,9 +793,6 @@ def register(engine_path: pathlib.Path = None, def _run_register(args: argparse) -> int: - if args.override_home_folder: - manifest.override_home_folder = args.override_home_folder - if args.update: remove_invalid_o3de_objects() return repo.refresh_repos() @@ -891,8 +888,6 @@ def add_parser_args(parser): default=False, help='Refresh the repo cache.') - parser.add_argument('-ohf', '--override-home-folder', type=pathlib.Path, required=False, - help='By default the home folder is the user folder, override it to this folder.') parser.add_argument('-r', '--remove', action='store_true', required=False, default=False, help='Remove entry.') diff --git a/scripts/o3de/tests/unit_test_enable_gem.py b/scripts/o3de/tests/unit_test_enable_gem.py index c765f74731..8067fc329d 100644 --- a/scripts/o3de/tests/unit_test_enable_gem.py +++ b/scripts/o3de/tests/unit_test_enable_gem.py @@ -42,8 +42,10 @@ TEST_GEM_JSON_PAYLOAD = ''' { "gem_name": "TestGem", "display_name": "TestGem", - "license": "What license TestGem uses goes here: i.e. https://opensource.org/licenses/MIT", - "origin": "The primary repo for TestGem goes here: i.e. http://www.mydomain.com", + "license": "Apache-2.0 Or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", + "origin": "Open 3D Engine - o3de.org", + "origin_url": "https://github.com/o3de/o3de", "type": "Code", "summary": "A short description of TestGem.", "canonical_tags": [ @@ -53,7 +55,10 @@ TEST_GEM_JSON_PAYLOAD = ''' "TestGem" ], "icon_path": "preview.png", - "requirements": "" + "requirements": "Any requirement goes here.", + "documentation_url": "The link to the documentation goes here.", + "dependencies": [ + ] } ''' diff --git a/scripts/o3de/tests/unit_test_engine_template.py b/scripts/o3de/tests/unit_test_engine_template.py index ed1c8258d3..da23ee11f1 100755 --- a/scripts/o3de/tests/unit_test_engine_template.py +++ b/scripts/o3de/tests/unit_test_engine_template.py @@ -93,37 +93,28 @@ TEST_TEMPLATE_JSON_CONTENTS = """\ "copyFiles": [ { "file": "Code/Include/${Name}/${Name}Bus.h", - "origin": "Code/Include/${Name}/${Name}Bus.h", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { - "file": "Code/Include/Platform/Salem/${Name}Bus.h", - "origin": "Code/Include/Platform/Salem/${Name}Bus.h", - "isTemplated": true, - "isOptional": false + "file": "Code/Include/Platform/Windows/${Name}Bus.h", + "isTemplated": true } ], "createDirectories": [ { - "dir": "Code", - "origin": "Code" + "dir": "Code" }, { - "dir": "Code/Include", - "origin": "Code/Include" + "dir": "Code/Include" }, { - "dir": "Code/Include/${Name}", - "origin": "Code/Include/${Name}" + "dir": "Code/Include/${Name}" }, { - "dir": "Code/Include/Platform", - "origin": "Code/Include/Platform" + "dir": "Code/Include/Platform" }, { - "dir": "Code/Include/Platform/Salem", - "origin": "Code/Include/Platform/Salem" + "dir": "Code/Include/Platform/Windows" } ] } @@ -174,10 +165,10 @@ def test_create_template(tmpdir, with gem_bus_file.open('w') as s: s.write(concrete_contents) - engine_gem_code_include_platform_salem = template_source_path / 'Code/Include/Platform/Salem' - engine_gem_code_include_platform_salem.mkdir(parents=True, exist_ok=True) + engine_gem_code_include_platform_windows = template_source_path / 'Code/Include/Platform/Windows' + engine_gem_code_include_platform_windows.mkdir(parents=True, exist_ok=True) - restricted_gem_bus_file = engine_gem_code_include_platform_salem / 'TestTemplateBus.h' + restricted_gem_bus_file = engine_gem_code_include_platform_windows / 'TestTemplateBus.h' with restricted_gem_bus_file.open('w') as s: s.write(concrete_contents) @@ -209,9 +200,9 @@ def test_create_template(tmpdir, else: assert s_data == templated_contents_without_license - platform_template_folder = engine_root / 'Salem/Templates' + platform_template_folder = engine_root / 'Windows/Templates' - new_platform_default_name_bus_file = template_content_folder / 'Code/Include/Platform/Salem/${Name}Bus.h' + new_platform_default_name_bus_file = template_content_folder / 'Code/Include/Platform/Windows/${Name}Bus.h' assert new_platform_default_name_bus_file.is_file() with new_platform_default_name_bus_file.open('r') as s: s_data = s.read() @@ -255,7 +246,7 @@ class TestCreateTemplate: s.write(templated_contents) template_content_folder = template_default_folder / 'Template' - platform_default_name_bus_dir = template_content_folder / 'Code/Include/Platform/Salem' + platform_default_name_bus_dir = template_content_folder / 'Code/Include/Platform/Windows' platform_default_name_bus_dir.mkdir(parents=True, exist_ok=True) platform_default_name_bus_file = platform_default_name_bus_dir / '${Name}Bus.h' @@ -263,10 +254,13 @@ class TestCreateTemplate: s.write(templated_contents) template_dest_path = engine_root / instantiated_name - # Skip registeration in test + # Skip registration in test with patch('uuid.uuid4', return_value=uuid.uuid5(uuid.NAMESPACE_DNS, instantiated_name)) as uuid4_mock: - result = create_from_template_func(template_dest_path, template_path=template_default_folder, force=True, - keep_license_text=keep_license_text, **create_from_template_kwargs) + result = create_from_template_func(template_dest_path, + template_path=template_default_folder, + keep_license_text=keep_license_text, + force=True, + **create_from_template_kwargs) if expect_failure: assert result != 0 else: @@ -281,7 +275,7 @@ class TestCreateTemplate: s_data = s.read() assert s_data == concrete_contents - platform_test_bus_folder = test_folder / 'Code/Include/Platform/Salem' + platform_test_bus_folder = test_folder / 'Code/Include/Platform/Windows' assert platform_test_bus_folder.is_dir() platform_default_name_bus_file = platform_test_bus_folder / f'{instantiated_name}Bus.h' @@ -338,9 +332,7 @@ class TestCreateTemplate: template_json_dict.setdefault('copyFiles', []).append( { "file": "project.json", - "origin": "project.json", - "isTemplated": True, - "isOptional": False + "isTemplated": True }) # Convert the python dictionary back into a json string template_json_contents = json.dumps(template_json_dict, indent=4) @@ -376,9 +368,7 @@ class TestCreateTemplate: template_json_dict.setdefault('copyFiles', []).append( { "file": "gem.json", - "origin": "gem.json", - "isTemplated": True, - "isOptional": False + "isTemplated": True }) #Convert dict back to string template_json_contents = json.dumps(template_json_dict, indent=4) diff --git a/scripts/o3de/tests/unit_test_gem_properties.py b/scripts/o3de/tests/unit_test_gem_properties.py index dee5811b65..6358917852 100644 --- a/scripts/o3de/tests/unit_test_gem_properties.py +++ b/scripts/o3de/tests/unit_test_gem_properties.py @@ -18,10 +18,9 @@ TEST_GEM_JSON_PAYLOAD = ''' { "gem_name": "TestGem", "display_name": "TestGem", - "license": "MIT", - "license_url": "https://opensource.org/licenses/MIT", + "license": "Apache-2.0 or MIT", + "license_url": "https://github.com/o3de/o3de/blob/development/LICENSE.txt", "origin": "The primary repo for TestGem goes here: i.e. http://www.mydomain.com", - "type": "Code", "summary": "A short description of TestGem.", "canonical_tags": [ "Gem" @@ -31,7 +30,9 @@ TEST_GEM_JSON_PAYLOAD = ''' ], "icon_path": "preview.png", "requirements": "", - "documentation_url": "https://o3de.org/docs/" + "documentation_url": "https://o3de.org/docs/", + "dependencies": [ + ] } ''' diff --git a/scripts/o3de/tests/unit_test_manifest.py b/scripts/o3de/tests/unit_test_manifest.py index ad4809dc1d..c7d7a7573b 100644 --- a/scripts/o3de/tests/unit_test_manifest.py +++ b/scripts/o3de/tests/unit_test_manifest.py @@ -22,7 +22,7 @@ from o3de import manifest ]) class TestGetTemplatesForCreation: @staticmethod - def get_templates() -> list: + def get_manifest_templates() -> list: return [] @staticmethod @@ -40,20 +40,24 @@ class TestGetTemplatesForCreation: ) def test_get_templates_for_generic_creation(self, valid_project_json_paths, valid_gem_json_paths, expected_template_paths): - def validate_project_json(template_path) -> bool: - return pathlib.Path(template_path) in valid_project_json_paths + def validate_project_json(project_json_path) -> bool: + return pathlib.Path(project_json_path) in valid_project_json_paths - def validate_gem_json(template_path) -> bool: - return pathlib.Path(template_path) in valid_gem_json_paths + def validate_gem_json(gem_json_path) -> bool: + return pathlib.Path(gem_json_path) in valid_gem_json_paths - with patch('o3de.manifest.get_templates', side_effect=self.get_templates) as get_templates_patch, \ + with patch('o3de.manifest.get_manifest_templates', side_effect=self.get_manifest_templates)\ + as get_manifest_templates_patch, \ patch('o3de.manifest.get_project_templates', side_effect=self.get_project_templates)\ as get_project_templates_patch, \ patch('o3de.manifest.get_engine_templates', side_effect=self.get_engine_templates)\ as get_engine_templates_patch, \ - patch('o3de.validation.valid_o3de_template_json', return_value=True) as validate_template_json,\ - patch('o3de.validation.valid_o3de_project_json', side_effect=validate_project_json) as validate_project_json,\ - patch('o3de.validation.valid_o3de_gem_json', side_effect=validate_gem_json) as validate_gem_json: + patch('o3de.validation.valid_o3de_template_json', return_value=True) \ + as validate_template_json,\ + patch('o3de.validation.valid_o3de_project_json', side_effect=validate_project_json) \ + as validate_project_json,\ + patch('o3de.validation.valid_o3de_gem_json', side_effect=validate_gem_json) \ + as validate_gem_json: templates = manifest.get_templates_for_generic_creation() assert templates == expected_template_paths @@ -64,21 +68,24 @@ class TestGetTemplatesForCreation: ) def test_get_templates_for_gem_creation(self, valid_project_json_paths, valid_gem_json_paths, expected_template_paths): - def validate_project_json(template_path) -> bool: - return pathlib.Path(template_path) in valid_project_json_paths + def validate_project_json(project_json_path) -> bool: + return pathlib.Path(project_json_path) in valid_project_json_paths - def validate_gem_json(template_path) -> bool: - return pathlib.Path(template_path) in valid_gem_json_paths + def validate_gem_json(gem_json_path) -> bool: + return pathlib.Path(gem_json_path) in valid_gem_json_paths - with patch('o3de.manifest.get_templates', side_effect=self.get_templates) as get_templates_patch, \ + with patch('o3de.manifest.get_manifest_templates', side_effect=self.get_manifest_templates)\ + as get_manifest_templates_patch, \ patch('o3de.manifest.get_project_templates', side_effect=self.get_project_templates) \ as get_project_templates_patch, \ patch('o3de.manifest.get_engine_templates', side_effect=self.get_engine_templates) \ as get_engine_templates_patch, \ - patch('o3de.validation.valid_o3de_template_json', return_value=True) as validate_template_json, \ - patch('o3de.validation.valid_o3de_project_json', - side_effect=validate_project_json) as validate_project_json, \ - patch('o3de.validation.valid_o3de_gem_json', side_effect=validate_gem_json) as validate_gem_json: + patch('o3de.validation.valid_o3de_template_json', return_value=True) \ + as validate_template_json, \ + patch('o3de.validation.valid_o3de_project_json', side_effect=validate_project_json) \ + as validate_project_json, \ + patch('o3de.validation.valid_o3de_gem_json', side_effect=validate_gem_json) \ + as validate_gem_json: templates = manifest.get_templates_for_project_creation() assert templates == expected_template_paths @@ -89,20 +96,23 @@ class TestGetTemplatesForCreation: ) def test_get_templates_for_project_creation(self, valid_project_json_paths, valid_gem_json_paths, expected_template_paths): - def validate_project_json(template_path) -> bool: - return pathlib.Path(template_path) in valid_project_json_paths + def validate_project_json(project_json_path) -> bool: + return pathlib.Path(project_json_path) in valid_project_json_paths - def validate_gem_json(template_path) -> bool: - return pathlib.Path(template_path) in valid_gem_json_paths + def validate_gem_json(gem_json_path) -> bool: + return pathlib.Path(gem_json_path) in valid_gem_json_paths - with patch('o3de.manifest.get_templates', side_effect=self.get_templates) as get_templates_patch, \ + with patch('o3de.manifest.get_manifest_templates', side_effect=self.get_manifest_templates) \ + as get_manifest_templates_patch, \ patch('o3de.manifest.get_project_templates', side_effect=self.get_project_templates) \ as get_project_templates_patch, \ patch('o3de.manifest.get_engine_templates', side_effect=self.get_engine_templates) \ as get_engine_templates_patch, \ - patch('o3de.validation.valid_o3de_template_json', return_value=True) as validate_template_json, \ - patch('o3de.validation.valid_o3de_project_json', - side_effect=validate_project_json) as validate_project_json, \ - patch('o3de.validation.valid_o3de_gem_json', side_effect=validate_gem_json) as validate_gem_json: + patch('o3de.validation.valid_o3de_template_json', return_value=True) \ + as validate_template_json, \ + patch('o3de.validation.valid_o3de_project_json', side_effect=validate_project_json) \ + as validate_project_json, \ + patch('o3de.validation.valid_o3de_gem_json', side_effect=validate_gem_json) \ + as validate_gem_json: templates = manifest.get_templates_for_gem_creation() assert templates == expected_template_paths \ No newline at end of file diff --git a/scripts/o3de/tests/unit_test_print_registration.py b/scripts/o3de/tests/unit_test_print_registration.py index 7e3e75edcd..d01434c99f 100644 --- a/scripts/o3de/tests/unit_test_print_registration.py +++ b/scripts/o3de/tests/unit_test_print_registration.py @@ -90,27 +90,20 @@ TEST_TEMPLATE_JSON_PAYLOAD = ''' "copyFiles": [ { "file": "CMakeLists.txt", - "origin": "CMakeLists.txt", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "gem.json", - "origin": "gem.json", - "isTemplated": true, - "isOptional": false + "isTemplated": true }, { "file": "preview.png", - "origin": "preview.png", - "isTemplated": false, - "isOptional": false + "isTemplated": false } ], "createDirectories": [ { - "dir": "Assets", - "origin": "Assets" + "dir": "Assets" } ] } @@ -277,13 +270,9 @@ class TestPrintRegistration: # Patch the manifest.py function to locate gem.json files in external subdirectories # to just return a fake path to a single test gem - def get_gems_from_subdirectories(external_subdirs: list) -> list: - return ["D:/TestGem"] - with patch('o3de.manifest.load_o3de_manifest', side_effect=self.load_manifest_json) as load_manifest_patch, \ patch('o3de.manifest.get_gem_json_data', side_effect=self.get_gem_json_data) as get_json_patch, \ patch('o3de.manifest.get_project_json_data', side_effect=self.get_project_json_data) as get_project_json_patch, \ - patch('o3de.manifest.get_gems_from_subdirectories', side_effect=get_gems_from_subdirectories) as get_gems_from_subdirs_patch, \ patch('o3de.print_registration.get_project_path', return_value=project_path) as get_project_path_patch: result = print_registration._run_register_show(test_args) assert result == 0