How to stream video from videogame to another computer in realtime?
===

I just started coding an application, my idea is to create something like StreamMyGame but for personal use, there is already a project called Single Player Game Transmiter that achieves some of this (http://sourceforge.net/projects/spgt/files/).

So far I'm not encoding nor streaming, I'm just capturing video and displaying it in my app window. 

So how could I handle encoding/streaming? I was thinking an UDP stream of raw JPEGs would be the easiest path but I'm not sure.

Also how could I optimize what I have so far? It works fine for video playback but when capturing game windows it doesn't seem as snappy as the original video, I think it might be due to the fact that it's running in the background. That leads me to another question, how can I capture the Window with the specified title instead of the active Window?


https://github.com/fr500/desktop_streamer