@face-auth/face-id-video
Version:
Utility library for capturing photos from webcam video streams in the browser. Handles camera selection, image formatting, and output for face authentication APIs.
20 lines (19 loc) • 520 B
TypeScript
import { CameraOptions } from "./types/CameraOptions";
import { FaceVideoElement } from "./types/FaceVideoElement";
export declare class FaceCameraManager {
private video;
private stream;
constructor(videoElement: HTMLVideoElement);
/**
* List available cameras
*/
getDevices(): Promise<MediaDeviceInfo[]>;
/**
* Start video stream
*/
start(options?: CameraOptions, deviceId?: string): Promise<FaceVideoElement>;
/**
* Stop the camera
*/
stop(): void;
}