aboutsummaryrefslogtreecommitdiffstats
path: root/core/metadata.cpp
AgeCommit message (Collapse)Author
2018-08-01Cleanup: remove silly " != 0" expressionGravatar Berthold Stoeger
In metadata.cpp, replace a silly "if (!memcmp(...) != 0)" by the intended "if (!memcmp(...))" Obviously, both have the same effect. Fixes a warning. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2018-07-14Metadata: Parse ASFs (=WMVs)Gravatar Berthold Stoeger
The simplest video-formats to parse so far. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2018-07-14Metadata: Parse AVIsGravatar Berthold Stoeger
Whereas extraction of the dive-duration is trivial, AVIs don't seem to have a standardized way of saving the creation time. This commit implements support for two versions randomly found on the internet. Additional version will follow if need arises. AVI seems not to be a particular popular format for either vacation or professional videographers. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2018-07-14Metadata: extract duration fom QuickTime/MP4-style containersGravatar Berthold Stoeger
We want the duration of videos for two reasons: - To display the duration of the video in the profile plot. - To be able to determine which dive a video is closer to if the start is not during a dive. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2018-04-01Dive pictures: extract timestamp from MP4 and related formatsGravatar Berthold Stoeger
Parse MP4s and related video files and extract the creation timestamp from the "mdhd" (media header) atom. Introduce helper function templates to extract arbitrary-length unsigned integers in big-endian format from file or memory. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2018-04-01Dive pictures: use get_metadata() in dive_create_picture()Gravatar Berthold Stoeger
Thus, metadata has to be only read once and the picture_load_exif_data() function can be removed. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2018-04-01Dive pictures: Move metadata functions into own translation unitGravatar Berthold Stoeger
Move all metadata function into new core/metadata.cpp file. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>