【发布时间】:2015-11-26 01:37:17
【问题描述】:
我看到了这个答案:What is the difference between Bitmap and Drawable in Android?
谁能给出实际的解释?什么时候使用?优势劣势?
【问题讨论】:
-
这样想:JPEG 和 PNG 是图像编码的两个例子。因此,当您处理图像时,您需要做两件事:解码图像(将流转换为像素)和渲染图像。
Bitmap是关于编码/解码/操作像素的全部内容。Drawable就是将事物渲染到屏幕上以便您可以看到它们。BitmapDrawable汇聚于此。
标签: android performance android-drawable android-bitmap