mirror of
https://github.com/crskycode/GARbro.git
synced 2024-12-24 20:04:13 +08:00
(S25Format.Read): use ImageData.Create shortcut.
This commit is contained in:
parent
1f9e4d7b33
commit
fc27ece34d
@ -80,10 +80,7 @@ namespace GameRes.Formats.ShiinaRio
|
||||
using (var reader = new Reader (stream, meta))
|
||||
{
|
||||
var pixels = reader.Unpack();
|
||||
var bitmap = BitmapSource.Create ((int)info.Width, (int)info.Height, 96, 96,
|
||||
PixelFormats.Bgra32, null, pixels, (int)info.Width*4);
|
||||
bitmap.Freeze();
|
||||
return new ImageData (bitmap, info);
|
||||
return ImageData.Create (info, PixelFormats.Bgra32, null, pixels);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user