Мне нужна помощь, у меня есть этот метод для получения BitmapImage из байта []
public BitmapSource ByteToBitmapSource(byte[] image)
{
BitmapImage imageSource = new BitmapImage();
using (MemoryStream stream = new MemoryStream(image))
{
stream.Seek(0, SeekOrigin.Begin);
imageSource.BeginInit();
imageSource.StreamSource = stream;
imageSource.CacheOption = BitmapCacheOption.OnLoad;
imageSource.EndInit();
}
return imageSource;
}
imageSource.EndInit();
выдает сообщение об ошибке "Мы не нашли компонент изображения, подходящий для завершения этой операции".