Alex319
Alex319

Reputation: 3918

Take screenshots in GLUT

I have a GLUT application and I want to take a sequence of screen captures of the window so I can later put it into a movie. Is there a function that takes the contents of a window created by GLUT and puts it into an image file?

Upvotes: 3

Views: 1541

Answers (1)

genpfault
genpfault

Reputation: 52167

Use glReadPixels() to grab the framebuffer and dump the result using your favorite image handling library.

Upvotes: 4

Related Questions