Deprecate profiler categories based on global enum

(to be supplanted by registered budgets in the future)

Signed-off-by: Jeremy Ong <jcong@amazon.com>
This commit is contained in:
Jeremy Ong
2021-08-17 12:10:57 -06:00
parent d15d40fec6
commit df9b4d4a2f
274 changed files with 1435 additions and 1965 deletions
@@ -345,7 +345,7 @@ namespace AzToolsFramework
EntityList& entityList,
AZ::SliceComponent::SliceReferenceToInstancePtrs& layerInstances)
{
AZ_PROFILE_FUNCTION(AZ::Debug::ProfileCategory::AzToolsFramework);
AZ_PROFILE_FUNCTION(AzToolsFramework);
EditorLayer layer;
LayerResult layerPrepareResult = PrepareLayerForSaving(layer, entityList, layerInstances);
if (!layerPrepareResult.IsSuccess())
@@ -373,7 +373,7 @@ namespace AzToolsFramework
AZ::SliceComponent::SliceAssetToSliceInstancePtrs& sliceInstances,
AZStd::unordered_map<AZ::EntityId, AZ::Entity*>& uniqueEntities)
{
AZ_PROFILE_FUNCTION(AZ::Debug::ProfileCategory::AzToolsFramework);
AZ_PROFILE_FUNCTION(AzToolsFramework);
// If this layer is being loaded, it won't have a level save dependency yet, so clear that flag.
m_mustSaveLevelWhenLayerSaves = false;
QString fullPathName = levelPakFile;
@@ -518,7 +518,7 @@ namespace AzToolsFramework
EntityList& entityList,
AZ::SliceComponent::SliceReferenceToInstancePtrs& layerInstances)
{
AZ_PROFILE_FUNCTION(AZ::Debug::ProfileCategory::AzToolsFramework);
AZ_PROFILE_FUNCTION(AzToolsFramework);
// Move the editable data into the data serialized to the layer, and not the layer component.
layer.m_layerProperties = m_editableLayerProperties;
layer.m_layerEntityId = GetEntityId();
@@ -640,7 +640,7 @@ namespace AzToolsFramework
const EditorLayer& layer,
AZ::IO::ByteContainerStream<AZStd::vector<char> >& entitySaveStream)
{
AZ_PROFILE_FUNCTION(AZ::Debug::ProfileCategory::AzToolsFramework);
AZ_PROFILE_FUNCTION(AzToolsFramework);
m_otherLayersToSave.clear();
m_mustSaveLevelWhenLayerSaves = false;
@@ -662,7 +662,7 @@ namespace AzToolsFramework
QString levelAbsoluteFolder,
const AZ::IO::ByteContainerStream<AZStd::vector<char> >& entitySaveStream)
{
AZ_PROFILE_FUNCTION(AZ::Debug::ProfileCategory::AzToolsFramework);
AZ_PROFILE_FUNCTION(AzToolsFramework);
AZStd::string layerBaseFileName(m_layerFileName);
// Write to a temp file first.
@@ -68,7 +68,7 @@ namespace AzToolsFramework
AZStd::function<void()> accentRefreshCallback =
[this]()
{
AZ_PROFILE_SCOPE(AZ::Debug::ProfileCategory::AzToolsFramework, "EditorSelectionAccentSystemComponent::QueueAccentRefresh:AccentRefreshCallback");
AZ_PROFILE_SCOPE(AzToolsFramework, "EditorSelectionAccentSystemComponent::QueueAccentRefresh:AccentRefreshCallback");
InvalidateAccents();
RecalculateAndApplyAccents();
m_isAccentRefreshQueued = false;
@@ -79,14 +79,14 @@ namespace AzToolsFramework
void EditorSelectionAccentSystemComponent::ForceSelectionAccentRefresh()
{
AZ_PROFILE_FUNCTION(AZ::Debug::ProfileCategory::AzToolsFramework);
AZ_PROFILE_FUNCTION(AzToolsFramework);
InvalidateAccents();
RecalculateAndApplyAccents();
}
void EditorSelectionAccentSystemComponent::InvalidateAccents()
{
AZ_PROFILE_FUNCTION(AZ::Debug::ProfileCategory::AzToolsFramework);
AZ_PROFILE_FUNCTION(AzToolsFramework);
for (const AZ::EntityId& accentedEntity : m_currentlyAccentedEntities)
{
AzToolsFramework::ComponentEntityEditorRequestBus::Event(accentedEntity, &AzToolsFramework::ComponentEntityEditorRequests::SetSandboxObjectAccent, ComponentEntityAccentType::None);
@@ -96,7 +96,7 @@ namespace AzToolsFramework
void EditorSelectionAccentSystemComponent::RecalculateAndApplyAccents()
{
AZ_PROFILE_FUNCTION(AZ::Debug::ProfileCategory::AzToolsFramework);
AZ_PROFILE_FUNCTION(AzToolsFramework);
AzToolsFramework::EntityIdList selectedEntities;
AzToolsFramework::ToolsApplicationRequests::Bus::BroadcastResult(selectedEntities, &AzToolsFramework::ToolsApplicationRequests::GetSelectedEntities);
AzToolsFramework::EntityIdSet selectedEntitiesSet;