Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GIF glitchy rendering with RoundedCorners in Glide 4.2 #2472

Closed
moxie0 opened this issue Oct 12, 2017 · 3 comments
Closed

GIF glitchy rendering with RoundedCorners in Glide 4.2 #2472

moxie0 opened this issue Oct 12, 2017 · 3 comments
Labels
Milestone

Comments

@moxie0
Copy link

moxie0 commented Oct 12, 2017

With this layout:

<FrameLayout
        xmlns:android="http://schemas.android.com/apk/res/android"
        xmlns:tools="http://schemas.android.com/tools"
        android:layout_width="@dimen/media_bubble_height"
        android:layout_height="@dimen/media_bubble_height"
        android:layout_marginBottom="5dp"
        android:layout_gravity="center"
        android:scaleType="centerCrop"
        android:adjustViewBounds="true">

    <ImageView android:id="@+id/image"
               android:layout_width="match_parent"
               android:layout_height="match_parent"
               android:adjustViewBounds="true"
               android:clickable="false"
               android:longClickable="false"
               android:scaleType="fitCenter"/>

</FrameLayout>

Loading a gif into the ImageView:

    GlideApp.with(getContext())
            .load(model)
            .diskCacheStrategy(DiskCacheStrategy.NONE)
            .transform(new RoundedCorners(radius))
            .transition(withCrossFade())
            .into(image);

Consistently produces these glitches in Glide 4.2.0:
glitchy

Happens for every gif I try, here's a sample:
https://media.giphy.com/media/xUNd9W5Wbh8cRmdFBe/giphy.gif

In Glide 3.7 I used a custom RoundedCorners transformation (I don't think one came with Glide?) and this wasn't an issue.

Glide Version: 4.2.0

@sjudd
Copy link
Collaborator

sjudd commented Oct 12, 2017

Does the old custom one you used with 3.7 cause these glitches as well? Or just the built in one in Glide?

Looks like #2345

@moxie0
Copy link
Author

moxie0 commented Oct 12, 2017

The old custom one I used with 3.7 worked fine. I'm working on upgrading to 4.x to see if that resolves #2453, but I'm having problems with this and gif playback speed.

Here's a small standalone project that reproduces these glitches:
https://github.com/moxie0/GlitchyCorners

@sjudd sjudd added the bug label Oct 12, 2017
@sjudd
Copy link
Collaborator

sjudd commented Oct 12, 2017

Thanks for the sample app, hugely helpful!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants