You are here: Symbol Reference > clMtxExpr Namespace > Classes > clVector Record > public > UpSample Method > clVector.UpSample Method (TOpenCLMtxVec, integer, integer)
MtxVec VCL
ContentsIndex
PreviousUpNext
clVector.UpSample Method (TOpenCLMtxVec, integer, integer)

Inserts zeroes between consecutive vector values.

Pascal
function UpSample(const Src: TOpenCLMtxVec; Factor: integer; Phase: integer = 0): TOpenCLVector; overload;

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.LengthLengthand TOpenCLBase.ComplexComplexproperties of the calling vector are set implicitly. Phase parameter defines the initial sample offset and must be less than Factor.

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;
Examples on GitHub
Copyright (c) 1999-2025 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!