Re: md5_sum column - Developing command line tool for F-Spot
- From: Johan Zaxmy <johan zaxmy com>
- To: Robin Clarke <robin robinclarke net>
- Cc: f-spot-list gnome org
- Subject: Re: md5_sum column - Developing command line tool for F-Spot
- Date: Sun, 30 May 2010 22:39:52 +0200
sön 2010-05-30 klockan 19:52 +0200 skrev Robin Clarke:
> My problem: To search local files and identify whether they are in the
> database yet, I want to create the md5 hash, and search the database for
> this hash. Problem is that the md5 hash I generate for a known image
> doesn't come out the same as the one in the database. I've heard that
> it is just the image data which is used (without the meta data), but if
> someone has some more specific information, that would be very helpful.
hmm you will problary need this also (ThumbnailGenerator)
public static Gdk.Pixbuf Create (SafeUri uri)
{
try {
Gdk.Pixbuf thumb;
using (ImageFile img = ImageFile.Create (uri)) {
thumb = img.Load (256, 256);
}
if (thumb == null)
return null;
Save (thumb, uri);
return thumb;
} catch (Exception e) {
Log.Exception (e);
return null;
}
}
regards
Johan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]