-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pictures: Move to exiv2 for image metadata retrieval (exif and iptc)
- Loading branch information
Showing
18 changed files
with
996 additions
and
1,327 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -210,6 +210,7 @@ set(required_deps ASS>=0.15.0 | |
Cdio | ||
CrossGUID | ||
Curl | ||
Exiv2 | ||
FFMPEG | ||
FlatBuffers | ||
Fmt | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,6 +9,7 @@ DEPENDS = \ | |
brotli \ | ||
bzip2 \ | ||
dav1d \ | ||
exiv2 \ | ||
expat \ | ||
ffmpeg \ | ||
fontconfig \ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
/* | ||
* Copyright (C) 2023 Team Kodi | ||
* This file is part of Kodi - https://kodi.tv | ||
* | ||
* SPDX-License-Identifier: GPL-2.0-or-later | ||
* See LICENSES/README.md for more information. | ||
*/ | ||
|
||
#pragma once | ||
|
||
#include <string> | ||
#include <vector> | ||
|
||
constexpr unsigned int MAX_DATE_COPIES = 10; | ||
constexpr int EXIF_COMMENT_CHARSET_CONVERTED = -1; | ||
|
||
struct ExifInfo | ||
{ | ||
ExifInfo() = default; | ||
ExifInfo(const ExifInfo&) = default; | ||
ExifInfo(ExifInfo&&) = default; | ||
|
||
ExifInfo& operator=(const ExifInfo&) = default; | ||
ExifInfo& operator=(ExifInfo&&) = default; | ||
|
||
std::string CameraMake; | ||
std::string CameraModel; | ||
std::string DateTime; | ||
int Height{}; | ||
int Width{}; | ||
int Orientation{}; | ||
int IsColor{}; | ||
std::string Process{}; | ||
int FlashUsed{}; | ||
float FocalLength{}; | ||
float ExposureTime{}; | ||
float ApertureFNumber{}; | ||
float Distance{}; | ||
float CCDWidth{}; | ||
float ExposureBias{}; | ||
float DigitalZoomRatio{}; | ||
int FocalLength35mmEquiv{}; | ||
int Whitebalance{}; | ||
int MeteringMode{}; | ||
int ExposureProgram{}; | ||
int ExposureMode{}; | ||
int ISOequivalent{}; | ||
int LightSource{}; | ||
//! TODO: Remove me, not needed anymore (still exposed to addon interface) | ||
int CommentsCharset{}; | ||
//! TODO: Remove me, not needed anymore (still exposed to addon interface) | ||
int XPCommentsCharset{}; | ||
std::string Comments; | ||
std::string FileComment; | ||
std::string XPComment; | ||
std::string Description; | ||
|
||
//! TODO: this is not used anywhere, just nuke it | ||
unsigned ThumbnailOffset{}; | ||
unsigned ThumbnailSize{}; | ||
unsigned LargestExifOffset{}; | ||
//! TODO: this is not used anywhere, just nuke it | ||
char ThumbnailAtEnd{}; | ||
int ThumbnailSizeOffset{}; | ||
//! TODO: this is not used anywhere, just nuke it | ||
std::vector<int> DateTimeOffsets; | ||
|
||
int GpsInfoPresent{}; | ||
std::string GpsLat; | ||
std::string GpsLong; | ||
std::string GpsAlt; | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/* | ||
* Copyright (C) 2023 Team Kodi | ||
* This file is part of Kodi - https://kodi.tv | ||
* | ||
* SPDX-License-Identifier: GPL-2.0-or-later | ||
* See LICENSES/README.md for more information. | ||
*/ | ||
|
||
#pragma once | ||
|
||
#include "Exif.h" | ||
#include "Iptc.h" | ||
|
||
struct ImageMetadata | ||
{ | ||
ExifInfo exifInfo; | ||
IPTCInfo iptcInfo; | ||
}; |
Oops, something went wrong.