-
-
Notifications
You must be signed in to change notification settings - Fork 16
Description
When retrieving the imagesource like this:
selection.forEach(function(asset) {
asset.getImage().then(function(imagesource){
let folder = fs.knownFolders.documents();
let path = fs.path.join(folder.path, "Test"+counter+".jpg");
let saved = imagesource.saveToFile(path, "jpg");
if(saved){
var task = sendImages("Image"+counter+".jpg", path);
}
})
});
the image header information gets reduced, and the rotation information is lost.
Our server is using the orientation information to rotate the image.
When using the approach above to upload the image, the image header information looks like this:
Luminance Table:0
Chrominance Table:0
But if I'm uploading the image directly using the asset.fileUri, the image header information looks like this:
Chrominance Table:0
Flash:reserved
Equip Model:D6603
Metering Mode:Pattern
DTDigSS:371350
Thumbnail Compression:6
DTSubsec:371350
PixXDim:3840
FocalLength:4,6
Resolution Unit:2
Y Resolution:72/1
Thumbnail ResolutionX:72/1
Thumbnail ResolutionY:72/1
Exposure Bias:0/3
Software Used:23.5.A.1.291_6_f1000010
DTOrig:2016:12:22 15:17:56
Orientation:6
Thumbnail Orientation:6
ISO Speed:ISO-80
JPEG InterFormat:11790
Exposure Time:0,03
JPEG InterLength:5928
Date Time:2016:12:22 15:17:56
Thumbnail Data:255
DTOrigSS:371350
Maker Note:-
PixYDim:2160
Ver:-
FPXVer:-
Equip Make:Sony
X Resolution:72/1
CompConfig:-
YCbCr Positioning:1
F-Number:F/2
Thumbnail ResolutionUnit:2
Luminance Table:0
LightSource:unknown
Shutter Speed:1/32
ColorSpace:1
DTDigitized:2016:12:22 15:17:56
Is there a way to maintain the header information, or at least the orientation property?