XNA Game Studio 3.1 Video Sample

Here’s a sample on how to use the new support for video files in XNA Game Studio 3.1.

All you have to do is add the video file (wmv) to your Content project, and you’re ready to use it with a few lines of code.

The sample loads a video containing a montage of XNA games, released some while ago. After loading it, you can view it in 4 ways (use spacebar/gamepad A to change):

Here’s some screenshots:

VideoSample 2009-06-11 21-37-40-68 VideoSample 2009-06-11 21-37-41-48

VideoSample 2009-06-11 21-38-04-88

And here’s the sample: VideoSample.zip

P.S. If a video file you have doesn’t work from the first try, try re-encoding it with Windows Movie Maker.