Return-Path: X-Original-To: apmail-incubator-callback-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-callback-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8FD48D4A3 for ; Fri, 28 Sep 2012 18:04:30 +0000 (UTC) Received: (qmail 23442 invoked by uid 500); 28 Sep 2012 18:04:30 -0000 Delivered-To: apmail-incubator-callback-dev-archive@incubator.apache.org Received: (qmail 23392 invoked by uid 500); 28 Sep 2012 18:04:30 -0000 Mailing-List: contact callback-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: callback-dev@incubator.apache.org Delivered-To: mailing list callback-dev@incubator.apache.org Received: (qmail 23381 invoked by uid 99); 28 Sep 2012 18:04:30 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Sep 2012 18:04:30 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of bowserj@gmail.com designates 209.85.212.177 as permitted sender) Received: from [209.85.212.177] (HELO mail-wi0-f177.google.com) (209.85.212.177) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Sep 2012 18:04:26 +0000 Received: by wibhj13 with SMTP id hj13so101205wib.0 for ; Fri, 28 Sep 2012 11:04:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=1swrP5YZbAipDF3of2MqMDlWFUL21teY3FebSnLrOTA=; b=hTTHj4C+lmzysuJAmgR4TdhFvYv7+0EAOpFULjzipbXb4ZvAf3rWnIPj9CJqVrIZ4N t8bThrGFpqTQhqmGwmRmqNQyjy7oOBw8o3UX706ZS/3Nh2Y1K6QztxZUZp9bJ/G/+Urb pK2jTZG/Hd6a9ThLkuFdWKfrnLijzaf+jOrB2P/nWZXhpCLbR57u0ihzUbKf6C4WZOAr L9XyxCXUZQrmW/g5F2RodCLwdEwj5VHsT/j6WBGZU0wkHyUs9sRA0FxQkoGRP+mmTtxH dluXsetq6UGLFJGPbGNLa2KLdwnUnq5AVkIS4P7X/HH2IA11e7PZe7v/pMJmqoXtM54j Em3A== MIME-Version: 1.0 Received: by 10.180.94.226 with SMTP id df2mr5361236wib.11.1348855444803; Fri, 28 Sep 2012 11:04:04 -0700 (PDT) Received: by 10.223.194.66 with HTTP; Fri, 28 Sep 2012 11:04:04 -0700 (PDT) In-Reply-To: References: Date: Fri, 28 Sep 2012 11:04:04 -0700 Message-ID: Subject: Re: Own. The. Camera. From: Joe Bowser To: callback-dev@incubator.apache.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org Hey I added zoom and fiddled with the UI so I could test zoom. The UI looks like ass but may be better once we get better assets. The good news is that we now have: * AutoFocus * Zoom We need to lock orientation and config changes, because right now they're crashing the camera. Also, we still need to have a good way to do previews. But yeah, anyone who says that Native UI is better clearly hasn't made a UI on Android. Getting the slider to do what I wanted took a while!!!! Joe On Wed, Sep 26, 2012 at 9:49 AM, Simon MacDonald wrote: > I merge our two streams here: > > https://github.com/macdonst/cordova-android/tree/camera2 > > I'll have to look at pushing to Apache soon. > > Right now I can't seem to get the proper orientation of the picture > which will screw a lot of things up. > > Simon Mac Donald > http://hi.im/simonmacdonald > > > On Tue, Sep 25, 2012 at 6:26 PM, Joe Bowser wrote: >> Hey >> >> I have some preliminary UI work done up on my Camera branch: >> >> https://github.com/infil00p/callback-android/tree/camera >> >> There's quite a few issues with the Camera that I'm still trying to >> hammer down. I might start moving this into the JS, but I think that >> we might want to talk about the UI and how to improve it. Should the >> camera button be larger, and should it be a picture of a camera? Does >> this make sense? It'd be good to minimize the number of images used, >> since I would rather not have to distribute images. >> >> I'll finish up auto-focus, but it'd be good if it would consistently >> take a photo first. There seems to be an issue with the photo that's >> coming back which is the issue. >> >> Also, would it make sense to move the branch onto a branch on the >> Apache Cordova repo? >> >> Joe >> >> On Tue, Sep 25, 2012 at 11:24 AM, Simon MacDonald >> wrote: >>> Cool Joe. Thanks for the heads up on the UI. I kinda think we will >>> need a preview as that is what folks expect. >>> >>> Simon Mac Donald >>> http://hi.im/simonmacdonald >>> >>> >>> On Tue, Sep 25, 2012 at 2:19 PM, Joe Bowser wrote: >>>> Hey >>>> >>>> I'm currently hacking on the UI. This really reminds me of why this >>>> project exists in the first place. I'm hoping to get a basic layout >>>> working by the end of the day for phones. >>>> >>>> We also need to implement the following: >>>> >>>> * AutoFocus >>>> * Zoom >>>> * Preview >>>> >>>> I'm willing to not have preview, since this could be implemented in >>>> HTML and Javascript by the developer, even though every camera app >>>> that I've seen did have preview built-in so far. >>>> >>>> Joe >>>> >>>> On Tue, Sep 25, 2012 at 11:13 AM, Simon MacDonald >>>> wrote: >>>>> Just an update as I continue to work on this. I have the >>>>> CameraActivity working with the following options: >>>>> >>>>> quality : any quality >>>>> destinationType : DATA_URL or FILE_URI, >>>>> sourceType : CAMERA or PHOTOALBUM >>>>> allowEdit : N/A on Android >>>>> encodingType: JPEG only >>>>> targetWidth: any width >>>>> targetHeight: any height >>>>> mediaType: any media type >>>>> popoverOptions: N/A on Android >>>>> saveToPhotoAlbum: true or false >>>>> correctOrientation: completely broken >>>>> >>>>> Things that need to be done include: >>>>> >>>>> 1) Figure out why the Camera class does not save any of the EXIF data >>>>> with orientation being the most important so we can do >>>>> correctOrientation properly. >>>>> 2) Move a lot of the code in CameraLauncher into CameraActivity. That >>>>> way we won't need to write a File in CameraActivity then read it in >>>>> CameraLauncher. By working with the raw bytes in CameraActivity to do >>>>> rotation/resizing/compression we should be able to save on memory. >>>>> 3) Make the Camera GUI look so much nicer than my current utilitarian mode. >>>>> 4) Move away from a camera layout file to putting the layout in code >>>>> so we don't have to make Cordova a library project. >>>>> >>>>> Simon Mac Donald >>>>> http://hi.im/simonmacdonald >>>>> >>>>> >>>>> On Fri, Sep 21, 2012 at 8:50 PM, Simon MacDonald >>>>> wrote: >>>>>> That should already be fixed by this commit: >>>>>> >>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-cordova-android.git;a=commit;h=f78af9f27baa82a351fb4b8a317ad50d54d99e56 >>>>>> >>>>>> Simon Mac Donald >>>>>> http://hi.im/simonmacdonald >>>>>> >>>>>> >>>>>> On Fri, Sep 21, 2012 at 7:11 PM, Anis KADRI wrote: >>>>>>> >>>>>>> Indeed. >>>>>>> >>>>>>> I got this with the latest target http://pastebin.com/wj11TGhh >>>>>>> >>>>>>> and the errors above with an old target and I then I recalled >>>>>>> that renderscript.opt.level thingy. Anyway we can fix this for good ? I >>>>>>> know it has nothing to do with the topic! :-) >>>>>>> >>>>>>> On Fri, Sep 21, 2012 at 3:59 PM, Simon MacDonald >>>>>>> wrote: >>>>>>> >>>>>>> > Looks like you are using an older version of Android before those Exif >>>>>>> > properties existed. >>>>>>> > >>>>>>> > Simon Mac Donald >>>>>>> > http://hi.im/simonmacdonald >>>>>>> > >>>>>>> > >>>>>>> > On Fri, Sep 21, 2012 at 6:56 PM, Anis KADRI >>>>>>> > wrote: >>>>>>> > >>>>>>> > > Tried it out. Not compiling. http://pastebin.com/3KK96gCu >>>>>>> > > Didn't spend too much time on it. So solution can be trivial :) >>>>>>> > > >>>>>>> > > On Fri, Sep 21, 2012 at 2:04 PM, Joe Bowser wrote: >>>>>>> > > >>>>>>> > > > That sounds like a good idea. Do we want auto-focus on or off on >>>>>>> > > > the >>>>>>> > > > camera? >>>>>>> > > > >>>>>>> > > > Joe >>>>>>> > > > >>>>>>> > > > On Fri, Sep 21, 2012 at 12:43 PM, Simon MacDonald >>>>>>> > > > wrote: >>>>>>> > > > > Okay, >>>>>>> > > > > >>>>>>> > > > > So I've done a bit of work today on taking the camera code back in >>>>>>> > > house. >>>>>>> > > > > Right now I have the very basic take a picture and return a file >>>>>>> > > > > URI >>>>>>> > > > > working. It does not respect and options or do any image >>>>>>> > manipulation. >>>>>>> > > > I'm >>>>>>> > > > > going to take the time to add that back in slowly. >>>>>>> > > > > >>>>>>> > > > > >>>>>>> > > > >>>>>>> > > >>>>>>> > >>>>>>> > https://github.com/macdonst/cordova-android/commit/ac5dbf3f54ac6e43f6c346130ac2ac86aed26eb5 >>>>>>> > > > > >>>>>>> > > > > Also, I'm using a layout file which means you have to import >>>>>>> > > > > Cordova >>>>>>> > > into >>>>>>> > > > > your test app as a library project. I'm just doing that for now as >>>>>>> > > > > eventually that layout will get converted to code so we can go >>>>>>> > > > > back >>>>>>> > to >>>>>>> > > > > making it a jar. I am not a UI designer so Joe volunteered Yohei >>>>>>> > > > > to >>>>>>> > > > design >>>>>>> > > > > the camera interface so it doesn't look like a deranged >>>>>>> > > > > coffee fuelled monster designed it. Thanks Yohei! >>>>>>> > > > > >>>>>>> > > > > Simon Mac Donald >>>>>>> > > > > http://hi.im/simonmacdonald >>>>>>> > > > >>>>>>> > > >>>>>>> > >>>>>> >>>>>>