Composite#

rforge.library.processes.composite.composite(layers: list[Layer] | list[ndarray], alpha: Layer | ndarray | None = None, gamma: list | tuple | None = None, as_array: bool = False) ndarray | Layer[source]#

Stacks all provided layers into a single array in order, including alpha. Applies gamma correction if provided.

Parameters:
  • layers – List of raster layers.

  • alpha – Alpha layer. Defaults to None.

  • gamma – List of gamma values to apply to each layer. Defaults to None.

  • as_array – If True, returns the distance field as a Numpy array. Defaults to False.

Returns:

Stacked composite layer.

Raises:

TypeError – If inputs are not of the accepted type.