开发者

Grab the contents on screen painted via OpenGL

开发者 https://www.devze.com 2023-03-29 13:15 出处:网络
I want to know if its possible to grab the contents of screen/surface painted via OpenGL? and how to do it?

I want to know if its possible to grab the contents of screen/surface painted via OpenGL? and how to do it?

I mean something like this (From Quarzt), If I have CGBitmapContextRef, I can do all the drawing 开发者_C百科activity on it and then create a CGBitmap out of it. Is there something similar? If not please suggest some different approach.


Yes, for this you have to use glReadPixels, but you should notice that heavy use of this function can be slow.

0

精彩评论

暂无评论...
验证码 换一张
取 消