summaryrefslogtreecommitdiffstats
path: root/tools/gfx/metal/metal-sampler.h
blob: 0d94a6d2df772fad1c807f458bb546cd8c9f1e71 (plain)
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
// metal-sampler.h
#pragma once

#include "metal-base.h"
#include "metal-device.h"

namespace gfx
{

using namespace Slang;

namespace metal
{

class SamplerStateImpl : public SamplerStateBase
{
public:
    RefPtr<DeviceImpl> m_device;
    NS::SharedPtr<MTL::SamplerState> m_samplerState;

    ~SamplerStateImpl();

    Result init(DeviceImpl* device, const ISamplerState::Desc& desc);

    virtual SLANG_NO_THROW Result SLANG_MCALL getNativeHandle(InteropHandle* outHandle) override;
};

} // namespace metal
} // namespace gfx