From 886931f2a930b3080ba034e2d6f83cfa100d9b7c Mon Sep 17 00:00:00 2001 From: antonmic Date: Wed, 9 Jun 2021 09:24:34 -0700 Subject: [PATCH] Pass changes: minor fixes misses previously --- Gems/Atom/RPI/Code/Source/RPI.Public/Pass/ParentPass.cpp | 1 + Gems/Atom/RPI/Code/Source/RPI.Public/Pass/Pass.cpp | 3 --- Gems/Atom/RPI/Code/Source/RPI.Public/Pass/PassSystem.cpp | 2 -- 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/ParentPass.cpp b/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/ParentPass.cpp index e06ffca556..773deafe68 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/ParentPass.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/ParentPass.cpp @@ -248,6 +248,7 @@ namespace AZ void ParentPass::CreateChildPasses() { + // The already created flag prevents this function from executing multiple times a frame if (!m_flags.m_createChildren || m_flags.m_alreadyCreated) { return; diff --git a/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/Pass.cpp b/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/Pass.cpp index f36673221b..7ae3559e38 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/Pass.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/Pass.cpp @@ -42,7 +42,6 @@ namespace AZ { namespace RPI { -#pragma optimize("", off) // --- Constructors --- @@ -1633,8 +1632,6 @@ namespace AZ } } -#pragma optimize("", on) - } // namespace RPI } // namespace AZ diff --git a/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/PassSystem.cpp b/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/PassSystem.cpp index d209d03580..ad3d6d31ca 100644 --- a/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/PassSystem.cpp +++ b/Gems/Atom/RPI/Code/Source/RPI.Public/Pass/PassSystem.cpp @@ -50,7 +50,6 @@ namespace AZ { namespace RPI { -#pragma optimize("", off) PassSystemInterface* PassSystemInterface::Get() { @@ -486,6 +485,5 @@ namespace AZ return nullptr; } -#pragma optimize("", on) } // namespace RPI } // namespace AZ