Questions tagged [ndk]
The ndk tag has no usage guidance.
21 questions
1
vote
1
answer
107
views
Cannot find game library when trying to port game to android
I've been working on a project of mine(a game with SDL3 + OpenGL ES 3.2), and as of right now I want to port it to android with android NDK, I compile my game as a library(compiles and links correctly,...
0
votes
0
answers
44
views
NDK opengl-es unknown error
Projection matrix? Renderer? Where is the error?
I recently started studying NDK to create better performing android games ... but ... An error I didn't expect to deal with appeared a few weeks ago
...
5
votes
2
answers
2k
views
How to preserve EGL context when pausing Android ndk app
I am trying to improve openframeworks so that the GL context is preserved when pausing and resuming my game. So that I don't have to reload all textures after each pause. I don't expect you to know ...
3
votes
1
answer
11k
views
How to get asset folder path in android native activity?
I am trying to create a small game with android native activity. I wish to load textures using stb image. I don't know how to get the path to assets folder.
Is there any API to get path to apk ...
1
vote
0
answers
68
views
Why can't I use C routines to load files in Android NDK?
I have successfully rendered a triangle with a hard coded shader using NativeActivity of Android NDK. Now I have the requirement to load a shader file. I tried to ...
0
votes
0
answers
127
views
How can I use the NDK to make games?
I want to use NDK to use my existing C++ code for a game. I know there are two ways to use NDK:
I can use Java to create GLSurface and opengl context;
I can use NativeActivity class to entirely write ...
1
vote
1
answer
174
views
Texture does not fit the screen
Hi guys I am really new in OpenGL-ES and I am developing a simple android application with NDK, and I just want to ask why the image is not fit after I set the width and height of it.
this is my <...
0
votes
1
answer
73
views
If someone is using JNI then are they are true user of NDK (c++)?
As someone involved in the hiring of engineers that must have experience using NDK (I work for Unity and support the VR/graphics groups), I see quite a few resumes of people who claim to be using NDK ...
1
vote
1
answer
524
views
How to implement glDrawElementsBaseVertex in OpenGL ES 3.0
I want to convert simple OpenGL project to Android native using OpenGL ES3.0, one of the functions which is not implemented is glDrawElementsBaseVertex, I have one ...
1
vote
1
answer
349
views
Many OpenGL declarations are not occured in GLESv3 gl3.h
I created a small OpenGL renderer in C++ and I want to move to Android so I prepared eclipse with all suitable platforms and create a Native Activity project then add the NDK to the includes and ...
2
votes
1
answer
2k
views
Android with SDL2
How to link native code (it has SDL_CreateWindow) with Java application code? In my case, there libSDL2.so, also my .so library ...
0
votes
1
answer
2k
views
OBJ Model not being rendered properly in OpenGL ES 2 android app
I have an Android OpenGL ES 2 app that loads an .OBJ model using Assimp and renders the same.
The vertices data is stored in a object declared like this :
...
0
votes
1
answer
377
views
glGetActiveAttrib on Android NDK
In my code-base I need to link the vertex declarations from a mesh to the attributes of a shader. To do this I retrieve all the attribute names after linking the shader. I use the following code (with ...
1
vote
1
answer
425
views
Error compiling irrlicht android using ndk in Mac
I'm new to irrlicht and I have started with irrlicht android port. I have made the following changes to android.mk file:
...
3
votes
1
answer
4k
views
Android ndk-build can't find glm headers
I am trying to port some boilerplate code of mine to work on android, using the android ndk & NativeActivity
So far I have just one file that defines the glue between android and my code and it ...
1
vote
3
answers
1k
views
Are native code obfuscations needed to prevent piracy of Android games?
Is the copyright protection and enforcement of Android apps written in Java sufficient or should I be relying on a native implementation to use machine code obfuscating techniques in order to prevent ...
1
vote
1
answer
305
views
Is there a way to setup an Android game project with a large assets during development to allow for fast testing/iteration?
I'm working on an Android port of an iOS game at the moment. I am using the Android NDK only (android_native_app_glue) in Eclipse (CDT + ADT). I am using the Android emulator, API 15 (but we are ...
0
votes
2
answers
3k
views
Android NDK - moving .so files from one project to another
I have a small project I've coded for Android that uses a small about of NDK/JNI code. I'd like to share this code between two projects but I'm having little luck so far. First off, I've tried to ...
1
vote
1
answer
1k
views
Android : Some textures not loading after resuming twice
This is an odd one. When I press home and then restart my game I reload all my textures (checking glIsTexture on the id's first). If I do this once, all textures load as expected, but if I do it ...
1
vote
1
answer
2k
views
Passing an OpenGL texture ID loaded in NDK back to java
Is it possible to load a texture using the NDK, but pass the result back to use in java.
I have used the code in the link above and it appears to load the png correctly and generates a texture ID ...
9
votes
6
answers
8k
views
How can I refer to Android assets in other directories?
My project was initially not meant for Android, and its assets are organised along the following directory structure (I hope the ASCII art renders reasonably well):
...