summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--stream.c2
-rw-r--r--uvc.c5
-rw-r--r--uvc.h1
3 files changed, 7 insertions, 1 deletions
diff --git a/stream.c b/stream.c
index 6fb5a42..ba9a924 100644
--- a/stream.c
+++ b/stream.c
@@ -243,8 +243,8 @@ void uvc_stream_init_uvc(struct uvc_stream *stream,
* FIXME: The maximum size should be specified per format and frame.
*/
stream->uvc->maxsize = 0;
- stream->uvc->fc = fc;
+ uvc_set_config(stream->uvc, fc);
uvc_events_init(stream->uvc, stream->events);
}
diff --git a/uvc.c b/uvc.c
index 7131a50..0a276a4 100644
--- a/uvc.c
+++ b/uvc.c
@@ -341,3 +341,8 @@ void uvc_events_init(struct uvc_device *dev, struct events *events)
events_watch_fd(events, dev->vdev->fd, EVENT_EXCEPTION,
uvc_events_process, dev);
}
+
+void uvc_set_config(struct uvc_device *dev, struct uvc_function_config *fc)
+{
+ dev->fc = fc;
+}
diff --git a/uvc.h b/uvc.h
index febc662..c1138bf 100644
--- a/uvc.h
+++ b/uvc.h
@@ -48,5 +48,6 @@ struct uvc_device
struct uvc_device *uvc_open(const char *devname, struct uvc_stream *stream);
void uvc_close(struct uvc_device *dev);
void uvc_events_init(struct uvc_device *dev, struct events *events);
+void uvc_set_config(struct uvc_device *dev, struct uvc_function_config *fc);
#endif /* __UVC_H__ */