Abstract
In this chapter, you will get your feet wet with native development in Android. You learn how easy it is to build a simple Android app that loads a native library and executes methods written in C within Java. You also learn how to call back Java methods within C, so the communication goes both ways between the languages. Next you learn how to cascade audio, video, key, and touch events from Java to C by using thin Java wrappers that simply pass event information to the native library. And finally, you tackle multitouch, which is a useful subject for advanced games such as first person shooters and others. Multitouch can be a tricky subject so check it out. But first, you’ll learn how to add native code to your Android project. Let’s get started.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Rights and permissions
Copyright information
© 2012 Vladimir Silva
About this chapter
Cite this chapter
Silva, V. (2012). Gaming Tricks for Phones or Tablets. In: Pro Android Games. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4302-4798-2_2
Download citation
DOI: https://doi.org/10.1007/978-1-4302-4798-2_2
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4302-4797-5
Online ISBN: 978-1-4302-4798-2
eBook Packages: Professional and Applied ComputingProfessional and Applied Computing (R0)Apress Access Books