Write a script/app to move photos to camera roll?

Discussion in 'iPad Hacking' started by jsherk, Apr 29, 2011.

  1. jsherk
    Offline

    jsherk iPF Novice

    Joined:
    Apr 19, 2011
    Messages:
    78
    Thanks Received:
    1
    Trophy Points:
    0
    Ratings:
    +1 / 0
    Hi

    Is there anybody that can write a script that would look for images in a pre-defined folder, and then move them to the camera roll of the Photos app?

    Basically the only options would be:
    Location = the folder where the photos are stored.
    Move or Copy = should they just be copied to the camera roll and originals left in folder, or should originals be deleted after being copied to camera roll.

    It would be nice if the options were on the Settings screen, so that one tap on home page icon would start the app, it would move/copy photos and then shut itself back down with no other intervention required.

    And one additional feature would be that when it looks for photos in the specified folder, if it finds sub-folders that those sub-folders would create new albums in Photos app.

    If anybody is interested, please let me know what you would charge to develop this.

    Thanks
  2. incapete
    Offline

    incapete iPad Fan

    Joined:
    Apr 25, 2011
    Messages:
    109
    Thanks Received:
    0
    Trophy Points:
    0
    Ratings:
    +0 / 0
    I could do it on the pc in a few minutes...I've already got one that scans for films recorded in media centre then moves them somewhere else.
    No idea about running it on an ipad though!
  3. graywolf
    Offline

    graywolf iPad Super Guru

    Joined:
    Aug 22, 2010
    Messages:
    3,652
    Thanks Received:
    35
    Trophy Points:
    0
    Location:
    Raleigh, NC USA
    Ratings:
    +35 / 0
    You can just download ifile from Cydia and then navigate to your pics and tap the blue arrow next to the pic and scroll down the window that pops up and then tap "add to camera roll". That's what I use. But, I cant do anything about albums. I know there is an app in the app store that does albums, but it is like $5.00.
  4. jsherk
    Offline

    jsherk iPF Novice

    Joined:
    Apr 19, 2011
    Messages:
    78
    Thanks Received:
    1
    Trophy Points:
    0
    Ratings:
    +1 / 0
    Yes, I have iFile already, and I can do that one pic at a time, but it takes a few taps to transfer each pic.

    What I want to accomplish is a simple one-tap solution to bulk transfer all pics to camera roll at once. I would predefine the directory, and then I can drop all my hundreds of pics into that directory via WinSCP, and then go to iPad and simply tap once on my "Camera Roll Import Utility", wait a few moments and it's done!
    Last edited: Apr 29, 2011
  5. graywolf
    Offline

    graywolf iPad Super Guru

    Joined:
    Aug 22, 2010
    Messages:
    3,652
    Thanks Received:
    35
    Trophy Points:
    0
    Location:
    Raleigh, NC USA
    Ratings:
    +35 / 0
    That would be great! Let's wait for others to chime in and add on.
  6. jsherk
    Offline

    jsherk iPF Novice

    Joined:
    Apr 19, 2011
    Messages:
    78
    Thanks Received:
    1
    Trophy Points:
    0
    Ratings:
    +1 / 0
    SOLVED (sort of)...

    If you drop pics into the /mobile/Media/DCIM/100APPLE folder (or 200APPLE or 300APPLE etc), Photos app will not recognize them. There does not appear to be a script based method to 'add pics to camera roll' that I can find, without writing something that would modify the Photos app sqlite database. I found one post that was accessing sqlite database on an iPhone from bash script, so I am assuming it is theoretically possible on iPad but do not know how to do it myself.

    So here is my solution that works for my purposes...
    #1- Using WinSCP from my PC, I connect to iPad over WiFi (via OpenSSH).
    #2- I copy all my pics I want to transfer into /mobile/Media/DCIM/100APPLE folder. The pic names do not matter, meaning they not have be in IMG_1234.JPG format.
    #3- I delete the two sqlite database files in the PhotosData folder: this file /mobile/Media/PhotoData/Photos.sqlite and this file /mobile/Media/PhotoData/PhotosAux.sqlite
    #4- I kill the Photo app process from either the multitasking bar or from command line.
    #5- Restart the Photos app and it will rebuild the database and add all the pics it finds in the 100APPLE folder and they will now appear in the camera roll!

    WARNING:
    Deleting the sqlite database files will cause you to lose any custom data that is in them. For example, if you use PhotoAlbum+, all your album/folders data will be deleted (but not the pics themselves). The other issue you might see, is that pics you already had in the Photos app camera roll will be re-ordered differently.

    So this is not a perfect solution, but it will work for me and what I need to do!

    Here are some of the helpful links I found related to this issue:
    george-graphics.co.uk » Fixing the iPhone’s photo library
    Adding Pictures to Camera Roll (NOTE: This did not work on iPad)
    Custom script launched via icon or SBsettings toggle?
    Springboard Icon to Run Script?

    Hope this helps someboady!
    Last edited: May 2, 2011
  7. DontUnderstandMyIpad
    Offline

    DontUnderstandMyIpad iPad Guru

    Joined:
    Jan 22, 2011
    Messages:
    3,193
    Thanks Received:
    13
    Trophy Points:
    0
    Location:
    Outside my iPad, or was it inside?
    Ratings:
    +13 / 0
    Well, that sounds like a solution.

    And you can probably use ifile instead of WinSCP for step 1 and 2.
  8. jsherk
    Offline

    jsherk iPF Novice

    Joined:
    Apr 19, 2011
    Messages:
    78
    Thanks Received:
    1
    Trophy Points:
    0
    Ratings:
    +1 / 0
    The iPad is really my wife's and I want to access it directly from my PC so I don't actually have to go to the iPad at all to do any of this (I do have iFile installed though)! I am already working with WinSCP all day long anyways, and when we get a few hundred pics on our camera, I can just download them from the camera onto my PC like I always did before, and then transfer them over, and tell her "ok, you have them now" without ever actually having to touch the iPad.

    On a side note, I have always been a PC fan... started learning BASIC on Commodore 64 and then have had a PC ever since they came out in the 80's with DOS. I have never really had any interest in anything Apple at all, and never even used any kind of Apple or Mac device before. My step father is in his mid 60's and has never used a computer before. Somebody bought him an iPad 1, and within 2 weeks he was using it to check and send emails and read the news. This is the first time I have ever touched any Apple device, and I was very impressed, and since my wife was always "borrowing" my computer to check her emails and facebook, I decided this might the perfect device for her. She loves it, and I am extremely impressed by it as well!

    Anyways, back to the topic at hand... my solution works perfect for me!

    I would like to see PhotoAlbums+ or iFile add some kind of "Batch Camera Roll Import Utility", which would be a much nicer solution, but until that happens, this will have to do!

    Thanks for everybody's help and suggestions.
  9. refrainer
    Offline

    refrainer iPF Novice

    Joined:
    Apr 26, 2011
    Messages:
    43
    Thanks Received:
    0
    Trophy Points:
    0
    Ratings:
    +0 / 0
    ill put this on my stickies. Its a great isolution, at least can use ifile to copy all the images on the folder and just delete the sql files on it and let the photo app rebuild it later.
  10. refrainer
    Offline

    refrainer iPF Novice

    Joined:
    Apr 26, 2011
    Messages:
    43
    Thanks Received:
    0
    Trophy Points:
    0
    Ratings:
    +0 / 0
    I tried this technique to add multiple files on the camera roll, it seems to work only with jpg files with intact exif files. All my jpg that has been modified or created were ignored by the rebuilt. wish ifile has multiple add to camera roll option.
  11. jsherk
    Offline

    jsherk iPF Novice

    Joined:
    Apr 19, 2011
    Messages:
    78
    Thanks Received:
    1
    Trophy Points:
    0
    Ratings:
    +1 / 0
    I would be lying if I even knew what exif was!

    You should contact iFile developer and make a "Feature Request".
    ifile [at] iphone.heinelt.eu

Share This Page

Search tags for this page
add new images ifile
,
canmera awesome transfer all photos on ipad to camera rool
,
date pictures on camara roll
,
how do u write on a picture what it is for photos in camera roll
,

how to import image from ifile into camera roll

,
how to move photos to different places using ifile
,

ifile add all to camera roll

,
ifile export batch to camera roll
,

ifile import picture to camera roll

,

ifile import to camera roll

,

ifile mass add to camera roll

,
import multiple images through ifile
,
import photo to ipad with ifile
,
import pictures ifile
,
ipad 100apple 200apple photos
,

move photos to camera roll ifile

,
moving pics from ifile to camera roll
,
photos folder from ifile to camera roll
,
script move photos camera roll
,

write camera roll