android - How can I make the transparent part of an image not show up -
in android, animating 2 images 1 small on top of larger one. small generated using photoshop , visible part surrounded checkerboard pattern (which supposed transparent). when animation runs, images appear checkerboard patters shows grey square.
how can make transparent.
this how imagebutton setup in layout.xml
<imagebutton android:layout_gravity="top|left" android:layout_marginleft="184dp" android:layout_margintop="55dp" android:id="@+id/videothumb" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/button_power_on" />
and animation file:
<?xml version="1.0" encoding="utf-8"?> <alpha xmlns:android="http://schemas.android.com/apk/res/android" android:fromalpha="0.0" android:toalpha="0.8" android:duration="5000" android:repeatmode="reverse" android:repeatcount="infinite" />
i think it's because using imagebutton , grey color see default background of button. use imageview instead.
Comments
Post a Comment