[tracker] Revert "tracker-extract, png: Fix DLNA profiles"
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker] Revert "tracker-extract, png: Fix DLNA profiles"
- Date: Fri, 27 Jan 2017 11:07:37 +0000 (UTC)
commit e48537eb7e25ed9308ad691d92e668b2847a6b31
Author: Carlos Garnacho <carlosg gnome org>
Date: Fri Jan 27 11:48:55 2017 +0100
Revert "tracker-extract, png: Fix DLNA profiles"
This reverts commit 89baaa45a70e5d50462bbd4e5b89dbb2c221e701.
The reasons to classify all pngs as PNG_LRG went away with the maemo
bugzilla. The reason isn't clear and seems to go against the DNLA spec
(at least, how gupnp-dlna understands it, which Tracker took inspiration
from). This commit also made the if (profile)... check below useless,
which raised warnings in Coverity.
Coverity ID: 1298205
https://bugzilla.gnome.org/show_bug.cgi?id=777819
src/tracker-extract/tracker-extract-png.c | 10 +++++++++-
1 files changed, 9 insertions(+), 1 deletions(-)
---
diff --git a/src/tracker-extract/tracker-extract-png.c b/src/tracker-extract/tracker-extract-png.c
index d392365..d77dc9e 100644
--- a/src/tracker-extract/tracker-extract-png.c
+++ b/src/tracker-extract/tracker-extract-png.c
@@ -587,7 +587,15 @@ guess_dlna_profile (gint depth,
*dlna_mimetype = NULL;
}
- profile = "PNG_LRG";
+ if (width == 120 && height == 120) {
+ profile = "PNG_LRG_ICO";
+ } else if (width == 48 && height == 48) {
+ profile = "PNG_SM_ICO";
+ } else if (width <= 160 && height <= 160) {
+ profile = "PNG_TN";
+ } else if (depth <= 32 && width <= 4096 && height <= 4096) {
+ profile = "PNG_LRG";
+ }
if (profile) {
if (dlna_profile) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]