CogStatistics GetBufferedNumSamples Method Cognex VisionPro 9.24
The number of samples over the specified range of buffered values. Invalid values will not be included in the value returned. Index 0 represents the oldest value. Index NumBufferedValues-1 represents the most recent value.

Namespace: Cognex.VisionPro
Assembly: Cognex.VisionPro.Core (in Cognex.VisionPro.Core.dll) Version: 91.0.0.0
Syntax

public int GetBufferedNumSamples(
	int startIndex,
	int endIndex
)

Parameters

startIndex
Type: System Int32

The 0-based index of the first buffered value to consider.

endIndex
Type: System Int32

The 0-based index of the last buffered value to consider.

Return Value

Type: Int32

The number of valid samples.

Exceptions

ExceptionCondition
ArgumentException

startIndex is less than 0 or startIndex is greater than or equal to NumBufferedValues.

ArgumentException

endIndex is not cogNoIndex and endIndex is less than startIndex or endIndex is greater than or equal to NumBufferedValues.

Remarks

The number of valid samples within the specified range of buffered values. An index of 0 represents the oldest value; an index of NumBufferedValues - 1 represents the most recent value.

Note: This total does not include invalid values.

See Also