使用Separate插件分离图像输出
The Separate plugin is used to create a separate window for each eye. It can be used with any devices that support separate images output, e.g. for 3D video glasses or helmets (HMD)Separate插件用于为每只眼睛创建一个单独的窗口。它可以与任何支持单独图像输出的设备一起使用,例如用于3D视频眼镜或头盔(HMD)
- The Separate plugin is available only on DirectX 11 graphics API. So it can be used under Windows only. Separate 插件仅在 DirectX 11 图形API上可用。因此只能在Windows下使用。
- This plugin cannot be used in a Qt-based application.此插件不能在基于Qt的应用程序中使用。
Separate can be rendered in both the windowed and the full-screen mode.Separate可以在窗口模式和全屏模式下呈现。
Launching Separate启动Separate#
To use the plugin, specify the extern_plugin command line option and STEREO_SEPARATE define on the start-up:要使用该插件,请在启动时指定extern_plugin命令行选项,并定义 STEREO_SEPARATE :
main_x64d -extern_plugin "UnigineSeparate" -extern_define STEREO_SEPARATE
Also you can create a new project with the Separate plugin support by checking the Dual output stereo 3D option on the New Project tab of the UNIGINE SDK Browser.您也可以通过选中UNIGINE SDK浏览器的New Project选项卡上的Dual output stereo 3D选项,创建具有Separate插件支持的新项目。
The engine automatically loads the appropriate version of the library depending on the specified main application. So you can use 64-bit debug or release version of the library.引擎将根据指定的主应用程序自动加载适当版本的库。因此,您可以使用该库的64位调试或发行版本。
- Multi-monitor plugins (SpiderVision)Multi-monitor plugins (SpiderVision)
- Panoramic renderingPanoramic rendering
- The other stereo 3D pluginsThe other stereo 3D plugins
- Multi-monitor plugins (SpiderVision)多监视器插件(SpiderVision)
- Panoramic rendering全景渲染
- The other stereo 3D plugins其他立体3D插件
Customizing Separate自定义Separate#
Unigine-based application can be used with any custom device that supports an output of separate image pairs. You simply need to do the following:基于Unigine的应用程序可与支持单独图像对输出的任何自定义设备一起使用。您只需要执行以下操作:
- Define the application behaviour when the STEREO_SEPARATE define is set on the start-up or in the configuration file:
在启动时或在配置文件中设置STEREO_SEPARATE定义时,定义应用程序行为:
#ifdef STEREO_SEPARATE // implement your code here #endif
#ifdef STEREO_SEPARATE // implement your code here #endif
- Implement the input device interface using an extensible C++ API.使用可扩展的 C ++ API 实现输入设备接口。
Stereo settings that control eye separation and distance to the zero parallax plane are added to GUI by data/core/scripts/system/stereo.h script and can be controlled from there.通过data/core/scripts/system/stereo.h脚本将控制眼睛分离和到零视差平面的距离的立体声设置添加到GUI,并可以从那里进行控制。