Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>In my understanding, the NDK simply allows you to program games (and apps if you wanted to) in C/C++ for Android. The code is compiled to Android machine code, not converted into Java in some way. It's questionable whether there's really a huge performance difference on modern phones however.</p> <p>The big advantage of the NDK that hasn't been mentioned here is that it allows you to utilize OpenGL ES 2.0 on older Android versions rather than being stuck with 1.1 if you use Java. OpenGL ES 2.0 has been included in the Java SDK in <del>Gingerbread</del> <em><strong>EDIT: Actually it's Froyo not Gingerbread, as Leif Andersen pointed out in the comments</strong></em>, but at least at the moment, <del>Gingerbread is not widely available</del> Froyo is only on about 60% of Android phones (though that will continue to grow in the next few months).</p> <p>The other huge advantage to the NDK is the ability to port iOS games (and games from some other platforms) that are written in C/C++.</p> <p>If you're fine with using OpenGL ES 1.1, or want to use 2.0 but are fine targeting <del>Gingerbread</del> Froyo and above, and you aren't doing any iOS or other platform ports, then Java is going to almost definitely be the best solution for you. That is unless you're a seasoned C/C++ programmer, then you may be more comfortable programming using the NDK.</p> <p>Also, another advantage to programming in Java is that if there are eventually x86 devices or other chips running Android, your game will still play fine. With NDK it would have to be specially compiled to run on those different chips.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload