cuda.core.texture.MipmappedArrayOptions#

class cuda.core.texture.MipmappedArrayOptions(
shape: tuple[int, ...],
format: object,
num_channels: int,
num_levels: int,
is_surface_load_store: bool = False,
)#

Options for cuda.core.Device.create_mipmapped_array().

shape#

(width,), (width, height), or (width, height, depth) in elements, for the base (level 0) mip.

Type:

tuple of int

format#

Element format. Accepts an ArrayFormatType, a plain string (e.g. "float32"), or a NumPy dtype object.

Type:

ArrayFormatType, str, or numpy.dtype

num_channels#

Channels per element. Must be 1, 2, or 4.

Type:

int

num_levels#

Number of mip levels to allocate; must be >= 1. The driver caps this at the log2 of the largest dimension; passing a larger value yields a driver error.

Type:

int

is_surface_load_store#

If True, allocate with CUDA_ARRAY3D_SURFACE_LDST so individual levels (obtained via MipmappedArray.get_level()) can be bound as a SurfaceObject for kernel-side writes. Default False.

Type:

bool

.. versionadded:: 1.1.0