Timestamp of generated bitmap - Android

眉间皱痕 提交于 2019-12-22 10:15:59

问题


I have an app where I have downloaded an image file from the web and I save this file in external storage.

Later, to add this image to the media store, I call:

MediaStore.Images.Media.insertImage(getContentResolver(),
                fullPath, "IMG_"+System.currentTimeMillis(),null);

However, my picture always adds to the end of the gallery - it thinks that the picture was taken in 1970. How do I change this information?

Thanks!


回答1:


Worked using JPEGS (not PNG!) with ExifInterface



来源:https://stackoverflow.com/questions/12180934/timestamp-of-generated-bitmap-android

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!