L_CanLoadSvg

#include "l_bitmap.h"

L_LTFIL_API L_INT L_CanLoadSvg(pszFile, pbSupported, pLoadOptions)

L_TCHAR* pszFile; file name
L_BOOL* pbSupported; pointer to variable to be updated
pLOADFILEOPTION pLoadOptions; pointer to optional extended load options

Determines whether the specified image, document or vector file can be loaded as an SVG file.

Parameter Description
pszFile Character string containing the name of the image file to load.
pbSupported Pointer to a variable to be updated. TRUE if the specified image, document or vector file can be loaded as SVG; otherwise, FALSE.
pLoadOptions Pointer to optional extended load options. Pass NULL to use the default load options.

Returns

SUCCESS The function was successful.
< 1 An error occurred. Refer to Return Codes.

Comments

Use this function to determine whether the specified image, document or vector file supports being loaded as an SVG (Scalable Vector Graphics) file. The following conditions must be met in order to load a page from a file as SVG:

Condition Description
The file format is SVG SVG can be loaded as SVG
The file format is document Any of the document file formats supported by LEADTOOLS such as DOC/DOCX, PPT/PPTX, XLS/XLSX, RTF, TXT, AFP, ICA, etc. These formats will set the FILEINFO.bIsDocFile member to TRUE when calling L_FileInfo.
The file format is vector Any of the vector file formats supported by LEADTOOLS such as DXF, DWG, etc. These formats will set the FILEINFO.bIsVectorFile member to TRUE when calling L_FileInfo.
The file format is PDF And the PDF file contains more than pure raster data (for example, not scanned PDF file).

In addition to LTFIL, the following additional DLLs may be required to support loading as SVG:

DLL Description
LTSVG SVG support. Always required.
LVKRN Required if the input document is a vector file.
LTPDF Required if the input document is a PDF file.

Note: More options are available in the LOADFILEOPTION structure.

Support for loading SVG is only available in the Document and Medical Imaging toolkits.

Required DLLs and Libraries

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

Platforms

Win32, x64, Linux.

See Also

Functions: L_CanLoadSvg2, L_LoadSvg, L_LoadSvg2, L_LoadBitmap, L_SetRasterizeDocOptions
Topics: Raster Image Functions: Loading Files
Raster Image Functions: Redirecting Input and Output
Loading and Saving Images
Working With SVG
SVG Size, Bounds and Flat
SVG Rendering

Example

For an example, refer to L_LoadSvg.

Help Version 20.0.2019.3.12
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2019 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS SVG C API Help