Hello,
Welcome to Microsoft Q&A.
Please try the following code as an approach:
private async void DisplayBytes(byte[] array)
{
var writeableBitmapSource = new WriteableBitmap((int)c_OriginalWidth, (int)c_OriginalHeight);
using (Stream stream = writeableBitmapSource.PixelBuffer.AsStream())
{
await stream.WriteAsync(array, 0, array.Length);
}
ImageBrush localbrush = new ImageBrush
{
ImageSource = writeableBitmapSource,
Stretch = Stretch.Uniform
};
ImagePanelTarget.Background = localbrush;
}
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.