Hi there,
I'll need a shared library from bullet, because I'll try to create a java binding throught JNI.
The problem with this are the different c++ styles in java and bullet which would not compile in one shared library. Therefore I'll need one from bullet and one for my binding.
I'll tried to set the Jamfile rules but do not have success. As there is very little documentation on jam I'll thought I'll write here and maybe anyone could give a hint on how to do shared linking?
Shared library from bullet
-
- Posts: 40
- Joined: Fri Jan 11, 2008 8:33 am
Re: Shared library from bullet
Hi, have you seen JBullet? It's pure Java port of Bullet (not binding).
If yes and wish to have binding as well, I initially did a binding, but I didn't like to have to create multiple builds for all platforms (and testing them), wanted tighter integration with Java to use internal stuff and generally provide more Java-like library. I had no problems using JNI and Bullet in the same library (though I've tested it only on Linux). What are your problems exactly?
If yes and wish to have binding as well, I initially did a binding, but I didn't like to have to create multiple builds for all platforms (and testing them), wanted tighter integration with Java to use internal stuff and generally provide more Java-like library. I had no problems using JNI and Bullet in the same library (though I've tested it only on Linux). What are your problems exactly?
-
- Posts: 5
- Joined: Tue Jul 29, 2008 6:45 am
Re: Shared library from bullet
I have problem with linking in linux with either gcc or g++.
When choosing one then the bullet symbols are not found, if I choose the other the java symbols are not found.
I've seen JBullet and would like to use it, but I need collada support and as far as I have seen there is currently no support for it in JBullet, is it? Maybe I could contribute something to the port if you accept patches.
When choosing one then the bullet symbols are not found, if I choose the other the java symbols are not found.
I've seen JBullet and would like to use it, but I need collada support and as far as I have seen there is currently no support for it in JBullet, is it? Maybe I could contribute something to the port if you accept patches.
-
- Posts: 40
- Joined: Fri Jan 11, 2008 8:33 am
Re: Shared library from bullet
Did you use extern "C" for JNI functions?KnisterPeter wrote:I have problem with linking in linux with either gcc or g++.
When choosing one then the bullet symbols are not found, if I choose the other the java symbols are not found.
Currently no support for COLLADA has been made. Would be nice if you port it, I can help you if you encounter any problems. Personally I would look at XPP3 library (which is supposedly one of the fastest and effective XML libs out there) to see if it's applicable for the task. Looking into Bullet code I see generated classes from COLLADA schema to access COLLADA's DOM, so maybe JAXB is better choice.KnisterPeter wrote: I've seen JBullet and would like to use it, but I need collada support and as far as I have seen there is currently no support for it in JBullet, is it? Maybe I could contribute something to the port if you accept patches.
-
- Posts: 5
- Joined: Tue Jul 29, 2008 6:45 am
Re: Shared library from bullet
Yes, maybe that's the problem?Did you use extern "C" for JNI functions
I'll try to port it appropriatelly. But first I have to learn bullet.Currently no support for COLLADA has been made.
For XML parsing I would either choose JAXP since it is a std. interface, implement some sort of interface to implement for the xml parser of user choice with a default implementation (either xpp3 or jaxp).
-
- Posts: 40
- Joined: Fri Jan 11, 2008 8:33 am
Re: Shared library from bullet
No, that's how it should be. Try posting error messages you are getting.KnisterPeter wrote:Yes, maybe that's the problem?Did you use extern "C" for JNI functions
Sounds good for me, though I'm not using XML much, so I can hardly compare. From very quick overview I can't find if it provides also XMLPULL interface (or something similar) which is both good for performance and is programmer friendly (EDIT: looks like it provides it with javax.xml.stream). It doesn't matter much if you take DOM route though.KnisterPeter wrote: For XML parsing I would either choose JAXP since it is a std. interface, implement some sort of interface to implement for the xml parser of user choice with a default implementation (either xpp3 or jaxp).
Anyway, choose what you think is best for it, I've just gave some hints
-
- Posts: 5
- Joined: Tue Jul 29, 2008 6:45 am
Re: Shared library from bullet
I'll try with JBullet first. If all work well I'll don't need my binding.jezek2 wrote:No, that's how it should be. Try posting error messages you are getting.KnisterPeter wrote:Yes, maybe that's the problem?Did you use extern "C" for JNI functions
If I have something to show I'll post it here, but it will need some time.jezek2 wrote:Anyway, choose what you think is best for it, I've just gave some hints
-
- Posts: 5
- Joined: Tue Jul 29, 2008 6:45 am
Re: Shared library from bullet
Hi,
I've decided to create an interface to the 3d engine i'm using. It's way to much work to create a colada parser.
I've decided to create an interface to the 3d engine i'm using. It's way to much work to create a colada parser.