Dimezis / BlurView

Dynamic iOS-like blur of underlying Views for Android
Apache License 2.0
3.49k stars 331 forks source link

java.lang.StackOverflowError: stack size 8MB at android.view.ViewGroup.buildOrderedChildList(ViewGroup.java:3427) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3313) at androidx.constraintlayout.widget.ConstraintLayout.dispatchDraw(ConstraintLayout.java:1975) #166

Closed kirikaTowa closed 4 months ago

kirikaTowa commented 2 years ago

Please include: 1) Library version 2) Device and OS version 3) Detailed steps to reproduce the issue 4) XML layout and code for BlurView setup 5) Stacktrace in case of a crash

kirikaTowa commented 2 years ago

at android.view.View.draw(View.java:15363) at android.widget.FrameLayout.draw(FrameLayout.java:647) at eightbitlab.com.blurview.BlockingBlurController.updateBlur(BlockingBlurController.java:122) at eightbitlab.com.blurview.BlockingBlurController.draw(BlockingBlurController.java:164)

rootView.draw(internalCanvas) Seems to be in an endless loop。In LG 5.0

Dimezis commented 2 years ago

Please fill in the required details properly

kirikaTowa commented 2 years ago

请正确填写所需的详细信息 I would like to ask, this method will cause an infinite loop under normal circumstances in BlockingBlurController, how do you deal with it? image

Dimezis commented 2 years ago

The BlurView checks if the Canvas used in draw is internalCanvas, so it draws itself only on system canvas and skips the recursive drawing on internalCanvas

kirikaTowa commented 2 years ago

Thank you.InternalCanvas will have a problem when performing animation on some 5.0 models, resulting in this type of error. The rootView can be solved by using the parent of the previous level.