canvas - Android. How can I make an ImageView draw itself as a PNG? -


an imageview has been loaded 1514 × 564 png image of 67kb.

a linearlayout, containing several views including such imageview, needs drawn canvas. when calling method imageview.draw(canvas), canvas size in bytes increases 67kb 13mb! (because "draw" draws bitmap, not compressed png)

is there easy way make imageview draw png?

so far, i've thought of extending imageview , overriding draw method compresses bitmap before drawing.

is there easy way make imageview draw png?

no, because there no such concept. moreover, have png, unclear why calling draw()` in first place. if want png, use png.

so far, i've thought of extending imageview , overriding draw method compresses bitmap before drawing.

that pointless, need re-decompress image before drawing it. canvas draws bitmap, not png, , bitmap decompressed image.


Comments

Popular posts from this blog

c# - Validate object ID from GET to POST -

node.js - Custom Model Validator SailsJS -

php - Find a regex to take part of Email -