Products | Support | Send comments on this topic. | Email a link to this topic. | Back to Getting Started | Help Version 18.0.10.23
LEADTOOLS Vector C++ Class Library Help

LVectorFile::LoadFile

Show in webframe

#include "ltwrappr.h"

virtual L_INT LVectorFile::LoadFile(pLoadOptions=NULL, pFileInfo=NULL)

pLOADFILEOPTION pLoadOptions;

/* pointer to a structure */

pFILEINFO pFileInfo;

/* pointer to a structure */

Loads an image file into the class object's associated vector. The file can be in any supported vector file format.

Parameter

Description

pLoadOptions

Pointer to a LOADFILEOPTION structure that contains information about loading the vector.

pFileInfo

Pointer to a FILEINFO structure. This structure may contain file information used in loading an image, or it may be updated with information about the file being loaded.

 

If nothing is known about the file, pass NULL for this parameter, or declare a variable of type FILEINFO and set the FILEINFO.Flags to 0, then pass the address of the FILEINFO structure in this parameter. In this case, if the address of a FILEINFO structure is passed, the FILEINFO structure will be updated with the results of LFile::GetInfo.

 

If only the file type is known, set pFileInfo.Format to the file type and set pFileInfo.Flags to FILEINFO_ONLYFORMATVALID. This can also be done if LFile::GetInfo has been called previously, but values that affect the size of the image loaded have been changed (for example, by calling LFileSettings::SetPCDResolution or LFileSettings::SetWMFResolution). In this case the FILEINFO structure pointed to by pFileInfo will be updated with the results of LFile::GetInfo

 

If LFile::GetInfo has been called prior to calling this function, and no changes have been made to the contents of the structure filled by LFile::GetInfo, then the address of the filled FILEINFO structure can be passed for this parameter. In this case, the FILEINFO.Flags member should be set to FILEINFO_INFOVALID. The LFile::GetInfo function will set the FILEINFO.Flags to FILEINFO_INFOVALID. In this case the load will be faster since this function does not have to query the file filters for the file type.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

Note: More options are available in the LOADFILEOPTION structure.

For supported formats, refer to Vector Input File Formats.

You should never pass an uninitialized FILEINFO structure to this function.

Required DLLs and Libraries

LVKRN
LTFIL

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

See Also

Functions:

Class Members

Topics:

Vector Images: Loading and Saving Vector Files

 

Vector Loading, Saving and Copying

Example

For an example, refer to LVectorFile::LVectorFile().

Products | Support | Contact Us | Copyright Notices
© 2006-2014 All Rights Reserved. LEAD Technologies, Inc.