Android build quick start guide

Discussion of issues specific to mobile platforms such as iOS, Android, Symbian and Meego.
Post Reply
HoneyBunchesOfOats
Gnoblar
Posts: 9
Joined: Thu Mar 25, 2010 9:04 am

Re: Android build quick start guide

Post by HoneyBunchesOfOats »

Yati wrote:Hi,

I'm having the same problem as luis: could not find toolchain file - ..\cmake\toolchain\android.toolchain.cmake

But unlike luis I get it for both step 6 & 7. And I actually can't find android.toolchain.cmake on my machine, does it come with NDK r8c?

thanks!
It should be in the cmake folder at the base of your ogre src directory.
User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 99
Contact:

Re: Android build quick start guide

Post by Wolfmanfx »

I am sure you do not switched the branch to 1.9!
Yati
Greenskin
Posts: 115
Joined: Thu Jun 09, 2011 5:41 am
Location: Melbourne, Australia
x 5

Re: Android build quick start guide

Post by Yati »

Wolfmanfx wrote:I am sure you do not switched the branch to 1.9!
>_< now I'm embarrassed.

But I ran into another problem, when in step 6:

Code: Select all

CMake Error at CMake/toolchain/android.toolchain.cmake:486 (message):
  Could not any working toolchain in the NDK.  Probably your Android NDK is
  broken.
I'm not sure what this means exactly.
HoneyBunchesOfOats
Gnoblar
Posts: 9
Joined: Thu Mar 25, 2010 9:04 am

Re: Android build quick start guide

Post by HoneyBunchesOfOats »

Check out a copy from bitbucket. Make sure you're checking out the version 1.9 src. Right click and update to 1.9 just to be sure.
Yati
Greenskin
Posts: 115
Joined: Thu Jun 09, 2011 5:41 am
Location: Melbourne, Australia
x 5

Re: Android build quick start guide

Post by Yati »

I updated to 1-9, I looked in the ChangeLog and found this; v1.8.1 [Byatis] (02 September 2012) - MAINTENANCE RELEASE. But I definitely updated to 1-9. Is there a file in there which has the version number?


Anyway, this is what I see in visual studio command promt when trying to get past step 6:

Code: Select all

c:\OgreSDK\ogre_src_v1-9\AndroidDeps>cmake -G"NMake Makefiles" -DCMAKE_TOOLCHAIN
_FILE=..\cmake\toolchain\android.toolchain.cmake -DANDROID_ABI=armeabi ..
CMake Error at CMake/toolchain/android.toolchain.cmake:493 (message):
  Could not any working toolchain in the NDK.  Probably your Android NDK is
  broken.
Call Stack (most recent call first):
  C:/Program Files/CMake 2.8/share/cmake-2.8/Modules/CMakeDetermineSystem.cmake:
86 (INCLUDE)
  CMakeLists.txt:44 (project)


CMake Error: Error required internal CMake variable not set, cmake may be not be
 built correctly.
Missing variable is:
CMAKE_C_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be
 built correctly.
Missing variable is:
CMAKE_C_COMPILER
CMake Error: Could not find cmake module file:C:/OgreSDK/ogre_src_v1-9/AndroidDe
ps/CMakeFiles/CMakeCCompiler.cmake
CMake Error: Error required internal CMake variable not set, cmake may be not be
 built correctly.
Missing variable is:
CMAKE_CXX_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be
 built correctly.
Missing variable is:
CMAKE_CXX_COMPILER
CMake Error: Could not find cmake module file:C:/OgreSDK/ogre_src_v1-9/AndroidDe
ps/CMakeFiles/CMakeCXXCompiler.cmake
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
dudeabot
Gnome
Posts: 334
Joined: Thu Jun 28, 2007 2:12 pm
Location: Brazil
x 5
Contact:

Re: Android build quick start guide

Post by dudeabot »

huh

i think you have to clone the caphalor deps...

but u can downloaded the precompiled binaries that wolfcoder posted (they run fine with ndkr8c), no need to compile that unless you want
FeetyScent
Gnoblar
Posts: 1
Joined: Fri Dec 21, 2012 5:51 pm

Re: Android build quick start guide

Post by FeetyScent »

Hi,

I'm looking into Ogre for use as a cross platform engine for a new project I'm working on. We have sucessfully built and launched the sample project for iOS, however, I'm having some trouble getting Ogre working for Android. The build process seems to be fine as far as I can tell. However, when I try to launch the OgreSampleBrowser it crashes with this error:

Code: Select all

E/AndroidRuntime( 1236): java.lang.RuntimeException: Unable to start activity ComponentInfo{org.ogre3d.browser/android.app.NativeActivity}: java.lang.IllegalArgumentException: Unable to find native library: OgreSampleBrowser
I got these error when I ran nmake:

Code: Select all

