This is a simple class that can generate a thumbnail graphic of a given image.
The class generates a thumbnail graphic that keeps the proportion of original image and at the same time neither the width nor the height do not exceed a given size.
The class reads the original image using a given file name. It detects the image type checking the file name extension. It supports either GIF, JPEG and PNG formats.
The thumbnail image is stored in another file given its file name. The output image format is also determined from the output file name extension. The supported output formats are the same. |