Skip to content

Demonstrates how to access and write into the framebuffer directly, in Android native applications.

License

Notifications You must be signed in to change notification settings

Miouyouyou/Android-framebuffer-Direct-Example

Repository files navigation

If you appreciate this project, support me on Patreon or Liberapay !

Patreon ! Liberapay ! Tip with Altcoins

About

This project demonstrates how to access and write into a "window" framebuffer in Android.

As it stands, it just lit every line of pixel of the window with a color randomly selected in a palette of 4 colors.

The useful part of the example is inside fill_pixels.c.
android_native_app_glue.c is, as the name implies, just a way to connect Android's NativeActivity code to this native code.

Testing

If you want to test this code, you'll need :

  • An Android SDK with the right build tools (27.0.0);
  • An Android NDK (used by the Android build system to get the right compilers for each architecture);
  • An Android terminal (Phone, tablet, emulator, ...).

Then you will need to execute, from a terminal workig in this folder :

git submodule init
git submodule update
cd apk
./gradlew installDebug

About

Demonstrates how to access and write into the framebuffer directly, in Android native applications.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published