From e33d94fecd272db4bf542541c069e9e2c168c1d5 Mon Sep 17 00:00:00 2001 From: Egor Yusov Date: Fri, 15 Feb 2019 22:48:41 -0800 Subject: Moved NativeApp to Diligent namespace --- Tests/TestApp/include/TestApp.h | 25 +++++++++++++++---------- Tests/TestApp/src/Android/TestAppAndroid.cpp | 5 ++++- Tests/TestApp/src/IOS/TestAppIOS.cpp | 5 ++++- Tests/TestApp/src/Linux/TestAppLinux.cpp | 6 +++++- Tests/TestApp/src/MacOS/TestAppMacOS.cpp | 5 ++++- Tests/TestApp/src/TestApp.cpp | 5 ++++- Tests/TestApp/src/UWP/TestAppUWP.cpp | 5 ++++- Tests/TestApp/src/Win32/TestAppWin32.cpp | 5 +++++ 8 files changed, 45 insertions(+), 16 deletions(-) (limited to 'Tests/TestApp') diff --git a/Tests/TestApp/include/TestApp.h b/Tests/TestApp/include/TestApp.h index 25ba0d3..1bd626d 100644 --- a/Tests/TestApp/include/TestApp.h +++ b/Tests/TestApp/include/TestApp.h @@ -46,6 +46,9 @@ #include "TestGeometryShader.h" #include "TestTessellation.h" +namespace Diligent +{ + class TestApp : public NativeAppBase { public: @@ -67,11 +70,11 @@ protected: ); void InitializeRenderers(); - Diligent::DeviceType m_DeviceType = Diligent::DeviceType::Undefined; - Diligent::RefCntAutoPtr m_pDevice; - Diligent::RefCntAutoPtr m_pImmediateContext; - std::vector > m_pDeferredContexts; - Diligent::RefCntAutoPtr m_pSwapChain; + DeviceType m_DeviceType = DeviceType::Undefined; + RefCntAutoPtr m_pDevice; + RefCntAutoPtr m_pImmediateContext; + std::vector > m_pDeferredContexts; + RefCntAutoPtr m_pSwapChain; std::string m_AppTitle; std::unique_ptr m_pTestDrawCommands; @@ -84,12 +87,14 @@ protected: TestGeometryShader m_TestGS; TestTessellation m_TestTessellation; - Diligent::RefCntAutoPtr m_pInstBuff, m_pInstBuff2, m_pUniformBuff, m_pUniformBuff2, m_pUniformBuff3, m_pUniformBuff4; - Diligent::RefCntAutoPtr m_pTestTex; - Diligent::RefCntAutoPtr m_pRenderScript; - Diligent::RefCntAutoPtr m_pFence; - Diligent::Uint64 m_NextFenceValue = 1; + RefCntAutoPtr m_pInstBuff, m_pInstBuff2, m_pUniformBuff, m_pUniformBuff2, m_pUniformBuff3, m_pUniformBuff4; + RefCntAutoPtr m_pTestTex; + RefCntAutoPtr m_pRenderScript; + RefCntAutoPtr m_pFence; + Uint64 m_NextFenceValue = 1; SmartPointerTest m_SmartPointerTest; double m_CurrTime = 0; }; + +} diff --git a/Tests/TestApp/src/Android/TestAppAndroid.cpp b/Tests/TestApp/src/Android/TestAppAndroid.cpp index 222081a..fe1c86a 100644 --- a/Tests/TestApp/src/Android/TestAppAndroid.cpp +++ b/Tests/TestApp/src/Android/TestAppAndroid.cpp @@ -24,7 +24,8 @@ #include "TestApp.h" #include "RenderDeviceGLES.h" -using namespace Diligent; +namespace Diligent +{ class TestAppAndroid final : public TestApp { @@ -67,3 +68,5 @@ NativeAppBase* CreateApplication() { return new TestAppAndroid; } + +} diff --git a/Tests/TestApp/src/IOS/TestAppIOS.cpp b/Tests/TestApp/src/IOS/TestAppIOS.cpp index d71ca5a..70bb6de 100644 --- a/Tests/TestApp/src/IOS/TestAppIOS.cpp +++ b/Tests/TestApp/src/IOS/TestAppIOS.cpp @@ -24,7 +24,8 @@ #include #include "TestApp.h" -using namespace Diligent; +namespace Diligent +{ class TestAppIOS final : public TestApp { @@ -47,3 +48,5 @@ NativeAppBase* CreateApplication() { return new TestAppIOS; } + +} diff --git a/Tests/TestApp/src/Linux/TestAppLinux.cpp b/Tests/TestApp/src/Linux/TestAppLinux.cpp index 1393714..9ce02b9 100644 --- a/Tests/TestApp/src/Linux/TestAppLinux.cpp +++ b/Tests/TestApp/src/Linux/TestAppLinux.cpp @@ -22,7 +22,9 @@ */ #include "TestApp.h" -using namespace Diligent; + +namespace Diligent +{ class TestAppLinux final : public TestApp { @@ -57,3 +59,5 @@ NativeAppBase* CreateApplication() { return new TestAppLinux; } + +} diff --git a/Tests/TestApp/src/MacOS/TestAppMacOS.cpp b/Tests/TestApp/src/MacOS/TestAppMacOS.cpp index e902dd8..3542251 100644 --- a/Tests/TestApp/src/MacOS/TestAppMacOS.cpp +++ b/Tests/TestApp/src/MacOS/TestAppMacOS.cpp @@ -24,7 +24,8 @@ #include #include "TestApp.h" -using namespace Diligent; +namespace Diligent +{ class TestAppMacOS final : public TestApp { @@ -46,3 +47,5 @@ NativeAppBase* CreateApplication() { return new TestAppMacOS; } + +} diff --git a/Tests/TestApp/src/TestApp.cpp b/Tests/TestApp/src/TestApp.cpp index 7e6479c..4b072a3 100644 --- a/Tests/TestApp/src/TestApp.cpp +++ b/Tests/TestApp/src/TestApp.cpp @@ -73,7 +73,8 @@ #include "TestSeparateTextureSampler.h" #include "StringTools.h" -using namespace Diligent; +namespace Diligent +{ TestApp::TestApp() : m_AppTitle("Test app") @@ -720,3 +721,5 @@ void TestApp::Present() { m_pSwapChain->Present(0); } + +} diff --git a/Tests/TestApp/src/UWP/TestAppUWP.cpp b/Tests/TestApp/src/UWP/TestAppUWP.cpp index d7158f8..a3e40b5 100644 --- a/Tests/TestApp/src/UWP/TestAppUWP.cpp +++ b/Tests/TestApp/src/UWP/TestAppUWP.cpp @@ -29,7 +29,8 @@ #include "RenderDeviceFactoryD3D11.h" #include "RenderDeviceFactoryD3D12.h" -using namespace Diligent; +namespace Diligent +{ class TestAppUWP final : public TestApp { @@ -207,3 +208,5 @@ NativeAppBase* CreateApplication() { return new TestAppUWP; } + +} diff --git a/Tests/TestApp/src/Win32/TestAppWin32.cpp b/Tests/TestApp/src/Win32/TestAppWin32.cpp index 969bfb1..40ed6ed 100644 --- a/Tests/TestApp/src/Win32/TestAppWin32.cpp +++ b/Tests/TestApp/src/Win32/TestAppWin32.cpp @@ -23,6 +23,9 @@ #include "TestApp.h" +namespace Diligent +{ + class TestAppWin32 final : public TestApp { public: @@ -37,3 +40,5 @@ NativeAppBase* CreateApplication() { return new TestAppWin32; } + +} -- cgit v1.2.3