开发者

rub image in canvas

I am using android 2.x and I have four bitmaps drawn on a canvas, now i want to replace "yahoo" image with some other image and that image's size is different than "yahoo" image. Now what i want is , i want to rub the yahoo image and replace it with the new one but in such a way that if i rub "yahoo" image then images that are laying in the background don't get disturbed or vanished.

开发者_JAVA技巧

here is the sample image

rub image in canvas


This sounds pretty simple to do....

on your ondraw function, you should just re-draw each bitmap, starting at the most bottom one to the top.

I dont know what do you mean by "rub", the only way I know how to do this is just to always re-draw each objects, and if you dont want Yahoo to show, just replace Yahoo bitmap with the new Bitmap that you wish to replace it.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