Android Development How to let the program generated picture files will not be scanned by the system

Source: Internet
Author: User
When we write the application, may save a lot of pictures, big small, only our application will be used, for a variety of reasons do not want users to see, I think if the user saw, lost my application of that layer of mysterious veil, Users are meters have carefree to open your layer of folders to look at your saved pictures or audio and video and other multimedia files. However, many like the image gallery software or music player video player when playing local audio and video will scan the user's file system, will be your saved multimedia files swept out.
At this time if you save a small picture too much, or too much audio, the user after a lot of pages, full screen or your app inside can cause users to dislike, so that uninstall your app. How to avoid this situation?
1. When creating a picture, do not create files with a. jpg or. png file name, read directly to the stream of files to read, so the file system does not know what you are the files, the disadvantage is that you do not know your own save the success of No, you do not know what you save is thousand what things, not very intuitive. And can only be read in a stream way.
2, directly in the form of pictures to save in the folder, in the folder to create a file named . Nomedia , so that your multimedia files relative to the system is hidden. Isn't it convenient?

Android Development How to let the program generated picture files will not be scanned by the system

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.