ios - UIImage Caching cause memory high -


consider:

+(nullable uiimage *)imagenamed:(nsstring *)name; 

i use method so:

uiimage *image = [uiimage imagenamed:@"test"]; 

but image's type png.

enter image description here

in project, loads lot of different images.

so, cache hight

enter image description here

your images huge. 3001*4057 12 million pixels. theres 3 bytes in 1 pixel (one byte red, green , blue each), image size have 12million * 3 bytes, 36mb per image.

i scale down image size if can.


Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -