B
B
BelBES2014-04-01 12:57:27
Java
BelBES, 2014-04-01 12:57:27

Android NDK - how to get absolute file path from NativeActivity?

Hello!
There is such a task: my application (completely native, without Java code) has some files in the assets folder (I can basically transfer it to res / raw - this is not important) inside the APK.
I can read them as a stream of bytes through AASsetManager into a buffer, but this option does not suit me, I need to get the absolute path to the file. Nobody faced this? How can I do that?
Thanks in advance!
ps The options for how to do this through the Java part are known to me and for a number of reasons are not suitable.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
B
BelBES, 2014-04-01
@BelBES

I solved the problem as follows:
I got the absolute path to the folder with the program through android_app * app; app->activity->internalDataPath
And then all the insides of this folder can be accessed through the usual sish file I / O interfaces.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question