LEADTOOLS For .NET Class Library Send comments on this topic. | Back to Introduction - All Topics | Help Version 17.0.3.28
Interoperation between LEADTOOLS and Windows Presentation Foundation (WPF) images.

The Leadtools.Windows.Media.RasterImageConverter class provides methods to convert a Leadtools.RasterImage object to and from an System.Windows.Media.ImageSource.

The RasterImageConverter.ConvertFrom method will convert a Leadtools.RasterImage object to a WPF System.Windows.Media.ImageSource. The flags in the Leadtools.Windows.Media.ConvertFromSourceOptions enumeration can be used to control the conversion operation.

The RasterImageConverter.ConvertTo method will convert a WPF System.Windows.Media.ImageSource object to a Leadtools.RasterImage. The flags in the Leadtools.Windows.Media.ConvertToSourceOptions enumeration can be used to control the conversion operation.

The conversion works by copying the image data over to the new destination. Currently, there is no support for sharing memory between a Leadtools.RasterImage and an System.Windows.Media.ImageSource.