From cd0aaf45cae96e37c0ab2dbbf261c52fe5f88c47 Mon Sep 17 00:00:00 2001 From: Tonton Th Date: Tue, 28 May 2019 11:56:02 +0200 Subject: [PATCH] more pretty formating --- v4l2/grabvidseq.c | 69 ++++++++++++++++++++++++----------------------- 1 file changed, 36 insertions(+), 33 deletions(-) diff --git a/v4l2/grabvidseq.c b/v4l2/grabvidseq.c index ccef5143..a920e956 100644 --- a/v4l2/grabvidseq.c +++ b/v4l2/grabvidseq.c @@ -1,4 +1,7 @@ /* V4L2 video picture grabber + + Origin :V4L2GRAB.C - patched by tTh + Copyright (C) 2009 Mauro Carvalho Chehab This program is free software; you can redistribute it and/or modify @@ -11,24 +14,24 @@ GNU General Public License for more details. */ - #include - #include - #include - #include - #include - #include - #include - #include - #include - #include - #include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include - #define CLEAR(x) memset(&(x), 0, sizeof(x)) +#define CLEAR(x) memset(&(x), 0, sizeof(x)) - struct buffer { - void *start; - size_t length; - }; +struct buffer { + void *start; + size_t length; + }; int verbosity; @@ -59,24 +62,24 @@ exit(0); } /* --------------------------------------------------------------------- */ - int main(int argc, char **argv) - { - struct v4l2_format fmt; - struct v4l2_buffer buf; - struct v4l2_requestbuffers req; - enum v4l2_buf_type type; - fd_set fds; - struct timeval tv; - int r, fd = -1; - unsigned int i, n_buffers; - char *dev_name = "/dev/video0"; - char out_name[256]; - FILE *fout; - struct buffer *buffers; +int main(int argc, char **argv) +{ +struct v4l2_format fmt; +struct v4l2_buffer buf; +struct v4l2_requestbuffers req; +enum v4l2_buf_type type; +fd_set fds; +struct timeval tv; +int r, fd = -1; +unsigned int i, n_buffers; +char *dev_name = "/dev/video0"; +char out_name[256]; +FILE *fout; +struct buffer *buffers; - int period = 10; /* delai entre les captures */ - int nbre_capt = 1; /* nombre de captures */ - int opt; +int period = 10; /* delai entre les captures */ +int nbre_capt = 1; /* nombre de captures */ +int opt; while ((opt = getopt(argc, argv, "d:hn:p:v")) != -1) { switch(opt) {