cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nirav Gandhi (JIRA)" <>
Subject [jira] [Commented] (CB-12613) Camera encoding type not respected when destination type is NATIVE_URI
Date Mon, 17 Dec 2018 07:01:00 GMT


Nirav Gandhi commented on CB-12613:

I am able to reproduce this bug when I specify destination type as 
Camera.DestinationType.DATA_URL. The plugin ignores the encoding and returns the original
    var options = { quality:50, destinationType:Camera.DestinationType.DATA_URL, allowEdit:false,
encodingType:Camera.EncodingType.JPEG, popoverOptions:CameraPopoverOptions, saveToPhotoAlbum:true,
correctOrientation:true };  {code}
Hope this helps.

> Camera encoding type not respected when destination type is NATIVE_URI
> ----------------------------------------------------------------------
>                 Key: CB-12613
>                 URL:
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: cordova-plugin-camera
>         Environment: iOS 10+
>            Reporter: John Czaplewski
>            Priority: Major
> When a PNG or HEIC (Apple's new compressed file format) image is selected using the method
`getPicture` on iOS with the destination encoding type set to JPEG, the original file format
is returned instead of a JPEG. 
> For example,
> {code:javascript}
> camera.getPicture({
>   quality: 100,
>   destinationType: camera.DestinationType.NATIVE_URI,
>   encodingType: camera.EncodingType.JPEG
> }).then(imageData => {
>   // imageData will be the original file format, not a JPEG
> })
> {code}
> If the destinationType is changed to `FILE_URI` the image will be converted to a JPEG
as expected, but metadata such as geolocation will be stripped from the image (this might
be a separate issue?).

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message