cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stephan Wezel <s.we...@web.de>
Subject Re: [Camera Plugin] Add support to save unmodified image to photoalbum
Date Thu, 28 Nov 2013 21:50:45 GMT
I don't say that this feature should be only for iOS. 
I need this feature for my project which isn't iOS only. But iOS is the first target.
I came up with this solution because i didn't knew it better.

I'm also fine if we would redefine what the result is when the option saveToPhotoAlbum is
active to mean that the original image is saved instead the image which is returned to the
caller.

- Stephan Wezel

On Thursday 28 November 2013 13:05:32 James Jong wrote:
> One consideration here is cross-platform consistency.  Camera is an area where we've
had issues with platforms having different behaviors for the same option.  Currently, you
can save the original image with the following camera options:
> { allowEdit : false,
>   correctOrientation : false,
>   saveToPhotoAlbum : true
> }
> 
> I'm also not sold that adding another save-to-photoalbum option (saveUnmodifiedImageToPhotAlbum)
is the best way.  May be a bit confusing.  If we do add it, the behavior of the 2 options
need to be documented clearly.  Perhaps it would be better to document the above options as
the way to get the unmodified image?
> 
> -James Jong
> 
> On Nov 28, 2013, at 11:18 AM, Stephan Wezel <s.wezel@web.de> wrote:
> 
> > Hi Andrew,
> > 
> >> Have you signed the Apache CLA? http://www.apache.org/licenses/#clas You'll
> >> need to do so before we can accept code from you.
> > No not yet.
> > 
> >> Could you clarify your intent with the new flag for me? Is it:
> >> 1. To ensure the image isn't resized at all, or:
> >> 2. To save the unmodified image to the camera roll, but then return a
> >> resized image to the app.
> >> 
> >> If it's #2, then I think that would be reasonable default behaviour
> >> when saveToPhotoAlbum is set. WDYT?
> > For me it is #2. First i thought that the option saveToPhotoAlbum would save the
original image from the camera without any changes to it (scale, rotate).
> > Because the description of this option doesn't say anything that the image, is saved
to the photoalbum after a modification (if targetWidth/targetHeight, correctOrientation or
quality is changed from its default value  )
> > 
> > But the current implementation (at least under iOS and Android) save the photo to
the photoalbum after the image is scaled/rotated.
> > 
> > So i came up with this patch vor iOS and created a jira entry (https://issues.apache.org/jira/browse/CB-5479)
> > 
> > I also think that saving the original image would be a reasonable default behaviour.
> > 
> > On Thursday 28 November 2013 10:47:24 Andrew Grieve wrote:
> >> Thanks Stephan.
> >> 
> >> Have you signed the Apache CLA? http://www.apache.org/licenses/#clas You'll
> >> need to do so before we can accept code from you.
> >> 
> >> Could you clarify your intent with the new flag for me? Is it:
> >> 1. To ensure the image isn't resized at all, or:
> >> 2. To save the unmodified image to the camera roll, but then return a
> >> resized image to the app.
> >> 
> >> If it's #2, then I think that would be reasonable default behaviour
> >> when saveToPhotoAlbum is set. WDYT?
> >> 
> >> 
> >> On Thu, Nov 28, 2013 at 4:36 AM, Stephan Wezel <s.wezel@web.de> wrote:
> >> 
> >>> Hi,
> >>> 
> >>> for a project which I'm developing with cordova i need the possibility
> >>> to save the unmodified image from the camera to the photoalbum.
> >>> 
> >>> I have attached a patch which implements this new functionality for iOS.
> >>> 
> >>> Regards
> >>> 
> >>> Stephan Wezel
> >>> 
> > 
> 


Mime
View raw message