GPUTextureDescriptor constructor

GPUTextureDescriptor({
  1. dynamic size,
  2. int? mipLevelCount,
  3. int? sampleCount,
  4. GPUTextureDimension? dimension,
  5. GPUTextureFormat? format,
  6. int? usage,
  7. Iterable<GPUTextureFormat>? viewFormats,
})

Implementation

factory GPUTextureDescriptor(
        {dynamic size,
        int? mipLevelCount,
        int? sampleCount,
        GPUTextureDimension? dimension,
        GPUTextureFormat? format,
        int? usage,
        Iterable<GPUTextureFormat>? viewFormats}) =>
    GPUTextureDescriptor._(
        size: size ?? undefined,
        mipLevelCount: mipLevelCount ?? 1,
        sampleCount: sampleCount ?? 1,
        dimension: dimension?.value ?? GPUTextureDimension.value2d.value,
        format: format?.value ?? undefined,
        usage: usage ?? undefined,
        viewFormats: viewFormats?.map((e) => e.value) ?? const []);