<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.silverlight.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Game Development</title><link>http://forums.silverlight.net/forums/52.aspx</link><description>A forum for discussions around casual game development using Silverlight.  Ask about game logic, animations, etc. with regard to game development.</description><dc:language>en</dc:language><generator>CommunityServer 2007 (Build: 20416.853)</generator><item><title>Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/276919.aspx</link><pubDate>Thu, 27 Aug 2009 07:15:57 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:276919</guid><dc:creator>Jose Luis Quintero Mendez</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/276919.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=276919</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;Example in Game RPG. &lt;a href="http://www.elquintero.net/games/SimonTheLegacy/"&gt;http://www.elquintero.net/games/SimonTheLegacy/&lt;/a&gt;&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/244534.aspx</link><pubDate>Wed, 08 Jul 2009 11:49:30 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:244534</guid><dc:creator>Grofit</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/244534.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=244534</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;I revisited my tile system to see if there were any immediate issues i could look at updating... and it ends up that i was already translating the canvas, so im not positioning every single one of the tiles... one thing is though im using 32x32 tiles so i would end up having more smaller elements compared to your fewer larger elements... i wont be in my actual game but as im just prototyping everything i thought i would start with them.&lt;/p&gt;&lt;p&gt;Anyway my framerate is awful, its perfect if you are stationary constantly &amp;gt; 60fps with menus and other things going on... but the scrolling kills it. It seems to be marginly slower if i just put all the tiles into the canvas and let SL deal with what to display on the given page. However if i use a quadtree system to enable/disable children as and when are needed it is like 5fps faster.&lt;/p&gt;&lt;p&gt;Im not sure if the bottle neck comes from having lots of things to draw on screen or just having lots of things in the canvas... im hoping to be able to have &amp;gt;30fps consistantly with the scrolling and lots of stuff on screen at once and hopefully some simple particle style effects... although im not sure if it will happen :( as im struggling to get &amp;gt;20 fps when scrolling with more than 1 tile layer at the moment... im still got a few optimizations up my sleave like baking the static things together ad a few other tweaks around...&lt;/p&gt;&lt;p&gt;I also tried testing my app on my other laptop, which is a dedicated gaming one... and it got pretty much the same performance as my crappy little laptop which i found as odd...although it does only have a single core (its &amp;gt;3 years old), and im guessing SL still hammers the CPU more than anything else... &lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243986.aspx</link><pubDate>Tue, 07 Jul 2009 14:45:26 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243986</guid><dc:creator>HaywireGuy</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243986.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243986</wfw:commentRss><description>&lt;p&gt;Well, Ksleung I am not sure if that is going to solve my problem. I was merely doing a WriteableBitmap.Render(m_SourceImage, new TranslateTransform) when the &amp;quot;jump&amp;quot; needs to happen (roughly once per second), and it already causes jittery movement. I can of course lower my frame rate to make the &amp;quot;jump&amp;quot; transition smooth (if each frame takes longer time than what is required for the jump transition, then the jump won’t be noticeable). But I doubt I’d want to go there. I do trust SL team will be improving this &amp;quot;blitting&amp;quot; overtime though.&lt;/p&gt;
&lt;p&gt;Gofit, I have 384 tiles in the humungous Content Canvas at one time. Older tiles that scrolled out of view will be recycled and used in position of newer tiles, which then get scrolled into view. The only reason I use humungous canvas is because of the limitations I stated in the original post (to avoid 384 calls to Get/SetValue on 384 Image objects, which was proven to be costly).&lt;/p&gt;
&lt;p&gt;The tiles are the &amp;quot;background&amp;quot; actually. 384 isometric tiles made up the map that covers the entire displayable area. I have yet to put static buildings on the map, but I don’t expect that to cause much problem. The frame rate for a scrolling background of this many tiles is quite satisfying on my single core laptop actually. &lt;img src="http://silverlight.net/emoticons/emotion-2.gif" alt="Big Smile" /&gt;&lt;/p&gt;</description></item><item><title>Re: Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243715.aspx</link><pubDate>Tue, 07 Jul 2009 07:21:35 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243715</guid><dc:creator>Grofit</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243715.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243715</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;I completely agree with you about WritableBitmap being alot better suited for this sort of task, just with the performance bottle neck its a killer...&lt;/p&gt;&lt;p&gt;When you said you were getting around 54 Fps constant with a massive canvas, how many tiles did you have (roughly) in it and how many tiles were on screen at once (roughly), for my game the resolution will be anything between 640x480 to 1280x1024 (or whatever the resolution is around that size). This means i would have a few hundered on screen at once, but also they are layered, so although there may be lets say 200 flat tiles, there may be 3x this many acctually on the screen, and paired with any other moving objects... i think im going to try and test this tonight, i got a bit carried away with writing some of the logic the other day... oh and moving house, so will see if i can bring back any numbers from my example...&lt;/p&gt;&lt;p&gt;At the moment the juddering on translating is killing my game, and if i could get rid of that it would probably be fine and i can do a little dance! OH also while we are on topic...&lt;/p&gt;&lt;p&gt;so far we have been comparing Canvas.Top/Left vs TranslateTransformation.X/Y, for a reason i cant remember off the top of my head i have had to use both. I think the static tiles dont ever change the Canvas.Top/Left but as i have lots of moving entities they require the canvas position to move as well as the render transformations... well i think so off top of my head anyway...&lt;/p&gt;&lt;p&gt;In your game im guessing you will have the goomba equivalent which will be moving around a bit, how have you gone about doing his movement with a scrolling background? Same route as me or some other gem? &lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243314.aspx</link><pubDate>Mon, 06 Jul 2009 17:30:52 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243314</guid><dc:creator>ksleung</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243314.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243314</wfw:commentRss><description>&lt;p&gt;Good to hear that you made some progress.&lt;/p&gt;&lt;p&gt;One comment on WriteableBitmap.&lt;/p&gt;&lt;p&gt;I don&amp;#39;t think the SL team will provide access to the WriteableBitmap in background thread.&amp;nbsp; The reason is that SL must have full access to all UI assets whenever it is running the UI thread, so it really cannot afford to let you muck with it in the meantime.&lt;br /&gt;&lt;/p&gt;&lt;p&gt;I do hope that the SL team can provide better WriteableBitmap APIs.&amp;nbsp; Currently the only pixel access is the [] operator, which I image has tons of checks (security and bound) on a per-pixel basis.&amp;nbsp; This is highly inefficient especially we all want to use WriteableBitmap in a very heavy way.&amp;nbsp; Why not provide wholesale array copy API?&amp;nbsp; For example,&lt;/p&gt;&lt;p&gt;&lt;font face="courier new,courier"&gt;WriteableBitmap.CopyFrom(int[] Src, int SrcWidth, int SrcHeight, Rect Region, int TranslateX, int TranslateY);&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;font face="courier new,courier"&gt;WriteableBitmap.CopyTo(int[] Dest, int DestWidth, int DestHeight, Rect Region, int TranslateX, int TranslateY);&lt;/font&gt; &lt;/p&gt;&lt;p&gt;This way, whatever check only needs to be done once.&lt;/p&gt;&lt;p&gt;It is still okay to require that these APIs be called from the UI thead.&amp;nbsp; But at least this approach would allow us to write decent code to perform all the maths in the background thread, and make one async call to push the result to the WriteableBitmap.&lt;/p&gt;&lt;p&gt;I hope the SL team would consider this.&amp;nbsp; Perhaps they already did, but the frustrating thing is that nobody knows! &lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243201.aspx</link><pubDate>Mon, 06 Jul 2009 14:18:22 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243201</guid><dc:creator>HaywireGuy</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243201.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243201</wfw:commentRss><description>&lt;p&gt;Okay folks, I have got some updates regarding the humungous Canvas. The outcome is good; I have created Canvas of size 20480x10240 pixels at no additional cost (both in terms of memory consumption and performance). So Ksleung was right. I am having 384 tiles visible each of which is 64x32 pixels in size. Content Canvas hosting them moves smoothly (it is going at 58fps constantly) since I no longer have to offset these 384 tiles when the “jump” happens.&lt;/p&gt;
&lt;p&gt;Thanks for your performance benchmark, Bill. I still use Get/SetValue methods for now as 384 tiles are much lesser than 4000 in your case, so I don’t expect that to cause too much of a problem (also I suspect creating another 384 TranslateTransform will likely to stress .NET runtime in a way that it needs to track these objects’ lifespan).&lt;/p&gt;
&lt;p&gt;I am not sure what is going to happen if I have more tile bitmaps in future, I hope Silverlight runtime puts all my bitmaps on one texture in hardware level (imho texture switching in video memory is costly).&lt;/p&gt;
&lt;p&gt;While this is not the optimal solution I would personally like to see (I think WriteableBitmap is more “natural” for my purposes), it does solve the problem for now. Ultimate solution I’d like to see is the ability to access Image (in SL3 RTW, even if it is read-only) from a background thread, then the jittery issue can be completely resolved.&lt;/p&gt;
&lt;p&gt;Thanks again for your help, guys!&lt;/p&gt;</description></item><item><title>Re: Re: Re: Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243147.aspx</link><pubDate>Mon, 06 Jul 2009 13:09:24 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243147</guid><dc:creator>Qbus</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243147.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243147</wfw:commentRss><description>Man, you have a lot of good stuff coming :) Really looking forward to it. Actually I have just brought Michael Show&amp;#39;s &amp;quot;Game development in Silverlight&amp;quot; book (not sure the name is right). Guess I will by yours when it comes out.</description></item><item><title>Re: Re: Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243145.aspx</link><pubDate>Mon, 06 Jul 2009 13:06:35 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243145</guid><dc:creator>Bill Reiss</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243145.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243145</wfw:commentRss><description>&lt;p&gt;I also have a solution to the inheritance problem that I&amp;#39;ll be blogging about soon and is covered in the updated game chapter in my book, available soon electronically.&lt;/p&gt;</description></item><item><title>Re: Re: Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243143.aspx</link><pubDate>Mon, 06 Jul 2009 12:59:12 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243143</guid><dc:creator>Qbus</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243143.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243143</wfw:commentRss><description>Ok great, I would like to read that post, as you can see I have asked my self the same question, about using one over they other.

