Motion - Exif Tagging Patch
You are here: Foswiki>Motion Web>ExifTaggingPatch (30 Oct 2011, AngelCarpintero)Edit Attach

EXIF information for pictures

Description of Patch

Here's a patch that adds EXIF information for pictures saved by Motion.

The text (the "image description" tag) is controlled by the new exif_text config option, which can contain %foo sequences to interpolate the time, event number, or whatever. The capture time and the region in which movement was detected are also stored in appropriate EXIF tags. (The motion region is stored as the "subject area" rectangle. I don't know if any software uses that information, but it was in the EXIF spec so I used it.)

This patch is against the trunk r523 and on top of ConfigureTweaks, but it should also apply cleanly to the trunk without ConfigureTweaks.

Installation of Patch

Download the patch file. Then copy it to the motion source directory and issue the command (assuming the patch file is called exiftagging.diff)

patch -p2 < exiftagging.diff

Then re-build Motion and test the patch.

Change History of Patch

  • 1.0 Initial revision- Adds configurable EXIF tags to JPEG images saved by Motion
  • 2.0 Maintenance- Applies cleanly to trunkREV523 + ConfigureTweaks 4

Discussion and Comments

There are a few things that could be improved about the patch. The argument list to put_jpeg_yuv420p_memory() (etc.) is getting kind of long; maybe it would be better to pass just a pointer to image_data or similar structure instead of the multiple pieces of information which can be written to the picture.

-- WimLewis - 18 Nov 2010

Wim , your patch is good smile

But checking the EXTIF information that is written i see that timestamp is twice , why ?

e.g : ext_text %i-%J/%K-%L

160-108/222-180 2011:02:17 04:10:35 2011:02:17 04:10:35


-- AngelCarpintero - 17 Feb 2011

Forget it , original and digitalized date.

-- AngelCarpintero - 21 Feb 2011

Included in GIT and SVN.

-- AngelCarpintero - 30 Oct 2011

Topic revision: r5 - 30 Oct 2011, AngelCarpintero
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.