CastArray3DTFrom, TToSlice(Int32) Method

Gets a new CastArray3DTFrom, TTo instance, which represents a subrange of planes of the current instance starting with the specified startPlaneIndex. Please note that the size of TTo multiplied by Width times Height must be divisible by the size of TFrom.

Definition

Namespace: KGySoft.Collections
Assembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 10.0.0
C#
public CastArray3D<TFrom, TTo> Slice(
	int startPlaneIndex
)

Parameters

startPlaneIndex  Int32
The offset that points to the first plane of the returned CastArray3DTFrom, TTo.

Return Value

CastArray3DTFrom, TTo
The subrange of planes of the current CastArray3DTFrom, TTo instance starting with the specified startPlaneIndex.

Exceptions

ArgumentOutOfRangeExceptionstartPlaneIndex is out of range.
ArgumentExceptionThe size of TTo multiplied by Width times Height is not divisible by the size of TFrom.

See Also