我只是做一个简单的工作:将位图转换为数组,然后使用该数组,使用BitmapSource.Create方法重新创建位图。 但是,我收到错误:“价值不符合预期范围”。这是我的代码。 Dim width As Integer = bitmapImage.PixelWidth
Dim height As Integer = bitmapImage.PixelHeight
Dim
我从BitmapSource加载BitmapImage,我总是发现BitmapImage的格式是Bgr32,而不是BitmapSource是Bgra32。这里有一个类似的线程: BitmapImage from file PixelFormat is always bgr32 但使用BitmapCreateOptions.PreservePixelFormat不适用于我在线程中所建议的。这里是我在