PhysX學習筆記1 - win2000運行PhysX的demo時出錯

來源:互聯網
上載者:User
 Keys: PhysX, Novodex,windows2000

一、所需安裝包及步驟
1. PhysX_6.11.01_SystemSoftware.exe(主要)
2. PhysX_2.6.2_SDK_Core.exe(主要)
3. PhysX_2.6.2_Tools.exe

我的系統是win2000.用vc2005。
(雖然安裝包裡面說支援winXP及以上版本,但我發現在win2000下demo幾乎都可以運行)

二,運行demo
假設安裝在c:/AGEIA Technologies/AGEIA PhysX SDK/v2.6.2, 以下目錄均以此為根目錄。

demo的原始碼位置在
Samples/
TrainingPrograms/
所有demo的exe檔案集中在 Bin/win32/ ,有兩類Sample***.exe和Lesson***.exe

---------------問題1-----------------

系統是windows2000,運行PhysX的demo時有如下問題:
TrainingPrograms/目錄下所對應的程式,即Lesson***.exe(在Bin/win32/下)運行時出錯退出。
Samples/ 即Sample***.exe(在Bin/win32/下)可以正常運行。

解決方案:
將主程式中sceneDesc.simType = NX_SIMULATION_HW,
改為sceneDesc.simType = NX_SIMULATION_SW即可。
即:把硬體類比設定為軟體類比。

詳細步驟:(以一個為例,其他同理)
1.開啟
  TrainingPrograms/Programs/Chapter10_Cloth/Lesson1001_Cloth/compiler/vc7/Lesson1001.sln
2.在Lesson1001.cpp中尋找字串"NX_SIMULATION_HW"所在位置
  結果有兩處:
  a)bHardwareScene = (gScene->getSimType() == NX_SIMULATION_HW);
  b)sceneDesc.simType = NX_SIMULATION_HW;
3.將sceneDesc.simType = NX_SIMULATION_HW; 的NX_SIMULATION_HW改為NX_SIMULATION_SW,即
    sceneDesc.simType = NX_SIMULATION_SW;
4.編譯運行,OK!

---------------問題2----------------
Lesson115.exe運行出錯退出,提示:
Assertion failed: ok, file <indstalldir>/trainingprograms/programs/chapter1_rigid_bodies/lesson115_mesh_shapes/source/lesson115.cpp, line 176
解決方案:
1.開啟TrainingPrograms/Programs/Chapter1_Rigid_Bodies/Lesson115_Mesh_Shapes/source/lesson115.cpp
將 line 176的“assert(ok);”注釋掉。
2.編譯運行,OK!

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.