物理エンジン「Box2D」のiPhone移植版が、「Rolando」の開発元HandCircus社でテストベッドとして開発され、オープンソースとしてsourceforgeで公開されています。
元々私がRolandoを見つけた経緯は、iPhoneでBox2Dを動作させているビデオからのつながりだったのです。

その後、同社がRolandoを開発していることがわかり、さらにパブリッシャーがng:mocoになったりしたのですが、「Rolandoのエンジンに使われただけなのかな?」と思っていたら、HandCircus社のHPにて「iPhone版Box2Dのポーティング(テストベッド)が出来たのでsourceforgeに上げてるよ」というエントリーを見つけました。
それによると、
HandCircus » iPhone port of Box2D Testbed now available
I’ve just added a port of the Box2D testbed to the project, which should hopefully help anyone that is planning on using it on their iPhone projects - you should be able to just build and go. Its got an OpenGLES renderer, and allows you to use the touchscreen and accelerometer to interact with the environment. Here’s some instructions on how to interact with it:
- On the first screen, choose the test project that you would like to run.
- Drag an object around the environment using your finger, or just drag on an empty part of the screen to pan around.
- Tilt the iPhone to affect gravity.
- Double tap to return to the projects list
I hope this of use to any budding iPhone developers out there!
You can download the Box2D engine (including the iPhone testBed) from here.
ということで、sourceforgeでiPhone testBedを含んだバージョンが公開されています。
※最新バージョンは「Last Update: Apr 13 2008」となっていますが、zipファイルの内容は「Version 2.0.1」で、最終更新は2009年2月2日となっており、iPhone(Xcode)用TestBedも同梱されています。
Box2Dといえば、特にFlasherの方には説明不要でしょうが、元々C++で書かれた物理演算ライブラリで、その後ActionScript3(Box2DFlashAS3)をはじめJava、Python、JavaScriptなど各種言語にポーティングされているエンジンです。
日本ではハドソンからパブリッシュされたクレヨンフィジックスなどのゲームもこのBox2Dエンジンを利用したアプリとして有名なところですね。
今回のテストベッドでは、Xcode + OpenGLES向けにポーティングされたエンジン部分のほかに、タッチインターフェース、加速度センサー入力をもサポートしているということです。iPhone開発に関わっている方はぜひチェックしてみてください。



Comments are closed.