PictureType

<< Click to Display Table of Contents >>

Navigation:  Picture Functions >

PictureType

Previous pageReturn to chapter overviewNext page

By default, VPE determines the type of an image that shall be imported or exported by its filename extension. If PictureType is other than PIC_TYPE_AUTO (the default = determining the file-type by its extension), the extension will be ignored and VPE is forced to use the specified file type.

If PIC_TYPE_AUTO is used for import, VPE is able to determine the image type not only by looking at the file suffix, but also by examining the file itself. So PIC_TYPE_AUTO will work in most cases even if the file suffix does not describe the image type. Example: you try to import a JPEG image with the name "test.001" and have set PictureType = PIC_TYPE_AUTO, even then VPE will detect that this is a JPEG file!

This property applies to image-file import and export.

property PictureType [long] VPE.PictureType

read / write; runtime only; also supported by TVPEObject

Possible Values:

ActiveX / VCL

Value

Enum

Comment

PIC_TYPE_AUTO

255

Auto

Automatic determination by filename-suffix (default)

PIC_TYPE_BMP

0

BMP

Windows-Bitmap

PIC_TYPE_WMF

5

WMF

WMF

PIC_TYPE_EMF        

6

EMF

EMF

PIC_TYPE_TIFF

64

TIFF

TIFF-File

PIC_TYPE_GIF

65

GIF

GIF-File

PIC_TYPE_PCX

66

PCX

PCX-File

PIC_TYPE_JPEG

68

JPEG

JPEG-File

PIC_TYPE_PNG

69

PNG

PNG (Portable Network Graphic)

PIC_TYPE_ICO

70

ICO

ICO (Windows Icon)

PIC_TYPE_JNG

71

JNG

JNG (JPEG Network Graphics)

PIC_TYPE_KOALA

72

KOALA

KOA (C64 Koala Graphics)

PIC_TYPE_IFF

73

IFF

IFF/LBM (Interchangeable File Format - Amiga/Deluxe Paint)

PIC_TYPE_MNG

74

MNG

MNG (Multiple-Image Network Graphics)

PIC_TYPE_PBM

75

PBM

PBM (Portable Bitmap [ASCII])

PIC_TYPE_PBM_RAW

76

PBM_RAW

PBM (Portable Bitmap [RAW])

PIC_TYPE_PCD

77

PCD

PCD (Kodak PhotoCD)

PIC_TYPE_PGM

78

PGM

PGM (Portable Greymap [ASCII])

PIC_TYPE_PGM_RAW

79

PGM_RAW

PGM (Portable Greymap [RAW])

PIC_TYPE_PPM

80

PPM

PPM (Portable Pixelmap [ASCII])

PIC_TYPE_PPM_RAW

81

PPM_RAW

PPM (Portable Pixelmap [RAW])

PIC_TYPE_RAS

82

RAS

RAS (Sun Raster Image)

PIC_TYPE_TARGA

83

TARGA

TGA/TARGA (Truevision Targa)

PIC_TYPE_WBMP

84

WBMP

WAP/WBMP/WBM (Wireless Bitmap)

PIC_TYPE_PSD

85

PSD

PSD (Adobe Photoshop)

PIC_TYPE_CUT

86

CUT

CUT (Dr. Halo)

PIC_TYPE_XBM

87

XBM

XBM (X11 Bitmap Format)

PIC_TYPE_XPM

88

XPM

XPM (X11 Pixmap Format)

PIC_TYPE_DDS

89

DDS

DDS (DirectX Surface)

PIC_TYPE_HDR

90

HDR

HDR (High Dynamic Range Image)

PIC_TYPE_FAX_G3

91

FAX_G3

G3  (Raw fax format CCITT G.3)

PIC_TYPE_SGI

92

SGI

SGI (SGI Image Format)

 

Default:

PIC_TYPE_AUTO

Remarks:

Setting this property for a VPE Object  that resides in a document can have unpredictable results. In contrast you may set this property for a VPE Object that resides in a template without problems, if the file name contains at least one field.

 

We recommend to set this flag to PIC_TYPE_AUTO always.

Example:

ActiveX / VCL:

Doc.PictureType = PIC_TYPE_TIFF

Doc.Picture(1, 1, VFREE, VFREE, "image.001")

Will import "image.001" as TIFF file.

 

.NET:

Doc.PictureType = PictureType.TIFF

Doc.Picture(1, 1, Doc.nFree, Doc.nFree, "image.001")

Will import "image.001" as TIFF file.

 

See also:

"Pictures" in the Programmer's Manual