You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
W/ExifInterface: Invalid image: ExifInterface got an unsupported image format file(ExifInterface supports JPEG and some RAW image formats only) or a corrupted JPEG file to ExifInterface.
java.io.IOException: Invalid marker: 89
at android.media.ExifInterface.getJpegAttributes(ExifInterface.java:1837)
at android.media.ExifInterface.loadAttributes(ExifInterface.java:1475)
at android.media.ExifInterface.(ExifInterface.java:1112)
at cn.finalteam.galleryfinal.widget.crop.CropUtil.getExifRotation(CropUtil.java:59)
at cn.finalteam.galleryfinal.widget.crop.CropImageActivity.setSourceUri(CropImageActivity.java:119)
at cn.finalteam.galleryfinal.PhotoEditActivity.loadImage(PhotoEditActivity.java:385)
at cn.finalteam.galleryfinal.PhotoEditActivity.onCreate(PhotoEditActivity.java:261)
at android.app.Activity.performCreate(Activity.java:6745)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1134)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2655)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2788)
at android.app.ActivityThread.-wrap12(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1503)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6209)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:865)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:755)
The text was updated successfully, but these errors were encountered:
Uri uri; // the URI you've received from the other app
InputStream in;
try {
in = getContentResolver().openInputStream(uri);
ExifInterface exifInterface = new ExifInterface(in);
// Now you can extract any Exif tag you want
// Assuming the image is a JPEG or supported raw format
} catch (IOException e) {
// Handle any errors
} finally {
if (in != null) {
try {
in.close();
} catch (IOException ignored) {}
}
}
W/ExifInterface: Invalid image: ExifInterface got an unsupported image format file(ExifInterface supports JPEG and some RAW image formats only) or a corrupted JPEG file to ExifInterface.
java.io.IOException: Invalid marker: 89
at android.media.ExifInterface.getJpegAttributes(ExifInterface.java:1837)
at android.media.ExifInterface.loadAttributes(ExifInterface.java:1475)
at android.media.ExifInterface.(ExifInterface.java:1112)
at cn.finalteam.galleryfinal.widget.crop.CropUtil.getExifRotation(CropUtil.java:59)
at cn.finalteam.galleryfinal.widget.crop.CropImageActivity.setSourceUri(CropImageActivity.java:119)
at cn.finalteam.galleryfinal.PhotoEditActivity.loadImage(PhotoEditActivity.java:385)
at cn.finalteam.galleryfinal.PhotoEditActivity.onCreate(PhotoEditActivity.java:261)
at android.app.Activity.performCreate(Activity.java:6745)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1134)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2655)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2788)
at android.app.ActivityThread.-wrap12(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1503)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6209)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:865)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:755)
The text was updated successfully, but these errors were encountered: