[android-developers] Re: Exception Locking Canvas
@Jason: thanks for the inputs.
There are two reason for canvas lock; the other is failed to dequeue
GL buffer. THe following is written to the logs when this happens:
W/GraphicBufferMapper(2541): registerBuffer(0x3a2408) failed -14 (Bad
address)
W/Surface(2541): registerBuffer(...) failed -14 (Bad address)
E/Surface(2541): getBufferLocked(0, 0, 0, 0, 00000033) failed (Bad
address)
E/Surface(2541): dequeueBuffer failed (Bad address)
E/ViewRoot(2541): IllegalArgumentException locking surface
E/ViewRoot(2541): java.lang.IllegalArgumentException
E/ViewRoot(2541): at android.view.Surface.lockCanvasNative(Native
Method)
E/ViewRoot(2541): at android.view.Surface.lockCanvas(Surface.java:
314)
E/ViewRoot(2541): at android.view.ViewRoot.draw(ViewRoot.java:1456)
E/ViewRoot(2541): at
android.view.ViewRoot.performTraversals(ViewRoot.java:1258)
E/ViewRoot(2541): at
android.view.ViewRoot.handleMessage(ViewRoot.java:1859)
E/ViewRoot(2541): at android.os.Handler.dispatchMessage(Handler.java:
99)
E/ViewRoot(2541): at android.os.Looper.loop(Looper.java:130)
E/ViewRoot(2541): at
android.app.ActivityThread.main(ActivityThread.java:3683)
E/ViewRoot(2541): at java.lang.reflect.Method.invokeNative(Native
Method)
E/ViewRoot(2541): at java.lang.reflect.Method.invoke(Method.java:507)
E/ViewRoot(2541): at com.android.internal.os.ZygoteInit
$MethodAndArgsCaller.run(ZygoteInit.java:839)
E/ViewRoot(2541): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
E/ViewRoot(2541): at dalvik.system.NativeStart.main(Native Method)
It seems as if when the canvas is being built, there is some problem
in Buffer alloc/dealloc.
Can anyone give any pointers on what may be causing this?
Thanks.
On May 5, 9:46 am, "Jason Teagle" <teagle.ja...@gmail.com> wrote:
> >E/ViewRootImpl(10414): IllegalArgumentException locking surface
>
> I notice that it says 'illegal argument' - can you be absolutely sure that
> at the point where it fails, the Rect you are passing for the dirty area is
> a valid rect? Can you bounds check it against the extents of the surface as
> a sanity check?
>
> Quite why it should fail after a while I don't know, but it might be a place
> to start looking...
--
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+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home