← Back to team overview

widelands-dev team mailing list archive

[Merge] lp:~widelands-dev/widelands/compiler_warning into lp:widelands

 

GunChleoc has proposed merging lp:~widelands-dev/widelands/compiler_warning into lp:widelands.

Commit message:
Fixed compiler warning and updated comment in game_renderer.cc.

Requested reviews:
  SirVer (sirver)

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/compiler_warning/+merge/284659

Fixed compiler warning and updated comment in game_renderer.cc.

@SirVer: Are the fixes to the explanation correct?
-- 
Your team Widelands Developers is subscribed to branch lp:~widelands-dev/widelands/compiler_warning.
=== modified file 'src/graphic/game_renderer.cc'
--- src/graphic/game_renderer.cc	2016-01-23 11:42:26 +0000
+++ src/graphic/game_renderer.cc	2016-02-01 18:31:40 +0000
@@ -35,36 +35,37 @@
 #include "wui/mapviewpixelconstants.h"
 #include "wui/mapviewpixelfunctions.h"
 
-// Explanation of how drawing works:
-// Schematic of triangle neighborhood:
-//
-//               *
-//              / \
-//             / u \
-//         (f)/     \
-//    *------*------* (r)
-//     \  l / \  r / \
-//      \  /   \  /   \
-//       \/  d  \/ rr  \
-//       *------*------* (br)
-//        \ dd /
-//         \  /
-//          \/
-//          *
-//
-// Each field (f) owns two triangles: (r)ight & (d)own. When we look at the
-// field, we have to make sure to schedule drawing the triangles. This is done
-// by of these triangles is done by TerrainProgram.
-//
-// To draw dithered edges, we have to look at the neighboring triangles for the
-// two triangles too: If a neighboring triangle has another texture and our
-// dither layer is smaller, we have to draw a dithering triangle too - this lets the neighboring
-// texture
-// bleed into our triangle.
-//
-// The dither triangle is the triangle that should be partially (either r or
-// d). Example: if r and d have different textures and r.dither_layer >
-// d.dither_layer, then we will repaint d with the dither texture as mask.
+/*
+ * Explanation of how drawing works:
+ * Schematic of triangle neighborhood:
+ *
+ *               *
+ *              / \
+ *             / u \
+ *         (f)/     \
+ *    *------*------* (r)
+ *     \  l / \  r / \
+ *      \  /   \  /   \
+ *       \/  d  \/ rr  \
+ *       *------*------* (br)
+ *        \ dd /
+ *         \  /
+ *          \/
+ *          *
+ *
+ * Each field (f) owns two triangles: (r)ight & (d)own. When we look at the
+ * field, we have to make sure to schedule drawing the triangles. This is done
+ * by TerrainProgram.
+ *
+ * To draw dithered edges, we have to look at the neighboring triangles for the
+ * two triangles too: If a neighboring triangle has another texture and our
+ * dither layer is smaller, we have to draw a dithering triangle too - this lets
+ * the neighboring texture bleed into our triangle.
+ *
+ * The dither triangle is the triangle that should be partially drawn (either r or
+ * d). Example: if r and d have different textures and r.dither_layer >
+ * d.dither_layer, then we will repaint d with the dither texture as mask.
+ */
 
 namespace {
 


Follow ups