[英]I want to read exif info in image in android. I can read exif from image in gallery but i cannot read exif photo taken from the camera
You cannot read exif data from a Stream using the android api. 您无法使用android API从Stream中读取exif数据。 ExifInterface doesn't have a constructor with an InputStream.
ExifInterface没有带有InputStream的构造函数。
However, You can use the metadata-extractor and use the constructor with an InputStream to build an InputStream backed by your byte[] using a ByteArrayInputStream 但是,您可以使用元数据提取器 ,并将构造函数与InputStream一起使用,以使用ByteArrayInputStream构建由byte []支持的InputStream。
It is now possible to read EXIF data from streams through the ExifInterface Support Library. 现在可以通过ExifInterface支持库从流中读取EXIF数据。
compile "com.android.support:exifinterface:25.1.0"
Source: https://android-developers.googleblog.com/2016/12/introducing-the-exifinterface-support-library.html 来源: https : //android-developers.googleblog.com/2016/12/introducing-the-exifinterface-support-library.html
Android API do not read EXIF from Stream
. Android API不会从
Stream
读取EXIF。
Check this one - https://stackoverflow.com/a/12952370/842607 选中一个-https://stackoverflow.com/a/12952370/842607
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.