search

Home  >  Q&A  >  body text

java - android如何获取一个图片文件夹中所有图片的缩略图?

PHPzPHPz2801 days ago823

reply all(2)I'll reply

  • 黄舟

    黄舟2017-04-18 10:47:24

    When adding/deleting pictures in the folder, generate a thumbnail in advance, and then load it directly when needed.

    p.s. The avatar of the WeChat group is pre-generated when the group is created.

    p.p.s. If you generate all the pictures into a thumbnail first, if you do it incorrectly, it will directly cause OOM. If the number is large, you can only do it one by one....

    reply
    0
  • 伊谢尔伦

    伊谢尔伦2017-04-18 10:47:24

    MediaStore.Images.ThumbnailUtils can get thumbnails in bitmap format, which should solve your problem

    reply
    0
  • Cancelreply