# SDL_Camera

A handle to a physical camera device. Freed when references drop or camera is closed.


### frame() <sub>function</sub>

Acquire the latest camera frame (as an SDL_Surface). Returns undefined if no
new frame is available yet. Throws on error.



**Returns**: SDL_Surface or undefined.


### release_frame(surface) <sub>function</sub>

Release a frame surface previously acquired via camera.frame(). Must be
done for each acquired frame.



**surface**: The surface to release.


**Returns**: None

