views:

39

answers:

1

Hi!

i would like to know if it's possible, in c/c++, to launch an application and grab it's standard video output?

The goal of this would be to grab the buffer of an application, and use it as a texture for a grid of vertex with special texture coordinate (in order to project it in a FullDome)?

I'm developing under Linux.

Thnaks!

+1  A: 

Theoretically, it's possible. Is the other application using OpenGL? Or is just any X11 application?

If is just an X11 app, you need to do what a compositing manager does, which is use the COMPOSITE X extension to get window contents, and then process them.

If is just a OpenGL app, and you can modify it, you can use a FBO to draw everything to a texture, and use shader memory (SHM) to share the texture data with the other application.

Matias Valdenegro