Allow camera engines to signal events to the card.

This commit is contained in:
Dermot Duffy
2024-03-03 15:40:20 -08:00
parent 305a2db573
commit 88bea0ae7d
61 changed files with 7480 additions and 4213 deletions
+16
View File
@@ -150,6 +150,22 @@ export interface EngineOptions {
useCache?: boolean;
}
export interface CameraEvent {
cameraID: string;
type: 'new' | 'update' | 'end';
// When fidelity is `high`, the engine is assumed to provide exact details of
// what new media is available. Otherwise all media types are assumed to be
// possibly newly available.
fidelity?: 'high' | 'low';
// Whether a new clip/snapshot/recording may be available.
clip?: boolean;
snapshot?: boolean;
}
export type CameraEventCallback = (ev: CameraEvent) => void;
// ===========
// Event Query
// ===========