diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2018-06-09 02:45:00 +0300 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2018-06-09 02:55:47 +0300 |
commit | 2483a44374433299866b0c16e35ccea40b5379e5 (patch) | |
tree | 4e0db44dcd69a39e93f8f7f5be8255b307a88b18 /stream.h | |
parent | 3e5b2d028c743f8e6f22aae74471a2f1be25d120 (diff) |
uvc: Add API to set video format
Add a uvc_setformat() function to set the format for the UVC video
stream instead of accessing the internals of the uvc_device in
stream.c.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'stream.h')
-rw-r--r-- | stream.h | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -23,6 +23,7 @@ struct events; struct uvc_function_config; struct uvc_stream; +struct v4l2_pix_format; /* * uvc_stream_new - Create a new UVC stream @@ -87,13 +88,15 @@ void uvc_stream_delete(struct uvc_stream *stream); /* * uvc_stream_set_format - Set the active video format for the stream * @stream: the UVC stream + * @format: the video stream format * * This function is called from the UVC protocol handler to configure the video * format for the @stream. It must not be called directly by applications. * * Returns 0 on success, or a negative error code on failure. */ -int uvc_stream_set_format(struct uvc_stream *stream); +int uvc_stream_set_format(struct uvc_stream *stream, + const struct v4l2_pix_format *format); /* * uvc_stream_enable - Turn on/off video streaming for the UVC stream |