From: Carsten H. (T. R. <ra...@ra...> - 2001-10-10 01:14:01
|
On Tue, 09 Oct 2001 15:27:36 -0700 enl...@li... babbled profusely: > Enlightenment CVS committal > > Author : rbdpngn > Project : e17 > Module : libs/imlib2_loaders > > Dir : e17/libs/imlib2_loaders/src > > > Modified Files: > loader_db.c > > > Log Message: > After much hair pulling, fixed a bug in the db loader that affected big endian > systems. > > When saving compressed images, the header was not being byte swapped, but it > was when loading (which is why db's created on little endian systems worked, > but > not ones created and used on the big endian systems). So now the headers are > also swapped to little endian order when saving. OOOOOOOOOOOH1 thanks! i would have never noticed! :) > > =================================================================== > RCS file: /cvsroot/enlightenment/e17/libs/imlib2_loaders/src/loader_db.c,v > retrieving revision 1.1 > retrieving revision 1.2 > diff -u -3 -r1.1 -r1.2 > --- loader_db.c 2001/08/12 14:52:17 1.1 > +++ loader_db.c 2001/10/09 22:27:36 1.2 > @@ -325,7 +325,11 @@ > buflen = ((im->w * im->h * sizeof(DATA32) * 101) / 100) + 12; > #ifdef WORDS_BIGENDIAN > { > + int i; > DATA32 *buf2; > + > + for (i = 0; i < 8; i++) > + SWAP32(header[i]); > > buf2 = malloc((((im->w * im->h * 101) / 100) + 3) * sizeof(DATA32)); > if (buf2) > > > > _______________________________________________ > enlightenment-cvs mailing list > enl...@li... > https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs -- --------------- Codito, ergo sum - "I code, therefore I am" -------------------- The Rasterman (Carsten Haitzler) ra...@ra... Unemployed Bum ra...@de... Mobile Phone: +61 (0)408 363 984 Home Phone: 02 9386 9362 |