No project name specified, using Activity name 'NativeActivity'.
If you wish to change it, edit the first line of build.xml.
Added file C:\Users\Paul\ogre\buildDir\SampleBrowserNDK\build.xml
Added file C:\Users\Paul\ogre\buildDir\SampleBrowserNDK\proguard-project.txt
make: *** No rule to make target `C:/Users/Paul/ogre/Samples/Browser/src/FileSys
temLayerImpl_Android.cpp', needed by `obj/local/armeabi-v7a/objs/OgreSampleBrows
er/FileSystemLayerImpl_Android.o'.  Stop.
NMAKE : fatal error U1077: 'C:\Users\Paul\android-ndk-r8c\ndk-build.CMD' : retur
n code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 10.0
\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 10.0
\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
When I look inside the NativeActivity-debug.apk, it only contains 'assets, 'META-INF', 'res' directories, and the 'resources.arsc' and 'AndroidManifest.xml' files. Is this correct?
I had the same problem building for both PC and Mac.
I followed the steps on the android quick start guide.
http://www.ogre3d.org/tikiwiki/CMake%20 ... on=Android
And I followed the steps decribed by haydenli in this thread
http://www.ogre3d.org/forums/viewtopic. ... &start=100
I'm using branch 1.9 (rev 4117)
android-ndk-r8c
CMake 2.8
ant 1.8.4
Visual Studios Express 2010

Any assistance would be appreciated.
Padres
Gnoblar
Posts: 17
Joined: Mon Oct 17, 2011 8:54 am
x 2

Re: Android build quick start guide

Post by Padres »

Hi all,

I have one small problem building ogre-android: when doing last step (compiling ogre with cmake) the dependencies are not found. I tried rebuilding dependencies instead of using precompiled, but with no luck. The dependencies are in the right directory, but still the cmake is not able to find them. The only dependency that it is able to find is libz (but it is already part of android-ndk). All other, like freetype and so, are not found anything I do. But they are there! There is a directory and everything set like in wiki :)

Has anyone experienced this problem?

I'm running on Windows 7 64bit, Ogre 1.9, NDK r8c, (VS 2010 command prompt).

Thans

PS: at first I solved one cmake problem by updating the android.toolchain.cmake to the latest version (the one in ogre mercurial caused some errors)
User avatar
Mikachu
Gnoll
Posts: 603
Joined: Thu Jul 28, 2005 4:11 pm
Location: Nice, France
x 35

Re: Android build quick start guide

Post by Mikachu »

Hi,
I followed this guide, trying to build Ogre 1.9 (latest revision) with VS2012 express.
It failed with the following message :

Code: Select all

[  1%] Building CXX object OgreMain/CMakeFiles/OgreMain.dir/src/OgreProgressiveM
esh.cpp.o
..\..\OgreMain\src\OgreProgressiveMesh.cpp:75:3: error: 'auto_ptr' in namespace
'std' does not name a type
..\..\OgreMain\src\OgreProgressiveMesh.cpp: In constructor 'Ogre::VertexDataVari
ant::VertexDataVariant(const Ogre::VertexData*, const Ogre::VertexElement*, Ogre
::VertexDataVariant*)':
..\..\OgreMain\src\OgreProgressiveMesh.cpp:95:6: error: 'mLockGuard' was not dec
lared in this scope
..\..\OgreMain\src\OgreProgressiveMesh.cpp:100:60: error: 'class Ogre::VertexDat
aVariant' has no member named 'mLockGuard'
..\..\OgreMain\src\OgreProgressiveMesh.cpp: At global scope:
..\..\OgreMain\src\OgreProgressiveMesh.cpp:172:3: error: 'auto_ptr' in namespace
 'std' does not name a type
..\..\OgreMain\src\OgreProgressiveMesh.cpp: In constructor 'Ogre::IndexDataVaria
nt::IndexDataVariant(const Ogre::IndexData*, Ogre::HardwareBuffer::LockOptions)'
:
..\..\OgreMain\src\OgreProgressiveMesh.cpp:193:4: error: 'mLockGuard' was not de
clared in this scope
..\..\OgreMain\src\OgreProgressiveMesh.cpp: In static member function 'static in
t Ogre::ProgressiveMesh::cmpByCost(const void*, const void*)':
..\..\OgreMain\src\OgreProgressiveMesh.cpp:1466:30: warning: cast from type 'con
st void*' to type 'Ogre::ProgressiveMesh::CostIndexPair* {aka std::pair<float, u
nsigned int>*}' casts away qualifiers [-Wcast-qual]
..\..\OgreMain\src\OgreProgressiveMesh.cpp:1467:30: warning: cast from type 'con
st void*' to type 'Ogre::ProgressiveMesh::CostIndexPair* {aka std::pair<float, u
nsigned int>*}' casts away qualifiers [-Wcast-qual]
NMAKE : fatal error U1077: 'C:\Prog\Libs\android-ndk-r8d\toolchains\arm-linux-an
droideabi-4.7\prebuilt\windows\bin\arm-linux-androideabi-g++.exe' : code retour
'0x1'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 11.0
\VC\BIN\nmake.exe"' : code retour '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 11.0
\VC\BIN\nmake.exe"' : code retour '0x2'
Stop.
Maybe it's because of an auto_ptr deprecation with c++11?

But I don't get any error when building Ogre from IDE (normal build, not android build).

What's the specific matter with android that makes it fail?
OgreProcedural - Procedural Geometry for Ogre3D
User avatar
Mikachu
Gnoll
Posts: 603
Joined: Thu Jul 28, 2005 4:11 pm
Location: Nice, France
x 35

Re: Android build quick start guide

Post by Mikachu »

I tried to narrow down the cause of the problem...
A classic nmake Ogre build (no android) doesn't have the problem.

Anyway, it seems to be easy to fix : just add the following line to OgreProgressiveMesh.cpp :

Code: Select all

