How to get the EXIF metadata info from a base64 image in Ionic 3? - ionic-framework

I am picking an image from android phone gallery using Ionic native Camera plugin which is giving me base64 data which is my requirement for the time. Now, on some mobiles the image picked (base64 data) returns with its orientation rotated. How can I can extract the EXIF information from this base64 image and change its orientation so that I can then send it to the server for uploading.
and I am not looking for the upload code. Just the EXIF info & change orientation part.
Any help is highly appreciated in advance :).

You can use cordova-plugin-camera-with-exif library to get the EXIF metadata

I have used piexifjs to read the Exif data and add geo coordinates to a base64. I bet you can fix the orientation issue using the same plugin. But the plugin itself very memory intensive. It took more than 2 minutes to read the exif data, change, and write again to a base64.

Related

Is there a Flutter plugin to Strip/Modify EXIF data from photos, such as GPS coordinates?

I've seen a few plugins that allow you to read this data, but nothing to write/remove it.
I know in Android there is a way to do this with the support lib (https://developer.android.com/reference/android/support/media/ExifInterface.html#saveAttributes())
And there appears to be several examples for Modifying EXIF data on iOS.
But I don't see this in any image or standalone plugins that handle this for flutter.
This all seems a bit strange, since there are several example Flutter Photo Sharing apps using Firebase storage and such. But none, that I've seen, are removing any of this data.
You can use flutter_image_compress to strip the Exif (you can optionally maintain it). But I could not find any solution to edit Exif with Flutter.

Facebook, what is WebP format of photo

In this reference of the "photo" table on Facebook, there was a new image format, which is called WebP format, any one knows what's the difference between this format and some other formats like JPEG or PNG? Is this kind of image used on handsets?
It's a image format created by Google that's around 20% smaller than JPG.
https://developers.google.com/speed/webp/
It's supported in Google Chrome and Android 4.0+

DICOM video converter

I've recently get a set of medical videos data in DICOM format. The problem is that I know they should be videos but any DICOM program I've used till now, knows each video as a single image!
I've also tried MATLAB dicomreader to convert videos to stream of frames but the same problem occurs.
Does anyone know how can I convert my data to a known video format like avi, mpg, wmv,...?
Can the problem be the system(GEMS echocardiography) which has burnt data on CD? or maybe there must be a setting before writing...
Thank you all for your help and guides.
Imebra has an example called dicom2jpeg that can also convert to video if you have ffmpeg installed on your pc.
The downside is that you have to compile the example yourself using QMake or QtCreator.
In the case that the originator really stored the video as a collection of single images, your best bet is still to use ffmpeg and give the bunch of images (converted to jpeg or png) as input.

Uploading images from iPad in base64 format and size limit

We are developing a inspection application for iPad, where user can select multiple images from iPad and upload this images to portal, also he can enter comments on each particular image.
We are using xml for communication and converting images into base64 string format and uploading to server.
When xml size reaches around 2 MB, at the server side xml is not received and tomcat server returns Null Pointer Exception.
It will work fine if xml size is less than 2 MB.
So i would like to know is converting images to base64 is a proper way to upload images to server?
Is there any size limit for uploading data from iPad/iPhone Application?
Any help is really appreciated.
hi just compress your image
NSData *imageData = UIImageJPEGRepresentation(theImage, 0.1f);
This compress your image and then convert it to base64..
Use ASIHTTP framework for uploas an image from mobile to server
use the below link for how to upload image
http://allseeing-i.com/ASIHTTPRequest/How-to-use don't forgot to add asihttp framewok to your app
We have used PUT for HTTPMethod instead of POST and it worked properly, But I am not sure if there are any disadvantage of using PUT.

objectiveflickr geotag

I am trying to use objectiveflickr to upload an image to flickr from my iphone but for some reason it strips the EXIF info (i want the image geotagged), is there a way around this?
Maybe it's related to this issue :
UIImagePickerController and extracting EXIF data from existing photos
See my answer to this question there :
UIImagePickerController and extracting EXIF data from existing photos