function UpSample(const Src: TOpenCLMtxVec; Factor: integer; Phase: integer = 0): TOpenCLVector; overload;
Inserts zeroes between consecutive vector values.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
| 2 | Factor | integer | |
| 3 | Phase | integer |
Returns: TOpenCLVector
Remarks:
Inserts zeroes between consecutive vector values. The method copies the values from Src to the calling vector and places Factor-1 zeros between consecutive values. The TOpenCLBase.Length and TOpenCLBase.Complex properties of the calling vector are set implicitly. Phase parameter defines the initial sample offset and must be less than Factor.
Examples
var a,b: clVector;
begin
b.CopyFromArray(TSingleArray.Create(0,0,1,3,2));
a.UpSample(b,2); // a = [0,0,0,0,1,0,3,0,2,0]
end;
See Also: clVector.DownSample, TOpenCLMtxVec.DownSample, TOpenCLMtxVec.UpSample
Indexed: function UpSample(const Src: TOpenCLMtxVec; Factor, SrcIndex, Index, Len, Phase: integer): TOpenCLMtxVec; overload;
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
| 2 | Factor | integer | |
| 3 | SrcIndex | integer | source start index |
| 4 | Index | integer | start index |
| 5 | Len | integer | element count |
| 6 | Phase | integer |
Result: stored in self (calling object), returns self for chaining