ImageGear for Silverlight
Assembly Initialization
Send Feedback
ImageGear for Silverlight User Guide > Using ImageGear for Silverlight > Using Multiple Assemblies > Assembly Initialization

Glossary Item Box

The following ImageGear assemblies require explicit initialization at application startup:

Assembly Initialization Method
ImageGear20.Formats.Advanced.dll  ImGearAdvancedFormats.Initialize Method
ImageGear20.Formats.CameraRaw.dll  ImGearCameraRawFormats.Initialize Method
ImageGear20.Formats.Common.dll  ImGearCommonFormats.Initialize Method
ImageGear20.Formats.SimplifiedMetadata.dll ImGearSimplifiedMetadata.Initialize Method

The order in which format filter assemblies are initialized is important, because it defines format detection priority.

CameraRaw formats should be initialized before Common formats, because many camera raw formats use custom versions of TIFF. If the application initializes Common formats before Camera Raw formats, ImageGear can incorrectly detect camera raw files as TIFF. Advanced formats will usually be initialized last, to allow for faster detection of Camera Raw and Common formats.

The following initialization order is recommended:

C# Copy Code
ImGearCameraRawFormats.Initialize();
ImGearCommonFormats.Initialize();
ImGearAdvancedFormats.Initialize();

CUT format (supported in ImageGear20.Formats.Advanced assembly) doesn't have a specific signature in the file's header, which makes its detection less reliable. Detection of this format in ImageGear is disabled by default.

Headerless Camera Raw format (supported in ImageGear20.Formats.CameraRaw assembly) doesn't have a file header, which makes its detection less reliable. Detection of this format in ImageGear is disabled by default.

If you enable detection of these formats, it is recommended that you move them to the end of the global formats list, as follows:

C# Copy Code
IImGearFormat headerlessRawFormat = ImGearFileFormats.Filters.Get(ImGearFormats.HeaderlessRaw); 
ImGearFileFormats.Filters.Remove(ImGearFormats.HeaderlessRaw); 
ImGearFileFormats.Filters.Add(headerlessRawFormat); 

The order in which ImageGear20.Formats.SimplifiedMetadata assembly is initialized in relation to other assemblies is not important. 

©2013. Accusoft Corporation. All Rights Reserved.