From 2bb0cfbf8137e02cc32aae3b36f85ef7300e8936 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Sat, 9 Jun 2018 14:29:41 +0300 Subject: Split UVC gadget into a library and test application Split the project into a UVC gadget library and a test application. To avoid rolling out a custom build system, switch to CMake. Signed-off-by: Laurent Pinchart --- video-source.c | 62 ---------------------------------------------------------- 1 file changed, 62 deletions(-) delete mode 100644 video-source.c (limited to 'video-source.c') diff --git a/video-source.c b/video-source.c deleted file mode 100644 index 06092f5..0000000 --- a/video-source.c +++ /dev/null @@ -1,62 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-or-later */ -/* - * Abstract video source - * - * Copyright (C) 2018 Laurent Pinchart - * - * Contact: Laurent Pinchart - */ - -#include "video-source.h" - -void video_source_set_buffer_handler(struct video_source *src, - video_source_buffer_handler_t handler, - void *data) -{ - src->handler = handler; - src->handler_data = data; -} - -void video_source_destroy(struct video_source *src) -{ - if (src) - src->ops->destroy(src); -} - -int video_source_set_format(struct video_source *src, - struct v4l2_pix_format *fmt) -{ - return src->ops->set_format(src, fmt); -} - -int video_source_alloc_buffers(struct video_source *src, unsigned int nbufs) -{ - return src->ops->alloc_buffers(src, nbufs); -} - -int video_source_export_buffers(struct video_source *src, - struct video_buffer_set **buffers) -{ - return src->ops->export_buffers(src, buffers); -} - -int video_source_free_buffers(struct video_source *src) -{ - return src->ops->free_buffers(src); -} - -int video_source_stream_on(struct video_source *src) -{ - return src->ops->stream_on(src); -} - -int video_source_stream_off(struct video_source *src) -{ - return src->ops->stream_off(src); -} - -int video_source_queue_buffer(struct video_source *src, - struct video_buffer *buf) -{ - return src->ops->queue_buffer(src, buf); -} -- cgit v1.2.3