[Kde-silk] [Draft]PictureProvider DataEngine
Onur - Hayri Bakici
thehayro at gmail.com
Fri Oct 16 01:16:15 CEST 2009
Hi,
i started to plan the pictureprovider DataEngine class.
since flickr has a complete different api-structure than picasa i had the idea
to make two packages: PicturePackage and AlbumPackage.
The reason: with picasa, every picture is in at least one album. so if we are
searching for pictures in picasa, we also get information in which album they
belong. In flickr it is not that way. pictures in flickr do not necessarily
belong to an album. Also, in flickr, to get the whole information about a
picture, we have to call another query. Nevertheless, i think the
picturePackage-struct should have an albumId.
my idea of the packages:
typedef struct {
QString id;
QDate published;
QDate updated;
QString title;
QString link;
uint width;
uint height;
uint size; //necessary?
QString thumbnail;
QStringList tags;
} PicturePackage;
typedef struct {
QString id;
QString title;
QString author;
QList<PicturePackage*> photos;
} AlbumPackage;
In the picasa DataEngine (picasainterface.cpp) is a method listAllAlbums. in
this case the AlbumPackage can be used? What do you think?
I did some research and i found some other Image Host sites such as imageShack, Fotolog, CrunchBase and photoBucket. Of course i bumped into some limits:
* ImageShack has (at first sight) no fuction call to search for pictures, only to upload and manipulate images and albums.
* FotoLog can (as far as i know) only be accessed as a facebook app
* Crunchbase's response method is only in JSON
Photobucket responses in xml, like flickr and picasa.
So anyways, about the queries.
sice some image Host sites also provide videos, i suggest to make the queries like in the videoProvider query.
greetz
greetz
More information about the Kde-silk
mailing list