#include <memory>
I'll issue a pull request for that..
OgreProcedural - Procedural Geometry for Ogre3D
User avatar
Mikachu
Gnoll
Posts: 603
Joined: Thu Jul 28, 2005 4:11 pm
Location: Nice, France
x 35

Re: Android build quick start guide

Post by Mikachu »

FeetyScent wrote: I got these error when I ran nmake:

Code: Select all

No project name specified, using Activity name 'NativeActivity'.
If you wish to change it, edit the first line of build.xml.
Added file C:\Users\Paul\ogre\buildDir\SampleBrowserNDK\build.xml
Added file C:\Users\Paul\ogre\buildDir\SampleBrowserNDK\proguard-project.txt
make: *** No rule to make target `C:/Users/Paul/ogre/Samples/Browser/src/FileSys
temLayerImpl_Android.cpp', needed by `obj/local/armeabi-v7a/objs/OgreSampleBrows
er/FileSystemLayerImpl_Android.o'.  Stop.
NMAKE : fatal error U1077: 'C:\Users\Paul\android-ndk-r8c\ndk-build.CMD' : retur
n code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 10.0
\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 10.0
\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
I experienced the same problem with branch v1-9.

I think I managed to fix the bug, the pull request is here : https://bitbucket.org/sinbad/ogre/pull-request/47
OgreProcedural - Procedural Geometry for Ogre3D
ma12155506
Gnoblar
Posts: 2
Joined: Thu Jan 10, 2013 9:06 am

Re: Android build quick start guide

Post by ma12155506 »

