Flutter Engine
The Flutter Engine
DawnComputePipeline.h
Go to the documentation of this file.
1/*
2 * Copyright 2023 Google LLC
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8#ifndef skgpu_graphite_DawnComputePipeline_DEFINED
9#define skgpu_graphite_DawnComputePipeline_DEFINED
10
13
14#include "webgpu/webgpu_cpp.h" // NO_G3_REWRITE
15
16namespace skgpu::graphite {
17
18class ComputePipelineDesc;
19class DawnComputePipelineDesc;
20class DawnSharedContext;
21
23public:
25 ~DawnComputePipeline() override = default;
26
27 const wgpu::ComputePipeline& dawnComputePipeline() const { return fPipeline; }
28 const wgpu::BindGroupLayout& dawnGroupLayout() const { return fGroupLayout; }
29
30private:
31 DawnComputePipeline(const SharedContext*, wgpu::ComputePipeline, wgpu::BindGroupLayout);
32
33 void freeGpuData() override;
34
35 wgpu::ComputePipeline fPipeline;
36 wgpu::BindGroupLayout fGroupLayout;
37};
38
39} // namespace skgpu::graphite
40
41#endif // skgpu_graphite_DawnComputePipeline_DEFINED
static sk_sp< DawnComputePipeline > Make(const DawnSharedContext *, const ComputePipelineDesc &)
const wgpu::BindGroupLayout & dawnGroupLayout() const
const wgpu::ComputePipeline & dawnComputePipeline() const
~DawnComputePipeline() override=default