| // Copyright 2018 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/ |
| |
| typedef [EnforceRange] unsigned long GPUBufferDynamicOffset; |
| typedef [EnforceRange] unsigned long GPUStencilValue; |
| typedef [EnforceRange] unsigned long GPUSampleMask; |
| typedef [EnforceRange] long GPUDepthBias; |
| |
| typedef [EnforceRange] unsigned long long GPUSize64; |
| typedef [EnforceRange] unsigned long GPUIntegerCoordinate; |
| typedef [EnforceRange] unsigned long GPUIndex32; |
| typedef [EnforceRange] unsigned long GPUSize32; |
| typedef [EnforceRange] long GPUSignedOffset32; |
| |
| typedef (sequence<double> or GPUColorDict) GPUColor; |
| typedef (sequence<GPUIntegerCoordinate> or GPUExtent3DDict) GPUExtent3D; |
| typedef (sequence<GPUIntegerCoordinate> or GPUOrigin2DDict) GPUOrigin2D; |
| typedef (sequence<GPUIntegerCoordinate> or GPUOrigin3DDict) GPUOrigin3D; |
| |
| [ |
| Exposed(Window WebGPU, Worker WebGPU) |
| ] interface GPU { |
| [ |
| RuntimeEnabled=WebGPU, |
| CallWith=ScriptState |
| ] Promise<GPUAdapter?> requestAdapter(optional GPURequestAdapterOptions options = {}); |
| }; |