Esempio n. 1
0
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            if (value == null)
            {
                return(null);
            }
            var image = (Bitmap)value;

            return(BitmapUtility.Bitmap2BitmapImage(image));
        }
Esempio n. 2
0
 public static BitmapImage ToSource(this Bitmap src)
 {
     return(BitmapUtility.Bitmap2BitmapImage(src));
 }