facebook rss twitter

Streaming DivX through the Xbox 360

by Casey Chesnut on 18 January 2006, 01:45

Tags: Xbox 360, Microsoft (NASDAQ:MSFT), DivX, Xbox 360

Quick Link: HEXUS.net/qaekg

Add to My Vault: x

First steps...

ASX

First, I created the _MediaEncoder.asx text file with the line mms://COMPUTER-NAME:8080. NOTE: you can use an IP Address to the Media Center Computer too. This file goes in your 'My Videos' file and it is what you use to view whatever is being streamed using Media Encoder.

You can also tweak the ASX file a bit to include a thumbnail image (just add both to your 'My Videos' folder) : _MediaEncoder2.asx and _MediaEncoder.jpg

Media Encoder

Second, I downloaded and installed Windows Media Encoder 9 and the Windows Media Encoder 9 SDK. With the ASX file and the WM9 Encoder installed, you can manually test to see that it works with the files that you are interested and to judge quality etc... NOTE: the code below streams to port 8080, so no other program can be using that port. If you change it do a different port, then you need to change the .asx file as well. This will create an error in the log file that looks like : An attempt to acquire a network resource failed.

Click for larger image


Codecs Originally, I had the ffdshow codecs installed, but it was not working with Media Encoder. From the thread above, I switched to DivX 6.1 and AC3 1.01a RC5. If you've got a file that won't play, first make sure you can play it with Media Player, then try to stream it manually with Windows Media Encoder. This makes it easier to experiment with different codecs. The GSpot Coded Information Appliance also comes in handy. Also, see the 'Extended Windows' and 'Permissions' sections below.

NOTE I did not try any HD DivX movies because it requires a 64 meg video card which I don't currently have. It will stream DivX with Advanced Features too (e.g. Revelations: Star Wars), but it just plays the menu sequence and you cannot interact with it.

Encoder Profile

Third step was to create a higher quality encoding profile that the end user can tweak and can be referenced from code. Created this with the 'Windows Media Profile Editor' which is either installed with Windows Media Encoder or the SDK. Named the file DVD_Quality_Video.prx which needs to be placed in the folder : C:\Program Files\Windows Media Components\Encoder\Profiles\. If the profile is not placed in that location, then the code will fail over to a lower quality profile. You can modify the profile to improve or reduce the streaming quality, e.g. you might switch from Constant Bit Rates to Variable Bit Rates.



NOTE: I changed the Video size to 'Same as video input' and let the Xbox do the scaling to fit the TV. This works for me, but if you have files with a really high resolution, then you'll need to reduce the quality to avoid skipping (e.g. anything over 720x480 might be too big to encode on the fly).



HEXUS.links: Check out casey's homepage at www.brains-N-brawn.com.