vinc3m1/RoundedImageView

Poor Render Quality on Android Version 9

sorter opened this issue · 1 comments

I'm experiencing extremely poor quality rendering on Moto g(7) play Android version 9.

This only occurs on this device/version, all others render normally. Here is a screenshot of ImageView side by side with RoundedImageView, I have also attached the image asset depicted in the screenshot.

        <com.makeramen.roundedimageview.RoundedImageView
            android:id="@+id/matrix_cell_avatar"
            android:layout_width="90dp"
            android:layout_height="90dp"
            android:layout_marginStart="5dp"
            android:layout_marginTop="5dp"
            android:layout_marginEnd="5dp"
            android:scaleType="fitCenter"
            app:riv_mutate_background="true"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toTopOf="parent"
            app:riv_corner_radius="5dp"/>

Any guidance would be appreciated.

RoundedImageView
image

ImageView
image

image asset
air_conditioner

mBitmapPaint = new Paint(); mBitmapPaint.setStyle(Paint.Style.FILL); mBitmapPaint.setFlags(Paint.FILTER_BITMAP_FLAG); mBitmapPaint.setAntiAlias(true); mBitmapPaint.setDither(true);

Add Paint.FILTER_BITMAP_FLAG in RoundedDrawable maybe be get better image quality