Android Bitmap memory question - ARGB_4444 vs RGB_565
When loading an image into a bitmap, which method consumes more memory (ARGB_4444 vs RGB_565) ?
开发者_如何学运维Thanks.
They take the same amount of memory. (See those numbers? They tell you the number of bits for each component (A, R, G, B). Add them up to get the total bits per pixel.)
If you don't need the transparency, though, of those two i'd recommend RGB_565 as it gives you more distinct colors. ARGB_4444 sacrifices some of its color depth in order to provide transparency.
Both take the same amount of memory. Do not use ARGB_4444 unless you are really sure you need it - it looks horrible.
精彩评论