[Marble-commits] branches/KDE/4.4/kdeedu/marble/src/lib

Torsten Rahn tackat at kde.org
Mon Jan 18 23:45:57 CET 2010


SVN commit 1076838 by rahn:

- Backport "Fix screen corruptions for jmho"



 M  +8 -5      TextureTile.cpp  


--- branches/KDE/4.4/kdeedu/marble/src/lib/TextureTile.cpp #1076837:1076838
@@ -77,13 +77,16 @@
 
 uint TextureTilePrivate::pixel( int x, int y ) const
 {
-    if ( m_depth == 8 || m_depth == 1 ) {
-        if ( !m_isGrayscale )
+    if ( m_depth == 8 ) {
+        if ( m_isGrayscale )
+            return (jumpTable8)[y][x];
+        else
             return m_rawtile.color( (jumpTable8)[y][x] );
-        else
-            return (jumpTable8)[y][x];
     }
-    return (jumpTable32)[y][x];
+    if ( m_depth == 32 )
+        return (jumpTable32)[y][x];
+
+    return m_rawtile.pixel( x, y );
 }
 
 uint TextureTilePrivate::pixelF( qreal x, qreal y, const QRgb& topLeftValue ) const


More information about the Marble-commits mailing list