Skip to main content

camera_open

Function camera_open 

Source
pub fn camera_open() -> i32
Expand description

Opens the default camera. Gated by an in-browser permission prompt on first use per origin.

Returns 0 on success. Negative codes: -1 user blocked, -2 no camera, -3 open failed, PERMISSION_PENDING while the prompt is showing (retry next frame).