我的问题是..。在这个中,他们将缓存实现为硬缓存和软缓存。对于硬cache..here
// Hard cache, with a fixed maximum capacity and a life duration
private final HashMap<String, Bitmap> sHardBitmapCache =
new LinkedHashMap<String, Bitmap>(HARD_CACHE_CAPACITY / 2, 0.75f, true) {
@Override
protected boolean remove
我有一个1.28MB (1,343,488字节)的大图片,我在我的应用程序中使用,但是我想改变一些东西,创建一个只有292 KB (299,008字节)大小的新图片。我在Photoshop 7.0中创建了这两张图片,将它们分别保存为.png和交错。我一直在围绕较大的图像创建此应用程序,当我切换到较小的图像时,我的位图显示OutOfMemory错误
12108912-byte external allocation too large for this process
为什么它认为我的新镜像是11.5MB?如果我将图像切换回较大的图像,它可以正确编译。
private Bitmap loadMa
为了解释我的问题,我将首先提供一些代码,并解释它的功能:
% 1 1 65532{}for % cut off on mac with font set
% 1 1 99996{}for % cut off on mac without font set
% 1 1 300048{}for % cut off on linux with font set
% 1 1 300368{}for % cut off on linux without font set
% /Times-Roman findfont 10 scalefont setfont
showpage
当我