Skip to content

@camera.ui/sdk / plugin / MotionDetectionInterface

Interface: MotionDetectionInterface

Defined in: plugin/interfaces.ts:245

Implemented by plugins that perform video-based motion detection. The host invokes testMotionDetection() from the UI test panel and detectMotion() from automation / benchmark pipelines.

Methods

detectMotion()?

optional detectMotion(frames, config?): Promise<MotionDetectionPluginResponse | undefined>

Defined in: plugin/interfaces.ts:249

Run detection on already-decoded frames, supplied by automation / benchmark pipelines to avoid re-encoding.

Parameters

frames

VideoFrameData[]

config?

Record<string, unknown>

Returns

Promise<MotionDetectionPluginResponse | undefined>


motionDetectionSettings()?

optional motionDetectionSettings(): Promise<JsonSchema[] | undefined>

Defined in: plugin/interfaces.ts:251

Return the JSON schema used to render the motion-detection settings form in the UI, or undefined for no schema.

Returns

Promise<JsonSchema[] | undefined>


testMotionDetection()

testMotionDetection(videoData, config): Promise<MotionDetectionPluginResponse | undefined>

Defined in: plugin/interfaces.ts:247

Run detection on a raw video buffer captured by the UI test panel and return the result for preview rendering.

Parameters

videoData

Buffer<ArrayBufferLike> | Uint8Array<ArrayBufferLike>

config

Record<string, unknown>

Returns

Promise<MotionDetectionPluginResponse | undefined>