GPUTextureDescriptor


class GPUTextureDescriptor


Describes a texture to be created.

Summary

Nested types

Builder for GPUTextureDescriptor.

Public constructors

GPUTextureDescriptor(
    usage: Int,
    size: GPUExtent3D,
    label: String?,
    dimension: Int,
    format: Int,
    mipLevelCount: Int,
    sampleCount: Int,
    viewFormats: IntArray,
    textureBindingViewDimension: GPUTextureBindingViewDimension?
)

Public properties

Int

The dimension of the texture.

Int

The format of the texture.

String?

A human-readable label for debugging.

Int
Int
GPUExtent3D

The size of the texture.

GPUTextureBindingViewDimension?
Int

The allowed usages for the texture.

IntArray

Public constructors

GPUTextureDescriptor

Added in 1.0.0-alpha06
GPUTextureDescriptor(
    usage: Int,
    size: GPUExtent3D,
    label: String? = null,
    dimension: Int = TextureDimension._2D,
    format: Int = TextureFormat.Undefined,
    mipLevelCount: Int = 1,
    sampleCount: Int = 1,
    viewFormats: IntArray = intArrayOf(),
    textureBindingViewDimension: GPUTextureBindingViewDimension? = null
)

Public properties

dimension

Added in 1.0.0-alpha06
var dimension: Int

The dimension of the texture. Defaults to @see TextureDimension._2D.

Value is one of the following:

  • 0
  • 1
  • 2
  • 3

format

Added in 1.0.0-alpha06
var format: Int

The format of the texture.

Value is one of the following:

  • 0
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101

label

Added in 1.0.0-alpha06
var label: String?

A human-readable label for debugging.

mipLevelCount

Added in 1.0.0-alpha06
var mipLevelCount: Int

sampleCount

Added in 1.0.0-alpha06
var sampleCount: Int

size

Added in 1.0.0-alpha06
var size: GPUExtent3D

The size of the texture.

textureBindingViewDimension

Added in 1.0.0-alpha06
var textureBindingViewDimension: GPUTextureBindingViewDimension?

usage

Added in 1.0.0-alpha06
var usage: Int

The allowed usages for the texture.

Value is either 0 or a combination of the following:

  • 0
  • 1
  • 2
  • 4
  • 8
  • 16
  • 32

viewFormats

Added in 1.0.0-alpha06
var viewFormats: IntArray

Value is one of the following:

  • 0
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101