private ImageSource GetThumbnail() { RasterImage image = Image.CreateThumbnail(200, 200, 24, RasterViewPerspective.BottomLeft, RasterSizeFlags.None); var imageSource = RasterImageConverter.ConvertToSource(image, ConvertToSourceOptions.None); return(imageSource); }
public static IImage ToImage(this RasterImage rasterImage) { var convertToSource = (BitmapSource)RasterImageConverter.ConvertToSource(rasterImage, ConvertToSourceOptions.None); return(convertToSource.ToArray <Bgr <byte> >().Lock()); }