From 2a0f9a6b4c4e71a21711f794b864ecb0f27f300d Mon Sep 17 00:00:00 2001 From: assiduous Date: Mon, 27 Jan 2020 12:34:52 -0800 Subject: Fixed class vs struct issues. Implemented HLSL2GLSL Convertor C interfaces --- Graphics/GraphicsEngineOpenGL/include/BufferGLImpl.hpp | 2 +- Graphics/GraphicsEngineOpenGL/include/BufferViewGLImpl.hpp | 6 ------ Graphics/GraphicsEngineOpenGL/include/GLPipelineResourceLayout.hpp | 2 -- Graphics/GraphicsEngineOpenGL/include/GLProgramResourceCache.hpp | 4 ++-- Graphics/GraphicsEngineOpenGL/include/SwapChainGLBase.hpp | 2 -- Graphics/GraphicsEngineOpenGL/include/SwapChainGLImpl.hpp | 2 -- Graphics/GraphicsEngineOpenGL/include/TextureBaseGL.hpp | 2 +- Graphics/GraphicsEngineOpenGL/src/BufferGLImpl.cpp | 2 +- Graphics/GraphicsEngineOpenGL/src/GLProgramResourceCache.cpp | 4 ++-- Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp | 2 +- 10 files changed, 8 insertions(+), 20 deletions(-) (limited to 'Graphics/GraphicsEngineOpenGL') diff --git a/Graphics/GraphicsEngineOpenGL/include/BufferGLImpl.hpp b/Graphics/GraphicsEngineOpenGL/include/BufferGLImpl.hpp index 72142592..a5a033c8 100644 --- a/Graphics/GraphicsEngineOpenGL/include/BufferGLImpl.hpp +++ b/Graphics/GraphicsEngineOpenGL/include/BufferGLImpl.hpp @@ -85,7 +85,7 @@ public: virtual void* GetNativeHandle() override final { return reinterpret_cast(static_cast(GetGLBufferHandle())); } private: - virtual void CreateViewInternal(const struct BufferViewDesc& ViewDesc, class IBufferView** ppView, bool bIsDefaultView) override; + virtual void CreateViewInternal(const struct BufferViewDesc& ViewDesc, IBufferView** ppView, bool bIsDefaultView) override; friend class DeviceContextGLImpl; friend class VAOCache; diff --git a/Graphics/GraphicsEngineOpenGL/include/BufferViewGLImpl.hpp b/Graphics/GraphicsEngineOpenGL/include/BufferViewGLImpl.hpp index 5cefada0..6c92168e 100644 --- a/Graphics/GraphicsEngineOpenGL/include/BufferViewGLImpl.hpp +++ b/Graphics/GraphicsEngineOpenGL/include/BufferViewGLImpl.hpp @@ -37,12 +37,6 @@ namespace Diligent { -class FixedBlockMemoryAllocator; -class IRenderDevice; -class IDeviceContext; -class BufferGLImpl; -struct BufferViewDesc; - /// Buffer view implementation in OpenGL backend. class BufferViewGLImpl final : public BufferViewBase { diff --git a/Graphics/GraphicsEngineOpenGL/include/GLPipelineResourceLayout.hpp b/Graphics/GraphicsEngineOpenGL/include/GLPipelineResourceLayout.hpp index d97db39f..bcaee216 100644 --- a/Graphics/GraphicsEngineOpenGL/include/GLPipelineResourceLayout.hpp +++ b/Graphics/GraphicsEngineOpenGL/include/GLPipelineResourceLayout.hpp @@ -77,8 +77,6 @@ namespace Diligent { -class IMemoryAllocator; - class GLPipelineResourceLayout { public: diff --git a/Graphics/GraphicsEngineOpenGL/include/GLProgramResourceCache.hpp b/Graphics/GraphicsEngineOpenGL/include/GLProgramResourceCache.hpp index 0a0bdd5a..cb2cce48 100644 --- a/Graphics/GraphicsEngineOpenGL/include/GLProgramResourceCache.hpp +++ b/Graphics/GraphicsEngineOpenGL/include/GLProgramResourceCache.hpp @@ -115,8 +115,8 @@ public: static size_t GetRequriedMemorySize(Uint32 UBCount, Uint32 SamplerCount, Uint32 ImageCount, Uint32 SSBOCount); - void Initialize(Uint32 UBCount, Uint32 SamplerCount, Uint32 ImageCount, Uint32 SSBOCount, class IMemoryAllocator& MemAllocator); - void Destroy(class IMemoryAllocator& MemAllocator); + void Initialize(Uint32 UBCount, Uint32 SamplerCount, Uint32 ImageCount, Uint32 SSBOCount, IMemoryAllocator& MemAllocator); + void Destroy(IMemoryAllocator& MemAllocator); void SetUniformBuffer(Uint32 Binding, RefCntAutoPtr&& pBuff) { diff --git a/Graphics/GraphicsEngineOpenGL/include/SwapChainGLBase.hpp b/Graphics/GraphicsEngineOpenGL/include/SwapChainGLBase.hpp index 4d18927b..2eeb500e 100644 --- a/Graphics/GraphicsEngineOpenGL/include/SwapChainGLBase.hpp +++ b/Graphics/GraphicsEngineOpenGL/include/SwapChainGLBase.hpp @@ -33,8 +33,6 @@ namespace Diligent { -class IMemoryAllocator; - /// Base implementation of a swap chain for OpenGL. template class SwapChainGLBase : public SwapChainBase diff --git a/Graphics/GraphicsEngineOpenGL/include/SwapChainGLImpl.hpp b/Graphics/GraphicsEngineOpenGL/include/SwapChainGLImpl.hpp index fb069301..b3613007 100644 --- a/Graphics/GraphicsEngineOpenGL/include/SwapChainGLImpl.hpp +++ b/Graphics/GraphicsEngineOpenGL/include/SwapChainGLImpl.hpp @@ -34,8 +34,6 @@ namespace Diligent { -class IMemoryAllocator; - /// Swap chain implementation in OpenGL backend. class SwapChainGLImpl final : public SwapChainGLBase { diff --git a/Graphics/GraphicsEngineOpenGL/include/TextureBaseGL.hpp b/Graphics/GraphicsEngineOpenGL/include/TextureBaseGL.hpp index 306ddb64..3ec4a128 100644 --- a/Graphics/GraphicsEngineOpenGL/include/TextureBaseGL.hpp +++ b/Graphics/GraphicsEngineOpenGL/include/TextureBaseGL.hpp @@ -123,7 +123,7 @@ public: protected: virtual void CreateViewInternal(const struct TextureViewDesc& ViewDesc, - class ITextureView** ppView, + ITextureView** ppView, bool bIsDefaultView) override; void SetDefaultGLParameters(); diff --git a/Graphics/GraphicsEngineOpenGL/src/BufferGLImpl.cpp b/Graphics/GraphicsEngineOpenGL/src/BufferGLImpl.cpp index bce00b60..e3fff3ee 100644 --- a/Graphics/GraphicsEngineOpenGL/src/BufferGLImpl.cpp +++ b/Graphics/GraphicsEngineOpenGL/src/BufferGLImpl.cpp @@ -365,7 +365,7 @@ void BufferGLImpl::BufferMemoryBarrier(Uint32 RequiredBarriers, GLContextState& #endif } -void BufferGLImpl::CreateViewInternal(const BufferViewDesc& OrigViewDesc, class IBufferView** ppView, bool bIsDefaultView) +void BufferGLImpl::CreateViewInternal(const BufferViewDesc& OrigViewDesc, IBufferView** ppView, bool bIsDefaultView) { VERIFY(ppView != nullptr, "Buffer view pointer address is null"); if (!ppView) return; diff --git a/Graphics/GraphicsEngineOpenGL/src/GLProgramResourceCache.cpp b/Graphics/GraphicsEngineOpenGL/src/GLProgramResourceCache.cpp index a23abd3e..5981ce86 100644 --- a/Graphics/GraphicsEngineOpenGL/src/GLProgramResourceCache.cpp +++ b/Graphics/GraphicsEngineOpenGL/src/GLProgramResourceCache.cpp @@ -43,7 +43,7 @@ size_t GLProgramResourceCache::GetRequriedMemorySize(Uint32 UBCount, Uint32 Samp return MemSize; } -void GLProgramResourceCache::Initialize(Uint32 UBCount, Uint32 SamplerCount, Uint32 ImageCount, Uint32 SSBOCount, class IMemoryAllocator& MemAllocator) +void GLProgramResourceCache::Initialize(Uint32 UBCount, Uint32 SamplerCount, Uint32 ImageCount, Uint32 SSBOCount, IMemoryAllocator& MemAllocator) { // clang-format off m_SmplrsOffset = static_cast(m_UBsOffset + sizeof(CachedUB) * UBCount); @@ -90,7 +90,7 @@ GLProgramResourceCache::~GLProgramResourceCache() VERIFY(!IsInitialized(), "Shader resource cache memory must be released with GLProgramResourceCache::Destroy()"); } -void GLProgramResourceCache::Destroy(class IMemoryAllocator& MemAllocator) +void GLProgramResourceCache::Destroy(IMemoryAllocator& MemAllocator) { VERIFY(IsInitialized(), "Resource cache is not initialized"); VERIFY(m_pdbgMemoryAllocator == &MemAllocator, "The allocator does not match the one used to create resources"); diff --git a/Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp b/Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp index 72733d70..19119423 100644 --- a/Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp +++ b/Graphics/GraphicsEngineOpenGL/src/TextureBaseGL.cpp @@ -283,7 +283,7 @@ TextureBaseGL::~TextureBaseGL() IMPLEMENT_QUERY_INTERFACE(TextureBaseGL, IID_TextureGL, TTextureBase) -void TextureBaseGL::CreateViewInternal(const struct TextureViewDesc& OrigViewDesc, class ITextureView** ppView, bool bIsDefaultView) +void TextureBaseGL::CreateViewInternal(const struct TextureViewDesc& OrigViewDesc, ITextureView** ppView, bool bIsDefaultView) { VERIFY(ppView != nullptr, "Null pointer provided"); if (!ppView) return; -- cgit v1.2.3