Franco.Chou's Space

Franco's Tech Blog

Monthly Archives: 10月 2008

version matching for OGRE(by Fanco)


Version matching is gnawing!
Why Microsoft always give us a lot of sdks and sp1,sp2…. and different versions to match?
OK,here is my experience of version matching:OGRE for VS2008
how to configure VS2008 with OGRE?
 
Firstly,download "OGRE 1.4.9 Source For Windows" and "Visual C++.Net 2008 (9.0) Precompiled Dependencies 1.4.x"
from http://www.ogre3d.org/index.php?option=com_content&task=view&id=412&Itemid=132 it’s not hard ,right?But it’s very very important!
don’t download wrong versions.
 
Sencondly,uncompress the two packs,and we get 3 folders here:"ogre" "sample" and "Dependencies".Put Dependencies into ogre.And we get
the physical location(for example:"C:\ogre" and "C:\ogre\Dependencies"). AND very important,put all the dlls in "Samples\Common\bin\Debug" into "…ogre\Samples\Common\bin\Debug" AND put all the dlls in "Samples\Common\bin\release" into "…ogre\Samples\Common\bin\release"
 
Thirdly,we should configure the environment for VS2008.Follow me as this:
tools–>options–>items and solutions–>C++ directory  choose "include files".And add the include folder in ogreMain(for example:C:\ogre\OgreMain\include)here.AND VERY VERY IMPORTANT also the include and lib folers in Dependencies(for example:
C:\ogre\Dependencies\include and C:\ogre\Dependencies\lib)OK.it’s done.
 
Open "ogre.sln in folder "ogre"
AND COMPILE ALL.If lucky no errors.(Come on,don’t take care of the warnings)
 
BUT if you don’t install dx sdk,here comes the problem as me:
错误 173 fatal error C1083: 无法打开包括文件:“d3dx9.h”: No such file or directory c:\ogre\rendersystems\direct3d9\include\OgreD3D9Prerequisites.h 47 RenderSystem_Direct3D9
 
AND add the lib into VS2008
tools–>options–>items and solutions–>C++ directory  choose "include files". Add "C:\dx9.0 sdk\Lib(or C:\dx9.0 sdk\Lib\x86)"  and "C:\dx9.0 sdk\Include" here(ur physical location may be different).The system may also add them for u.No more details for it here.
 
U may also face an error :"cmd.exe".
It’s very strange for me.And I look for its solution for a long long time.
tools–>options–>items and solutions–>C++ directory 
Here it is:put into $(SystemRoot)
                        $(SystemRoot)\System32
                        $(SystemRoot)\System32\wbem
 
And compile all,damn!!!!!!
in MilkshapeExport  错误 1 error LNK2001: 无法解析的外部符号 CreatePlugIn MilkshapeExporter.def MilkshapeExport
                          错误 2 fatal error LNK1120: 1 个无法解析的外部命令 
OK,ignore it !!!
{罗佳 18:25:02
milkshape的资源导出插件,无所谓了,我们都用不到这个插件}  ^_^
 
Open "C:\ogre\Samples\Common\bin\Release"(urs may be different,) u can see 32 exes.Choose one and double-click.
Amazing things comes to u! It’s OGRE!
 
 

关于OGRE 3D


    OGRE 3D 是一个被广泛使用的开源三维图形渲染库,成功地被应用于诸多三维仿真领域,其中包括网络游戏和一些商业的三维仿真项目
 

游戏引擎基础