Tuesday, January 25, 2005

TDBImage and JPEG files

It's been a while. Well, I've no time to explain, so here's a tip. If you were looking to support JPEGs in TDBImage, you're out of luck, because it only supports BMPs (or so I think). I found out that TJvDBImage from jvcl.sourceforge.net supports JPEG images...but there's a catch. There are two kinds of JPEG images, JFIF and Exif. (Exifs are usually output by digital cameras)

Now if you want Exif support, the standard TJpegImage supports it - but TJvDBImage does not. To fix, add the following line in the GraphicSignaturesNeeded procedure:

RegisterGraphicSignature('Exif', 6 , TJPEGImage);

That's about all you need.

0 Comments:

Post a Comment

<< Home