简体   繁体   中英

C++ vs Java in Android

I'm interesting in start a game development. I currently did some openGL in C++, but now I'm looking for the options that offers Android, and I have found people who developes his games using Native code (C++) and others that use Java...

So I don't really know which is the main difference. I read that many people has experience using C++ and prefers this one to don't have to learn new things using java... but I don't think this is the main reason.

What are the main differences developing a game using C++ or Java? Perfomance? Scalability? Posibilities?

Also, do you recommend to start the game development using OpenGL?

I would suggest using whichever language you are more comfortable with. A game is never a small project, and since you are new to the process (judging by this question) you will probably not be concerned with any performance differences or anything like that.

To answer your questions:

Performance

see C++ vs Java Performance , Android: Java, C or C++? , etc.

Possibilities

There is nothing inherit that C++ can do and Java can't, or vice versa when it comes to your goal.

Scalability

Not sure what you are asking with this one.

C++ can perform better than Java (don't believe the naysayers, do your own benchmarks), but there is more support for Java on Android. In the end it depends on how intensive your app is going to be and how much battery it is going to drain. If it is extremely intensive, go with C++ because you can do more with less. If it doesn't matter, then go with Java.

at the end it doesn't matter sense if you use c++ you will need to learn all those frameworks used for android development, if you use java you will learn java and openGL is the same in all languages so just go with c++ if you are a c++ developer

Also, do you recommend to start the game development using OpenGL?

you should not start with OpenGL not that you can't but I would sagest something like SFML witch will teach you a lot about graphics programming then you can move to OpenGL

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM