Motion - Config Option On Movie Start

on_movie_start

  • Type: String
  • Range / Valid values: Max 4095 characters
  • Default: Not defined
  • Group: Script Execution

Command to be executed when an mpeg movie is created. You can use Conversion Specifiers and spaces as part of the command. Use %f for passing filename (with full path) to the command., Command to be executed when an mpeg movie is created. You can use Conversion Specifiers and spaces as part of the command. Use %f for passing filename (with full path) to the command.

Full path name of the program/script.

This can be any type of program or script. Remember to set the execution bit in the ACL and if it is a script type program such as perl or bash also remember the shebang line (e.g. #!/user/bin/perl) as the first line of the script. When you use ffmpeg the film is generated on the fly and on_movie_start then runs when the new mpeg file is created. Often you will want to use the on_movie_end option which runs when the mpeg file is closed and the event is over.

This option was previously called onmpeg.

To include the path name of the picture in the command line, you can use the conversion specifier %f to insert the picture filename (full path) anywhere in the command.

Most common conversion specifiers

  • %Y = year, %m = month, %d = date
  • %H = hour, %M = minute, %S = second
  • %v = event
  • %q = frame number
  • %t = thread (camera) number
  • %D = changed pixels
  • %N = noise level
  • %i and %J = width and height of motion area
  • %K and %L = X and Y coordinates of motion center
  • %C = value defined by text_event
  • %f = filename with full path
  • %n = number indicating file-type
Topic revision: r7 - 07 Aug 2016, KennethLavrsen
Copyright © 1999-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Please do not email Kenneth for support questions (read why). Use the Support Requests page or join the Mailing List.
This website only use harmless session cookies. See Cookie Policy for details. By using this website you accept the use of these cookies.