Hack request: Import Picasa sequencing
System
Registered Users Posts: 8,186 moderator
After I bitched and whined about this long enough (:-), Andy suggested that I post about it over here.
I'm not sure the API exposes enough functionality to get this accomplished -- my skimming of the documentation suggests not -- but it's worth asking.
I use Picasa, and as I mentioned in this thread, I'm trying to find a way to apply the sequencing it maintains to the galleries I then upload to Smug.
I did, finally, find a way to get that sequencing out; it will generate (in its Export To Web function) an XML file, which contains the album description, the photo filenames (in order) and their associated captions (though those are already supposed to also be in the IPTC data).
I've posted a copy of such a file here, for your perusal.
If anyone *can* figure out how to do this from outside, without Smug having to write any code, I suspect they'll make a whole lot of Picasa users very happy. And while perhaps I'm the only one silly enough to try to use it with a Pro account, surely there are lots of people with more basic accounts, for whom it would be good enough... if you didn't have to sequence everything twice.
Thoughts?
I'm not sure the API exposes enough functionality to get this accomplished -- my skimming of the documentation suggests not -- but it's worth asking.
I use Picasa, and as I mentioned in this thread, I'm trying to find a way to apply the sequencing it maintains to the galleries I then upload to Smug.
I did, finally, find a way to get that sequencing out; it will generate (in its Export To Web function) an XML file, which contains the album description, the photo filenames (in order) and their associated captions (though those are already supposed to also be in the IPTC data).
I've posted a copy of such a file here, for your perusal.
If anyone *can* figure out how to do this from outside, without Smug having to write any code, I suspect they'll make a whole lot of Picasa users very happy. And while perhaps I'm the only one silly enough to try to use it with a Pro account, surely there are lots of people with more basic accounts, for whom it would be good enough... if you didn't have to sequence everything twice.
Thoughts?
0
Comments
http://wall-art.smugmug.com/
Hand that to changePosition, and Bob's your uncle.
Anyone got a Smug API program framework in, say, Python I can steal?
set heavy and you'll get the full image info in the array on the first get call, saving you an order n loop ping ponging with the server to get the details.
good start. I would first iterating through the images and setting their position += round(number of images). Basically move them all up out of the way in whatever order they are in now, then bring them back down in the order you want them. I'm not sure if that's *needed* or not.... would likely depend on how the api reacts if you have images 1-5 and you try to insert another 1 (that used to be, say, 42)... do you get two 1s? does the former 1 become 2? (and so forth up the line until there is a gap?)
I have one started in objective c... but it's not moving very fast at all. :cry
http://wall-art.smugmug.com/
Rutt wrote a version sometime ago on an older version of the api, before some of the easier API methods (REST, PHP, JSON) were available. If you can't find his script, perhaps send him a PM.
SmugMug API Developer
My Photos
I haven't looked at it in detail yet, but that sounds like nearly exactly what I want, yes.
If Rutt is still around, I'd love to kibitz with him on updating his code to 1.1.1, and adding in the Picasa reposition functionality.
I was all set to say "good point" here, until I tried to explain what I didn't understand, and realized it was immaterial. :-)
Our handle on the thing-to-be-moved isn't a position, it's an ImageID, so it won't change.
Therefore, we just line up all the imageIDs in *our idea of* The Right Sequence, and then we iterate over i=1...max, changePosition'ing ImageID to position I.
And we're done; no semantic messes.
Oh! Duh. Yeah, iterate by new position, not image id.
http://wall-art.smugmug.com/