Overload List
| # | Signature | Description |
|---|---|---|
| 1 | TOpenCLVector DownSample(TOpenCLMtxVec Src, Int32 Factor, Int32 Phase) | Downsamples vector values. |
| 2 | TOpenCLMtxVec DownSample(TOpenCLMtxVec Src, Int32 Factor, Int32 SrcIndex, Int32 Index, Int32 Len, Int32 Phase) | Downsamples object values. |
Overload 1: TOpenCLVector DownSample(TOpenCLMtxVec Src, Int32 Factor, Int32 Phase)
Downsamples vector values.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
| 2 | Factor | Int32 | |
| 3 | Phase | Int32 |
Returns: TOpenCLVector
The methods copies only every Factor sample from the Src vector to the calling vector. The Dew.Math.TOpenCLBase.Length and Dew.Math.TOpenCLBase.Complex properties of the calling vector are set implicitly. The phase parameter determines the initial sample offset. Phase must be less than Factor.
TOpenCLVector a;
TOpenCLVector b;
clMtxVec.CreateIt(a,b);
try
{
b.CopyFromArray(TSingleArray.Create(0,0,0,0,1,2,3,4,5,6));
a.DownSample(b,2); // a = new double[] {0,0,1,3,5}
}
finally
{
clMtxVec.FreeIt(a,b);
}
Overload 2: TOpenCLMtxVec DownSample(TOpenCLMtxVec Src, Int32 Factor, Int32 SrcIndex, Int32 Index, Int32 Len, Int32 Phase)
Downsamples object values.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
| 2 | Factor | Int32 | |
| 3 | SrcIndex | Int32 | source start index |
| 4 | Index | Int32 | start index |
| 5 | Len | Int32 | element count |
| 6 | Phase | Int32 |
Result: stored in self (calling object), returns self for chaining
Copy only every Factor sample from Src starting at SrcIndex up to Len to the calling object starting at Index. The phase parameter determines the initial sample offset. Phase must be less then Factor. Size and Dew.Math.TOpenCLBase.Complex properties of the calling object are set implicitly. An exception is raised if array borders are overrun/underrun.