What's the fastest way to read the screen buffer using CUDA (Whole screen, not just a window)?
Can I do this without copying tons of pixels between host and device?
Can I access this specific buffer directly?
Asked
Active
Viewed 1,549 times
0

Kh40tiK
- 2,276
- 19
- 29
-
1I don't believe there is *any* way of reading the screen buffer using CUDA. – talonmies Jul 05 '13 at 11:16
-
I'm a newbie. Can u give me more explanation on this? What can CUDA do? Do I need to access the VGA mem? – Kh40tiK Jul 05 '13 at 11:32
-
Alter the gl buffer before being sent to display buffer. GL interop. – huseyin tugrul buyukisik Jul 05 '13 at 14:54
1 Answers
1
Render to an openGL render buffer object, then use CUDA OpenGL interop to map it to a device pointer and read it in a CUDA kernel. You can also do the equivalent with Direct3D.
See the Graphics Samples included with the CUDA SDK.

harrism
- 26,505
- 2
- 57
- 88
-
Thanks for the answer. But the problem is how can I map the render buffer for the ENTIRE screen( without copying buffer to host mem )? For example, how can I catch a screenshot including start menu, desktop icons things? – Kh40tiK Jul 08 '13 at 13:02
-
That is not a CUDA question, and is not what you originally asked. You should post that as a separate question or remove the CUDA tag. A quick google turned up [this](http://blogs.msdn.com/b/dsui_team/archive/2013/03/25/ways-to-capture-the-screen.aspx). If my answer was helpful, please upvote and/or accept. – harrism Jul 09 '13 at 01:39