Skip to main content

MimDetectEvent

BoardSupported
Host SystemYes
V4L2Yes
Clarity UHDYes
Concord PoENo
GenTLYes
GevIQYes
GigE VisionYes
IndioNo
Iris GTXYes
Radient eV-CLYes
Rapixo CLYes
Rapixo CoFYes
Rapixo CXPYes
USB3 VisionYes

Detect if at least one of the pixels in the source image satisfies the specified condition.

Syntax

AIL_INT MimDetectEvent(
AIL_ID SrcImageBufId, //in
AIL_INT64 Condition, //in
AIL_DOUBLE CondLow, //in
AIL_DOUBLE CondHigh //in
)

Description

This function detects if at least one of the pixels in the source image satisfies the specified condition. To establish the location of the event, you can use MimLocateEvent.

You can limit this function's result to a region of the image buffer using a region of interest set using MbufSetRegion.

Parameters

SrcImageBufId (in, AIL_ID)

Specifies the identifier of the source image buffer. The buffer must be a 1-band image buffer.

Condition (in, AIL_INT64)

Specifies the condition under which pixel values are considered an event.

For conditions that use two limits

ValueDescription
M_IN_RANGESpecifies that pixels with values between CondLow and CondHigh, inclusive, are considered events.
M_OUT_RANGESpecifies that pixels with values less than CondLow, or greater than CondHigh, are considered events.

For conditions that use one limit

ValueDescription
M_EQUALSpecifies that only pixels with values equal to CondLow will be considered an event.
M_GREATERSpecifies that only pixels with values greater than CondLow will be considered an event.
M_GREATER_OR_EQUALSpecifies that only pixels with values greater than or equal to the CondLow will be considered an event.
M_LESSSpecifies that only pixels with values less than CondLow will be considered an event.
M_LESS_OR_EQUALSpecifies that only pixels with values less than or equal to CondLow will be considered an event.
M_NOT_EQUALSpecifies that only pixels with values not equal to CondLow will be considered an event.

CondLow (in, AIL_DOUBLE)

Specifies the lower limit of the selected condition.

For specifying the lower limit

ValueDescription
ValueSpecifies the lower limit.

CondHigh (in, AIL_DOUBLE)

Specifies the upper limit of the selected condition.

For specifying the upper limit

ValueDescription
M_NULLSpecifies that no upper limit is required. This setting should be selected for conditions that use one limit.
ValueSpecifies the upper limit.

Return Value

Type: AIL_INT

The returned value is M_TRUE if a pixel with the specified condition is found and M_FALSE otherwise.

Copyright © 2026 Zebra Technologies.