Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


ID: 17467, TThumbnail 3.2 creates a thumbnail from any bitmap, JPEG, GIF, P

by David Simpson Email: Anonymous


TThumbnail creates a thumbnail from a bitmap, JPEG, GIF, PNG, icon or metafile.
Download Details
FTP  download also available
CDN Login Required to Download. (You will be redirected to the login page if you click on the Download Link)
To download this, you must have registered:
A free membership

For Delphi, Version 5.0  to 6.0 2240 downloads
Copyright: No significant restrictions


Size: 11,600 bytes
Updated on Sun, 30 Mar 2003 13:33:11 GMT
Originally uploaded on Fri, 25 Jan 2002 05:26:14 GMT
SHA1 Hash: 06404B36A5F061B90DF85A8776AA4BA660DC7C4A
MD5 Hash: 384E2457207D531AB872D6AF3ECC9CCB

    Explore the files in this upload

Description
TThumbnail creates a thumbnail from a bitmap, JPEG, GIF, PNG, icon or metafile. The image may be assigned from a TBitmap, TJPEGImage, TGIFImage, TPNGObject, TIcon, TMetafile or TPicture, or the file name passed as a parameter to Execute.

It creates one of three kinds of thumbnails:

1: a thumbnail which maintains the original image's aspect ratio;
2: a thumbnail which stretches to MaxHeight and MaxWidth;
3: a thumbnail which maintains the original image's aspect ratio on a coloured background stretched to MaxHeight and MaxWidth.

If there is an exception then an error thumbnail consisting of a white background with a diagonal red cross is created instead.

The thumbnail is returned as a TBitmap but may be saved to file in any of the supported formats.

It would be used something like this:

JPEGImage.LoadFromFile(aFileName);
Thumbnail.Assign(JPEGImage);
if Thumbnail.Execute then
Image.Picture.Assign(Thumbnail.Bitmap);

TThumbnail 2.0 was developed and tested in D6 Pro. It should work in D5 also. It is a significant improvement on 1.3. It is more memory efficient because it no longer uses one of each type of Graphics object and output quality is significantly improved because it uses the JEDI VCL (Jcl) Stretch procedure when resizing rather than StretchDraw (although the downside is that Stretch seems subjectively slower than StretchDraw). This means TThumbnail is now suitable as a general purpose image resizing tool rather than as just a generator of low quality thumbnails.

DEPENDENCIES:

Note: this object uses
1: Anders Melander's TGIFImage, which can be
downloaded from http://www.melander.dk/delphi/gifimage/index.html.
2: Gustavo Daud's TPNGObject, which can be
downloaded from http://pngdelphi.sourceforge.net/.
3: JEDI VCL (tested with v1.21), which can be
downloaded from http://jcl.sourceforge.net/

   Latest Comments  View All Add New

Move mouse over comment to see the full text
Reply  Posted by Kevin Jesshope on Feb 12 2002
re: TThumbnail 1.2 creates a thumbnail from any bitmap, JPEG, GIF, i
Reply  Posted by John Kaster on Feb 12 2002
TThumbnail 1.2 creates a thumbnail from any bitmap, JPEG, GIF, i

Server Response from: ETNACDC03