Graphics: Add GetViewerDataUBO

This commit is contained in:
Jérôme Leclercq
2021-01-22 23:27:11 +01:00
parent a6ff64106e
commit a0d5750ec8
3 changed files with 15 additions and 0 deletions

View File

@@ -14,6 +14,7 @@
namespace Nz
{
class AbstractBuffer;
class RenderDevice;
class NAZARA_GRAPHICS_API Graphics : public ModuleBase<Graphics>
@@ -29,6 +30,7 @@ namespace Nz
~Graphics();
inline RenderDevice& GetRenderDevice();
inline const std::shared_ptr<AbstractBuffer>& GetViewerDataUBO();
struct Config
{
@@ -36,6 +38,7 @@ namespace Nz
};
private:
std::shared_ptr<AbstractBuffer> m_viewerDataUBO;
std::shared_ptr<RenderDevice> m_renderDevice;
static Graphics* s_instance;

View File

@@ -11,6 +11,11 @@ namespace Nz
{
return *m_renderDevice;
}
inline const std::shared_ptr<AbstractBuffer>& Graphics::GetViewerDataUBO()
{
return m_viewerDataUBO;
}
}
#include <Nazara/Graphics/DebugOff.hpp>