Overload List
| # | Signature | Description |
|---|---|---|
| 1 | function ThresholdGT_LT(const GTLevel: Integer; const GTValue: Integer; const LTLevel: Integer; const LTValue: Integer): TMtxVecInt; | Threshold greater than and less than operation. |
| └ indexed: function ThresholdGT_LT(const GTLevel: Integer; const GTValue: Integer; const LTLevel: Integer; const LTValue: Integer; Index: Integer; Len: Integer): TMtxVecInt; | ||
| 2 | function ThresholdGT_LT(const Vec: TMtxVecInt; const GTLevel: Integer; const GTValue: Integer; const LTLevel: Integer; const LTValue: Integer): TMtxVecInt; | Perform "greater than and less than" threshold operation on all Vec object values. |
| 3 | function ThresholdGT_LT(const Vec: TMtxVecInt; const GTLevel: Integer; const GTValue: Integer; const LTLevel: Integer; const LTValue: Integer; VecIndex: Integer; Index: Integer; Len: Integer): TMtxVecInt; | Perform "greater than and less than" threshold operation on Vec elements from range [VecIndex]..[VecIndex+Len-1]. |
Overload 1: function ThresholdGT_LT(const GTLevel: Integer; const GTValue: Integer; const LTLevel: Integer; const LTValue: Integer): TMtxVecInt;
Threshold greater than and less than operation.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | GTLevel | Integer | |
| 2 | GTValue | Integer | |
| 3 | LTLevel | Integer | |
| 4 | LTValue | Integer |
Result: stored in self (calling object), returns self for chaining
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.
var a: TVecInt;
begin
CreateIt(a);
try
a.SetIt([20,1,30,40]);
a.ThresholdGT_LT(23,34,10,5); // a = [20,5,34,34]
finally
FreeIt(a);
end;
end;
Indexed: function ThresholdGT_LT(const GTLevel: Integer; const GTValue: Integer; const LTLevel: Integer; const LTValue: Integer; Index: Integer; Len: Integer): TMtxVecInt;
Perfrom "greater than and less than" threshold operation on the calling object values in range [Index]..[Index+Len-1].
| # | Name | Type | Description |
|---|---|---|---|
| 1 | GTLevel | Integer | |
| 2 | GTValue | Integer | |
| 3 | LTLevel | Integer | |
| 4 | LTValue | Integer | |
| 5 | Index | Integer | start index |
| 6 | Len | Integer | element count |
Result: stored in self (calling object), returns self for chaining
An exception is raised if array borders are overrun/underrun.
var a: TMtxInt;
begin
CreateIt(a);
try
a.SetIt(2,2,[20,1,30,40]);
a.ThresholdGT_LT(23,34,10,5); // a = [20,5,34,34]
finally
FreeIt(a);
end;
end;
Overload 2: function ThresholdGT_LT(const Vec: TMtxVecInt; const GTLevel: Integer; const GTValue: Integer; const LTLevel: Integer; const LTValue: Integer): TMtxVecInt;
Perform "greater than and less than" threshold operation on all Vec object values.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Vec | TMtxVecInt | |
| 2 | GTLevel | Integer | |
| 3 | GTValue | Integer | |
| 4 | LTLevel | Integer | |
| 5 | LTValue | Integer |
Result: stored in self (calling object), returns self for chaining
Store the results in calling object. Size of the calling object is adjusted automatically.
Overload 3: function ThresholdGT_LT(const Vec: TMtxVecInt; const GTLevel: Integer; const GTValue: Integer; const LTLevel: Integer; const LTValue: Integer; VecIndex: Integer; Index: Integer; Len: Integer): TMtxVecInt;
Perform "greater than and less than" threshold operation on Vec elements from range [VecIndex]..[VecIndex+Len-1].
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Vec | TMtxVecInt | |
| 2 | GTLevel | Integer | |
| 3 | GTValue | Integer | |
| 4 | LTLevel | Integer | |
| 5 | LTValue | Integer | |
| 6 | VecIndex | Integer | |
| 7 | Index | Integer | start index |
| 8 | Len | Integer | element count |
Result: stored in self (calling object), returns self for chaining
Store the results in the calling object elements [Index]..[Index+Len-1]. Size of the calling object must be set explicitly. An exception is raised if TMtxVecBase.ConditionCheck is true and array borders are overrun/underrun.