mmin18 / RealtimeBlurView

A realtime blurring overlay for Android (like iOS UIVisualEffectView)
Other
3.21k stars 350 forks source link

The blur view will show part when execute scale animator #49

Open aiynmm opened 4 years ago

aiynmm commented 4 years ago

The layout is very sample:

<FrameLayout
        android:id="@+id/save_pic"
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <ImageView
            android:id="@+id/pic_holder"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:scaleType="centerCrop"
            android:src="@mipmap/share_pic_1" />

        <com.github.mmin18.widget.RealtimeBlurView
            android:id="@+id/blur_view"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            app:realtimeBlurRadius="10dp"
            app:realtimeOverlayColor="#4DFFFFFF" />
</FrameLayout>

Then, I want to the framelayout execute a scale animator.

View savePic  = findViewById(R.id.save_pic);
savePic.animate().scaleX(0.8f).scaleY(0.8f).start();

Finally,I found the bottom and right part of the layout had no blur effect.