Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

SurfaceFlinger: Failed to find layer & Applying effect in wrong GL context

See original GitHub issue
...document, PID: 664
    java.lang.RuntimeException: Applying effect in wrong GL context!
        at ja.burhanrashid52.photoeditor.ImageFilterView.applyEffect(
        at ja.burhanrashid52.photoeditor.ImageFilterView.onDrawFrame(
        at android.opengl.GLSurfaceView$GLThread.guardedRun(
        at android.opengl.GLSurfaceView$

Does this library support all the android version above 5.0 i am using 8.1.0

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:8 (1 by maintainers)

github_iconTop GitHub Comments

NahlaSaadAlDeencommented, Jul 7, 2022

I’v solved it add the lib as module in the project, update on ImageFilterView class the update is in this section of code if (!mInitialized) { //Only need to do this once mEffectContext = EffectContext.createWithCurrentGlContext(); mTexRenderer.init(); loadTextures(); mInitialized = true; }

the solution is : remove the mInitialized condition and let the code in it run without this condition (remove the role of mInitialized)

burhanrashid52commented, Dec 18, 2022

@burhanrashid52 can you please prioritise this issue. Facing this in my current usage in recycler view.

Check this comment on issue #242

Read more comments on GitHub >

github_iconTop Results From Across the Web

Applying effect in wrong GL context! in android app while ...
I am showing all the filters that are available in-app in horizontal recyclerview. But when I scroll the recycler view my application crashes....
Read more >
SurfaceFlinger.cpp - Google Git
Get a RenderEngine for the given display / config (can't fail). getBE(). ... make the default display GLContext current so that we can...
Read more >
SurfaceFlinger and WindowManager
After SurfaceFlinger has collected all buffers for visible layers, it asks the Hardware Composer (HWC) how composition should be performed. If ...
Read more >
[Quote] Android Graphics Architecture - Shawn X.Y. Bai - 博客园
When the VSYNC signal arrives, SurfaceFlinger walks through its list of layers looking for new buffers. If it finds a new one, it...
Read more >
Chapter 4. Screen and UI Performance - O'Reilly
Applying the same argument to apps tells us that the faster you can get ... as the “depth” of your view XML can...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found