Am Mittwoch, 9. April 2008 22:05:37 schrieb Sven Neumann:
> Hi,
> On Wed, 2008-04-09 at 09:27 +0930, David Gowers wrote:
> > What you are talking about is a hash function. There is a string
> > hasher in GLib that should do what you want.
> The string hash function in GLib is not suitable for this job. Torsten
> doesn't want to hash a string, he is asking for a checksum over image
> data.
> You can use GChecksum which was added recently to GLib or you can use
> the MD5 implementation in libgimpmath.

Unfortunately, I'm stuck with GLib 2.14 at the moment and the GChecksum is 
available from 2.16 on only.

Regarding the MD5 implementation in limbgimpmath, it would have been nice if I 
could use it, but I cannot as I have to produce an MD5 on the whole drawable, 
which means that I whould have to run gimp_md5_update() on every tile.
Yet, gimp_md5_init(), gimp_md5_update(), and gimp_md5_final() are declared as 
static (why ?), so I will have to use something else.

For now, I will therefore use the OpenSSL implementation of MD5 (also, why 
isn't limbgimpmath reusing the OpenSSL code for that purpose ?   Just a 
curious question...).


InWise    -     Wirtschaftlich-Wissenschaftlicher Internet Service GmbH
Waldhofstraße 14                                   Tel: +49-4101-403605
D-25474 Ellerbek                                   Fax: +49-4101-403606
E-Mail: [EMAIL PROTECTED]                   Internet:

Handelsregistereintrag:       HR B 2277      -    Amtsgericht Pinneberg
Geschäftsführung:                    Jan Michael Kraeber, Torsten Neuer
Steuer-Nr.: 182 910 1130                        VAT-Nr.: DE 134 782 712

Attachment: signature.asc
Description: This is a digitally signed message part.

Gimp-developer mailing list

Reply via email to