L
LocalMode-AI
/
LocalMode
/
hooks
Files
Code
Info
useWebcam
ui/media-vision/use-webcam
A React hook that owns a getUserMedia video stream: start() acquires (or re-acquires after a denial - the retry path), stop() releases every track, and unmount cleanup guarantees the camera light goes off. Runtime permission denial surfaces as a recoverable error (permission / hardware / unknown) rather than a thrown exception. Returns { stream, isActive, error, start, stop, clearError }; exports WebcamError / WebcamErrorKind. Imports only React and browser APIs - zero @localmode. Powers webcam-driven vision surfaces (object detection, live landmark tracking).
Select a component to view its code
Click on any item in the sidebar to get started
Select a component to view its information
useWebcam
ui/media-vision/use-webcam
A React hook that owns a getUserMedia video stream: start() acquires (or re-acquires after a denial - the retry path), stop() releases every track, and unmount cleanup guarantees the camera light goes off. Runtime permission denial surfaces as a recoverable error (permission / hardware / unknown) rather than a thrown exception. Returns { stream, isActive, error, start, stop, clearError }; exports WebcamError / WebcamErrorKind. Imports only React and browser APIs - zero @localmode. Powers webcam-driven vision surfaces (object detection, live landmark tracking).
Select a component to view its code
Click on any item in the sidebar to get started
Select a component to view its information