ATOM-16237 Using setting registry to RPI system settings (#3663)
* ATOM-16237 Using setting registry to RPI system settings Changes include: - Remove RHISystemDesriptor since the pre-registered draw list tag is not needed. - Remove EitorContext which was for system component settings. - Add atom_rpi.setreg file - Add getting RPISystemDescriptor from setting registry. Signed-off-by: qingtao <qingtao@amazon.com>monroegm-disable-blank-issue-2
parent
c32740ad53
commit
f2eb8ff51f
@ -1,31 +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 <AzCore/Name/Name.h>
|
||||
#include <AzCore/std/containers/vector.h>
|
||||
|
||||
namespace AZ
|
||||
{
|
||||
class ReflectContext;
|
||||
|
||||
|
||||
namespace RHI
|
||||
{
|
||||
class PlatformLimits;
|
||||
struct RHISystemDescriptor final
|
||||
{
|
||||
AZ_TYPE_INFO(RHISystemDescriptor, "{A506DA28-856C-483A-938D-73471D2C5A5B}");
|
||||
static void Reflect(AZ::ReflectContext* context);
|
||||
|
||||
//! The set of globally declared draw list tags, which will be registered with the registry at startup.
|
||||
AZStd::vector<AZ::Name> m_drawListTags;
|
||||
};
|
||||
} // namespace RHI
|
||||
} // namespace AZ
|
||||
@ -1,40 +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 <Atom/RHI.Reflect/RHISystemDescriptor.h>
|
||||
#include <Atom/RHI.Reflect/PlatformLimitsDescriptor.h>
|
||||
|
||||
#include <AzCore/Serialization/SerializeContext.h>
|
||||
#include <AzCore/Serialization/EditContext.h>
|
||||
|
||||
namespace AZ
|
||||
{
|
||||
namespace RHI
|
||||
{
|
||||
void RHISystemDescriptor::Reflect(AZ::ReflectContext* context)
|
||||
{
|
||||
if (auto* serializeContext = azrtti_cast<AZ::SerializeContext*>(context))
|
||||
{
|
||||
serializeContext->Class<RHISystemDescriptor>()
|
||||
->Version(4)
|
||||
->Field("DrawItemTags", &RHISystemDescriptor::m_drawListTags)
|
||||
;
|
||||
|
||||
if (AZ::EditContext* ec = serializeContext->GetEditContext())
|
||||
{
|
||||
ec->Class<RHISystemDescriptor>("RHI Settings", "Settings for runtime RHI system")
|
||||
->ClassElement(AZ::Edit::ClassElements::EditorData, "")
|
||||
->Attribute(AZ::Edit::Attributes::AppearsInAddComponentMenu, AZ_CRC("System", 0xc94d118b))
|
||||
->Attribute(AZ::Edit::Attributes::AutoExpand, true)
|
||||
->DataElement(AZ::Edit::UIHandlers::Default, &RHISystemDescriptor::m_drawListTags, "Draw List Tags", "The set of globally declared draw list tags, which will be registered with the registry at startup.")
|
||||
;
|
||||
}
|
||||
}
|
||||
}
|
||||
} // namespace RPI
|
||||
} // namespace AZ
|
||||
@ -0,0 +1,24 @@
|
||||
{
|
||||
"O3DE": {
|
||||
"Atom": {
|
||||
"RPI": {
|
||||
"Initialization": {
|
||||
"CommonSrgsShaderAssetPath": "shader/sceneandviewsrgs.azshader",
|
||||
"ImageSystemDescriptor": {
|
||||
"AssetStreamingImagePoolSize": 2147483648, // 2 * 1024 * 1024 * 1024
|
||||
"SystemStreamingImagePoolSize": 134217728, // 128 * 1024 * 1024
|
||||
"SystemAttachmentImagePoolSize": 536870912 // 512 * 1024 * 1024
|
||||
},
|
||||
"GpuQuerySystemDescriptor": {
|
||||
"OcclusionQueryCount": 128,
|
||||
"StatisticsQueryCount": 256,
|
||||
"TimestampQueryCount": 256
|
||||
},
|
||||
"DynamicDrawSystemDescriptor": {
|
||||
"DynamicBufferPoolSize": 50331648 // 3 * 16 * 1024 * 1024 (for 3 frames)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue