What to choose for developing games for Windows Phone 7? Silverlight or XNA

Original author: Silverlight Games 101
  • Transfer
imageAs a result of support, both XNA and Silverlight on the Windows Phone 7 platform, a common question is - what is the best way to write games? The answer is simple - it all depends on ... :)

Both technologies have characteristic advantages and it would be nice to ultimately combine the graphics capabilities of both technologies in the same application and use the best tool for work. I have not delved into XNA’s changes on Windows Phone yet, so I’ll draw conclusions based on my XNA game development experience in the past.

In general, writing games will be easier in XNA, as XNA was nurtured like a game framework. Many decisions that were made in the design of XNA also make the platform not the best for developing other types of applications other than games.

The main architectural difference is the visual tree, rather than drawing everything in each frame. In Silverlight, to display something, you need to add it as a child. In XNA, everything is drawn in every frame. If you obviously didn’t draw something, then nothing will appear. Which option is better depends on your game, but if there are many actions, then the option of "urgent" XNA rendering is best.

Let's take a look at some of the advantages of each technology (I am sure there are many of them on each side):

Benefits of XNA:


  • Great 3D support
  • Superior performance when moving many items or adding and removing them
  • Built-in game loop.
  • XNA user input is generally better for games than Silverlight input events.
  • XNA data pipeline makes handling data arrays easier
  • Support for more image types
  • You can develop games for Xbox and Phone
  • A combination of graphical models (Silverlight only has alpha overlay)
  • Less memory consumption for image-based games
  • More integrated GPU acceleration
  • Superior shader support
  • Drawing a little easier

Silverlight Benefits:


  • Vector graphics (XNA has simple line support)
  • Vector text rendering (XNA based on images)
  • You can create games for the web and phone
  • Storyboard animation
  • Visual states and various behaviors
  • Navigation framework
  • Controls (button, list, user controls, etc.)
  • Expression Design Support
  • Event-based model more familiar to developers
  • Data binding is sometimes very convenient.
  • VisualTreeHelper helps determine which item is touched

So, if your game is based on vector graphics or involves the presence of such things as buttons or other GUI elements, then it might be better to choose Silverlight for development. If you are making a 3D game or 2D with a lot of movements, or particle effects, then choose XNA. If you have something between these two technologies, then choose the one with which you are more familiar, as well as looking where you want to distribute the application on the web or Xbox.

It's great that both options are available to us and you can choose which one to use.

Also popular now: