예제 #1
0
        public static ImageSource GetImageSource(this Image image)
        {
            var prepared = image.PrepareImageLoad();

            return(new StreamImageSource
            {
                Stream = async token => new MemoryStream(await prepared.GetDataAsync() ?? BackupData.BackupImageData)
            });
        }
예제 #2
0
        public static ImageSource GetImageSource(this Image image)
        {
            var data = image.Data;

            return(ImageSource.FromStream(() => new MemoryStream(data)));
        }