diff --git a/CHANGELOG b/CHANGELOG index a4de385..c3a2287 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -45,6 +45,8 @@ Features * Added new log type COR , to filter messages from CORE. (Angel Carpintero) * Added a new starting option -m to disable motion detection. (Angel Carpintero) * Allow image dimension not 4:3 changing a check of modulo 16 by modulo 8. (Jeroen Massar) + * Added codec Ogg/Theora as new output format for regular movies. + http://www.lavrsen.dk/foswiki/bin/view/Motion/OggTimelapse (Michael Luich) Bugfixes * Avoid segfault detecting strerror_r() version GNU or SUSv3. (Angel Carpintero) @@ -76,7 +78,8 @@ Bugfixes * Fixed configure for SDL. * Replace malloc() by calloc(). (Jeroen Massar) * Free file descriptor buffers on exit. - * Avoid segfault when text_left or text_right uses non supported chars. + * Avoid segfault when text_left or text_right uses non supported chars. + * Fixed leak in vloopback. 3.2.12 Summary of Changes diff --git a/CREDITS b/CREDITS index 96f4c0e..89390a7 100644 --- a/CREDITS +++ b/CREDITS @@ -1086,6 +1086,11 @@ Michal Licko * Track pan/tilt support for uvcvideo ( Michal Licko ,Dirk Wesenberg and Angel Carpintero ) http://www.lavrsen.dk/twiki/bin/view/Motion/LinuxUvcTrackingPatch +Michael Luich + + * Added codec Ogg/Theora as new output format for regular movies. + http://www.lavrsen.dk/foswiki/bin/view/Motion/OggTimelapse + Bill Maidment * Fixed bug reporting errors when creating symlink to last snap. diff --git a/conf.c b/conf.c index 2581c80..2da0da6 100644 --- a/conf.c +++ b/conf.c @@ -749,7 +749,8 @@ config_param config_params[] = { "# swf - gives you a flash film with extension .swf\n" "# flv - gives you a flash video with extension .flv\n" "# ffv1 - FF video codec 1 for Lossless Encoding ( experimental )\n" - "# mov - QuickTime ( testing )", + "# mov - QuickTime ( testing )\n" + "# ogg - Ogg/Theora ( testing )", 0, CONF_OFFSET(ffmpeg_video_codec), copy_string, diff --git a/configure b/configure index 6398d64..1ee57ca 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.67 for motion Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7. +# Generated by GNU Autoconf 2.67 for motion Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -549,8 +549,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='motion' PACKAGE_TARNAME='motion' -PACKAGE_VERSION='Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7' -PACKAGE_STRING='motion Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7' +PACKAGE_VERSION='Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa' +PACKAGE_STRING='motion Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1217,7 +1217,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures motion Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7 to adapt to many kinds of systems. +\`configure' configures motion Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1278,7 +1278,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of motion Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7:";; + short | recursive ) echo "Configuration of motion Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa:";; esac cat <<\_ACEOF @@ -1424,7 +1424,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -motion configure Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7 +motion configure Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa generated by GNU Autoconf 2.67 Copyright (C) 2010 Free Software Foundation, Inc. @@ -2021,7 +2021,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by motion $as_me Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7, which was +It was created by motion $as_me Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa, which was generated by GNU Autoconf 2.67. Invocation command line was $ $0 $@ @@ -6531,7 +6531,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by motion $as_me Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7, which was +This file was extended by motion $as_me Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa, which was generated by GNU Autoconf 2.67. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -6593,7 +6593,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -motion config.status Git-fcdd33103646f13db62d7c1d97040ea6e78ba7a7 +motion config.status Git-97ade56ea87f9c9a5857bbfba284bae2a14911aa configured by $0, generated by GNU Autoconf 2.67, with options \\"\$ac_cs_config\\" diff --git a/ffmpeg.c b/ffmpeg.c index 5ce4a57..8e86b7e 100644 --- a/ffmpeg.c +++ b/ffmpeg.c @@ -63,6 +63,7 @@ # define AVSTREAM_CODEC_PTR(avs_ptr) (&avs_ptr->codec) #endif /* LIBAVFORMAT_BUILD >= 4629 */ + /* * Name of custom file protocol for appending to existing files instead * of truncating. @@ -383,6 +384,15 @@ static AVOutputFormat *get_oformat(const char *codec, char *filename) of = guess_format("mpeg1video", NULL, NULL); #else of = av_guess_format("mov", NULL, NULL); +#endif + } + else if (strcmp (codec, "ogg") == 0) + { + ext = ".ogg"; +#ifdef GUESS_NO_DEPRECATED + of = guess_format ("ogg", NULL, NULL); +#else + of = av_guess_format ("ogg", NULL, NULL); #endif } else { MOTION_LOG(ERR, TYPE_ENCODER, NO_ERRNO, "%s: ffmpeg_video_codec option value" diff --git a/motion-dist.conf.in b/motion-dist.conf.in index afe44f1..30886bc 100644 --- a/motion-dist.conf.in +++ b/motion-dist.conf.in @@ -302,6 +302,7 @@ ffmpeg_variable_bitrate 0 # flv - gives you a flash video with extension .flv # ffv1 - FF video codec 1 for Lossless Encoding ( experimental ) # mov - QuickTime ( testing ) +# ogg - Ogg/Theora ( testing ) ffmpeg_video_codec mpeg4 # Use ffmpeg to deinterlace video. Necessary if you use an analog camera diff --git a/motion.1 b/motion.1 index a77fb31..a023f83 100644 --- a/motion.1 +++ b/motion.1 @@ -170,7 +170,7 @@ Values: 0, 2 - 31 / Default: 0 (disabled) Enables and defines variable bitrate for the ffmpeg encoder. ffmpeg_bps is ignored if variable bitrate is enabled. Valid values: 0 (default) = fixed bitrate defined by ffmpeg_bps, or the range 2 - 31 where 2 means best quality and 31 is worst. .TP .B ffmpeg_video_codec discrete strings -Values: mpeg1 (ffmpeg-0.4.8 only), mpeg4, msmpeg4, swf , flv , ffv1, mov / Default: mpeg4 +Values: mpeg1 (ffmpeg-0.4.8 only), mpeg4, msmpeg4, swf , flv , ffv1, mov, ogg / Default: mpeg4 .br Codec to be used by ffmpeg for the video compression. Timelapse movies are always made in mpeg1 format independent from this option. .TP diff --git a/vloopback_motion.c b/vloopback_motion.c index 6d5462b..3433bf8 100644 --- a/vloopback_motion.c +++ b/vloopback_motion.c @@ -58,6 +58,7 @@ static int v4l_open_vidpipe(void) /* Read vloopback version*/ if (!fgets(buffer, sizeof(buffer), vloopbacks)) { MOTION_LOG(CRT, TYPE_VIDEO, SHOW_ERRNO, "%s: Unable to read vloopback version"); + myfclose(vloopbacks); return -1; } @@ -68,6 +69,7 @@ static int v4l_open_vidpipe(void) if (!fgets(buffer, sizeof(buffer), vloopbacks)) { MOTION_LOG(CRT, TYPE_VIDEO, SHOW_ERRNO, "%s: Unable to read vloopback" " explanation line"); + myfclose(vloopbacks); return -1; }