summaryrefslogtreecommitdiffstats
path: root/file.h
diff options
context:
space:
mode:
authorGravatar Robert C. Helling <helling@atdotde.de>2014-01-27 14:44:26 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-02-06 11:29:23 -0800
commit5c1abde2a5217cc8217cb25c4a81515d0fda0253 (patch)
tree429bb0cb972b49b77bef11aa9e786b554de2bd46 /file.h
parentc84ef319a2d83affbd4a0f2f7c391cdfb25d09ee (diff)
downloadsubsurface-5c1abde2a5217cc8217cb25c4a81515d0fda0253.tar.gz
Include images in profile
This adds an entry to the dive list context menu to load images. The user can select image files and set a time offset to align camera and dive computer clocks. Using the exif time stamp the images are tried to match to the times of the selected dives (with a grace period of an hour before and after the dive). Upon success an event of type 123 is created per image with the string value being the path to the image. Those images are displayed as thumbnails in the profile. If the matching dive does not yet have a geo location specified but the image provides one it is copied to the dive (making the camera a poor man's companion app). This patch includes easyexif https://code.google.com/p/easyexif/ which is originally under a New BSD License to parse the image meta data. This commit includes a new test dive dives/test31.xml with a matching image wreck.jpg to try out the functionallity. Obvious to do's: Have images on the map Have the images clickable Have a proper picture viewer Give visual reference for image time shifting. Use the new profile Signed-off-by: Robert C. Helling <helling@atdotde.de> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'file.h')
-rw-r--r--file.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/file.h b/file.h
index b3a1ebac3..1e1e07721 100644
--- a/file.h
+++ b/file.h
@@ -9,6 +9,14 @@ struct memblock {
#if 0
extern int try_to_open_cochran(const char *filename, struct memblock *mem, GError **error);
#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
extern int readfile(const char *filename, struct memblock *mem);
+extern timestamp_t parse_date(const char *date);
+#ifdef __cplusplus
+}
+#endif
#endif