You still haven't clearly explained how you use the GL context from two
different threads? I understand you're locking, etc. But are you doing an
eglMakeCurrent() to transfer ownership from GLSurfaceView's thread to
another thread?


On Sun, Jul 1, 2012 at 5:30 PM, gl...@wanderfulstorybooks.com <
gl...@wanderfulstorybooks.com> wrote:

> Romaine,
>
> I am only called from Andrioid with a useable GL10 context from
> GLSurfaveView.Renderer.onDrawFrame (or onSurfaceXXX).  If I save the value
> and try to use it from another thread, it does not work.  Please ignore the
> question of locking.  I was trying to inform you that I have been
> developing software for 35 years and wasn't asking anything stupid.  I know
> I cannot use the context from two thread simultaneously.  That is what the
> locking is for.  In this manner, I am able to set the gl context on a
> different thread and use it successfully on iOS, OSX, Win32, etc.  The
> OpenGL ES spec says nothing about Andrioid, which perhaps is an act of
> discretion ...
>
> On Saturday, June 30, 2012 4:33:32 PM UTC-7, 
> gl...@wanderfulstorybooks.comwrote:
>>
>> Hello,
>>
>> I am optimizing an OpenGL-based application ported from that other
>> major mobile OS and find that I cannot successfully access the GL
>> context from anything other than the rendering thread of
>> GLSurfaceView.  What I CAN do on other platforms is upload my single
>> (and large) texture to GL prior to needing to render the texture
>> itself.  This is a 640x480 8-bit RGB texture that takes some time to
>> upload to the chip and needs to be done every time I realize a new
>> frame of animation from the background system memory buffer.  I'm sure
>> you can appreciate the savings in execution time if I can perform this
>> upload from another thread when I have nothing left to do but wait for
>> GLSurfaceView's rendering thread to call me.  All is synchronized
>> safely as evidenced by the successful release of this software using
>> this very same technique on that-other-platform-that-**shall-not-be
>> named.  Things are very smooth and zippy on that platform, but Android
>> currently suffers by comparison.  Is there any way to do this?
>>
>>
>> Thanks
>>
>> Glenn
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en




-- 
Romain Guy
Android framework engineer
romain...@android.com

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to