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

Threshold greater than and less than operation.

Pascal
function ThresholdGT_LT(GTLevel: double; GTValue: double; LTLevel: double; LTValue: double): TOpenCLMtxVec; overload;

Perform operation on all calling object values. The LTValue parameter is an lower bound for threshold operation. The GTValue parameter is an upper bound for threshold operation. All values less than LTLevel will be replaced with LTValue. All values bigger than GTLevel will be replaced with GTValue. Operation is available only for none Complex values.

var a: clVector; begin a.CopyFromArray(TSingleArray.Create(2,0.1,3,4)); a.ThresholdGT_LT(2.3,3.4,1,0.5); // a = [2,0.5,3.4,3.4] end;
Examples on GitHub
Copyright (c) 1999-2024 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!