GetImagePage

#include ”faxclass.h”

#include ”faxbft.h”

virtual int  GetImagePage(            int            PageNum,
TEImageType       Type,
TUFaxImage far   &aImage,
BOOL    Append)

Class 1.

Class 2.

Class 2.0

Brooktrout

 

GammaLink

 

Dialogic

 

NMS

 

g

g

g

g

g

g

Description

This function is called when a new page is received. The Type parameter specifies the type of the image and aImage contains the global memory handle or name of the image file. The global memory can contain either a CCITT encoded raw image or Windows device dependent or independent bitmap. The types of the image page can be:

 

IMT_NOTHING                    Bad image type for every device or incompatible TIFF format only for Gammalink.

IMT_MEM_DIRECT            Memory handle to raw data.

IMT_MEM_BITMAP            Memory handle to a device dependent bitmap.

IMT_MEM_DIB                    Memory handle to a device independent bitmap.

IMT_FILE_DIRECT            The data in a  file.

IMT_FILE_BMP                   The image is given as a Windows bitmap file.

IMT_FILE_PCX                   The image is given as a PCX file

IMT_FILE_DCX                   The image is given as a DCX file.

IMT_FILE_TIFF_NOCOMP         The image is given as an uncompressed TIFF file.

IMT_FILE_TIFF_PACKBITS      The image is given as a TIFF file with pack bits compression.

IMT_FILE_TIFF_LZW        The image is given as a TIFF file with LZW compression.

IMT_FILE_TIFF_LZDIFF   The image is given as a TIFF file with differential LZW compression.

IMT_FILE_TIFF_G31DNOEOL  The image is given as a TIFF file with Group 3 one-dimensional NoEol compression..

IMT_FILE_TIFF_G31D      The image is given as a TIFF file with Group 2 one-dimensional.

IMT_FILE_TIFF_G32D      The image is given as a TIFF file with Group 3 two-dimensional compression..

IMT_FILE_TIFF_G4            The image is given as a TIFF file with G4 compression.

IMT_FILE_GIF                     The image is given as a GIF file.

IMT_FILE_TGA                   The image is given as a TGA file.

IMT_FILE_CLS                    The image is given as a CALS file.

IMT_FILE_JPEG                 The image is given as a JPEG file.

IMT_BFTOBJ                      The page is a BFT page. The PageImage -> BftObj member must point to a valid TCBinaryParam object.

This function loads the specified page of a fax, decompresses  it and stores it in the specified format by the Type. If Type is IMT_MEM_DIRECT or IMT_FILE_DIRECT the decompression procedure is not performed.

Parameters

int

PageNum

Zero based page number.

TEImageType

Type

Type of image.

TUFaxImage far

&aImage

Contains the memory handle or file name of the image.

BOOL

Append

If  TRUE, the image will be appended to the file, otherwise the file will be created or truncated.

Return Value

Returns the line number of the page if Type is IMT_MEM_DIRECT or IMT_FILE_DIRECT  on success, otherwise returns an error code.

Sample Code

None at present.