第一步:下載下傳Hydrax-v0.5.1插件
下載下傳頁面:http://www.ogre3d.org/tikiwiki/Hydrax#Downloads

插件下載下傳位址:http://modclub.rigsofrods.com/xavi/Hydrax-v0.5.1.rar
第二步:由于原來的預設環境是2005,是以需要将項目轉換為2008。
預設release下進行編譯,會出現N多錯誤
第三步,進行糾錯
糾錯網址:
http://www.ogre3d.org/addonforums/viewtopic.php?f=20&t=11089
對着改
第1處:
SimpleGrid.cpp裡面第305行
第2處
mesh.cpp裡面414行
繼續該檔案,原來檔案裡面421行(由于前面已修改,這裡是426行)
繼續該檔案,原來檔案裡面435行(由于前面已修改,這裡是444行)
繼續該檔案,原來檔案裡面442行(由于前面已修改,這裡是456行)
第3處
cfgFileManager.cpp檔案第305行
第4處
cfgFileManager.h檔案第159行
改完後運作
第四步:編譯插件自帶的Demo1
右鍵點選Demo1解決方案,選擇設為啟動項目
然後在Release下面運作,會出現一堆錯誤
将開始生成的Release版本的dll,lib(我的這兩個檔案位于C:\Users\nomorefancy\Desktop\Hydrax-v0.5.1\Hydrax\bin\release)
放入Demo1檔案夾下(我的是C:\Users\nomorefancy\Desktop\Hydrax-v0.5.1\Demo1)
然後運作,會提示找不到resources.cfg檔案
然後将Demo1中bin目錄下的release中的Plugins.cfg和resources.cfg檔案拷到Demo1檔案夾下
将resources.cfg檔案中的所有 ../../ 去掉
變成
# Resource locations to be added to the 'boostrap' path
# This also contains the minimum you need to use the Ogre example framework
[Bootstrap]
Zip=Media/packs/OgreCore.zip
# Resource locations to be added to the default path
[General]
FileSystem=Media
FileSystem=Media/materials/programs
FileSystem=Media/materials/scripts
FileSystem=Media/materials/textures
FileSystem=Media/models
Zip=Media/packs/SkyBoxes.zip
[Hydrax]
FileSystem=Media/Hydrax
最後運作,啊哈,結果終于出現了、
這海洋各種特效啊,神馬折射、反射、焦散、柏林噪聲、FFT各種高端。正好這個項目我做海洋部分。是以我應該會對裡面的源碼進行研究。到時候有成果了跟大家分享哈