This one almost slipped past me.
Lots of folks have asked about ways to automate encoding videos for Silverlight applications both on the client and on the server.
Ben Waggoner just announced that Expression Encoder 2 includes a .NET object model for automation.
The code in the SDK example looks really simple and straight-forward:
static void Main(string[] args)
{
MediaItem mediaItem = new MediaItem(@"C:\Users\Public\Videos\Sample Videos\Bear.wmv");
// Create a job and the media item for the video we wish
// to encode.
Job job = new Job();
job.MediaItems.Add(mediaItem);
// Set up the progress callback function
job.EncodeProgress
+= new EventHandler<EncodeProgressEventArgs>(OnProgress);
// Set the output directory and encode.
job.OutputDirectory = @"C:\output";
job.Encode();
}
static void OnProgress(object sender, EncodeProgressEventArgs e)
{
Console.WriteLine(e.Progress);
}
I haven't tried it out yet, but it looks like it would work in both server and client scenarios as they provide a number of examples including console and wpf. If you give it a spin, let me know how it works for you.