TOpenCLMtxVec Copy(TOpenCLMtxVec Src)
Copy object values.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
Result: stored in self (calling object), returns self for chaining
Remarks:
Copy each of Vec elements to the calling object. Size and Dew.Math.TOpenCLBase.Complex properties of the calling object are set implicitly to match Vec object.
Examples
clMatrix a;
clMatrix b;
clMatrix c;
a.CopyFromArray(2,2,TSingleArray.Create(1,2,3,4)); // a = new double[] {1,2,3,4}
b.Copy(a); // b = new double[] {1,2,3,4}
Indexed: TOpenCLMtxVec Copy(TOpenCLMtxVec Vec, Int32 VecIndex, Int32 Index, Int32 Len)
Copy Vec elements [VecIndex]..[VecIndex+Len-1] in the calling object elements [Index]..[Index+Len-1].
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Vec | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
| 2 | VecIndex | Int32 | |
| 3 | Index | Int32 | start index |
| 4 | Len | Int32 | element count |
Result: stored in self (calling object), returns self for chaining
Remarks:
Size and Dew.Math.TOpenCLBase.Complex properties must be set explicitly. An exception is raised if array borders are overrun or underrun.