facebook

How to take picture and save it to local dtb

💡
Our Forums Have Moved

For help with installation, bugs reports or feature requests, please head over to our new forums.
Genuitec Community on GitHub

  1. MobiOne Archive
  2.  > 
  3. Getting Help – General
Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #331797 Reply

    Max87
    Member

    Hello guys,
    I’m trying to take picture and store it’s location using phonegap.
    The problem is, that captured photos is stored at Temp directory, which deletes sometimes.
    My question is, how can I copy/move my captured photos into Document/Photos folder(I can create Photos folder via Phonegap Directory API).
    Thank you for any help.
    Max87

    #331803

    support-michael
    Keymaster

    Hi Max,

    >My question is, how can I copy/move my captured photos into Document/Photos folder(I can create Photos folder via Phonegap Directory API).

    Based on your info are you looking for the process to save a captured image (photo) to a specific path? That is you already have the dir created?

    #331804

    Max87
    Member

    Hi Wayne,
    yes, that’s I’m trying to do. Problem is, when I capture a photo, it saves in app’s Temp directoy, which can be deleted by iOS – so my photos are gone. So I’m trying to capture photo and move it to new folder in my app’s Documents, which cannot be deleted automatically(and can be backed up to iCloud btw).
    Thanks

    #331879

    support-michael
    Keymaster

    @Max87

    We are discussing with the dev team.

    1) are you effectively creating another photo gallery (may app specific gallery)?

    2) have you looked at the phonegap FileEntry api for moving or copying a file?
    MobiOne 2.2.x uses the apache cordova/phonegap 1.1 apis:
    http://docs.phonegap.com/en/1.1.0/

    #331880

    Max87
    Member

    Hi Wayne,
    1. I don’t understand what you mean. I can take pictures from camera, save it into temporary folder and retrieve ImageURI(full path).
    2. Yes, I looked at the FileEntry API, but I don’t know how to use it. I found this solution – http://stackoverflow.com/questions/10335563/capturing-and-storing-a-picture-taken-with-the-camera-into-a-local-database-ph

    but it’s not working for me – if I save image as base64-encoded string, movepic function is not called/working.
    The only thing I can do is, that i take picture, retrieve its full path, the image is saved into Temp directory. Also, I can create custom folders into Documents. But I need help how to use that FileEntry API, so I can move my photos into new directory.
    I can send you my project if it helps.
    Thank you

    #332056

    support-michael
    Keymaster

    @Max87

    We have not had time to develop an example for your scenario. We have been working on an Cordova/PhoneGap update to provide access to latest features. More details coming soon.

    #332388

    Max87
    Member

    Hi Wayne,
    have you had time to look at my problem?
    Thanks

    #332406

    Hi Max,

    We’ve kicked this to a dev team member and not much progress made yet. I will nag the developer and provide feedback.

    #332407

    Max87
    Member

    Thanks Octavio for response.

    #332408
    #332409

    Max87
    Member

    Hi Octavio,
    I found the first linked article too, but i wasn’t able to make it work for me…First part – taking picture – is fine, but second part – renaming file and move it to another directory causes problems – I call that function, but nothing happens(I check via iPhone browser).
    Can you please try this sample code and write a tutorial?
    Thank you.

Viewing 11 posts - 1 through 11 (of 11 total)
Reply To: How to take picture and save it to local dtb

You must be logged in to post in the forum log in