RoundImageView支持圆形、圆角、椭圆,可定制每个角的大小

RoundImageView支持圆形、圆角、椭圆,可定制每个角的大小_第1张图片
screenshot.png

Gradle

dependencies {
    compile 'org.raphets:roundimageview:1.2.0'
}

Usage

Define in xml:


Or in code:

        RoundImageView iv1= (RoundImageView) findViewById(R.id.iv1);

        iv1.setBorderWidth(3)
                .setBorderColor(Color.RED)
                .setType(RoundImageView.TYPE_ROUND)
                .setLeftTopCornerRadius(0)
                .setRightTopCornerRadius(10)
                .setRightBottomCornerRadius(30)
                .setLeftBottomCornerRadius(50);

        Picasso.with(this)
                .load("http://ww2.sinaimg.cn/large/610dc034jw1fa42ktmjh4j20u011hn8g.jpg")
                .into(iv1);

源码

https://github.com/RaphetS/RoundImageView

你可能感兴趣的:(RoundImageView支持圆形、圆角、椭圆,可定制每个角的大小)