Scheduling native threads at Android NDK

This recipe discusses how to schedule native threads at Android NDK.

Getting ready...

Readers are suggested to read the Manipulating classes in JNI and Calling static and instance methods from native code recipes in Chapter 2, Java Native Interface, and Creating and terminating native threads at Android NDK recipe in this chapter.

How to do it...

The following steps will help us create an Android project that demonstrates threads scheduling at Android NDK:

  1. Create an Android application named NativeThreadsSchedule. Set the package name as cookbook.chapter6.nativethreadsschedule. Refer to the Loading native libraries and registering native methods recipe in Chapter 2, Java Native Interface for more detailed instructions. ...

Get Android Native Development Kit Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.