The Free, Quality Image library for Windows
ActiveX-Library: Freeimage.Application
Design and implementation by
Markus Loibl
(markus.loibl@epost.de)
This file is part of FreeImage 2.6.0
Sample
Option explicit
dim ctrl
dim title
dim text
set ctrl = createObject("FreeImage.Application")
title = ctrl.Version
text = ctrl.Copyright
MsgBox text, 0, title
set ctrl = Nothing
Reference
|
|
Test | Shows a Message-Box (for testing and debugging purposes) |
| in | String | This string appears in the messagebox (message) |
| in | String | This string appears in the messagebox (title) |
|
|
Version | |
| out | String | String with the freeimage-version |
|
|
Copyright | |
| out | String | String with the freeimage-copyright |
|
|
IsValidImage | Checks the extension of the file |
| in | String | filename |
| out | short | -1: not a valid extension (FIF_UNKNOWN) else: the id for the corresponding image-format |
|
|
ShowMessages | |
| get/set | short | This property specifies, if freeimage-messages should be shown in a messagebox (1) or not (0). |
|
|
GetImageType | Checks if the file can be opened by freeimage |
| in | short | 0: Checks only the extension (similar to
IsValidImage) 1: Checks by opening the image (looking for "characteristic bytes" |
| in | String | filename |
| out | short | -1: not a valid image (FIF_UNKNOWN) else: the id for the corresponding image-format |
|
|
SupportsReading | Checks if the image-format supports beeing read. Accessing this property may fail if the specified image-format is invalid. |
| in | short | Image-format to test for. Can be inquired by GetImageType or IsValidImage |
| get | short | 0: This image-format cannot be read 1: Freeimag can read this image-format |
|
|
SupportsWriting | Checks if the image-format supports beeing written. Accessing this property may fail if the specified image-format is invalid. |
| in | short | Image-format to test for. Can be inquired by GetImageType or IsValidImage |
| get | short | 0: This image-format cannot be written 1: Freeimag can write this image-format |
With version 2.5.3 the following image-formats are supported:
(see also features of freeimage)
| Image-format | Description | extensions | loading | saving |
| 0 | Windows or OS/2 Bitmap | bmp | x | x |
| 1 | Windows Icon | ico | x | x |
| 2 | JPEG - JFIF Compliant | jpg,jif,jpeg | x | x |
| 3 | JPEG Network Graphics | jng | x | - |
| 4 | C64 Koala Graphics | koa | x | - |
| 5 | IFF Interleaved Bitmap | iff,lbm | x | - |
| 6 | Multiple Network Graphics | mng | x | - |
| 7 | Portable Bitmap (ASCII) | pbm | x | x |
| 8 | Portable Bitmap (RAW) | pbmraw | x | x |
| 9 | Kodak PhotoCD | pcd | x | - |
| 10 | Zsoft Paintbrush | pcx | x | - |
| 11 | Portable Network Media | pbm,pgm,ppm | x | x |
| 12 | Portable Greymap (RAW) | pgmraw | x | x |
| 13 | Portable Network Graphics | png | x | x |
| 14 | Portable Pixelmap (ASCII) | ppm | x | x |
| 15 | Portable Pixelmap (RAW) | ppmraw | x | x |
| 16 | Sun Raster Image | ras | x | - |
| 17 | Truevision Targa | tga,targa | x | x |
| 18 | Tagged Image File Format | tif,tiff | x | x |
| 19 | Wireless Bitmap | wap,wbmp,wbm | x | x |
| 20 | Adobe Photoshop | psd | x | - |
| 21 | Dr. Halo | cut | x | - |
| 22 | IFF Interleaved Bitmap | iff,lbm | x | - |