My English is not very good, and in accordance with this tutorial, I encountered a problem. I try to use this tutorial but I not find AndroidDependencies1.9\ cmake \ android.toolchain.cmake but I find the Android Dependencies and find the \ cmake \ android.toolchain.cmake but behind me is not found in OGRE CMake \ toolchain \ android.toolchain.cmake so I copied OGRE \ Dependencies \ cmake \ android.toolchain.cmak OGRE \ cmake \ android.toolchain.cmake but I get the following error compile. How can I do :(

Code: Select all

J:\TDDOWNLOAD\ogre_src_v1-8-1\build>cmake -G"NMake Makefiles" -DCMAKE_TOOLCHAIN
FILE=..\cmake\toolchain\android.toolchain.cmake -DOGRE_DEPENDENCIES_DIR=..\Andr
idDependencies -DANDROID_ABI=armeabi -DANDROID_NATIVE_API_LEVEL=9 ..
-- Configuring OGRE 1.8.1
-- Detected g++ 4.6

-- Enabling GCC visibility flags
-- Search path: J:/TDDOWNLOAD/ogre_src_v1-8-1/AndroidDependencies;J:/TDDOWNLOAD
ogre_src_v1-8-1/build/Dependencies;J:/TDDOWNLOAD/ogre_src_v1-8-1/Dependencies;J
/TDDOWNLOAD/ogre_src_v1-8-1/build/../Dependencies;J:/TDDOWNLOAD/ogre_src_v1-8-1
../Dependencies
-- Looking for ZLIB...
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Found ZLIB: optimized;zlib;debug;zlib
-- Looking for ZZip...
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Found ZZip: optimized;zziplib;debug;zziplib
-- Looking for FreeImage...
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Found FreeImage: optimized;FreeImage;debug;FreeImage
-- Looking for FREETYPE...
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- CMAKE_PREFIX_PATH: J:/TDDOWNLOAD/ogre_src_v1-8-1/AndroidDependencies;J:/TDDO
NLOAD/ogre_src_v1-8-1/build/Dependencies;J:/TDDOWNLOAD/ogre_src_v1-8-1/Dependen
ies;J:/TDDOWNLOAD/ogre_src_v1-8-1/build/../Dependencies;J:/TDDOWNLOAD/ogre_src_
1-8-1/../Dependencies;/usr/local;/usr/lib/armv5te-linux-gnu
-- CMAKE_PREFIX_PATH: J:/TDDOWNLOAD/ogre_src_v1-8-1/AndroidDependencies;J:/TDDO
NLOAD/ogre_src_v1-8-1/build/Dependencies;J:/TDDOWNLOAD/ogre_src_v1-8-1/Dependen
ies;J:/TDDOWNLOAD/ogre_src_v1-8-1/build/../Dependencies;J:/TDDOWNLOAD/ogre_src_
1-8-1/../Dependencies;/usr/local;/usr/lib/armv5te-linux-gnu
-- Found FREETYPE: optimized;freetype;debug;freetype
-- Could NOT find OpenGL (missing:  OPENGL_gl_LIBRARY)
-- Looking for Cg...
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Could not locate Cg
-- Looking for POCO...
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Could not locate POCO
-- Looking for TBB...
-- Could not locate TBB
-- Looking for GLSL_Optimizer...
-- GLSL_Optimizer_PREFIX_PATH changed.
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Could not locate GLSL_Optimizer
-- Looking for HLSL2GLSL...
-- HLSL2GLSL_PREFIX_PATH changed.
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Could not locate HLSL2GLSL
-- Looking for OIS...
-- OIS_PREFIX_PATH changed.
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Could not locate OIS
-- Could NOT find Doxygen (missing:  DOXYGEN_EXECUTABLE)
-- Looking for Softimage...
-- Could not locate Softimage
-- Looking for CppUnit...
-- Could NOT find PkgConfig (missing:  PKG_CONFIG_EXECUTABLE)
-- Could not locate CppUnit
CMake Error at CMake/Utils/MacroLogFeature.cmake:100 (MESSAGE):



  -----------------------------------------------------------------------------


  -- The following REQUIRED packages could NOT be located on your system.

  -- Please install them before continuing this software installation.

  -- If you are in Windows, try passing -DOGRE_DEPENDENCIES_DIR=<path to
  dependencies>


  -----------------------------------------------------------------------------


  + X11: X Window system <http://www.x.org>

  + Xt: X Toolkit <http://www.x.org>

  + Xaw: X11 Athena widget set <http://www.x.org>


  -----------------------------------------------------------------------------
Call Stack (most recent call first):
  CMake/Dependencies.cmake:234 (MACRO_DISPLAY_FEATURE_LOG)
  CMakeLists.txt:194 (include)


-- Configuring incomplete, errors occurred!

J:\TDDOWNLOAD\ogre_src_v1-8-1\build>
ultirock
Gnoblar
Posts: 6
Joined: Fri Feb 01, 2013 5:33 pm

Re: Android build quick start guide

Post by ultirock »

Hi,

I have a problem using ogre-android built on Linux. I used the quick start and managed to build ogre for android. However, I only get a black screen for SampleBrowser. It seems that I have a problem with OpenGL ES 2.x Renderer.

Here is my log

Code: Select all

02-01 16:15:26.690: D/dalvikvm(763): Not late-enabling CheckJNI (already on)
02-01 16:15:27.000: E/Trace(763): error opening trace file: No such file or directory (2)
02-01 16:15:27.000: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.000: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.000: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.419: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.419: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.589: I/OGRE(763): Creating resource group General
02-01 16:15:27.589: I/OGRE(763): Creating resource group Internal
02-01 16:15:27.589: I/OGRE(763): Creating resource group Autodetect
02-01 16:15:27.599: I/OGRE(763): SceneManagerFactory for type 'DefaultSceneManager' registered.
02-01 16:15:27.609: I/OGRE(763): Registering ResourceManager for type Material
02-01 16:15:27.609: I/OGRE(763): Registering ResourceManager for type Mesh
02-01 16:15:27.619: I/OGRE(763): Registering ResourceManager for type Skeleton
02-01 16:15:27.619: I/OGRE(763): MovableObjectFactory for type 'ParticleSystem' registered.
02-01 16:15:27.619: I/OGRE(763): ArchiveFactory for archive type FileSystem registered.
02-01 16:15:27.619: I/OGRE(763): ArchiveFactory for archive type Zip registered.
02-01 16:15:27.619: I/OGRE(763): ArchiveFactory for archive type EmbeddedZip registered.
02-01 16:15:27.619: I/OGRE(763): DDS codec registering
02-01 16:15:27.629: I/OGRE(763): PVRTC codec registering
02-01 16:15:27.629: I/OGRE(763): ETC1 codec registering
02-01 16:15:27.629: I/OGRE(763): Registering ResourceManager for type HighLevelGpuProgram
02-01 16:15:27.629: I/OGRE(763): Registering ResourceManager for type Compositor
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'Entity' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'Light' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'BillboardSet' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'ManualObject' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'BillboardChain' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'RibbonTrail' registered.
02-01 16:15:27.659: E/OGRE(763): OGRE EXCEPTION(6:FileNotFoundException): 'plugins.cfg' file not found! in ConfigFile::load at /home/chris/ogre_1.9/sinbad-ogre-e0f9072928ad/OgreMain/src/OgreConfigFile.cpp (line 88)
02-01 16:15:27.669: I/OGRE(763): plugins.cfg not found, automatic plugin loading disabled.
02-01 16:15:27.669: I/OGRE(763): *-*-* OGRE Initialising
02-01 16:15:27.669: I/OGRE(763): *-*-* Version 1.9.0unstable (Ghadamon)
02-01 16:15:27.669: I/OGRE(763): Installing plugin: OpenGL ES 2.0 RenderSystem
02-01 16:15:27.669: I/OGRE(763): OpenGL ES 2.x Rendering Subsystem created.
02-01 16:15:27.679: D/libEGL(763): loaded /system/lib/egl/libEGL_emulation.so
02-01 16:15:27.690: D/(763): HostConnection::get() New Host Connection established 0x2a1631e0, tid 779
02-01 16:15:27.690: D/libEGL(763): loaded /system/lib/egl/libGLESv1_CM_emulation.so
02-01 16:15:27.700: D/libEGL(763): loaded /system/lib/egl/libGLESv2_emulation.so
02-01 16:15:27.720: I/OGRE(763): Plugin successfully installed
02-01 16:15:27.720: I/OGRE(763): Installing plugin: Octree Scene Manager
02-01 16:15:27.720: I/OGRE(763): Plugin successfully installed
02-01 16:15:27.720: I/OGRE(763): Installing plugin: ParticleFX
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Point' registered
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Box' registered
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Ellipsoid' registered
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Cylinder' registered
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Ring' registered
02-01 16:15:27.730: I/OGRE(763): Particle Emitter Type 'HollowEllipsoid' registered
02-01 16:15:27.730: I/OGRE(763): Particle Affector Type 'LinearForce' registered
02-01 16:15:27.730: I/OGRE(763): Particle Affector Type 'ColourFader' registered
02-01 16:15:27.730: I/OGRE(763): Particle Affector Type 'ColourFader2' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'ColourImage' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'ColourInterpolator' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'Scaler' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'Rotator' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'DirectionRandomiser' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'DeflectorPlane' registered
02-01 16:15:27.740: I/OGRE(763): Plugin successfully installed
02-01 16:15:27.750: I/OGRE(763): CPU Identifier & Features
02-01 16:15:27.750: I/OGRE(763): -------------------------
02-01 16:15:27.750: I/OGRE(763):  *   CPU ID: ARMv7
02-01 16:15:27.750: I/OGRE(763):  *      VFP: yes
02-01 16:15:27.750: I/OGRE(763):  *     NEON: yes
02-01 16:15:27.750: I/OGRE(763): -------------------------
02-01 16:15:27.760: I/OGRE(763): Registering ResourceManager for type Texture
02-01 16:15:27.810: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.810: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.810: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.820: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.880: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.880: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.890: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.920: I/OGRE(763): GLES2RenderSystem::_createRenderWindow "OgreWindow", 0x0 windowed  miscParams: androidConfig=706121192 externalWindowHandle=706457240 
02-01 16:15:27.920: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.920: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.920: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.930: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.950: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.950: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.960: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.980: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:28.070: I/OGRE(763): GL_VERSION = OpenGL ES 2.0 (3.0 Mesa 9.0)
02-01 16:15:28.080: I/OGRE(763): GL_VENDOR = Google (X.Org)
02-01 16:15:28.080: I/OGRE(763): GL_RENDERER = Android Emulator OpenGL ES Translator (Gallium 0.4 on AMD CEDAR)
02-01 16:15:28.080: I/OGRE(763): GL_EXTENSIONS = GL_EXT_debug_marker GL_OES_EGL_image GL_OES_depth24 GL_OES_depth32 GL_OES_element_index_uint GL_OES_texture_float GL_OES_texture_float_linear GL_OES_compressed_paletted_texture GL_OES_compressed_ETC1_RGB8_texture GL_OES_depth_texture GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_packed_depth_stencil GL_OES_vertex_half_float 
02-01 16:15:28.099: I/OGRE(763): EXT:GL_EXT_debug_marker
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_EGL_image
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_depth24
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_depth32
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_element_index_uint
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_texture_float
02-01 16:15:28.120: I/OGRE(763): EXT:GL_OES_texture_float_linear
02-01 16:15:28.120: I/OGRE(763): EXT:GL_OES_compressed_paletted_texture
02-01 16:15:28.140: I/OGRE(763): EXT:GL_OES_compressed_ETC1_RGB8_texture
02-01 16:15:28.140: I/OGRE(763): EXT:GL_OES_depth_texture
02-01 16:15:28.150: I/OGRE(763): EXT:GL_OES_texture_half_float
02-01 16:15:28.150: I/OGRE(763): EXT:GL_OES_texture_half_float_linear
02-01 16:15:28.170: I/OGRE(763): EXT:GL_OES_packed_depth_stencil
02-01 16:15:28.170: I/OGRE(763): EXT:GL_OES_vertex_half_float
02-01 16:15:28.180: I/OGRE(763): **************************************
02-01 16:15:28.180: I/OGRE(763): *** OpenGL ES 2.x Renderer Started ***
02-01 16:15:28.180: I/OGRE(763): **************************************
02-01 16:15:28.199: A/libc(763): Fatal signal 11 (SIGSEGV) at 0xdeadbaad (code=1), thread 779 (.ogre3d.browser)
I built it on Linux Mint 14, used ogre branch v1-9, NDK r8d.

Do you have any ideas what is wrong?

Thank you in advance
Emerich
Halfling
Posts: 64
Joined: Wed Oct 24, 2012 10:59 am
x 12

Re: Android build quick start guide

Post by Emerich »

I finally got the sample browser compiled. Sadly it doesn't run but I'll try to debug that later.

Is there a way to get my own project which relies on ogre (uses the lib and stuff) to run on Android?

So far I just have a VS2010 project with my stuff set up and I was wondering how I would go about porting that to Android.
Help would be really appreciated =D
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: Android build quick start guide

Post by xavier »

ultirock wrote:Hi,

I have a problem using ogre-android built on Linux. I used the quick start and managed to build ogre for android. However, I only get a black screen for SampleBrowser. It seems that I have a problem with OpenGL ES 2.x Renderer.

Here is my log

Code: Select all

02-01 16:15:26.690: D/dalvikvm(763): Not late-enabling CheckJNI (already on)
02-01 16:15:27.000: E/Trace(763): error opening trace file: No such file or directory (2)
02-01 16:15:27.000: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.000: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.000: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.419: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.419: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.589: I/OGRE(763): Creating resource group General
02-01 16:15:27.589: I/OGRE(763): Creating resource group Internal
02-01 16:15:27.589: I/OGRE(763): Creating resource group Autodetect
02-01 16:15:27.599: I/OGRE(763): SceneManagerFactory for type 'DefaultSceneManager' registered.
02-01 16:15:27.609: I/OGRE(763): Registering ResourceManager for type Material
02-01 16:15:27.609: I/OGRE(763): Registering ResourceManager for type Mesh
02-01 16:15:27.619: I/OGRE(763): Registering ResourceManager for type Skeleton
02-01 16:15:27.619: I/OGRE(763): MovableObjectFactory for type 'ParticleSystem' registered.
02-01 16:15:27.619: I/OGRE(763): ArchiveFactory for archive type FileSystem registered.
02-01 16:15:27.619: I/OGRE(763): ArchiveFactory for archive type Zip registered.
02-01 16:15:27.619: I/OGRE(763): ArchiveFactory for archive type EmbeddedZip registered.
02-01 16:15:27.619: I/OGRE(763): DDS codec registering
02-01 16:15:27.629: I/OGRE(763): PVRTC codec registering
02-01 16:15:27.629: I/OGRE(763): ETC1 codec registering
02-01 16:15:27.629: I/OGRE(763): Registering ResourceManager for type HighLevelGpuProgram
02-01 16:15:27.629: I/OGRE(763): Registering ResourceManager for type Compositor
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'Entity' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'Light' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'BillboardSet' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'ManualObject' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'BillboardChain' registered.
02-01 16:15:27.649: I/OGRE(763): MovableObjectFactory for type 'RibbonTrail' registered.
02-01 16:15:27.659: E/OGRE(763): OGRE EXCEPTION(6:FileNotFoundException): 'plugins.cfg' file not found! in ConfigFile::load at /home/chris/ogre_1.9/sinbad-ogre-e0f9072928ad/OgreMain/src/OgreConfigFile.cpp (line 88)
02-01 16:15:27.669: I/OGRE(763): plugins.cfg not found, automatic plugin loading disabled.
02-01 16:15:27.669: I/OGRE(763): *-*-* OGRE Initialising
02-01 16:15:27.669: I/OGRE(763): *-*-* Version 1.9.0unstable (Ghadamon)
02-01 16:15:27.669: I/OGRE(763): Installing plugin: OpenGL ES 2.0 RenderSystem
02-01 16:15:27.669: I/OGRE(763): OpenGL ES 2.x Rendering Subsystem created.
02-01 16:15:27.679: D/libEGL(763): loaded /system/lib/egl/libEGL_emulation.so
02-01 16:15:27.690: D/(763): HostConnection::get() New Host Connection established 0x2a1631e0, tid 779
02-01 16:15:27.690: D/libEGL(763): loaded /system/lib/egl/libGLESv1_CM_emulation.so
02-01 16:15:27.700: D/libEGL(763): loaded /system/lib/egl/libGLESv2_emulation.so
02-01 16:15:27.720: I/OGRE(763): Plugin successfully installed
02-01 16:15:27.720: I/OGRE(763): Installing plugin: Octree Scene Manager
02-01 16:15:27.720: I/OGRE(763): Plugin successfully installed
02-01 16:15:27.720: I/OGRE(763): Installing plugin: ParticleFX
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Point' registered
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Box' registered
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Ellipsoid' registered
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Cylinder' registered
02-01 16:15:27.720: I/OGRE(763): Particle Emitter Type 'Ring' registered
02-01 16:15:27.730: I/OGRE(763): Particle Emitter Type 'HollowEllipsoid' registered
02-01 16:15:27.730: I/OGRE(763): Particle Affector Type 'LinearForce' registered
02-01 16:15:27.730: I/OGRE(763): Particle Affector Type 'ColourFader' registered
02-01 16:15:27.730: I/OGRE(763): Particle Affector Type 'ColourFader2' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'ColourImage' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'ColourInterpolator' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'Scaler' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'Rotator' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'DirectionRandomiser' registered
02-01 16:15:27.740: I/OGRE(763): Particle Affector Type 'DeflectorPlane' registered
02-01 16:15:27.740: I/OGRE(763): Plugin successfully installed
02-01 16:15:27.750: I/OGRE(763): CPU Identifier & Features
02-01 16:15:27.750: I/OGRE(763): -------------------------
02-01 16:15:27.750: I/OGRE(763):  *   CPU ID: ARMv7
02-01 16:15:27.750: I/OGRE(763):  *      VFP: yes
02-01 16:15:27.750: I/OGRE(763):  *     NEON: yes
02-01 16:15:27.750: I/OGRE(763): -------------------------
02-01 16:15:27.760: I/OGRE(763): Registering ResourceManager for type Texture
02-01 16:15:27.810: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.810: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.810: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.820: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.880: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.880: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.890: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.920: I/OGRE(763): GLES2RenderSystem::_createRenderWindow "OgreWindow", 0x0 windowed  miscParams: androidConfig=706121192 externalWindowHandle=706457240 
02-01 16:15:27.920: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.920: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.920: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.930: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.950: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.950: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.960: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:27.980: W/Trace(763): Unexpected value from nativeGetEnabledTags: 0
02-01 16:15:28.070: I/OGRE(763): GL_VERSION = OpenGL ES 2.0 (3.0 Mesa 9.0)
02-01 16:15:28.080: I/OGRE(763): GL_VENDOR = Google (X.Org)
02-01 16:15:28.080: I/OGRE(763): GL_RENDERER = Android Emulator OpenGL ES Translator (Gallium 0.4 on AMD CEDAR)
02-01 16:15:28.080: I/OGRE(763): GL_EXTENSIONS = GL_EXT_debug_marker GL_OES_EGL_image GL_OES_depth24 GL_OES_depth32 GL_OES_element_index_uint GL_OES_texture_float GL_OES_texture_float_linear GL_OES_compressed_paletted_texture GL_OES_compressed_ETC1_RGB8_texture GL_OES_depth_texture GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_packed_depth_stencil GL_OES_vertex_half_float 
02-01 16:15:28.099: I/OGRE(763): EXT:GL_EXT_debug_marker
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_EGL_image
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_depth24
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_depth32
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_element_index_uint
02-01 16:15:28.099: I/OGRE(763): EXT:GL_OES_texture_float
02-01 16:15:28.120: I/OGRE(763): EXT:GL_OES_texture_float_linear
02-01 16:15:28.120: I/OGRE(763): EXT:GL_OES_compressed_paletted_texture
02-01 16:15:28.140: I/OGRE(763): EXT:GL_OES_compressed_ETC1_RGB8_texture
02-01 16:15:28.140: I/OGRE(763): EXT:GL_OES_depth_texture
02-01 16:15:28.150: I/OGRE(763): EXT:GL_OES_texture_half_float
02-01 16:15:28.150: I/OGRE(763): EXT:GL_OES_texture_half_float_linear
02-01 16:15:28.170: I/OGRE(763): EXT:GL_OES_packed_depth_stencil
02-01 16:15:28.170: I/OGRE(763): EXT:GL_OES_vertex_half_float
02-01 16:15:28.180: I/OGRE(763): **************************************
02-01 16:15:28.180: I/OGRE(763): *** OpenGL ES 2.x Renderer Started ***
02-01 16:15:28.180: I/OGRE(763): **************************************
02-01 16:15:28.199: A/libc(763): Fatal signal 11 (SIGSEGV) at 0xdeadbaad (code=1), thread 779 (.ogre3d.browser)
I built it on Linux Mint 14, used ogre branch v1-9, NDK r8d.

Do you have any ideas what is wrong?

Thank you in advance
Is there a reason you can't use host GPU hardware? I see that you are using Mesa/Xorg -- does the host not have a GPU in it?

I've spent the past two days at work debugging a non-Ogre application on Android, only to figure out tonight that Android's emulator is hopelessly gimped in terms of GLES2 support. The tiny list of extensions you listed above is what I see on my r8d setup (no, no glMapBuffer or glBindVertexArray for me...). In contrast, here is what I see on my Acer A510 (Tegra 3):

Code: Select all

02-20 00:56:41.394: I/libgl2jni(30102): GL Version: OpenGL ES 2.0 14.01002
02-20 00:56:41.394: I/libgl2jni(30102): GL Vendor: NVIDIA Corporation
02-20 00:56:41.394: I/libgl2jni(30102): GL Renderer: NVIDIA Tegra 3
02-20 00:56:41.394: I/libgl2jni(30102): GL Extensions:
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_rgb8_rgba8
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_EGL_sync
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_surfaceless_context
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_fbo_render_mipmap
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_depth_nonlinear
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_draw_path
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_texture_npot_2D_mipmap
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_EGL_image
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_EGL_image_external
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_vertex_half_float
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_mapbuffer
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_draw_buffers
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_multiview_draw_buffers
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_Cg_shader
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_packed_float
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_texture_half_float
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_texture_array
02-20 00:56:41.394: I/libgl2jni(30102):     GL_OES_compressed_ETC1_RGB8_texture
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_texture_compression_latc
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_texture_compression_latc
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_texture_compression_dxt1
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_texture_compression_s3tc
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_texture_compression_s3tc
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_texture_filter_anisotropic
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_get_tex_image
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_read_buffer
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_shader_framebuffer_fetch
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_copy_image
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_fbo_color_attachments
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_bgra
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_texture_format_BGRA8888
02-20 00:56:41.394: I/libgl2jni(30102):     GL_EXT_unpack_subimage
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_pack_subimage
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_texture_compression_s3tc_update
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_read_depth
02-20 00:56:41.394: I/libgl2jni(30102):     GL_NV_read_stencil
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_uniform_buffer_object
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_map_buffer_range
02-20 00:56:41.404: I/libgl2jni(30102):     GL_EXT_robustness
02-20 00:56:41.404: I/libgl2jni(30102):     GL_OES_standard_derivatives
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_EGL_stream_consumer_external
02-20 00:56:41.404: I/libgl2jni(30102):     GL_EXT_separate_shader_objects
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_copy_buffer
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_3dvision_settings
02-20 00:56:41.404: I/libgl2jni(30102):     GL_EXT_debug_marker
02-20 00:56:41.404: I/libgl2jni(30102):     GL_EXT_debug_label
02-20 00:56:41.404: I/libgl2jni(30102):     GL_KHR_debug
02-20 00:56:41.404: I/libgl2jni(30102):     GL_EXT_texture_storage
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_pixel_buffer_object
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_framebuffer_blit
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_non_square_matrices
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_explicit_attrib_location
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_smooth_points_lines
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_coverage_sample
02-20 00:56:41.404: I/libgl2jni(30102):     GL_EXT_occlusion_query_boolean
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_occlusion_query_samples
02-20 00:56:41.404: I/libgl2jni(30102):     GL_NV_timer_query
Bit of a difference, eh? ;) (and yes, I know there are no VAO in that list either...does anyone know, is this really that tough a feature to implement?!? iOS -- 6, anyway -- has VAO just fine).

