如何在虚拟环境中呈现Windows程序 [英] How to Render Windows Programs in Virtual Environment

查看:89
本文介绍了如何在虚拟环境中呈现Windows程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在非桌面虚拟环境中使用Windows(例如虚拟房间中的3D用户界面),但我几乎不知道如何最有效地实现它。我将使用OpenGL来呈现用户界面和虚拟环境。我知道我可以通过将每个程序窗口角落的当前像素位置映射到用户界面中的缩放对应点然后重新渲染相应区域中的所有纹理来实现这一点,但这将非常繁琐。有没有更简单,更有效的方法来使用一些Windows API或利用Windows渲染程序的方式?谢谢。

I would like to work with Windows in a non-Desktop virtual environment(for example 3D user interface in a virtual room) but I have almost no clue how to most efficiently implement this. I will be using OpenGL to render the user interface and virtual environment. I know that I could possibly implement this by mapping the current pixel locations of the corner of each program window to a scaled corresponding points in the user interface and then rerender all the textures in the corresponding area but this would be extremely tedious. Is there an easier and more efficient way to do this using some windows API or by taking advantage of how windows renders programs? Thanks.

推荐答案

您应该使用Windows-API获取屏幕坐标并在OpenGL代码中使用它们。 OpenGL应该将绘图直接处理到Windows中的显示驱动程序。
you should use the Windows-API to get the screen coordinates and use them in your OpenGL code. The OpenGL should direct process the drawing to the display driver in the Windows.


这篇关于如何在虚拟环境中呈现Windows程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