Loading File Filters

Some operating systems (like Windows 95) have a limit for the number of DLLs that can be loaded at a time and that limit can be quickly reached, especially if there are several other third party libraries loading DLLs, or if the programming environments themselves load many DLLs. By default, LEADTOOLS loads several fixed filters and several cached filters. The fixed filters are FAX, CMP, TIF, JBG, LMB, BMP and PCX.

Use the following function to specify the file format filters you want LEADTOOLS to load:

LFileSettings::PreLoadFilters

Call LFileSettings::GetPreLoadFilters to determine the current list of filters that LEADTOOLS should load. If LFileSettings::GetPreLoadFilters is called before LFileSettings::PreLoadFilters has ever been called, then LFileSettings::GetPreLoadFilters will retrieve the list of default filters.

Use the following function to specify the file format filters LEADTOOLS should never load:

LFileSettings::IgnoreFilters

Call LFileSettings::GetIgnoreFilters to determine the current list of file format filters LEADTOOLS does not load. If LFileSettings::GetIgnoreFilters is called before LFileSettings::IgnoreFilters has ever been called in an application, then the list retrieved by LFileSettings::GetIgnoreFilters will be empty.

It is important to note that LFileSettings::PreLoadFilters must be called prior to loading, saving or getting information on a file. In addition, LFileSettings::PreLoadFilters must be called before calling LFileSettings::IgnoreFilters for LFileSettings::IgnoreFilters to work properly.

 

Also, you can use LBase::LoadLibraries to control the LEADTOOLS DLLs that your application loads into memory.