I'd be curious if anyone has had success running the samples in the emulator (any emulator) because I am considering trying to convince the rest of the team that we should end the insanity and just use a rendering solution that has encountered and addressed these issues...but if Ogre has the same problems on the emulator that I am having, it's a hard sell... ;)
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 99
Contact:

Re: Android build quick start guide

Post by Wolfmanfx »

hi xavier,

I made the gles2 rendersystem rubbibg on windows with powerVR emu running and it also lacks of these ext. but thats already addressed by our RS.
regarding android emu i did not have much luck but anyhow i try to have as many devices as possible because every driver impl. has it own problems.
woukd be great if you convice your team @intel to use ogre :) so if you need more info drop me a email.
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: Android build quick start guide

Post by xavier »

It's not actually at Intel but at a customer. As you probably know, Intel doesn't have any problems using Ogre. ;)

I may just do it on the side myself at home and see how it goes. If there are actual issues/shortcomings with the emulation layer, I might be able to get the Android team internally to help address them, at least for the x86 image (or may just fix them myself and submit patches upstream).
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
Emerich
Halfling
Posts: 64
Joined: Wed Oct 24, 2012 10:59 am
x 12

Re: Android build quick start guide

Post by Emerich »

Compiling the Ogre 1-9 branch again.
It tells me the following while i run cmake (and for some reason I have to manually call nmake with the new version. It did that on it's own before)

Code: Select all

-----------------------------------------------------------------------------
-- The following OPTIONAL packages could NOT be located on your system.
-- Consider installing them to enable more features from this software.
+ OpenGL 3+: Support for the OpenGL 3+ render system <http://www.opengl.org/>
+ boost: Boost (general) <http://boost.org>
+ boost-thread: Used for threading support <http://boost.org>
+ boost-date_time: Used for threading support <http://boost.org>
+ POCO: POCO framework <http://pocoproject.org/>
+ tbb: Threading Building Blocks <http://www.threadingbuildingblocks.org/>
+ GLSL Optimizer: GLSL Optimizer <http://github.com/aras-p/glsl-optimizer/>
+ HLSL2GLSL: HLSL2GLSL <http://hlsl2glslfork.googlecode.com/>
+ Doxygen: Tool for building API documentation <http://doxygen.org>
+ Softimage: Softimage SDK needed for building XSIExporter <FALSE>
+ CppUnit: Library for performing unit tests <http://cppunit.sourceforge.net>
-----------------------------------------------------------------------------
When I install it on a Samsung Galaxy Tab (GT-p1000) running Android 2.3.6 I get only white noise on the screen.Is that due to the optional packages missing? I am quite new to Android Ogre but the OpenGL thing looks really important.
User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 99
Contact:

Re: Android build quick start guide

Post by Wolfmanfx »

yes you have to enable the glsles optmizer than it will work - the problem is rtss related
Emerich
Halfling
Posts: 64
Joined: Wed Oct 24, 2012 10:59 am
x 12

Re: Android build quick start guide

Post by Emerich »

Wolfmanfx wrote:yes you have to enable the glsles optmizer than it will work - the problem is rtss related
Sadly, I have no clue on how to do that. I'd appreciate any hints on articles to read or something like that=)

On an unrelated note:
Do you think we can compile Ogre with NVidia NSight Tegra for Visual Studio?
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: Android build quick start guide

Post by xavier »

So the build succeeded. Now...how do I make an apk for the samples and browser? The how-to talks about grabbing Ant, but then never explains how it should be used (and no build.xml exists anywhere).
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
Emerich
Halfling
Posts: 64
Joined: Wed Oct 24, 2012 10:59 am
x 12

Re: Android build quick start guide

Post by Emerich »

xavier wrote:So the build succeeded. Now...how do I make an apk for the samples and browser? The how-to talks about grabbing Ant, but then never explains how it should be used (and no build.xml exists anywhere).
I had to do an nmake after cmake. Then I got the apk (had to search for it first) which sadly doesnt work =D
User avatar
Wolfmanfx
OGRE Team Member
OGRE Team Member
Posts: 1525
Joined: Fri Feb 03, 2006 10:37 pm
Location: Austria - Leoben
x 99
Contact:

Re: Android build quick start guide

Post by Wolfmanfx »

There is folder in the build folder called "SampleBrowserNDK" cd to it and than:
ndk-build all -j4
ant debug install

and it should deployed on your device
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: Android build quick start guide

Post by xavier »

Emerich wrote:
xavier wrote:So the build succeeded. Now...how do I make an apk for the samples and browser? The how-to talks about grabbing Ant, but then never explains how it should be used (and no build.xml exists anywhere).
I had to do an nmake after cmake. Then I got the apk (had to search for it first) which sadly doesnt work =D
Yes, did all that -- like I said, the build succeeded, but no apk:

Code: Select all

gjunker@tornado /cygdrive/f/projects/ogre/android
$ find .. -name "*.apk"
(note that the actual build was done in a VS2010 command prompt)
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
User avatar
xavier
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 9481
Joined: Fri Feb 18, 2005 2:03 am
Location: Dublin, CA, US
x 22

Re: Android build quick start guide

Post by xavier »

Wolfmanfx wrote:There is folder in the build folder called "SampleBrowserNDK" cd to it and than:
ndk-build all -j4
ant debug install

and it should deployed on your device

Thanks, but as I said, there is no build.xml present:

Code: Select all

F:\projects\ogre\android\SampleBrowserNDK>ant debug install
Unable to locate tools.jar. Expected to find it in F:\Program Files\Java\jre7\lib\tools.jar
Buildfile: build.xml does not exist!
Build failed

F:\projects\ogre\android\SampleBrowserNDK>
The native build for the browser finished fine.
Do you need help? What have you tried?

Image

Angels can fly because they take themselves lightly.
Post Reply