Final tweaks to improve Thumbnailing and now on CodePlex!

In the prior two posts, I talked about creating and fixing the logic for creating video thumbnails / screenshots but it had a few flaws in it. The first was I didn’t realize I had to close the MediaPlayer object’s stream, this caused memory to balloon upward after multiple plays.  Another problem was opening the same file for the same screenshots could cause issues in the long run at the same time.  To solve these issues, one was an easy fix, the other required a bit of threading knowledge. To correct this, I’ll first have a Dictionary object...

Improving Thumbnailing Code

From the prior post about getting thumbnails from a video in .Net, it was just prototype code and wasn’t properly abstracted.  Now it is time to fix it.  We’ll create a class called VideoScreenShot.  This class will function in both an asynchronous and synchronous mode.  This still could be improved by queuing up work but this is a nice refactoring. To get access to the tester app, head over to codeplex and source code can be found there too! public delegate void CaptureWorkerDelegate(BitmapFrame frame, object state); public static void CaptureScreenAsync(Uri source, TimeSpan timeSpan, object state, CaptureWorkerDelegate finalWorkerPrimary) { CaptureScreenAsync(source, timeSpan, -1, state, finalWorkerPrimary, null); } public static void...

Getting Thumbnails in WPF … on a non-UI thread

On my internal application for Channel 9, I have to create thumbnails at certain time codes in a movie.  After a giant headache attempting to track down the proper way of doing this, I figured out how to do this even if for a few hours I thought 127 seconds was the same at 1 minute and 27 seconds.  That caused some testing headaches as my test clip is 1:40 long. In this example I’ll write out the code for a threaded video thumbnail creating tool in WPF (XAML) and c#. To get access to the tester app, head over to codeplex and...

Creating my own media player

I’ve been tasked at creating a new feature / porting an application from WinForms to WPF at work.  Since Channel9 deals heavily with video, you guessed it, I have to deal with video! After attempting to see if there was a decent WPF player or example for the MediaElement, it really didn’t seem like there was.  Some of the examples did some crazy stuff when it wasn’t needed. So here are my requirements for it as of now: Play, Stop, Pause Be able to see current position’s time code ...

Drunktender lives! A brief live demo.

Drunktender - A brief demo from Clint Rutkas on Vimeo. I used red and blue water to create purple water to demonstrate the functionality of the hardware and software.  Trust me, it has a wicked kick back.

Drunktender – live alcohol test by making Irish Car Bombs

I was asked to make a quick demo for Ping( on MSDN’s Channel 9 (  I used this as an excuse to drink some car bombs along with test the system in a live setting with actual liquid and proper pouring.  Here is the system in action. Drunktender - Irish car bomb test from Clint Rutkas on Vimeo. So how did I create this simple app?  I have my relay source code pretty much locked down so all I need to do is fire off one command: relay.AddCommand( new RelayCommand(1, 1, 1000), new RelayCommand(1, 0, 1000), new RelayCommand(1, 2, 7000) ); In...

Relay code in action

Relay Test for drunktender from Clint Rutkas on Vimeo.

successful skateboard test

As Microsoft PDC approaches, I’m suppose to show off the skateboard in the Channel 9 lounge area.  I was also asked to submit it for the Show-off contest.  After a week’s worth of tweaking and disappointment, I successfully tested it. Self-balancing Skateboard PDC Show-Off clip from Clint Rutkas on Vimeo It also punched through some drywall again.

Breaking it down

I’ve been busy adding in the dead man switch and decided to video tape me taking the skateboard apart.  Everything is taken apart, with get this, 1 Allen wrench. I’m still noodling on doing some form of a quick disconnect for the wiring on the force sensors for the dead man switch.  I dislike the idea of having to screw and unscrew the wiring every time I want access.

Upgrade time for my subtext engine

Tim Heuer has created some very tight stuff for Live Writer such as Flickr4Writer and after sending in a nice little email to the LW team on why I couldn't get a feature that was there in Community Server, within I swear, 15 minutes, Tim had a fix on the totally different end than I expected. He made SubText ... work like WordPress ... in a few ways.  I gave me one feature I really wanted, another I might use, and is working on one I REALLY want. Tim, you, are my hero.  I can tag harder now.