ImageButton showing artifacts in transparent image
I have a layout like this:
<LinearLayout android:background="mybackgroundimage.jpg">
...
<LinearLayout android:weight=1> <!-- another layout to group the
images below and give it weight=1 -->
<ImageButton android:background="item1开发者_如何学Gobg.png" .../>
<ImageButton android:background="item2bg.png" .../>
</LinearLayout>
</LinearLayout>
The images item1bg and item2bg fade from full image to completely transparent. The desired effect is to have the image blending to the background.
I've verified the images and they look OK when you open them with whatever. But when applied in the button, they show artifacts in the blending section: some green vertical transparent lines.
I tried setAlpha(0) but the artifacts remain.
Any ideas on why this happens and/or how to solve it?
Thanks! Llappall
The problem was that the images DID have the artifacts, but they were hard to see because of the alpha value being bigger (making the section of the image transparent). It was a problem with the images, not ImageButton.
:(
Thanks
llappall
精彩评论