In school we're developing a game in java. However, since it won't be graded I've decided to use C++ for performance reasons. My other two teamates are using java.
What we want to do is integrate C++ code in java, but have never done so before. Is there anyone that can give me some advice, or perhaps a tutorial/demo to do so?
We're doing a 3D space simulation and need to process thousands of objects at once. Rather than use many clients to process objects, I figured I could use C++ to render and process everything to save the work and space problem.
Any ideas are welcome.
Thanks,
Jason
C++ and java integration
Started by gardon, Apr 05 2006 07:17 PM
6 replies to this topic
#1
Posted 05 April 2006 - 07:17 PM
#2
Posted 05 April 2006 - 10:20 PM
Interoperating C++ and Java is messy enough that for a school project it's probably easier to just do it all in one language. Java's performance isn't that bad. I'm not sure what you're referring to with "multiple clients to process objects". Don't the Java bindings for OpenGL allow you to render vertex arrays and so forth just as you could from C++?
reedbeta.com - developer blog, OpenGL demos, and other projects
#3
Posted 05 April 2006 - 10:50 PM
I'm not sure. They kind of scrapped my idea for using an API. I guess they want to use some kids engine that he made? Why i dont' know. I'm sure highly optomized and organized code will be better than some kid made in a day. But what do I know, I'm the only one that has an interest in games.
So it's 2 against one, and I have no say really. And it's in school, and IN JAVA so I could really care less. I was just trying to see if there was a way to mix the two.
And the clients thing I was talking about would be to have the program send out information to other computers (client computers) to process and send to a server, which would re-send the information back to the computer hosting the game. Stupid I know, but it wasn't my idea. That's why I recommended C++ (and an engine or API that works!)
Oh well,
jason
So it's 2 against one, and I have no say really. And it's in school, and IN JAVA so I could really care less. I was just trying to see if there was a way to mix the two.
And the clients thing I was talking about would be to have the program send out information to other computers (client computers) to process and send to a server, which would re-send the information back to the computer hosting the game. Stupid I know, but it wasn't my idea. That's why I recommended C++ (and an engine or API that works!)
Oh well,
jason
#4
Posted 05 April 2006 - 11:02 PM
Well, if you still want to see if you can get it to work, check out this page. You'll need to have Sun's Java Development Kit (JDK) installed.
reedbeta.com - developer blog, OpenGL demos, and other projects
#6
Posted 09 April 2006 - 08:02 AM
Distributed computing is very powerful!
And if you want to calculate the movement space there is certainly computation that could be distributed.
Java is NOT a glue langugae. For a glue language use something like Python or Lua.
Better use some 3D thing for Java and forget about performence of rendering. The computation of a space simulation will be great so I would focus on that.
And if you want to calculate the movement space there is certainly computation that could be distributed.
Java is NOT a glue langugae. For a glue language use something like Python or Lua.
Better use some 3D thing for Java and forget about performence of rendering. The computation of a space simulation will be great so I would focus on that.
#7
Posted 29 May 2006 - 04:20 PM
See JNI tools at:
http://www.simtel.net/product.php[id]93174[SiteID]simtel.net
http://www.simtel.net/product.php[id]94368[SiteID]simtel.net
http://www.simtel.net/product.php[id]95126[SiteID]simtel.net
:yes:
http://www.simtel.net/product.php[id]93174[SiteID]simtel.net
http://www.simtel.net/product.php[id]94368[SiteID]simtel.net
http://www.simtel.net/product.php[id]95126[SiteID]simtel.net
:yes:
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users