A big difference between Canvas and Grid, is the ease of implementation if you ask me. It&amp;#39;s much easier to implement the Canvas approach. When using the Grid you need to set up all these transforms in the load event of something, and it&amp;#39;s pretty much code you need to repeat, as you can&amp;#39;t just easially inherit stuff like this in Silverlight.

:)</description></item><item><title>Re: Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243104.aspx</link><pubDate>Mon, 06 Jul 2009 11:33:50 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243104</guid><dc:creator>Bill Reiss</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243104.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243104</wfw:commentRss><description>&lt;p&gt;For my tests, both used a Canvas, since the Grid has some overhead even if you&amp;#39;re just using TranslateTransform and you&amp;#39;re not using any of its features anyway, and I was using SL3 with GPU acceleration and about 4000 moving elements. I was getting about 40 FPS with Canvas.Left and Canvas.Top, and 45 FPS with TranslateTransform. With less elements the difference was negligible.&amp;nbsp;I&amp;#39;ll blog about my sample once SL3 is released.&lt;/p&gt;</description></item><item><title>Re: Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/243067.aspx</link><pubDate>Mon, 06 Jul 2009 09:52:30 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:243067</guid><dc:creator>Qbus</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/243067.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=243067</wfw:commentRss><description>&lt;p&gt;I actually did a test too on this (very simple) and I actually see it performing very equal. But I haven&amp;#39;t used any tools for performance testing or anything, just looked at the FPS counter. &lt;/p&gt;
&lt;p&gt;&lt;a href="http://laumania.net/post/Using-Grid-or-Canvas-as-sprite-container.aspx"&gt;http://laumania.net/post/Using-Grid-or-Canvas-as-sprite-container.aspx&lt;/a&gt;&lt;/p&gt;</description></item><item><title>Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/242739.aspx</link><pubDate>Sun, 05 Jul 2009 13:59:28 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:242739</guid><dc:creator>Bill Reiss</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/242739.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=242739</wfw:commentRss><description>&lt;div style="MARGIN:0in 0in 10pt;" class="MsoNormal"&gt;&lt;font size="3" face="Calibri"&gt;&lt;BLOCKQUOTE&gt;&lt;div&gt;&lt;img src="/Themes/silverlight/images/icon-quote.gif"&gt; &lt;strong&gt;HaywireGuy:&lt;/strong&gt;&lt;/div&gt;&lt;div&gt;Q: Should I be setting Canvas.LeftProperty, Canvas.TopProperty of each Image object, or should I use Image.RenderTransform property? Which one is faster and lighter to Silverlight runtime?&lt;/div&gt;&lt;/BLOCKQUOTE&gt;&lt;/font&gt;&lt;/div&gt;
&lt;div style="MARGIN:0in 0in 10pt;" class="MsoNormal"&gt;I did some tests on this recently and saw about a 10% performance gain using TranslateTransform instead of Canvas.Left and Canvas.Top. This is probably because of the extra overhead of setting attached properties using SetValue.&lt;/div&gt;</description></item><item><title>Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/242572.aspx</link><pubDate>Sat, 04 Jul 2009 16:50:17 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:242572</guid><dc:creator>ksleung</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/242572.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=242572</wfw:commentRss><description>&lt;p&gt;I am really surprised that the once-in-a-while rendering of primary to secondary WriteableBitmap is causing a lag...&amp;nbsp; A few ideas:&lt;/p&gt;&lt;p&gt;(1) make sure you don&amp;#39;t turn on the Bitmap Cache on the WriteableBitmap.&amp;nbsp; I don&amp;#39;t think it&amp;#39;ll help and in fact may force SL to do more work (keep a separate cached copy of something that takes zero effect to build).&lt;br /&gt;&lt;/p&gt;&lt;p&gt;(2) perhaps you can use multiple WriteableBitmaps, like 48x320.&amp;nbsp; So, you avoid the problem of having the blit the entire primary over to the secondary.&lt;/p&gt;&lt;p&gt;(3) i was also wondering about this in the previous reply...&amp;nbsp; can you look ahead and blit to the secondary when it is not as busy?&amp;nbsp; Not sure how to do this though (like an OnIdle)... &lt;/p&gt;&lt;p&gt;(4) yes it sucks that WriteableBitmap can only be touched in the UI thread.&amp;nbsp; I complained about this in the SL4 wishlist as well. &lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/242571.aspx</link><pubDate>Sat, 04 Jul 2009 16:40:10 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:242571</guid><dc:creator>Grofit</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/242571.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=242571</wfw:commentRss><description>&lt;p&gt;haha i didnt know there was a built in frame counter, i had my own timer going to track it... i found that using WritableBitmap was brilliant and logical and just like making a game on any other platform until i tried running it and it was slower than a 486 running crysis...&lt;/p&gt;&lt;p&gt;I found the only way to get *reasonable* performance (30fps) is to do the trick you mentioned earlier with 2 layers, one being the viewing canvas, and one being the moving canvas. It still juddered hits about 30fps every time you move, but thats alot better than 10fps it was hitting before... Ive turned GPU acceleration and caching on and noticed no benefit.&lt;/p&gt;&lt;p&gt;In my current game my player is usually at center of the screen unless they are near an edge, ive basically made my own simple translation system, so everything has a game position, then the virtual camera is bound to the players position and everything else is drawn with the offset of the camera. That way i dont have to worry about maintaining local and render transform things all the time (well i do but its abstracted) i just make sure everything has a game position, and then when the camera gets to close to an edge it becomes unbound from the player letting them walk to the edges of the screen... still doesnt work 100% way i want it to but its better than nothing...&lt;/p&gt;&lt;p&gt;My net will be off for a few days while i get it setup at the new place but it would be great to see how you get on as you sound like you are doing same stuff as me, if you can post any reports on FPS you are getting with movement and tiles that would be great! &lt;br /&gt;&lt;/p&gt;</description></item><item><title>Re: Super Mario, Tile Based Game and Silverlight Performance</title><link>http://forums.silverlight.net/forums/thread/242474.aspx</link><pubDate>Sat, 04 Jul 2009 09:51:31 GMT</pubDate><guid isPermaLink="false">d0d632c8-a6f7-4f68-b0ce-26aaafd62132:242474</guid><dc:creator>HaywireGuy</dc:creator><slash:comments>0</slash:comments><comments>http://forums.silverlight.net/forums/thread/242474.aspx</comments><wfw:commentRss>http://forums.silverlight.net/forums/commentrss.aspx?SectionID=52&amp;PostID=242474</wfw:commentRss><description>&lt;p&gt;First of all, thanks for taking time to answer my questions, guys. &lt;img src="http://silverlight.net/emoticons/emotion-2.gif" alt="Big Smile" /&gt;&lt;/p&gt;
&lt;p&gt;I have omitted some history on this implementation actually. Instead of having individual tiles, I used to have one WriteableBitmap in the Content Canvas. This WriteableBitmap is as big as the Content Canvas and it represents static background data (i.e. those bricks on screen). In DirectX term this is called &amp;quot;primary WriteableBitmap&amp;quot;, and there is another &amp;quot;secondary WriteableBitmap&amp;quot; which is not shown on screen.&lt;/p&gt;
&lt;p&gt;When the &amp;quot;jump&amp;quot; needs to happen, the unchanged portion of the &amp;quot;&lt;strong&gt;primary WriteableBitmap&lt;/strong&gt;&amp;quot; is blitted to the &amp;quot;&lt;strong&gt;secondary WriteableBitmap&lt;/strong&gt;&amp;quot; through &amp;quot;WriteableBitmap.Render&amp;quot; method. Delta tiles are then rendered on the &amp;quot;secondary WriteableBitmap&amp;quot;, followed by a &amp;quot;flip&amp;quot; which displays the &amp;quot;secondary WriteableBitmap&amp;quot; in the Content Canvas. Delta tiles are only a fraction of the entire screen, so blitting them (again, WriteableBitmap.Render) does not take much time, but I found the bottleneck is actually the part where &amp;quot;primary WriteableBitmap&amp;quot; is blitted onto the &amp;quot;secondary WriteableBitmap&amp;quot; (even in &lt;strong&gt;Release build&lt;/strong&gt; with &lt;strong&gt;GPU acceleration turned on&lt;/strong&gt; and &lt;strong&gt;bitmap cached&lt;/strong&gt; them).&lt;/p&gt;
&lt;p&gt;If you imagine a smooth scrolling of the Super Mario screen, there will be occasional &amp;quot;pause&amp;quot; happening, for my case, once every second. Though not exactly the same as Super Mario game, my game fixes the player in the middle of the screen, and it is very common for user to say &amp;quot;hey, please walk from (0, 0) to (80, 65)&amp;quot; with a click of the mouse button. Naturally, there will be multiple &amp;quot;jumps&amp;quot; that need to happen, which results in jittery scrolling.&lt;/p&gt;
&lt;p&gt;I tried using a &lt;strong&gt;BackgroundWorker&lt;/strong&gt;, but as you may already know, it does not allow access to tile &amp;quot;Image&amp;quot; objects which are required for composing the &amp;quot;secondary WriteableBitmap&amp;quot; in the worker thread. I’d really appreciate if anyone can illustrate &lt;strong&gt;how to do &amp;quot;WriteableBitmap.Render&amp;quot; in a non-UI thread&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Then I switched to use independent Image objects on-screen. Currently for the extreme case of my game, I will only have around 500 tiles on screen. It improves the jittery situation significantly, but still the jitter can be felt slightly. So if I am able to eliminate the offsetting of each Image object (by using a humungous Content Canvas), then the problem is likely to be resolved completely. Let me report this back soon as I figure it out (thinking of BitmapCache and the humungous Content Canvas sends a chill down my spine…).&lt;/p&gt;
&lt;p&gt;Also, I believe it is right to say single BitmapSource is duplicated for each Image object; that may explain why I saw bigger numbers when I turned on &amp;quot;EnableFrameRateCounter&amp;quot;, if there are more Image objects (by the way, can you explain what are the five numbers shown when &amp;quot;EnableFrameRateCounter&amp;quot; is turned on? I know the first one is frame rate).&lt;/p&gt;
&lt;p&gt;I welcome more suggestions and possible ways to eliminate jitters entirely.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Thanks,&lt;br /&gt;Ben.&lt;/p&gt;
&lt;p&gt;(Marked both these as answers, both helped in some ways.)&lt;/p&gt;</description></item></channel></rss>