Age | Commit message (Collapse) | Author |
|
Replace the manual V4L2 capture implementation by an abstract
video_source, provided by the user of the UVC stream. Removes any
knowledge of the video source internals from the uvc_stream class,
allowing usage of different source types.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The v4l2_video_buffer structure describes a video buffer. It is used by
the v4l2_device class only, but isn't otherwise tied to V4L2. To prepare
for non-V4L2 video sources, extract it to a separate file and rename it
to video_buffer.
At the same time, add a new video_buffer_set structure to represent as
set of video buffers.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The uvc_device maxsize field is initialized in stream.c, requiring
access to the uvc_device internals. Move its initialization to uvc.c.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
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>
|
|
Add a uvc_set_config() function to set the UVC function configuration
instead of accessing the internals of the uvc_device in stream.c.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The internals of the uvc_stream structure don't need to be accessed
outside stream.c. Move the structure definition from stream.h to
stream.c to make it opaque.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
The event notifier for the UVC device is registered in
uvc_stream_set_event_handler(), which requires exposing the
uvc_events_process() event handler to the uvc_stream class.
Make the event handler internal by registering it in uvc_events_init().
This requires passing the uvc_stream pointer to the uvc_open() function
and storing it internally in the uvc_device object.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
|
uvc-gadget.c has been getting cluttered with functions related to
UVC protocol handling and stream handling. Additionally, it is forseen
that we might want stream handling to be modular for different system
models. Factor out code related to UVC protocol handling to uvc.c (and
uvc.h) and code related to stream handling to stream.c (and stream.h),
and update the Makefile accordingly.
Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|