在xml中設(shè)置如下屬性,就可以把圖片變?yōu)閳A角
fresco:roundedCornerRadius="5dp"
<com.facebook.drawee.view.SimpleDraweeView
fresco:roundedCornerRadius="5dp"
fresco:actualImageScaleType="focusCrop"
android:id="@+id/image_view"
android:layout_width="match_parent"
android:layout_height="match_parent" />
Uri uri = Uri.parse("http://i.imgur.com/DvpvklR.png");
SimpleDraweeView imageView = (SimpleDraweeView) findViewById(R.id.image_view);
imageView.setImageURI(uri);```

- 當(dāng)然也可以設(shè)置底部不為圓角
<com.facebook.drawee.view.SimpleDraweeView
fresco:roundBottomLeft="false"
fresco:roundBottomRight="false"
fresco:roundedCornerRadius="500dp"
fresco:actualImageScaleType="focusCrop"
android:id="@+id/image_view"
android:layout_width="match_parent"
android:layout_height="match_parent" />

- 如果你是用來做頭像的,一般設(shè)置為圓圈圖片
<com.facebook.drawee.view.SimpleDraweeView
fresco:roundAsCircle="true"
fresco:actualImageScaleType="focusCrop"
android:id="@+id/image_view"
android:layout_width="match_parent"
android:layout_height="match_parent" />

- 還可以加個(gè)頭盔
<com.facebook.drawee.view.SimpleDraweeView
fresco:roundAsCircle="true"
fresco:actualImageScaleType="focusCrop"
android:id="@+id/image_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
fresco:roundingBorderWidth="10dp"
fresco:roundingBorderColor="#ff0000" />```
