android - define Bitmap bytes count and set limit to bitmap buffer -
in application have image viewer , getting bitmaps web server. in order increase performance of app, have buffer of bitmaps. max size of 1 bitmap can 0.5mb. have buffersize variable want store buffer bytes count , therefore need know each bitmap size going add in buffer.and if bites count exceed x number delete bitmap front of buffer. , here problems:
- i don't know how define bitmap bytes count
- i need suggestion x number .
thanks in advance.
- you can number of bytes in bitmap using getbytecount() method.
- depends on how memory app using, how many images retrieving web server, , how need display them. use fraction of system.maxmemory(). in case
Comments
Post a Comment