Well it's easy... there are some debug messages that I put them because the
obscureness and difficulties to find some error so usually the trace should
have first the message:

08-16 15:59:29.331: WARN/EGLview(4904): creating OpenGL ES 1 context

That message come from the EGL java class WHICH initializes the GLES
context. That message is in your logs. Now when you have the context
the method onSurfaceCreated is called and it's a do nothing in my
example, for more complex programs the correct initialization should
be done there and the surfaceChange have another initialization code,
because that function is called when you change possition on your
device and on other places. So they should not have the same code.

When you enter onSurfaceChanged, that's when OSG initializes
everything so NOW we have the BIG trouble. the init function goes
through a JNI bridge (init function) and calls the function
initOsgWindow of mainApp.

Inside initOsgWindow there's another LOG  that should write. It's the
FIRST instruction and it is dispatchet through __android_log_write so
that will ever show whathever happens.

"Initializing geometry"

If you don't see that Log entry then no OSG code has been used.

Then Maybe it's the same strange bug that Rafa told me once (he could
fix it for his samsung) but since 2.2 that bug dissapeared... And i
don't know e

Now you should test if the application can reach the JNI bridge, put
some __android_log_write in the osgNativeLib in the init function
after and before calling the osg function.

And about the log that's just the full heap. There are some manuals if you
want to know more to translate to code but just by looking what I've said to
you... it's a strange bug.


2011/8/17 Riccardo Corsi <riccardo.co...@kairos3d.it>

> Hi Jorge,
>
> I've set some breakpoints and stepped into the java code with the debugger.
> From the GLThread these methods are called in this order:
> - EGLView::onSurfaceCreated()
> - EGLView::onSurfaceChanged()
>
> Inside onSurfaceChanged(), when it calls the native method
> osgNativeLib.init(), it exits and thus never reaches onDrawFrame() is never
> reached.
>
> Ricky
>
> P.S. By the way... how did you get that info from the logcat? it's still
> quite obscure to me...
>
>
>
>
>
> On Wed, Aug 17, 2011 at 16:38, Jorge Izquierdo Ciges <jori...@gmail.com>wrote:
>
>> That's one hell of a error. ¡He doesn't reach the initOsgWindow function!
>>
>> I've never seen it, but I have some ideas. First it's the same error for
>> both of them. This must be some Native compatibility isue. I've heard that
>> the EglView in which the example is based has some troubles with some
>> devices but no one has said something solid about it. So, try to check by
>> debug or just Log (quicker) which methods of the EGLview.java if onDraw is
>> calle before onSurfaceChange or if onSurfaceChanged is never called we'll
>> hace to see if there has been some changes in the API that requiere a SDK
>> target version on the manifest. If not... well we'll see.
>>
>> 2011/8/17 Riccardo Corsi <riccardo.co...@kairos3d.it>
>>
>>> Hi Jorge and all,
>>>
>>> I start a new thread as I don't want to pollute the other -
>>> http://forum.openscenegraph.org/viewtopic.php?t=8917&start=17
>>> which mainly talks about building for Android.
>>>
>>> Basically the issue is that osgAndroidExampleGLES1 doesn't work when
>>> deployed to my Acer Iconia A500, running Android 3.1
>>> (while the same build works just fine on the Nexus S running Android
>>> 2.3.4)
>>>
>>> The application starts up for a couple of seconds, and when it's about to
>>> create the osg blue screen it dies.
>>> I attach the logcat, even though I couldn't understand from it what's the
>>> reason that makes the viewer die...
>>>
>>> The same happens with the GLES2 example, for which I attach the logcat as
>>> well.
>>>
>>> I'm still investigating and will post if I have some news,
>>> any hint is appreciated.
>>> Ricky
>>>
>>> _______________________________________________
>>> osg-users mailing list
>>> osg-users@lists.openscenegraph.org
>>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>>
>>>
>>
>> _______________________________________________
>> osg-users mailing list
>> osg-users@lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>>
>
> _______________________________________________
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to