[osg-users] Android osgPlugins

Christian Kehl christian-kehl at web.de
Thu Aug 20 12:42:21 PDT 2015


In the meanwhile, I was working further on the topic - and cracked it this time, I think. First and foremost, I use OpenSceneGraph 3.3.8 (still) and compile it for Android, while having the necessary 3rdParty-folder inside the OpenSceneGraph root folder (little suggestion: at some point this may be changed in the makefiles to search that folder by environment variable path, such as the data folder ...). I just define the GLES profile and the android platform and build it. Next:

A) For generating the PREBUILT_STATIC_LIBRARY, I took a sip from the OpenCV recipe that defines a local mk-file function that builds each 3rd Party dependency for the android package.

B) These local prebuilds are then referred to via "LOCAL_WHOLE_STATIC_LIBRARIES", which is necessary so that the ndk-build linker finds all referred functions. That's the actual behaviour I kind'a expected in any case for a STATIC library (containing all content), bust as Jan pointed out: Android NDK - you'll never know what you get :D

This way, it works for me now, as I can load osg.Image() within Android using a jpeg image, in order to texture a geometry.

Manual and code submission are still on my agenda. The appended make file is afree-for-all to try out - just take the ".txt" extension away.


Read this topic online here:

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: Android.mk.txt
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20150820/e83a8245/attachment-0003.txt>

More information about the osg-users mailing list