Added patch to fix mirrored textures with Qt >= 4.6

This commit is contained in:
Kalev Lember 2011-01-06 02:12:56 +02:00
parent 2462c6c58f
commit 3a883e5cd6
2 changed files with 36 additions and 2 deletions

View File

@ -0,0 +1,29 @@
Index: src/display/mapcanvas.cpp
===================================================================
--- src/display/mapcanvas.cpp (revision 202)
+++ src/display/mapcanvas.cpp (revision 203)
@@ -2706,6 +2706,7 @@
m_room_gllist = glGenLists(1);
glNewList(m_room_gllist, GL_COMPILE);
glBegin(GL_QUADS);
+#if QT_VERSION < 0x040600
glTexCoord2d(0, 1);
glVertex3d(0.0, 0.0, 0.0);
glTexCoord2d(0, 0);
@@ -2714,6 +2715,16 @@
glVertex3d(1.0, 1.0, 0.0);
glTexCoord2d(1, 1);
glVertex3d(1.0, 0.0, 0.0);
+#else
+ glTexCoord2d(0, 1);
+ glVertex3d(0.0, 1.0, 0.0);
+ glTexCoord2d(0, 0);
+ glVertex3d(0.0, 0.0, 0.0);
+ glTexCoord2d(1, 0);
+ glVertex3d(1.0, 0.0, 0.0);
+ glTexCoord2d(1, 1);
+ glVertex3d(1.0, 1.0, 0.0);
+#endif
glEnd();
glEndList();

View File

@ -1,14 +1,15 @@
Name: mmapper
Version: 2.1.0
Release: 1%{?dist}
Release: 2%{?dist}
Summary: Graphical MUME mapper
Group: Amusements/Games
License: GPLv2+
URL: http://sourceforge.net/projects/mmapper
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}-source.tar.gz
# Backported patch from upstream svn
# Backported patches from upstream svn
Patch0: mmapper-2.1.0-system_qtiocompressor.patch
Patch1: mmapper-2.1.0-mirrored_textures.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: cmake
@ -28,6 +29,7 @@ data in real time and show player's position in a map.
%prep
%setup -q -n %{name}-%{version}-source
%patch0 -p1 -b .system_qtiocompressor
%patch1 -p0 -b .mirrored_textures
# remove bundled copy of qtiocompressor
rm -rf src/3rdparty
@ -78,6 +80,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%changelog
* Thu Jan 06 2011 Kalev Lember <kalev@smartlink.ee> - 2.1.0-2
- Added patch to fix mirrored textures with Qt >= 4.6
* Mon Aug 23 2010 Kalev Lember <kalev@smartlink.ee> - 2.1.0-1
- Update to 2.1.0
- Dropped upstreamed patches