blob: 2880ea35afe9ed4914fe48fe92bead4e5a767f9b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
// Copyright 2019 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// https://gpuweb.github.io/gpuweb/
[
Exposed(Window WebGPU, Worker WebGPU)
] interface GPUBuffer {
[CallWith=ScriptState, RaisesException] Promise<void> mapAsync(
GPUMapModeFlags mode,
optional GPUSize64 offset = 0,
optional GPUSize64 size);
[RaisesException] ArrayBuffer getMappedRange(optional GPUSize64 offset = 0,
optional GPUSize64 size);
[CallWith=ScriptState] void unmap();
[CallWith=ScriptState] void destroy();
};
|