Page 1 of 1

Mono anyone?

Posted: Thu May 12, 2011 2:29 pm
by jsprute
I was curious if anyone has tried getting this engine to work with MonoGame, MonoTouch, or MonoWhatever-they-want-to-call-it. I'm currently working on a game that uses BEPU and would love to use Mono to port the game to the Iphone and eventually Android.

The source is available, if no one has done it... maybe i'll go where no one dares?

Re: Mono anyone?

Posted: Thu May 12, 2011 7:19 pm
by Norbo
If you decide to do it, I'll appreciate it :) I've wanted to do it for a while, but haven't had the time.

It shouldn't be too horrible- the main dependency is just on some simple XNA math types, like bounding shapes and Vector3/Matrix/Quaternion. Switching out the reference for an equivalent library should do the trick with a few using statement modifications. The TriangleMesh.GetVerticesAndIndicesFromModel convenience method has some additional dependencies, but it's not too hard to work around/replace.

Re: Mono anyone?

Posted: Fri May 13, 2011 5:23 pm
by jsprute
Yeah, sure, at some point. Whenever I can afford a mac... and the EDI. :D I hope to start on it towards the end of the year, if no one beats me to it.

Re: Mono anyone?

Posted: Mon Jul 11, 2011 9:38 am
by tksuoran
Norbo wrote:If you decide to do it, I'll appreciate it :) I've wanted to do it for a while, but haven't had the time.

It shouldn't be too horrible- the main dependency is just on some simple XNA math types, like bounding shapes and Vector3/Matrix/Quaternion. Switching out the reference for an equivalent library should do the trick with a few using statement modifications. The TriangleMesh.GetVerticesAndIndicesFromModel convenience method has some additional dependencies, but it's not too hard to work around/replace.
I managed to build BEPUphysics without XNA by making a "MiniXNA" assembly with classes from MonoXNA: http://code.google.com/p/monoxna/source ... .Framework

There was only one function that was not implemented, Vector3.Transform() with Quaternion. Implementation for this can be found from OpenTK. Then, a couple of methods from BEPUphysics need to be disabled as XNA model classes are missing. This does not remove any important functionality when not using XNA in the first place. With these mods I was able to run my OpenTK physics application with BEPU.

The results however were not quite as good as I had hoped, as there is room for improvement with collisions. I am not sure if using MonoXNA math classes could be causing some of the issues. I guess that is quite possible.

Re: Mono anyone?

Posted: Mon Jul 11, 2011 5:33 pm
by Norbo
Thanks for trying it out! Hopefully those issues are just caused by something simple in the supporting libraries.

Re: Mono anyone?

Posted: Tue Aug 02, 2011 10:54 pm
by Alic
Not sure how relevant this is, since I've never tried porting an XNA game myself, but have you guys seen this?

http://andrewrussell.net/exen/

Basically, it's a developer tool meant to make ports from XNA to iPhone/Silverlight/ and eventually Android as painless as possible. Apparently the iPhone and Silverlight port tools are working great right now -- people are already finishing ports.

Re: Mono anyone?

Posted: Tue Aug 02, 2011 11:28 pm
by Norbo
I did see that back when he was doing the first round of crowd funding, though it's good to see it's made progress. If someone wanted to play around with it, maybe... try to make a fork (http://bepuphysics.codeplex.com/SourceControl/network) for another platform, I'd appreciate it :)

I assume there would be some complications in the BEPUphysicsDemos/Drawer project, but the core library itself should be portable without too much of a problem.

Re: Mono anyone?

Posted: Sun Sep 04, 2011 2:18 am
by Norbo
Well, I went ahead and created a version of the library which does not rely on XNA or SlimDX. It is still pretty raw, but it runs. Over the next few days I'll be fixing a few more bugs and filling out the xml documentation. The fork can be found here: http://bepuphysics.codeplex.com/SourceC ... ndencyFree

Re: Mono anyone?

Posted: Tue Sep 06, 2011 5:26 pm
by Deimos
Well, I went ahead and created a version of the library which does not rely on XNA or SlimDX.
Will the SlimDX fork still be maintained regularly and receive fixes from the main dev fork or is it advisable to switch over to the DependencyFree fork now? I'm curious because the SlimDX fork is the only one which has not received any updates in 3 weeks while the others have.

Re: Mono anyone?

Posted: Tue Sep 06, 2011 5:45 pm
by Norbo
I don't plan to regularly update any secondary fork for in-development changes. The regular schedule will be to keep all secondary forks at the same level as the primary stable release. The development fork will be the only one moving forward between stable versions. Additionally, the updates to the secondary forks may take a day or two after the primary project is updated.

The dependency free version has been getting more updates because some things needed to be fixed and it was convenient to pull in a couple of changes from the development fork.

Re: Mono anyone?

Posted: Sun Sep 11, 2011 6:35 pm
by Deimos
Thanks for the Info :) Btw the BEPUphysicsDemos project of the SlimDX fork has stil XNA references and cant be opened without an XNA SDK installation.

Re: Mono anyone?

Posted: Sun Sep 11, 2011 8:44 pm
by Norbo
Btw the BEPUphysicsDemos project of the SlimDX fork has stil XNA references and cant be opened without an XNA SDK installation.
Yup; I don't intend to create non-XNA versions of the demos project. The actual simulation setup code doesn't require any dependencies, but the renderer does. The demos project is just to verify that the forked engine is running properly.

Though if someone else wants to set up a non-XNA debug renderer and demos, I'd appreciate it :)