スキャンに twain_32 を twainLib.TransferPictures
使用し、からDibToBitmap.FormHDib(hbitmap)
取得するために使用していますが、.bitmapsource
IntPtr
bitmapimage
IntPtr
bitmapsource
代わりにbitmapimage
直接に変換して、bitmapsource
その後に変換したいbitmapimage
ビットマップ コンストラクター メソッドを使用する
Bitmap newBitmap = new Bitmap(width, height, Stride, PixelFormat, bitmapSource);