summaryrefslogtreecommitdiffstats
path: root/debian/patches/i225-hide-black-squares-bug.patch
diff options
context:
space:
mode:
authorDidier Raboud <odyx@debian.org>2014-01-19 11:03:52 +0100
committerDidier Raboud <odyx@debian.org>2014-03-14 13:53:43 +0100
commit7f12f345650d8c7e704f844644494f91901d9536 (patch)
treed300c504b5eebfb1b23f68a24074dc67e6d49985 /debian/patches/i225-hide-black-squares-bug.patch
parenta59d1606c3592fad39194c0bc6b49e555acf9f6f (diff)
downloadcolobot-7f12f345650d8c7e704f844644494f91901d9536.tar.gz
colobot-7f12f345650d8c7e704f844644494f91901d9536.tar.bz2
colobot-7f12f345650d8c7e704f844644494f91901d9536.zip
Replace the patch to hide the black squares bug by the upstream fix
Diffstat (limited to 'debian/patches/i225-hide-black-squares-bug.patch')
-rw-r--r--debian/patches/i225-hide-black-squares-bug.patch48
1 files changed, 29 insertions, 19 deletions
diff --git a/debian/patches/i225-hide-black-squares-bug.patch b/debian/patches/i225-hide-black-squares-bug.patch
index 8425043..c405688 100644
--- a/debian/patches/i225-hide-black-squares-bug.patch
+++ b/debian/patches/i225-hide-black-squares-bug.patch
@@ -1,20 +1,30 @@
-Description: Hide upstream issue #225 "Black rectangles shows due to particle and fire effects"
-Author: Didier Raboud <odyx@debian.org>
-Origin: vendor
-Forwarded: https://github.com/colobot/colobot/issues/225
-Last-Updated: 2013-11-26
---- a/src/graphics/engine/particle.cpp
-+++ b/src/graphics/engine/particle.cpp
-@@ -2875,6 +2875,12 @@
- vertex[2] = Vertex(corner[3], n, Math::Point(m_particle[i].texSup.x, m_particle[i].texInf.y));
- vertex[3] = Vertex(corner[2], n, Math::Point(m_particle[i].texInf.x, m_particle[i].texInf.y));
+commit 70b18cc4c05398cd06558f4634937a70c2436546
+Author: Piotr Dziwinski <piotrdz@gmail.com>
+Date: Sat Jan 18 21:35:32 2014 +0100
+
+ Move engine frame update after game state update
+
+ This should finally fix #225
+
+--- a/src/app/app.cpp
++++ b/src/app/app.cpp
+@@ -962,15 +962,15 @@
+ {
+ LogEvent(event);
-+ // On first call, the coordinates are all 0, in that case, return as it's wrong.
-+ if((m_particle[i].texSup.x-m_particle[i].texInf.x) == 0.0f || (m_particle[i].texSup.y - m_particle[i].texInf.y) == 0.0f ) {
-+ // One particle texture dimension is zero, most probably wrong!
-+ // Don't display it then.
-+ return;
-+ }
- m_device->DrawPrimitive(PRIMITIVE_TRIANGLE_STRIP, vertex, 4);
- m_engine->AddStatisticTriangle(2);
- }
+- StartPerformanceCounter(PCNT_UPDATE_ENGINE);
+- m_engine->FrameUpdate();
+- StopPerformanceCounter(PCNT_UPDATE_ENGINE);
+-
+ m_sound->FrameMove(m_relTime);
+
+ StartPerformanceCounter(PCNT_UPDATE_GAME);
+ m_robotMain->ProcessEvent(event);
+ StopPerformanceCounter(PCNT_UPDATE_GAME);
++
++ StartPerformanceCounter(PCNT_UPDATE_ENGINE);
++ m_engine->FrameUpdate();
++ StopPerformanceCounter(PCNT_UPDATE_ENGINE);
+ }
+
+ StopPerformanceCounter(PCNT_UPDATE_ALL);