ArrayExtensionsAsArray3DT(ArraySegmentT, Int32, Int32, Int32) Method
Gets an
Array3DT wrapper for the specified
ArraySegmentT.
The array segment must have enough capacity for the specified
depth,
height and
width.
No heap allocation occurs when using this method.
Namespace: KGySoft.CoreLibrariesAssembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 10.0.0
public static Array3D<T> AsArray3D<T>(
this ArraySegment<T> arraySegment,
int depth,
int height,
int width
)
<ExtensionAttribute>
Public Shared Function AsArray3D(Of T) (
arraySegment As ArraySegment(Of T),
depth As Integer,
height As Integer,
width As Integer
) As Array3D(Of T)
public:
[ExtensionAttribute]
generic<typename T>
static Array3D<T> AsArray3D(
ArraySegment<T> arraySegment,
int depth,
int height,
int width
)
[<ExtensionAttribute>]
static member AsArray3D :
arraySegment : ArraySegment<'T> *
depth : int *
height : int *
width : int -> Array3D<'T>
- arraySegment ArraySegmentT
- The desired underlying buffer for the Array3DT instance to be created.
It must have sufficient capacity for the specified dimensions.
- depth Int32
- The depth of the array to be returned.
- height Int32
- The height of the array to be returned.
- width Int32
- The width of the array to be returned.
- T
- The type of the elements in the array.
Array3DTAn
Array3DT instance using the specified
arraySegment as its underlying buffer that has the specified dimensions.In Visual Basic and C#, you can call this method as an instance method on any object of type
ArraySegmentT. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).