Copies a range of elements from the array starting at the specified sourceIndex and pastes them to the unmanaged array starting at the specified destinationIndex. The length and the indexes are specified as 32-bit integers.

Namespace:  FreeImageAPI
Assembly:  FreeImageNET (in FreeImageNET.dll)

Syntax

C#
public void CopyFrom(
	T[] array,
	int sourceIndex,
	int destinationIndex,
	int length
)
Visual Basic (Declaration)
Public Sub CopyFrom ( _
	array As T(), _
	sourceIndex As Integer, _
	destinationIndex As Integer, _
	length As Integer _
)
Visual C++
public:
void CopyFrom(
	array<T>^ array, 
	int sourceIndex, 
	int destinationIndex, 
	int length
)

Parameters

array
Type: array< T >[]()[]
The array that holds the data.
sourceIndex
Type: System..::.Int32
A 32-bit integer that represents the index in the array at which copying begins.
destinationIndex
Type: System..::.Int32
A 32-bit integer that represents the index in the unmanaged array at which storing begins.
length
Type: System..::.Int32
A 32-bit integer that represents the number of elements to copy.

Exceptions

ExceptionCondition
System..::.ArgumentNullException array is a null reference (Nothing in Visual Basic).
System..::.ArgumentOutOfRangeException sourceIndex is outside the range of valid indexes for the array or length is greater than the number of elements from index to the end of the array

-or-

destinationIndex is outside the range of valid indexes for the unmanaged array or length is greater than the number of elements from index to the end of the unmanaged array.

Version Information

FreeImage.NET

Supported in: 3.11.0, 3.12.0, 3.13.0, 3.13.1

See Also