mirror of
https://github.com/crskycode/GARbro.git
synced 2026-07-08 01:30:18 +08:00
feat: MAGES PS3/PSV Image Format decoding
This commit is contained in:
@@ -65,6 +65,16 @@ namespace GameRes.Formats.BGI
|
||||
return null;
|
||||
if (0 != stream.ReadInt64())
|
||||
return null;
|
||||
|
||||
if (flag == 0)
|
||||
{
|
||||
int stride = (int)width * ((bpp + 7) / 8);
|
||||
var pixels = new byte[stride * (int)height];
|
||||
int read = stream.Read(pixels, 0, pixels.Length);
|
||||
if (read != pixels.Length)
|
||||
return null;
|
||||
}
|
||||
|
||||
return new BgiMetaData
|
||||
{
|
||||
Width = (uint)width,
|
||||
|
||||
Reference in New Issue
Block a user