TMtxInt.Median Method

Overload List

#SignatureDescription
1function Median: Integer;Median.
└ indexed: function Median(Index: Integer; Len: Integer): Integer;
2function Median(const Src: TMtxVecInt; MaskSize: Integer; SrcIndex: Integer; Index: Integer; Len: Integer): TMtxVecInt;Applies median filter with size Mask to Src object elements [SrcIndex..SrcIndex+Len-1] and stores the result in the calling vector elements [Index..Index+Len-1].
3function Median(MaskSize: Integer; Index: Integer; Len: Integer): TMtxVecInt;Applies median filter with size Mask to the calling vector elements [Index.. Index+Len-1].

Overload 1: function Median: Integer;

Median.

Returns: Int32

Remarks:

Calculate median value for all calling object elements.

Indexed: function Median(Index: Integer; Len: Integer): Integer;

Calculate median value for calling vector elements [Index]..[Index+Len-1].

#NameTypeDescription
1IndexIntegerstart index
2LenIntegerelement count

Returns: Int32

Remarks:

An exception is raised if TMtxVecBase.ConditionCheck is true and array borders are overrun.

Overload 2: function Median(const Src: TMtxVecInt; MaskSize: Integer; SrcIndex: Integer; Index: Integer; Len: Integer): TMtxVecInt;

Applies median filter with size Mask to Src object elements [SrcIndex..SrcIndex+Len-1] and stores the result in the calling vector elements [Index..Index+Len-1].

#NameTypeDescription
1SrcTMtxVecIntsource TVecInt or TMtxInt
2MaskSizeInteger
3SrcIndexIntegersource start index
4IndexIntegerstart index
5LenIntegerelement count

Result: stored in self (calling object), returns self for chaining

Remarks:

Median filter is a nonlinear filter which replaces each element of the Src vector with the median value, calculated over the fixed range (mask) centered around that element and stores the result in the calling vector.

Overload 3: function Median(MaskSize: Integer; Index: Integer; Len: Integer): TMtxVecInt;

Applies median filter with size Mask to the calling vector elements [Index.. Index+Len-1].

#NameTypeDescription
1MaskSizeInteger
2IndexIntegerstart index
3LenIntegerelement count

Result: stored in self (calling object), returns self for chaining

Remarks:

Median filter is a nonlinear filter which replaces each element of the calling vector with the median value, calculated over the fixed range (mask) centered around that element.