<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
<tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="http://reviewboard.kde.org/r/4908/">http://reviewboard.kde.org/r/4908/</a>
</td>
</tr>
</table>
<br />
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('http://reviewboard.kde.orgrb/images/review_request_box_top_bg.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for KDE Games and Parker Coates.</div>
<div>By Stefan Majewsky.</div>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This patch adds support for custom colors, i.e. colors that are replaced inside the SVG element during rendering. Colors can be defined per client, e.g. to reuse an avatar for players with different player colors.
The implementation uses a proxy QPaintDevice that maps the used QBrushes and QPens during painting operations. This imposes a considerable runtime overhead (~20% on my site), so the proxy device is only used if there are custom colors. If the application does not use custom colors, the runtime overhead is therefore negligible.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">The proxy QPaintDevice was developed and tested in a separate application, and was shown to work with single-colored brushes and pens as well as gradients (see my blog entry at http://majewsky.wordpress.com/2010/08/05/the-color-changing-qpaintdeviceproxy/ for details).
I have tested the integration with KGameRenderer by randomly picking a color from a KDiamond diamond, and replacing that with my favorite debugging color cyan. Look at the attached screenshot to see that it works.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>trunk/KDE/kdegames/libkdegames/CMakeLists.txt <span style="color: grey">(1157590)</span></li>
<li>trunk/KDE/kdegames/libkdegames/colorproxy_p.h <span style="color: grey">(PRE-CREATION)</span></li>
<li>trunk/KDE/kdegames/libkdegames/colorproxy_p.cpp <span style="color: grey">(PRE-CREATION)</span></li>
<li>trunk/KDE/kdegames/libkdegames/kgamerenderer.h <span style="color: grey">(1157590)</span></li>
<li>trunk/KDE/kdegames/libkdegames/kgamerenderer.cpp <span style="color: grey">(1157590)</span></li>
<li>trunk/KDE/kdegames/libkdegames/kgamerenderer_p.h <span style="color: grey">(1157590)</span></li>
<li>trunk/KDE/kdegames/libkdegames/kgamerendererclient.h <span style="color: grey">(1157590)</span></li>
<li>trunk/KDE/kdegames/libkdegames/kgamerendererclient.cpp <span style="color: grey">(1157590)</span></li>
</ul>
<p><a href="http://reviewboard.kde.org/r/4908/diff/" style="margin-left: 3em;">View Diff</a></p>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Screenshots </h1>
<div>
<a href="http://reviewboard.kde.org/r/4908/s/472/"><img src="http://reviewboard.kde.org/media/uploaded/images/2010/08/05/colorproxy5_400x100.png" style="border: 1px black solid;" alt="Some color inside a KDiamond diamond replaced by cyan" /></a>
</div>
</td>
</tr>
</table>
</div>
</body>
</html>