summaryrefslogtreecommitdiffstats
path: root/Graphics/GraphicsEngineOpenGL
diff options
context:
space:
mode:
authorazhirnov <zh1dron@gmail.com>2020-10-04 20:22:16 +0000
committerazhirnov <zh1dron@gmail.com>2020-10-04 20:22:16 +0000
commit9e567836f3e63c541cde7b0a02fd2fc7916402c8 (patch)
tree8168a4aad7818ca48d74f94e476c57e0e6f3d5c4 /Graphics/GraphicsEngineOpenGL
parentAdded ray tracing types (diff)
downloadDiligentCore-9e567836f3e63c541cde7b0a02fd2fc7916402c8.tar.gz
DiligentCore-9e567836f3e63c541cde7b0a02fd2fc7916402c8.zip
Added dummy implementation for D3D11, D3D12, OpenGL
Diffstat (limited to 'Graphics/GraphicsEngineOpenGL')
-rw-r--r--Graphics/GraphicsEngineOpenGL/include/DeviceContextGLImpl.hpp15
-rw-r--r--Graphics/GraphicsEngineOpenGL/include/RenderDeviceGLImpl.hpp12
-rw-r--r--Graphics/GraphicsEngineOpenGL/src/DeviceContextGLImpl.cpp25
-rw-r--r--Graphics/GraphicsEngineOpenGL/src/RenderDeviceGLImpl.cpp23
4 files changed, 74 insertions, 1 deletions
diff --git a/Graphics/GraphicsEngineOpenGL/include/DeviceContextGLImpl.hpp b/Graphics/GraphicsEngineOpenGL/include/DeviceContextGLImpl.hpp
index 205c62b7..8f1b4c37 100644
--- a/Graphics/GraphicsEngineOpenGL/include/DeviceContextGLImpl.hpp
+++ b/Graphics/GraphicsEngineOpenGL/include/DeviceContextGLImpl.hpp
@@ -243,6 +243,21 @@ public:
/// Implementation of IDeviceContext::Flush() in OpenGL backend.
virtual void DILIGENT_CALL_TYPE Flush() override final;
+ /// Implementation of IDeviceContext::BuildBLAS() in OpenGL backend.
+ virtual void DILIGENT_CALL_TYPE BuildBLAS(const BLASBuildAttribs& Attribs) override final;
+
+ /// Implementation of IDeviceContext::BuildTLAS() in OpenGL backend.
+ virtual void DILIGENT_CALL_TYPE BuildTLAS(const TLASBuildAttribs& Attribs) override final;
+
+ /// Implementation of IDeviceContext::CopyBLAS() in OpenGL backend.
+ virtual void DILIGENT_CALL_TYPE CopyBLAS(const CopyBLASAttribs& Attribs) override final;
+
+ /// Implementation of IDeviceContext::CopyTLAS() in OpenGL backend.
+ virtual void DILIGENT_CALL_TYPE CopyTLAS(const CopyTLASAttribs& Attribs) override final;
+
+ /// Implementation of IDeviceContext::TraceRays() in OpenGL backend.
+ virtual void DILIGENT_CALL_TYPE TraceRays(const TraceRaysAttribs& Attribs) override final;
+
/// Implementation of IDeviceContextGL::UpdateCurrentGLContext().
virtual bool DILIGENT_CALL_TYPE UpdateCurrentGLContext() override final;
diff --git a/Graphics/GraphicsEngineOpenGL/include/RenderDeviceGLImpl.hpp b/Graphics/GraphicsEngineOpenGL/include/RenderDeviceGLImpl.hpp
index afb46edb..be2b4ddc 100644
--- a/Graphics/GraphicsEngineOpenGL/include/RenderDeviceGLImpl.hpp
+++ b/Graphics/GraphicsEngineOpenGL/include/RenderDeviceGLImpl.hpp
@@ -107,6 +107,18 @@ public:
virtual void DILIGENT_CALL_TYPE CreateFramebuffer(const FramebufferDesc& Desc,
IFramebuffer** ppFramebuffer) override final;
+ /// Implementation of IRenderDevice::CreateBLAS() in OpenGL backend.
+ virtual void DILIGENT_CALL_TYPE CreateBLAS(const BottomLevelASDesc& Desc,
+ IBottomLevelAS** ppBLAS) override final;
+
+ /// Implementation of IRenderDevice::CreateTLAS() in OpenGL backend.
+ virtual void DILIGENT_CALL_TYPE CreateTLAS(const TopLevelASDesc& Desc,
+ ITopLevelAS** ppTLAS) override final;
+
+ /// Implementation of IRenderDevice::CreateSBT() in OpenGL backend.
+ virtual void DILIGENT_CALL_TYPE CreateSBT(const ShaderBindingTableDesc& Desc,
+ IShaderBindingTable** ppSBT) override final;
+
/// Implementation of IRenderDeviceGL::CreateTextureFromGLHandle().
virtual void DILIGENT_CALL_TYPE CreateTextureFromGLHandle(Uint32 GLHandle,
Uint32 GLBindTarget,
diff --git a/Graphics/GraphicsEngineOpenGL/src/DeviceContextGLImpl.cpp b/Graphics/GraphicsEngineOpenGL/src/DeviceContextGLImpl.cpp
index f4ef1136..deea5ade 100644
--- a/Graphics/GraphicsEngineOpenGL/src/DeviceContextGLImpl.cpp
+++ b/Graphics/GraphicsEngineOpenGL/src/DeviceContextGLImpl.cpp
@@ -1720,4 +1720,29 @@ void DeviceContextGLImpl::ResolveTextureSubresource(ITexture*
CommitRenderTargets();
}
+void DeviceContextGLImpl::BuildBLAS(const BLASBuildAttribs& Attribs)
+{
+ UNSUPPORTED("BuildBLAS is not supported in OpenGL");
+}
+
+void DeviceContextGLImpl::BuildTLAS(const TLASBuildAttribs& Attribs)
+{
+ UNSUPPORTED("BuildTLAS is not supported in OpenGL");
+}
+
+void DeviceContextGLImpl::CopyBLAS(const CopyBLASAttribs& Attribs)
+{
+ UNSUPPORTED("CopyBLAS is not supported in OpenGL");
+}
+
+void DeviceContextGLImpl::CopyTLAS(const CopyTLASAttribs& Attribs)
+{
+ UNSUPPORTED("CopyTLAS is not supported in OpenGL");
+}
+
+void DeviceContextGLImpl::TraceRays(const TraceRaysAttribs& Attribs)
+{
+ UNSUPPORTED("TraceRays is not supported in OpenGL");
+}
+
} // namespace Diligent
diff --git a/Graphics/GraphicsEngineOpenGL/src/RenderDeviceGLImpl.cpp b/Graphics/GraphicsEngineOpenGL/src/RenderDeviceGLImpl.cpp
index 466f1387..a4c8a35a 100644
--- a/Graphics/GraphicsEngineOpenGL/src/RenderDeviceGLImpl.cpp
+++ b/Graphics/GraphicsEngineOpenGL/src/RenderDeviceGLImpl.cpp
@@ -456,7 +456,7 @@ RenderDeviceGLImpl::RenderDeviceGLImpl(IReferenceCounters* pRefCounters,
#undef SET_FEATURE_STATE
#if defined(_MSC_VER) && defined(_WIN64)
- static_assert(sizeof(DeviceFeatures) == 30, "Did you add a new feature to DeviceFeatures? Please handle its satus here.");
+ static_assert(sizeof(DeviceFeatures) == 31, "Did you add a new feature to DeviceFeatures? Please handle its satus here.");
#endif
}
@@ -769,6 +769,27 @@ void RenderDeviceGLImpl::CreateFramebuffer(const FramebufferDesc& Desc, IFramebu
});
}
+void RenderDeviceGLImpl::CreateBLAS(const BottomLevelASDesc& Desc,
+ IBottomLevelAS** ppBLAS)
+{
+ UNSUPPORTED("CreateBLAS is not supported in OpenGL");
+ *ppBLAS = nullptr;
+}
+
+void RenderDeviceGLImpl::CreateTLAS(const TopLevelASDesc& Desc,
+ ITopLevelAS** ppTLAS)
+{
+ UNSUPPORTED("CreateTLAS is not supported in OpenGL");
+ *ppTLAS = nullptr;
+}
+
+void RenderDeviceGLImpl::CreateSBT(const ShaderBindingTableDesc& Desc,
+ IShaderBindingTable** ppSBT)
+{
+ UNSUPPORTED("CreateSBT is not supported in OpenGL");
+ *ppSBT = nullptr;
+}
+
bool RenderDeviceGLImpl::CheckExtension(const Char* ExtensionString)
{
return m_ExtensionStrings.find(ExtensionString) != m_ExtensionStrings.end();