debian/0000755000000000000000000000000012232544627007175 5ustar debian/rules0000755000000000000000000000033712232541316010250 0ustar #!/usr/bin/make -f %: dh $@ override_dh_auto_install-arch: $(MAKE) PREFIX=$(CURDIR)/debian/uvccapture/usr/bin install override_dh_install: dh_installchangelogs ChangeLog dh_installman debian/uvccapture.1 dh_install debian/uvccapture.10000644000000000000000000000333111773354360011442 0ustar .\" -*- nroff -*- .TH UVCCAPTURE 1 "28th March, 2008" .SH NAME uvccapture \- USB UVC Video Class snapshot software .SH SYNOPSIS .B uvccapture .RI [ options ] .SH DESCRIPTION This manual page documents briefly the .B uvccapture command. .PP The purpose of \fBuvccapture\fP is to capture an image from a USB webcam at a specified interval, and save it to a JPEG file, no other formats are supported, imagemagick can handle anything else you might need. .SH OPTIONS A summary of options is included below. .TP .B \-h Show summary of options. .TP .B \-v Verbose output. .TP .B \-o Output filename (default is snap.jpg) .TP .B \-d V4L2 Device (default is /dev/video0) .TP .B \-x Image Width (must be supported by device) (>960 activates YUYV capture) .TP .B \-y Image Height (must be supported by device) (>720 activates YUYV capture) .TP .B \-c Command to run after each image capture (executed as ) .TP .B \-t Take continuous shots with seconds between them (0 for single shot) .TP .B \-q JPEG Quality Compression Level (activates YUYV capture) .TP .B \-r Use read instead of mmap for image capture .TP .B \-w Wait for capture command to finish before starting next capture .TP .B \-m Toggles capture mode to YUYV capture .TP .B \-B Brightness .TP .B \-C Contrast .TP .B \-S Saturation .SH SEE ALSO .BR http://linux-uvc.berlios.de/ .SH AUTHOR uvccapture was written by Gabriel A. Devenyi . This software is based of the package luvcview by Laurent Pinchart and Michel Xhaard. .PP This manual page was written by Krzysztof Burghardt , for the Debian project (but may be used by others). debian/copyright0000644000000000000000000000253411773361461011136 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: uvccapture Upstream-Contact: Gabriel A. Devenyi Source: http://staticwave.ca/source/uvccapture/ Files: * Copyright: 2006, Gabriel A. Devenyi 2005-2006, Laurent Pinchart 2005-2006, Michel Xhaard License: GPL-2+ Files: debian/* Copyright: 2008, Krzysztof Burghardt 2012, Andrew Starr-Bochicchio License: GPL-2+ License: GPL-2+ This package is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. . This package is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this package; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA . On Debian systems, the complete text of the GNU General Public License can be found in `/usr/share/common-licenses/GPL-2'. debian/changelog0000644000000000000000000000512512232544627011052 0ustar uvccapture (0.5-3) unstable; urgency=low * Use returned number of buffers instead of requested. Thanks to Bas Wijnen for the patch (Closes: #726802). * debian/control: - Bump Standards-Version to 3.9.4 - Use my @debian.org address in the maintainer field. * Patch upstream Makefile inorder to use hardening flags. Thanks to Bas Wijnen for the patch (Closes: #726804). * Fix several warnings during the build: redefined symbols (which weren't referenced) and unused variables. Again, thanks to Bas Wijnen! -- Andrew Starr-Bochicchio Fri, 25 Oct 2013 15:42:10 -0400 uvccapture (0.5-2) unstable; urgency=low * Adopt package, adding myself as maintainer (Closes: #678860). * debian/patches/fix_videodev_include_FTBFS.patch: Move changes to upstream source to a proper patch system. * Move to a simplified dh style rules file and debhelper compat version 9, bumping the debhelper build dependency to >= 9. * Bump Standards-Version to 3.9.3.1 * Don't install TODO file, there's nothing very interesting there. * debian/copyright: Use machine readable copyright-format 1.0. * Create a collab-maint git repo on Alioth and add Vcs fields. -- Andrew Starr-Bochicchio Fri, 29 Jun 2012 14:23:50 -0400 uvccapture (0.5-1.2) unstable; urgency=low * Non-maintainer upload. * Build-Depends on libjpeg-dev, not libjpeg62-dev. Closes: #644969. -- Didier Raboud Mon, 21 Nov 2011 10:02:58 +0100 uvccapture (0.5-1.1) unstable; urgency=low * Non-maintainer upload. * uvccapture.c, v4l2uvc.c: Include linux/videodev2.h. Closes: #621963. -- Bart Martens Sun, 02 Oct 2011 22:04:40 +0200 uvccapture (0.5-1) unstable; urgency=low * New upstream release, all Debian patches merged -- Krzysztof Burghardt Sun, 03 Aug 2008 22:02:38 +0200 uvccapture (0.4-2) unstable; urgency=low * Add patch submited by Arno van Amersfoort to prevent double call to close_v4l2() (Closes: #491155) * Add patch from Sebastian Holtermann that fixes problems with implicit declaration of function ‘difftime’ * "Standards-Version:" bumped to 3.8.0 (no changes needed) * This package is licensed on GPL v2 or above, so it is more customary to point to /usr/share/common-licenses/GPL and not (only) to GPL-2 (debian/copyright fixed). -- Krzysztof Burghardt Sun, 03 Aug 2008 21:52:54 +0200 uvccapture (0.4-1) unstable; urgency=low * Initial release (Closes: #473153) -- Krzysztof Burghardt Fri, 28 Mar 2008 19:13:23 +0100 debian/watch0000644000000000000000000000011311773354360010223 0ustar version=3 http://staticwave.ca/source/uvccapture/uvccapture-(.*)\.tar\.bz2 debian/dirs0000644000000000000000000000001011773364167010060 0ustar usr/bin debian/compat0000644000000000000000000000000211773357007010376 0ustar 9 debian/patches/0000755000000000000000000000000012232544224010615 5ustar debian/patches/warnings.patch0000644000000000000000000000522112232544072013467 0ustar Description: Remove build warnings This patch fixes several warnings during the build: redefined symbols (which weren't referenced) and unused variables. Last-Update: 2013-10-19 Author: Bas Wijnen Debian-Bug: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=726804 --- uvccapture-0.5.orig/Makefile +++ uvccapture-0.5/Makefile @@ -18,6 +18,8 @@ LDFLAGS = $(DPKG_LDFLAGS) OBJECTS= uvccapture.o v4l2uvc.o +%.o: %.c v4l2uvc.h + $(CC) $(CPPFLAGS) $(CFLAGS) -c $< -o $@ all: uvccapture --- uvccapture-0.5.orig/v4l2uvc.c +++ uvccapture-0.5/v4l2uvc.c @@ -397,15 +397,13 @@ v4l2SetControl (struct vdIn *vd, int con { struct v4l2_control control_s; struct v4l2_queryctrl queryctrl; - int min, max, step, val_def; + int min, max; int err; if (isv4l2Control (vd, control, &queryctrl) < 0) return -1; min = queryctrl.minimum; max = queryctrl.maximum; - step = queryctrl.step; - val_def = queryctrl.default_value; if ((value >= min) && (value <= max)) { control_s.id = control; control_s.value = value; @@ -422,15 +420,13 @@ v4l2UpControl (struct vdIn *vd, int cont { struct v4l2_control control_s; struct v4l2_queryctrl queryctrl; - int min, max, current, step, val_def; + int max, current, step; int err; if (isv4l2Control (vd, control, &queryctrl) < 0) return -1; - min = queryctrl.minimum; max = queryctrl.maximum; step = queryctrl.step; - val_def = queryctrl.default_value; current = v4l2GetControl (vd, control); current += step; if (current <= max) { @@ -449,15 +445,13 @@ v4l2DownControl (struct vdIn *vd, int co { struct v4l2_control control_s; struct v4l2_queryctrl queryctrl; - int min, max, current, step, val_def; + int min, current, step; int err; if (isv4l2Control (vd, control, &queryctrl) < 0) return -1; min = queryctrl.minimum; - max = queryctrl.maximum; step = queryctrl.step; - val_def = queryctrl.default_value; current = v4l2GetControl (vd, control); current -= step; if (current >= min) { --- uvccapture-0.5.orig/v4l2uvc.h +++ uvccapture-0.5/v4l2uvc.h @@ -25,14 +25,6 @@ #define NB_BUFFER 16 #define DHT_SIZE 420 -#define V4L2_CID_BACKLIGHT_COMPENSATION (V4L2_CID_PRIVATE_BASE+0) -#define V4L2_CID_POWER_LINE_FREQUENCY (V4L2_CID_PRIVATE_BASE+1) -#define V4L2_CID_SHARPNESS (V4L2_CID_PRIVATE_BASE+2) -#define V4L2_CID_HUE_AUTO (V4L2_CID_PRIVATE_BASE+3) -#define V4L2_CID_FOCUS_AUTO (V4L2_CID_PRIVATE_BASE+4) -#define V4L2_CID_FOCUS_ABSOLUTE (V4L2_CID_PRIVATE_BASE+5) -#define V4L2_CID_FOCUS_RELATIVE (V4L2_CID_PRIVATE_BASE+6) - #define V4L2_CID_PANTILT_RELATIVE (V4L2_CID_PRIVATE_BASE+7) #define V4L2_CID_PANTILT_RESET (V4L2_CID_PRIVATE_BASE+8) debian/patches/hardening.patch0000644000000000000000000000201712232543647013605 0ustar Description: Add hardening build flags This patch adds hardening flags to the Makefile. It does this using Debian's tools, so in its current form it cannot be used upstream. Last-Update: 2013-10-19 Author: Bas Wijnen --- uvccapture-0.5.orig/Makefile +++ uvccapture-0.5/Makefile @@ -7,8 +7,14 @@ PREFIX=/usr/local/bin WARNINGS = -Wall -CFLAGS = -std=gnu99 -O2 -DLINUX -DVERSION=\"$(VERSION)\" $(WARNINGS) -CPPFLAGS = $(CFLAGS) +DPKG_CPPFLAGS:=$(shell dpkg-buildflags --get CPPFLAGS) +DPKG_CFLAGS:=$(shell dpkg-buildflags --get CFLAGS) +DPKG_LDFLAGS:=$(shell dpkg-buildflags --get LDFLAGS) +COMMON_FLAGS = -std=gnu99 -O2 $(WARNINGS) + +CFLAGS = $(DPKG_CFLAGS) $(COMMON_FLAGS) +CPPFLAGS = $(DPKG_CPPFLAGS) $(COMMON_FLAGS) -DLINUX -DVERSION=\"$(VERSION)\" +LDFLAGS = $(DPKG_LDFLAGS) OBJECTS= uvccapture.o v4l2uvc.o @@ -24,4 +30,4 @@ install: # Applications: uvccapture: $(OBJECTS) - $(CC) $(OBJECTS) $(XPM_LIB) $(MATH_LIB) -ljpeg -o $(APP_BINARY) + $(CC) $(LDFLAGS) $(OBJECTS) $(XPM_LIB) $(MATH_LIB) -ljpeg -o $(APP_BINARY) debian/patches/fix_videodev_include_FTBFS.patch0000644000000000000000000000215011773356207016751 0ustar Description: Fix build failure by using linux/videodev2.h instead of deprecated linux/videodev.h Orign: ubuntu Author: Daniel Polehn Ubuntu-Bug: https://bugs.launchpad.net/ubuntu/+source/uvccapture/+bug/756023 Debian-Bug: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=621963 Index: uvccapture/v4l2uvc.c =================================================================== --- uvccapture.orig/v4l2uvc.c 2008-07-31 22:26:18.000000000 -0400 +++ uvccapture/v4l2uvc.c 2012-06-29 12:48:31.912949668 -0400 @@ -28,7 +28,7 @@ #include #include #include -#include +#include #include #include #include "v4l2uvc.h" Index: uvccapture/uvccapture.c =================================================================== --- uvccapture.orig/uvccapture.c 2008-07-31 22:26:18.000000000 -0400 +++ uvccapture/uvccapture.c 2012-06-29 12:48:31.912949668 -0400 @@ -31,7 +31,7 @@ #include #include #include -#include +#include #include "v4l2uvc.h" debian/patches/numbuffers.patch0000644000000000000000000000251612232542010014005 0ustar Description: Use returned number of buffers instead of requested. VIDIOC_REQBUFS stores the number of actually allocated buffers. This patch uses this value instead of assuming it is equal to the requested number. Author: Bas Wijnen Debian-Bug: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=726802 Last-Update: 2013-10-19 --- uvccapture-0.5.orig/v4l2uvc.c +++ uvccapture-0.5/v4l2uvc.c @@ -202,7 +202,7 @@ init_v4l2 (struct vdIn *vd) goto fatal; } /* map the buffers */ - for (i = 0; i < NB_BUFFER; i++) { + for (i = 0; i < vd->rb.count; i++) { memset (&vd->buf, 0, sizeof (struct v4l2_buffer)); vd->buf.index = i; vd->buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; @@ -226,7 +226,7 @@ init_v4l2 (struct vdIn *vd) fprintf (stderr, "Buffer mapped at address %p.\n", vd->mem[i]); } /* Queue the buffers. */ - for (i = 0; i < NB_BUFFER; ++i) { + for (i = 0; i < vd->rb.count; ++i) { memset (&vd->buf, 0, sizeof (struct v4l2_buffer)); vd->buf.index = i; vd->buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; @@ -335,7 +335,7 @@ close_v4l2 (struct vdIn *vd) /* If the memory maps are not released the device will remain opened even after a call to close(); */ - for (i = 0; i < NB_BUFFER; i++) { + for (i = 0; i < vd->rb.count; i++) { munmap (vd->mem[i], vd->buf.length); } debian/patches/series0000644000000000000000000000010212232544002012015 0ustar fix_videodev_include_FTBFS.patch numbuffers.patch hardening.patch debian/control0000644000000000000000000000164512232543414010577 0ustar Source: uvccapture Section: graphics Priority: optional Maintainer: Andrew Starr-Bochicchio Build-Depends: debhelper (>= 9), libjpeg-dev Standards-Version: 3.9.4 Homepage: http://linux-uvc.berlios.de/ Vcs-Browser: http://anonscm.debian.org/gitweb/?p=collab-maint/uvccapture.git;a=summary Vcs-Git: git://git.debian.org/git/collab-maint/uvccapture.git Package: uvccapture Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} Description: USB UVC Video Class snapshot software The purpose of this software is to capture an image from a USB webcam at a specified interval, and save it to a JPEG file, no other formats are supported. . Right now this software is really a hack, since still image support is not yet available in the UVC driver. The program continually polls the UVC driver in MJPEG mode, and at a specified interval writes a JPEG header and a single frame to file, creating a JPEG image. debian/docs0000644000000000000000000000000711773357664010061 0ustar README debian/source/0000755000000000000000000000000012121230360010454 5ustar debian/source/format0000644000000000000000000000001411773355215011705 0ustar 3.0 (quilt)