summaryrefslogtreecommitdiffstats
path: root/tools/gfx/metal/metal-query.h
blob: 55dc9ebbe5550c3b261f40568fffd36e78846779 (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
30
// metal-query.h
#pragma once

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

namespace gfx
{

using namespace Slang;

namespace metal
{

class QueryPoolImpl : public QueryPoolBase
{
public:
    RefPtr<DeviceImpl> m_device;
    NS::SharedPtr<MTL::CounterSampleBuffer> m_counterSampleBuffer;

    ~QueryPoolImpl();

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

    virtual SLANG_NO_THROW Result SLANG_MCALL
    getResult(GfxIndex index, GfxCount count, uint64_t* data) override;
};

} // namespace metal
} // namespace gfx