🔥可以根据图片内容变阴影颜色,更加细腻的阴影效果 It can change color according to the picture, more delicate shadow effect
Java
Switch branches/tags
Nothing to show
Clone or download
Latest commit b06f927 May 23, 2018
Permalink
Failed to load latest commit information.
app update gradle Oct 26, 2017
gradle/wrapper update gradle Oct 26, 2017
shadowimageview update May 23, 2018
show update readme Oct 19, 2017
.gitignore ADD LICENSE Mar 26, 2017
LICENSE ADD LICENSE Mar 26, 2017
READEME_CN.md update readme Oct 19, 2017
README.md update May 23, 2018
build.gradle update May 23, 2018
gradle.properties Initial commit Mar 25, 2017
gradlew Initial commit Mar 25, 2017
gradlew.bat Initial commit Mar 25, 2017
settings.gradle Initial commit Mar 25, 2017

README.md

ShadowImageView

Abstract

More exquisite shadow effect, used in some special scene to enhance the user experience.

Chinese Documents

查看中文文档

Picture

1 2

GIF

1

Add Picture

3

Demo

Download App

Usage

Gradle

dependencies {
    compile 'com.yinglan.shadowimageview:shadowimageview:1.0.4'
}

In layout

	    <com.yinglan.shadowimageview.ShadowImageView
	            android:id="@+id/shadow"
                android:layout_width="300dp"
                android:layout_height="300dp"
                app:shadowRound="20dp"
                app:shadowSrc="@mipmap/lotus"
                app:shadowColor="@color/colorAccent"/>

Set Picture

    shadow.setImageResource(resID); 
    shadow.setImageDrawable(drawable); 
    shadow.setImageBitmap(bitmap);

Set the picture radius

    shadow.setImageRadius(radius);

Set the shadow color of the image

    shadow.setImageShadowColor(color);

Notice

SeePPMusicImageShadow, do a simple implementation, there may be a potential problem and use learning exchanges, looking forward to you have a better way of implementation.

License

The work done has been licensed under Apache License 2.0. The license file can be found here. You can find out more about the license at:

http://www.apache.org/licenses/LICENSE-2.0