summaryrefslogtreecommitdiff
path: root/tools/gfx/d3d12/d3d12-sampler.cpp
blob: b96fb4c9036b3ab9aa366ffb3d0b632598f270ab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// d3d12-sampler.cpp
#include "d3d12-sampler.h"

namespace gfx
{
namespace d3d12
{

using namespace Slang;

SamplerStateImpl::~SamplerStateImpl() { m_allocator->free(m_descriptor); }

Result SamplerStateImpl::getNativeHandle(InteropHandle* outHandle)
{
    outHandle->api = InteropHandleAPI::D3D12CpuDescriptorHandle;
    outHandle->handleValue = m_descriptor.cpuHandle.ptr;
    return SLANG_OK;
}

} // namespace d3d12
} // namespace gfx