捕获隐藏的 NSWindow
I'm able to capture NSWindow
s which are visible using code simular to the SonOfGrab Example
But how can I capture a hidden NSWindow
? Or what is the way to hide a NSWindow
from the user but to still appear in de Windowserver?
Thanks in advance!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
无法捕获屏幕上不可见的 NSWindow 的内容。当窗口最小化/隐藏/无论什么时候,视觉表示都会被删除以节省内存。
(不确定具体是如何管理的,如果您对窗口系统有更深入的了解,请随时插话。我只是根据尝试使用 CamTwist 和 BoinxTV 捕获窗口的经验才知道这一点。)
It isn't possible to capture the contents of an NSWindow which isn't visible on-screen. When a window is minimized/hidden/whatever, the visual representation is dropped to save memory.
(Not sure on exactly how this is managed, feel free to chime in if you have a deeper knowledge of the window system. I only know this from experience, trying to capture windows with CamTwist and BoinxTV.)
您可以通过以下方式做到这一点:
类别到 NSWindow:
You can do it by:
category to NSWindow: