How to set outer glow effect on ImageView?

PSK picture PSK · Mar 23, 2013 · Viewed 10.1k times · Source

I have tried this. but it is not working this on ImageView. but this code is not setting any outer glow on Image.

    android:shadowColor="#7ccb16"
    android:shadowDx="0"
    android:shadowDy="0"
    android:shadowRadius="3"

guide me how do I do this.

Answer

Gunaseelan picture Gunaseelan · Mar 23, 2013

Refered form here

using ninepatch tool in android sdk.

<ImageView
        android:id="@+id/image_test"
        android:background="@drawable/drop_shadow"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:paddingLeft="6px"
        android:paddingTop="4px"
        android:paddingRight="8px"
        android:paddingBottom="9px"
        android:src="@drawable/pic1"
        />

I hope this will be useful to you.