yum-mirror/slang

Making it easier to work with shaders

git clone https://git.yummers.dev/yum-mirror/slang

Ellie Hermaszewskaformatf65d756bf

master
767 B37 linesraw
1// d3d12-fence.h
2#pragma once
3
4#include "d3d12-base.h"
5
6
7namespace gfx
8{
9namespace d3d12
10{
11
12using namespace Slang;
13
14class FenceImpl : public FenceBase
15{
16public:
17    ComPtr<ID3D12Fence> m_fence;
18    HANDLE m_waitEvent = 0;
19
20    ~FenceImpl();
21
22    HANDLE getWaitEvent();
23
24    Result init(DeviceImpl* device, const IFence::Desc& desc);
25
26    virtual SLANG_NO_THROW Result SLANG_MCALL getCurrentValue(uint64_t* outValue) override;
27
28    virtual SLANG_NO_THROW Result SLANG_MCALL setCurrentValue(uint64_t value) override;
29
30    virtual SLANG_NO_THROW Result SLANG_MCALL getSharedHandle(InteropHandle* outHandle) override;
31
32    virtual SLANG_NO_THROW Result SLANG_MCALL
33    getNativeHandle(InteropHandle* outNativeHandle) override;
34};
35
36} // namespace d3d12
37} // namespace gfx