// Copyright (C) 2017 Jérôme Leclercq // This file is part of the "Nazara Engine - Graphics module" // For conditions of distribution and use, see copyright notice in Config.hpp #pragma once #ifndef NAZARA_TEXTURESAMPLERCACHE_HPP #define NAZARA_TEXTURESAMPLERCACHE_HPP #include #include #include #include namespace Nz { class RenderDevice; class NAZARA_GRAPHICS_API TextureSamplerCache { public: inline TextureSamplerCache(std::shared_ptr device); TextureSamplerCache(const TextureSamplerCache&) = delete; TextureSamplerCache(TextureSamplerCache&&) = delete; ~TextureSamplerCache() = default; const std::shared_ptr& Get(const TextureSamplerInfo& info); TextureSamplerCache& operator=(const TextureSamplerCache&) = delete; TextureSamplerCache& operator=(TextureSamplerCache&&) = delete; private: std::shared_ptr m_device; std::unordered_map> m_samplers; }; } #include #endif