summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_vulkan/vk_sampler_cache.h
blob: a33d1c0ee60c2203df08dc01829bd3ed0736a164 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// Copyright 2019 yuzu Emulator Project
// Licensed under GPLv2 or any later version
// Refer to the license.txt file included.

#pragma once

#include "video_core/renderer_vulkan/wrapper.h"
#include "video_core/sampler_cache.h"
#include "video_core/textures/texture.h"

namespace Vulkan {

class VKDevice;

class VKSamplerCache final : public VideoCommon::SamplerCache<VkSampler, vk::Sampler> {
public:
    explicit VKSamplerCache(const VKDevice& device);
    ~VKSamplerCache();

protected:
    vk::Sampler CreateSampler(const Tegra::Texture::TSCEntry& tsc) const override;

    VkSampler ToSamplerType(const vk::Sampler& sampler) const override;

private:
    const VKDevice& device;
};

} // namespace Vulkan