Graphics: Improve TextureSampler handling

This commit is contained in:
Jérôme Leclercq
2021-01-27 18:50:49 +01:00
parent 78c3f57333
commit b9151d8a7a
15 changed files with 181 additions and 27 deletions

View File

@@ -9,8 +9,10 @@
#include <Nazara/Prerequisites.hpp>
#include <Nazara/Graphics/Config.hpp>
#include <Nazara/Graphics/TextureSamplerCache.hpp>
#include <Nazara/Renderer/Renderer.hpp>
#include <Nazara/Renderer/RenderDevice.hpp>
#include <optional>
namespace Nz
{
@@ -30,6 +32,7 @@ namespace Nz
~Graphics();
inline RenderDevice& GetRenderDevice();
inline TextureSamplerCache& GetSamplerCache();
inline const std::shared_ptr<AbstractBuffer>& GetViewerDataUBO();
struct Config
@@ -38,6 +41,7 @@ namespace Nz
};
private:
std::optional<TextureSamplerCache> m_samplerCache;
std::shared_ptr<AbstractBuffer> m_viewerDataUBO;
std::shared_ptr<RenderDevice> m_renderDevice;