Screentendo is a desktop application by Aaron Randall that creates a playable Super Mario Bros. level out of a selection of your screen. Randall has a full technical breakdown of the application on his blog, and the code is available online at GitHub.
When Screentendo is launched, a semi-transparent window appears which can be moved and resized over other application windows. After placing the Screentendo window over an area of the screen, clicking inside the window will cause the app to render a game level based on the content beneath it.
images via Aaron Randall