You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hmm, I wasn't able to replicate this behavior with a simple test. I saved your second image as "C:\Temp\test-image.png", loaded it as a \psi Image, and called ToBitmap in both ways.
There still might be a bug in ToBitmap if something is screwed up with stride or pixel format, but I think I would have to see more of your code showing how the Shared<Image> stream gets created that is being passed to your Receive method.
After troubleshooting together, we found out that the incorrect behavior happens in linux only and not in windows (mac is untested). The sample code that @sandrist wrote leads to reproducible behavior in linux machine.
When
var bmp = message.Data.Resource.ToBitmap(false);
I get this imageWhen I change the Boolean
using var bmp = message.Data.Resource.ToBitmap(true);
I get this image.Not sure if this is a bug or not.
The text was updated successfully, but these errors were encountered: