@cloudflare/workers-types 4.20231016.0 → 4.20231025.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -243,6 +243,8 @@ declare interface ServiceWorkerGlobalScope extends WorkerGlobalScope {
243
243
  GPUBufferUsage: typeof gpuGPUBufferUsage;
244
244
  GPUShaderStage: typeof gpuGPUShaderStage;
245
245
  GPUMapMode: typeof gpuGPUMapMode;
246
+ GPUTextureUsage: typeof gpuGPUTextureUsage;
247
+ GPUColorWrite: typeof gpuGPUColorWrite;
246
248
  }
247
249
  declare function addEventListener<Type extends keyof WorkerGlobalScopeEventMap>(
248
250
  type: Type,
@@ -1975,9 +1977,13 @@ declare interface gpuGPUDevice extends EventTarget {
1975
1977
  createComputePipeline(
1976
1978
  descriptor: gpuGPUComputePipelineDescriptor
1977
1979
  ): gpuGPUComputePipeline;
1980
+ createRenderPipeline(
1981
+ descriptor: gpuGPURenderPipelineDescriptor
1982
+ ): gpuGPURenderPipeline;
1978
1983
  createCommandEncoder(
1979
1984
  descriptor?: gpuGPUCommandEncoderDescriptor
1980
1985
  ): gpuGPUCommandEncoder;
1986
+ createTexture(param1: gpuGPUTextureDescriptor): gpuGPUTexture;
1981
1987
  destroy(): void;
1982
1988
  createQuerySet(descriptor: gpuGPUQuerySetDescriptor): gpuGPUQuerySet;
1983
1989
  pushErrorScope(filter: string): void;
@@ -2247,6 +2253,133 @@ declare interface gpuGPUCompilationMessage {
2247
2253
  declare interface gpuGPUCompilationInfo {
2248
2254
  get messages(): gpuGPUCompilationMessage[];
2249
2255
  }
2256
+ declare abstract class gpuGPUTextureUsage {
2257
+ static readonly COPY_SRC: number;
2258
+ static readonly COPY_DST: number;
2259
+ static readonly TEXTURE_BINDING: number;
2260
+ static readonly STORAGE_BINDING: number;
2261
+ static readonly RENDER_ATTACHMENT: number;
2262
+ }
2263
+ declare interface gpuGPUTextureDescriptor {
2264
+ label: string;
2265
+ size: number[] | gpuGPUExtent3DDict;
2266
+ mipLevelCount?: number;
2267
+ sampleCount?: number;
2268
+ dimension?: string;
2269
+ format: string;
2270
+ usage: number;
2271
+ viewFormats?: string[];
2272
+ }
2273
+ declare interface gpuGPUExtent3DDict {
2274
+ width: number;
2275
+ height?: number;
2276
+ depthOrArrayLayers?: number;
2277
+ }
2278
+ declare interface gpuGPUTexture {
2279
+ createView(descriptor?: gpuGPUTextureViewDescriptor): gpuGPUTextureView;
2280
+ destroy(): void;
2281
+ get width(): number;
2282
+ get height(): number;
2283
+ get depthOrArrayLayers(): number;
2284
+ get mipLevelCount(): number;
2285
+ get dimension(): string;
2286
+ get format(): string;
2287
+ get usage(): number;
2288
+ }
2289
+ declare interface gpuGPUTextureView {}
2290
+ declare interface gpuGPUTextureViewDescriptor {
2291
+ label: string;
2292
+ format: string;
2293
+ dimension: string;
2294
+ aspect?: string;
2295
+ baseMipLevel?: number;
2296
+ mipLevelCount: number;
2297
+ baseArrayLayer?: number;
2298
+ arrayLayerCount: number;
2299
+ }
2300
+ declare abstract class gpuGPUColorWrite {
2301
+ static readonly RED: number;
2302
+ static readonly GREEN: number;
2303
+ static readonly BLUE: number;
2304
+ static readonly ALPHA: number;
2305
+ static readonly ALL: number;
2306
+ }
2307
+ declare interface gpuGPURenderPipeline {}
2308
+ declare interface gpuGPURenderPipelineDescriptor {
2309
+ label?: string;
2310
+ layout: string | gpuGPUPipelineLayout;
2311
+ vertex: gpuGPUVertexState;
2312
+ primitive?: gpuGPUPrimitiveState;
2313
+ depthStencil?: gpuGPUDepthStencilState;
2314
+ multisample?: gpuGPUMultisampleState;
2315
+ fragment?: gpuGPUFragmentState;
2316
+ }
2317
+ declare interface gpuGPUVertexState {
2318
+ module: gpuGPUShaderModule;
2319
+ entryPoint: string;
2320
+ constants?: Record<string, number>;
2321
+ buffers?: gpuGPUVertexBufferLayout[];
2322
+ }
2323
+ declare interface gpuGPUVertexBufferLayout {
2324
+ arrayStride: number | bigint;
2325
+ stepMode?: string;
2326
+ attributes: gpuGPUVertexAttribute[];
2327
+ }
2328
+ declare interface gpuGPUVertexAttribute {
2329
+ format: string;
2330
+ offset: number | bigint;
2331
+ shaderLocation: number;
2332
+ }
2333
+ declare interface gpuGPUPrimitiveState {
2334
+ topology?: string;
2335
+ stripIndexFormat?: string;
2336
+ frontFace?: string;
2337
+ cullMode?: string;
2338
+ unclippedDepth?: boolean;
2339
+ }
2340
+ declare interface gpuGPUStencilFaceState {
2341
+ compare?: string;
2342
+ failOp?: string;
2343
+ depthFailOp?: string;
2344
+ passOp?: string;
2345
+ }
2346
+ declare interface gpuGPUDepthStencilState {
2347
+ format: string;
2348
+ depthWriteEnabled: boolean;
2349
+ depthCompare: string;
2350
+ stencilFront?: gpuGPUStencilFaceState;
2351
+ stencilBack?: gpuGPUStencilFaceState;
2352
+ stencilReadMask?: number;
2353
+ stencilWriteMask?: number;
2354
+ depthBias?: number;
2355
+ depthBiasSlopeScale?: number;
2356
+ depthBiasClamp?: number;
2357
+ }
2358
+ declare interface gpuGPUMultisampleState {
2359
+ count?: number;
2360
+ mask?: number;
2361
+ alphaToCoverageEnabled?: boolean;
2362
+ }
2363
+ declare interface gpuGPUFragmentState {
2364
+ module: gpuGPUShaderModule;
2365
+ entryPoint: string;
2366
+ constants?: Record<string, number>;
2367
+ targets: gpuGPUColorTargetState[];
2368
+ }
2369
+ declare interface gpuGPUColorTargetState {
2370
+ format: string;
2371
+ blend: gpuGPUBlendState;
2372
+ writeMask?: number;
2373
+ }
2374
+ declare interface gpuGPUBlendState {
2375
+ color: gpuGPUBlendComponent;
2376
+ alpha: gpuGPUBlendComponent;
2377
+ }
2378
+ declare interface gpuGPUBlendComponent {
2379
+ operation?: string;
2380
+ srcFactor?: string;
2381
+ dstFactor?: string;
2382
+ }
2250
2383
  declare interface BasicImageTransformations {
2251
2384
  /**
2252
2385
  * Maximum width in image pixels. The value must be an integer.
@@ -243,6 +243,8 @@ export interface ServiceWorkerGlobalScope extends WorkerGlobalScope {
243
243
  GPUBufferUsage: typeof gpuGPUBufferUsage;
244
244
  GPUShaderStage: typeof gpuGPUShaderStage;
245
245
  GPUMapMode: typeof gpuGPUMapMode;
246
+ GPUTextureUsage: typeof gpuGPUTextureUsage;
247
+ GPUColorWrite: typeof gpuGPUColorWrite;
246
248
  }
247
249
  export declare function addEventListener<
248
250
  Type extends keyof WorkerGlobalScopeEventMap
@@ -1980,9 +1982,13 @@ export interface gpuGPUDevice extends EventTarget {
1980
1982
  createComputePipeline(
1981
1983
  descriptor: gpuGPUComputePipelineDescriptor
1982
1984
  ): gpuGPUComputePipeline;
1985
+ createRenderPipeline(
1986
+ descriptor: gpuGPURenderPipelineDescriptor
1987
+ ): gpuGPURenderPipeline;
1983
1988
  createCommandEncoder(
1984
1989
  descriptor?: gpuGPUCommandEncoderDescriptor
1985
1990
  ): gpuGPUCommandEncoder;
1991
+ createTexture(param1: gpuGPUTextureDescriptor): gpuGPUTexture;
1986
1992
  destroy(): void;
1987
1993
  createQuerySet(descriptor: gpuGPUQuerySetDescriptor): gpuGPUQuerySet;
1988
1994
  pushErrorScope(filter: string): void;
@@ -2252,6 +2258,133 @@ export interface gpuGPUCompilationMessage {
2252
2258
  export interface gpuGPUCompilationInfo {
2253
2259
  get messages(): gpuGPUCompilationMessage[];
2254
2260
  }
2261
+ export declare abstract class gpuGPUTextureUsage {
2262
+ static readonly COPY_SRC: number;
2263
+ static readonly COPY_DST: number;
2264
+ static readonly TEXTURE_BINDING: number;
2265
+ static readonly STORAGE_BINDING: number;
2266
+ static readonly RENDER_ATTACHMENT: number;
2267
+ }
2268
+ export interface gpuGPUTextureDescriptor {
2269
+ label: string;
2270
+ size: number[] | gpuGPUExtent3DDict;
2271
+ mipLevelCount?: number;
2272
+ sampleCount?: number;
2273
+ dimension?: string;
2274
+ format: string;
2275
+ usage: number;
2276
+ viewFormats?: string[];
2277
+ }
2278
+ export interface gpuGPUExtent3DDict {
2279
+ width: number;
2280
+ height?: number;
2281
+ depthOrArrayLayers?: number;
2282
+ }
2283
+ export interface gpuGPUTexture {
2284
+ createView(descriptor?: gpuGPUTextureViewDescriptor): gpuGPUTextureView;
2285
+ destroy(): void;
2286
+ get width(): number;
2287
+ get height(): number;
2288
+ get depthOrArrayLayers(): number;
2289
+ get mipLevelCount(): number;
2290
+ get dimension(): string;
2291
+ get format(): string;
2292
+ get usage(): number;
2293
+ }
2294
+ export interface gpuGPUTextureView {}
2295
+ export interface gpuGPUTextureViewDescriptor {
2296
+ label: string;
2297
+ format: string;
2298
+ dimension: string;
2299
+ aspect?: string;
2300
+ baseMipLevel?: number;
2301
+ mipLevelCount: number;
2302
+ baseArrayLayer?: number;
2303
+ arrayLayerCount: number;
2304
+ }
2305
+ export declare abstract class gpuGPUColorWrite {
2306
+ static readonly RED: number;
2307
+ static readonly GREEN: number;
2308
+ static readonly BLUE: number;
2309
+ static readonly ALPHA: number;
2310
+ static readonly ALL: number;
2311
+ }
2312
+ export interface gpuGPURenderPipeline {}
2313
+ export interface gpuGPURenderPipelineDescriptor {
2314
+ label?: string;
2315
+ layout: string | gpuGPUPipelineLayout;
2316
+ vertex: gpuGPUVertexState;
2317
+ primitive?: gpuGPUPrimitiveState;
2318
+ depthStencil?: gpuGPUDepthStencilState;
2319
+ multisample?: gpuGPUMultisampleState;
2320
+ fragment?: gpuGPUFragmentState;
2321
+ }
2322
+ export interface gpuGPUVertexState {
2323
+ module: gpuGPUShaderModule;
2324
+ entryPoint: string;
2325
+ constants?: Record<string, number>;
2326
+ buffers?: gpuGPUVertexBufferLayout[];
2327
+ }
2328
+ export interface gpuGPUVertexBufferLayout {
2329
+ arrayStride: number | bigint;
2330
+ stepMode?: string;
2331
+ attributes: gpuGPUVertexAttribute[];
2332
+ }
2333
+ export interface gpuGPUVertexAttribute {
2334
+ format: string;
2335
+ offset: number | bigint;
2336
+ shaderLocation: number;
2337
+ }
2338
+ export interface gpuGPUPrimitiveState {
2339
+ topology?: string;
2340
+ stripIndexFormat?: string;
2341
+ frontFace?: string;
2342
+ cullMode?: string;
2343
+ unclippedDepth?: boolean;
2344
+ }
2345
+ export interface gpuGPUStencilFaceState {
2346
+ compare?: string;
2347
+ failOp?: string;
2348
+ depthFailOp?: string;
2349
+ passOp?: string;
2350
+ }
2351
+ export interface gpuGPUDepthStencilState {
2352
+ format: string;
2353
+ depthWriteEnabled: boolean;
2354
+ depthCompare: string;
2355
+ stencilFront?: gpuGPUStencilFaceState;
2356
+ stencilBack?: gpuGPUStencilFaceState;
2357
+ stencilReadMask?: number;
2358
+ stencilWriteMask?: number;
2359
+ depthBias?: number;
2360
+ depthBiasSlopeScale?: number;
2361
+ depthBiasClamp?: number;
2362
+ }
2363
+ export interface gpuGPUMultisampleState {
2364
+ count?: number;
2365
+ mask?: number;
2366
+ alphaToCoverageEnabled?: boolean;
2367
+ }
2368
+ export interface gpuGPUFragmentState {
2369
+ module: gpuGPUShaderModule;
2370
+ entryPoint: string;
2371
+ constants?: Record<string, number>;
2372
+ targets: gpuGPUColorTargetState[];
2373
+ }
2374
+ export interface gpuGPUColorTargetState {
2375
+ format: string;
2376
+ blend: gpuGPUBlendState;
2377
+ writeMask?: number;
2378
+ }
2379
+ export interface gpuGPUBlendState {
2380
+ color: gpuGPUBlendComponent;
2381
+ alpha: gpuGPUBlendComponent;
2382
+ }
2383
+ export interface gpuGPUBlendComponent {
2384
+ operation?: string;
2385
+ srcFactor?: string;
2386
+ dstFactor?: string;
2387
+ }
2255
2388
  export interface BasicImageTransformations {
2256
2389
  /**
2257
2390
  * Maximum width in image pixels. The value must be an integer.
@@ -243,6 +243,8 @@ declare interface ServiceWorkerGlobalScope extends WorkerGlobalScope {
243
243
  GPUBufferUsage: typeof gpuGPUBufferUsage;
244
244
  GPUShaderStage: typeof gpuGPUShaderStage;
245
245
  GPUMapMode: typeof gpuGPUMapMode;
246
+ GPUTextureUsage: typeof gpuGPUTextureUsage;
247
+ GPUColorWrite: typeof gpuGPUColorWrite;
246
248
  }
247
249
  declare function addEventListener<Type extends keyof WorkerGlobalScopeEventMap>(
248
250
  type: Type,
@@ -1976,9 +1978,13 @@ declare interface gpuGPUDevice extends EventTarget {
1976
1978
  createComputePipeline(
1977
1979
  descriptor: gpuGPUComputePipelineDescriptor
1978
1980
  ): gpuGPUComputePipeline;
1981
+ createRenderPipeline(
1982
+ descriptor: gpuGPURenderPipelineDescriptor
1983
+ ): gpuGPURenderPipeline;
1979
1984
  createCommandEncoder(
1980
1985
  descriptor?: gpuGPUCommandEncoderDescriptor
1981
1986
  ): gpuGPUCommandEncoder;
1987
+ createTexture(param1: gpuGPUTextureDescriptor): gpuGPUTexture;
1982
1988
  destroy(): void;
1983
1989
  createQuerySet(descriptor: gpuGPUQuerySetDescriptor): gpuGPUQuerySet;
1984
1990
  pushErrorScope(filter: string): void;
@@ -2248,6 +2254,133 @@ declare interface gpuGPUCompilationMessage {
2248
2254
  declare interface gpuGPUCompilationInfo {
2249
2255
  get messages(): gpuGPUCompilationMessage[];
2250
2256
  }
2257
+ declare abstract class gpuGPUTextureUsage {
2258
+ static readonly COPY_SRC: number;
2259
+ static readonly COPY_DST: number;
2260
+ static readonly TEXTURE_BINDING: number;
2261
+ static readonly STORAGE_BINDING: number;
2262
+ static readonly RENDER_ATTACHMENT: number;
2263
+ }
2264
+ declare interface gpuGPUTextureDescriptor {
2265
+ label: string;
2266
+ size: number[] | gpuGPUExtent3DDict;
2267
+ mipLevelCount?: number;
2268
+ sampleCount?: number;
2269
+ dimension?: string;
2270
+ format: string;
2271
+ usage: number;
2272
+ viewFormats?: string[];
2273
+ }
2274
+ declare interface gpuGPUExtent3DDict {
2275
+ width: number;
2276
+ height?: number;
2277
+ depthOrArrayLayers?: number;
2278
+ }
2279
+ declare interface gpuGPUTexture {
2280
+ createView(descriptor?: gpuGPUTextureViewDescriptor): gpuGPUTextureView;
2281
+ destroy(): void;
2282
+ get width(): number;
2283
+ get height(): number;
2284
+ get depthOrArrayLayers(): number;
2285
+ get mipLevelCount(): number;
2286
+ get dimension(): string;
2287
+ get format(): string;
2288
+ get usage(): number;
2289
+ }
2290
+ declare interface gpuGPUTextureView {}
2291
+ declare interface gpuGPUTextureViewDescriptor {
2292
+ label: string;
2293
+ format: string;
2294
+ dimension: string;
2295
+ aspect?: string;
2296
+ baseMipLevel?: number;
2297
+ mipLevelCount: number;
2298
+ baseArrayLayer?: number;
2299
+ arrayLayerCount: number;
2300
+ }
2301
+ declare abstract class gpuGPUColorWrite {
2302
+ static readonly RED: number;
2303
+ static readonly GREEN: number;
2304
+ static readonly BLUE: number;
2305
+ static readonly ALPHA: number;
2306
+ static readonly ALL: number;
2307
+ }
2308
+ declare interface gpuGPURenderPipeline {}
2309
+ declare interface gpuGPURenderPipelineDescriptor {
2310
+ label?: string;
2311
+ layout: string | gpuGPUPipelineLayout;
2312
+ vertex: gpuGPUVertexState;
2313
+ primitive?: gpuGPUPrimitiveState;
2314
+ depthStencil?: gpuGPUDepthStencilState;
2315
+ multisample?: gpuGPUMultisampleState;
2316
+ fragment?: gpuGPUFragmentState;
2317
+ }
2318
+ declare interface gpuGPUVertexState {
2319
+ module: gpuGPUShaderModule;
2320
+ entryPoint: string;
2321
+ constants?: Record<string, number>;
2322
+ buffers?: gpuGPUVertexBufferLayout[];
2323
+ }
2324
+ declare interface gpuGPUVertexBufferLayout {
2325
+ arrayStride: number | bigint;
2326
+ stepMode?: string;
2327
+ attributes: gpuGPUVertexAttribute[];
2328
+ }
2329
+ declare interface gpuGPUVertexAttribute {
2330
+ format: string;
2331
+ offset: number | bigint;
2332
+ shaderLocation: number;
2333
+ }
2334
+ declare interface gpuGPUPrimitiveState {
2335
+ topology?: string;
2336
+ stripIndexFormat?: string;
2337
+ frontFace?: string;
2338
+ cullMode?: string;
2339
+ unclippedDepth?: boolean;
2340
+ }
2341
+ declare interface gpuGPUStencilFaceState {
2342
+ compare?: string;
2343
+ failOp?: string;
2344
+ depthFailOp?: string;
2345
+ passOp?: string;
2346
+ }
2347
+ declare interface gpuGPUDepthStencilState {
2348
+ format: string;
2349
+ depthWriteEnabled: boolean;
2350
+ depthCompare: string;
2351
+ stencilFront?: gpuGPUStencilFaceState;
2352
+ stencilBack?: gpuGPUStencilFaceState;
2353
+ stencilReadMask?: number;
2354
+ stencilWriteMask?: number;
2355
+ depthBias?: number;
2356
+ depthBiasSlopeScale?: number;
2357
+ depthBiasClamp?: number;
2358
+ }
2359
+ declare interface gpuGPUMultisampleState {
2360
+ count?: number;
2361
+ mask?: number;
2362
+ alphaToCoverageEnabled?: boolean;
2363
+ }
2364
+ declare interface gpuGPUFragmentState {
2365
+ module: gpuGPUShaderModule;
2366
+ entryPoint: string;
2367
+ constants?: Record<string, number>;
2368
+ targets: gpuGPUColorTargetState[];
2369
+ }
2370
+ declare interface gpuGPUColorTargetState {
2371
+ format: string;
2372
+ blend: gpuGPUBlendState;
2373
+ writeMask?: number;
2374
+ }
2375
+ declare interface gpuGPUBlendState {
2376
+ color: gpuGPUBlendComponent;
2377
+ alpha: gpuGPUBlendComponent;
2378
+ }
2379
+ declare interface gpuGPUBlendComponent {
2380
+ operation?: string;
2381
+ srcFactor?: string;
2382
+ dstFactor?: string;
2383
+ }
2251
2384
  declare interface BasicImageTransformations {
2252
2385
  /**
2253
2386
  * Maximum width in image pixels. The value must be an integer.
@@ -243,6 +243,8 @@ export interface ServiceWorkerGlobalScope extends WorkerGlobalScope {
243
243
  GPUBufferUsage: typeof gpuGPUBufferUsage;
244
244
  GPUShaderStage: typeof gpuGPUShaderStage;
245
245
  GPUMapMode: typeof gpuGPUMapMode;
246
+ GPUTextureUsage: typeof gpuGPUTextureUsage;
247
+ GPUColorWrite: typeof gpuGPUColorWrite;
246
248
  }
247
249
  export declare function addEventListener<
248
250
  Type extends keyof WorkerGlobalScopeEventMap
@@ -1981,9 +1983,13 @@ export interface gpuGPUDevice extends EventTarget {
1981
1983
  createComputePipeline(
1982
1984
  descriptor: gpuGPUComputePipelineDescriptor
1983
1985
  ): gpuGPUComputePipeline;
1986
+ createRenderPipeline(
1987
+ descriptor: gpuGPURenderPipelineDescriptor
1988
+ ): gpuGPURenderPipeline;
1984
1989
  createCommandEncoder(
1985
1990
  descriptor?: gpuGPUCommandEncoderDescriptor
1986
1991
  ): gpuGPUCommandEncoder;
1992
+ createTexture(param1: gpuGPUTextureDescriptor): gpuGPUTexture;
1987
1993
  destroy(): void;
1988
1994
  createQuerySet(descriptor: gpuGPUQuerySetDescriptor): gpuGPUQuerySet;
1989
1995
  pushErrorScope(filter: string): void;
@@ -2253,6 +2259,133 @@ export interface gpuGPUCompilationMessage {
2253
2259
  export interface gpuGPUCompilationInfo {
2254
2260
  get messages(): gpuGPUCompilationMessage[];
2255
2261
  }
2262
+ export declare abstract class gpuGPUTextureUsage {
2263
+ static readonly COPY_SRC: number;
2264
+ static readonly COPY_DST: number;
2265
+ static readonly TEXTURE_BINDING: number;
2266
+ static readonly STORAGE_BINDING: number;
2267
+ static readonly RENDER_ATTACHMENT: number;
2268
+ }
2269
+ export interface gpuGPUTextureDescriptor {
2270
+ label: string;
2271
+ size: number[] | gpuGPUExtent3DDict;
2272
+ mipLevelCount?: number;
2273
+ sampleCount?: number;
2274
+ dimension?: string;
2275
+ format: string;
2276
+ usage: number;
2277
+ viewFormats?: string[];
2278
+ }
2279
+ export interface gpuGPUExtent3DDict {
2280
+ width: number;
2281
+ height?: number;
2282
+ depthOrArrayLayers?: number;
2283
+ }
2284
+ export interface gpuGPUTexture {
2285
+ createView(descriptor?: gpuGPUTextureViewDescriptor): gpuGPUTextureView;
2286
+ destroy(): void;
2287
+ get width(): number;
2288
+ get height(): number;
2289
+ get depthOrArrayLayers(): number;
2290
+ get mipLevelCount(): number;
2291
+ get dimension(): string;
2292
+ get format(): string;
2293
+ get usage(): number;
2294
+ }
2295
+ export interface gpuGPUTextureView {}
2296
+ export interface gpuGPUTextureViewDescriptor {
2297
+ label: string;
2298
+ format: string;
2299
+ dimension: string;
2300
+ aspect?: string;
2301
+ baseMipLevel?: number;
2302
+ mipLevelCount: number;
2303
+ baseArrayLayer?: number;
2304
+ arrayLayerCount: number;
2305
+ }
2306
+ export declare abstract class gpuGPUColorWrite {
2307
+ static readonly RED: number;
2308
+ static readonly GREEN: number;
2309
+ static readonly BLUE: number;
2310
+ static readonly ALPHA: number;
2311
+ static readonly ALL: number;
2312
+ }
2313
+ export interface gpuGPURenderPipeline {}
2314
+ export interface gpuGPURenderPipelineDescriptor {
2315
+ label?: string;
2316
+ layout: string | gpuGPUPipelineLayout;
2317
+ vertex: gpuGPUVertexState;
2318
+ primitive?: gpuGPUPrimitiveState;
2319
+ depthStencil?: gpuGPUDepthStencilState;
2320
+ multisample?: gpuGPUMultisampleState;
2321
+ fragment?: gpuGPUFragmentState;
2322
+ }
2323
+ export interface gpuGPUVertexState {
2324
+ module: gpuGPUShaderModule;
2325
+ entryPoint: string;
2326
+ constants?: Record<string, number>;
2327
+ buffers?: gpuGPUVertexBufferLayout[];
2328
+ }
2329
+ export interface gpuGPUVertexBufferLayout {
2330
+ arrayStride: number | bigint;
2331
+ stepMode?: string;
2332
+ attributes: gpuGPUVertexAttribute[];
2333
+ }
2334
+ export interface gpuGPUVertexAttribute {
2335
+ format: string;
2336
+ offset: number | bigint;
2337
+ shaderLocation: number;
2338
+ }
2339
+ export interface gpuGPUPrimitiveState {
2340
+ topology?: string;
2341
+ stripIndexFormat?: string;
2342
+ frontFace?: string;
2343
+ cullMode?: string;
2344
+ unclippedDepth?: boolean;
2345
+ }
2346
+ export interface gpuGPUStencilFaceState {
2347
+ compare?: string;
2348
+ failOp?: string;
2349
+ depthFailOp?: string;
2350
+ passOp?: string;
2351
+ }
2352
+ export interface gpuGPUDepthStencilState {
2353
+ format: string;
2354
+ depthWriteEnabled: boolean;
2355
+ depthCompare: string;
2356
+ stencilFront?: gpuGPUStencilFaceState;
2357
+ stencilBack?: gpuGPUStencilFaceState;
2358
+ stencilReadMask?: number;
2359
+ stencilWriteMask?: number;
2360
+ depthBias?: number;
2361
+ depthBiasSlopeScale?: number;
2362
+ depthBiasClamp?: number;
2363
+ }
2364
+ export interface gpuGPUMultisampleState {
2365
+ count?: number;
2366
+ mask?: number;
2367
+ alphaToCoverageEnabled?: boolean;
2368
+ }
2369
+ export interface gpuGPUFragmentState {
2370
+ module: gpuGPUShaderModule;
2371
+ entryPoint: string;
2372
+ constants?: Record<string, number>;
2373
+ targets: gpuGPUColorTargetState[];
2374
+ }
2375
+ export interface gpuGPUColorTargetState {
2376
+ format: string;
2377
+ blend: gpuGPUBlendState;
2378
+ writeMask?: number;
2379
+ }
2380
+ export interface gpuGPUBlendState {
2381
+ color: gpuGPUBlendComponent;
2382
+ alpha: gpuGPUBlendComponent;
2383
+ }
2384
+ export interface gpuGPUBlendComponent {
2385
+ operation?: string;
2386
+ srcFactor?: string;
2387
+ dstFactor?: string;
2388
+ }
2256
2389
  export interface BasicImageTransformations {
2257
2390
  /**
2258
2391
  * Maximum width in image pixels. The value must be an integer.