OSG官网——Windows --Compiling with Visual Studio翻译

Follows are details on usage of OpenSceneGraph from source packages. These are useful if you want to always stay up to date with the newest OSG sources from the github repository, or to use an OSG release that has no binaries. If you don't want this, you can probably use precompiled binaries from the Downloads page

以下是一些OSG源代码包的一些使用细节。这些都很有用,如果你一直保持跟随github repository,的最新的源代码,或者使用没有二进制包的OSG 发行版。如果你不想这样,可以直接使用预先编译好的二进制版本。

Subpages:
Help for compiling specific optional plugins
Instructions when using older Visual Studio versions (6.0)

Compiling with Visual Studio .NET用VS.NET 编译

(Note: These instructions are valid for Visual Studio .NET 2005 (8.0) and Visual Studio Express 2005 (see below), but they should also apply to Visual Studio .NET 2003 (7.0) or to Visual Studio .NET 2008 (9.0).)

注意:这些指示对VS.NET 2005 (8.0)是有效的,VS2003,VS2008 也是一样的

Initial setup初始安装

The project files are set up so that if you have the dependencies in the same base directory as the OpenSceneGraph sources, then it will find them. Thus, the suggested directory structure is:

这个项目文件已经建立好了,如果你具有和OSG一样的目录中有依赖,这些目录应该是这样的:

OpenSceneGraph-VERSION (replace VERSION by 2.8 or SVN or whatever) 
OpenSceneGraph-VERSION\3rdParty (put the contents of the 3rdParty zip file in here) 第三方库的zip文件放在这里
OpenSceneGraph-VERSION\OpenSceneGraph

In the OpenSceneGraph directory, see the Downloads page and download the sources for the version you're interested in, or check out the sources from the github repository,

OpenSceneGraph 目录中,请看the Downloads page并下载源代码,或者从github repository检出源代码。

In the 3rdParty directory, see the Dependencies page and download the dependencies for your platform. Place them so that the bin, lib etc. directories are directly under OpenSceneGraph-VERSION\3rdParty .

在第三方库目录下,看the Dependencies page依赖页面)然后下载这些依赖把他们放置起来。放到OpenSceneGraph-VERSION\3rdParty目录下。

Generating Project & Solution files with CMake  CMake使用的一般项目&解决方案文件

Once the sources and dependencies are in place you need to generate the Visual Studio solution and project files. This is done with CMake. Download it at Download | CMake.

一旦源代码和依赖都到位了,就可以创建VS解决方案和项目文件了,这是由CMake来完成的。请你去下载它。

Start the CMake GUI once it's installed, and select root OpenSceneGraph directory in the "Where is the source code" field. The same directory needs to be put into the "Where to build the binaries" field. If you like to do out-of-source builds, you can add \build to the end. Then click Configure.

安装完就开启CMakeGUI,并选择根OSG目录在"Where is the source code"域中。同样的目录需要被放入"Where to build the binaries"域中。如果你喜欢做out-of-source builds,你可以添加\build 到末端,然后点击Configure

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值