Java: Capture video of what's on the screen

700 Software picture 700 Software · Mar 9, 2011 · Viewed 10.4k times · Source

We are considering writing a software in Java that records whats monitor for certain durations of time while it is running. Do you have any suggestions on how to efficiently capture the monitor output?

The less CPU it takes the more often we can capture the screen and the smoother a video we can generate without interfering with the other apps that are running.

An existing Open Source program in Java would work if it is not too difficult to copy out the screen capture section. I hope it won't require a call to another programming language. We will see.

Answer

unk1102 picture unk1102 · Mar 9, 2011

I'm not sure if you'll need a framework.

Check out the documentation for the java.awt.Robot class, specifically the createScreenCapture method.

http://java.sun.com/javase/6/docs/api/java/awt/Robot.html