[packages/xzgv] - fix exif orientation support - rel 2
adwol
adwol at pld-linux.org
Tue Jun 12 23:59:27 CEST 2018
commit b345f8ce56eafd171eb881aa2125564090eb7768
Author: Adam Osuchowski <adwol at pld-linux.org>
Date: Tue Jun 12 23:58:55 2018 +0200
- fix exif orientation support
- rel 2
xzgv-exif_orient.patch | 24 ++++++++++++++++++++++++
xzgv.spec | 4 +++-
2 files changed, 27 insertions(+), 1 deletion(-)
---
diff --git a/xzgv.spec b/xzgv.spec
index 92eca80..e80e982 100644
--- a/xzgv.spec
+++ b/xzgv.spec
@@ -2,7 +2,7 @@ Summary: Picture viewer for X, with thumbnail-based file selector
Summary(pl.UTF-8): Przeglądarka plików graficznych pod X Window System z obsługą miniatur
Name: xzgv
Version: 0.9.2
-Release: 1
+Release: 2
License: GPL v2+
Group: X11/Applications/Graphics
Source0: http://downloads.sourceforge.net/%{name}/%{name}/%{version}/%{name}-%{version}.tar.gz
@@ -10,6 +10,7 @@ Source0: http://downloads.sourceforge.net/%{name}/%{name}/%{version}/%{name}-%{v
Source1: %{name}.desktop
Source2: %{name}.png
Patch0: %{name}-patch
+Patch1: %{name}-exif_orient.patch
URL: http://sourceforge.net/projects/xzgv
BuildRequires: gawk
BuildRequires: gtk+2-devel >= 1:2.0
@@ -37,6 +38,7 @@ Oczywiście po instalacji.
%prep
%setup -q
%patch0 -p1
+%patch1 -p1
%build
%{__make} \
diff --git a/xzgv-exif_orient.patch b/xzgv-exif_orient.patch
new file mode 100644
index 0000000..2476419
--- /dev/null
+++ b/xzgv-exif_orient.patch
@@ -0,0 +1,24 @@
+diff -ruNp xzgv-0.9.2.orig/src/backend.c xzgv-0.9.2/src/backend.c
+--- xzgv-0.9.2.orig/src/backend.c 2017-09-03 12:11:50.000000000 +0200
++++ xzgv-0.9.2/src/backend.c 2018-06-12 23:12:08.995486496 +0200
+@@ -207,7 +207,7 @@ gchar *format;
+ ExifData *ed;
+ ExifEntry *entry;
+ ExifShort orient;
+-static const ExifShort xzgv_orient[]={0,0,1,3,2,7,4,6,5};
++static const ExifShort xzgv_orient[]={0,0,3,1,2,7,5,6,4};
+
+ if((imform=gdk_pixbuf_get_file_info(filename,NULL,NULL))==NULL) return 0;
+ if((format=gdk_pixbuf_format_get_name(imform))==NULL) return 0;
+diff -ruNp xzgv-0.9.2.orig/src/main.c xzgv-0.9.2/src/main.c
+--- xzgv-0.9.2.orig/src/main.c 2017-09-03 12:11:50.000000000 +0200
++++ xzgv-0.9.2/src/main.c 2018-06-12 23:13:45.121031080 +0200
+@@ -3423,7 +3423,7 @@ orient_current_state=0;
+ if(use_exif_orient)
+ {
+ /* apply Exif orientation correction, then pretend it's the normal pic */
+- orient_change_state(0,jpeg_exif_orient);
++ orient_change_state(jpeg_exif_orient,0);
+ orient_current_state=0;
+ }
+
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/xzgv.git/commitdiff/b345f8ce56eafd171eb881aa2125564090eb7768
More information about the pld-cvs-commit
mailing list